Logo ExelensiaExelensia/Docs
Getting Started
  • Introduction
API Reference
  • Schemas
  • Templates
  • Upload
  • Process
  • Files
  • Results
  • Exports

Files

The Files API lists and deletes files that have been uploaded to your team. Files are created by the Upload API and are referenced by process jobs. Deleting a file removes it from storage and cannot be undone.

Endpoints

GET /v1/files

Returns a paginated list of files belonging to your team.

Query Parameters

ParameterTypeRequiredDefaultDescription
pagenumberNo1Page number (min: 1)
limitnumberNo20Items per page (min: 1, max: 100)
sort_bystringNocreated_atSort field. Files support created_at
sort_orderstringNodescSort direction: asc or desc
created_afterstringNo—ISO 8601 date — files created on or after this date
created_beforestringNo—ISO 8601 date — files created on or before this date

Request

Bash
curl -H "x-api-key: wk_xxxxxxxx.your_secret_here" \
  "https://api.exelensia.com/v1/files?page=1&limit=20"

Response

JSON
{
  "data": [
    {
      "id": "019760a0-0020-7000-8000-000000000020",
      "filename": "invoice_2024_01.pdf",
      "bytes": 245760,
      "created_at": "2024-01-16T09:00:00.000Z",
      "updated_at": "2024-01-16T09:00:15.000Z"
    },
    {
      "id": "019760a0-0021-7000-8000-000000000021",
      "filename": "contract_q1.docx",
      "bytes": 87040,
      "created_at": "2024-01-16T08:30:00.000Z",
      "updated_at": "2024-01-16T08:30:10.000Z"
    }
  ],
  "meta": {
    "total": 2,
    "page": 1,
    "limit": 20,
    "totalPages": 1,
    "hasNextPage": false,
    "hasPrevPage": false
  }
}
FieldDescription
idFile UUID
filenameStored filename
bytesFile size in bytes
created_atWhen the file was uploaded
updated_atWhen the file record was last updated

Status Codes

StatusDescription
200Success
401Missing or invalid authentication

DELETE /v1/files/:id

Deletes a file by ID. This removes the file record and its stored content permanently. This action cannot be undone.

Warning: Deleting a file does not delete the process jobs or results derived from it. Existing results remain accessible.

Path Parameters

ParameterTypeRequiredDescription
idstringYesFile UUID

Request

Bash
curl -X DELETE \
  -H "x-api-key: wk_xxxxxxxx.your_secret_here" \
  "https://api.exelensia.com/v1/files/019760a0-0020-7000-8000-000000000020"

Response

JSON
{
  "message": "OK"
}

Status Codes

StatusDescription
200File deleted
401Missing or invalid authentication
404File not found

On this page

  • Endpoints
  • GET /v1/files
  • DELETE /v1/files/:id