Documentation Index
Fetch the complete documentation index at: https://clearlayer.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
The sandbox lets you integrate and test Clearlayer without creating real investors, wallets, or policies. It is available at the same base URL as production — https://clearlayer-api-production.up.railway.app — and uses a dedicated test API key. All seed data is pre-loaded; no setup is required.
Test API key
Use the following key for all sandbox requests:
Pass it in the Authorization header:
Authorization: Bearer cl_test_key_1234567890
Do not use the test API key in a production environment. It is publicly documented and grants access to shared seed data only.
Seed data
The sandbox database is pre-seeded with three investors, three wallets, and one asset policy.
Investors
| ID | Name | Type | Country | KYC status | Accredited | Expected outcome |
|---|
inv_seed_001 | Alice Johnson | individual | US | verified | true | allow |
inv_seed_002 | Bob Smith | individual | GB | pending | false | review |
inv_seed_003 | Charlie Doe | entity | US | verified | true | deny (blocked wallet) |
Wallets
| ID | Screening status | Risk level | Linked investor |
|---|
wal_seed_001 | verified | low | inv_seed_001 |
wal_seed_002 | pending | medium | inv_seed_002 |
wal_seed_003 | blocked | high | inv_seed_003 |
Policy
| ID | Name | requires_kyc | requires_accredited | allowed_countries | wallet_must_be_verified |
|---|
pol_seed_001 | US Accredited Only Fund | true | true | ["US"] | true |
Testing each outcome
The following examples use the seed data to produce each of the three possible decision outcomes. All requests target the production base URL with the test API key.
Alice Johnson (inv_seed_001) is KYC-verified, accredited, based in the US, and has a verified low-risk wallet. She passes every check in pol_seed_001.curl -X POST https://clearlayer-api-production.up.railway.app/v1/decisions \
-H "Authorization: Bearer cl_test_key_1234567890" \
-H "Content-Type: application/json" \
-d '{
"investor_id": "inv_seed_001",
"wallet_id": "wal_seed_001",
"asset_policy_id": "pol_seed_001",
"action": "transfer"
}'
Expected response:{
"decision": "allow",
"reasons": ["policy_requirements_satisfied"],
"audit_id": "dec_...",
"policy_version": "v1",
"timestamp": "..."
}
Bob Smith (inv_seed_002) has a pending KYC status. The engine hits rule 2 and returns review before any other checks run.curl -X POST https://clearlayer-api-production.up.railway.app/v1/decisions \
-H "Authorization: Bearer cl_test_key_1234567890" \
-H "Content-Type: application/json" \
-d '{
"investor_id": "inv_seed_002",
"wallet_id": "wal_seed_002",
"asset_policy_id": "pol_seed_001",
"action": "transfer"
}'
Expected response:{
"decision": "review",
"reasons": ["kyc_not_verified"],
"audit_id": "dec_...",
"policy_version": "v1",
"timestamp": "..."
}
Charlie Doe (inv_seed_003) has a blocked wallet (wal_seed_003). The engine hits rule 1 — the first check — and returns deny immediately.curl -X POST https://clearlayer-api-production.up.railway.app/v1/decisions \
-H "Authorization: Bearer cl_test_key_1234567890" \
-H "Content-Type: application/json" \
-d '{
"investor_id": "inv_seed_003",
"wallet_id": "wal_seed_003",
"asset_policy_id": "pol_seed_001",
"action": "transfer"
}'
Expected response:{
"decision": "deny",
"reasons": ["wallet_blocked"],
"audit_id": "dec_...",
"policy_version": "v1",
"timestamp": "..."
}
The seed data only covers the most common scenarios. Create your own investors, wallets, and policies via the API to test edge cases — for example, an investor from a blocked country, a non-accredited investor against a policy that doesn’t require accreditation, or a wallet in a pending state against a policy where wallet_must_be_verified is false.