Create Ticket My Tickets Post Discussion
Welcome
Login  Sign up

POST Task (Files)

TABLE OF CONTENTS

ADDITIONAL INFO


This request method allows you to upload files for a given task. On the Cloud, this API is available via SSL-secured HTTPS connection using the REST POST verb. The format query string parameter controls the desired response format. Specify either XML or JSON.


/api/v2/task?format=xml/json


You may use either JSON or XML formats in your POST submission.You indicate this by setting the ContentType HTTP header as "application/json" or "application/xml". If no ContentType is specified, XML format is assumed.


All XML formatted requests must specify the following XML namespace in the data source root element:
xmlns:i="http://www.w3.org/2001/XMLSchema-instance"



Parameters

The POST verb allows you to upload files for a given task.
The required and optional parameters for a POST call to the Task API are outlined below.


NameTypeDescriptionRequired
TaskIdStringThe unique identifier of the Task to upload this file.

SendTaskOnUploadBoolean

Whether or not to send the Task on successful upload. If additional files are still required to be uploaded on the Task, this instruction will be ignored.


CompanyIdIntegerYour unique Company Id is found on the Organisation Setup page of the secure website.

IntegrationKeyString

Your unique Integration Key is found on the Organisation Setup page of the secure website.


FileFileThe file(s) to upload using multipart/form-data. Multiple files can be uploaded in a single request. Ensure you have registered the file name(s) in the Task. Files collection via the /task API ahead of uploading file(s). Uploaded file name(s) MUST match a pre-existing record in the target Task's Files collection. Note, too, that file names may only contain a maximum of 200 characters comprising of numbers, letters, and underscores. Any other characters will automatically be removed.



Example

Given that the API is REST-based, you can access the API directly via your web browser to test or by using Postman API Platform.


Request URL

https://secure.formsonfire.com/api/v2/task/files?TaskId=537XXXXXXXXXXXXXXXXXXXX&SendTaskOnUpload=false&CompanyId=6XXXX&IntegrationKey=995XXXXXXXXXXXXXXXXXXXXXXXXXX


Response Body

{
  "Id": "537XXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
  "Status": "Sent"
}


Did you find it helpful? Yes No

Send feedback
Sorry we couldn't be helpful. Help us improve this article with your feedback.