cURL
curl --request POST --fail-with-body --max-time 30 \
"${AMLOK_API_BASE_URL}/v1/exports/record_synthetic/download-links" \
--header "Authorization: Bearer ${AMLOK_API_KEY}" \
--header 'Accept: application/json' \
--header 'Idempotency-Key: downloadExport-synthetic-0042' \
--header 'Content-Type: application/json' \
--data '{"purpose":"Institution underwriting review"}'import os
import requests
headers = {'Accept': 'application/json', 'Idempotency-Key': 'downloadExport-synthetic-0042', 'Content-Type': 'application/json'}
headers["Authorization"] = "Bearer " + os.environ["AMLOK_API_KEY"]
response = requests.request('POST', os.environ["AMLOK_API_BASE_URL"] + '/v1/exports/record_synthetic/download-links', headers=headers, json={'purpose': 'Institution underwriting review'}, timeout=30, allow_redirects=False)
response.raise_for_status()
print(response.json())
const headers = {"Accept": "application/json", "Idempotency-Key": "downloadExport-synthetic-0042", "Content-Type": "application/json"};
headers.Authorization = `Bearer ${process.env.AMLOK_API_KEY}`;
const response = await fetch(process.env.AMLOK_API_BASE_URL + "/v1/exports/record_synthetic/download-links", {
method: "POST", headers, redirect: "error", signal: AbortSignal.timeout(30000),
body: JSON.stringify({"purpose": "Institution underwriting review"})
});
if (!response.ok) throw new Error(`HTTP ${response.status}: ${await response.text()}`);
console.log(await response.json());
{
"data": {
"url": "https://downloads.example.com/synthetic",
"expires_at": "2026-11-06T12:05:00Z",
"sha256": "0000000000000000000000000000000000000000000000000000000000000000",
"mime_type": "application/json"
},
"meta": {
"request_id": "req_synthetic",
"schema_version": "1.0.0",
"environment": "sandbox"
}
}{
"error": {
"code": "validation_error",
"message": "Validation error.",
"retryable": false,
"request_id": "req_synthetic",
"field": null
}
}{
"error": {
"code": "unauthenticated",
"message": "Unauthenticated.",
"retryable": false,
"request_id": "req_synthetic",
"field": null
}
}{
"error": {
"code": "insufficient_credits",
"message": "Insufficient credits.",
"retryable": false,
"request_id": "req_synthetic",
"field": null
}
}{
"error": {
"code": "forbidden",
"message": "Forbidden.",
"retryable": false,
"request_id": "req_synthetic",
"field": null
}
}{
"error": {
"code": "not_found",
"message": "Not found.",
"retryable": false,
"request_id": "req_synthetic",
"field": null
}
}{
"error": {
"code": "idempotency_conflict",
"message": "Idempotency conflict.",
"retryable": false,
"request_id": "req_synthetic",
"field": null
}
}{
"error": {
"code": "cursor_expired",
"message": "Cursor expired.",
"retryable": false,
"request_id": "req_synthetic",
"field": null
}
}{
"error": {
"code": "payload_too_large",
"message": "payload too large",
"retryable": false,
"request_id": "req_synthetic",
"field": null
}
}{
"error": {
"code": "unsupported_media_type",
"message": "unsupported media type",
"retryable": false,
"request_id": "req_synthetic",
"field": null
}
}{
"error": {
"code": "validation_error",
"message": "Validation error.",
"retryable": false,
"request_id": "req_synthetic",
"field": null
}
}{
"error": {
"code": "rate_limited",
"message": "Rate limited.",
"retryable": true,
"request_id": "req_synthetic",
"field": null
}
}{
"error": {
"code": "temporarily_unavailable",
"message": "Temporarily unavailable.",
"retryable": true,
"request_id": "req_synthetic",
"field": null
}
}Exports
Download export
Download export.
POST
/
v1
/
exports
/
{id}
/
download-links
cURL
curl --request POST --fail-with-body --max-time 30 \
"${AMLOK_API_BASE_URL}/v1/exports/record_synthetic/download-links" \
--header "Authorization: Bearer ${AMLOK_API_KEY}" \
--header 'Accept: application/json' \
--header 'Idempotency-Key: downloadExport-synthetic-0042' \
--header 'Content-Type: application/json' \
--data '{"purpose":"Institution underwriting review"}'import os
import requests
headers = {'Accept': 'application/json', 'Idempotency-Key': 'downloadExport-synthetic-0042', 'Content-Type': 'application/json'}
headers["Authorization"] = "Bearer " + os.environ["AMLOK_API_KEY"]
response = requests.request('POST', os.environ["AMLOK_API_BASE_URL"] + '/v1/exports/record_synthetic/download-links', headers=headers, json={'purpose': 'Institution underwriting review'}, timeout=30, allow_redirects=False)
response.raise_for_status()
print(response.json())
const headers = {"Accept": "application/json", "Idempotency-Key": "downloadExport-synthetic-0042", "Content-Type": "application/json"};
headers.Authorization = `Bearer ${process.env.AMLOK_API_KEY}`;
const response = await fetch(process.env.AMLOK_API_BASE_URL + "/v1/exports/record_synthetic/download-links", {
method: "POST", headers, redirect: "error", signal: AbortSignal.timeout(30000),
body: JSON.stringify({"purpose": "Institution underwriting review"})
});
if (!response.ok) throw new Error(`HTTP ${response.status}: ${await response.text()}`);
console.log(await response.json());
{
"data": {
"url": "https://downloads.example.com/synthetic",
"expires_at": "2026-11-06T12:05:00Z",
"sha256": "0000000000000000000000000000000000000000000000000000000000000000",
"mime_type": "application/json"
},
"meta": {
"request_id": "req_synthetic",
"schema_version": "1.0.0",
"environment": "sandbox"
}
}{
"error": {
"code": "validation_error",
"message": "Validation error.",
"retryable": false,
"request_id": "req_synthetic",
"field": null
}
}{
"error": {
"code": "unauthenticated",
"message": "Unauthenticated.",
"retryable": false,
"request_id": "req_synthetic",
"field": null
}
}{
"error": {
"code": "insufficient_credits",
"message": "Insufficient credits.",
"retryable": false,
"request_id": "req_synthetic",
"field": null
}
}{
"error": {
"code": "forbidden",
"message": "Forbidden.",
"retryable": false,
"request_id": "req_synthetic",
"field": null
}
}{
"error": {
"code": "not_found",
"message": "Not found.",
"retryable": false,
"request_id": "req_synthetic",
"field": null
}
}{
"error": {
"code": "idempotency_conflict",
"message": "Idempotency conflict.",
"retryable": false,
"request_id": "req_synthetic",
"field": null
}
}{
"error": {
"code": "cursor_expired",
"message": "Cursor expired.",
"retryable": false,
"request_id": "req_synthetic",
"field": null
}
}{
"error": {
"code": "payload_too_large",
"message": "payload too large",
"retryable": false,
"request_id": "req_synthetic",
"field": null
}
}{
"error": {
"code": "unsupported_media_type",
"message": "unsupported media type",
"retryable": false,
"request_id": "req_synthetic",
"field": null
}
}{
"error": {
"code": "validation_error",
"message": "Validation error.",
"retryable": false,
"request_id": "req_synthetic",
"field": null
}
}{
"error": {
"code": "rate_limited",
"message": "Rate limited.",
"retryable": true,
"request_id": "req_synthetic",
"field": null
}
}{
"error": {
"code": "temporarily_unavailable",
"message": "Temporarily unavailable.",
"retryable": true,
"request_id": "req_synthetic",
"field": null
}
}Download export. All IDs and cursors must belong to the authorized workspace and environment. Required scope: exports:read. Data exports require data:read and source authorization; risk-package exports require results:read; billing exports require billing:read and Owner authority; evidence exports require evidence:read and source entitlements. Permissions are checked at creation, retrieval and download.
Examples use synthetic IDs. Replace them with values returned by your environment.
Authorizations
Server-to-server API key bound to exactly one workspace, institution tenant and environment. No caller-supplied workspace override is accepted. Do not use in public browser code.
Headers
Stable for one intended command and its retries, scoped to key workspace/environment and operation. Mismatched body returns 409. Full response replay 24 hours; durable receipt remains.
Minimum string length:
1Path Parameters
id
Minimum string length:
1Body
application/json
Authorized reason for accessing evidence or an export.
Minimum string length:
1