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

# Stripe

> Connect your PolyAI agent to Stripe for payment status, refunds, and coupon management.

Use the [Stripe](https://stripe.com/) integration to let your agent check payment status, process refunds, create coupons, and manage subscriptions during conversations.

<Note>This is a managed integration. Prepare the credentials below, then contact your PolyAI account manager to complete setup.</Note>

<Warning>
  Direct card collection over voice requires PCI DSS compliance. Pair Stripe with [PCI Pal](/integrations/pci-pal) to capture card details securely, then process the payment through Stripe as your gateway.
</Warning>

## Capabilities

<CardGroup cols={2}>
  <Card title="Payment status" icon="magnifying-glass-dollar">
    Look up the status of existing payments or charges.
  </Card>

  <Card title="Refunds" icon="rotate-left">
    Initiate refunds for eligible transactions.
  </Card>

  <Card title="Coupons" icon="tag">
    Generate promotional discounts on demand.
  </Card>

  <Card title="Subscriptions" icon="repeat">
    Query subscription status and details.
  </Card>
</CardGroup>

## Getting started

### Prerequisites

* A Stripe account (Test or Live mode)
* Stripe API keys with the permissions your integration needs
* PolyAI project access

### Set up

<Steps>
  <Step title="Obtain API credentials">
    1. Log in to your [Stripe Dashboard](https://dashboard.stripe.com/).
    2. Go to **Developers → API keys**.
    3. Copy the values you need:

    | Credential          | Used for                                       |
    | ------------------- | ---------------------------------------------- |
    | **Publishable key** | Client-side operations (only if needed)        |
    | **Secret key**      | Server-side API calls — required               |
    | **Webhook secret**  | Only if you set up a webhook endpoint (step 2) |

    <Warning>Use test-mode keys during development, and never expose secret keys publicly.</Warning>
  </Step>

  <Step title="Configure a webhook (optional)">
    If your integration needs real-time payment notifications:

    1. Go to **Developers → Webhooks**.
    2. Click **Add endpoint**.
    3. Enter the webhook URL provided by PolyAI.
    4. Select the events to receive, for example `payment_intent.succeeded` and `charge.refunded`.
  </Step>

  <Step title="Share credentials with PolyAI">
    Securely share with your PolyAI representative:

    * API secret key
    * Webhook secret (if using webhooks)
    * Any specific configuration requirements

    PolyAI stores these as encrypted secrets and completes the integration.
  </Step>
</Steps>

## Use cases

<AccordionGroup>
  <Accordion title="Payment confirmation" icon="check">
    **Caller:** "Did my payment go through?"

    **Agent:** Looks up recent charges by customer email or phone and confirms the payment status.
  </Accordion>

  <Accordion title="Refund requests" icon="rotate-left">
    **Caller:** "I'd like a refund for my order."

    **Agent:** Verifies the transaction and initiates the refund through Stripe.
  </Accordion>

  <Accordion title="Promotional discounts" icon="tag">
    **Caller:** "I was promised a discount."

    **Agent:** Creates a one-time coupon in Stripe and reads the code back to the caller.
  </Accordion>
</AccordionGroup>

## Limitations

* **Card collection** — Direct card number capture requires PCI compliance; use [PCI Pal](/integrations/pci-pal) for secure entry.
* **Dispute handling** — Complex dispute resolution needs human intervention.
* **Sensitive account changes** — Verify with additional authentication before modifying account details.

## Security

* API keys are stored as encrypted secrets.
* All API calls use HTTPS.
* Webhook signatures are verified to prevent spoofing.

## Support

* For integration assistance, contact your PolyAI account manager.
* For Stripe-specific questions, see the [Stripe documentation](https://stripe.com/docs).

## Related pages

<CardGroup cols={2}>
  <Card title="PCI Pal" href="/integrations/pci-pal" icon="credit-card">
    Secure payment processing for card collection.
  </Card>

  <Card title="Managed services" href="/integrations/managed-services" icon="handshake">
    Other managed integrations requiring account manager setup.
  </Card>
</CardGroup>
