Audience: controls engineers writing C++ for TwinCAT 3 / Beckhoff ADS, Rockwell ControlLogix add-on instructions, Siemens Open Controller / TIA Portal blocks, or custom industrial PCs.
C++ integrations call the physical-AI cloud HTTP API directly from a small mediator process you write. This guide shows that pattern; the wire contract is the Authority API reference.
Do not make HTTP calls from your real-time task. A SIL-rated controller's hot path has no business waiting on a cloud round-trip. Run a non-RT mediator process on the same industrial PC, route requests to it over local IPC (Unix socket / shared memory / loopback TCP), and let the mediator own TLS, retries, and idempotency.
The mediator owns issuance. Downstream components that need to check a token before actuating verify its RS256 signature against the cloud-served JWKS at /.well-known/jwks.json — see Verify Decision Tokens.
Issuance for an unregistered actorIdentity returns 403 actor_not_registered. Register each robot once at commissioning. Registering actors and minting tokens both require an API key (or user) holding the admin:config:write permission; otherwise the API returns 403 forbidden.
The physical issuer returns ALLOW / ESCALATE / DENY. ALLOW and ESCALATE arrive as HTTP 200; a policy DENY arrives as HTTP 422 (policy_denied, or 423 for an audit-gap clause) with decision, clauseId, and safeDefault under error.details. Other non-200 responses (400 validation, 402 spend_cap_reached, 403 actor_not_registered / forbidden, 409 idempotency conflicts) mean no token was minted. Branch on the HTTP status, then on decision, and actuate the safe-default on anything other than ALLOW.
The mediator owns the token blob (an RS256 JWT, ~700 bytes). The PLC holds a handle so it can hand the token to a downstream verifier, which checks it against the cloud-served JWKS before motion is commanded.
Mark a predicate safetyRated: true only when it actually traverses a safety-rated channel. Misclaiming attestation is a control failure an auditor will catch — and it is the clause that gates "is this robot allowed to move at all."
Fail closed. Classification and issuance happen in the cloud. If the cloud is unreachable or returns anything other than an ALLOW, the mediator reports the safe-default to the PLC.
Budget for the round trip. Each issuance is an HTTP call. For high-rate cycles, pre-issue and cache against expiresAtMs, and send an Idempotency-Key so retries replay the original response instead of minting twice.