## plain Module ##

anyurn.php
	Returns a random low level URN e.g. for testing.
	GET Parameters:

anyworkurn.php
	Returns a random edition level URN e.g. for testing.
	GET Parameters:

authors.php
	Returns Document authors from workdata table.
	GET Parameters:sort

cloneedition.php
	Returns document content for document for cloning. Limited to copyright free data.
	GET Parameters:urn

clonemetadata.php
	Returns metadata for document for cloning
	GET Parameters:urn

credit.php
	Returns information about license, authorship and the project of the text passage and text corpus. corpus information is extracted from the file corpuscredit.txt if it exists.
	GET Parameters:urn

daterange.php
	Returns minimum, maximum values of publication dates and number of distinct date values in workdata table.
	GET Parameters:

dates.php
	Returns distinct publication dates and their frequencies.
	GET Parameters:

doccount.php
	Returns number of distinct work URNs.
	GET Parameters:urnfilter

doclanguages.php
	Returns distinct document languages and their frequencies.
	GET Parameters:

editions.php
	Returns edition level URN list.
	GET Parameters:author,lang,restricted,sortBy,title,unrestricted,urnfilter,year,yearmax,yearmin

editionsslim.php
	Returns edition level URN list.
	GET Parameters:urnfilter

exactsearch.php
	Returns exact matching structural elements for the given snippet and URN . Text is not included. Text is returned by textsearch.php.
	GET Parameters:limit,snippet,urn

firsturn.php
	Returns first child URN of a speciified URN.
	GET Parameters:urn

generatedpassage.php
	Returns a generated passage for the URN without using the cache. Slower and less performant than using the normal funtions but good for debugging of the cache.
	GET Parameters:nl,urn

label.php
	Returns the label for a specified URN. The result is based on db_GetLabel.php
	GET Parameters:urn

lemmatized.php
	Returns document URNs that included lemma-annotation by looking for </w> AND ( lemma= OR lemma =  ) in the text passage
	GET Parameters:

nexturn.php
	Returns the next URN in document order or NULL if the specified URN if there is none.
	GET Parameters:range,urn

passage.php
	Returns the text passage for the given URN.
	GET Parameters:deletexml,nl,urn

prevnexturn.php
	Returns the previous and next (or left and right) URN in document order or NULL if the specified URN if there is none.
	GET Parameters:urn

prevurn.php
	Returns the next URN in document order or NULL if the specified URN if there is none.
	GET Parameters:range,urn

punctuation.php
	Returns the characters that are considered as special chars
	GET Parameters:

searchauthors.php
	Returns Document authors matching the snippet from workdata table.
	GET Parameters:prefixsearch,snippet,sort,suffixsearch

searchtitles.php
	Returns Document titles matching the snippet from workdata table.
	GET Parameters:prefixsearch,snippet,sort,suffixsearch

stats.php
	RETURN DOCU MISSING.
	GET Parameters:

structure.php
	Returns every child URN with corresponding type and textlength. Dynamic URNs are not (yet) supported.
	GET Parameters:urn

structuretext.php
	Returns every child URN of a given static URN plus the corresponding text snippet. Dynamic URNs are not (yet) supported.
	GET Parameters:deletexml,lowercase,urn

textdistribution.php
	Returns the number of occurrences per structure element of the given character or text snippet.
	GET Parameters:character,deletexml,lowercase,snippet,urn

textexamples.php
	Returns textexamples for a given text snippet. Searches the copyrighted documents if less than 5 examples were found.
	GET Parameters:deletexml,limit,snippet,token

textgroups.php
	Returns textgroups generated from edition level URNs.
	GET Parameters:

textsearch.php
	Returns URNs and text. Limited to copyright-free documents. exactsearch.php returns only URNs and includes copyright-restricted documents.
	GET Parameters:limit,snippet,urn

urncount.php
	Returns number of static URNs on text level. This includes edition level URNs
	GET Parameters:urnfilter

urnlanguages.php
	Returns distinct urn languages.
	GET Parameters:

urnsperlang.php
	Returns URNs with the requested lang value.
	GET Parameters:lang,urn

urnstype.php
	Returns child URNs and their type fur a given URN.
	GET Parameters:urn

validreff.php
	Returns child URNs as specified by GetValidReff but without XML.
	GET Parameters:level,urn


## tm Module ##

bagofwords.php
	Returns Token Frequencies for a given URN. Count whitespace-separated surface forms after removing TEI tags per Regex, lowercasing according to the servers PHP configuration, and replacing punctuation listed in the servers $replacearr configuration. This endpoint does not return linguistically correct normalized word frequencies for arbitrary UTF-8 TEI documents.
	GET Parameters:lowercase,sort,urn

entities.php
	Returns a very basic Entitiy Recognition for a given URN. An entity is a capitalized word that does not appear uncapitalized
	GET Parameters:sort,urn

ngrams.php
	Returns ngrams for a given URN and n. Count whitespace-separated surface forms after removing TEI tags per Regex, lowercasing according to the servers PHP configuration, and replacing punctuation listed in the servers $replacearr configuration. This endpoint does not return linguistically correct normalized word forms for arbitrary UTF-8 TEI documents. nGram windows are calculated per sentence. A sentence is detected based on the servers $punctarr configuration. nGrams for restricted documents are only added for n<10. nGrams are only counted if completed, no placeholders are added.
	GET Parameters:lowercase,n,sort,urn

structurealignment.php
	Returns Alignments of text passages based on document structure. Works best with parallel corpora.
	GET Parameters:alignpart,urn

structurealignmenttable.php
	Returns Alignments of text passages based on document structure as a table. Works best with parallel corpora.
	GET Parameters:alignpart,urn

structurebagofwords.php
	Returns every child URN of a given static URN plus the corresponding text snippet bagofwords. Dynamic URNs are not (yet) supported.
	GET Parameters:lowercase,urn

typetokenratio.php
	Returns Type / Token Ratio for a given URN, a measure of vocabulary size
	GET Parameters:urn


## eval Module ##

document_coverage.php
	Returns percentage of coverage of the generated text passage compared to the source XML document. Parameter list provides URN based vs XML based passage length per document. Parameter incomplete reduces the result to incomplete cases. Parameter diff lists the calculated difference between xml and structure markup.
	GET Parameters:diff,incomplete,list

missingmetadata.php
	Returns edition level URN list.
	GET Parameters:year

textsize.php
	Returns the sum of all documents characters.
	GET Parameters:urnfilter


## files Module ##

tei.php
	Returns tei files for a given document level URN. The folder structure MUST be equal to the one that was used for the import.
	GET Parameters:urn



CTS Specifications:
https://github.com/cite-architecture/cts_spec/blob/master/md/specification.md

DTS Specifications:
https://dtsapi.org/specifications/
