Errors
Handle ActLayer errors as structured governance results.
Agents should inspect success, decision, receipt_id, approval_id, risk_score, reasons, and error.code instead of flattening errors into generic text.
Error shape
error response
{
"success": false,
"capability": "http_request",
"receipt_id": "rcpt_...",
"approval_id": null,
"decision": "block",
"risk_score": 90,
"reasons": ["ssrf_blocked"],
"error": {
"code": "SRG_BLOCKED",
"message": "Action blocked by SRG governance."
}
}Common codes
NEEDS_APPROVAL
Tell the user to approve the request in the ActLayer dashboard.
SRG_BLOCKED
Do not retry through another provider to bypass governance.
INSUFFICIENT_BALANCE
Tell the user to top up the ActLayer wallet.
VALIDATION_ERROR
Fix the capability input according to its input schema.
PROVIDER_UNAVAILABLE
Provider execution failed or timed out. Retry only if the action is idempotent.
SSRF_BLOCKED
The HTTP request target is local, private, metadata, or otherwise blocked.
