The AddFormDocument() command allows the user to add a document to a form.
|
| Parameter | Type | Max Length | Required | Description |
|---|---|---|---|---|
| apiToken | string | 50 | y | Your Field View API token. |
| formId | string | y | The form ID to which the document will be added. | |
| documentBytes | string | 15MB | y | The contents of the document. |
| fileName | string | 255 | y | The file name of the document you wish to attach to the form. |
| Field | Type | Description |
|---|---|---|
| formId | string | If successful, the form ID to which the document was added. |
| status | success or fail message | The status of the request. |
Sample request
<AddFormDocument>
<apiToken>F4CB1F55BB64625BD0F6A588DECB3D03F17B87F</apiToken>
<formId>F1.1900</formID>
<documentBytes>dGVzdCBmaWxlIGNvbnRlbnRz</documentBytes>
<fileName>test-document.txt<fileName>
</AddFormDocument>
Sample response
<AddFormDocumentResponse>
<AddFormDocumentResult>{"ID":"F1.1900","Status":{"Code":2,"Message":"Success. [ActivityId]: 6df820ae-66e3-4c97-8e32-de70d113dd9a"}} </AddFormDocumentResponse>
</AddFormDocumentResponse>