curl --request GET \
--url https://sandbox.circularo.com/api/v2/documents \
--header 'Authorization: Bearer <token>'import requests
url = "https://sandbox.circularo.com/api/v2/documents"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://sandbox.circularo.com/api/v2/documents', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://sandbox.circularo.com/api/v2/documents",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://sandbox.circularo.com/api/v2/documents"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://sandbox.circularo.com/api/v2/documents")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.circularo.com/api/v2/documents")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"pagination": {
"limit": 20,
"nextCursor": "9f1c4e2a7b0d83f65a1e94c7d2b8061f3ac59e470b2d8f1a6c3e90b7d45f2a18",
"offset": 0
},
"results": [
{
"annotations": [
{
"addedAt": "2024-11-02T09:15:30.000Z",
"addedBy": {
"email": "jane.doe@example.com",
"fullname": "Jane Doe",
"userId": "jane.doe@example.com"
},
"comment": "Reviewed and approved",
"text": "Approved",
"type": "annotation_generic"
}
],
"attachments": [
{
"fileId": "s1pss1atbzli272pinbt48n2ssy96ax2pwgqrz5qyzklwxg1kl0tq6anvz1p97xj",
"fileName": "LegalNotes.docx",
"isMerged": false,
"isPublic": false,
"mimeType": "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
"pageCount": 8,
"size": 522481
}
],
"category": "Contract",
"createdAt": "2024-11-02T09:15:30.000Z",
"createdBy": {
"email": "jane.doe@example.com",
"fullname": "Jane Doe",
"userId": "jane.doe@example.com"
},
"customFields": [
{
"displayName": "Internal reference",
"key": "internalReference",
"value": "ACME-2026-001",
"type": "string"
}
],
"expiresAt": "2026-12-31T22:59:59.999Z",
"folders": [
{
"folderId": "97cfb9de-92dd-413a-b5e7-175eff7506d6",
"scope": "personal"
}
],
"id": "a0d01c9d-f72f-4c57-af11-e26bda19cc59",
"images": [
{
"addedAt": "2024-11-02T09:15:30.000Z",
"addedBy": {
"email": "jane.doe@example.com",
"fullname": "Jane Doe",
"userId": "jane.doe@example.com"
},
"comment": "Company logo",
"fileId": "s1pss1atbzli272pinbt48n2ssy96ax2pwgqrz5qyzklwxg1kl0tq6anvz1p97xj"
}
],
"mainFile": {
"fileId": "s1pss1atbzli272pinbt48n2ssy96ax2pwgqrz5qyzklwxg1kl0tq6anvz1p97xj",
"fileName": "Contract.pdf",
"mimeType": "application/pdf",
"pageCount": 12,
"size": 724158
},
"metadataDefinition": "d_default",
"metadataFields": {
"D_DEFAULT_DESCRIPTION": "Quarterly maintenance contract"
},
"owner": {
"email": "jane.doe@example.com",
"fullname": "Jane Doe",
"userId": "jane.doe@example.com"
},
"signatureProvider": "internal",
"signatures": [
{
"certificate": {
"fingerprintSha256": "A13767DDACA2D1B0ACAEB7CD3145D3D1CE14E208106318968FAF9882C8423F43",
"hasQcComplianceStatement": true,
"hasQcSscdStatement": true,
"isSelfSigned": true,
"issuer": "CN=Example Qualified CA,O=Example Trust Services,C=CZ",
"keyUsage": [
"digitalSignature",
"nonRepudiation"
],
"qcTypes": [
"eseal"
],
"serialNumber": "4DC32DD214A19795A2111484900663142F513989",
"signatureAlgorithm": "SHA256withRSA",
"subject": "CN=Example Ltd,O=Example Ltd,C=CZ",
"trustLists": [
"EUTL"
],
"validityEndsAt": "2024-11-02T09:15:30.000Z",
"validityStartsAt": "2024-11-02T09:15:30.000Z"
},
"comment": "Reviewed and approved",
"hasLongTermValidationData": true,
"isTimestamped": true,
"isVerified": true,
"sealProvider": "company-qseal",
"signatureProvider": "internal",
"signedAt": "2024-11-02T09:15:30.000Z",
"signedBy": {
"email": "jane.doe@example.com",
"fullname": "Jane Doe",
"userId": "jane.doe@example.com"
},
"signerName": "John Doe",
"timestampAuthority": "CN=Example TSA,O=Example Trust Services,C=CZ",
"tsaServer": "primary",
"type": "signature"
}
],
"submittedFiles": [
{
"createdAt": "2024-11-02T09:15:30.000Z",
"createdBy": {
"email": "jane.doe@example.com",
"fullname": "Jane Doe",
"userId": "jane.doe@example.com"
},
"fileId": "s1pss1atbzli272pinbt48n2ssy96ax2pwgqrz5qyzklwxg1kl0tq6anvz1p97xj",
"fileName": "SignedConsentForm.pdf",
"isPublic": false,
"mimeType": "application/pdf",
"pageCount": 8,
"size": 522481
}
],
"templateId": "cba71ea5-9a68-431a-a5c2-6d9932792ec7",
"term": {
"nonFixedTerm": {
"noticePeriod": "3M",
"terminationStartedAt": "2024-11-02T09:15:30.000Z"
},
"reminders": [
{
"notifyOwner": true,
"period": "30d",
"recipients": [
{
"email": "jane.doe@example.com",
"fullname": "Jane Doe",
"userId": "jane.doe@example.com"
}
],
"scheduledAt": "2024-11-02T09:15:30.000Z",
"sentAt": "2024-11-02T09:15:30.000Z",
"status": "scheduled",
"time": "09:00",
"timeZone": "Europe/Prague"
}
],
"renewal": {
"lastRenewedAt": "2024-11-02T09:15:30.000Z",
"latestExpiresAt": "2030-12-31T22:59:59.999Z",
"maxRenewals": 5,
"mode": "auto",
"noticeDueAt": "2027-03-31T22:00:00.000Z",
"noticePeriod": "3M",
"period": "1y",
"renewalCount": 2
},
"type": "fixed_term"
},
"title": "Client agreement",
"transaction": {
"completedAt": "2024-11-02T09:15:30.000Z",
"id": "a0d01c9d-f72f-4c57-af11-e26bda19cc590",
"status": "not-started",
"waitingFor": [
{
"expiresAt": "2024-11-02T09:15:30.000Z",
"hasTurn": true,
"order": 1,
"purpose": "sign",
"recipient": {
"email": "jane.doe@example.com",
"fullname": "Jane Doe",
"userId": "jane.doe@example.com"
},
"turnStartedAt": "2024-11-02T09:15:30.000Z"
}
]
},
"trashed": false,
"webUrl": "https://sandbox.circularo.com/home/detail?select=a0d01c9d-f72f-4c57-af11-e26bda19cc59"
}
],
"total": 42
}{
"status": 400,
"type": "VALIDATION:INPUT_INVALID",
"message": "Invalid input",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}{
"status": 401,
"type": "AUTH:UNAUTHORIZED",
"message": "Authentication failed",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}{
"status": 403,
"type": "AUTH:ACCESS_DENIED",
"message": "Access denied",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}{
"status": 429,
"type": "SYSTEM:RATE_LIMIT_EXCEEDED",
"message": "Rate limit exceeded",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}List documents
GET /documents
Lists the documents you can access, filtered with query parameters.
Combine any of the filters — every one you supply must match. Filter on the document itself: its title and content (query), metadata definition, category, creator, owner, creation time, expiration date, renewal notice deadline and kind of term. Filter on its transaction too: the status it is in, when it ended, the recipient it is currently waiting on, what that recipient is asked to do, and how long it has been waiting. Filter on the people who took part as well: who the document is shared with, who signed it and when, and who approved, reviewed or accepted it. Narrow the search to a single folder tree with scope, or to one folder with folderId. Alternatively, pass viewId to apply one of your saved document views (listed by GET /me under documentViews) — the view’s filters run server-side exactly as in the Circularo web app.
To filter by the values of metadata-definition fields, use the document search endpoint, which takes the same filters plus metadata-field values in a request body.
Results are returned newest first, or best match first when you search with query, documents holding its words as a phrase generally ranking highest. Page through them either with an offset for shallow access, or by following the opaque nextCursor returned in the pagination metadata for deep traversal. When you page with the cursor, send it on its own; it also keeps the order of a query’s results stable from page to page, which pages reached by offset do not guarantee.
curl --request GET \
--url https://sandbox.circularo.com/api/v2/documents \
--header 'Authorization: Bearer <token>'import requests
url = "https://sandbox.circularo.com/api/v2/documents"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://sandbox.circularo.com/api/v2/documents', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://sandbox.circularo.com/api/v2/documents",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://sandbox.circularo.com/api/v2/documents"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://sandbox.circularo.com/api/v2/documents")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.circularo.com/api/v2/documents")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"pagination": {
"limit": 20,
"nextCursor": "9f1c4e2a7b0d83f65a1e94c7d2b8061f3ac59e470b2d8f1a6c3e90b7d45f2a18",
"offset": 0
},
"results": [
{
"annotations": [
{
"addedAt": "2024-11-02T09:15:30.000Z",
"addedBy": {
"email": "jane.doe@example.com",
"fullname": "Jane Doe",
"userId": "jane.doe@example.com"
},
"comment": "Reviewed and approved",
"text": "Approved",
"type": "annotation_generic"
}
],
"attachments": [
{
"fileId": "s1pss1atbzli272pinbt48n2ssy96ax2pwgqrz5qyzklwxg1kl0tq6anvz1p97xj",
"fileName": "LegalNotes.docx",
"isMerged": false,
"isPublic": false,
"mimeType": "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
"pageCount": 8,
"size": 522481
}
],
"category": "Contract",
"createdAt": "2024-11-02T09:15:30.000Z",
"createdBy": {
"email": "jane.doe@example.com",
"fullname": "Jane Doe",
"userId": "jane.doe@example.com"
},
"customFields": [
{
"displayName": "Internal reference",
"key": "internalReference",
"value": "ACME-2026-001",
"type": "string"
}
],
"expiresAt": "2026-12-31T22:59:59.999Z",
"folders": [
{
"folderId": "97cfb9de-92dd-413a-b5e7-175eff7506d6",
"scope": "personal"
}
],
"id": "a0d01c9d-f72f-4c57-af11-e26bda19cc59",
"images": [
{
"addedAt": "2024-11-02T09:15:30.000Z",
"addedBy": {
"email": "jane.doe@example.com",
"fullname": "Jane Doe",
"userId": "jane.doe@example.com"
},
"comment": "Company logo",
"fileId": "s1pss1atbzli272pinbt48n2ssy96ax2pwgqrz5qyzklwxg1kl0tq6anvz1p97xj"
}
],
"mainFile": {
"fileId": "s1pss1atbzli272pinbt48n2ssy96ax2pwgqrz5qyzklwxg1kl0tq6anvz1p97xj",
"fileName": "Contract.pdf",
"mimeType": "application/pdf",
"pageCount": 12,
"size": 724158
},
"metadataDefinition": "d_default",
"metadataFields": {
"D_DEFAULT_DESCRIPTION": "Quarterly maintenance contract"
},
"owner": {
"email": "jane.doe@example.com",
"fullname": "Jane Doe",
"userId": "jane.doe@example.com"
},
"signatureProvider": "internal",
"signatures": [
{
"certificate": {
"fingerprintSha256": "A13767DDACA2D1B0ACAEB7CD3145D3D1CE14E208106318968FAF9882C8423F43",
"hasQcComplianceStatement": true,
"hasQcSscdStatement": true,
"isSelfSigned": true,
"issuer": "CN=Example Qualified CA,O=Example Trust Services,C=CZ",
"keyUsage": [
"digitalSignature",
"nonRepudiation"
],
"qcTypes": [
"eseal"
],
"serialNumber": "4DC32DD214A19795A2111484900663142F513989",
"signatureAlgorithm": "SHA256withRSA",
"subject": "CN=Example Ltd,O=Example Ltd,C=CZ",
"trustLists": [
"EUTL"
],
"validityEndsAt": "2024-11-02T09:15:30.000Z",
"validityStartsAt": "2024-11-02T09:15:30.000Z"
},
"comment": "Reviewed and approved",
"hasLongTermValidationData": true,
"isTimestamped": true,
"isVerified": true,
"sealProvider": "company-qseal",
"signatureProvider": "internal",
"signedAt": "2024-11-02T09:15:30.000Z",
"signedBy": {
"email": "jane.doe@example.com",
"fullname": "Jane Doe",
"userId": "jane.doe@example.com"
},
"signerName": "John Doe",
"timestampAuthority": "CN=Example TSA,O=Example Trust Services,C=CZ",
"tsaServer": "primary",
"type": "signature"
}
],
"submittedFiles": [
{
"createdAt": "2024-11-02T09:15:30.000Z",
"createdBy": {
"email": "jane.doe@example.com",
"fullname": "Jane Doe",
"userId": "jane.doe@example.com"
},
"fileId": "s1pss1atbzli272pinbt48n2ssy96ax2pwgqrz5qyzklwxg1kl0tq6anvz1p97xj",
"fileName": "SignedConsentForm.pdf",
"isPublic": false,
"mimeType": "application/pdf",
"pageCount": 8,
"size": 522481
}
],
"templateId": "cba71ea5-9a68-431a-a5c2-6d9932792ec7",
"term": {
"nonFixedTerm": {
"noticePeriod": "3M",
"terminationStartedAt": "2024-11-02T09:15:30.000Z"
},
"reminders": [
{
"notifyOwner": true,
"period": "30d",
"recipients": [
{
"email": "jane.doe@example.com",
"fullname": "Jane Doe",
"userId": "jane.doe@example.com"
}
],
"scheduledAt": "2024-11-02T09:15:30.000Z",
"sentAt": "2024-11-02T09:15:30.000Z",
"status": "scheduled",
"time": "09:00",
"timeZone": "Europe/Prague"
}
],
"renewal": {
"lastRenewedAt": "2024-11-02T09:15:30.000Z",
"latestExpiresAt": "2030-12-31T22:59:59.999Z",
"maxRenewals": 5,
"mode": "auto",
"noticeDueAt": "2027-03-31T22:00:00.000Z",
"noticePeriod": "3M",
"period": "1y",
"renewalCount": 2
},
"type": "fixed_term"
},
"title": "Client agreement",
"transaction": {
"completedAt": "2024-11-02T09:15:30.000Z",
"id": "a0d01c9d-f72f-4c57-af11-e26bda19cc590",
"status": "not-started",
"waitingFor": [
{
"expiresAt": "2024-11-02T09:15:30.000Z",
"hasTurn": true,
"order": 1,
"purpose": "sign",
"recipient": {
"email": "jane.doe@example.com",
"fullname": "Jane Doe",
"userId": "jane.doe@example.com"
},
"turnStartedAt": "2024-11-02T09:15:30.000Z"
}
]
},
"trashed": false,
"webUrl": "https://sandbox.circularo.com/home/detail?select=a0d01c9d-f72f-4c57-af11-e26bda19cc59"
}
],
"total": 42
}{
"status": 400,
"type": "VALIDATION:INPUT_INVALID",
"message": "Invalid input",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}{
"status": 401,
"type": "AUTH:UNAUTHORIZED",
"message": "Authentication failed",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}{
"status": 403,
"type": "AUTH:ACCESS_DENIED",
"message": "Access denied",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}{
"status": 429,
"type": "SYSTEM:RATE_LIMIT_EXCEEDED",
"message": "Rate limit exceeded",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}Authorizations
Query Parameters
Return only documents whose transaction reached its final state — completed, rejected, cancelled or expired — at or after this moment, as their transaction.completedAt states. A document whose transaction is still running or has not started does not match.
"2024-11-02T09:15:30.000Z"
Return only documents whose transaction reached its final state — completed, rejected, cancelled or expired — at or before this moment, as their transaction.completedAt states. A document whose transaction is still running or has not started does not match.
"2024-11-02T09:15:30.000Z"
Return only documents placed directly in this folder; the folder tree is taken from it. Combine with recursive to also include documents nested deeper. At most one of folderId and scope may be provided.
1^[A-Za-z0-9_-]+$"97cfb9de-92dd-413a-b5e7-175eff7506d6"
Return only documents whose last day for the renewal notice starts at or after this moment, as their term.renewal.noticeDueAt states — to include a notice due today, give the start of today or earlier. A document without a notice deadline does not match.
"2024-11-02T09:15:30.000Z"
Return only documents whose transaction is waiting for a recipient asked to perform any of these actions, whether it is already their turn or they are queued behind an earlier round.
sign: The recipient is requested to sign the document.approve: The recipient is requested to approve the document.review: The recipient is requested to review the document.accept: The recipient is requested to accept the document.
sign, approve, review, accept ["sign"]
Restrict the search to a single folder tree. Only documents at the root of that tree are returned — combine with recursive to include documents nested at any depth. Omit to search both trees. At most one of folderId and scope may be provided.
personal: Your personal folder tree, visible only to you.shared: The organization-wide shared folder tree.
personal, shared "shared"
Return only documents currently shared with any of these people, each given by the userId or email address of a user, or by the email address of a recipient without a Circularo account. Everyone the document was shared with, delegated to or reassigned to counts while their share lasts — also after they acted on it, and a recipient who delegated their action keeps their share. A share that was cancelled or has expired no longer counts.
["jane.doe@example.com"]
Return only documents signed at or after this moment — by a recipient, or by an owner signing the stored document; a signature placed while the document was created or edited, or as a step of its metadata definition's workflow, does not count, nor does a seal. Together with signedBy, one of those people must have signed within the period.
"2024-11-02T09:15:30.000Z"
Return only documents signed at or before this moment — by a recipient, or by an owner signing the stored document; a signature placed while the document was created or edited, or as a step of its metadata definition's workflow, does not count, nor does a seal. Together with signedBy, one of those people must have signed within the period.
"2024-11-02T09:15:30.000Z"
Return only documents signed by any of these people — a recipient who signed, or an owner who signed the stored document; a signature placed while the document was created or edited, or as a step of its metadata definition's workflow, does not count — each given by the userId or email address of a user, or by the email address of a recipient without a Circularo account.
["jane.doe@example.com"]
Return only documents whose term is of any of these kinds.
fixed_term: The document expires on a set date and its contract is renewed, automatically or by hand.expiry_only: The document expires on a set date and nothing renews it.non_fixed_term: The contract runs until it is terminated. The document expires only once a termination has started, the notice period after it.none: The document has no kind of term: it has no expiration date and is not a contract running until it is terminated.
fixed_term, expiry_only, non_fixed_term, none ["fixed_term"]
Return only documents whose transaction is in any of these statuses.
not-started: The document has been created, but no transaction has started over it yet.in-progress: A transaction is in progress: the document has been shared and is awaiting action from one or more recipients.completed: The transaction completed successfully — every requested recipient finished their action.rejected: The transaction ended because a recipient rejected the document.cancelled: The transaction was cancelled before completion.expired: The transaction expired before completion.
not-started, in-progress, completed, rejected, cancelled, expired ["in-progress"]
Apply one of your saved document views; the view's filters are applied exactly as in the Circularo web app. It cannot be combined with other search filters — pagination works as usual. The search returns documents only, so any folder-targeting part of the view does not apply.
^[A-Za-z0-9_-]+$"12"
Return only documents whose transaction is waiting for this recipient — the userId or email address of a user, or the email address of a recipient without a Circularo account — whether it is already their turn or they are queued behind an earlier round.
"jane.doe@example.com"
Response
Returns the matching documents and pagination metadata.
A page of documents.