# Stripe Checkout

Promo codes tracking with Stripe Checkout requires almost no setup. No website script is required, you just have to make sure that promo codes are enabled on your Stripe Checkout page. You can kick off Stripe Checkout sessions via the API or with Stripe Payment Links.

## Enable Promo Codes When Calling the Stripe API

To enable promo codes when calling the Stripe API, include the `allow_promotion_codes` parameter when [creating the checkout session](https://docs.stripe.com/api/checkout/sessions/create).

```javascript
allow_promotion_codes: true
```

## Enable Promo Codes Using Stripe Payment Links

To enable promo codes when using Stripe Payment Links, edit your Payment Link, expand Advanced options, and check Allow promotion codes.

<figure><img src="/files/IjYGgn1GG9Z9mMVUZ9hM" alt=""><figcaption></figcaption></figure>

Once promo codes are enabled, move on to [Setting a Default Coupon Code](/affiliate-promo-codes-setup/setting-a-default-coupon-code.md).


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.promotekit.com/affiliate-promo-codes-setup/stripe-checkout.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
