# Sims ## `POST /api/guilds/{guild_id}/sims` **Queue a sim** Validates and queues a gear-swap sim for a character, resolved through the character's stored Battle.net sheet (fetched fresh if stale). Runs one at a time per web pod through the wowsims/forever CLI; poll Get a sim job for its result. 400s for an unknown character, an unknown or ambiguous item (with up to 5 suggestions), an unsupported class/spec, or an item that doesn't fit its slot. 429s if `requested_by` already has 3 jobs queued or running. **Parameters** | Name | In | Type | Required | Description | |---|---|---|---|---| | `guild_id` | path | integer | yes | The Discord server ID. Only the SideQuest server works. | **Request body** Model: {ref}`SimRequest ` | Field | Type | Required | Description | |---|---|---|---| | `character` | string | yes | The character's 'Name Surname' or slug, e.g. 'legs-behindhead'. | | `swaps` | array of {ref}`SimItem ` | yes | The items to try, up to 6. | | `wearing` | array of {ref}`SimItem ` | no | Corrections to the character's stored gear, since Battle.net's copy is stale until the character next logs out. | | `spec` | string \| null | no | Override the character's spec, e.g. 'feralbear' for a druid tanking instead of cat form. | | `talents` | string \| null | no | A wowhead-style talent string; defaults to the spec preset's own talents. | | `targets` | array of integer | no | Target counts to sim, each 1-5 (default 1 and 4). | | `mobs` | array of string | no | Mob types to sim against. | | `duration` | integer | no | Fight length in seconds. | | `requested_by` | string \| null | no | The requesting Discord user's id, for rate limiting. | **Response `202` — The queued job, with its position.** Model: {ref}`SimJobSchema ` | Field | Type | Required | Description | |---|---|---|---| | `id` | string (uuid) | yes | The job's id. | | `status` | string | yes | queued, running, done, or failed. | | `position` | integer \| null | no | This job's place in the queue, counting other queued jobs ahead of it. | | `error` | string \| null | no | A plain-English failure reason, if status is failed. | | `result` | {ref}`SimResult ` \| null | no | The sim result, once status is done. | | `created_at` | string (date-time) | yes | When the job was queued. | ## `GET /api/guilds/{guild_id}/sims/{job_id}` **Get a sim job** Returns one sim job's status, queue position (while queued), and result (once done). **Parameters** | Name | In | Type | Required | Description | |---|---|---|---|---| | `guild_id` | path | integer | yes | The Discord server ID. Only the SideQuest server works. | | `job_id` | path | string (uuid) | yes | The job's id, from Queue a sim. | **Response `200` — The sim job.** Model: {ref}`SimJobSchema ` | Field | Type | Required | Description | |---|---|---|---| | `id` | string (uuid) | yes | The job's id. | | `status` | string | yes | queued, running, done, or failed. | | `position` | integer \| null | no | This job's place in the queue, counting other queued jobs ahead of it. | | `error` | string \| null | no | A plain-English failure reason, if status is failed. | | `result` | {ref}`SimResult ` \| null | no | The sim result, once status is done. | | `created_at` | string (date-time) | yes | When the job was queued. |