Create Record Documents

Creates one or more document attachments for the specified record. To specify the documents to be attached, use the HTTP header "Content-Type:multipart/form-data" and form-data for "uploadedFile" and "fileInfo". Note that the "fileInfo" is a string containing an array of file attributes. Use "fileInfo" to specify one or more documents to be attached. See the example for details.

Resource Information

Scoperecords

Deprecated scope name:   create_record_documents

App TypeAll
Authorization TypeAccess token
URI /v4/records/{recordId}/documents?userId={userId}&password={password}&lang={lang}
HTTP MethodPOST
Automation Version(s)7.3.2

Request Information

Field or ParameterTypeRequiredValuesDescriptionAutomation Version
categorystringNoThe document category. The list of category options varies depending on the document group.7.3.2
groupstringNoThe group query parameter.7.3.2
langStringNoIndicates the language applied.7.3.2
passwordstringNoThe password related to the operation.7.3.2
recordIdstringYes Get All Records Search Records Get My Records The unique ID associated with a record.7.3.2
userIdstringNoThe users login ID for the Accela Civic Platform, created by agency administrators.7.3.2

Example

Sample Request Head

POST https://apis.accela.com/v4/records/12CAP-00000-00003/documents
Content-Type: multipart/form-data

Sample Request Body

Form-data:
Content-Disposition: form-data; name="uploadedFile"; filename="Accela_Logo.gif"
 Content-Type: image/gif
Content-Disposition: form-data; name="fileInfo"
[
   {
      "serviceProviderCode": "ISLANDTON",
      "fileName": "Accela_logo.gif",
      "type": "image/gif",
      "description": "Sample logo file"
   }
]

Response Information

FieldTypeDescriptionAutomation Version
result[]result{}7.3.2
result.codestringA code identifying an associated item7.3.2
result.idstringThe unique identifier for the object, assigned by the Civic Platform server and provided in a response.7.3.2
result.isSuccessbooleanIndicates whether or not the operation on the item is successful. 7.3.2
result.messagestringA text message related to the operation.7.3.2
statusintegerThe record status.7.3.3

Example

Sample Response Body

{
  "status": 200,
  "result": [
    {
      "id": 2556216
    }
  ]
}