Method GET: POST Resource: event/{id}/texttexts Parameters (transferred as JSON): {id} - OBJECT_ID of event
Supporting HTTP-heading Range Response: All the extracted text of the event intercepted (if there are few enclosed documents, the text is to be extracted from all the documents and to be assembled into one block). | Блок кода | Content-type: text/plain.response_type — type of response:chunked — using Transfer-Encoding: chunked , where each text is left within its block and order, transferred within the query body. In case there is no text, null, symbol "\0" is trasferred instead of the textmultipart/mixed — multipart/mixedrfc tech-ms format is used, it is not a HTTP format, but it is used in e-mails. That's why this can be realised. It is also similar to multipart/form-data . Each text is left within its block and is specified by X-Event-ID title in accordance with event it belongs to. In case there is no text, it cannot be transferred or the text body is absentevents — objects massive with fields:id — event IDtbsId — event tablespace
Examples: chunked : | Блок кода |
|---|
| POST /xapi/event/texts
X-API-Version: 1.1
X-API-CompanyId: iw
X-API-ImporterName: dome
X-API-Auth-Token: brse99dugp1cdbr69axz
(empty string)
{"response_type": "chunked", "events": [{"id": 2, "tbsId": 4}, {"id": 4, "tbsId": 4}]} |
| Блок кода |
|---|
| HTTP/1.1 200 OK
Content-Type: text/plain
Transfer-Encoding: chunked
(empty string)
1
\0 (text absence symbol for event 2)
48AC
(text content for event 4)
0 |
multipart/mixed :
| Блок кода |
|---|
| POST /xapi/event/texts
X-API-Version: 1.1
X-API-CompanyId: iw
X-API-ImporterName: dome
X-API-Auth-Token: brse99dugp1cdbr69axz
(empty string)
{"response_type": "multipart/mixed", "events": [{"id": 2, "tbsId": 4}, {"id": 4, "tbsId": 4}]} |
| Блок кода |
|---|
| HTTP/1.1 200 OK
Content-Type: multipart/mixed; boundary=Asrf456BGe4h
Content-Length: (summary amount, including child titles can be absent!)
(empty string)
(absent preamble)
--Asrf456BGe4h
Content-Type: application/x-empty
Content-Disposition: attachment; filename="text-2.txt"
X-Event-ID: 2
(empty string and null content after)
--Asrf456BGe4h
Content-Disposition: attachment; filename="text-4.txt"
Content-Type: text/plain
X-Event-ID: 4
(empty string)
(text content for event 4)
--Asrf456BGe4h--
(absent epilogue - empty string) |
|