simulations (operator)
Sandbox simulations (SC-38, P-89): every asynchronous outcome on demand — incoming payments and debits, payment status, returns and recalls, inbound recalls, exchange settlement, FX rate moves, direct-debit outcomes, card events, KYC outcomes, integrator events, statements, scheduled runs and provider outages. Backed by the sandbox bank, and by the Banking Circle and Integrated Finance sandboxes where they offer a simulation.
Simulate a statement becoming available
POST /v1/simulations/statements
- simulateStatement
- Customer and operator keys
- API key scope webhooks:manage
- Tenant customer
A statement.available integrator event for the balance.
Sandbox only: 404 feature-disabled wherever the sandbox is off (always in production). Callers: a wb_test_ API key of the customer, or a member session of a developer sandbox workspace (403 for live keys and other sessions). Every simulation answers 202 SimulationResult; queued outcomes arrive through the normal pipeline (ledger, notifications, integrator webhooks) within seconds. Rules: docs/SANDBOX.md.
API key scope: webhooks:manage.
Parameters
| Name | In | Type | Description |
|---|---|---|---|
X-Tenant-Idrequired | header | Uuid | Tenant context: the operator tenant id (staff operations) or customer tenant id (customer operations). Validated against the caller's memberships; mismatch → |
X-Request-Id | header | string | Client-supplied correlation id. Generated by the server when absent; always echoed in the response and in problem details. |
Idempotency-Key | header | string | Optional idempotency key; same semantics as on money operations. |
Request body
Responses
202 Accepted
application/jsonsimulationIdUuidrequiredkindSimulationKindrequiredstatusstringrequiredqueued: a provider event was stored and handed to the workers;submitted: the partner sandbox accepted it and notifies by webhook;applied: done synchronously.providerSimulationProviderrequiredproviderEventIdsarray of Uuidrequiredproviders.eventsrows written (provider event log).providerReferencestring | nullrequireddetailsobjectrequiredPer kind (amounts, refs, rates, case id, …).
Fields of details
400 Malformed request: unparseable JSON, or an invalid header, path or query parameter (`errors[].field` is `header.X`, `path.x` or `query.x`). Body validation failures are 422 `validation-error`.
application/problem+json401 Missing, expired or invalid credentials (`unauthenticated`, `session-expired` with `reason` `idle` / `revoked` / `expired`, `invalid-api-key`, `mfa-required`).
application/problem+json403 Authenticated but not allowed: missing capability or scope, tenant not in memberships, `step-up-required`, IP not allow-listed, impersonation restriction.
application/problem+json409 State conflict: `invalid-transition`, `duplicate-recipient`, `quote-expired`, `insufficient-funds`, `idempotency-key-in-use` (with Retry-After), `not-cancellable`.
application/problem+json422 Semantically invalid request; `errors[]` lists field-level problems. Also `idempotency-key-reused` when the key was used with a different payload, `limit-exceeded`, `recipient-not-approved`.
application/problem+json429 Rate limit exceeded.
application/problem+jsondefault Unexpected error (`500 internal-error`, `501 not-implemented`, `502 provider-error`, `503 service-unavailable`, `504 provider-timeout`). Money operations that time out at the provider are never retried blindly; their state becomes `exception`/unknown and is reconciled.
application/problem+json
Code samples
curl -X POST "https://bank.wirebloom.com/v1/simulations/statements" \
-H "Authorization: Bearer $WIREBLOOM_API_KEY" \
-H "X-Tenant-Id: $WIREBLOOM_CUSTOMER_ID" \
-H "Content-Type: application/json" \
--data '{
"balanceId": "0192a6f0-7c1e-7b3a-9d2e-5f4c3b2a1908"
}'const response = await fetch("https://bank.wirebloom.com/v1/simulations/statements", {
method: "POST",
headers: {
"Authorization": `Bearer ${process.env.WIREBLOOM_API_KEY}`,
"X-Tenant-Id": process.env.WIREBLOOM_CUSTOMER_ID!,
"Content-Type": "application/json",
},
body: JSON.stringify({
"balanceId": "0192a6f0-7c1e-7b3a-9d2e-5f4c3b2a1908"
}),
});
if (!response.ok) throw new Error(`${response.status} ${await response.text()}`);
const result = await response.json();import os
import requests
response = requests.request(
"POST",
"https://bank.wirebloom.com/v1/simulations/statements",
headers={
"Authorization": f"Bearer {os.environ['WIREBLOOM_API_KEY']}",
"X-Tenant-Id": os.environ["WIREBLOOM_CUSTOMER_ID"],
"Content-Type": "application/json",
},
json={
"balanceId": "0192a6f0-7c1e-7b3a-9d2e-5f4c3b2a1908"
},
timeout=30,
)
response.raise_for_status()Send an integrator event to your endpoints
POST /v1/simulations/webhook-events
- simulateWebhookEvent
- Customer and operator keys
- API key scope webhooks:manage
- Tenant customer
Delivered to the customer's active endpoints subscribed to the type, with data.sandbox: true.
Sandbox only: 404 feature-disabled wherever the sandbox is off (always in production). Callers: a wb_test_ API key of the customer, or a member session of a developer sandbox workspace (403 for live keys and other sessions). Every simulation answers 202 SimulationResult; queued outcomes arrive through the normal pipeline (ledger, notifications, integrator webhooks) within seconds. Rules: docs/SANDBOX.md.
API key scope: webhooks:manage.
Parameters
| Name | In | Type | Description |
|---|---|---|---|
X-Tenant-Idrequired | header | Uuid | Tenant context: the operator tenant id (staff operations) or customer tenant id (customer operations). Validated against the caller's memberships; mismatch → |
X-Request-Id | header | string | Client-supplied correlation id. Generated by the server when absent; always echoed in the response and in problem details. |
Idempotency-Key | header | string | Optional idempotency key; same semantics as on money operations. |
Request body
typeIntegratorEventTyperequiredobjectIdUuidstatusstringamountMoney
Responses
202 Accepted
application/jsonsimulationIdUuidrequiredkindSimulationKindrequiredstatusstringrequiredqueued: a provider event was stored and handed to the workers;submitted: the partner sandbox accepted it and notifies by webhook;applied: done synchronously.providerSimulationProviderrequiredproviderEventIdsarray of Uuidrequiredproviders.eventsrows written (provider event log).providerReferencestring | nullrequireddetailsobjectrequiredPer kind (amounts, refs, rates, case id, …).
Fields of details
400 Malformed request: unparseable JSON, or an invalid header, path or query parameter (`errors[].field` is `header.X`, `path.x` or `query.x`). Body validation failures are 422 `validation-error`.
application/problem+json401 Missing, expired or invalid credentials (`unauthenticated`, `session-expired` with `reason` `idle` / `revoked` / `expired`, `invalid-api-key`, `mfa-required`).
application/problem+json403 Authenticated but not allowed: missing capability or scope, tenant not in memberships, `step-up-required`, IP not allow-listed, impersonation restriction.
application/problem+json409 State conflict: `invalid-transition`, `duplicate-recipient`, `quote-expired`, `insufficient-funds`, `idempotency-key-in-use` (with Retry-After), `not-cancellable`.
application/problem+json422 Semantically invalid request; `errors[]` lists field-level problems. Also `idempotency-key-reused` when the key was used with a different payload, `limit-exceeded`, `recipient-not-approved`.
application/problem+json429 Rate limit exceeded.
application/problem+jsondefault Unexpected error (`500 internal-error`, `501 not-implemented`, `502 provider-error`, `503 service-unavailable`, `504 provider-timeout`). Money operations that time out at the provider are never retried blindly; their state becomes `exception`/unknown and is reconciled.
application/problem+json
Code samples
curl -X POST "https://bank.wirebloom.com/v1/simulations/webhook-events" \
-H "Authorization: Bearer $WIREBLOOM_API_KEY" \
-H "X-Tenant-Id: $WIREBLOOM_CUSTOMER_ID" \
-H "Content-Type: application/json" \
--data '{
"type": "webhook.test"
}'const response = await fetch("https://bank.wirebloom.com/v1/simulations/webhook-events", {
method: "POST",
headers: {
"Authorization": `Bearer ${process.env.WIREBLOOM_API_KEY}`,
"X-Tenant-Id": process.env.WIREBLOOM_CUSTOMER_ID!,
"Content-Type": "application/json",
},
body: JSON.stringify({
"type": "webhook.test"
}),
});
if (!response.ok) throw new Error(`${response.status} ${await response.text()}`);
const result = await response.json();import os
import requests
response = requests.request(
"POST",
"https://bank.wirebloom.com/v1/simulations/webhook-events",
headers={
"Authorization": f"Bearer {os.environ['WIREBLOOM_API_KEY']}",
"X-Tenant-Id": os.environ["WIREBLOOM_CUSTOMER_ID"],
"Content-Type": "application/json",
},
json={
"type": "webhook.test"
},
timeout=30,
)
response.raise_for_status()