Skip to content

Create Resource Document

Request

Attach an uploaded document to a resource without a validity. Upload the file through the document upload endpoint first and pass the returned upload_id.

Security
oAuth2ClientCredentials
Path
resource_idstring, (uuid)(Resource Id)required
Bodyapplication/jsonrequired
upload_idstring, (uuid)(Upload Id)required

Unique identifier of the uploaded file

document_typeContainerDocumentTypes (string) or DriverDocumentTypes (string) or VehicleDocumentTypes (string)(Document Type)required
Any of:

Type of the document

string(ContainerDocumentTypes)
Enum:"COMMUNICATION_SUBCONTRACTOR""CONTAINER_CERTIFICATE""CONTAINER_DAMAGE_REPORT""CONTAINER_INSPECTION_REPORT""CONTAINER_LEASE""CONTAINER_MAINTENANCE_REPORT""CONTAINER_REPAIR_REPORT""CONTAINER_TANK_TEST_CERTIFICATE_2Y5""CONTAINER_TANK_TEST_CERTIFICATE_5Y""CONTAINER_TANK_TEST_CERTIFICATE"
namestring(Name)required

Name of the document

{ "upload_id": "f2ef591b-135b-46fa-a604-3d4fda5bfbfb", "document_type": "COMMUNICATION_SUBCONTRACTOR", "name": "string" }

Responses

Successful Response

Bodyapplication/json
idstring, (uuid)(Id)required

Unique identifier of the document

namestring(Name)required

Name of the document

typestring(Type)required

Type of the document

download_urlstring(Download Url)

Relative URL from the base URL to download the document

Default:""
subject_typestring(Subject Type)required

Linked subject of the document

content_typestring or null(Content Type)
Any of:

Content type of the document

string
Response
{ "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "name": "string", "type": "string", "download_url": "", "subject_type": "string", "content_type": "string" }