# Bring several accounts online at once

URL: https://docs.fxapis.com/api-reference/lifecycle/bring-several-accounts-online-at-once

> Bring several accounts online at once. Brings every account listed online and returns 202 with a result for each — the broker logins are still in progress.

`POST https://api.fxapis.com/v1/accounts/prepare`

Brings every account listed online and returns **202** with a result for each — the broker logins are still in progress. Built for a signal: call it when the signal goes out, and by the time people act on it their accounts are online, so the order goes straight through instead of waiting for a login.

An account already online is reported as `already_running`; one that needs a human first (`needs_operator`) is not retried. `warm_on_demand` accounts go offline again by themselves after the idle window with no orders.

Authentication: `Authorization: Bearer <API key>`.

#### Request body (application/json, required)

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `accountIds` | string (uuid)[] | yes |  |

#### Responses

- `202`
- `400`
- `401`

Failures return `{ "error": { "code", "message" } }`; every code is listed at https://docs.fxapis.com/errors.

#### 202 response fields

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `data` | object[] | no |  |
| `data[].accountId` | string (uuid) | yes |  |
| `data[].result` | "starting" \| "already_running" \| "not_found" \| "leased_elsewhere" \| "needs_operator" \| "no_secret" \| "failed" | yes | `starting`: connecting now. `already_running`: already online or connecting. `leased_elsewhere`: busy with another request; retry in a moment. `needs_operator`: needs a human first — a wrong login, 2FA or a certificate. `no_secret`: no credentials are stored; send them again. `failed`: could not be brought online; `message` says why. |
| `data[].message` | null \| string | no |  |