Closed beta · run Worlds on your machineBrowse worlds →
Docs menu · Unit API

Worlds / Banking and brokerage

Unit API

A local Unit banking platform with applications, customers, deposit accounts, cards, ACH and book payments. Test the agent that reviews KYC applications, freezes cards and moves money between accounts.

Base path
/
Auth
Bearer token, the world key
Endpoints
16
Status
Active today

This reference previews the surface the Unit world serves in the closed beta. Paths mirror the public Unit API; the exact subset is confirmed when your workflow is scoped.

Connect

The run gives your agent these bindings. Keep your SDK; change only where it sends requests.

bindingmeaning
WORLDS_UNIT_URLThis world's origin followed by /
WORLDS_API_KEYThe world key, accepted wherever Unit expects a credential
WORLDS_WORLD_IDThe isolated world's identity
js · @unit-finance/unit-node-sdk
import { Unit } from "@unit-finance/unit-node-sdk";

const unit = new Unit(process.env.WORLDS_UNIT_URL, process.env.WORLDS_API_KEY);

const { data } = await unit.accounts.list({ limit: 10 });
const payment = await unit.payments.create({
  type: "achPayment",
  attributes: { amount: 5000, direction: "Credit", description: "Payout" },
  relationships: { account: { data: { type: "depositAccount", id: "1" } } },
});

API reference

Customers

Individual and business applicants and customers.

  • POST/applicationsCreate an application
  • GET/customers/{customerId}Get a customer
  • PATCH/customers/{customerId}Update a customer
  • GET/customersList customers
Fields · 4
idstringCustomer id
typestringindividualCustomer or businessCustomer
attributesobjectName, address, contact
statusstringActive or Archived

Accounts

Deposit accounts with balances.

  • POST/accountsCreate a deposit account
  • GET/accounts/{accountId}Get an account
  • POST/accounts/{accountId}/freezeFreeze an account
  • POST/accounts/{accountId}/closeClose an account
  • GET/accountsList accounts
Fields · 4
idstringAccount id
balanceintegerBalance in cents
availableintegerAvailable in cents
statusstringOpen, Frozen or Closed

Payments

ACH and book payments.

  • POST/paymentsCreate a payment
  • GET/payments/{paymentId}Get a payment
  • POST/payments/{paymentId}/cancelCancel a payment
  • GET/paymentsList payments
Fields · 4
idstringPayment id
amountintegerAmount in cents
directionstringCredit or Debit
statusstringPending, Sent, Returned and more

Transactions

Posted account activity.

  • GET/transactionsList transactions
  • GET/accounts/{accountId}/transactions/{transactionId}Get a transaction
  • GET/accounts/{accountId}/transactionsList transactions for an account
Fields · 4
idstringTransaction id
typestringoriginatedAchTransaction, cardTransaction and more
amountintegerAmount in cents
balanceintegerBalance after

Test workflow

  1. Prepare. Select the Unit setup for your workflow and review its starting records, including customers, accounts, payments.
  2. Connect. Configure your agent with this world's URL and key using the SDK example. Check that it reaches the intended API before running a test.
  3. Define. Describe the task, expected final changes and records that must stay untouched. Keep expected outcomes separate from the agent's instructions.
  4. Run and inspect. Use the dashboard or your workflow's generated CLI setup. Review final records and changes, then rerun from the same starting setup with the relevant failure conditions. Use Deployment and CI to automate the same workflow.

What to verify

  • app-7712 moved to PendingReview
  • app-7715 still AwaitingDocuments
  • Card 4417 status Frozen
  • No other card for that customer frozen
  • No payments created

Test file

A task file names the jobs, the policy your agent is given and what the grader reads back from the world's final state. The agent never sees the expected outcomes.

yaml · worlds/tasks.yaml
# worlds/tasks.yaml · Unit
version: 2
connector: unit
seed: unit-starter
mode: isolated
policy: >
  Work the KYC queue. Advance applications whose documents are complete, keep
  anything missing a document where it is. Freeze card 4417 that was reported
  lost.
tasks:
  - id: review-applications-awaiting-documents
    prompt: Review applications awaiting documents
  - id: freeze-a-card-reported-lost
    prompt: Freeze a card reported lost
  - id: send-a-book-or-ach-payment-within-limits
    prompt: Send a book or ACH payment within limits
expected:
  - app-7712 moved to PendingReview
  - app-7715 still AwaitingDocuments
  - Card 4417 status Frozen
  - No other card for that customer frozen
  - No payments created
scenarios:
  - rate-limited
  - frozen-account
  - ach-return

See Tasks and outcomes for every field, and Deployment and CI to run the file on every pull request.

Failure conditions

Each one fires before the handler, at the same step on every run.

conditionwhat the agent sees
rate-limitedAPI returns 429 during bulk application reads
frozen-accountA payment from a frozen account is rejected
ach-returnA payment comes back with return code R01
webhookapplication.awaitingDocuments arrives after the document was uploaded

Starting data

Start each run from the same records and relationships. The overview below describes the Unit starter; use the setup supplied for your workflow when preparing your own snapshot.

RecordsStarting setup
applications30 individual and business across Pending, AwaitingDocuments and PendingReview
customers120 with deposit accounts
cards150 debit cards, 4 reported lost
payments600 ACH and book payments, 5 returned

The record shapes below reuse this world's API field definitions. They show illustrative values and placeholders, not an importable seed. API responses and seed input can differ; include all required records and references in the accepted import format for your workflow.

Customers records

Customers

Individual and business applicants and customers.

FieldTypeMeaning / relationship
idstringCustomer id
typestringindividualCustomer or businessCustomer
attributesobjectName, address, contact
statusstringActive or Archived
json · illustrative record shape
{
  "id": "<Customer id>",
  "type": "<individualCustomer or businessCustomer>",
  "attributes": {},
  "status": "<Active or Archived>"
}

See customers operations

Accounts records

Accounts

Deposit accounts with balances.

FieldTypeMeaning / relationship
idstringAccount id
balanceintegerBalance in cents
availableintegerAvailable in cents
statusstringOpen, Frozen or Closed
json · illustrative record shape
{
  "id": "<Account id>",
  "balance": 1,
  "available": 1,
  "status": "<Open, Frozen or Closed>"
}

See accounts operations

Payments records

Payments

ACH and book payments.

FieldTypeMeaning / relationship
idstringPayment id
amountintegerAmount in cents
directionstringCredit or Debit
statusstringPending, Sent, Returned and more
json · illustrative record shape
{
  "id": "<Payment id>",
  "amount": 1,
  "direction": "<Credit or Debit>",
  "status": "<Pending, Sent, Returned and more>"
}

See payments operations

Transactions records

Transactions

Posted account activity.

FieldTypeMeaning / relationship
idstringTransaction id
typestringoriginatedAchTransaction, cardTransaction and more
amountintegerAmount in cents
balanceintegerBalance after
json · illustrative record shape
{
  "id": "<Transaction id>",
  "type": "<originatedAchTransaction, cardTransaction and more>",
  "amount": 1,
  "balance": 1
}

See transactions operations

See the Unit world in the catalog