Skip to main content
GET
/
document
/
cURL
curl --request GET \
  --url https://api.example.com/document/ \
  --header 'Authorization: Bearer <token>'
{
  "count": 123,
  "results": [
    {
      "id": 123,
      "title": "<string>",
      "processed": true,
      "approved": true,
      "sent": true,
      "created_at": "2023-11-07T05:31:56Z",
      "file": "<string>",
      "user": {
        "id": 123,
        "username": "<string>",
        "email": "jsmith@example.com"
      },
      "tags": [
        {}
      ],
      "archive": true,
      "archive_reason": "<string>",
      "fleet": {
        "id": 123,
        "region_details": [
          {
            "id": 123,
            "title": "<string>"
          }
        ],
        "title": "<string>",
        "is_active": true,
        "warning_threshold_per_vehicle": "<string>",
        "deactivation_threshold_per_vehicle": "<string>",
        "client": "<string>",
        "onboarding_vehicle_order": 123
      },
      "vehicle_status": "<string>"
    }
  ],
  "next": "http://api.example.org/accounts/?offset=400&limit=100",
  "previous": "http://api.example.org/accounts/?offset=200&limit=100"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Query Parameters

limit
integer

Number of results to return per page.

offset
integer

The initial index from which to return the results.

Full-text search on document title, uploader username, and uploader email.

ordering
string

Sort field: created_at, title, user__username, fleet__title, or tags. Prefix with - for descending order.

status
enum<string>

Filter by processing status. Repeatable to include multiple statuses.

Available options:
Processing,
Uploaded,
Processed
approved
boolean

Filter by approval flag.

processed
boolean

Filter by processed flag.

sent
boolean

Filter by sent flag.

archived
boolean

Filter by archive flag.

title__icontains
string

Case-insensitive substring match on title. istartswith, iendswith, and exact lookups are also supported.

user__username__icontains
string

Case-insensitive substring match on uploader username.

user__email__icontains
string

Case-insensitive substring match on uploader email.

fleet__title__icontains
string

Case-insensitive substring match on fleet title.

tags__icontains
string

Filter by tag name (case-insensitive substring match).

created_at__gte
string<date>

Return documents created on or after this date (YYYY-MM-DD).

created_at__lte
string<date>

Return documents created on or before this date (YYYY-MM-DD).

Response

200 - application/json
count
integer
required
Example:

123

results
object[]
required
next
string<uri> | null
Example:

"http://api.example.org/accounts/?offset=400&limit=100"

previous
string<uri> | null
Example:

"http://api.example.org/accounts/?offset=200&limit=100"