Was this helpful?
List all cargo containers
GET /api/cargo/container HTTP/1.1 Host: localhost:3000 Authorization: Bearer JWT Accept: */*
List of cargo containers
[ { "id": "123e4567-e89b-12d3-a456-426614174000", "name": "text", "description": "text", "items": [ { "cargoId": "123e4567-e89b-12d3-a456-426614174000", "targetPath": "text" } ], "createdAt": "2025-05-20T02:38:03.178Z", "updatedAt": "2025-05-20T02:38:03.178Z" } ]
Get cargo details by ID
GET /api/cargo/{id} HTTP/1.1 Host: localhost:3000 Authorization: Bearer JWT Accept: */*
Cargo details
{ "id": "123e4567-e89b-12d3-a456-426614174000", "name": "text", "description": "text", "hash": "text", "size": 1, "mimeType": "text", "type": "local", "remoteUrl": "text", "properties": { "hidden": true, "readonly": true, "noDelete": true, "customProperties": {} }, "createdAt": "2025-05-20T02:38:03.178Z", "updatedAt": "2025-05-20T02:38:03.178Z" }
Delete a cargo item
DELETE /api/cargo/{id} HTTP/1.1 Host: localhost:3000 Authorization: Bearer JWT Accept: */*
Cargo deleted successfully
No content
Download a cargo file
GET /api/cargo/{id}/download HTTP/1.1 Host: localhost:3000 Authorization: Bearer JWT Accept: */*
Cargo file
binary
Get container details by ID
GET /api/cargo/containers/{id} HTTP/1.1 Host: localhost:3000 Authorization: Bearer JWT Accept: */*
Container details
{ "id": "123e4567-e89b-12d3-a456-426614174000", "name": "text", "description": "text", "items": [ { "cargoId": "123e4567-e89b-12d3-a456-426614174000", "targetPath": "text" } ], "createdAt": "2025-05-20T02:38:03.178Z", "updatedAt": "2025-05-20T02:38:03.178Z" }
Delete a cargo container
DELETE /api/cargo/containers/{id} HTTP/1.1 Host: localhost:3000 Authorization: Bearer JWT Accept: */*
Container deleted successfully
Assign a cargo container to a unit
POST /api/cargo/containers/{containerId}/units/{unitId} HTTP/1.1 Host: localhost:3000 Authorization: Bearer JWT Accept: */*
Container assigned successfully
Remove a cargo container from a unit
DELETE /api/cargo/containers/{containerId}/units/{unitId} HTTP/1.1 Host: localhost:3000 Authorization: Bearer JWT Accept: */*
Container removed successfully
List all cargo items
GET /api/cargo HTTP/1.1 Host: localhost:3000 Authorization: Bearer JWT Accept: */*
List of cargo items
[ { "id": "123e4567-e89b-12d3-a456-426614174000", "name": "text", "description": "text", "hash": "text", "size": 1, "mimeType": "text", "type": "local", "remoteUrl": "text", "properties": { "hidden": true, "readonly": true, "noDelete": true, "customProperties": {} }, "createdAt": "2025-05-20T02:38:03.178Z", "updatedAt": "2025-05-20T02:38:03.178Z" } ]
Upload a file as cargo
JSON string of cargo properties
POST /api/cargo/upload HTTP/1.1 Host: localhost:3000 Authorization: Bearer JWT Content-Type: multipart/form-data Accept: */* Content-Length: 31 { "file": "binary", "data": "text" }
Cargo uploaded successfully
Add a remote URL as cargo
POST /api/cargo/remote HTTP/1.1 Host: localhost:3000 Authorization: Bearer JWT Content-Type: application/json Accept: */* Content-Length: 153 { "name": "text", "description": "text", "remoteUrl": "https://example.com", "properties": { "hidden": true, "readonly": true, "noDelete": true, "customProperties": {} } }
Remote cargo added successfully
Update cargo properties
PATCH /api/cargo/{id} HTTP/1.1 Host: localhost:3000 Authorization: Bearer JWT Content-Type: application/json Accept: */* Content-Length: 119 { "name": "text", "description": "text", "properties": { "hidden": true, "readonly": true, "noDelete": true, "customProperties": {} } }
Cargo updated successfully
Create a new cargo container
POST /api/cargo/containers HTTP/1.1 Host: localhost:3000 Authorization: Bearer JWT Content-Type: application/json Accept: */* Content-Length: 117 { "name": "text", "description": "text", "items": [ { "cargoId": "123e4567-e89b-12d3-a456-426614174000", "targetPath": "text" } ] }
Container created successfully
Update container details
PATCH /api/cargo/containers/{id} HTTP/1.1 Host: localhost:3000 Authorization: Bearer JWT Content-Type: application/json Accept: */* Content-Length: 117 { "name": "text", "description": "text", "items": [ { "cargoId": "123e4567-e89b-12d3-a456-426614174000", "targetPath": "text" } ] }
Container updated successfully