> ## Documentation Index
> Fetch the complete documentation index at: https://agentrein.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# FAQ & Troubleshooting

> Common integration states and how to handle them.

<AccordionGroup>
  <Accordion title="Why is an action marked ROLLBACK_FAILED?">
    `ROLLBACK_FAILED` can occur when connector credentials were not configured before actions were executed. Run `validateConfig()` during agent startup to identify missing connector credentials before execution. See [Supported Integrations](/docs/sdk/supported-integrations#validating-credentials-before-execution) for the complete setup guidance.
  </Accordion>

  <Accordion title="What does UNVERIFIED mean?">
    `UNVERIFIED` means the outcome-verification call could not be completed. It is an infrastructure warning rather than a judgment about the agent, and it never creates an approval. Read [Core Concepts](/docs/core-concepts#6-intent-verification--drift-detection) for the other outcome states.
  </Accordion>

  <Accordion title="What happens when a reviewer rejects an action?">
    AgentRein throws `ApprovalRejectedError` when a reviewer rejects a `requiresApproval` action. The session rollback is triggered automatically before the error is thrown. See the [error reference](/docs/sdk/errors#approvalrejectederror) for handling guidance.
  </Accordion>

  <Accordion title="What happens when an approval expires?">
    Approvals that receive no response expire after 24 hours and are rejected. What happens next depends on the approval type:

    * **Before-execution approval** (action declared in `requiresApproval`): The approval is rejected, the action is marked `FAILED`, session rollback is triggered, and a failure email is sent.
    * **After-execution approval** (drift check or policy `REQUIRE_APPROVAL` on a logged action): The approval is rejected, the action stays `SUCCESS`, no rollback occurs, and no email is sent; it stays visible to the operator.
    * **Rollback approval** (`undoConfig.requireApproval`): The approval is rejected, the action stays `SUCCESS`, its undo is marked `DECLINED`, and no rollback occurs.

    Expiry never approves anything and never triggers an automatic undo for the last two cases. See [Human-in-the-Loop & Approval Gates](/docs/core-concepts#4-human-in-the-loop-hitl--approval-gates) for the distinction from SDK-managed approval timeouts.
  </Accordion>

  <Accordion title="Should I use a sandbox or production API key?">
    Use a sandbox key with the `ar_test_` prefix to test without writing to GitHub, Stripe, or Slack. Use an `ar_live_` key for production. See [Testing & Sandbox](/docs/quickstart#testing--sandbox) for the setup details.
  </Accordion>

  <Accordion title="Why did I receive a 403 response?">
    A `403` can mean the feature you called requires a higher plan than your current one. The backend returns a clear error message for insufficient-plan access. See [Plan Tiers & API Keys](/docs/quickstart#plan-tiers--api-keys) for feature availability and upgrade guidance.
  </Accordion>
</AccordionGroup>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.