curl --request PATCH --fail-with-body --max-time 30 \
"${AMLOK_API_BASE_URL}/v1/monitors/record_synthetic" \
--header "Authorization: Bearer ${AMLOK_API_KEY}" \
--header 'Accept: application/json' \
--header 'If-Match: "1"' \
--header 'Content-Type: application/json' \
--data '{"status":"paused"}'import os
import requests
headers = {'Accept': 'application/json', 'If-Match': '"1"', 'Content-Type': 'application/json'}
headers["Authorization"] = "Bearer " + os.environ["AMLOK_API_KEY"]
response = requests.request('PATCH', os.environ["AMLOK_API_BASE_URL"] + '/v1/monitors/record_synthetic', headers=headers, json={'status': 'paused'}, timeout=30, allow_redirects=False)
response.raise_for_status()
print(response.json())
const headers = {"Accept": "application/json", "If-Match": "\"1\"", "Content-Type": "application/json"};
headers.Authorization = `Bearer ${process.env.AMLOK_API_KEY}`;
const response = await fetch(process.env.AMLOK_API_BASE_URL + "/v1/monitors/record_synthetic", {
method: "PATCH", headers, redirect: "error", signal: AbortSignal.timeout(30000),
body: JSON.stringify({"status": "paused"})
});
if (!response.ok) throw new Error(`HTTP ${response.status}: ${await response.text()}`);
console.log(await response.json());
{
"data": {
"id": "mon_synthetic",
"borrower_id": "bor_synthetic",
"deal": {
"institution_reference": "LOAN-0042",
"funded_amount": {
"amount": "50000.00",
"currency": "CAD"
},
"outstanding_amount": {
"amount": "48000.00",
"currency": "CAD"
},
"funded_at": "2026-11-05T12:00:00Z",
"maturity_date": "2027-11-06",
"repayment_frequency": "monthly",
"terms_document_ids": []
},
"status": "paused",
"baseline_package_id": "rp_synthetic",
"latest_package_id": "rp_signal_synthetic",
"risk_policy_version_id": "rpv_synthetic",
"cadence_id": "cadence_synthetic",
"next_evaluation_at": null,
"record_version": 2,
"connection_ids": [
"con_synthetic"
],
"requirements": [],
"failure": null,
"latest_deal_snapshot_id": "ds_synthetic",
"updated_at": "2026-11-06T12:00:00Z"
},
"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": "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": "invalid_state",
"message": "Invalid state.",
"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": "precondition_failed",
"message": "Precondition failed.",
"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
}
}Update monitor
Change future monitoring configuration with the current ETag. Historical assessments, alerts, evidence and charges remain immutable. A stopped monitor cannot resume.
curl --request PATCH --fail-with-body --max-time 30 \
"${AMLOK_API_BASE_URL}/v1/monitors/record_synthetic" \
--header "Authorization: Bearer ${AMLOK_API_KEY}" \
--header 'Accept: application/json' \
--header 'If-Match: "1"' \
--header 'Content-Type: application/json' \
--data '{"status":"paused"}'import os
import requests
headers = {'Accept': 'application/json', 'If-Match': '"1"', 'Content-Type': 'application/json'}
headers["Authorization"] = "Bearer " + os.environ["AMLOK_API_KEY"]
response = requests.request('PATCH', os.environ["AMLOK_API_BASE_URL"] + '/v1/monitors/record_synthetic', headers=headers, json={'status': 'paused'}, timeout=30, allow_redirects=False)
response.raise_for_status()
print(response.json())
const headers = {"Accept": "application/json", "If-Match": "\"1\"", "Content-Type": "application/json"};
headers.Authorization = `Bearer ${process.env.AMLOK_API_KEY}`;
const response = await fetch(process.env.AMLOK_API_BASE_URL + "/v1/monitors/record_synthetic", {
method: "PATCH", headers, redirect: "error", signal: AbortSignal.timeout(30000),
body: JSON.stringify({"status": "paused"})
});
if (!response.ok) throw new Error(`HTTP ${response.status}: ${await response.text()}`);
console.log(await response.json());
{
"data": {
"id": "mon_synthetic",
"borrower_id": "bor_synthetic",
"deal": {
"institution_reference": "LOAN-0042",
"funded_amount": {
"amount": "50000.00",
"currency": "CAD"
},
"outstanding_amount": {
"amount": "48000.00",
"currency": "CAD"
},
"funded_at": "2026-11-05T12:00:00Z",
"maturity_date": "2027-11-06",
"repayment_frequency": "monthly",
"terms_document_ids": []
},
"status": "paused",
"baseline_package_id": "rp_synthetic",
"latest_package_id": "rp_signal_synthetic",
"risk_policy_version_id": "rpv_synthetic",
"cadence_id": "cadence_synthetic",
"next_evaluation_at": null,
"record_version": 2,
"connection_ids": [
"con_synthetic"
],
"requirements": [],
"failure": null,
"latest_deal_snapshot_id": "ds_synthetic",
"updated_at": "2026-11-06T12:00:00Z"
},
"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": "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": "invalid_state",
"message": "Invalid state.",
"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": "precondition_failed",
"message": "Precondition failed.",
"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
}
}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
Required ETag from the monitor. Reject stale values with 412.
1Path Parameters
id
1Body
Configuration only, with If-Match. Changes apply prospectively and never rewrite packages, evidence, events or historical charges. Stopped is terminal.
Current lifecycle state. See the product lifecycle and recovery guides.
active, paused, stopped Opaque identifier, authorized within the API key workspace and environment.
1Opaque identifier, authorized within the API key workspace and environment.
1Replacement set for future evaluations. Each source must belong to the borrower and authorize continuous_monitoring. Change uses If-Match and leaves past runs untouched.
Opaque identifier in the authorized workspace and environment.
1