Skip to main content
GET
/
workspaces
/
{workspaceId}
/
documents
List Workspace Documents
curl --request GET \
  --url https://api.raydocs.com/workspaces/{workspaceId}/documents \
  --header 'Authorization: Bearer <token>'
{
  "data": [
    {
      "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "workspace_id": 123,
      "filename": "<string>",
      "mime": "<string>",
      "size": 123,
      "sha256": "<string>",
      "status": "uploaded",
      "source_type": "upload",
      "source_url": "<string>",
      "parsings": [
        {
          "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
          "config_hash": "<string>",
          "status": "queued",
          "parser_version": "<string>",
          "updated_at": "2023-11-07T05:31:56Z"
        }
      ],
      "created_at": "2023-11-07T05:31:56Z"
    }
  ],
  "meta": {
    "current_page": 123,
    "last_page": 123,
    "per_page": 123,
    "total": 123
  }
}
List workspace-scoped documents that can be reused across sessions and runs.

Authentication & Scope

Requires documents-read.

Request

GET /workspaces/12/documents?query=invoice&status=processed&page=1&per_page=20 HTTP/1.1
Host: api.raydocs.com
Authorization: Bearer <token>

Query Parameters

ParameterTypeDescription
querystringSearch by filename, source URL, or hash
mimestringFilter by MIME type
statusstringFilter by document status
source_typestringupload, url, or connector
sortstringcreated_at, filename, size, status
orderstringasc or desc
pageintegerPage number
per_pageintegerItems per page (max 100)

Response

200 OK
{
  "data": [
    {
      "id": "880e8400-e29b-41d4-a716-446655440000",
      "workspace_id": 12,
      "filename": "invoice.pdf",
      "mime": "application/pdf",
      "size": 123456,
      "sha256": "6de7f6f5894c9f3fd1f6f8a4d1b3115d0d9b4b19d7a8a661f9fe90f9c2d80c3b",
      "status": "processed",
      "source_type": "upload",
      "created_at": "2026-02-28T10:30:00Z"
    }
  ],
  "meta": {
    "current_page": 1,
    "per_page": 20,
    "total": 153,
    "last_page": 8
  }
}

Authorizations

Authorization
string
header
required

Personal Access Token created from the Raydocs dashboard. Include in the Authorization header: Bearer <your_token> See API Keys for token creation and management.

Path Parameters

workspaceId
integer
required

Query Parameters

page
integer
default:1
per_page
integer
default:20
Required range: x <= 100
query
string
mime
string
status
string
source_type
enum<string>
Available options:
upload,
url,
connector
sort
enum<string>
Available options:
created_at,
filename,
size,
status
order
enum<string>
Available options:
asc,
desc

Response

Successful

data
object[]
meta
object