HTTP Request
POST
/v1/fileAuth: Signed API key required
Permissions: Valid signed API key required
Signed Location: Query string
Content-Type: multipart/form-data
Upload a file using multipart/form-data and receive its id and file_url.
Headers
| Parameter Name | Required | Type | Notes |
|---|---|---|---|
| X-MBX-APIKEY | true | string | Provisioned ACCESS_ID. x-access-id is also accepted by the backend, but X-MBX-APIKEY is recommended. |
Request Parameters
| Parameter Name | Required | Type | Notes |
|---|---|---|---|
| timestamp | true | int64 | Request timestamp in milliseconds. Microseconds are also accepted and normalized by the server. |
| recvWindow | false | integer | Optional receive window. Default 5000, maximum 60000. |
| signature | true | string | HMAC-SHA256 signature of the signed payload. RSA and Ed25519 are also supported when provisioned. |
Request Body
| Parameter Name | Required | Type | Notes |
|---|---|---|---|
| file | true | binary | Single uploaded file in multipart/form-data. |
Return Parameters
| Parameter Name | Required | Type | Notes |
|---|---|---|---|
| data.id | true | integer | Uploaded file id. |
| data.file_url | true | string | File URL. |
Notes
- Validate the magic header signature before accepting the file.
- Max size 50MB; images max 25MB; filename max 128 characters.
Request Example
curl -X POST 'https://<host>/v1/file?timestamp=<TIMESTAMP>&recvWindow=5000&signature=<SIGNATURE>' \
-H 'X-MBX-APIKEY: <ACCESS_ID>' \
-F 'file=@/path/to/proof.pdf'