PLCs.ai API
Interpret PLC code from your own tools.
A stable, versioned HTTP API over the same engine that powers PLCs.ai. Send a prompt about an Allen-Bradley or Siemens project; get a cited, plain-language answer back.
What you can do
| Endpoint | Purpose |
|---|---|
POST /projects/{id}/interpret | Prompt → cited interpretation (sync JSON or SSE stream). |
POST /projects/{id}/conversations | Open a stateful troubleshooting thread. |
POST /conversations/{cid}/messages | Append a turn to a thread. |
POST /projects/{id}/analyses | Start an async analysis job. |
GET /analyses/{analysisId} | Poll an analysis job's status and results. |
POST /projects | Ingest an L5X / Siemens export. |
POST /embed-tokens | Mint a read-only token for the embeddable iframe. |
At a glance
| Base URL | https://app.plcs.ai/api/v1 |
|---|---|
| Auth | Authorization: Bearer plck_live_… (the org is resolved from the key) |
| Writes | Require an Idempotency-Key header |
| Errors | One envelope with userMessage, suggestedAction, isRetryable |
| Every response | Carries a unique request-id header |
| SDKs | Python (PyPI plcsai) & C# (NuGet) |