﻿# Plain Text Jobs

Submit raw SimulationCraft profile text directly via `POST /v1/simc/jobs` with `Content-Type: text/plain`. No JSON envelope needed.

## Example

```bash
curl -X POST "https://api.simmit.com/v1/simc/jobs?channel=nightly&multiStage=true" \
  -H "Authorization: Bearer $SIMMIT_SECRET_KEY" \
  -H "Content-Type: text/plain" \
  --data-binary @profile.simc
```

## Query Parameters

Booleans must be the literal strings `"true"` or `"false"`. The request body is the profile text (maps to `profile.text` in JSON).

```yaml
# Build
channel: 'nightly | weekly | latest' # required → build.channel
gitBranch: 'midnight' # → build.gitBranch

# Scheduling
priority: 'standard | high' # default: standard

# Runtime
multiStage: true # Multistage execution with automatic culling
maxRuntimeSeconds: 3600 # Max job runtime in seconds
maxQueueSeconds: 600 # Max time waiting in queue before timeout

# Webhooks
webhookEvents: 'job.terminal' # Comma-separated → webhook.events

# Artifacts
artifactsHtml: true # Produce HTML report → artifacts.html
artifactsJsonVersion: '2 | 3' # 2 = stable, 3 = experimental → artifacts.json.version
```

## Headers

Optional headers:

```yaml
X-Bnet-Client-Id: '...' # Battle.net client ID (must pair with secret)
X-Bnet-Client-Secret: '...' # Battle.net client secret (must pair with ID)
```

## Limitations

The following are **only available via the JSON body** (`Content-Type: application/json`):

- **`metadata`**: opaque key-value map for client-side correlation/labeling (up to 20 entries, 1 KB total).
- **`credentials`**: available via headers (see above), not query params.

---

_HTML version: https://simmit.com/docs/api/plain-text-submission · Full docs index: https://simmit.com/llms.txt_
