For the complete documentation index, see llms.txt. This page is also available as Markdown.

Uploads

API for uploading billing files for savings estimates

Upload a billing file for a savings estimate

post

Accepts a multipart PDF, CSV, Excel (.xlsx), JSON, or text billing file, stores it in Archera's invoice upload bucket, and returns an upload ID. Use this upload ID with the savings-estimate operation. The upload status workflow is: PENDING before storage begins, PROCESSING while the file is being transferred, COMPLETE once it is available for analysis, and ERROR if storage fails.

Path parameters
org_idstring · uuidRequired
Body
descriptionstring · max: 255 · nullableOptional

Optional partner-supplied context for the uploaded billing file

filestring · binaryWrite-onlyRequired

Billing PDF, CSV, Excel (.xlsx), JSON, or text file to upload for a savings estimate

Responses
201

Created

application/json
idstring · uuidRead-onlyRequired
created_atstring · date-timeRead-onlyRequired
org_idstring · max: 50Read-onlyRequired
file_namestring · max: 255Read-onlyRequired
content_typestring · max: 255Read-onlyRequired
size_bytesintegerRead-onlyRequired
descriptionstring · max: 255 · nullableRead-onlyRequired
upload_statusstring · enumRead-onlyRequiredPossible values:
sourceundefined · enumRead-onlyRequiredPossible values:
detected_typestring · max: 64 · nullableRead-onlyRequired
post/v1/org/{org_id}/uploads
POST /v1/org/{org_id}/uploads HTTP/1.1
Content-Type: multipart/form-data
Accept: */*
Content-Length: 36

{
  "description": null,
  "file": "binary"
}
{
  "id": "123e4567-e89b-12d3-a456-426614174000",
  "created_at": "2026-01-01T00:00:00.000Z",
  "org_id": "text",
  "file_name": "text",
  "content_type": "text",
  "size_bytes": 1,
  "description": null,
  "upload_status": "PENDING",
  "source": "agent_upload",
  "detected_type": null,
  "available_actions": []
}

Initiate a direct billing-file upload

post

Creates a PENDING billing upload and returns a short-lived, one-write S3 PUT URL. PUT raw file bytes to upload_url using upload_method and every upload_headers value; do not use multipart form data. A 412 response means the bytes already reached storage, so POST to /uploads/{upload_id}/complete instead of retrying the PUT or initiating another upload. This is intended for clients that can access a local file but cannot pass file bytes through the API call, such as remote MCP clients.

Path parameters
org_idstring · uuidRequired
Body
file_namestring · max: 255Required
content_typestring · max: 255Required
size_bytesinteger · min: 1Required
descriptionstring · max: 255 · nullableOptional

Optional partner-supplied context for the uploaded billing file

Responses
201

Created

application/json
upload_idstring · uuidRead-onlyRequired
upload_urlstringRead-onlyRequired
upload_methodstringRead-onlyRequired
post/v1/org/{org_id}/uploads/initiate
POST /v1/org/{org_id}/uploads/initiate HTTP/1.1
Content-Type: application/json
Accept: */*
Content-Length: 76

{
  "file_name": "text",
  "content_type": "text",
  "size_bytes": 1,
  "description": null
}
{
  "upload_id": "123e4567-e89b-12d3-a456-426614174000",
  "upload_url": "text",
  "upload_method": "text",
  "upload_headers": {
    "ANY_ADDITIONAL_PROPERTY": "text"
  }
}

Complete a direct billing-file upload

post

Verifies that the file from a direct upload has reached storage at its declared size, then marks the upload COMPLETE so it can be used by the savings-estimate operation.

Path parameters
org_idstring · uuidRequired
upload_idstring · uuidRequired
Responses
200

OK

application/json
idstring · uuidRead-onlyRequired
created_atstring · date-timeRead-onlyRequired
org_idstring · max: 50Read-onlyRequired
file_namestring · max: 255Read-onlyRequired
content_typestring · max: 255Read-onlyRequired
size_bytesintegerRead-onlyRequired
descriptionstring · max: 255 · nullableRead-onlyRequired
upload_statusstring · enumRead-onlyRequiredPossible values:
sourceundefined · enumRead-onlyRequiredPossible values:
detected_typestring · max: 64 · nullableRead-onlyRequired
post/v1/org/{org_id}/uploads/{upload_id}/complete
POST /v1/org/{org_id}/uploads/{upload_id}/complete HTTP/1.1
Accept: */*
{
  "id": "123e4567-e89b-12d3-a456-426614174000",
  "created_at": "2026-01-01T00:00:00.000Z",
  "org_id": "text",
  "file_name": "text",
  "content_type": "text",
  "size_bytes": 1,
  "description": null,
  "upload_status": "PENDING",
  "source": "agent_upload",
  "detected_type": null,
  "available_actions": []
}

Get uploaded billing file status

get

Returns metadata and upload status for a partner API upload. Clients can poll this endpoint until upload_status is COMPLETE, then pass the upload ID to the savings-estimate operation.

Path parameters
org_idstring · uuidRequired
upload_idstring · uuidRequired
Responses
200

OK

application/json
idstring · uuidRead-onlyRequired
created_atstring · date-timeRead-onlyRequired
org_idstring · max: 50Read-onlyRequired
file_namestring · max: 255Read-onlyRequired
content_typestring · max: 255Read-onlyRequired
size_bytesintegerRead-onlyRequired
descriptionstring · max: 255 · nullableRead-onlyRequired
upload_statusstring · enumRead-onlyRequiredPossible values:
sourceundefined · enumRead-onlyRequiredPossible values:
detected_typestring · max: 64 · nullableRead-onlyRequired
get/v1/org/{org_id}/uploads/{upload_id}
GET /v1/org/{org_id}/uploads/{upload_id} HTTP/1.1
Accept: */*
{
  "id": "123e4567-e89b-12d3-a456-426614174000",
  "created_at": "2026-01-01T00:00:00.000Z",
  "org_id": "text",
  "file_name": "text",
  "content_type": "text",
  "size_bytes": 1,
  "description": null,
  "upload_status": "PENDING",
  "source": "agent_upload",
  "detected_type": null,
  "available_actions": []
}

Last updated

Was this helpful?