Table of Contents
This API is used for integration with other subsystems. The other subsystems consume this api as clients.
Resources defined in this part can be accesed without authorization. Path to all resources starts with /urest/ prefix.
List all domains existing in DocumentServer.
XML is returned as response
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?> <Domains ports="7780" sslPorts="7781"> <Domain description="LightComp v.o.s." name="lightcomp.ep1" /> <Domain description="Demo LightComp v.o.s." name="lightcomp.ept" /> </Domains>
Ports accepting connections from Tahiti are returned as attributes of <Domains> tag.
semicolon separated list of unsecure ports
semicolon separated list of ssl ports
Domain description is returned in attributes of tag <Domain>
human readable name of domain
system name of domain
Resources defined in this part can be accessed only by authorized users. HTTP BASIC authorization is used as authorization mechanism. Username is composed from user and domain separated by @.
user: user@domain password: *****
Path to all resources starts with /rest/ prefix.
Description of common structures returned as result of resource query
Description of document
<Document version="2" id="fd8b511d-6a83-4d58-a9f6-52ed73b0a335" documentTypeName="II - Invoice Incoming" documentType="BookKeeping_II"> - <Attributes> .... </Attributes> - <Pages> .... </Pages> </Document>
Document can contain <Attributes> and <Pages> and is described by following attributes
unique id of document
version of document
type of document
human readable localized name of document type
Description of one document attribute
<Attribute localizedName="Period" value="11" name="Period" />
Attribute contains following attributes
name of attribute
value of attribute
human readable localized name of attribute
Get concrete version of document
Resource is mapped to following URI accepting GET request
/rest/documents/${id}/${version}
Request parameters
unique identifier of document
version of document
execute request in context of given user, when not present execute in context of logged user
XML describing document version is returned.
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?> - <Document version="2" id="fd8b511d-6a83-4d58-a9f6-52ed73b0a335" documentTypeName="II - Invoice Incoming" documentType="BookKeeping_II"> - <Attributes> <Attribute localizedName="Period" value="11" name="Period" /> <Attribute localizedName="Supplier" value="franta" name="Supplier" /> <Attribute localizedName="Number" value="2010112300" name="FileNumber" /> <Attribute localizedName="Year" value="2010" name="BusinessYear" /> </Attributes> - <Pages> <Page id="8161ea78-4636-49a9-a77d-465acc887850" mimeType="APPLICATION/PDF" /> </Pages> </Document>
<Document> tag contains following attributes
unique id of document
version of document
type of document
human readable localized name of document type
<Attribute> tag contains following attributes
name of attribute
value of attribute
human readable localized name of attribute
<Page> tag contains following attributes
id of page
mime type of page
Get page of concrete document version
Resource is mapped to following URI accepting GET request
/rest/documents/${id}/${version}/${pageId}
Request parameters
id of document
version of document
id of requested page
execute request in context of given user, when not present execute in context of logged user
Get page by id
Resource is mapped to following URI accepting GET request
/rest/pages/${pageId}
Request attributes
id of requested page
execute request in context of given user, when not present execute in context of logged user
Push last document version to Tahiti
Resource is mapped to following URI accepting GET request
/rest/push/${id}?user=${user}
Request parameters
id of document to be pushed to Tahiti
connected user to push document to
XML describing status of push operation is returned
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?> <SearchResult result="OK" version="2" documentId="fd8b511d-6a83-4d58-a9f6-52ed73b0a335" />
<SearchResult> contains result of push operation.
OK - successfully push to given user, NOT_CONNECTED when user isn't connected to server
id of document
version of document pushed to user
Return HTTP 404 when document with given id doesn't exist
Search document by fulltext query
/rest/documents?query=11&start=0
Request attributes
fulltext serarch query
zero based index of first returned result, attribute is optional, default value is 0
restrict results to given documentType, attribute is optional
true - search only over last versions (default), false - search over all versions, attribute is optional
execute search in context of given user, when not present execute in context of logged user
XML containing search results are returned
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?> - <SearchResults numResults="4"> - <Documents> - <Document version="2" id="fd8b511d-6a83-4d58-a9f6-52ed73b0a335" documentTypeName="II - Invoice Incoming" documentType="BookKeeping_II"> - <Attributes> <Attribute localizedName="Period" value="11" name="Period" /> <Attribute localizedName="Supplier" value="franta" name="Supplier" /> <Attribute localizedName="Number" value="2010112300" name="FileNumber" /> <Attribute localizedName="Year" value="2010" name="BusinessYear" /> </Attributes> </Document> - <Document version="2" id="160632b3-42fa-405e-89b5-e417b0600d3a" documentTypeName="II - Invoice Incoming" documentType="BookKeeping_II"> - <Attributes> <Attribute localizedName="Period" value="11" name="Period" /> <Attribute localizedName="Supplier" value="franta" name="Supplier" /> <Attribute localizedName="Number" value="2010112301" name="FileNumber" /> <Attribute localizedName="Year" value="2010" name="BusinessYear" /> </Attributes> </Document> - <Document version="2" id="2743efc7-193b-4fa6-8db7-abdc2925fc96" documentTypeName="II - Invoice Incoming" documentType="BookKeeping_II"> - <Attributes> <Attribute localizedName="Period" value="11" name="Period" /> <Attribute localizedName="Supplier" value="franta" name="Supplier" /> <Attribute localizedName="Number" value="2010112302" name="FileNumber" /> <Attribute localizedName="Year" value="2010" name="BusinessYear" /> </Attributes> </Document> - <Document version="1" id="3e8361e7-0725-4e0e-97e8-192b474cb9d1" documentTypeName="API - Advance Payment Order Incoming" documentType="BookKeeping_AII"> - <Attributes> <Attribute localizedName="Period" value="11" name="Period" /> <Attribute localizedName="Supplier" value="" name="Supplier" /> <Attribute localizedName="Number" value="0050" name="FileNumber" /> <Attribute localizedName="Year" value="2010" name="BusinessYear" /> </Attributes> </Document> </Documents> </SearchResults>
<SearchResult> tag wrap returned results.
total number of documents satisfying given query