Hyperscale docs Sign in Start building

Join a sandbox Product through a join link

customer.join

Redeems a join link: creates a sandbox test customer from the first name, activates its enrollment in the link's Product, opens its customer_balance account, funds it with the link's test money, and signs it in. The session is bound to that one customer and Product, and ends no later than the link does. An unknown token is not found, an expired link is refused as expired, and a link that has admitted maxJoins people is refused as full. Each call makes a new customer; the same person joining twice is two customers. The session token is a one-time secret surfaced only in this response.

POST /v1/customer-identity/join

Principal public. Idempotency required. Environment sandbox.

Input

FieldInTypeDescription
X-Hyperscale-Environmentheadersandbox | live
Idempotency-Key requiredheaderstring
X-Hyperscale-Rehearsalheader"true"`true` runs the request through admission and execution, keeps nothing, and answers OperationRehearsal with 200 in place of the operation's own output. Needs a signed-in caller. Identity operations, such as sign-in, sessions, team members and agent grants, refuse it with invalid_request.
token requiredbodystringThe secret in a join link's URL path, after /j/. Whoever holds it can join the link's Product as a sandbox customer until the link expires or fills.
firstName requiredbodystringThe only thing a guest gives. It becomes the display name.

Request sample

curl --request POST 'https://hyperscale0.ai/v1/customer-identity/join' \
  --header "Authorization: Bearer $HYPERSCALE_API_KEY" \
  --header 'X-Hyperscale-Environment: sandbox' \
  --header "Idempotency-Key: $(uuidgen)" \
  --header 'Content-Type: application/json' \
  --data-raw '{"token":"demo_join_token_0000000000000001","firstName":"Aisha"}'

Errors

CodeHTTPCause
idempotency_conflict409The request reused an Idempotency-Key for a different logical mutation.
idempotency_required400The operation is a mutation and Hyperscale requires a replay key before executing it.
internal_error500Hyperscale hit an unexpected server-side condition and hid internal implementation details from this audience.
invalid_request400The request does not match the API reference.
not_found404No Hyperscale route matched the requested path and method.
rate_limited429The credential sent more than its limit in the current 60-second window: 600 requests per API key or session, 1,200 per IP address. Every response carries `x-ratelimit-limit`, `x-ratelimit-remaining` and `x-ratelimit-reset` (Unix seconds).
request_body_too_large413The JSON request body exceeded Hyperscale's accepted payload size.
resource_not_found404The requested resource does not exist in the credential's visible scope.
state_conflict409The operation conflicts with the current durable state of the resource.
state_constraint_failed422The request is syntactically valid but violates a business-state constraint.
tenant_not_found404The credential resolved to a tenant Hyperscale cannot find.
unauthorized403The request did not include a valid Hyperscale bearer credential for this environment.
cross_tenant_transfer_forbidden409An account on this transfer belongs to another tenant, or it has no tenant and is not a platform account. `details.accountId` names it. No intent or ledger effect was created.
currency_mismatch400The currency on the request does not match the settlement currency of the account or transfer it targets. Hyperscale never converts between currencies, so the two must be identical.
instrument_instance_not_found404No record of this instrument matches the `instanceId` in this Product, company and environment. `details.instrumentId` and `details.instrumentInstanceId` name what was looked up.
insufficient_balance409The source (debit) account's available balance is below the transfer amount, so the ledger refused the transfer. No money moved. The transfer was not created and its charge/transfer rows are recorded as failed.
join_link_expired410The join link's expiry has passed, so it admits no one new.
join_link_full409The join link has admitted as many people as its `maxJoins` allows.
join_link_not_found404No sandbox join link matches the token. Hyperscale stores only the token's SHA-256, so a lost link cannot be recovered.
ledger_transfer_rejected409The ledger refused the transfer for a reason other than insufficient balance. No money moved. `details` carries `transferId`, the debit-side `accountId`, `amount` and `currency`. The ledger's own reason stays in the server log.
ledger_unavailable503The ledger could not be reached, did not answer in time, or returned incomplete evidence for the accounts this request reads. `details.reason` is `request_timeout` when the call timed out.
operation_not_finalized409The operation in `details.operationId` has started but has no final receipt. It is still running, or its outcome is unknown after a failure past the point where it may have committed. `details.error` carries the underlying failure when there is one.
tenant_status_forbidden409The company is suspended or closed, so every credential bound to it is refused, reads included. `details.tenantId` names the company.

All operations