Skip to content
MyStocks Developers
API v1

API v1

Current stable contract

Versioning policyRelease changelog
Sandbox console

Register sandbox account

Developer Platform, Sandbox & Key Management

POST

/register

Register sandbox account

Sandbox onlyPortal sign-in requiredcreateRegister

Creates a sandbox account and returns a sandbox API key (sk_sandbox_…). Authentication: Pass your Firebase ID token as Authorization: Bearer <token>. The recommended flow is to sign in at the partner dashboard and use its explicit Create/Rotate Key action; the portal performs this authenticated request without exposing the Firebase token. The token identifies your Firebase account and links the sandbox key to your partner profile. - Your master wallet is seeded with a virtual $100,000 on first registration. - Calling this endpoint again rotates the credential and immediately invalidates the previous sandbox key. - The sandbox is fully isolated — no real money moves. To go live, complete KYB verification via the partner dashboard and request a production key.

Parameters

This endpoint has no path or query parameters.

Headers

AuthorizationstringRequired

Bearer Firebase ID token from your partner portal session.

Response fields

messagestring

Example: "Sandbox account created."

apiKeystring

Example: "sk_sandbox_a1b2c3d4e5f6"

walletBalancenumber

Example: 100000

currencystring

Example: "USD"

existingboolean

true if your account already existed and the key was retrieved rather than created.

Example: false

Response codes

201Registration successful.
401Missing or invalid Firebase ID token.
403No partner application on file. Apply at /partners/register first.