# Adding Affiliates (/docs/adding-affiliates)



As a store owner, affiliates can join your program in two ways:

* They can apply from your store's customer portal
* You can send them an invite from [the Affiliates dashboard](https://sell.app/dashboard/affiliates)

Anyone can apply to join your affiliate program. They do not need to have purchased from your store before, and they do not need to create their own SellApp store. This makes it easier to recruit creators, partners, and customers who can promote your digital products.

<Note>
  Invites send an application link to the affiliate's email. The affiliate still needs to complete the join flow and submit their payout details before they can promote your store.
</Note>

***

## Application Flow [#application-flow]

The standard application flow starts with a user navigating to your store's customer portal.

There, they will find an "Affiliate Program" option in the sidebar &#x2A;(provided you've enabled the affiliate program in your store's settings)*. This page will show them a general overview of your store's affiliate program, with a button that lets them apply.

You can also open [the Affiliates dashboard](https://sell.app/dashboard/affiliates), click **Invite**, and send an application link to an affiliate's email. This is handy when you already know who you want in the program.

Once the user has applied to your affiliate program, the affiliate request will be shown [in the Affiliates dashboard](https://sell.app/dashboard/affiliates)

The status of the request will depend on whether you've enabled or disabled the "Affiliate Approval" toggle in your store's affiliate settings.

* If the toggle is enabled, all affiliate requests are automatically accepted. The status of the affiliate [in the Affiliates dashboard](https://sell.app/dashboard/affiliates) will be shown as "Active"
* If the toggle is disabled, all affiliate requests need to be manually reviewed. The status of the affiliate [in the Affiliates dashboard](https://sell.app/dashboard/affiliates) will be shown as "Pending"
  * If the status is "Pending", clicking on the relevant affiliate will open a slide-over where you can accept or reject an affiliate.
  * Once rejected, an affiliate cannot submit a fresh request for the same store, but you can enable them again from the dashboard.

Once an affiliate has been accepted, they will be shown an affiliate dashboard in the customer portal. Here, they can see their earnings, copy their affiliate link, and see recent referrals and payouts.

***

## Frequently Asked Questions [#frequently-asked-questions]

### Can I disable accepted affiliates at any time? [#can-i-disable-accepted-affiliates-at-any-time]

Yes, you can always disable affiliates with an "accepted" status [in the Affiliates dashboard](https://sell.app/dashboard/affiliates). A disabled affiliate can be re-activated via the dashboard as well.

### Can I modify the "Affiliate Approval" toggle at any time? [#can-i-modify-the-affiliate-approval-toggle-at-any-time]

Yes, all your store's affiliate program settings can be modified at any time.


# Affiliate Program Software (/docs/affiliate-program-introduction)



Create an affiliate program for your SellApp store in just a few clicks, and attract affiliates who promote your digital products in exchange for a commission.

SellApp includes affiliate program software with the pieces you need to run a serious program without duct-taping spreadsheets together:

* Flexible configuration options, including the following:
  * Auto-approving new affiliates
  * Minimum payout amount
  * Percentage-based or fixed USD commissions
  * Tracking duration
  * First-referrer or last-referrer attribution
  * Supported payout methods
  * Product-level commission overrides
* A comprehensive dashboard for affiliates to keep track of their earnings, referrals, and payouts
* Notifications for new affiliate applications, pending payouts, and more
* Automatic commission calculation when orders are completed

***

## How Affiliate Tracking Works [#how-affiliate-tracking-works]

To get started with the affiliate program, it is important to know how affiliate tracking works. Start with this general overview.

1. A store can configure an affiliate program. Once enabled, users can apply to join the affiliate program from the store's customer portal
2. When users apply to join your store's affiliate program, you will receive that request [in the Affiliates dashboard](https://sell.app/dashboard/affiliates) with a status of pending
3. Once you accept the request, the affiliate can start promoting your product(s) with their unique affiliate ID
4. Whenever an affiliate refers a customer with their affiliate code, SellApp tracks the referral for the duration you configured and attributes the purchase using your selected referrer order. You can see referred purchases [in the Referrals dashboard](https://sell.app/dashboard/affiliates/referrals)
5. Once an affiliate has referred enough customers to meet the minimum payout threshold, which is defined in your store's affiliate settings, they will be eligible for a payout
6. On the **1st and 15th of the month**, you will receive a notification to pay eligible affiliates out.
7. SellApp does not handle payouts, but we do make it very easy. [The Payouts dashboard](https://sell.app/dashboard/affiliates/payouts) lets you export pending payouts with all the prerequisite information to pay your affiliates out (in bulk)

***

## Frequently Asked Questions [#frequently-asked-questions]

### How much does it cost to use the affiliate program? [#how-much-does-it-cost-to-use-the-affiliate-program]

We do not charge any additional fees for the affiliate program. It is included in SellApp's default pricing structure.

### Does this work with crypto payments? [#does-this-work-with-crypto-payments]

Yes, the affiliate program works across all current and future payment methods present on SellApp, which includes crypto payment methods.

### Does SellApp handle paying affiliates out, or do I have to do so myself? [#does-sellapp-handle-paying-affiliates-out-or-do-i-have-to-do-so-myself]

SellApp does not handle payouts, but we do make it very easy.  [The Payouts dashboard](https://sell.app/dashboard/affiliates/payouts&#x29; lets you export pending payouts with all the prerequisite information to pay your affiliates out &#x2A;*(in bulk where applicable)**

### Does the embed modal recognize affiliate referrals? [#does-the-embed-modal-recognize-affiliate-referrals]

Yes, it works out of the box and optionally supports a hardcoded `data-sell-affiliate` variable

### Can affiliates see customer information? [#can-affiliates-see-customer-information]

No, affiliates are only shown a high-level overview of their referrals. The information displayed does not include any customer information such as emails or IP addresses


# Double-sided Incentives (/docs/double-sided-incentives)



## What is a double-sided incentive? [#what-is-a-double-sided-incentive]

A double-sided incentive benefits two sides of a transaction. In the context of your store's affiliate program, this is a coupon code that is tied to a specific affiliate.

The two incentives are as follows:

1. The affiliate has the incentive to generate referrals in exchange for earning commissions
2. The referred customer has the incentive to purchase your products at a discounted price with the affiliate-specific coupon

The affiliate-specific coupon has the added benefit of being able to attribute a referral to an affiliate in a privacy-preserving and cookie-free way. This can improve affiliate tracking when customers share codes in private groups, videos, newsletters, or other places where link clicks may be harder to preserve.

***

## Creating an affiliate-specific coupon [#creating-an-affiliate-specific-coupon]

In just a few simple steps, you can create and configure an affiliate-specific coupon. Here's how:

1. Navigate to [the Affiliates dashboard](https://sell.app/dashboard/affiliates)
2. Click on the relevant affiliate to open their slide-over
3. Navigate to the "Settings" section and click on the "Affiliate Coupon" button
4. Toggle "Create Affiliate Coupon" on, then fill in the details

Finally, click the "Save" button and you're good to go. The affiliate will be able to view this coupon and share it with potential customers.

***

## Coupon Options [#coupon-options]

You can configure the coupon to your preferences. Below you will find each coupon option and its explanation.

1. **Coupon Code**: This is the coupon code a potential customer will submit when placing a purchase.
   * Should the code leak at any point in time, you can always change it to anything else of your choosing
2. **Coupon Value**: This is the value of the coupon code that will apply to the purchase, either amount-based or percentage-based
   * An amount-based discount deducts a specific amount from the purchase price.
     * If the price is $5 and the amount entered is "1", then a discount of $1 will apply and the customer will pay $4
   * A percentage-based discount deducts a percentage from the purchase price
     * If the price is $5 and the percentage entered is "10", then a discount of $0.50 will apply and the customer will pay $4.50
3. **Limit Discount**: For percentage-based coupons, you can cap the total discount amount so a big cart does not get a bigger discount than you planned
4. **Limit Usage**: When toggled off, the coupon can be used unlimited times. When toggled on, you can specify the number of times this coupon can be used for before it's disabled
5. **Expire Coupon**: When toggled off, this coupon can be used at any time. When toggled on, you can specify a date and time after which the coupon gets disabled
6. **Apply Storewide**: When toggled on, the coupon can be applied to all products in a store. You can also set a minimum spend for storewide coupons. When toggled off, a product selector will appear so you can choose exactly which products the coupon can be applied to

***

## Frequently Asked Questions [#frequently-asked-questions]

### Will the affiliate's commission be calculated based on the full price or the discounted price? [#will-the-affiliates-commission-be-calculated-based-on-the-full-price-or-the-discounted-price]

The affiliate's commission will be calculated based on the discounted price


# For Affiliates: Program Explained (/docs/for-affiliates)



<Note>
  This page is dedicated to affiliates who are either part of an affiliate program, or are looking to join an affiliate program
</Note>

If you're looking to join a store's affiliate program, or you're already an affiliate and want to know where everything lives, this page is for you.

We will start by explaining how to apply to an affiliate program, then continue with a high-level overview of each affiliate dashboard's purpose.

***

## Joining an affiliate program [#joining-an-affiliate-program]

To join an affiliate program, navigate to the store's respective customer portal. The customer portal can be found by appending /customer-portal to a store's URL

* If the store URL is bob.sell.app, then the customer portal can be found at bob.sell.app/customer-portal
* If the store URL is example.com, then the customer portal can be found at example.com/customer-portal

Once you've logged into the customer portal, you will be met with a list of your orders placed on the store. To the left of the page you will find a sidebar containing a number of options.

* If the store does not have an affiliate program present, then you will not see a dropdown called "Affiliate Program"
* If the store does have an affiliate program present, then you will see a dropdown called "Affiliate Program". Clicking any option in that dropdown will redirect you to the join page, which looks like bob.sell.app/customer-portal/affiliates/join

In the second case, where a store does have an affiliate program, you will see an overview of this affiliate program's benefits. If this is your first time applying to an affiliate program, you will see a "Become an Affiliate" button.

If the store invited you directly, the same page will show a "Complete Application" button instead.

***

For first-time affiliates who are not affiliates at other stores, clicking the "Become an Affiliate" button opens a join form where you create your affiliate profile. Note the following:

* This information cannot be changed further down the line
* The submitted information will be visible to all stores you apply to
* Your identifier becomes your affiliate code and is used to track referrals

The form also asks for your payout method, payout details, and a short message explaining why you want to join the store's affiliate program. The payout methods shown depend on what the store has enabled.

***

Once you've clicked "Save", either the store needs to review your request, or they will auto-approve your request. This depends on the store's affiliate program settings.

***

## Affiliate Dashboard Explained [#affiliate-dashboard-explained]

Once you've been accepted to the affiliate program, the customer portal should show a number of options in the "Affiliate Program". The first of which is the "Overview"

This overview is a dashboard with a high-level overview of your affiliate activity and information

1. Paid earnings, unpaid earnings, and total referral count
2. Your unique affiliate link, and optionally your unique affiliate coupon code &#x2A;(if set)*
3. Your most recent referrals generated for the store
4. Your most recent payouts

***

## Products Dashboard Explained [#products-dashboard-explained]

The second dropdown option is the "Products" dashboard

This dashboard also displays your affiliate link, as shown in the dashboard overview.

In addition, the dashboard displays a list of products with a breakdown of their price and commission rate. This can come in handy to see which products are eligible for a commission, and what the commission rates are.

A store can assign custom commission rates per product, on an affiliate-by-affiliate basis. If this is the case for you, this dashboard will display those custom rates.

***

## Referrals Dashboard Explained [#referrals-dashboard-explained]

The third dropdown option is the "Referrals" dashboard

This dashboard displays a list of all referrals generated by you, each displaying the date, status, and commission earned.

Clicking on a specific referral will open a slide-over that displays a breakdown of how the commission has been calculated, alongside a timeline of the referral's statuses.

***

## Payouts Dashboard Explained [#payouts-dashboard-explained]

The fourth dropdown option is the "Payouts" dashboard

This dashboard displays a list of all payouts associated with your affiliate profile, each displaying the date, status, and payout amount.

Clicking on a specific payout will open a slide-over that displays a breakdown of how the payout has been calculated, alongside a list of associated referrals and a timeline of the payout's statuses.

***

## Affiliate Settings Explained [#affiliate-settings-explained]

The fifth and final dropdown option is the "Settings" overview

This overview helps you modify your payout details, should you need to do so at any time. When updating your payout details, subsequent payouts will be sent to the new payout details.

Additionally, you will be shown your unique affiliate coupon code &#x2A;(if set)* and a description of this coupon's properties.

The coupon can be used to further incentivize potential customers to make a purchase, resulting in you earning more referrals.

***

## Frequently Asked Questions [#frequently-asked-questions]

### How much does it cost to apply to an affiliate program? [#how-much-does-it-cost-to-apply-to-an-affiliate-program]

No fees are charged for affiliates applying to an affiliate program. Additionally, you should also not be charged any fees for payouts or the like, except for potentially applicable payment processor fees.

### Can I join multiple affiliate programs? [#can-i-join-multiple-affiliate-programs]

Yes, you can join as many affiliate programs as you like.

### How do I refer customers? [#how-do-i-refer-customers]

Copy your unique affiliate link and send it over to the potential customer. Ensure that you do not remove the `?affiliate=[affiliateIdentifier]` value from the URL, as this is what is used to attribute a purchase to you.

You can also copy unique product URLs in the Products dashboard.

### Can I get paid out in... [#can-i-get-paid-out-in]

This depends entirely on the store's payout settings. Where certain stores can only pay out in some payment methods, other stores can pay out in other payment methods.

### How long does it take before I get paid out for referrals generated? [#how-long-does-it-take-before-i-get-paid-out-for-referrals-generated]

This depends on a number of factors. The first factor is what payment method the customer has paid with.

* **For fiat payment methods**, such as PayPal or Stripe, the eligible for payout date is **30 days** after a purchase has been made.
  * This measure is in place to prevent affiliate fraud and factor in potential charge-backs.
* **For crypto payment methods**, such as Bitcoin, the eligible for payout date is **immediately** once the purchase has been made.
  * This is because crypto payments are irreversible and are thus not prone to fraud

On the first and fifteenth of every month, eligible referrals are calculated and a payout is generated.

The store is then notified that the payouts are ready to be paid, after which the store manually sends the funds to your payout details.

<Warn>
  If your commission amount is less than the "Minimum Payout" amount specified by the store, then your payout will not be generated until you have exceeded the threshold.
</Warn>


# Set Up an Affiliate Program (/docs/getting-started-affiliate-program)





There are only two steps involved in launching an affiliate program for your SellApp store. After setup, affiliates can apply, share referral links, and earn commissions when tracked orders are completed.

The first step is to navigate to [your store's affiliates settings](https://sell.app/dashboard/settings?settings=affiliates). This will display a list of configurable options for your store.

<img src="`${docsBasePath}/images/affiliate-settings.webp`" alt="SellApp store affiliate settings" className="rounded-xl w-full shadow-lg" />

The second step is to fill each of these options in with the values of your choosing, and then save the changes. Once you've done that, you're good to go.

***

## Affiliate Program Settings [#affiliate-program-settings]

The below is an overview of each of the affiliate settings and their respective purpose.

1. **Affiliate Program toggle**: Enable or disable your store's affiliate program
2. **Affiliate Approval toggle**: Automatically or manually approve new affiliate requests
3. **Referral Commission Input**: Specify how much commission an affiliate can earn for each referral.
   * You can set either an amount-based value in USD, or a percentage-based value.
4. **Minimum Payout Balance input**: Specify how much an affiliate needs to earn in commissions before being eligible for a payout
5. **Tracking Duration input**: Specify for how long the affiliate can earn a commission on a customer's purchase.
   * For example, if this is set to 1 day, the affiliate only has 1 day for the visitor to make a purchase in order for them to be eligible for a commission.
     * If they referred a customer 2 days ago, then the affiliate would not be eligible for a commission any longer
     * If this is set to 10 days, the affiliate has 10 days for the visitor to make a purchase in order for them to be eligible for a commission
6. **Referrer Order dropdown**: Specify which referrer should be credited with a sale, in the case where a customer clicks on two referral links
   * The first referrer option credits is the affiliate who was first in referring the customer to your product
   * The last referrer option credits is the affiliate who most recently referred the customer to your product
7. **Payout Methods checkbox**: Select the payment methods you are able to pay affiliates out with
8. **Custom Products toggle**: Override the default referral commission from point 3, then choose exactly which products affiliates can promote and what commission each product pays

***

## Frequently Asked Questions [#frequently-asked-questions]

### Can I specify a custom commission rate on an affiliate-by-affiliate basis? [#can-i-specify-a-custom-commission-rate-on-an-affiliate-by-affiliate-basis]

Yes, once you approve an affiliate you can do so in the respective affiliate's slide-over.

### Do I have to configure any code on the storefront? [#do-i-have-to-configure-any-code-on-the-storefront]

No, everything is configured and ready to go out of the box. No code changes are required, unless you want to hard-code the `data-sell-affiliate` variable in your embed modal.


# Handling Payouts (/docs/handling-payouts)



Affiliate payouts can be viewed at any time [in the Payouts dashboard](https://sell.app/dashboard/affiliates/payouts). SellApp calculates eligible commissions and gives you the export data needed to pay affiliates through your chosen payout methods.

***

## Payouts Dashboard [#payouts-dashboard]

[The Payouts dashboard](https://sell.app/dashboard/affiliates/payouts) displays all affiliate payouts. Since all payouts are displayed regardless of their status or payout method, we have added two filters that help narrow things down.

The first filter helps display payouts with a specific status. The status of each payout is either "Due" or "Paid".

The second filter helps display payouts that are to be paid in a specific payment method. This filter can be used in conjunction with the export functionality in order to generate valid CSV exports for bulk payouts.

For example, if you need to filter the payouts table for payouts that are due, and affiliates expecting to receive their payout sent to their PayPal account, you would do the following:

1. Set the &#x2A;*"Status"*&#x2A; dropdown to &#x2A;*"Due"**
2. Set the &#x2A;*"Payout method"*&#x2A; to &#x2A;*"PayPal"**

The resulting table will exclusively display payouts that are due and to be paid out with PayPal. Subsequently, you can export these payouts by clicking the checkbox at the top left -> "Select All" -> "Export"

SellApp will start the export in the background and notify you when the payout data is ready to download. The CSV is formatted in such a way that you can import it to your PayPal account and pay all of these affiliates at one time.

Once you have paid the affiliates via the respective payment method, &#x2A;*please make sure to navigate back to the Payouts dashboard and mark the respective payouts as "paid"**.

***

## Payout Slide-over [#payout-slide-over]

The payout slide-over provides a breakdown of the payout created. The first section displays a breakdown of how the affiliate's payout is calculated.

The second section displays a table of referrals associated with this payout. Each individual referral can be viewed as well via the respective quick-action button.

The third and final section displays a timeline of the payout, including when it was created, and paid.

The slide-over also displays a number of quick actions: updating a payout's status, and displaying the associated affiliate.

***

## Frequently Asked Questions [#frequently-asked-questions]

### How do I use PayPal Mass Pay? [#how-do-i-use-paypal-mass-pay]

To pay your affiliates with PayPal Mass Pay, you need to own a verified PayPal business account. If this is the case, proceed with applying for PayPal Mass Pay:

1. Sign in to your PayPal account and click the "Pay & Get Paid" button at the top of the page
2. Click ["Payouts"](https://www.paypal.com/payoutsweb/batchFileUpload?entry=nav) that is shown under "Make Payments"
3. Fill in the form by answering the four questions asked
4. Finally, click the "Submit" button

Once done, you will need to wait for up to 3 days for PayPal to review and accept your request

### When are payouts generated? [#when-are-payouts-generated]

Payouts are generated on the first and fifteenth of every month.

### When are referrals eligible for a payout? [#when-are-referrals-eligible-for-a-payout]

Referrals become eligible for a payout once their status is "Accepted" and their eligible for payout date has been met. The eligible for payout date depends on the payment method the customer has paid with:

* **For fiat payment methods**, such as PayPal or Stripe, the eligible for payout date is **30 days** after the purchase has been made.
  * This measure is in place to prevent affiliate fraud and factor in potential charge-backs.
* **For crypto payment methods**, such as Bitcoin, the eligible for payout date is **immediately** once the purchase has been made.
  * This is because crypto payments are irreversible and are thus not prone to fraud


# Managing Affiliates (/docs/managing-affiliates)



Affiliates can be managed at any time [in the Affiliates dashboard](https://sell.app/dashboard/affiliates). Use this dashboard as the control center for affiliate management, custom rates, affiliate coupons, referral activity, and payout history.

***

## Affiliates Dashboard [#affiliates-dashboard]

[The Affiliates dashboard](https://sell.app/dashboard/affiliates) provides a general overview of all affiliates present in your store's affiliate program.

The dashboard also helps you perform the following quick actions:

1. Inviting affiliates by email
2. Accepting or rejecting pending affiliate requests
3. Disabling and/or re-enabling affiliates
4. Opening a specific affiliate's slide-over

***

## Affiliate Slide-over [#affiliate-slide-over]

The affiliate slide-over provides a more in-depth overview of an affiliate, which is split up into a number of tabs.

1. The first tab displays an overview of the affiliate's information. Of note is the "Settings" section, which consists of two buttons:
   * Affiliate Coupon: Create an affiliate-specific coupon which the affiliate can use for the following
     * To further incentivize potential customers to purchase your product(s)
     * It's another, privacy-preserving, way of associating an affiliate with a purchase
   * Custom Rates: Affiliate-specific rates and eligible products which this affiliate can promote
2. The second tab displays a table of recent referrals generated by this affiliate
3. The third tab displays a table of recent payouts associated with this affiliate
4. The fourth and fifth tab display the affiliate's total earnings, and the amount of earnings which have not been paid yet.

***

## Frequently Asked Questions [#frequently-asked-questions]

### Can I disable accepted affiliates at any time? [#can-i-disable-accepted-affiliates-at-any-time]

Yes, you can always disable affiliates with an "Active" status [in the Affiliates dashboard](https://sell.app/dashboard/affiliates). A disabled affiliate can be re-activated via the dashboard as well.

### Can I modify the "Affiliate Approval" toggle at any time? [#can-i-modify-the-affiliate-approval-toggle-at-any-time]

Yes, all your store's affiliate program settings can be modified at any time.


# Managing Referrals (/docs/managing-referrals)



Affiliate referrals can be managed at any time [in the Referrals dashboard](https://sell.app/dashboard/affiliates/referrals). This is where referral tracking, commission review, and referral status decisions live.

***

## Referrals Dashboard [#referrals-dashboard]

[The Referrals dashboard](https://sell.app/dashboard/affiliates/referrals) provides a general overview of all referrals generated by affiliates.

The dashboard also helps you perform the following quick actions:

1. Accept, review, or reject a referral when the current status allows it
2. Opening a specific referral's slide-over

***

## Referral Slide-over [#referral-slide-over]

The referral slide-over provides a breakdown of the referral created. The first part displays how the affiliate's commission is calculated.

The second part displays a timeline of the referral, including when it was created, reviewed, and accepted.

The slide-over also displays a number of quick actions: updating a referral's status, displaying the associated invoice or affiliate, and opening the associated payout when one exists.

***

## Frequently Asked Questions [#frequently-asked-questions]

### Can I update a previously rejected referral to an accepted status? [#can-i-update-a-previously-rejected-referral-to-an-accepted-status]

No, once you reject a referral, it is no longer possible to update its status to accepted at a later stage. As such, we only advise rejecting a referral if and when you are certain that you don't want to update the status at a later date.

Should you wish to keep the optionality, we advise changing the status to "In Review" instead.


# Sell Community Access (/docs/community-introduction)



Community lets you sell paid access to the places your customers already use: Discord servers, Telegram groups or channels, Slack channels, and WhatsApp groups. It works for memberships, subscriptions, private communities, paid support rooms, and buyer-only access spaces.

The flow is always the same:

1. Connect the platform from [Community settings](https://sell.app/dashboard/settings?settings=community).
2. Add the server, group, or channel you want SellApp to manage.
3. Open a product, expand **Community**, and choose which access should be granted after purchase.
4. Decide whether linking is required at checkout and whether access should be removed when a subscription expires.

SellApp tracks the grant on the order, shows pending actions when a platform needs the customer to join, and gives you a Health view for setup issues like missing bot access or Discord role hierarchy problems.

***

## Platform differences [#platform-differences]

Discord can grant one or more roles inside a connected server, which makes it a strong fit for a paid Discord server or role-based membership. The customer connects their Discord account during checkout when the product requires it.

Telegram adds customers to a connected group or channel. Setup uses a verification code flow, so you do not need to create your own Telegram app.

Slack grants access to channels in a connected workspace. Customers are invited through your workspace invite link, then SellApp handles the channel access.

WhatsApp grants access to groups. The customer confirms their phone number, then joins the group so SellApp can approve the request.

***

## Before you attach access to products [#before-you-attach-access-to-products]

Make sure the platform is connected and healthy first. If SellApp cannot see a Discord role, cannot access a Slack channel, or cannot verify a WhatsApp group, that issue will carry into checkout.

For subscription products, keep the expiry setting switched on when access should only last for the paid period. SellApp will revoke community access when the subscription expires or is cancelled, so access stays tied to the customer's paid status.


# Paid Discord Server Roles (/docs/discord-roling)





Use Discord roles when a product should unlock a paid Discord server, private buyer role, VIP room, or any other server access after checkout. SellApp can use the official SellApp bot, or your own custom bot if you want the Discord invite and role grant to come from your brand.

***

## Video Guide [#video-guide]

We've created a step-by-step video guide that will help you set up and configure your Discord bot correctly. If you prefer a text-based guide, please proceed to scroll down.

<video className="rounded-xl w-full">
  <source src="`${docsBasePath}/images/discord.mp4`" type="video/mp4" />

  Your browser does not support the video tag.
</video>

***

## Connect Discord [#connect-discord]

Start in [your SellApp community settings](https://sell.app/dashboard/settings?settings=community), then open **Discord**.

1. Click **Add** under **Connected Accounts** and connect your Discord account.
2. Click **Add** under **Connected Servers** and choose the server you want customers to join.
3. Invite the bot if SellApp shows the server as pending.
4. Click **Sync Roles** after adding or changing roles in Discord.

<Note>
  Make sure the bot's role is above the role(s) you are trying to grant. If it is too low in your Discord server's role list, the bot will not be able to assign those roles after a successful purchase.
</Note>

SellApp checks Discord health automatically. If it detects a role hierarchy issue, the Discord settings page shows which products may be affected and lets you re-check after you fix the role order.

***

## Using a custom bot [#using-a-custom-bot]

The official bot is enough for most stores. If you want to use your own bot, click **Custom Bot** in the Discord settings panel and create a Discord bot [in the Discord Developer Portal](https://discord.com/developers/applications).

1. Click "New Application" at the top right hand side.
2. Once your bot is created, retrieve your client ID and secret from the OAuth2 page, then add the following redirect URLs:
   * [https://sell.app/discord/connect-account](https://sell.app/discord/connect-account)
   * [https://sell.app/discord/connect-customer](https://sell.app/discord/connect-customer)
   * [https://sell.app/discord/connect-guild](https://sell.app/discord/connect-guild)
3. Retrieve your bot token from the Bot page.
4. Paste the client ID, client secret, and bot token into SellApp, then save.
5. When adding your first server, choose **Custom Bot**. Existing stores can switch all connected servers between official and custom mode from the Discord server menu.

***

## Add Paid Discord Access to a Product [#add-paid-discord-access-to-a-product]

Once your account and server are connected, open a product and expand **Community**. Select the Discord server, add one or more roles, then choose whether Discord authorization is required at checkout.

You can also decide whether SellApp should kick the customer from the server when a subscription expires. Keep this enabled when Discord access is part of the paid subscription, membership, or recurring community product.

You will also be able to update your products in bulk. Select products in [your products dashboard](https://sell.app/dashboard/listings), open **Bulk update**, then choose **Discord invite**.

Happy selling!


# Paid Slack Channel Access (/docs/slack-access)



Use Slack access when your product should unlock a paid private channel inside a Slack workspace. SellApp connects to your workspace, reads the channels the app can access, and grants customers access after checkout.

***

## Connect Slack [#connect-slack]

Start in [your SellApp community settings](https://sell.app/dashboard/settings?settings=community), then open **Slack**.

1. Click **Connect workspace** and approve the SellApp Slack app.
2. Add your workspace invite link. Customers use this link to join the workspace before channel access can be completed.
3. Make sure the SellApp app is a member of each channel you want to sell.
4. Click **Add channel**, choose the channel, then save it.

Use **Check Health** on a channel after changing Slack permissions. If SellApp says the bot is not a member, invite the app to that channel and check again.

<Note>
  Slack needs a valid workspace invite link before you can add paid channels. Without it, customers may be eligible for the channel but unable to join the workspace.
</Note>

***

## Add Slack to a product [#add-slack-to-a-product]

Open a product, expand **Community**, then choose the Slack channel.

Slack channel access is handled as a post-purchase grant. Keep **Remove from channel on subscription expiry** enabled when the channel should only stay available while the subscription or membership is active.

***

## What customers see [#what-customers-see]

Customers use your Slack workspace invite to join the workspace. After the order is completed, SellApp grants the configured channel access and shows pending access on the order if the customer still needs to complete the join step.

If a grant looks stuck, open the order and check the **Community Access** panel. It will show whether Slack is processing, waiting on the customer, or needs manual attention.


# Paid Telegram Group Access (/docs/telegram-access)



Use Telegram access when a product should unlock a paid Telegram group, supergroup, or channel. SellApp uses the official Telegram bot and a verification code flow, so there is no custom bot setup to maintain.

***

## Connect Telegram [#connect-telegram]

Start in [your SellApp community settings](https://sell.app/dashboard/settings?settings=community), then open **Telegram**.

1. Click **Connect group/channel**.
2. SellApp will generate a verification code.
3. Add the SellApp Telegram bot to the group or channel you want to sell access to.
4. Post the verification code in that group or channel.
5. Return to SellApp and wait for the group or channel to appear.

After it is connected, use **Check Health** if you want to confirm the bot can still manage that group or channel. SellApp also checks stale connections automatically.

<Note>
  The bot needs enough permission to manage membership. If a health check fails, make the bot an admin in Telegram, then run the check again.
</Note>

***

## Add Telegram to a product [#add-telegram-to-a-product]

Open a product, expand **Community**, and choose the Telegram group or channel. Then decide whether the customer must link Telegram during checkout.

If linking is required, checkout will stop until the customer connects Telegram. If it is optional, SellApp can still show the access step without blocking the order.

For subscription products, keep **Kick from group on subscription expiry** enabled when the customer should lose paid community access after cancellation or failed renewal.

***

## What customers see [#what-customers-see]

During checkout, customers are asked to connect Telegram when the product requires it. Once the order completes, SellApp creates the community grant and tracks the result on the order.

If something needs attention later, check the order's **Community Access** panel and the Community Health page.


# Paid WhatsApp Group Access (/docs/whatsapp-access)



Use WhatsApp access when a product should unlock a paid private WhatsApp group. Customers confirm their phone number during checkout, then SellApp approves the join request once the order is paid.

***

## Connect WhatsApp [#connect-whatsapp]

Start in [your SellApp community settings](https://sell.app/dashboard/settings?settings=community), then open **WhatsApp**.

1. Click **Add group**.
2. Scan the QR code shown by SellApp.
3. Wait for SellApp to load the groups available in that WhatsApp session.
4. Select the group you want to sell access to.
5. Add the SellApp bot phone numbers as group admins.
6. Enable **Approve new members** in the WhatsApp group.

After the group is added, SellApp checks whether the bot is an admin and whether approval mode is enabled. Fix any warnings before attaching the group to a product.

<Note>
  WhatsApp access depends on approval requests. If **Approve new members** is off, SellApp cannot safely approve paid customers into the group.
</Note>

***

## Add WhatsApp to a product [#add-whatsapp-to-a-product]

Open a product, expand **Community**, and choose the WhatsApp group. Then decide whether the customer must confirm WhatsApp during checkout.

For subscription products, keep **Kick from group on subscription expiry** enabled when paid group access should end with the subscription.

***

## What customers see [#what-customers-see]

During checkout, customers enter their WhatsApp phone number when the product requires it. After purchase, they join the group with that same phone number.

SellApp tracks the grant while the customer is waiting to join, then marks it granted after the join request is approved. If the customer uses a different phone number, the order can stay in a pending state until it is fixed.

Use the order's **Community Access** panel to see whether WhatsApp is processing, awaiting the customer, granted, or needs manual action.


# Store Notifications (/docs/creating-notifications)





You may want to receive a notification when a specific event happens on your SellApp store, such as when an order gets completed, a support ticket is created, or another store event needs attention.

<img src="`${docsBasePath}/images/notifications.webp`" alt="Sample Discord notification" className="rounded-xl w-full max-w-xl shadow-lg" />

<Note>
  Currently, you can create Discord notifications and email notifications. More notification channels will be added in the future.
</Note>

***

## Setting up Discord channel notifications [#setting-up-discord-channel-notifications]

1. **Get yourself a webhook URL from your Discord server**
   1. Right click the Discord channel where you'd like to receive notifications and click "Edit Channel"
   2. Navigate to "Integrations" and click "Create Webhook"
   3. Click "Copy Webhook URL" and save this somewhere, you're going to paste this in step 2.2

2. **Add Discord webhook URL to SellApp**
   1. Navigate [to your SellApp storefront notifications](https://sell.app/dashboard/settings?settings=notifications) and click "Add Channel"
   2. Select "Discord" as the channel type, add a reference you can remember for the channel name, and paste the webhook URL you got from step 1.1. in the "Webhook Url" input field.
   3. Select the notifications you'd like to receive on your channel. For example, if you only want to receive completed order notifications, select "Order Completed" here. Finally, click "Save" to complete the setup.

There you go. Now, specified notifications are sent near-instantly to the Discord channel you entered.

You can also click **Send Test Notification** while configuring a Discord channel to make sure the webhook is working before you rely on it.

***

## Setting up email notifications [#setting-up-email-notifications]

1. Navigate [to your SellApp storefront notifications](https://sell.app/dashboard/settings?settings=notifications) and click "Add Channel"
2. Select "Email" as the channel type and enter the email address in the "Email" input field.
3. Select the notifications you'd like to receive to your email. For example, if you only want to receive completed order notifications, select "Order Completed" here. Finally, click "Save" to complete the setup.

There you go. Now, specified notifications are sent near-instantly to the email address you entered.


# Sell Subscriptions Online (/docs/creating-subscriptions)





With SellApp, you can sell subscriptions online by creating products with recurring prices. Customers are charged at a predefined period of time, for example: **daily**, **weekly**, **monthly**, or **yearly**.

This pricing type is ideal for digital products that require continuous maintenance and effort, with good examples being SaaS software, paid communities, memberships, and resources that are updated regularly.

Let's dive into how you can create a product with a recurring subscription.

<Note>
  Currently, subscription products require a payment method that supports subscriptions, such as [Stripe](/stripe) or [PayPal](/paypal).
</Note>

***

## Create a Subscription Product [#create-a-subscription-product]

* Start by creating or editing a product [in the product dashboard](https://sell.app/dashboard/listings).
* In the "Pricing" section, select "Subscription" as the pricing type.
  * Once you've enabled the subscription pricing type, you can proceed to set your price and duration for the subscription.
  * Here's a preview of what that looks like:
  <img src="`${docsBasePath}/images/subscriptions.webp`" alt="Creating a subscription" className="rounded-xl w-full shadow-lg" />
  * Specify any kind of subscription duration you'd like. Charge customers every X days, weeks, months, or years. The highest duration supported is currently 365 days, 52 weeks, 12 months, or 1 year, so you cannot set the duration to be more than a year.
* Once saved, customers can purchase this newly created subscription product.
  * We'll handle setting up the subscription and notifying the customer if a payment happens to fail.
  * You'll be able to see how many subscriptions are active and how many payments have been made in your [SellApp subscription dashboard](https://sell.app/dashboard/subscriptions)


# Payment Method Discounts (/docs/discounting-payment-methods)



Offering a discount or adding a fee to a specific payment method is as easy as modifying the payment method in question. Use this when you want to encourage a lower-cost checkout option or pass through a fee for a specific processor.

**Here's how to do so:**

1. Go to your [store's payment settings](https://sell.app/dashboard/settings?settings=payment)
2. For the payment method in question, click its name so its respective modal appears.
3. In the **Discount/Fee** section, enter a percentage, a fixed amount, or both.
   * To add a discount, enter positive values. For example, for a 10% discount, enter `10` in the percentage field.
   * To add a fee, enter negative values. For example, for a 5% fee, enter `-5` in the percentage field.
   * If you use both percentage and fixed amount, they must both be discounts or both be fees.
4. Save the payment method.

That's all done. The payment method in question will now have a fee or discount applied, which will be visible to the end-user during the checkout process.


# Embed Digital Products (/docs/embedding-products)





SellApp's embed modal lets customers buy products from your own website without being redirected to a SellApp product page. It works on any website or codebase and will not affect your site's design.

<img src="`${docsBasePath}/images/embed.webp`" alt="Toggle Embed" className="rounded-xl w-full max-w-xl shadow-lg" />

Use it when you want to sell from your own landing page, blog, community site, or custom storefront while still letting SellApp handle checkout.

***

## Add the embed [#add-the-embed]

The easiest way to get the embed code is from your products dashboard:

1. Open [your products dashboard](https://sell.app/dashboard/listings).
2. Select the product or products you want to embed.
3. Choose **Embed Code** from the action bar.
4. Paste the generated button where customers should click.
5. Add the embed script once on the page.

```html
<script src="https://cdn.sell.app/embed/script.js" type="module"></script>
```

You only need to load the script once per page, even when the page has multiple product buttons.

<Note>
  If your generated snippet includes an extra stylesheet line, keep it with the snippet. The dashboard always gives you the safest version for your store.
</Note>

***

## Product buttons [#product-buttons]

A product button needs your store ID and product ID. When a customer clicks it, the checkout opens on your website.

```html
<button
  data-sell-store="123"
  data-sell-product="456"
>
  Buy now
</button>
```

Use one button per product or offer. You can also add optional details, such as a starting quantity, coupon, theme color, or customer email.

***

## Cart buttons [#cart-buttons]

You can also add a cart button for customers who want to review what they have added before paying.

```html
<button
  data-sell-cart
  data-sell-store="123"
>
  View cart
</button>
```

The cart stays available for returning visitors for a short period, so customers can come back and continue checkout.

If you want a product button to use single-product checkout only, add `data-sell-disable-cart="true"`. This hides cart actions in the modal and ignores any saved cart for that button.

```html
<button
  data-sell-store="123"
  data-sell-product="456"
  data-sell-disable-cart="true"
>
  Buy now
</button>
```

If your developer wants to open the cart from another part of your site, they can use:

```js
window.openCheckoutCart('123', {
  darkMode: true,
  theme: '#f97316',
  language: 'en',
})
```

***

## Button options [#button-options]

You can customize a button by adding extra `data-sell-*` attributes. These are optional unless marked as required.

| Attribute                  | Description                                                                                                               |
| -------------------------- | ------------------------------------------------------------------------------------------------------------------------- |
| `data-sell-store`          | Required store ID.                                                                                                        |
| `data-sell-product`        | Required product ID for product buttons.                                                                                  |
| `data-sell-variant`        | Opens a specific variant immediately.                                                                                     |
| `data-sell-quantity`       | Sets the starting quantity. Use a number, such as `3`.                                                                    |
| `data-sell-coupon`         | Applies a coupon code when the modal opens.                                                                               |
| `data-sell-email`          | Prefills the customer's email address.                                                                                    |
| `data-sell-extra`          | Sets a starting extra amount for pay-what-you-want products.                                                              |
| `data-sell-payment_method` | Starts checkout with a preferred payment method selected.                                                                 |
| `data-sell-affiliate`      | Attributes the order to an affiliate identifier. If omitted, `affiliate` or `aff` from the page URL is used when present. |
| `data-sell-disable-cart`   | Use `true` to disable cart functionality for this product button.                                                         |
| `data-sell-hide-stock`     | Use `true` to hide stock and availability counts in the modal.                                                            |
| `data-sell-darkmode`       | Use `true` to open the modal in dark mode.                                                                                |
| `data-sell-theme`          | Sets the checkout accent color, such as `#f97316`.                                                                        |
| `data-sell-language`       | Opens checkout in a chosen language.                                                                                      |

For language, you can use values like `en`, `de`, `fr`, `nl`, `es`, or `pt-BR`.

For payment methods, use the value shown in SellApp for the payment option you want to preselect.

***

## Checkout info prefills [#checkout-info-prefills]

If your product asks customers for extra checkout information, you can prefill those fields too. Use the field key from the checkout information field in SellApp.

The key is not the field label customers see at checkout. For example, a field labeled "In-game username" may have a key like `4124bc0a9335c27f086f24ba207a4912`. Copy the key from SellApp and place it after `data-sell-checkout-`.

```html
<button
  data-sell-store="123"
  data-sell-product="456"
  data-sell-checkout-4124bc0a9335c27f086f24ba207a4912="JohnDoe123"
>
  Buy now
</button>
```

This is useful when the customer is already logged in on your site and you already know details such as their username, license name, or another field your product asks for.

***

## Full button example [#full-button-example]

This example opens a specific variant, applies an orange accent color, adds a coupon, sets quantity, prefills email, and fills a checkout field.

```html
<button
  data-sell-store="123"
  data-sell-product="456"
  data-sell-variant="789"
  data-sell-darkmode="true"
  data-sell-theme="#f97316"
  data-sell-language="en"
  data-sell-coupon="LOYAL10"
  data-sell-quantity="10"
  data-sell-hide-stock="true"
  data-sell-email="johndoe@example.com"
  data-sell-checkout-4124bc0a9335c27f086f24ba207a4912="JohnDoe123"
>
  Buy credits
</button>
```

***

## Modern websites [#modern-websites]

The embed is designed to work on static websites, landing page builders, and modern app-style websites. If your site loads product buttons after the page first opens, the embed usually detects them automatically.

If your developer needs to manually refresh the embed buttons, they can call:

```js
window.refreshCheckoutEmbed()
```


# Link a Custom Domain (/docs/linking-custom-domain)





By default, your SellApp storefront comes with a free subdomain, for example: **admin.sell.app**. You can also add a custom domain of your own, for example: **admin.com**, so your digital product store lives on your own brand.

**It is completely free to add a custom domain to your SellApp storefront.**

***

## **Video Guide: Root Domain** [#video-guide-root-domain]

In the following video guide we visually show you how to configure a **root** domain such as **example.com**, **bob.com**, or **varrock.osrs**.

For you to follow this guide step-by-step, you will want to change your domain's DNS provider to Cloudflare. It's free and easy to do so.

<video className="rounded-xl w-full">
  <source src="`${docsBasePath}/images/custom-domain.mp4`" type="video/mp4" />

  Your browser does not support the video tag.
</video>

If you prefer a text-based guide, please proceed to scroll down to "Step 1".

***

## **Video Guide: Subdomain** [#video-guide-subdomain]

In the following video guide we visually show you how to configure a **subdomain*&#x2A; such as &#x2A;*[www.example.com](http://www.example.com)**, **me.bob.com**, or **teleport.varrock.osrs**.

For you to follow this guide step-by-step, you will want to change your domain's DNS provider to Cloudflare. It's free and easy to do so.

<video className="rounded-xl w-full">
  <source src="`${docsBasePath}/images/custom-subdomain.mp4`" type="video/mp4" />

  Your browser does not support the video tag.
</video>

If you prefer a text-based guide, please proceed to scroll down to "Step 1".

***

## **Step 1: Buy a custom domain** [#step-1-buy-a-custom-domain]

*If you've already purchased or own a domain name, skip ahead to Step 2.*

If you don't already have a custom domain, you're going to want to buy one. We strongly suggest going with [Cloudflare](https://www.cloudflare.com) as they're easy, affordable, and have a best-in-class DNS system that comes with DDoS protection out of the box.

***

## **Step 2: Add your custom domain to SellApp** [#step-2-add-your-custom-domain-to-sellapp]

To set up your custom domain, &#x2A;*[navigate to your storefront's personalization settings](https://sell.app/dashboard/settings?settings=personalization)** -> **Custom Domain** and enter the custom domain you'd like your SellApp storefront to live on.

You can specify any domain you'd like:

1. A root domain such as **example.com**, **bob.com**, or **varrock.osrs**
2. A subdomain such as &#x2A;*[www.example.com](http://www.example.com)**, **me.bob.com**, or **teleport.varrock.osrs**

***

## **Step 3: Add the CNAME and TXT records to your custom domain's DNS settings** [#step-3-add-the-cname-and-txt-records-to-your-custom-domains-dns-settings]

In your domain's DNS settings, create the records shown in the SellApp setup wizard. For most domains, you'll see two **CNAME records** pointing your (sub)domain to **sell-beacon.net**:

1. **CNAME Record 1**
   * **Host/Name:**  \*
   * **Value**/&#x2A;*Points To:** sell-beacon.net

2. **CNAME Record 2**
   * **Host/Name:**
     * **@*&#x2A; — If you'd like to link to your root domain &#x2A;(as mentioned in point 1 above)*.
     * **www**, or **me**, or **teleport*&#x2A; — If you'd like to link to your subdomain &#x2A;(as mentioned in point 2 above)*.
     * Some providers ask for the full domain shown in SellApp instead of &#x2A;*@** or the subdomain prefix. If your DNS dashboard does that, use the exact value SellApp shows.
   * **Value**/&#x2A;*Points To:** sell-beacon.net
   <Note>
     Some DNS providers require a period at the end of the domain that's being pointed to. In which case, you'll want to enter: sell-beacon.net.
   </Note>

3. **TXT Record**

   * If SellApp shows a TXT record, add it exactly as displayed. This is usually an **\_acme-challenge** record used to issue SSL for your domain.
     * If you are linking a root domain
       * **Host/Name:** \_acme-challenge
       * **Value/Points To:** The random string of characters shown on the SellApp page
     * If you are linking a subdomain
       * **Host/Name:*&#x2A; **\_acme-challenge.www*&#x2A; or **\_acme-challenge.me*&#x2A; or **\_acme-challenge.teleport**
       * **Value/Points To:** The random string of characters shown on the SellApp page

   <Note>
     At times, the TXT record is not required, so if it doesn't appear in SellApp you should be OK to proceed with the rest of the setup steps.
   </Note>

Once done, let the page finish loading on SellApp. Usually this takes less than a few minutes once the above values have been set, however, with some providers it may take longer.

***

## **Support: My custom domain is not being verified** [#support-my-custom-domain-is-not-being-verified]

Please make sure your DNS records have the following values:

1. 1X CNAME value pointing from host \* to value **sell-beacon.net**
2. 1X CNAME value pointing from host &#x2A;*@** to value **sell-beacon.net** (**www**, or **me**, or **teleport** if it's a subdomain )
3. 1X TXT host pointing from just **\_acme-challenge*&#x2A; to value being the random string of characters shown on the SellApp page (**\_acme-challenge.www*&#x2A;, or **\_acme-challenge.me*&#x2A;, or **\_acme-challenge.teleport** in case of subdomain)

Once done, go to the SellApp side and let it finish loading. This should take a few minutes once the above has been completed.

Should things not finish loading on the SellApp side in an hour after the changes have been made, it might be an issue with your DNS provider. As a workaround, we advise switching from your current DNS provider to Cloudflare.

Switching is free and easy to do, and should take no more than 5 minutes.


# Post-Purchase Redirect (/docs/post-purchase-redirect)



You might need to redirect a customer to a URL of your choosing once they have made payment and completed their purchase.

With SellApp, you can do so as follows: create or edit the relevant product, navigate to the **Customization** section, then enter the URL in the **redirect URL** input field.

Once done and saved, customers will be redirected to the URL you've entered. If you've appended the URL with any dynamic variables, these will automatically be inserted before redirecting your customer.

***

## Dynamic Redirect Variables [#dynamic-redirect-variables]

At present, the following dynamic redirect variables are supported:

* `[customer_email]` The customer's email address
* `[order_id]` The order ID associated with the purchase
* `[quantity]` The quantity purchased for the first product in the order
* `[payment_method]` The payment method used for the order

Looking for a variable that's not in the above list? Send us a message by contacting us via live chat &#x2A;(found at the bottom right hand corner of this page)*

### Redirect Example [#redirect-example]

You have a coding course. You want to automatically check whether a customer has paid for your course before activating their account and displaying the course.

With redirect URLs and dynamic variables, you can verify whether the customer's order ID and email address correspond with a paid invoice. For example, you can check the API or store incoming webhook data from your `order completed` webhooks, then let the customer create an account or activate their existing account.

The redirect URL would be: `https://my-coding-course.com/purchase-completed?email=[customer_email]&orderId=[order_id]`


# Pre-Fill Checkout Info (/docs/pre-fill-info)



At times, you might want to pre-fill the product page with a customer's checkout information.

A good example is when you want to redirect a customer from your own project to the checkout page in order to reduce the risk of mistakes during checkout.

With SellApp, you can do so by appending the URL with the appropriate query string variables. This helps when you already know the buyer's email, product variant, quantity, coupon, or preferred payment method.

***

## Supported variables [#supported-variables]

At present, the following query string variables are supported:

* `coupon` Any coupon code you would like to have automatically applied
* `email` The customer's email address
* `payment_method` The payment method with which the customer will pay. For built-in methods, use the gateway value such as `STRIPE` or `PAYPAL`. For custom payment methods, use the full custom method value shown by SellApp.
* `quantity` Product quantity which the customer will be purchasing
* `variant` If there is more than one variant, you can specify a specific variant ID
* `additional-[key]&#x60; The key and value of a checkout info field &#x2A;(you can copy the key when creating/editing a checkout info field)*

Looking for a variable that's not in the above list? Send us a message by contacting us via live chat &#x2A;(found at the bottom right hand corner of this page)*

### Checkout Example [#checkout-example]

Your website is all about rare game skins. Logged in customers can browse and purchase these game skins. One of your customers, John Doe, wants to purchase one of these skins and clicks on it to be redirected to the SellApp checkout page.

Rather than sending John to the default URL `https://example.sell.app/product/rare-game-skin` you could modify the URL with the customer's information you already have on your end.

Say they have a preferred payment method, are a recurring customer eligible for a 5% discount coupon, and they modified the quantity input to 2 rare game skins. Additionally, you have a custom checkout info "text" field that asks for the customer's in-game username.

You could then use this information and automatically modify the URL with the new query string variables.

The final URL would be: `https://example.sell.app/product/rare-game-skin?coupon=LOYAL5&email=john_doe@example.com&payment_method=STRIPE&quantity=2&additional-4124bc0a9335c27f086f24ba207a4912=JohnDoe123`

***

## Embed modal variables [#embed-modal-variables]

The query string variables above apply to SellApp storefront and product URLs. If you are using the embed modal on your own site, pass the same kind of data on the button instead.

For standard checkout values, use `data-sell-*` attributes such as `data-sell-coupon`, `data-sell-email`, `data-sell-payment_method`, `data-sell-quantity`, and `data-sell-variant`.

For custom checkout information fields, use `data-sell-checkout-{fieldKey}`. Copy the field key from SellApp; it is not always the same as the field label customers see at checkout.

```html
<button
  data-sell-store="123"
  data-sell-product="456"
  data-sell-email="john_doe@example.com"
  data-sell-coupon="LOYAL5"
  data-sell-quantity="2"
  data-sell-payment_method="STRIPE"
  data-sell-checkout-4124bc0a9335c27f086f24ba207a4912="JohnDoe123"
>
  Buy now
</button>
```

Embed checkout field values are parsed as JSON when possible, so booleans, numbers, arrays, and objects can be passed when a field type needs them. See [Embed Digital Products](/embedding-products#checkout-info-prefills) for the full embed attribute list.


# Dynamic Webhook Setup (/docs/setting-up-dynamic-webhook)



SellApp's dynamic webhook sends a `POST` request to the webhook URL you enter on a product variant.

The `POST` request is sent as a `JSON object` when a customer successfully completes a payment, and contains all the relevant order data so your webhook can process the order programmatically.

Whatever value you return to us as a response to the above `POST` request can be passed along to the customer as the dynamic deliverable. Use dynamic webhooks when digital product delivery depends on your own system, such as generated accounts, custom keys, provisioning flows, or external stock.

<Warn>
  Use an `HTTPS` webhook endpoint in production so the order payload and signature cannot be intercepted.
</Warn>

***

## **Generate a webhook secret** [#generate-a-webhook-secret]

Before proceeding, we strongly advise creating a webhook secret that you'll want to be using to verify and validate incoming webhook requests as legitimate.

If you don't do so, a malicious person could spoof requests and make it look like we're sending them, thus possibly resulting in your stock being drained.

Here's how to create a webhook secret:

1. Navigate [to your store's developers settings](https://sell.app/dashboard/settings?settings=developers)
2. Click "Generate" in the "Webhook secret" section.
3. The newly generated secret is saved and copied to your clipboard.

***

## **Validating signed webhooks** [#validating-signed-webhooks]

To verify the authenticity of webhook calls sent to your dynamic webhook endpoint, SellApp sends a HMAC signature that is comprised of the JSON encoded request body and your generated webhook secret.

<Note>
  SellApp uses the 

  `sha256`

   hash function
</Note>

Here is a validation example for the dynamic webhook endpoint in PHP:

```php
$secret = "webhook-secret-here"; // the webhook secret you generated on SellApp
$signature = $_SERVER['HTTP_SIGNATURE']; // Retrieving the HMAC signature sent by our servers

$computedSignature = hash_hmac('sha256', file_get_contents('php://input'), $secret); // Validating the HMAC signature sent by our servers

if (hash_equals($computedSignature, $signature)) {
    // The signature sent by the webhook is valid, we can process the order
} else {  
  // The signature is invalid, this means something in the configuration is wrong or the webhook was not sent by SellApp
}
```

<Note>
  Sending a test dynamic webhook is only for the purpose of checking whether your endpoint is correct. The test sends mock data which is not representative for production webhooks.

  If you have set a webhook secret, test dynamic webhooks do send the secret in the header under the variable "signature"
</Note>

***

## **Returning dynamic content** [#returning-dynamic-content]

When your endpoint responds successfully, SellApp stores the response on the delivered order.

You can return plain text, which will be shown to the customer as the dynamic deliverable message. You can also return JSON with a `message` value:

```json
{
  "message": "Your custom account has been created."
}
```

If your dynamic webhook manages stock externally, you may also return a `stock` value to update the product variant's stock:

```json
{
  "message": "Your custom account has been created.",
  "stock": 42
}
```

Once this has been set up and configured correctly, you're all good to go.

Whenever a new order is delivered, we'll ping the dynamic endpoint URL you entered on the product variant, then pass along your webhook's response to the customer.


# Bitcoin Payments (/docs/bitcoin-payments)



Use Bitcoin payments when customers should pay for digital products with BTC and funds should route through the Bitcoin wallet setup connected to your SellApp store.

Open [Payment settings](https://sell.app/dashboard/settings?settings=payment), then open **Bitcoin** under **Cryptocurrencies**.

## Connect Bitcoin [#connect-bitcoin]

Enter your Bitcoin XPUB, then save the method. If you use Exodus, copy the second Bitcoin XPUB in the export list, which starts with `zpub`. SellApp recommends Electrum or Exodus for XPUB-based Bitcoin setup.

Do not use an XPUB from an exchange or Ledger. Those setups can cause funds to appear in addresses you cannot access from the wallet you expected.

## Enable Bitcoin on products [#enable-bitcoin-on-products]

When saving Bitcoin, you can enable it for all existing products. You can also control Bitcoin per variant from the product editor or bulk update payment methods from the Products dashboard.

Use Bitcoin for products where crypto checkout is expected, then keep card or wallet methods enabled when you also want a lower-friction checkout option for other buyers.


# BNB Payments (/docs/bnb-payments)



Use BNB payments when customers should pay with BNB and funds should route to your configured BNB wallet.

Open [Payment settings](https://sell.app/dashboard/settings?settings=payment), then open **BNB** under **Cryptocurrencies**.

## Connect BNB [#connect-bnb]

Enter your BNB wallet address. If the modal shows **Minimum Withdrawal**, optionally set the minimum BNB amount before funds are forwarded to your wallet. Leave it empty if you want forwarding to happen as soon as possible.

## Enable BNB on products [#enable-bnb-on-products]

When saving BNB, you can enable it for all existing products. You can also control BNB per variant from the product editor or with the Products dashboard bulk payment-method update.

If customers prefer stablecoins on BNB Smart Chain, configure USDT BEP20 or USDC BEP20 instead.


# Crypto Payment Methods (/docs/crypto-payment-methods-introduction)



SellApp lets you accept crypto payments for digital products through direct wallet payment methods and a broader Crypto Tokens checkout. Direct wallets send payments to the wallet details you configure, while Crypto Tokens lets buyers pay with a wider token set and settle funds into an eligible wallet.

Open [Payment settings](https://sell.app/dashboard/settings?settings=payment), then scroll to **Cryptocurrencies**.

## Direct crypto wallets [#direct-crypto-wallets]

Direct wallet methods are best when you know which coin or token your buyers want to use. SellApp supports:

1. Bitcoin.
2. Litecoin.
3. Ethereum.
4. BNB.
5. Tron.
6. Polygon.
7. Solana.
8. Monero.
9. ERC20 tokens: USDT, USDC, UNI, SHIB, and DAI.
10. BEP20 tokens: USDT and USDC.
11. Solana tokens: USDT and USDC.

Some wallets support a minimum withdrawal amount before funds are forwarded. If the option appears, leave it empty to forward funds as soon as possible.

## Crypto Tokens [#crypto-tokens]

Crypto Tokens lets customers pay with a larger token selection through a widget, then settle the payment into a wallet you choose. Before enabling Crypto Tokens, you need at least one eligible destination wallet enabled in SellApp.

Eligible destination wallets include supported Bitcoin, Ethereum, BNB Smart Chain, Polygon, Solana, and configured USDT or USDC wallets.

## Product-level enablement [#product-level-enablement]

When you add a crypto payment method, you can enable it for all existing products. You can also manage crypto methods per product variant from the product editor or with the Products dashboard bulk payment-method update.

Use product-level controls when only specific products should accept crypto payments, such as digital downloads, license keys, or manual-review products.


# Crypto Tokens (/docs/crypto-tokens)



Crypto Tokens lets buyers pay with a broad token selection through a checkout widget while funds settle to a wallet you choose. Use it when customers ask for more token flexibility than a single direct crypto payment method provides.

Open [Payment settings](https://sell.app/dashboard/settings?settings=payment), then open **Crypto Tokens** under **Cryptocurrencies**.

## Add an eligible settlement wallet [#add-an-eligible-settlement-wallet]

Before enabling Crypto Tokens, enable at least one supported wallet in SellApp. Eligible destinations include supported Bitcoin, Ethereum, BNB Smart Chain, Polygon, Solana, and configured USDT or USDC wallets.

If no eligible wallet is enabled, the Crypto Tokens modal will show a warning and ask you to add a supported crypto wallet first.

## Choose the settlement wallet [#choose-the-settlement-wallet]

In the Crypto Tokens modal, choose the wallet that should receive settled funds. SellApp only lists wallets that are already enabled and eligible for the store.

If the previously selected destination is no longer eligible, the modal will warn you so you can choose another wallet or disable Crypto Tokens.

## Enable Crypto Tokens on products [#enable-crypto-tokens-on-products]

When saving Crypto Tokens, you can enable it for all existing products. You can also manage it per product variant from the product editor or with the Products dashboard bulk payment-method update.

Use Crypto Tokens when you want a flexible crypto payment method without maintaining a separate direct wallet setup for every token customers might hold.


# DAI ERC20 Payments (/docs/dai-erc20-payments)



Use DAI ERC20 payments when customers should pay with DAI on Ethereum and funds should route to your configured DAI ERC20 wallet.

Open [Payment settings](https://sell.app/dashboard/settings?settings=payment), then open **DAI ERC20** under **Cryptocurrencies**.

## Connect DAI ERC20 [#connect-dai-erc20]

Enter the wallet address that should receive DAI on Ethereum. If the modal shows **Minimum Withdrawal**, optionally set the minimum amount before funds are forwarded. Leave it empty if you want forwarding to happen as soon as possible.

## Enable DAI ERC20 on products [#enable-dai-erc20-on-products]

When saving DAI ERC20, you can enable it for all existing products. You can also control it per variant from the product editor or with the Products dashboard bulk payment-method update.

DAI can be useful when customers want a stablecoin checkout option on Ethereum.


# Ethereum Payments (/docs/ethereum-payments)



Use Ethereum payments when customers should pay with ETH and funds should route to your configured Ethereum wallet.

Open [Payment settings](https://sell.app/dashboard/settings?settings=payment), then open **Ethereum** under **Cryptocurrencies**.

## Connect Ethereum [#connect-ethereum]

Enter your Ethereum wallet address. If the modal shows **Minimum Withdrawal**, optionally set the minimum ETH amount before funds are forwarded to your wallet. Leave it empty if you want forwarding to happen as soon as possible.

After saving, SellApp creates or updates the crypto wallet setup for your store.

## Enable Ethereum on products [#enable-ethereum-on-products]

When saving Ethereum, you can enable it for all existing products. You can also manage Ethereum per variant from the product editor or with the Products dashboard bulk payment-method update.

If buyers need ERC20 stablecoins or tokens instead of ETH, enable the relevant ERC20 payment method or use Crypto Tokens.


# Litecoin Payments (/docs/litecoin-payments)



Use Litecoin payments when customers should pay with LTC and funds should route through the Litecoin wallet setup connected to your SellApp store.

Open [Payment settings](https://sell.app/dashboard/settings?settings=payment), then open **Litecoin** under **Cryptocurrencies**.

## Connect Litecoin [#connect-litecoin]

Enter your Litecoin XPUB, then save the method. SellApp recommends Electrum or Exodus for XPUB-based Litecoin setup.

Do not use an XPUB from an exchange or Ledger. Those setups can cause funds to appear in addresses you cannot access from the wallet you expected.

## Enable Litecoin on products [#enable-litecoin-on-products]

When saving Litecoin, you can enable it for all existing products. You can also control Litecoin per variant from the product editor or bulk update payment methods from the Products dashboard.

Litecoin can be a useful alternative when buyers want direct crypto payment but prefer a different network from Bitcoin.


# Monero Payments (/docs/monero-payments)



Use Monero payments when customers should pay with XMR and funds should route through the Monero wallet details connected to your SellApp store.

Open [Payment settings](https://sell.app/dashboard/settings?settings=payment), then open **Monero** under **Cryptocurrencies**.

## Connect Monero [#connect-monero]

Enter the Monero address and the wallet's **Private View Key**. SellApp needs both values to watch for payments and process orders correctly.

After saving, SellApp validates the Monero setup and makes XMR available as a payment method for products that allow it.

## Enable Monero on products [#enable-monero-on-products]

When saving Monero, you can enable it for all existing products. You can also control Monero per variant from the product editor or with the Products dashboard bulk payment-method update.

Use clear checkout and delivery instructions when a product accepts crypto payment methods that customers may need more time to complete.


# Polygon Payments (/docs/polygon-payments)



Use Polygon payments when customers should pay with MATIC and funds should route to your configured Polygon wallet.

Open [Payment settings](https://sell.app/dashboard/settings?settings=payment), then open **Polygon** under **Cryptocurrencies**.

## Connect Polygon [#connect-polygon]

Enter your MATIC wallet address, then save the method. SellApp will validate the wallet setup and make Polygon available as a checkout option for products that allow it.

## Enable Polygon on products [#enable-polygon-on-products]

When saving Polygon, you can enable it for all existing products. You can also control Polygon per variant from the product editor or with the Products dashboard bulk payment-method update.

Polygon can also be used as an eligible destination wallet for Crypto Tokens when it is enabled for your store.


# SHIB ERC20 Payments (/docs/shib-erc20-payments)



Use SHIB ERC20 payments when customers should pay with SHIB on Ethereum and funds should route to your configured SHIB ERC20 wallet.

Open [Payment settings](https://sell.app/dashboard/settings?settings=payment), then open **SHIB ERC20** under **Cryptocurrencies**.

## Connect SHIB ERC20 [#connect-shib-erc20]

Enter the wallet address that should receive SHIB on Ethereum. If the modal shows **Minimum Withdrawal**, optionally set the minimum amount before funds are forwarded. Leave it empty if you want forwarding to happen as soon as possible.

## Enable SHIB ERC20 on products [#enable-shib-erc20-on-products]

When saving SHIB ERC20, you can enable it for all existing products. You can also control it per variant from the product editor or with the Products dashboard bulk payment-method update.

Keep product checkout options intentional. If SHIB is only relevant to a few products, enable it only on those variants.


# Solana Payments (/docs/solana-payments)



Use Solana payments when customers should pay with SOL and funds should route to your configured Solana wallet.

Open [Payment settings](https://sell.app/dashboard/settings?settings=payment), then open **Solana** under **Cryptocurrencies**.

## Connect Solana [#connect-solana]

Enter your Solana wallet address. If the modal shows **Minimum Withdrawal**, optionally set the minimum SOL amount before funds are forwarded to your wallet. Leave it empty if you want forwarding to happen as soon as possible.

## Enable Solana on products [#enable-solana-on-products]

When saving Solana, you can enable it for all existing products. You can also control Solana per variant from the product editor or with the Products dashboard bulk payment-method update.

If customers prefer stablecoins on Solana, configure USDT Solana or USDC Solana. Solana can also be an eligible settlement wallet for Crypto Tokens.


# Tron Payments (/docs/tron-payments)



Use Tron payments when customers should pay with TRX and funds should route to your configured Tron wallet.

Open [Payment settings](https://sell.app/dashboard/settings?settings=payment), then open **Tron** under **Cryptocurrencies**.

## Connect Tron [#connect-tron]

Enter your Tron wallet address. If the modal shows **Minimum Withdrawal**, optionally set the minimum TRX amount before funds are forwarded to your wallet. Leave it empty if you want forwarding to happen as soon as possible.

## Enable Tron on products [#enable-tron-on-products]

When saving Tron, you can enable it for all existing products. You can also control Tron per variant from the product editor or with the Products dashboard bulk payment-method update.

Keep the product's delivery and payment instructions clear so customers know which crypto option they selected at checkout.


# UNI ERC20 Payments (/docs/uni-erc20-payments)



Use UNI ERC20 payments when customers should pay with UNI on Ethereum and funds should route to your configured UNI ERC20 wallet.

Open [Payment settings](https://sell.app/dashboard/settings?settings=payment), then open **UNI ERC20** under **Cryptocurrencies**.

## Connect UNI ERC20 [#connect-uni-erc20]

Enter the wallet address that should receive UNI on Ethereum. If the modal shows **Minimum Withdrawal**, optionally set the minimum amount before funds are forwarded. Leave it empty if you want forwarding to happen as soon as possible.

## Enable UNI ERC20 on products [#enable-uni-erc20-on-products]

When saving UNI ERC20, you can enable it for all existing products. You can also control it per variant from the product editor or with the Products dashboard bulk payment-method update.

If you want to support a broader token list without creating a dedicated direct wallet for every buyer preference, configure Crypto Tokens as well.


# USDC BEP20 Payments (/docs/usdc-bep20-payments)



Use USDC BEP20 payments when customers should pay with USDC on BNB Smart Chain and funds should route to your configured USDC BEP20 wallet.

Open [Payment settings](https://sell.app/dashboard/settings?settings=payment), then open **USDC BEP20** under **Cryptocurrencies**.

## Connect USDC BEP20 [#connect-usdc-bep20]

Enter the wallet address that should receive USDC on BNB Smart Chain. If the modal shows **Minimum Withdrawal**, optionally set the minimum amount before funds are forwarded. Leave it empty if you want forwarding to happen as soon as possible.

## Enable USDC BEP20 on products [#enable-usdc-bep20-on-products]

When saving USDC BEP20, you can enable it for all existing products. You can also control it per variant from the product editor or with the Products dashboard bulk payment-method update.

Make sure customers know this is the BEP20 version of USDC, not USDC on Ethereum, Solana, or another network.


# USDC ERC20 Payments (/docs/usdc-erc20-payments)



Use USDC ERC20 payments when customers should pay with USDC on Ethereum and funds should route to your configured USDC ERC20 wallet.

Open [Payment settings](https://sell.app/dashboard/settings?settings=payment), then open **USDC ERC20** under **Cryptocurrencies**.

## Connect USDC ERC20 [#connect-usdc-erc20]

Enter the wallet address that should receive USDC on Ethereum. If the modal shows **Minimum Withdrawal**, optionally set the minimum amount before funds are forwarded. Leave it empty if you want forwarding to happen as soon as possible.

## Enable USDC ERC20 on products [#enable-usdc-erc20-on-products]

When saving USDC ERC20, you can enable it for all existing products. You can also control it per variant from the product editor or with the Products dashboard bulk payment-method update.

Make sure customers know this is the Ethereum ERC20 version of USDC, not USDC on another network.


# USDC Solana Payments (/docs/usdc-solana-payments)



Use USDC Solana payments when customers should pay with USDC on Solana and funds should route to your configured USDC Solana wallet.

Open [Payment settings](https://sell.app/dashboard/settings?settings=payment), then open **USDC Solana** under **Cryptocurrencies**.

## Connect USDC Solana [#connect-usdc-solana]

Enter the wallet address that should receive USDC on Solana. If the modal shows **Minimum Withdrawal**, optionally set the minimum amount before funds are forwarded. Leave it empty if you want forwarding to happen as soon as possible.

## Enable USDC Solana on products [#enable-usdc-solana-on-products]

When saving USDC Solana, you can enable it for all existing products. You can also control it per variant from the product editor or with the Products dashboard bulk payment-method update.

Make sure customers know this is the Solana version of USDC, not USDC on Ethereum, BNB Smart Chain, or another network.


# USDT BEP20 Payments (/docs/usdt-bep20-payments)



Use USDT BEP20 payments when customers should pay with Tether on BNB Smart Chain and funds should route to your configured USDT BEP20 wallet.

Open [Payment settings](https://sell.app/dashboard/settings?settings=payment), then open **USDT BEP20** under **Cryptocurrencies**.

## Connect USDT BEP20 [#connect-usdt-bep20]

Enter the wallet address that should receive USDT on BNB Smart Chain. If the modal shows **Minimum Withdrawal**, optionally set the minimum amount before funds are forwarded. Leave it empty if you want forwarding to happen as soon as possible.

## Enable USDT BEP20 on products [#enable-usdt-bep20-on-products]

When saving USDT BEP20, you can enable it for all existing products. You can also control it per variant from the product editor or with the Products dashboard bulk payment-method update.

Make sure customers know this is the BEP20 version of USDT, not USDT on Ethereum, Solana, or another network.


# USDT ERC20 Payments (/docs/usdt-erc20-payments)



Use USDT ERC20 payments when customers should pay with Tether on Ethereum and funds should route to your configured USDT ERC20 wallet.

Open [Payment settings](https://sell.app/dashboard/settings?settings=payment), then open **USDT ERC20** under **Cryptocurrencies**.

## Connect USDT ERC20 [#connect-usdt-erc20]

Enter the wallet address that should receive USDT on Ethereum. If the modal shows **Minimum Withdrawal**, optionally set the minimum amount before funds are forwarded. Leave it empty if you want forwarding to happen as soon as possible.

## Enable USDT ERC20 on products [#enable-usdt-erc20-on-products]

When saving USDT ERC20, you can enable it for all existing products. You can also control it per variant from the product editor or with the Products dashboard bulk payment-method update.

Make sure customers know this is the Ethereum ERC20 version of USDT, not USDT on another network.


# USDT Solana Payments (/docs/usdt-solana-payments)



Use USDT Solana payments when customers should pay with Tether on Solana and funds should route to your configured USDT Solana wallet.

Open [Payment settings](https://sell.app/dashboard/settings?settings=payment), then open **USDT Solana** under **Cryptocurrencies**.

## Connect USDT Solana [#connect-usdt-solana]

Enter the wallet address that should receive USDT on Solana. If the modal shows **Minimum Withdrawal**, optionally set the minimum amount before funds are forwarded. Leave it empty if you want forwarding to happen as soon as possible.

## Enable USDT Solana on products [#enable-usdt-solana-on-products]

When saving USDT Solana, you can enable it for all existing products. You can also control it per variant from the product editor or with the Products dashboard bulk payment-method update.

Make sure customers know this is the Solana version of USDT, not USDT on Ethereum, BNB Smart Chain, or another network.


# SellApp FAQ (/docs/faq)



This page covers common SellApp questions that are not answered elsewhere in the documentation, including store settings, digital product stock, license keys, and order statuses.

## General [#general]

### How do I allow customers using a VPN to make purchases? [#how-do-i-allow-customers-using-a-vpn-to-make-purchases]

The VPN check helps protect your store from fraud. If you want to allow VPN-based purchases:

1. Open [your storefront payment settings](https://sell.app/dashboard/settings?settings=payment).
2. Enable **Allow VPN purchases**.
3. Save your changes.

### How do I change my subdomain? [#how-do-i-change-my-subdomain]

Store subdomains cannot currently be changed.

### How do I appeal negative feedback? [#how-do-i-appeal-negative-feedback]

Feedback cannot currently be appealed.

### My store got banned. Can I recover my products or data? [#my-store-got-banned-can-i-recover-my-products-or-data]

Storefronts that violate SellApp rules are reviewed and banned by the internal risk team. Associated products, files, and stock are purged. SellApp does not restore or redistribute that content.

## Products [#products]

### How do I restock my product? [#how-do-i-restock-my-product]

1. Open [the products dashboard](https://sell.app/dashboard/listings).
2. Click the relevant product.
3. Go to the **Content** section and add more stock.
4. Save the product.

### How do I sell serials, codes, keys, or licenses one-by-one? [#how-do-i-sell-serials-codes-keys-or-licenses-one-by-one]

1. Open [the products dashboard](https://sell.app/dashboard/listings).
2. Create a new product or edit an existing one.
3. In the **Content** section, select **Codes & Serials**.
4. Enter your stock in the **Saved Serials** field.
5. Set the correct stock delimiter if needed.
6. Save the product.

This is the recommended setup when you need license key management for software, access codes, gift codes, or any digital product that should deliver one unique value per order.

### How do I sell a product for under a dollar? [#how-do-i-sell-a-product-for-under-a-dollar]

Payment providers typically require the total order value to be at least one dollar. The usual workaround is to increase the minimum quantity so the total reaches that threshold.

For example, if a product costs `$0.50`, set the minimum quantity to `2`.

## Orders [#orders]

### When should I mark an order as completed, and how do I do so? [#when-should-i-mark-an-order-as-completed-and-how-do-i-do-so]

SellApp automatically detects successful payments and marks orders as completed. In most cases, you should not need to do this manually.

If you still need to mark an order as completed:

1. Open [the orders dashboard](https://sell.app/dashboard/invoices).
2. Click the three-dot menu on the relevant order.
3. Select &#x2A;*Mark as...**.
4. Choose **Mark as completed** and process the change.

### What do pending, voided, and completed mean in my orders dashboard? [#what-do-pending-voided-and-completed-mean-in-my-orders-dashboard]

* **Pending**: The order was started but not yet paid.
* **Voided**: The order was not paid within 24 hours.
* **Completed**: Payment was received and the order was processed successfully.


# SellApp Features (/docs/features)



Out of the box, SellApp includes the features merchants need to sell digital products online, automate delivery, manage payments, and grow a storefront without extra plugins.

## Digital Commerce Features [#digital-commerce-features]

* Digital product delivery with files, serials, license keys, manual delivery notes, and dynamic webhooks
* Hosted storefronts with custom domains, storefront personalization, Stories, feedback, and a visual builder
* Payment integrations for cards, wallets, direct crypto wallets, Solana, Crypto Tokens, Cash App, custom payment methods, and subscription-capable gateways
* Fraud protection, blacklists, VPN controls, checkout rate limiting, and store-level risk tooling
* Coupons, promotions, abandoned cart recovery, payment-method discounts or fees, bulk discounts, upsells, cross-sells, add-ons, and pay-what-you-want pricing
* Built-in affiliate programs with applications, invites, referral tracking, custom rates, coupons, and payout management
* Subscription and recurring billing support for products that need ongoing access
* Community access automation for Discord, Telegram, Slack, and WhatsApp
* Embedded checkout flows for selling from your own site
* Staff permissions, customer portals, tickets, order management, feedback replies, and analytics
* API access, webhooks, scoped API keys, webhook secrets, and recent webhook delivery logs

## What You Can Build [#what-you-can-build]

With SellApp, you can sell software, ebooks, memberships, license keys, subscriptions, paid communities, files, templates, videos, and other digital products through a single storefront.

## Built for Growth [#built-for-growth]

Start with a simple checkout and automated file delivery, then add the tools that match your sales strategy. You can use coupons and bundles for promotions, abandoned cart recovery for unfinished checkouts, upsells and cross-sells for larger carts, affiliate tracking for referrals, and tickets or feedback replies for customer support.

## Related Guides [#related-guides]

<Cards>
  <Card title="Setup Guide" href="/setup">
    Create your store, connect payments, and publish products.
  </Card>

  <Card title="Support" href="/support">
    Reach the support team when you need help with your store.
  </Card>

  <Card title="FAQ" href="/faq">
    Review common operational questions and answers.
  </Card>
</Cards>


# Sell Digital Products with SellApp (/docs)





SellApp is an ecommerce platform for selling digital products, downloads, subscriptions, license keys, and paid community access from one hosted storefront. You can launch a store, connect payment methods, automate delivery, and manage customers without stitching together separate tools.

<img src="`${docsBasePath}/images/dash.webp`" alt="SellApp dashboard" className="w-full rounded-xl border shadow-lg" />

## Start Selling Digital Products [#start-selling-digital-products]

Use these docs to move from account setup to your first paid order. The core flow is simple: create a storefront, connect a payment method, publish products, then let SellApp handle checkout, fraud checks, and digital product delivery.

## Getting Started [#getting-started]

SellApp is built for speed and simplicity, but it also supports larger workflows like subscriptions, affiliate programs, coupons, paid Discord or Telegram access, and custom payment methods. These pages cover the core setup flow, feature overview, support options, and common questions.

<Cards>
  <Card title="Setup Guide" href="/setup">
    Learn how to create your store, connect payments, and list your first products.
  </Card>

  <Card title="Store Settings" href="/storefront-settings-introduction">
    Configure dashboard defaults, checkout behavior, analytics, personalization, and developer tools.
  </Card>

  <Card title="Features" href="/features">
    Review the main platform capabilities available out of the box.
  </Card>

  <Card title="Support" href="/support">
    Find the fastest way to contact the SellApp support team.
  </Card>

  <Card title="FAQ" href="/faq">
    Read the answers to common questions from merchants using SellApp.
  </Card>
</Cards>


# Set Up Your SellApp Store (/docs/setup)





Starting to sell digital products on SellApp is simple. Most merchants can get through the initial store setup in a few minutes:

1. Sign up.
2. Create your first store.
3. List your products.

After that, customers can visit your store and make purchases while SellApp handles payment processing, digital delivery, and fraud protection.

## Signing Up [#signing-up]

Create an account in seconds at [sell.app/register](https://sell.app/register). You can register with email details or sign up in one click with Google.

## Creating a Storefront [#creating-a-storefront]

During sign-up, you can create a store immediately. We only ask for three pieces of information:

1. Store name
2. Store visibility
3. Store subdomain

<Callout title="Note">
  Store name and visibility can be updated later. Store subdomains cannot currently be changed.
</Callout>

<video className="w-full rounded-xl border">
  <source src="`${docsBasePath}/images/register.mp4`" type="video/mp4" />

  Your browser does not support the video tag.
</video>

## Listing Your Digital Products [#listing-your-digital-products]

Before listing products, connect at least one payment method in your storefront settings or directly at [the payment settings page](https://sell.app/dashboard/settings?settings=payment).

<Callout title="Note">
  Customer payments are sent directly to your linked payment account. SellApp does not hold your funds.
</Callout>

Once a payment method is connected, you can immediately start creating products. SellApp supports files, license keys, serials, subscriptions, memberships, and other digital product formats, so choose the delivery type that matches what customers should receive after checkout.

<video className="w-full rounded-xl border">
  <source src="`${docsBasePath}/images/product.mp4`" type="video/mp4" />

  Your browser does not support the video tag.
</video>

## Next Steps After Launch [#next-steps-after-launch]

You now have the basics in place: an account, a storefront, and your first products. From here, you can expand with more payment methods, a custom domain, promotions, paid community access, and automation.

<video className="w-full rounded-xl border">
  <source src="`${docsBasePath}/images/earn.mp4`" type="video/mp4" />

  Your browser does not support the video tag.
</video>

If you need help at any point, use the live chat button on the site.


# SellApp Support (/docs/support)



Should you ever need help with your SellApp store, the fastest way to contact SellApp is through live chat in the dashboard.

## Live Chat [#live-chat]

Live chat is the main support channel for creators who manage a storefront, products, payments, subscriptions, community access, or customer support tickets in SellApp.

### For Customers [#for-customers]

The SellApp support team cannot assist customers with purchase-related inquiries at this time. Please direct your questions to the store owner. You can do so through the contact options on the store URL itself or by creating a support ticket in the customer portal.

### For Creators [#for-creators]

To get in touch, navigate to [the SellApp dashboard](https://sell.app/dashboard) and click on the "Support" button at the bottom left. Then, select "Live Chat". The live chat button will appear at the bottom right of the page. Click it to open the live chat modal and start a chat session.

## Report Abuse [#report-abuse]

If you come across a storefront that appears to violate platform rules, send an email to [report@sell.app](mailto:report@sell.app) with the store URL, relevant details, and screenshots if possible.

<Callout type="warning" title="Important">
  Abuse reports are only handled through email. Do not send them through social media or live chat.
</Callout>


# Abandoned Cart Recovery (/docs/abandoned-cart-recovery)



Abandoned cart recovery helps you follow up with customers who start checkout but do not complete payment. SellApp can send reminder emails, limit reminders to certain order totals, and include a coupon incentive in a chosen email.

Open [Marketing settings](https://sell.app/dashboard/settings?settings=marketing), then use **Abandoned Cart Reminders**.

## Enable reminder emails [#enable-reminder-emails]

Switch **Status** on to enable abandoned cart reminder emails for the store. SellApp scans eligible unpaid checkouts and schedules reminders based on the settings you save.

Use the order amount range when you only want reminders for carts above a minimum total or below a maximum total. Leave the fields empty when every eligible cart should be considered.

## Configure the reminder schedule [#configure-the-reminder-schedule]

You can configure up to three reminder emails. Each reminder uses an hour delay after checkout starts, with a maximum of 72 hours.

The schedule cannot have gaps. Email #2 requires Email #1, and Email #3 requires Email #2. Each later reminder must be scheduled after the previous one.

## Add a purchase incentive [#add-a-purchase-incentive]

If you want to offer a discount, choose a coupon and select which reminder email should include it. The incentive is only shown when the order does not already have a coupon, and expired or unavailable coupons are ignored.

Use abandoned cart recovery with a clear coupon strategy. A small discount in Email #2 or Email #3 can recover buyers without training every customer to wait for a discount.


# Product Add-Ons (/docs/add-ons)



Product add-ons are optional extras customers can add while buying a digital product. They work well for priority support, setup help, extra files, license upgrades, templates, source files, or any small product that makes the main purchase more valuable.

***

## Create an add-on [#create-an-add-on]

Open [Add-ons](https://sell.app/dashboard/addons), then click **New add-on**.

Set the basics:

1. Add a title, slug, and description.
2. Choose the visibility.
3. Choose which parent products can offer this add-on.
4. Save the add-on.

An add-on is still a listing behind the scenes, but it is presented as an optional attachment to the parent product instead of as a normal storefront product.

***

## Attach add-ons from a product [#attach-add-ons-from-a-product]

You can also attach add-ons while editing a product.

Open the product, expand **Marketing**, then use **Add-ons** to select one or more add-ons customers can choose from.

Customers will see those add-ons during cart and checkout for that product. If they select one, SellApp stores the add-on alongside the parent order item so the relationship stays clear on the order.

<Note>
  Add-ons are built for one-time product carts. They are not available for subscription carts.
</Note>

***

## Good add-on ideas [#good-add-on-ideas]

Strong add-ons are easy to understand and clearly tied to the main product. A good add-on should feel like a natural upgrade, not a separate product the customer has to research.

Examples:

1. Installation help for a software product.
2. A commercial license upgrade for a digital asset.
3. Bonus templates for a design pack.
4. Priority support for a setup-heavy product.
5. Source files for a finished resource.

Keep the add-on title direct. Customers should understand the upgrade before they even open the description.


# Product Bundles (/docs/bundles)



Product bundles let you sell multiple products together as a single listing. They are useful for starter packs, full-access drops, course packs, template bundles, software packs, and discounted digital product collections.

***

## Create a bundle [#create-a-bundle]

Open [Bundles](https://sell.app/dashboard/bundles), then click **New bundle**.

Set up the bundle like a normal listing:

1. Add a title, slug, and description.
2. Choose the visibility.
3. Add product images.
4. Add any extra checkout fields, redirect URL, video, FAQ, or SEO fields you need.
5. Save the bundle.

After the bundle exists, add the products and variants it should include. Each bundle item can have its own quantity, so one bundle can include multiple copies of the same underlying item if needed.

<Note>
  Bundles are their own listings. Customers buy the bundle directly instead of adding the bundle itself into a normal cart flow.
</Note>

***

## Add products to a bundle [#add-products-to-a-bundle]

From the bundle editor, add the product variants that should be delivered when the bundle is purchased.

Use clear bundle titles so customers understand the package at a glance, then use the description to explain the included products and why buying the bundle is better than buying each product separately.

Strong bundle pages usually mention the full contents, the normal individual value, and the outcome the customer gets by buying everything together.

***

## Price the bundle [#price-the-bundle]

A bundle has its own pricing. Set the bundle price based on the value of the full package, not just the cheapest item inside it.

Common approaches:

1. **Discounted pack:** bundle several products and price below the sum of individual prices.
2. **Premium pack:** include exclusive files, access, or services that are not available separately.
3. **Fast-start pack:** combine the product with templates, guides, or support to shorten setup time.

Bundles currently work best for one-time purchases. If you need recurring billing, create a subscription product instead.

***

## Delivery [#delivery]

When a customer purchases a bundle, SellApp keeps a snapshot of the bundled items for that order. That means the order stays clear even if you edit the bundle later.

Use the order page to confirm which products were included in the customer's bundle purchase.


# Coupon Codes (/docs/coupons)



Coupons are code-based discounts for your SellApp storefront. They are best when you want a specific audience to enter a code, such as an affiliate audience, a private group, a returning customer segment, or a one-off support gesture.

***

## Create a coupon [#create-a-coupon]

Open [Coupons](https://sell.app/dashboard/coupons), then click **New coupon**.

Set the core fields:

1. Enter the coupon code customers will type at checkout.
2. Choose **Fixed amount** or **Percentage**.
3. Enter the discount amount.
4. Decide whether the coupon is store-wide or limited to selected products.
5. Optionally add a redemption limit.
6. Optionally set an expiration date and time.

Percentage coupons can also have a maximum discount amount. Use that when you want a large percentage discount to feel strong without risking a huge discount on high-ticket orders.

***

## Limit a coupon to products [#limit-a-coupon-to-products]

Turn off store-wide use when a code should only work on specific products. Then add the products that should accept the coupon.

This is useful for:

1. New product launches.
2. Slow-moving products.
3. Affiliate campaigns around a specific offer.
4. Private customer upgrades.
5. Support credits for a specific replacement purchase.

If a coupon should work everywhere, keep it store-wide and avoid extra product restrictions.

Product-limited coupon codes are useful when one digital product needs a launch discount but the rest of your catalog should keep its normal pricing.

***

## Minimum amount and caps [#minimum-amount-and-caps]

Use **Minimum amount** when the customer should spend a certain amount before the coupon applies.

Use **Maximum discount amount** for percentage coupons when you want to cap the money saved. For example, a 50% code with a maximum discount of $25 still feels generous, but it will not remove half the price of a high-value cart.

***

## Coupons vs promotions [#coupons-vs-promotions]

Use a coupon when the customer needs a code.

Use a promotion when the discount should apply automatically.

If a cart has both a coupon and a promotion, the promotion's stackable setting decides whether the automatic promotion can apply alongside the coupon.


# Marketing Digital Products (/docs/marketing-introduction)



SellApp's marketing tools help you shape how customers discover digital products, choose a better option, and add more before checkout. Use them to launch offers, raise average order value, reward campaigns, and guide buyers through a larger catalog.

The main tools are:

1. **Promotions** for automatic store-wide offers with phases, limits, and checkout labels.
2. **Abandoned cart recovery** for reminder emails, order amount ranges, schedules, and coupon incentives.
3. **Coupons** for code-based discounts that can apply store-wide or to selected products.
4. **Bundles** for selling multiple products together as one listing.
5. **Add-ons** for optional extras customers can attach in the cart or checkout.
6. **Upsells and cross-sells** for recommending variants and similar products on product pages.
7. **Stories** for visual product drops, previews, social proof, and builder blocks.

***

## Where to start [#where-to-start]

Use **Promotions** when you want the discount to apply automatically.

Use **Abandoned cart recovery** when customers start checkout but do not complete payment.

Use **Coupons** when you want customers, affiliates, or campaigns to use a specific code.

Use **Bundles** when the offer is a packaged product with its own listing page, such as a template pack, software bundle, course pack, or digital download collection.

Use **Add-ons** when the extra should be optional during purchase.

Use **Upsells and cross-sells** when the customer is already viewing a product and you want to guide them to a better or related option.

***

## A simple launch stack [#a-simple-launch-stack]

For a product launch, you might:

1. Create a limited-time promotion for launch pricing.
2. Enable abandoned cart recovery with a follow-up email and optional coupon.
3. Create a bundle that packages the main product with bonus products.
4. Add a premium add-on for customers who want extra setup, support, or files.
5. Mark the strongest variant as **Recommended** or **Best value**.
6. Publish a story that shows the product, bonus, or customer proof in the storefront builder.

Each tool can work on its own, but they become stronger when they point customers toward the same offer.


# Automatic Promotions (/docs/promotions)



Promotions are automatic discounts for your SellApp storefront. Customers do not enter a code; SellApp checks the current active promotion and applies it at checkout when the order qualifies.

Use promotions for digital product launches, flash sales, limited redemption offers, cart incentives, and scheduled campaigns.

***

## Create a promotion [#create-a-promotion]

Open [Promotions](https://sell.app/dashboard/promotions), then click **New promotion**.

Set the basics first:

1. Add a clear internal name, like `Launch week` or `Weekend flash sale`.
2. Choose whether the promotion is active.
3. Optionally set a start date and end date.
4. Set a priority. Lower numbers are evaluated first when multiple promotions are active.
5. Decide whether the promotion can stack with coupons.
6. Optionally cap total redemptions.

After that, configure at least one phase.

***

## Promotion phases [#promotion-phases]

Phases let one promotion change over time or after a usage cap. Each phase can have:

1. A percentage or fixed discount.
2. An optional end date.
3. An optional maximum redemption count.
4. An optional minimum subtotal.

For example, a launch promotion can start at 30% off for the first 50 orders, then move to 15% off until the campaign ends. This lets a product launch reward early buyers without requiring a separate coupon code.

<Note>
  If a customer has a valid coupon and the promotion is not stackable, SellApp will block the promotion for that cart. Turn on stacking only when you intentionally want both discounts to apply.
</Note>

***

## Storefront labels and incentives [#storefront-labels-and-incentives]

SellApp can show promotion labels on the storefront and cart. If a promotion has a minimum subtotal, the cart can show an incentive message such as how much more the customer needs to add before the deal unlocks.

Keep promotion names customer-friendly if you plan to show them publicly. `Summer drop` reads better than `promo-test-4`.

***

## Check performance [#check-performance]

The Promotions dashboard includes usage data, so you can see whether a campaign is getting redeemed. If a promotion is not being applied, check:

1. The promotion status.
2. Start and end dates.
3. Promotion and phase redemption caps.
4. Minimum subtotal.
5. Coupon stacking.
6. Whether another active promotion has higher priority.


# Storefront Stories (/docs/stories)





Stories help turn your store into a more interactive buying experience without forcing customers to bounce around your storefront. Use them for product launches, social proof, quick demos, product education, bonus previews, and visual merchandizing for digital products.

<img src="`${docsBasePath}/images/stories.png`" alt="Story example" className="rounded-xl w-full shadow-lg" />

Instead of browsing various pages, customers can:

1. Open a story to view an image/video about a product being used
2. Click on a product link **directly within the story*&#x2A; to immediately navigate to the product page &#x2A;(or display the product's embed modal)*
3. Do the same as above for various other stories. You can have a story for your products, customer reviews, upcoming product drops, and so on

***

## Creating Stories [#creating-stories]

<img src="`${docsBasePath}/images/stories-dashboard.png`" alt="Stories in Dashboard" className="rounded-xl w-full shadow-lg" />

1. Navigate to [the Stories dashboard by clicking here](https://sell.app/dashboard/stories).
2. Click on the "New Story" button to create your first story
3. Add a title, choose whether the story is public or hidden, then upload up to 30 media files. Each media file:
   1. Will be played one after the other
   2. Can be linked to a unique product
   3. Can have a different "Call to action" text
4. You can preview the story before publishing it
5. You can sort media files to your liking, the story will play the media in the order you've sorted
6. You can also sort each story to your liking. The order in which you sort a story will be shown when you create the Stories block in the builder.

That's it. You've now created one or multiple Stories. Now, head to the builder to display your Stories block.

***

## Displaying Stories [#displaying-stories]

<img src="`${docsBasePath}/images/stories-builder.png`" alt="Stories in Builder" className="rounded-xl w-full shadow-lg" />

1. Navigate to [the storefront builder by clicking here](https://builder.sell.app).
2. Click on the relevant section within which you want to add the "Stories" block
3. Click the "Add block" button in the left sidebar, then select the "Stories" option
4. The "Stories" block will be inserted into the section. Drag and drop it to whichever place you prefer, the whole section is your canvas. &#x2A;(Don't forget to check the mobile version of your page once done)*
5. If required, you can configure which story/stories to display by clicking on the "Stories" block and doing so in the left sidebar's "Stories Settings"

Once done, click the "Publish" button at the top right to publish your store's changes. You can then visit your site to see the stories block and interact with it.


# Upsells and Cross-Sells (/docs/upsells-cross-sells)



Upsells and cross-sells help customers choose a better option without making them hunt around your digital product store.

In SellApp, these live inside the product editor under **Marketing**.

***

## Featured variants [#featured-variants]

A featured variant highlights one variant on the product page as the recommended choice.

Open a product, expand **Marketing**, then choose a **Featured variant**. You can label it:

1. **Popular**
2. **Recommended**
3. **Best value**

Use this when one variant is the offer you most want customers to pick, like a lifetime plan, premium pack, larger quantity, bundled license, or best-margin option.

<Note>
  Featured variants are product-level recommendations. They point customers toward a variant of the product they are already viewing.
</Note>

***

## Similar products [#similar-products]

Similar products are cross-sells. They recommend products from elsewhere in your store alongside the current product.

Open a product, expand **Marketing**, then choose **Similar products**. If a product has multiple variants, choose the exact variant you want to recommend.

Use similar products for:

1. Products that solve the next problem.
2. Companion templates or files.
3. A cheaper starter product.
4. A higher-value product for customers who want more.
5. Product families that naturally belong together.

***

## Keep recommendations tight [#keep-recommendations-tight]

Do not recommend everything. Two or three strong cross-sells usually convert better than a long list of loosely related products.

Use the featured variant to guide the current product decision, then use similar products when the customer may want something adjacent.

If the extra should be attached to the same cart item, use [Add-ons](/add-ons) instead.


# Store Blacklist (/docs/blacklist)



The Blacklist helps you reduce fraud and abuse before it reaches checkout. Use it to block customers or traffic patterns that should not be allowed to buy from your store.

Open [Blacklist](https://sell.app/dashboard/blacklist) to manage entries.

***

## Blacklist types [#blacklist-types]

SellApp supports these blacklist types:

1. **Email** for a specific email address.
2. **Wildcard email** for a pattern across multiple emails.
3. **IP** for a specific IP address.
4. **Country** for country-level blocking.
5. **ASN** for blocking a network or hosting provider range.

Each entry also includes a description. Write the reason clearly so another team member understands why the block exists later.

***

## When to add an entry [#when-to-add-an-entry]

Add a blacklist entry when you see repeated fraud attempts, abuse, chargeback patterns, spam tickets, bot traffic, or traffic from a source that should never purchase.

Avoid overly broad blocks unless the risk is clear. A country or ASN block can stop legitimate customers too, so use specific email or IP blocks when the issue is narrow.

***

## Review periodically [#review-periodically]

Blacklist entries can outlive the original issue. Review older entries from time to time, especially broad wildcard, country, and ASN blocks.

If a real customer says they cannot checkout, check the Blacklist before assuming the payment method is failing. This can save time when troubleshooting blocked payments or failed purchase attempts.


# Payment Charges (/docs/charges)



Charges are standalone payment records. They are useful when you need to request a payment that is not tied to a normal storefront product flow, such as a custom invoice, service fee, balance collection, or manual deal.

Open [Charges](https://sell.app/dashboard/charges) to view them.

***

## What a charge includes [#what-a-charge-includes]

A charge can store:

1. Customer email.
2. Reference text.
3. Status.
4. Checkout URL.
5. Payment method and gateway data.
6. Currency and totals.
7. VAT and fee data.
8. Description, deliverable data, metadata, webhook, return URL, and cancel URL.

Use the reference field to make charges easy to recognize later.

***

## Charge statuses [#charge-statuses]

The Charges dashboard shows status, customer, revenue, and payment method. You can search by charge ID.

Pending or voided charges can be marked from the dashboard when the charge flow requires a manual status update. For higher-risk or larger flows, review the charge details before marking it completed.

***

## When to use charges [#when-to-use-charges]

Use charges when the customer should pay a specific amount without browsing a public product page. They can help with manual payment flows, custom work, one-off services, or payment links that should not become reusable storefront products.

Use products when the offer should be discoverable, reusable, and part of the normal storefront catalog.


# Orders and Customers (/docs/orders-and-customers)



The Orders and Customers dashboards are where you handle completed purchases, failed digital delivery, customer history, and sales exports.

***

## Orders [#orders]

Open [Orders](https://sell.app/dashboard/invoices) to search and review purchases.

You can search by:

1. Order ID or customer email.
2. Transaction ID.
3. Crypto transaction hash or address.
4. Coupon code.
5. Product name.
6. Serial code.
7. Additional information.
8. Discord customer data.

Use status and payment filters when you need to narrow the list quickly.

***

## Order actions [#order-actions]

From an order, you can inspect payment, customer, product, delivery, community access, and custom payment proof details.

If fulfillment failed, retry delivery from the order. SellApp will only retry affected delivery steps, so you can recover from temporary webhook, stock, license key, community access, or notification issues without recreating the whole order.

For custom payment methods, orders can require review before they are marked completed.

***

## Customers [#customers]

Open [Customers](https://sell.app/dashboard/customers) to search customer emails and review revenue per customer.

The customer slide-over helps you understand what someone bought, how much revenue they generated, and where you may need to support them. This is useful when a buyer asks about an order, a license key, a subscription, or access to a paid community.

***

## Exports [#exports]

Use sales and customer exports when you need reporting outside SellApp. Exports are useful for accounting, cohort analysis, campaign review, or reconciling activity with an external CRM.


# Support Tickets and Feedback (/docs/tickets-and-feedback)



Tickets and feedback help you keep ecommerce customer service and customer sentiment close to the orders that created them.

***

## Tickets [#tickets]

Open [Tickets](https://sell.app/dashboard/tickets) to manage support conversations.

Customers can create support tickets from the customer portal. Tickets include a title, customer information, optional order reference, status, and message thread.

From the dashboard, you can:

1. Read and reply as the store.
2. Close or reopen conversations.
3. Archive tickets you no longer need in the active view.
4. Follow the order reference when the ticket is tied to a purchase.

Keep replies specific and include the order context when possible. It saves back-and-forth and makes support feel less generic, especially for delivery, access, payment, or subscription questions.

***

## Feedback [#feedback]

Open [Feedback](https://sell.app/dashboard/feedback) to review customer ratings and messages.

You can search feedback, filter by star rating, sort the table, and jump back to the related order when you need more context.

Feedback is tied to the product, variant, and order when available, so it can help you spot issues like unclear digital delivery text, bad stock, confusing checkout fields, or products that need better setup instructions.

***

## Turn feedback into action [#turn-feedback-into-action]

Use feedback patterns to improve your store:

1. Repeated delivery confusion means the product instructions need work.
2. Repeated support tickets about the same issue may need an FAQ.
3. Positive feedback can become a story, testimonial, or storefront proof.
4. Low ratings on one variant may mean the offer or product copy is misaligned.


# Digital Product Delivery (/docs/digital-items)



Digital items are the deliverables attached to a variant. They decide what the customer receives after a successful payment, whether you sell downloadable files, license keys, serials, access codes, or generated products.

Open a product variant, then expand **Digital Items**.

***

## Digital Delivery Types [#digital-delivery-types]

SellApp supports these delivery types:

1. **Unique Codes & Serials** for text stock delivered one-by-one, such as keys, accounts, codes, or credentials.
2. **Downloadable Files** for files customers can download after payment.
3. **Dynamic Product** for webhook-based delivery where your system generates the product after SellApp pings it.
4. **Static Value** for manual services, links, instructions, or fixed text.
5. **License key** for generated software licenses with usage and expiration controls.

You can combine delivery types when a variant needs more than one kind of fulfillment.

***

## Unique codes and serials [#unique-codes-and-serials]

Use serials when each customer should receive unique stock. This works well for software keys, account credentials, coupon codes, gift codes, or any digital download that needs one unique value per order.

You can paste stock into the editor, upload stock, remove duplicates, and choose how SellApp should split the stock:

1. Comma
2. New line
3. Space
4. Custom delimiter

After saving, you can view, copy, and manage sold or unsold serials from the variant.

***

## Dynamic products [#dynamic-products]

Dynamic products are for custom fulfillment. SellApp sends a webhook to your endpoint, then your endpoint returns the delivered content.

Use this for generated accounts, custom keys, provisioning flows, or any product where stock should be created on demand instead of uploaded ahead of time.

Dynamic products are the best fit when your own system needs to decide what the buyer receives after checkout.

***

## License keys [#license-keys]

License keys are generated after purchase and can include:

1. A license prefix.
2. A usage limit.
3. An expiration length or unlimited duration.

After purchase, generated licenses appear in the Licenses dashboard where you can search, view customers, and manage usage.


# Storefront Groups and Sections (/docs/groups-and-sections)



Groups and sections help customers scan your digital product catalog without digging through every product.

Use sections for broad storefront areas, then use groups when several products belong together inside or across those sections.

***

## Sections [#sections]

Open [Sections](https://sell.app/dashboard/sections) to create and sort storefront sections.

A section can have:

1. A title.
2. Hidden or visible state.
3. Products assigned to it.
4. Groups assigned to it.
5. A custom order for how items appear.

Sections are best for high-level storefront organization, such as `Accounts`, `Templates`, `Software`, `Services`, `Memberships`, or `Bundles`.

***

## Groups [#groups]

Open [Groups](https://sell.app/dashboard/groups) to create product groups.

A group can have:

1. A title.
2. An optional image.
3. An unlisted state.
4. An assigned section.
5. A manually ordered product list.

Groups are useful when products share a theme but should not be merged into one product. For example, you might group several templates, server packages, account types, license packs, or add-on services.

***

## Product placement [#product-placement]

You can assign a product directly to a section from the product editor. You can also manage placement from the Sections and Groups dashboards when you want to organize many products at once.

Keep the storefront simple. Clear sections and groups help customers find the right digital product faster, while overloaded placement can make the catalog harder to trust.


# License Key Management (/docs/license-keys)



License keys are a digital item type for software, private tools, paid communities with external access, or any product that needs a unique key after purchase. SellApp handles license key generation and delivery, then gives you a dashboard for search, usage, and expiration management.

***

## Sell a license key product [#sell-a-license-key-product]

Open a product variant, expand **Digital Items**, then select **License key**.

Configure the license data:

1. Add a license prefix if you want keys to follow your brand or product naming.
2. Set a usage limit, or make the license unlimited.
3. Set an expiration length, or make the license unlimited.
4. Save the variant.

After purchase, SellApp generates and delivers the license key to the customer. This keeps license key management connected to the order, customer email, and product variant that produced the key.

***

## Manage licenses [#manage-licenses]

Open [Licenses](https://sell.app/dashboard/licenses) to see generated license keys.

The Licenses dashboard shows:

1. The license key with prefix.
2. Status.
3. Customer email.
4. Usage count and limit.
5. Expiration.

Use search when a customer sends you a key and you need to find the matching purchase quickly.

***

## License instances [#license-instances]

License instances track where a license has been used. This is useful when your app or external platform validates license keys and registers installs, devices, projects, or workspaces.

If a customer reaches their usage limit, review the license and its instances before increasing the limit or issuing a replacement.


# Products and Variants (/docs/products-and-variants)



Products are the main listings customers browse on your store. Variants are the purchasable options inside a product, such as different plans, quantities, packages, formats, subscriptions, or access levels.

Open [Products](https://sell.app/dashboard/listings) to create or edit a product.

***

## Digital Product Basics [#digital-product-basics]

The product editor controls the storefront page:

1. **Title and slug** for the product name and URL.
2. **Description** for the main product copy.
3. **Visibility** for whether the product is visible or hidden.
4. **Images** for the product gallery.
5. **Section** for storefront organization.
6. **Delivery text** for post-purchase instructions.
7. **FAQ** and extra product-page settings.

You can save a product as a draft while you are still preparing the listing.

***

## Variants [#variants]

Each product needs at least one variant before it is ready to sell. A variant controls the purchase details and delivery setup:

1. Title and short description.
2. Price and currency.
3. Single payment, subscription, or pay-what-you-want pricing.
4. Compare-at price for crossed-out pricing.
5. Accepted payment methods.
6. Minimum and maximum purchase quantity.
7. Volume discounts.
8. Digital items delivered after payment.

For subscriptions, SellApp currently shows subscription pricing when Stripe or PayPal is available for the store. Use separate variants when one listing needs both one-time digital downloads and recurring access.

***

## Payment methods per variant [#payment-methods-per-variant]

Variants can use different payment methods. For example, you can offer Stripe and PayPal on a subscription variant, while another one-time variant uses crypto, Cash App, or a custom payment method.

If you use custom payment methods, select the specific custom methods that should be allowed for the variant.

***

## Bulk updates [#bulk-updates]

The Products dashboard includes bulk actions for repeated product settings such as visibility, payment methods, redirect URLs, delivery text, FAQ, additional information, and Discord invite settings.

Use bulk updates when a setting should be consistent across many products, then edit individual products for exceptions. This is useful when you add a new payment method, change post-purchase redirects, or update delivery instructions across a large digital product catalog.


# Analytics Settings (/docs/analytics-settings)



Analytics settings let you connect storefront tracking for customer behavior, conversions, and advertising optimization.

Open [Analytics settings](https://sell.app/dashboard/settings?settings=analytics).

## Google Analytics 4 [#google-analytics-4]

Enter the GA4 **Measurement ID** and optional **API Secret**. The measurement ID identifies the Google Analytics property, and the API secret enables server-side event tracking.

If a secret is already saved, enter a new value to replace it or clear the saved measurement ID and secret.

## Meta Pixel [#meta-pixel]

Enter the Meta **Pixel ID** and optional **Access Token** to track conversions and build audiences for Facebook and Instagram advertising.

If a token is already saved, enter a new token to replace it or clear the saved Pixel ID and token.

## TikTok Pixel [#tiktok-pixel]

Enter the TikTok **Pixel ID** and optional **Access Token** to track conversions and optimize TikTok advertising campaigns.

If a token is already saved, enter a new token to replace it or clear the saved Pixel ID and token.

## When to configure analytics [#when-to-configure-analytics]

Configure ecommerce analytics tracking before you run paid campaigns or launch a new product. That gives you cleaner conversion data for product pages, checkout activity, and purchase events.


# Dashboard Customization (/docs/dashboard-customization)



Dashboard customization in SellApp is controlled by the dashboard date range, selected metric, dashboard timezone, dashboard currency, and analytics cards shown for the active store.

Open [the dashboard](https://sell.app/dashboard), then use [General settings](https://sell.app/dashboard/settings?settings=general) for timezone and currency defaults.

## Date range and metrics [#date-range-and-metrics]

Use the dashboard date picker to change the reporting window. Presets include today, last 7 days, last month, last quarter, last year, this month, all time, and custom ranges.

The main dashboard cards show revenue, orders, visitors, and conversion rate. Select a metric card to switch the chart to that metric.

## Timezone and display currency [#timezone-and-display-currency]

Set **Dashboard Timezone** in General settings so order dates, charge dates, license activity, sales reports, and other dashboard timestamps match the timezone your team uses.

Set **Dashboard Currency** so revenue and reporting views use your preferred display currency.

## Live visitors and analytics cards [#live-visitors-and-analytics-cards]

The dashboard includes live visitor count, top-performing products, top-performing payment processors, visitor analytics, traffic sources, locations, devices, and recent analytics snapshots when data is available.

Use these cards to understand which products, pages, campaigns, and payment methods are driving store activity.


# Delete Store Settings (/docs/delete-store-settings)



The **Other** settings tab contains destructive account or storefront actions that are only shown when your account has the required ownership access.

Open [Other settings](https://sell.app/dashboard/settings?settings=other).

## Delete a storefront [#delete-a-storefront]

If you own the current storefront, the Other tab can show the delete-store form. Use it only when you are certain the storefront should be removed.

Before deleting a store, review any products, orders, customers, custom domains, payment settings, webhooks, affiliate data, and customer support history that you may need later.

## Before using destructive actions [#before-using-destructive-actions]

Destructive settings can affect customer access and your ability to operate the store. Confirm that you are in the correct storefront, then make sure no active sales, subscriptions, community access grants, or support workflows depend on it.

If you only need to stop new purchases, consider setting the store visibility to **Private Store** in [General Store Settings](/general-store-settings) instead of deleting the storefront.


# Developer Settings (/docs/developer-settings)



Developer settings control the webhook and API tooling used to automate your SellApp store.

Open [Developer settings](https://sell.app/dashboard/settings?settings=developers).

## Webhooks [#webhooks]

Use webhooks when an external system needs to receive store events. You can create webhook endpoints, edit existing endpoints, test delivery, and review recent webhook deliveries.

Webhook delivery logs help you debug endpoint status, payloads, and recent failures without guessing whether SellApp sent an event.

## Webhook secret [#webhook-secret]

Generate a webhook secret when your endpoint needs to verify that incoming requests came from SellApp.

Use the secret to validate signed webhook requests before creating accounts, granting access, updating stock, or trusting an incoming order event.

For dynamic product delivery, see [Dynamic Webhook Setup](/setting-up-dynamic-webhook).

## API tokens [#api-tokens]

Use API tokens when your own system needs scoped API access to SellApp. Create tokens only for the systems that need them, and delete old tokens when they are no longer used.

Keep webhook secrets and API tokens private. Rotate them if they are exposed or copied into a place your team does not control.


# General Store Settings (/docs/general-store-settings)



General store settings control the basics of your SellApp storefront and dashboard defaults.

Open [General settings](https://sell.app/dashboard/settings?settings=general).

## Store visibility [#store-visibility]

Choose how customers can access the store:

1. **Public Store**: accessible to anyone. Products are visible and can be purchased.
2. **Hidden Store**: accessible to anyone with a link. Products can be purchased.
3. **Private Store**: inaccessible. Products are invisible and cannot be purchased.

Use Hidden when you want a private launch link, and Private when the store should stop accepting purchases.

## Store name and URL [#store-name-and-url]

Update the store name shown in the dashboard and storefront. The SellApp subdomain is shown in the Store URL field so you can confirm the active storefront address.

For a branded domain, use [custom domain setup](/linking-custom-domain).

## Dashboard timezone and currency [#dashboard-timezone-and-currency]

Choose the dashboard timezone used for dates in orders, charges, sales, licenses, and other store activity. Choose the dashboard currency used for reporting and dashboard metrics.

These settings help teams read reports in their operating timezone and preferred display currency.

## Checkout color scheme [#checkout-color-scheme]

Use **Checkout color scheme** to follow the customer's system theme or force checkout into dark or light mode.


# Payment Functionality Settings (/docs/payment-functionality-settings)



Payment functionality settings control checkout behavior around customer data, taxes, risk checks, cart behavior, email delivery, and rate limiting.

Open [Payment settings](https://sell.app/dashboard/settings?settings=payment), then use **Payment Functionality**.

## Checkout and customer details [#checkout-and-customer-details]

Use these settings to decide what checkout asks for and how orders are processed:

1. **Collect Billing Details** asks customers for billing details during checkout.
2. **Enable VAT** collects VAT during checkout.
3. **VAT inclusive product pricing** includes VAT in product prices instead of adding it on top.
4. **Disable Checkout Email** stops asking customers for an email address during checkout. Delivery emails cannot be sent when no customer email is available.
5. **Send Delivery Email** controls whether SellApp sends the delivery email after purchase.

Use billing details and VAT settings when your tax, invoicing, or processor workflow requires them.

## Store risk and cart controls [#store-risk-and-cart-controls]

Use **Blacklist On Dispute** to automatically blacklist a customer's email and IP if they open a dispute.

Use **Allow VPN Purchases** when customers using a VPN or proxy should still be allowed to buy. Leave stricter risk controls in place when fraud prevention is more important than allowing VPN traffic.

Use **Disable Shopping Cart** when customers should buy one product at a time instead of building a cart.

## Minimum spend and descriptor [#minimum-spend-and-descriptor]

Use **Minimum Spend** to require customers to spend at least a certain amount before checkout.

Use **Customize Billing Descriptor** to change the text customers see while checking out. The descriptor is limited to 20 characters.

## Checkout rate limits [#checkout-rate-limits]

Checkout rate limits control invoice creation attempts per store. You can set:

1. Customer attempts per hour for the same IP and email combination.
2. Optional limits per IP.
3. Optional limits per email.
4. Optional limits per checkout session fingerprint.
5. A window in seconds before attempts are allowed again.

Leave optional limits empty to disable them. Use stricter limits when you see repeated checkout abuse or bot-created invoices.

## Crypto checkout settings [#crypto-checkout-settings]

If your store has crypto wallets enabled, extra settings can appear:

1. **Underpaid Percentage** for the allowed underpayment threshold.
2. **Minimum Confirmations** for the number of block confirmations required before an order processes.

Use these settings carefully because they affect when crypto orders move forward to delivery.


# Personalization Settings (/docs/personalization-settings)



Personalization settings control customer-facing support details, invoice business information, review invitations, return links, custom email, and custom domains.

Open [Personalization settings](https://sell.app/dashboard/settings?settings=personalization).

## Support and review settings [#support-and-review-settings]

Set **Support Email** to show customers where they can contact you for help.

Set **Trustpilot Email** when you want Trustpilot to send post-purchase review invitations from SellApp delivery emails. See [Trustpilot Review Invitations](/trustpilot) for the full setup flow.

If your store has a custom email connected, use **Email Sender Name** to control the sender name shown in customer emails. Leave it blank to use SellApp.

## Business details for invoices [#business-details-for-invoices]

Business details are displayed on invoices. You can set:

1. Address.
2. City.
3. State.
4. ZIP.
5. Country.
6. Tax information.

Add the business details your customers or tax workflow need to see on receipts and invoices.

## Custom return link [#custom-return-link]

Use **Customize Return Link** to change the label and URL for the Back button on product and checkout pages.

If you leave it empty, the Back button automatically redirects to the store's home page.

## Custom email and custom domains [#custom-email-and-custom-domains]

Use **Custom Email** to send transactional emails from your own email address.

Use custom domains when your storefront should live on your own domain. See [Link a Custom Domain](/linking-custom-domain) for DNS, CNAME, TXT, and SSL setup.


# Staff Settings (/docs/staff-settings)



Staff settings control who can help manage your SellApp storefront.

Open [Staff settings](https://sell.app/dashboard/settings?settings=staff).

## Invite staff [#invite-staff]

Use the Staff tab to invite team members who need access to the storefront dashboard. Send invites only to people who should help manage products, orders, customers, payments, support, or settings.

Before inviting someone, decide what operational access they need and whether they should be trusted with sensitive areas like payment settings, developer tools, customer data, and staff management.

## Review team access [#review-team-access]

Review staff access when someone changes roles, leaves the team, or no longer needs dashboard access.

Remove users who should not be able to view store data or make changes. Keeping the staff list current helps protect order data, customer information, and payment configuration.

## Access denied states [#access-denied-states]

If a user cannot view settings, they may not have permission to update the current storefront. Ask a store owner or admin to review their team access.


# Storefront Settings (/docs/storefront-settings-introduction)



Storefront settings control how your SellApp store appears, how checkout behaves, which integrations run, and which dashboard defaults your team uses.

Open [Settings](https://sell.app/dashboard/settings) from the SellApp dashboard.

## Settings tabs [#settings-tabs]

The settings page is organized into tabs:

1. **General** for visibility, store name, dashboard timezone, dashboard currency, and checkout color scheme.
2. **Payment** for payment methods, billing details, VAT, checkout rules, minimum spend, rate limits, and crypto checkout controls.
3. **Notifications** for Discord and email notification channels.
4. **Analytics** for Google Analytics 4, Meta Pixel, and TikTok Pixel tracking.
5. **Personalization** for support email, Trustpilot, business invoice details, return links, custom email, and custom domains.
6. **Affiliates**, **Community**, and **Marketing** for growth and access settings.
7. **Staff** for team member access.
8. **Developers** for webhooks, webhook secrets, recent deliveries, and API tokens.
9. **Other** for destructive store actions shown to store owners.

## Where to start [#where-to-start]

Start with General settings and Payment settings before publishing a store. Then configure Analytics, Personalization, Notifications, and Developer settings based on how your store handles tracking, customer support, and automation.

Use the dedicated docs in this section for settings that affect checkout behavior, reporting, customer emails, team access, developer automation, and operational risk.


# Authorize.net Payments (/docs/authorize)



[Authorize.net](https://www.authorize.net/) is a card payment processor that lets customers pay with their credit or debit card.

SellApp has integrated Authorize.net as a payment processor, helping you accept card payments through Authorize.net for your digital products via the SellApp storefront and API. Use it when you already process cards through Authorize.net and want SellApp to handle checkout, order tracking, and delivery.

***

## Link Authorize.net to SellApp [#link-authorizenet-to-sellapp]

1. Navigate to [your storefront payment settings by clicking here](https://sell.app/dashboard/settings?settings=payment).
2. Click "Card (Authorize.net)". In the modal that appears, enter the requested credentials:
   1. You were provided your "API Login ID" and "Transaction Key" when first signing up to Authorize.net
   2. Generate a "Signature Key" by logging into the [Merchant Interface](https://login.authorize.net/) -> Click the "Account" tab -> click "API Credentials & Keys" in the "Security Settings" section
      * Finally, create the "Signature Key" and enter it on the SellApp side
      * This page also shows your API Login ID and optionally lets you create a new "Transaction Key"
3. Optionally add a discount/fee if you want to adjust the checkout total for customers who pay with Authorize.net.
4. Save the settings. If all details were entered correctly, you'll now see "Card (Authorize.net)" as "Active" in the payment settings.

All done. Authorize.net has been enabled for your store and you can now enable Authorize.net for every new product you create.

***

## Optionally: Enabling Authorize.net for products that already exist [#optionally-enabling-authorizenet-for-products-that-already-exist]

If you want to enable Authorize.net for products that already exist, here's how to do so:

1. Navigate to [your products dashboard by clicking here](https://sell.app/dashboard/listings).
2. On the products page, toggle the checkboxes of the products you want to enable Authorize.net for.
3. Open the "Bulk update" dropdown and click "Payment methods".
   * A modal will pop up; check "Card (Authorize.net)" &#x2A;(& optionally other payment methods you'd like enabled)*
4. Finally, click "Update All" in the modal to update the products' payment methods.

That's all done for you: all the products you selected will now have Authorize.net enabled as a payment method, which customers will be able to select when making a purchase.


# Cash App Payments (/docs/cashapp)





[Cash App](https://cash.app/) is a P2P payment service that lets users transfer money to one another via a mobile app.

SellApp has integrated Cash App as a payment processor, which means you can accept Cash App payments for your digital products through the SellApp storefront and API. The key setup step is email forwarding, which lets SellApp detect eligible Cash App receipts and process orders automatically.

***

## Step 1: Link email [#step-1-link-email]

The first step is to add an email address to your Cash App account if you haven't done so already:

1. [Sign in to Cash App on your computer](https://cash.app/account/activity)

<img src="`${docsBasePath}/images/cashapp/account_step.png`" alt="SellApp Dashboard" className="rounded-xl w-1/2 mx-auto shadow-lg dark:shadow-black" />

2. [Go to your account settings](https://cash.app/account/settings)

<img src="`${docsBasePath}/images/cashapp/email_step.png`" alt="SellApp Dashboard" className="rounded-xl w-1/2 mx-auto shadow-lg dark:shadow-black" />

3. In the "Personal info" section, you should see your email address
4. If it's not there, click the "add" button and follow the steps to enter your personal email address
   * *Don't forget to verify your email with the code Cash App sends you*

***

## Step 2: Forward Cash App emails to SellApp [#step-2-forward-cash-app-emails-to-sellapp]

<Warn>
  Without the forwarding rule added, SellApp cannot detect or process Cash App payments automatically, so make sure to add it.
</Warn>

Here's how to do so with a `@gmail.com` email address:

1. [Click here to open your gmail settings](https://mail.google.com/mail/u/0/#settings/general).
2. Click the "Forwarding and POP/IMAP" tab &#x2A;(the 6th tab at the top)*

<img src="`${docsBasePath}/images/cashapp/tab_step.png`" alt="SellApp Dashboard" className="rounded-xl w-1/2 mx-auto shadow-lg dark:shadow-black" />

3. Click the "Add a forwarding address" button
4. In the modal that appears, enter `<cash@payments.sell.app>` as the forwarding address

<img src="`${docsBasePath}/images/cashapp/forwarding_step.png`" alt="SellApp Dashboard" className="rounded-xl w-1/2 mx-auto shadow-lg dark:shadow-black" />

5. Once you click the "Next" button, Gmail will send our systems an email with a confirmation URL. We automatically forward the URL to your email. Visit this URL and you will be good to go.
6. Once verified, we need to create a filter to only forward emails from Cash App to the email we just linked:

   1. In Gmail, [go to the "Forwarding" section by clicking here](https://mail.google.com/mail/u/0/#settings/fwdandpop)

   <img src="`${docsBasePath}/images/cashapp/filter_step.png`" alt="SellApp Dashboard" className="rounded-xl w-1/2 mx-auto shadow-lg dark:shadow-black" />

   2. Click the blue "creating a filter!" text to open the filter modal
   3. In the filter modal that pops up, enter `<cash@square.com>` in the "From" field, then click the "Create filter" button

   <img src="`${docsBasePath}/images/cashapp/from_step.png`" alt="SellApp Dashboard" className="rounded-xl w-1/2 mx-auto shadow-lg dark:shadow-black" />

   4. In the next page, select the "Forward it to" option, and select `<cash@payments.sell.app>` as the forwarding address

   <img src="`${docsBasePath}/images/cashapp/to_step.png`" alt="SellApp Dashboard" className="rounded-xl w-1/2 mx-auto shadow-lg dark:shadow-black" />

   5. Finally, click "Create filter"

If your Cash App receipt emails come from an `@notifications.cash.app` address instead, add that sender to your forwarding filter too. The goal is simple: Cash App receipt emails should forward to SellApp, but the rest of your inbox should not.

***

## Step 3: Link Cash App to SellApp [#step-3-link-cash-app-to-sellapp]

The final step is to add your Cash App details to your SellApp storefront:

1. Navigate to [your storefront payment settings by clicking here](https://sell.app/dashboard/settings?settings=payment).
2. Click Cash App. In the modal that appears, enter your Cash Tag &#x2A;(including the `$`)* and **the email address you added to your Cash App in step 1**.
3. Follow the forwarding step in the modal, confirm your information, then click "Finish". If all details were entered correctly, you'll now see Cash App as "Active" in the payment settings.

All done. Cash App has been enabled for your store and you can now enable Cash App for every new product you create.

***

## Optionally: Enabling Cash App for products that already exist [#optionally-enabling-cash-app-for-products-that-already-exist]

If you want to enable Cash App for products that already exist, here's how to do so:

1. Navigate to [your products dashboard by clicking here](https://sell.app/dashboard/listings).
2. On the products page, toggle the checkboxes of the products you want to enable Cash App for.
3. Open the "Bulk update" dropdown and click "Payment methods".
   * A modal will pop up; check Cash App &#x2A;(& optionally other payment methods you'd like enabled)*
4. Finally, click "Update All" in the modal to update the products' payment methods.

That's all done for you: all the products you selected will now have Cash App enabled as a payment method, which customers will be able to select when making a purchase.


# Crypto Payments Overview (/docs/crypto)





Crypto payment setup now has its own documentation section with one page for each supported crypto method.

Start with [Crypto Payment Methods](/crypto-payment-methods-introduction) to choose between direct wallets, stablecoins, Solana, and Crypto Tokens.

<img src="`${docsBasePath}/images/crypto.webp`" alt="Cryptocurrency" className="rounded-xl w-full shadow-lg" />

***

## Supported crypto payment docs [#supported-crypto-payment-docs]

<Cards>
  <Card title="Bitcoin Payments" href="/bitcoin-payments">
    Connect a BTC XPUB and enable Bitcoin checkout.
  </Card>

  <Card title="Ethereum Payments" href="/ethereum-payments">
    Connect an ETH wallet and enable Ethereum checkout.
  </Card>

  <Card title="Solana Payments" href="/solana-payments">
    Connect a SOL wallet and enable Solana checkout.
  </Card>

  <Card title="Crypto Tokens" href="/crypto-tokens">
    Let buyers pay with a broad token selection and settle to an eligible wallet.
  </Card>
</Cards>

Open [Payment settings](https://sell.app/dashboard/settings?settings=payment), then scroll to **Cryptocurrencies**.

***

## Optionally: Enabling crypto for products that already exist [#optionally-enabling-crypto-for-products-that-already-exist]

If you want to enable crypto for products that already exist, here's how to do so:

1. Navigate to [your products dashboard by clicking here](https://sell.app/dashboard/listings).
2. On the products page, toggle the checkboxes of the products you want to enable crypto for.
3. Open the "Bulk update" dropdown and click "Payment methods".
   * A modal will pop up; check the relevant crypto option &#x2A;(, as well as all other payment methods you'd like enabled)*
4. Finally, click "Update All" in the modal to update the products' payment methods.

That's all done for you: all the products you selected will now have crypto enabled as a payment method, which customers will be able to select when making a purchase.

***

## Support: How to find Extended Public Key &#x2A;(XPUB)* for Bitcoin and/or Litecoin [#support-how-to-find-extended-public-key-xpub-for-bitcoin-andor-litecoin]

For certain crypto, SellApp generates new payment addresses for every order created. These addresses are generated via the extended public key (xpub/zpub/ypub) that you link to your store.

The benefits of linking an XPUB to your SellApp store:

1. SellApp does not require access to your private keys, meaning there is zero risk of something going wrong.
2. Bitcoin/Litecoin payments go directly to your wallet. We do not hold the crypto or run a separate SellApp payout.
3. Enhanced privacy as every new order created generates a fresh address

<Warn>
  We **strongly** recommend using either Exodus or Electrum. **Other wallets, such as Ledger, are known to cause issues** and **may result in funds not being accessible** unless you're technical
</Warn>

**Where to find xpub in Exodus:**

<Note>
  When exporting your XPUB from Exodus for Bitcoin, **make sure to use the second XPUB in the list, which starts with a ZPUB**
</Note>

<img src="`${docsBasePath}/images/exodus-xpub-desktop.png`" alt="Exodus Xpub Option" className="rounded-xl w-full shadow-lg" />

1. Open your Exodus desktop wallet app &#x2A;(Note, the mobile wallet does not have this option)*
2. Navigate to the Bitcoin or Litecoin wallet in the app
3. Click the three dots at the top right, then select "Export XPUB" to download your xpub/zpub/ypub key.
4. Copy the xpub/zpub/ypub key from the exported file and paste it [into your SellApp Bitcoin/Litecoin wallet settings](https://sell.app/dashboard/settings?settings=payment)
   * **Copy and paste the second option for Bitcoin, which starts with a ZPUB**

**Where to find xpub in Electrum Wallet:**

<img src="`${docsBasePath}/images/xpub-electrum.png`" alt="Electrum Xpub Option" className="rounded-xl w-full shadow-lg" />

1. Open your Electrum app.
2. Navigate to "Wallet" -> "Information".
3. A modal will appear. The second text area should be titled as "Master Public Key". In the text area itself, it should show your public key that starts with "xpub", "zpub", or "ypub"
4. Copy the xpub/zpub/ypub key and paste it [into your SellApp Bitcoin/Litecoin wallet settings](https://sell.app/dashboard/settings?settings=payment)

**Where to find xpub in Coinbase, Binance, Trust Wallet, Kraken, etc.:**

These providers hold funds on your behalf, so you don't have an actual wallet with them. This means that you can't retrieve an "xpub", "zpub", or "ypub" key from them.

If this is the case, we'd recommend downloading [Electrum](https://electrum.org) or [Exodus](https://exodus.com/) to use as your SellApp wallet.

***

## Support: I didn't receive the funds in my wallet [#support-i-didnt-receive-the-funds-in-my-wallet]

There are two possible reasons why you don't see the funds you've received:

1. You manually marked an order as completed. **Orders should never be marked as completed unless you're absolutely certain you've received the funds**
2. You copy/pasted an XPUB from a wallet other than Electrum/Exodus

In the first case, this is a user error as funds might never have been sent by the customer. We cannot assist in this scenario, as the payment very likely does not exist.

In the second case, you will want to export your seed and import it into [Electrum](https://electrum.org). Then, you'd need to scan the derivations and/or set the derivation path manually.

To see what derivation path your funds are in, we suggest using the following Trezor link: [https://btc1.trezor.io/xpub/EnterYourXpubHere](https://btc1.trezor.io/xpub/EnterYourXpubHere)

The above link will show all of the payments your XPUB has received, and the derivation path for each address.


# Custom Payment Methods (/docs/custom-payment-methods)



Custom Payment Methods let you accept payments through your own manual or external process while still tracking the order inside SellApp. They are useful when your preferred local wallet, bank transfer, private processor, or manual crypto flow is not available as a native integration.

Use them for any payment process where SellApp should create a pending order for you to verify before digital product delivery is completed.

***

## Create a custom processor [#create-a-custom-processor]

Open [Payment settings](https://sell.app/dashboard/settings?settings=payment), then open **Custom Processors** and click **Add method**.

Choose one of two processor flows:

1. **Instruction-based:** SellApp shows payment instructions on checkout.
2. **Redirect-based:** SellApp sends the customer to your own payment page.

Then add the payment method name, optional icon, and the details for that flow.

***

## Instruction-based methods [#instruction-based-methods]

Use instruction-based methods when the customer should read payment details on the SellApp checkout page.

You can add:

1. A short description.
2. Rich instructions.
3. Up to three checkout steps.
4. Proof of payment upload.
5. A customer preview before saving.

If proof is required, the customer can submit text or a screenshot. The order will stay pending until you review it.

***

## Redirect-based methods [#redirect-based-methods]

Use redirect-based methods when you already have a hosted payment page.

Add a redirect URL and include variables when your external flow needs order context. SellApp supports variables like:

1. `{id}`
2. `{invoice_id}`
3. `{customer_email}`
4. `{currency}`
5. `{price}`
6. `{price_usd}`
7. `{product_name}`
8. `{quantity}`

For example, your redirect URL might include the order ID and price so your external page can prefill the checkout.

***

## Enable on products [#enable-on-products]

When saving a custom processor, you can enable it on all current products. You can also control custom payment methods per variant from the product editor.

Custom processor orders require manual review. Open the order, confirm payment, then mark it completed when the payment is valid. Keep the instructions clear so customers know exactly where to pay, what proof to upload, and when they should expect their order to be reviewed.


# NMI Payment Gateway Setup (/docs/nmi)



NMI lets you accept debit and credit card payments for digital products through your own NMI payment gateway account. Connect NMI when you want card checkout handled through your merchant account while SellApp manages the order, delivery, and product-level payment settings.

***

## Add NMI [#add-nmi]

Open [Payment settings](https://sell.app/dashboard/settings?settings=payment), then open **NMI**.

Enter:

1. Merchant secure key.
2. Merchant tokenization key.
3. Webhook signing key.
4. At least one supported currency.

Then save the method.

<Note>
  NMI credentials must match the expected key formats. If SellApp rejects a key, copy it again from your NMI account and make sure there are no extra spaces.
</Note>

***

## Enable NMI on products [#enable-nmi-on-products]

When adding NMI, you can enable it for all existing products. You can also manage payment methods per variant from the product editor or with the Products dashboard bulk payment-method update.

Use product-level controls when only certain listings should accept NMI card payments. For example, you might keep NMI enabled on high-volume digital downloads while leaving another payment method on subscription or manual-review products.

After NMI is removed, SellApp removes unavailable payment methods from variants so customers are not offered a broken checkout option.

***

## Fees or discounts [#fees-or-discounts]

Once NMI is active, you can add a payment-method fee or discount.

Use a positive value to discount NMI payments. Use a negative value to charge an extra fee.

For example:

1. `10` in the percentage field gives a 10% discount.
2. `-10` in the percentage field adds a 10% fee.
3. `5` in the fixed field gives a fixed discount.
4. `-5` in the fixed field adds a fixed fee.

***

## Configuration issues [#configuration-issues]

If NMI authentication fails during checkout, SellApp can flag the configuration issue so you know the payment method needs attention.

Check the merchant secure key, tokenization key, signing key, and enabled currencies before sending customers back through checkout.


# Paddle Payments (/docs/paddle)



SellApp makes it easy to link your [Paddle](https://paddle.com/) account and start accepting card, wallet, and other Paddle-supported payment types for your digital products. Use Paddle when you want Paddle Billing or an existing Paddle Classic account to process orders while SellApp manages the storefront and product delivery.

***

## Before you start [#before-you-start]

Paddle needs to send SellApp a webhook when a transaction is completed. &#x2A;*Without this, payments will not automatically process.**

In Paddle, create a webhook/notification destination that points to:

```txt
https://sell.app/paddle/webhook
```

For Paddle Billing, make sure the destination sends the `transaction.completed` event, then copy the webhook secret. You'll paste that secret into SellApp in the next step.

***

## Linking Paddle [#linking-paddle]

Now we can link Paddle to your SellApp storefront:

1. Navigate to [your storefront payment settings by clicking here](https://sell.app/dashboard/settings?settings=payment).
2. Click "Paddle" to open the modal. The "Paddle Billing" tab is selected by default.
3. Enter your Paddle Billing credentials:
   1. **API Key**: starts with `pdl_`
   2. **Client-side Token**: starts with `test_` or `live_`
   3. **Webhook Secret**: the secret from the Paddle webhook/notification destination you created above
4. Optionally add a discount/fee if you want to adjust the checkout total for customers who pay with Paddle.
5. Save the settings by clicking "Save" in the SellApp modal.

That's it. Paddle has been enabled for your store and you can now enable Paddle for every new product you create.

***

## Paddle Classic [#paddle-classic]

Only use the "Paddle Classic" tab if your store already uses the old Paddle Classic integration.

Classic asks for:

1. **Vendor ID**
2. **Vendor Auth Code**
3. **Public Key*&#x2A; &#x2A;(copy the full key, including `-----BEGIN PUBLIC KEY-----` and `-----END PUBLIC KEY-----`)*

New Paddle setups should use Paddle Billing instead.

***

## Optionally: Enabling Paddle for products that already exist [#optionally-enabling-paddle-for-products-that-already-exist]

If you want to enable Paddle for products that already exist, here's how to do so:

1. Navigate to [your products dashboard by clicking here](https://sell.app/dashboard/listings).
2. On the products page, toggle the checkboxes of the products you want to enable Paddle for.
3. Open the "Bulk update" dropdown and click "Payment methods".
   * A modal will pop up; check Paddle &#x2A;(& optionally other payment methods you'd like enabled)*
4. Finally, click "Update All" in the modal to update the products' payment methods.

That's all done for you: all the products you selected will now have Paddle enabled as a payment method, which customers will be able to select when making a purchase.


# Payment Methods for Digital Products (/docs/payment-methods-introduction)



Use this page to add, remove, and manage payment methods for your SellApp storefront. SellApp supports card processors, PayPal, Cash App, crypto wallets, merchant-of-record providers, NMI, and custom payment methods so you can choose the checkout options that fit your digital products.

***

## Where can I add or remove a payment method? [#where-can-i-add-or-remove-a-payment-method]

You can add/remove payment methods in your SellApp storefront's payment settings.

If you don't know where that is, [here's a link to your storefront's payment settings](https://sell.app/dashboard/settings?settings=payment).

***

### How do I add or remove a payment method? [#how-do-i-add-or-remove-a-payment-method]

Each payment method has its own setup flow. Start with the method you want to enable:

<Cards>
  <Card title="Authorize.net" href="/authorize">
    Accept credit and debit card payments through Authorize.net.
  </Card>

  <Card title="CashApp" href="/cashapp">
    Configure Cash App and email forwarding so payments process automatically.
  </Card>

  <Card title="Crypto Payment Methods" href="/crypto-payment-methods-introduction">
    Link direct wallets, stablecoins, Solana, and Crypto Tokens.
  </Card>

  <Card title="Custom Payment Methods" href="/custom-payment-methods">
    Create instruction-based or redirect-based manual payment flows.
  </Card>

  <Card title="NMI" href="/nmi">
    Accept debit and credit card payments through NMI.
  </Card>

  <Card title="Paddle" href="/paddle">
    Connect Paddle and register the SellApp webhook endpoint.
  </Card>

  <Card title="PayPal" href="/paypal">
    Link PayPal directly or enable it with your PayPal email address.
  </Card>

  <Card title="Square" href="/square">
    Add your Square access token and location ID.
  </Card>

  <Card title="Stripe" href="/stripe">
    Complete Stripe onboarding and enable it for your products.
  </Card>
</Cards>

Your payment settings may also show extra options like Paystack, Venmo, and crypto token swaps depending on what is available for your store. Those follow the same pattern: open the method, add the required account or wallet details, choose any fee or discount, and save it.

For most digital product stores, start with one card or wallet option, then add alternatives after your first sales. More payment methods can increase buyer choice, but each processor still needs correct credentials and product-level enablement.

***

## How do I enable or disable a payment method for all of my products? [#how-do-i-enable-or-disable-a-payment-method-for-all-of-my-products]

There are two ways to enable or disable a payment method for all products at once:

1. Via the [storefront payment settings](https://sell.app/dashboard/settings?settings=payment):
   1. To enable: When adding a payment method, in the payment method's popup modal, toggle "Enable X &#x2A;(where X is the payment method)* for all existing products?" on before clicking save.
   2. To disable: Remove the payment method by emptying the respective modal's input and saving. Once done, the payment method should say "Not configured" which in turn will have disabled it for all existing products that had the payment method enabled.
2. Via [your product dashboard](https://sell.app/dashboard/listings)
   1. Click the checkbox for the products on the left hand side
   2. Click "Select all" if you'd like to apply this change to all existing products in your storefront
   3. Open the "Bulk update" dropdown and click "Payment methods"
   4. Toggle the payment methods you would like to accept on &#x2A;(or keep the one you don't want to accept unchecked)*
   5. Once you click "Update All", all of the selected products will be updated to only the ones you've toggled on in step 4.

***

## How do I get my earnings? [#how-do-i-get-my-earnings]

For normal storefront orders, SellApp does not hold your money or make you wait until a specific payout date for your earned funds.

The customer does not pay our account. Instead, the money is sent from them to your linked payment processor or wallet.

That means access to the funds is handled by the payment method you enabled, not by a SellApp payout schedule.


# PayPal Payments for Digital Products (/docs/paypal)



SellApp makes it easy to link your [PayPal](https://www.paypal.com/) account and start accepting PayPal payments for your digital products. Use PayPal when customers prefer wallet checkout and you want orders tracked inside SellApp.

***

## Linking PayPal [#linking-paypal]

1. Navigate to [your storefront payment settings by clicking here](https://sell.app/dashboard/settings?settings=payment).
2. You will find a "PayPal" button. Click it, then click "Connect your PayPal account".
3. You will be redirected to PayPal and asked to give SellApp the required permissions.
4. When you are redirected back to SellApp, your PayPal account will be linked with your store.
5. If SellApp shows an action-required warning, follow it before taking live payments. This can happen if your PayPal email is not confirmed or your PayPal account is restricted from receiving payments.
6. Optionally add a discount/fee if you want to adjust the checkout total for customers who pay with PayPal.

That's it. PayPal has been enabled for your store and you can now enable PayPal for every new product you create.

***

## Optionally: Enabling PayPal for products that already exist [#optionally-enabling-paypal-for-products-that-already-exist]

If you want to enable PayPal for products that already exist, here's how to do so:

1. Navigate to [your products dashboard by clicking here](https://sell.app/dashboard/listings).
2. On the products page, toggle the checkboxes of the products you want to enable PayPal for.
3. Open the "Bulk update" dropdown and click "Payment methods".
   * A modal will pop up; check PayPal &#x2A;(& optionally other payment methods you'd like enabled)*
4. Finally, click "Update All" in the modal to update the products' payment methods.

That's all done for you: all the products you selected will now have PayPal enabled as a payment method, which customers will be able to select when making a purchase.

***

## Support: Pending PayPal payments [#support-pending-paypal-payments]

There are two types of pending PayPal payment types:

1. A pending payment where you have to accept the money on your account before the order can get processed
   1. This is due to your PayPal account not having the respective balance enabled which the customer paid with.
      * For example: if you live in the EU and only have an Euro balance enabled on your account, but then sign up to SellApp and list a product in USD, the money will be sent as USD
      * Since PayPal does not know whether you want to reject the payment, or whether you'd like to convert the USD earnings into Euro, or whether you'd like to open a separate USD balance, this payment will be set as pending until you decide
   2. The solution here is to either open a USD balance &#x2A;(it's free to open as many balances on PayPal as you'd like)*, or price your product in a currency your PayPal account has a balance opened for.
      * We strongly advise applying the solution as fast as possible, as each and every order made via SellApp will continue to remain stuck and not process until you accept/convert the payment.
2. A pending payment that has been completed on SellApp's side, but the money being held by PayPal for 1/3/7 days
   1. This is due to an internal system on PayPal's end.
      * If you're a new seller, or a seller who hasn't had activity on PayPal in a long time, they may temporarily place you into this system.
      * We at SellApp can't influence anything on this end, it's a seemingly arbitrary decision applied by PayPal
   2. The solution here is to wait it out. After a handful of successful sales with no disputes, PayPal will move you out of their system and you'll be able to accept payments instantly.


# Square Payments (/docs/square)



SellApp makes it easy to link your [Square](https://square.com/) account and start accepting credit or debit card, Cash App Pay, Apple Pay, Google Pay, and other Square-supported payment types for your digital products.

***

## Linking Square [#linking-square]

Here's how to link Square to your SellApp account:

1. Navigate to [your storefront payment settings by clicking here](https://sell.app/dashboard/settings?settings=payment).
2. You will find a "Square" button. Click it to open the modal which displays **two** input fields: "**Access token**" and "**Location ID**".
   1. [You can find your access token by clicking here](https://developer.squareup.com/apps). If you don't have an app yet, click "Create App" and copy the provided token.
   2. [You can find your location ID by clicking here](https://developer.squareup.com/) -> Click your app -> locations and copy the provided location ID.
3. Optionally add a discount/fee if you want to adjust the checkout total for customers who pay with Square.
4. Paste the above values in the respective inputs and save the settings by clicking "Save" in the SellApp modal.

SellApp will check the credentials and create the required Square webhook subscription automatically. If Square rejects the credentials or webhook setup, the modal will show the error before saving.

That's it. Square has been enabled for your store and you can now enable Square for every new product you create.

***

## Optionally: Enabling Square for products that already exist [#optionally-enabling-square-for-products-that-already-exist]

If you want to enable Square for products that already exist, here's how to do so:

1. Navigate to [your products dashboard by clicking here](https://sell.app/dashboard/listings).
2. On the products page, toggle the checkboxes of the products you want to enable Square for.
3. Open the "Bulk update" dropdown and click "Payment methods".
   * A modal will pop up; check Square &#x2A;(& optionally other payment methods you'd like enabled)*
4. Finally, click "Update All" in the modal to update the products' payment methods.

That's all done for you: all the products you selected will now have Square enabled as a payment method, which customers will be able to select when making a purchase.


# Stripe Payments for Digital Products (/docs/stripe)



SellApp makes it easy to link your [Stripe](https://stripe.com/) account and start accepting card, wallet, and local payment methods for your digital products. Use Stripe when you want a familiar card checkout for files, license keys, subscriptions, memberships, and other digital goods.

<Note>
  Once Stripe is enabled, customers can select a wide variety of payment methods on Stripe's checkout page. These include Apple/Google Pay, iDeal, Bancontact, Sofort, Giropay, and more.
</Note>

***

## Linking Stripe [#linking-stripe]

1. Navigate to [your storefront payment settings by clicking here](https://sell.app/dashboard/settings?settings=payment).
2. You will find a "Stripe" button. Click it to open the Stripe configuration modal.
3. Click the "**Connect Stripe**" button to be redirected to Stripe's onboarding page:
   1. If you already have a Stripe account, enter your Stripe email and log in.
   2. Otherwise, enter your email address and go through the onboarding process.
4. Once you've completed Stripe's onboarding process, you will be redirected back to your storefront's payment settings. Click "Stripe" to open the modal again,
   1. It should now say "Stripe Connected".
   2. If Stripe still needs more information before live charges can run, finish that in Stripe first.
   3. Finally, click "Enable" in the modal.
5. Optionally add a discount/fee if you want to adjust the checkout total for customers who pay with Stripe.

That's it. Stripe has been enabled for your store and you can now enable Stripe for every new product you create.

***

## Optionally: Enabling Stripe for products that already exist [#optionally-enabling-stripe-for-products-that-already-exist]

If you want to enable Stripe for products that already exist, here's how to do so:

1. Navigate to [your products dashboard by clicking here](https://sell.app/dashboard/listings).
2. On the products page, toggle the checkboxes of the products you want to enable Stripe for.
3. Open the "Bulk update" dropdown and click "Payment methods".
   * A modal will pop up; check Stripe &#x2A;(& optionally other payment methods you'd like enabled)*
4. Finally, click "Update All" in the modal to update the products' payment methods.

That's all done for you: all the products you selected will now have Stripe enabled as a payment method, which customers will be able to select when making a purchase.

***

## Support: Linking Stripe if it's already connected to another platform [#support-linking-stripe-if-its-already-connected-to-another-platform]

If your Stripe account has already been connected to another platform, and you want to link it to SellApp, you'll find it's not possible unless you disconnect the other platform's link to your account.

Here's how to do so:

* [Click here for Stripe's official guide](https://support.stripe.com/questions/disconnect-your-stripe-account-from-a-connected-third-party-platform)

1. Navigate [to the "Authorized Applications" page on your Stripe dashboard](https://dashboard.stripe.com/account/applications)
2. Click "revoke access" for the relevant platform that has already been connected to your account
3. Finally, you can now link your Stripe account to SellApp without running into any issues

Happy selling!


# Storefront Builder (/docs/storefront-builder-introduction)



The SellApp storefront builder gives you full control over your storefront's design, product layout, page structure, and SEO settings.

We created the storefront builder with ease and simplicity in mind. You can use the builder without touching any code, and design your digital product store with a drag-and-drop interface.

To get started with the builder, click the "Store Builder" button in the sidebar of the SellApp dashboard.

If you see an "Authorization Request" screen, click "Authorize" to let the builder access the store you are currently managing. Only store owners and admins can authorize the builder.

***

## Storefront Builder Basics [#storefront-builder-basics]

<iframe className="w-full h-[315px]" src="https://www.youtube.com/embed/cM41yVBRbMQ?si=7gOB8v0NUGcL84xh" title="YouTube video player" frameBorder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerPolicy="strict-origin-when-cross-origin" />

There are a number of aspects that are worth explaining to help you become familiar with the builder and its functionality:

Summed up briefly: The builder is a collection of **pages**. Pages house **sections** containing **blocks**. A more elaborate explanation:

* A storefront is a collection of pages
  * Each page is comprised of three aspects:
    * **Navigation bar**: The navigation bar is the same across all pages
      * The navigation bar does not consist of sections and blocks, it only has unique configuration options, found in the sidebar on the left side of the editor
    * **Body**: The body is unique for each page
      * The body is comprised of **sections**
        * Sections consist of **blocks**
          * Blocks can be **text**, a **button**, an **image**, and so on
          * You can **drag & drop blocks** within a section
          * Blocks each have their **unique configuration options**, found in the **sidebar on the left side** of the editor
    * **Footer**: The footer is the same across all pages
      * Unlike the navigation bar, the footer also consists of sections and blocks.
  * Each page has its own settings (SEO). To configure the page, **click the tab of the page** and its settings will appear in the sidebar on the left side of the editor
* There are also site-wide options and settings. To configure site-wide options and settings, **click the settings button**, found to the right side of the browser address bar

Of note is that a store design is not automatically mobile-optimized. To switch between a design's desktop & mobile design, you will want to click their respective option found above the sidebar, next to the "Preview" button.

***

## Site-wide settings [#site-wide-settings]

To configure site-wide options and settings, **click the settings button**, found to the right side of the browser address bar.

Generally speaking, the site-wide settings are your starting point. Here, you can configure the following:

* **Configure site-wide SEO settings**
* **Text configuration**: Font family, toggle RTL (right-to-left) language, set text colour (can be overridden per section and/or text)
* **Colour palette**: Create an assortment of colours. From normal ones, to gradients
* **Button**: Create/edit variations, each with their own effects, colours, and so on
* **Design system**: Set a global background colour or image, and border radius

Once you've configured these, you're ready to start creating pages, sections, and configure blocks

***

## Navigation bar [#navigation-bar]

**Unlike the body and footer, the navigation bar does not consist of sections and blocks.** It only has unique configuration options, found in the sidebar on the left side of the editor

To open the navigation bar's settings, click "Edit navigation".

For some use-cases, you might find having a navigation bar to be detrimental to your store's design and conversion rate. Given this, the first option is whether or not you'd like to have the navigation bar enabled.

Secondly is the brand name. You may leave it empty or enter your store's brand name, which will be visible at the left side of the navigation bar

Finally there are the navigation bar items. A navigation bar is comprised of multiple items, but each item is one of two types: a link, or a spacer.

* **A link consists of a label** (text) and a link to which the label points. There are three types of links
  * **An internal URL**: Useful to point to another page within your storefront
  * **An external URL**: Useful to point to an external site, such as google.com, or a specific ID of an element within the page, such as #promotion.
  * **A specific product**

Worth noting is that each link can be rendered as a button, if needed.

* A spacer is commonly used to style the assortment of links in your navigation bar.
  * With 1 spacer, you can push links to the rightmost side of your navigation bar.
  * With two spacers, you can have the links centered within the navigation bar.

***

## Creating a new page [#creating-a-new-page]

To create a new page, click the &#x2A;*+** icon next to the tab in the editor's browser

***

## Sections & Blocks [#sections--blocks]

Both the body and footer are comprised of sections, which house blocks themselves.

* Sections can be anything you want; a **hero**, a **featured product list**, and so on.
  * Note that you are not required to utilize multiple sections and can house everything within one big section, though we advise to utilize multiple sections for the sake of simplicity.
* Blocks are elements found within a section.
  * These can be **static content**, such as a heading, a rectangle, and so on
  * These can also be **dynamic content**, such as a product list, or feedback
    * Dynamic content is **fetched directly from your SellApp storefront**
    * The builder can pull in storefront data such as products, groups, sections, feedback, and published stories/highlights
  * **Each block has their own set of configurable options** which will appear in the sidebar on the left when you click on the respective block

***

## Publishing a store design [#publishing-a-store-design]

<Warn>
  A store design is not automatically mobile-optimized. To review your store's mobile design before publishing, you will want to click the mobile button icon found above the sidebar, next to the "Preview" button.
</Warn>

Once you've created a store design you're satisfied with on both the desktop and mobile version, you are ready to publish the design to the world.

To do so, &#x2A;*simply click the "Publish" button at the top right.** Until you publish, your changes stay in the builder draft. Once it has been published, a modal will appear to let you know this has been done.

***

**And that's it, you've created a store design of your own and published it for the world to see and interact with.**


# API Reference (/docs/api)



The SellApp API lets you manage storefront data, automate workflows, and integrate your own tooling against the platform.

<Cards>
  <Card title="Authentication" href="/api/authentication">
    Learn how API keys are sent and how requests are authenticated.
  </Card>

  <Card title="Errors" href="/api/errors">
    Understand error responses and common failure modes.
  </Card>

  <Card title="Pagination" href="/api/pagination">
    Learn how paginated resource responses are structured.
  </Card>

  <Card title="SDKs & Extensions" href="/api/sdks">
    Track the migration path for SDK and extension guidance.
  </Card>

  <Card title="Webhooks" href="/api/webhooks">
    Review webhook delivery behavior and payload handling guidance.
  </Card>
</Cards>


# Trustpilot Review Invitations (/docs/trustpilot)



With SellApp, you can automatically invite customers to leave a review on your Trustpilot page after they purchase from your digital product store.

***

## Trustpilot Review Invitation Setup [#trustpilot-review-invitation-setup]

To start, head to [your Trustpilot invitation settings by clicking here](https://businessapp.b2b.trustpilot.com/invitations/eti-settings).

1. On this page you'll find a unique Trustpilot email address. Click the "Copy email address"
2. With the copied email address, head on over to [your SellApp storefront personalization settings by clicking here](https://sell.app/dashboard/settings?settings=personalization) and paste the unique email you copied in step 1 into the "Trustpilot Email" input, then click the "Save" button

That's it. Now, when SellApp sends the customer their delivery email after a purchase, Trustpilot can use that email to invite them to place a review on your Trustpilot page.

### How it works [#how-it-works]

Whenever the delivery email is sent, your Trustpilot email is BCC'ed into the email that is sent to your customer. This BCC'ed Trustpilot email is then used by Trustpilot to automatically send an invitation to the customer's email to leave a review.

The limitation lies in the number of invites you can send out. For non-paying Trustpilot members, you will only be able to send out 100 invitations per month after which the invites stop being sent out. For most stores this is plenty enough, but for others it might make sense to purchase a plan.

For more info, head on over to Trustpilot's [automatic feedback service (AFS) page by clicking here](https://businessapp.b2b.trustpilot.com/invitations/eti-settings).


# Authentication (/docs/api/authentication)



You'll need to authenticate your requests to access any of the endpoints in the
SellApp API. SellApp currently offers one way to authenticate API requests:
using a secret API key.

## Authentication with a secret API key [#authentication-with-a-secret-api-key]

Authenticating with the SellApp API is done by passing your secret API key in
the request headers.

```bash title="Example request with bearer token"
curl --request GET \
  --url 'https://sell.app/api/v2/invoices' \
  --header 'Authorization: Bearer {ApiKeyHere}' \
  --header 'Content-Type: application/json'
```

## Creating and managing a secret API key [#creating-and-managing-a-secret-api-key]

If you do not already have a secret API key, you can generate one in your [store
developers settings](https://sell.app/dashboard/settings?settings=developers).
Always keep your API key safe and rotate it if you suspect it has been
compromised.

API keys are tied to an account, not a storefront. While you can toggle API
permissions on or off while creating an API key, access to resources still
depends on what permissions your account has on the storefront you are
interacting with.

As the owner of a storefront, you will always have full access to all API
endpoints, provided the relevant permissions were enabled when the key was
created.

If your account is part of a storefront as support staff, you can only access
resources that your account has been given permission to manage. For example, a
support staff account limited to tickets cannot modify products or create groups
through the API.

## Multiple stores [#multiple-stores]

If your account belongs to multiple storefronts, you can pass an `X-STORE`
header to specify which store you want to access. If you do not own any stores
or do not pass the header, the API defaults to the first store you own or
joined.

If you want to access `bob.sell.app`, you would pass the slug `bob` via the
`X-STORE` header:

```bash title="Example request accessing bob.sell.app invoices"
curl --request GET \
  --url 'https://sell.app/api/v2/invoices' \
  --header 'Authorization: Bearer {ApiKeyHere}' \
  --header 'X-STORE: bob' \
  --header 'Content-Type: application/json'
```

## Using an SDK [#using-an-sdk]

If you use an SDK, you do not need to manage most of the request setup
yourself. Fetch your API key from your developers settings, then let the client
library handle the authentication headers and request plumbing for you.

For currently known packages and integrations, see [SDKs &
Extensions](/api/sdks).


# Errors (/docs/api/errors)



What happens when something goes wrong while you are interacting with the API?
Mistakes happen, so this guide covers the status codes and error types you may
encounter.

<Note>
  Before reaching out to support with an issue, carefully check your code for
  incorrectly typed variables and missing or malformed headers.
</Note>

You can tell if a request was successful by checking the HTTP status code on the
response. If a response is unsuccessful, use the error type and message to
understand what went wrong and to debug the request.

***

## Status codes [#status-codes]

Here are the status code categories returned by the SellApp API:

<Properties>
  <Property name="2xx">
    A `2xx` status code indicates a successful response.
  </Property>

  <Property name="4xx">
    A `4xx` status code indicates a client error.
  </Property>

  <Property name="5xx">
    A `5xx` status code indicates a server error.
  </Property>
</Properties>

***

## Error types [#error-types]

Whenever a request is unsuccessful, the SellApp API returns an error response
with an error type and message. Use this information to understand what went
wrong and how to fix it.

The list of error codes may grow over time. The following code is currently
documented in the legacy API reference:

<Properties>
  <Property name="1020">
    This means either the API key passed along is incorrectly formatted, or you
    are missing a required header.
  </Property>
</Properties>


# Pagination (/docs/api/pagination)



SellApp API list responses are paginated. By default, responses limit results to
fifteen items. You can increase that limit up to one hundred by adding a
`limit` query parameter to your request.

Whenever an API response returns a list of objects, pagination is supported. Use
the `page` query parameter to browse result pages.

## Example using invoices [#example-using-invoices]

<Row>
  <Col>
    In this example, we request page `10` with a limit of `20` results per
    page. The response returns twenty invoices and the `last_page` attribute
    tells us we have not yet reached the end of the result set.

    <Properties>
      <Property name="limit" type="integer">
        The response limit of the API resource you are accessing.
      </Property>

      <Property name="page" type="integer">
        The page number you are attempting to access.
      </Property>
    </Properties>
  </Col>

  <Col>
    ```bash title="Manual pagination using cURL"
    curl --request GET \
      --url 'https://sell.app/api/v2/invoices?page=10&limit=20' \
      --header 'Authorization: Bearer {ApiKeyHere}' \
      --header 'Content-Type: application/json'
    ```

    ```json title="Paginated response"
    {
      "data": [
        {
          "id": "1"
        },
        {
          "id": "2"
        },
        {
          "id": "3"
        }
      ],
      "meta": {
        "current_page": 10,
        "from": 181,
        "last_page": 42,
        "links": [
          // ...
        ]
      }
    }
    ```
  </Col>
</Row>


# SDKs & Extensions (/docs/api/sdks)



SellApp and its community have created API libraries and extensions to make it
easier to integrate with the platform.

We are working toward releasing official packages and integrations. We currently
do not offer official SDKs for every language, but members of the SellApp
community have created a handful of open-source packages that may be useful
depending on your stack.

<Note>
  Community packages listed here are not officially endorsed. They are included
  because they are open-source and may be useful for your use case.
</Note>

## Community SDKs & extensions [#community-sdks--extensions]

<Cards>
  <Card title="Node.js by t6c" href="https://github.com/t6c/sellapp-api-wrapper">
    A community-maintained Node.js wrapper for the SellApp API.
  </Card>

  <Card title="Python by qoft" href="https://github.com/qoft/sellapp">
    A community-maintained Python package for interacting with SellApp.
  </Card>

  <Card title=".NET by biitez" href="https://github.com/biitez/SellApp">
    A community-maintained .NET integration for SellApp.
  </Card>

  <Card title="React by 6ichem" href="https://github.com/6ichem/react-sellapp">
    A community-maintained React integration for SellApp storefront flows.
  </Card>
</Cards>

***

## Embedding SellApp products [#embedding-sellapp-products]

SellApp offers an official embed solution that lets you place product purchase
flows directly on your own website. Once embedded, customers can complete
purchases without being redirected to your storefront.

For setup instructions, see the [Embedding products](/embedding-products) guide
in the main help documentation.


# Webhooks (/docs/api/webhooks)



Webhooks let your application react when something happens in SellApp, such as
an order being completed or a support ticket receiving a new message.

## Registering webhooks [#registering-webhooks]

To register a webhook, you need a URL in your application that SellApp can call.
You can configure a new webhook from your storefront developers settings under
[the developers tab](https://sell.app/dashboard/settings?settings=developers).

Add your callback URL, pick the [events](#event-types) you want to listen for,
and save the webhook. Whenever one of those events happens, SellApp will send a
webhook request to your endpoint.

## Consuming webhooks [#consuming-webhooks]

When your app receives a webhook request from SellApp, inspect the `event`
attribute to see what triggered it. The first part of the event type tells you
the payload category, such as an order or product.

```json title="Example webhook payload"
{
  "event": "order.completed",
  "data": {
    "id": 236
  },
  "store": 1
}
```

In the example above, an order was `completed`, and the payload type is
`order`.

***

## Event types [#event-types]

<Row>
  <Col>
    <Properties>
      <Property name="cash_app.payment_requires_attention">
        A CashApp payment is pending.
      </Property>

      <Property name="feedback.created">
        A new feedback was created.
      </Property>

      <Property name="order.created">
        A new order was created.
      </Property>

      <Property name="order.completed">
        An existing order was paid.
      </Property>

      <Property name="order.disputed">
        A paid order was disputed.
      </Property>

      <Property name="product.created">
        A new product was created.
      </Property>

      <Property name="product.updated">
        An existing product was updated.
      </Property>

      <Property name="product.trashed">
        A product was successfully deleted.
      </Property>

      <Property name="ticket_message.created">
        A new ticket message was created.
      </Property>

      <Property name="variant.created">
        A new product variant was created.
      </Property>

      <Property name="variant.updated">
        An existing product variant was updated.
      </Property>

      <Property name="variant.sold_out">
        An existing product variant ran out of stock.
      </Property>
    </Properties>
  </Col>

  <Col>
    ```json title="Example payload"
    {
      "event": "ticket_message.created",
      "data": {
        "author": "CUSTOMER",
        "sender": "mark@meta.com",
        "content": "Hey, I'm interested in investing.",
        "ticket_id": 1337,
        "updated_at": "2022-04-20T13:37:69.000000Z",
        "created_at": "2022-04-20T13:37:69.000000Z",
        "id": 6969,
        "ticket": {
          "id": 1337,
          "title": "Acquisition",
          "status": "OPEN",
          "customer": {
            "id": "c4e45131-a187-3476-9efd-1fb6fbbf2243",
            "email": "mark@meta.com"
          },
          "reference": {
            "id": 87654,
            "type": "App\\Models\\Invoice"
          },
          "created_at": "2022-04-20T13:37:69.000000Z",
          "updated_at": "2022-04-20T13:37:69.000000Z",
          "store_id": 1,
          "read_by": 1,
          "archived": 0
        }
      },
      "store": 1
    }
    ```
  </Col>
</Row>

***

## Security [#security]

To verify that a webhook really came from SellApp and not from a malicious
sender, validate the request signature. To create a webhook signing secret,
navigate to your [storefront developers settings](https://sell.app/dashboard/settings?settings=developers),
click **New Secret**, and save it.

Each webhook request contains a `signature` header. You can verify that
signature by hashing the raw request payload with your secret webhook key using
HMAC SHA-256.

<CodeBlockTabs defaultValue="js">
  <CodeBlockTabsList>
    <CodeBlockTabsTrigger value="js">
      JavaScript
    </CodeBlockTabsTrigger>

    <CodeBlockTabsTrigger value="python">
      Python
    </CodeBlockTabsTrigger>

    <CodeBlockTabsTrigger value="php">
      PHP
    </CodeBlockTabsTrigger>
  </CodeBlockTabsList>

  <CodeBlockTab value="js">
    ```js
    const signature = req.headers['signature'];
    const hash = crypto.createHmac('sha256', secret).update(payload).digest('hex');

    if (hash === signature) {
      // Request has been verified
    } else {
      // Request could not be verified
    }
    ```
  </CodeBlockTab>

  <CodeBlockTab value="python">
    ```python
    from flask import request
    import hashlib
    import hmac

    signature = request.headers.get("signature")
    hash = hmac.new(bytes(secret, "ascii"), bytes(payload, "ascii"), hashlib.sha256)

    if hash.hexdigest() == signature:
        # Request has been verified
    else:
        # Request could not be verified
    ```
  </CodeBlockTab>

  <CodeBlockTab value="php">
    ```php
    $signature = $request['headers']['signature'];
    $hash = hash_hmac('sha256', $payload, $secret);

    if (hash_equals($hash, $signature)) {
      // Request has been verified
    } else {
      // Request could not be verified
    }
    ```
  </CodeBlockTab>
</CodeBlockTabs>

If your generated signature matches the `signature` header, you can be sure the
request came from SellApp. Keep your secret webhook key safe. If it leaks, you
can no longer trust the signature.

## Discord webhooks and email notifications [#discord-webhooks-and-email-notifications]

Traditional webhook delivery cannot be used to post directly into a Discord
channel. Instead, go to your [store notifications settings](https://sell.app/dashboard/settings?settings=notifications)
and configure your Discord webhook URL there.

Discord and email notification channels support the same types of events as
traditional webhook events. For setup instructions, see the [creating
notifications](/creating-notifications) guide.


# Create a Blacklist Rule (/docs/api/blacklists/create-blacklist)

Create a new blacklist rule for your store.

## Endpoint

- Method: `POST`

- Path: `/v1/blacklists`

- Full URL: `https://sell.app/api/v1/blacklists`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "required": [
    "type",
    "data",
    "description"
  ],
  "properties": {
    "type": {
      "type": "string",
      "description": "The type of blacklist rule.",
      "enum": [
        "ASN",
        "COUNTRY",
        "EMAIL",
        "IP",
        "WILDCARD_EMAIL"
      ]
    },
    "data": {
      "type": "string",
      "description": "The value to blacklist.",
      "example": "@yahoo.com"
    },
    "description": {
      "type": "string",
      "description": "Why this rule is being created.",
      "example": "This email domain is dangerous"
    }
  },
  "example": {
    "type": "WILDCARD_EMAIL",
    "data": "@yahoo.com",
    "description": "This email domain is dangerous"
  }
}
```

Example:

```json
{
  "type": "WILDCARD_EMAIL",
  "data": "@yahoo.com",
  "description": "This email domain is dangerous"
}
```

## Responses

### 200

The newly created blacklist rule.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "required": [
    "data"
  ],
  "properties": {
    "data": {
      "type": "object",
      "description": "A blacklist rule that blocks purchases matching the provided details.",
      "required": [
        "id",
        "type",
        "data",
        "description",
        "created_at",
        "updated_at",
        "store_id"
      ],
      "properties": {
        "id": {
          "type": "integer",
          "description": "Unique identifier for the blacklist rule.",
          "example": 1
        },
        "type": {
          "type": "string",
          "description": "The type of blacklist rule.",
          "enum": [
            "ASN",
            "COUNTRY",
            "EMAIL",
            "IP",
            "WILDCARD_EMAIL"
          ]
        },
        "data": {
          "type": "string",
          "description": "The data associated with the rule type, such as an IP address, email, or country code.",
          "example": "rick@astley.com"
        },
        "description": {
          "type": "string",
          "description": "Why this blacklist rule exists.",
          "example": "He rickrolled me too many times."
        },
        "created_at": {
          "type": "string",
          "format": "date-time",
          "description": "When the blacklist rule was created.",
          "example": "2022-12-12T12:12:12.000000Z"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time",
          "description": "When the blacklist rule was last updated.",
          "example": "2022-12-12T12:12:12.000000Z"
        },
        "store_id": {
          "type": "integer",
          "description": "The store ID this blacklist rule belongs to.",
          "example": 1
        }
      }
    }
  },
  "example": {
    "data": {
      "id": 1,
      "type": "WILDCARD_EMAIL",
      "data": "@yahoo.com",
      "description": "This email domain is dangerous",
      "created_at": "2022-12-12T12:12:12.000000Z",
      "updated_at": "2022-12-12T12:12:12.000000Z",
      "store_id": 1
    }
  }
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "type": "WILDCARD_EMAIL",
    "data": "@yahoo.com",
    "description": "This email domain is dangerous",
    "created_at": "2022-12-12T12:12:12.000000Z",
    "updated_at": "2022-12-12T12:12:12.000000Z",
    "store_id": 1
  }
}
```

### 401

Authentication failed.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "message": {
      "type": "string",
      "example": "Unauthenticated."
    }
  }
}
```

### 422

The request payload failed validation.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "message": {
      "type": "string",
      "example": "The given data was invalid."
    },
    "errors": {
      "type": "object",
      "additionalProperties": {
        "type": "array",
        "items": {
          "type": "string"
        }
      },
      "example": {
        "data": [
          "The data field is required."
        ]
      }
    }
  }
}
```

# Delete a Blacklist Rule (/docs/api/blacklists/delete-blacklist)

Permanently delete a blacklist rule from your store.

## Endpoint

- Method: `DELETE`

- Path: `/v1/blacklists/{blacklist}`

- Full URL: `https://sell.app/api/v1/blacklists/{blacklist}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `blacklist` (`integer`, required): The unique identifier of the blacklist rule.

## Query Parameters
None.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

The blacklist rule was deleted successfully.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "required": [
    "data"
  ],
  "properties": {
    "data": {
      "type": "object",
      "description": "A blacklist rule that blocks purchases matching the provided details.",
      "required": [
        "id",
        "type",
        "data",
        "description",
        "created_at",
        "updated_at",
        "store_id"
      ],
      "properties": {
        "id": {
          "type": "integer",
          "description": "Unique identifier for the blacklist rule.",
          "example": 1
        },
        "type": {
          "type": "string",
          "description": "The type of blacklist rule.",
          "enum": [
            "ASN",
            "COUNTRY",
            "EMAIL",
            "IP",
            "WILDCARD_EMAIL"
          ]
        },
        "data": {
          "type": "string",
          "description": "The data associated with the rule type, such as an IP address, email, or country code.",
          "example": "rick@astley.com"
        },
        "description": {
          "type": "string",
          "description": "Why this blacklist rule exists.",
          "example": "He rickrolled me too many times."
        },
        "created_at": {
          "type": "string",
          "format": "date-time",
          "description": "When the blacklist rule was created.",
          "example": "2022-12-12T12:12:12.000000Z"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time",
          "description": "When the blacklist rule was last updated.",
          "example": "2022-12-12T12:12:12.000000Z"
        },
        "store_id": {
          "type": "integer",
          "description": "The store ID this blacklist rule belongs to.",
          "example": 1
        }
      }
    }
  },
  "example": {
    "data": {
      "id": 1,
      "type": "WILDCARD_EMAIL",
      "data": "@yahoo.com",
      "description": "This email domain is dangerous",
      "created_at": "2022-12-12T12:12:12.000000Z",
      "updated_at": "2022-12-12T12:12:12.000000Z",
      "store_id": 1
    }
  }
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "type": "WILDCARD_EMAIL",
    "data": "@yahoo.com",
    "description": "This email domain is dangerous",
    "created_at": "2022-12-12T12:12:12.000000Z",
    "updated_at": "2022-12-12T12:12:12.000000Z",
    "store_id": 1
  }
}
```

### 401

Authentication failed.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "message": {
      "type": "string",
      "example": "Unauthenticated."
    }
  }
}
```

### 404

The requested blacklist rule was not found.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "message": {
      "type": "string",
      "example": "Blacklist rule not found."
    }
  }
}
```

# Overview (/docs/api/blacklists)



Blacklist rules help prevent your SellApp storefront from falling victim to
malicious users. They allow you to block fraud attempts by preventing purchases
when customer details match one of your blacklist rules.

This section breaks each blacklist endpoint into its own page so every
operation has a dedicated URL and can be indexed independently.

## Endpoints [#endpoints]

* [List all blacklist rules](/api/blacklists/list-blacklists)
* [Create a blacklist rule](/api/blacklists/create-blacklist)
* [Retrieve a blacklist rule](/api/blacklists/retrieve-blacklist)
* [Update a blacklist rule](/api/blacklists/update-blacklist)
* [Delete a blacklist rule](/api/blacklists/delete-blacklist)

***

## The blacklist model [#the-blacklist-model]

The blacklist model contains the information storefront purchase attempts are
checked against, including the rule type, the rule data, and an internal
description.

### Properties [#properties]

<Properties>
  <Property name="id" type="integer">
    Unique identifier for the blacklist rule.
  </Property>

  <Property name="type" type="string">
    The type of blacklist rule. Supported types:

    * `ASN`
    * `COUNTRY`
    * `EMAIL`
    * `IP`
    * `WILDCARD_EMAIL`
  </Property>

  <Property name="data" type="string">
    The data related to the rule type. Examples:

    * `ASN`: `AS1234`
    * `COUNTRY`: `BE`
    * `EMAIL`: `rick@astley.com`
    * `IP`: `1.3.3.7`
    * `WILDCARD_EMAIL`: `@yahoo.com`
  </Property>

  <Property name="description" type="string">
    The description of why this blacklist rule was created.
  </Property>

  <Property name="created_at" type="timestamp">
    The time at which this blacklist rule was first created.
  </Property>

  <Property name="updated_at" type="timestamp">
    The time at which this blacklist rule was last updated.
  </Property>

  <Property name="store_id" type="integer">
    The ID of the store this blacklist rule belongs to.
  </Property>
</Properties>


# List All Blacklist Rules (/docs/api/blacklists/list-blacklists)

Retrieve a paginated list of blacklist rules.

## Endpoint

- Method: `GET`

- Path: `/v1/blacklists`

- Full URL: `https://sell.app/api/v1/blacklists`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
- `limit` (`integer`, optional): Limit the number of blacklist rules returned.
- `page` (`integer`, optional): The page number you are attempting to access.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

A paginated list of blacklist rules.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "required": [
    "data",
    "links",
    "meta"
  ],
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "description": "A blacklist rule that blocks purchases matching the provided details.",
        "required": [
          "id",
          "type",
          "data",
          "description",
          "created_at",
          "updated_at",
          "store_id"
        ],
        "properties": {
          "id": {
            "type": "integer",
            "description": "Unique identifier for the blacklist rule.",
            "example": 1
          },
          "type": {
            "type": "string",
            "description": "The type of blacklist rule.",
            "enum": [
              "ASN",
              "COUNTRY",
              "EMAIL",
              "IP",
              "WILDCARD_EMAIL"
            ]
          },
          "data": {
            "type": "string",
            "description": "The data associated with the rule type, such as an IP address, email, or country code.",
            "example": "rick@astley.com"
          },
          "description": {
            "type": "string",
            "description": "Why this blacklist rule exists.",
            "example": "He rickrolled me too many times."
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the blacklist rule was created.",
            "example": "2022-12-12T12:12:12.000000Z"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the blacklist rule was last updated.",
            "example": "2022-12-12T12:12:12.000000Z"
          },
          "store_id": {
            "type": "integer",
            "description": "The store ID this blacklist rule belongs to.",
            "example": 1
          }
        }
      }
    },
    "links": {
      "type": "object",
      "properties": {
        "first": {
          "type": "string",
          "example": "https://sell.app/api/v1/blacklists?page=1"
        },
        "last": {
          "type": "string",
          "example": "https://sell.app/api/v1/blacklists?page=4"
        },
        "prev": {
          "type": [
            "string",
            "null"
          ],
          "example": null
        },
        "next": {
          "type": [
            "string",
            "null"
          ],
          "example": "https://sell.app/api/v1/blacklists?page=2"
        }
      }
    },
    "meta": {
      "type": "object",
      "properties": {
        "current_page": {
          "type": "integer",
          "example": 1
        },
        "from": {
          "type": "integer",
          "example": 1
        },
        "last_page": {
          "type": "integer",
          "example": 4
        },
        "path": {
          "type": "string",
          "example": "https://sell.app/api/v1/blacklists"
        },
        "per_page": {
          "type": "integer",
          "example": 15
        },
        "to": {
          "type": "integer",
          "example": 15
        },
        "total": {
          "type": "integer",
          "example": 57
        }
      }
    }
  },
  "example": {
    "data": [
      {
        "id": 1,
        "type": "EMAIL",
        "data": "rick@astley.com",
        "description": "He rickrolled me too many times.",
        "created_at": "2022-12-12T12:12:12.000000Z",
        "updated_at": "2022-12-12T12:12:12.000000Z",
        "store_id": 1
      }
    ],
    "links": {
      "first": "https://sell.app/api/v1/blacklists?page=1",
      "last": "https://sell.app/api/v1/blacklists?page=4",
      "prev": null,
      "next": "https://sell.app/api/v1/blacklists?page=2"
    },
    "meta": {
      "current_page": 1,
      "from": 1,
      "last_page": 4,
      "path": "https://sell.app/api/v1/blacklists",
      "per_page": 15,
      "to": 15,
      "total": 57
    }
  }
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "type": "EMAIL",
      "data": "rick@astley.com",
      "description": "He rickrolled me too many times.",
      "created_at": "2022-12-12T12:12:12.000000Z",
      "updated_at": "2022-12-12T12:12:12.000000Z",
      "store_id": 1
    }
  ],
  "links": {
    "first": "https://sell.app/api/v1/blacklists?page=1",
    "last": "https://sell.app/api/v1/blacklists?page=4",
    "prev": null,
    "next": "https://sell.app/api/v1/blacklists?page=2"
  },
  "meta": {
    "current_page": 1,
    "from": 1,
    "last_page": 4,
    "path": "https://sell.app/api/v1/blacklists",
    "per_page": 15,
    "to": 15,
    "total": 57
  }
}
```

### 401

Authentication failed.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "message": {
      "type": "string",
      "example": "Unauthenticated."
    }
  }
}
```

# Retrieve a Blacklist Rule (/docs/api/blacklists/retrieve-blacklist)

Retrieve a specific blacklist rule by its unique identifier.

## Endpoint

- Method: `GET`

- Path: `/v1/blacklists/{blacklist}`

- Full URL: `https://sell.app/api/v1/blacklists/{blacklist}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `blacklist` (`integer`, required): The unique identifier of the blacklist rule.

## Query Parameters
None.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

The requested blacklist rule.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "required": [
    "data"
  ],
  "properties": {
    "data": {
      "type": "object",
      "description": "A blacklist rule that blocks purchases matching the provided details.",
      "required": [
        "id",
        "type",
        "data",
        "description",
        "created_at",
        "updated_at",
        "store_id"
      ],
      "properties": {
        "id": {
          "type": "integer",
          "description": "Unique identifier for the blacklist rule.",
          "example": 1
        },
        "type": {
          "type": "string",
          "description": "The type of blacklist rule.",
          "enum": [
            "ASN",
            "COUNTRY",
            "EMAIL",
            "IP",
            "WILDCARD_EMAIL"
          ]
        },
        "data": {
          "type": "string",
          "description": "The data associated with the rule type, such as an IP address, email, or country code.",
          "example": "rick@astley.com"
        },
        "description": {
          "type": "string",
          "description": "Why this blacklist rule exists.",
          "example": "He rickrolled me too many times."
        },
        "created_at": {
          "type": "string",
          "format": "date-time",
          "description": "When the blacklist rule was created.",
          "example": "2022-12-12T12:12:12.000000Z"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time",
          "description": "When the blacklist rule was last updated.",
          "example": "2022-12-12T12:12:12.000000Z"
        },
        "store_id": {
          "type": "integer",
          "description": "The store ID this blacklist rule belongs to.",
          "example": 1
        }
      }
    }
  },
  "example": {
    "data": {
      "id": 1,
      "type": "WILDCARD_EMAIL",
      "data": "@yahoo.com",
      "description": "This email domain is dangerous",
      "created_at": "2022-12-12T12:12:12.000000Z",
      "updated_at": "2022-12-12T12:12:12.000000Z",
      "store_id": 1
    }
  }
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "type": "WILDCARD_EMAIL",
    "data": "@yahoo.com",
    "description": "This email domain is dangerous",
    "created_at": "2022-12-12T12:12:12.000000Z",
    "updated_at": "2022-12-12T12:12:12.000000Z",
    "store_id": 1
  }
}
```

### 401

Authentication failed.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "message": {
      "type": "string",
      "example": "Unauthenticated."
    }
  }
}
```

### 404

The requested blacklist rule was not found.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "message": {
      "type": "string",
      "example": "Blacklist rule not found."
    }
  }
}
```

# Update a Blacklist Rule (/docs/api/blacklists/update-blacklist)

Update one or more attributes on an existing blacklist rule.

## Endpoint

- Method: `PATCH`

- Path: `/v1/blacklists/{blacklist}`

- Full URL: `https://sell.app/api/v1/blacklists/{blacklist}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `blacklist` (`integer`, required): The unique identifier of the blacklist rule.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "description": "Provide one or more fields to update an existing blacklist rule.",
  "properties": {
    "type": {
      "type": "string",
      "description": "The type of blacklist rule.",
      "enum": [
        "ASN",
        "COUNTRY",
        "EMAIL",
        "IP",
        "WILDCARD_EMAIL"
      ]
    },
    "data": {
      "type": "string",
      "description": "The updated value to blacklist.",
      "example": "@yahoomail.com"
    },
    "description": {
      "type": "string",
      "description": "The updated reason for this rule.",
      "example": "This email domain is super dangerous"
    }
  },
  "example": {
    "type": "WILDCARD_EMAIL",
    "data": "@yahoomail.com",
    "description": "This email domain is super dangerous"
  }
}
```

Example:

```json
{
  "type": "WILDCARD_EMAIL",
  "data": "@yahoomail.com",
  "description": "This email domain is super dangerous"
}
```

## Responses

### 200

The updated blacklist rule.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "required": [
    "data"
  ],
  "properties": {
    "data": {
      "type": "object",
      "description": "A blacklist rule that blocks purchases matching the provided details.",
      "required": [
        "id",
        "type",
        "data",
        "description",
        "created_at",
        "updated_at",
        "store_id"
      ],
      "properties": {
        "id": {
          "type": "integer",
          "description": "Unique identifier for the blacklist rule.",
          "example": 1
        },
        "type": {
          "type": "string",
          "description": "The type of blacklist rule.",
          "enum": [
            "ASN",
            "COUNTRY",
            "EMAIL",
            "IP",
            "WILDCARD_EMAIL"
          ]
        },
        "data": {
          "type": "string",
          "description": "The data associated with the rule type, such as an IP address, email, or country code.",
          "example": "rick@astley.com"
        },
        "description": {
          "type": "string",
          "description": "Why this blacklist rule exists.",
          "example": "He rickrolled me too many times."
        },
        "created_at": {
          "type": "string",
          "format": "date-time",
          "description": "When the blacklist rule was created.",
          "example": "2022-12-12T12:12:12.000000Z"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time",
          "description": "When the blacklist rule was last updated.",
          "example": "2022-12-12T12:12:12.000000Z"
        },
        "store_id": {
          "type": "integer",
          "description": "The store ID this blacklist rule belongs to.",
          "example": 1
        }
      }
    }
  },
  "example": {
    "data": {
      "id": 1,
      "type": "WILDCARD_EMAIL",
      "data": "@yahoo.com",
      "description": "This email domain is dangerous",
      "created_at": "2022-12-12T12:12:12.000000Z",
      "updated_at": "2022-12-12T12:12:12.000000Z",
      "store_id": 1
    }
  }
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "type": "WILDCARD_EMAIL",
    "data": "@yahoo.com",
    "description": "This email domain is dangerous",
    "created_at": "2022-12-12T12:12:12.000000Z",
    "updated_at": "2022-12-12T12:12:12.000000Z",
    "store_id": 1
  }
}
```

### 401

Authentication failed.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "message": {
      "type": "string",
      "example": "Unauthenticated."
    }
  }
}
```

### 404

The requested blacklist rule was not found.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "message": {
      "type": "string",
      "example": "Blacklist rule not found."
    }
  }
}
```

### 422

The request payload failed validation.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "message": {
      "type": "string",
      "example": "The given data was invalid."
    },
    "errors": {
      "type": "object",
      "additionalProperties": {
        "type": "array",
        "items": {
          "type": "string"
        }
      },
      "example": {
        "data": [
          "The data field is required."
        ]
      }
    }
  }
}
```

# Create a charge (/docs/api/charges/create-a-charge)

This endpoint allows you to create a new charge object. This can be for a paid transaction or a free item claim.

## Endpoint

- Method: `POST`

- Path: `/v2/charges`

- Full URL: `https://sell.app/api/v2/charges`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "email": {
      "type": "string",
      "format": "email"
    },
    "return_url": {
      "type": "string",
      "format": "uri"
    },
    "cancel_url": {
      "type": "string",
      "format": "uri"
    },
    "webhook": {
      "type": "string",
      "format": "uri"
    },
    "reference": {
      "type": "string"
    },
    "description": {
      "type": "string"
    },
    "currency": {
      "type": "string"
    },
    "total": {
      "type": "integer"
    },
    "payment_method": {
      "type": "string",
      "enum": [
        "AUTHNET",
        "BTCPAY",
        "CASHAPP",
        "COINBASE",
        "PADDLE",
        "PAYDASH",
        "PAYPAL",
        "PAYSTACK",
        "SQUARE",
        "STRIPE",
        "VENMO",
        "NMI",
        "LIFI",
        "BTC",
        "LTC",
        "ETH",
        "XMR",
        "SOL",
        "ADA",
        "BNB",
        "TRX",
        "MATIC",
        "ETH_USDT",
        "ETH_USDC",
        "ETH_UNI",
        "ETH_SHIB",
        "ETH_DAI",
        "BNB_USDT",
        "BNB_USDC",
        "TRX_USDT",
        "TRX_USDC",
        "SOL_USDT",
        "SOL_USDC"
      ]
    },
    "payment_methods": {
      "type": "array",
      "items": {
        "type": "string",
        "enum": [
          "AUTHNET",
          "BTCPAY",
          "CASHAPP",
          "COINBASE",
          "PADDLE",
          "PAYDASH",
          "PAYPAL",
          "PAYSTACK",
          "SQUARE",
          "STRIPE",
          "VENMO",
          "NMI",
          "LIFI",
          "BTC",
          "LTC",
          "ETH",
          "XMR",
          "SOL",
          "ADA",
          "BNB",
          "TRX",
          "MATIC",
          "ETH_USDT",
          "ETH_USDC",
          "ETH_UNI",
          "ETH_SHIB",
          "ETH_DAI",
          "BNB_USDT",
          "BNB_USDC",
          "TRX_USDT",
          "TRX_USDC",
          "SOL_USDT",
          "SOL_USDC"
        ]
      }
    },
    "use_all_payment_methods": {
      "type": "boolean"
    },
    "deliverable": {
      "type": "object",
      "additionalProperties": true
    },
    "metadata": {
      "type": "object",
      "additionalProperties": true
    },
    "coupon_code": {
      "type": "string"
    }
  },
  "required": [
    "email",
    "return_url"
  ]
}
```

Example:

```json
{
  "email": "customer@example.com",
  "return_url": "https://store.com/thank-you",
  "currency": "USD",
  "total": 10000,
  "payment_method": "PAYPAL",
  "reference": "Test Payment"
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "url": {
          "type": "string"
        },
        "status": {
          "type": "string"
        }
      },
      "required": [
        "id",
        "url",
        "status"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "url": "https://sell.app/store/charges/select/1?signature=...",
    "status": "PENDING"
  }
}
```

# Overview (/docs/api/charges)



Charges are a slimmed down, more fluid, version of orders. Similar to orders, they are used to take payment for products/services rendered. Unlike orders, however, charges do not manage/handle product delivery.

This makes charges especially useful as a building block for your external project where you handle/manage product delivery manually.

On this page, we'll dive into the different charge endpoints you can use to manage charges programmatically. We'll look at how to view, create, and update charges.

## Endpoints [#endpoints]

* [Create a charge](/api/charges/create-a-charge)
* [List all charges](/api/charges/list-all-charges)
* [Retrieve a charge](/api/charges/retrieve-a-charge)
* [Mark pending charge completed](/api/charges/mark-pending-charge-completed)
* [Mark pending charge voided](/api/charges/mark-pending-charge-voided)

## The charge model [#the-charge-model]

The charge model contains all the information about the charges stores have, including the type, code, and discount amount.

### Properties [#properties]

<Properties>
  <Property name="id" type="integer">
    *(read-only)* The unique identifier for the Charge object.
  </Property>

  <Property name="url" type="string">
    *(read-only)* The checkout URL you would direct a customer to. The customer can complete the payment or claim the free item on this URL.
  </Property>

  <Property name="status" type="string">
    *(read-only)* The current status of the charge. Possible values include `PENDING`, `COMPLETED`, `VOIDED`.
  </Property>

  <Property name="email" type="string">
    The customer's email address. **Required**.
  </Property>

  <Property name="reference" type="string">
    *(optional)* An optional reference for the charge.
  </Property>

  <Property name="currency" type="string">
    *(conditional)* Three-letter ISO currency code. **Required** if `total` > 0.
  </Property>

  <Property name="total" type="integer">
    *(conditional)* The total amount intended to be charged in the smallest currency unit (e.g., cents for USD). **Required** if `currency` is provided and the charge is not free. Must be > 0 for paid charges.
  </Property>

  <Property name="return_url" type="string">
    The URL to redirect the customer back to after they complete the checkout process (successfully or not). **Required**.
  </Property>

  <Property name="webhook" type="string">
    *(optional)* A URL to send webhook events to for status updates regarding this charge.
  </Property>

  <Property name="payment_method / payment_methods / use_all_payment_methods" type="string/array/boolean">
    *(conditional)* The specific payment gateway(s) for this charge. **Required** for paid charges. You can either pass:

    1. One payment method: `"payment_method": "STRIPE"`
    2. Multiple payment methods (which the customer can select from): `"payment_methods": ["PAYPAL", "STRIPE"]`
    3. All payment methods configured on your SellApp store: `"use_all_payment_methods": true`
  </Property>

  <Property name="cancel_url" type="string">
    *(optional)* A URL to redirect the customer to if they cancel the checkout process.
  </Property>

  <Property name="description" type="string">
    *(optional)* An optional description for the charge.
  </Property>

  <Property name="coupon_code" type="string">
    *(optional)* A valid SellApp coupon code to apply to the charge.
  </Property>

  <Property name="created_at" type="timestamp">
    *(read-only)* Time at which the object was created.
  </Property>

  <Property name="updated_at" type="timestamp">
    *(read-only)* Time at which the object was last updated.
  </Property>
</Properties>

<Note>
  **Note on Amounts:** All monetary amounts (like `total`) are provided in the smallest currency unit (e.g., cents for USD, pence for GBP).
</Note>

***


# List all charges (/docs/api/charges/list-all-charges)

This endpoint allows you to retrieve a paginated list of charges for your store.

## Endpoint

- Method: `GET`

- Path: `/v2/charges`

- Full URL: `https://sell.app/api/v2/charges`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
- `limit` (`integer`, optional): Limit the number of blacklist rules returned.
- `page` (`integer`, optional): The page number you are attempting to access.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "url": {
            "type": "string"
          },
          "status": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "url",
          "status"
        ]
      }
    },
    "links": {
      "type": "object",
      "properties": {}
    },
    "meta": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "data",
    "links",
    "meta"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "url": "https://sell.app/store/charges/select/1?signature=...",
      "status": "PENDING"
    }
  ],
  "links": {},
  "meta": {}
}
```

# Mark pending charge completed (/docs/api/charges/mark-pending-charge-completed)

Manually marks a pending charge as completed.

<Warn>
  This action should only be performed on charges with a `PENDING` status and where you're certain you've received the funds. Attempting to mark a charge with a different status as completed will result in an error.
</Warn>

## Endpoint

- Method: `PUT`

- Path: `/v2/charges/{charge_id}/completed`

- Full URL: `https://sell.app/api/v2/charges/{charge_id}/completed`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `charge_id` (`integer`, required): The charge id path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "message": {
      "type": "string"
    }
  },
  "required": [
    "message"
  ]
}
```

Example:

```json
{
  "message": "Charge Completed Successfully"
}
```

# Mark pending charge voided (/docs/api/charges/mark-pending-charge-voided)

Manually marks a pending charge as voided (canceled).

<Warn>
  This action should only be performed on charges with a `PENDING` status. Attempting to void a charge with a different status will result in an error.
</Warn>

## Endpoint

- Method: `PUT`

- Path: `/v2/charges/{charge_id}/voided`

- Full URL: `https://sell.app/api/v2/charges/{charge_id}/voided`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `charge_id` (`integer`, required): The charge id path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "message": {
      "type": "string"
    }
  },
  "required": [
    "message"
  ]
}
```

Example:

```json
{
  "message": "Charge Voided Successfully"
}
```

# Retrieve a charge (/docs/api/charges/retrieve-a-charge)

Retrieves the details of an existing charge by its ID. Refer to [the charge model](#the-charge-model) section for details on the returned object structure.

## Endpoint

- Method: `GET`

- Path: `/v2/charges/{charge}`

- Full URL: `https://sell.app/api/v2/charges/{charge}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `charge` (`integer`, required): The charge path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "url": {
          "type": "string"
        },
        "status": {
          "type": "string"
        }
      },
      "required": [
        "id",
        "url",
        "status"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "url": "https://sell.app/store/charges/select/1?signature=...",
    "status": "PENDING"
  }
}
```

# Overview (/docs/api/feedback)



Feedback helps give your storefront more legitimacy by informing potential customers about your product quality and seller reputation. The better your feedback, the higher the likelihood visitors turn into customers.

On this page, we'll dive into the different feedback endpoints you can use to manage feedback programmatically. We'll look at how to query and reply to feedback.

## Endpoints [#endpoints]

* [List all feedback](/api/feedback/list-all-feedback)
* [Search feedback](/api/feedback/search-feedback)
* [Retrieve specific feedback](/api/feedback/retrieve-specific-feedback)
* [Reply to feedback](/api/feedback/reply-to-feedback)

## The feedback model [#the-feedback-model]

The feedback model contains all the information about your store's feedback, including the feedback's message, reply, and rating.

### Properties [#properties]

<Properties>
  <Property name="id" type="integer">
    The unique identifier for the feedback.
  </Property>

  <Property name="feedback" type="string">
    The feedback sentiment, one of three:

    * `POSITIVE`
    * `NEUTRAL`
    * `NEGATIVE`
  </Property>

  <Property name="rating" type="integer">
    The feedback rating, from one to five.
  </Property>

  <Property name="deleted_at" type="timestamp">
    The time at which this feedback was deleted.
  </Property>

  <Property name="created_at" type="timestamp">
    The time at which this feedback was first created.
  </Property>

  <Property name="updated_at" type="timestamp">
    The time at which this feedback was last updated.
  </Property>

  <Property name="listing_id" type="integer">
    The ID of the product this feedback belongs to.
  </Property>

  <Property name="invoice_id" type="integer">
    The ID of the order this feedback belongs to.
  </Property>

  <Property name="store_id" type="integer">
    The ID of the store this feedback belongs to.
  </Property>

  <Property name="metadata" type="array">
    Array of metadata related to the feedback; shows whether the feedback was imported.
  </Property>

  <Property name="message" type="string">
    The message the customer left in this feedback.
  </Property>

  <Property name="reply" type="string">
    The reply to the feedback the storefront left.
  </Property>

  <Property name="is_automatic" type="integer">
    Whether the feedback was automatic or not, one of two:

    * `1`: Feedback is automatically left
    * `0`: Feedback is not automatically left
  </Property>
</Properties>

***


# List all feedback (/docs/api/feedback/list-all-feedback)

This endpoint allows you to retrieve a paginated list of all your feedback received. By default, a maximum of fifteen feedback are shown per page.

## Endpoint

- Method: `GET`

- Path: `/v1/feedback`

- Full URL: `https://sell.app/api/v1/feedback`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
- `limit` (`integer`, optional): Limit the number of blacklist rules returned.
- `page` (`integer`, optional): The page number you are attempting to access.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "feedback": {
            "type": "string"
          },
          "rating": {
            "type": "integer"
          },
          "deleted_at": {
            "type": "null"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "listing_id": {
            "type": "integer"
          },
          "invoice_id": {
            "type": "integer"
          },
          "store_id": {
            "type": "integer"
          },
          "metadata": {
            "type": "null"
          },
          "message": {
            "type": "string"
          },
          "reply": {
            "type": "string"
          },
          "is_automatic": {
            "type": "integer"
          }
        },
        "required": [
          "id",
          "feedback",
          "rating",
          "deleted_at",
          "created_at",
          "updated_at",
          "listing_id",
          "invoice_id",
          "store_id",
          "metadata",
          "message",
          "reply",
          "is_automatic"
        ]
      }
    },
    "links": {
      "type": "object",
      "properties": {}
    },
    "meta": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "data",
    "links",
    "meta"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "feedback": "POSITIVE",
      "rating": 5,
      "deleted_at": null,
      "created_at": "2022-12-12T12:12:12.000000Z",
      "updated_at": "2022-12-12T12:12:12.000000Z",
      "listing_id": 1,
      "invoice_id": 1,
      "store_id": 1,
      "metadata": null,
      "message": "This product changed my life. My ex-wife wanted me back, my kids started talking to me, and my boss gave me a raise too!",
      "reply": "The power of selling your soul to the Illuminati!",
      "is_automatic": 1
    }
  ],
  "links": {},
  "meta": {}
}
```

# Reply to feedback (/docs/api/feedback/reply-to-feedback)

This endpoint allows you to reply to a given feedback.

## Endpoint

- Method: `PATCH`

- Path: `/v1/feedback/{feedback}`

- Full URL: `https://sell.app/api/v1/feedback/{feedback}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `feedback` (`integer`, required): The feedback path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "reply": {
      "type": "string"
    }
  },
  "required": [
    "reply"
  ]
}
```

Example:

```json
{
  "reply": "Do not sell your soul, kids!"
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "feedback": {
          "type": "string"
        },
        "rating": {
          "type": "integer"
        },
        "deleted_at": {
          "type": "null"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "listing_id": {
          "type": "integer"
        },
        "invoice_id": {
          "type": "integer"
        },
        "store_id": {
          "type": "integer"
        },
        "metadata": {
          "type": "null"
        },
        "message": {
          "type": "string"
        },
        "reply": {
          "type": "string"
        },
        "is_automatic": {
          "type": "integer"
        }
      },
      "required": [
        "id",
        "feedback",
        "rating",
        "deleted_at",
        "created_at",
        "updated_at",
        "listing_id",
        "invoice_id",
        "store_id",
        "metadata",
        "message",
        "reply",
        "is_automatic"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "feedback": "POSITIVE",
    "rating": 5,
    "deleted_at": null,
    "created_at": "2022-12-12T12:12:12.000000Z",
    "updated_at": "2022-12-12T12:12:12.000000Z",
    "listing_id": 1,
    "invoice_id": 1,
    "store_id": 1,
    "metadata": null,
    "message": "This product changed my life. My ex-wife wanted me back, my kids started talking to me, and my boss gave me a raise too!",
    "reply": "Do not sell your soul, kids!",
    "is_automatic": 1
  }
}
```

# Retrieve specific feedback (/docs/api/feedback/retrieve-specific-feedback)

This endpoint allows you to retrieve a specific feedback by providing the unique identifier. Refer to [the list](/api/feedback#the-feedback-model) to see which properties are included with feedback objects.

## Endpoint

- Method: `GET`

- Path: `/v1/feedback/{feedback}`

- Full URL: `https://sell.app/api/v1/feedback/{feedback}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `feedback` (`integer`, required): The feedback path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "feedback": {
          "type": "string"
        },
        "rating": {
          "type": "integer"
        },
        "deleted_at": {
          "type": "null"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "listing_id": {
          "type": "integer"
        },
        "invoice_id": {
          "type": "integer"
        },
        "store_id": {
          "type": "integer"
        },
        "metadata": {
          "type": "null"
        },
        "message": {
          "type": "string"
        },
        "reply": {
          "type": "string"
        },
        "is_automatic": {
          "type": "integer"
        }
      },
      "required": [
        "id",
        "feedback",
        "rating",
        "deleted_at",
        "created_at",
        "updated_at",
        "listing_id",
        "invoice_id",
        "store_id",
        "metadata",
        "message",
        "reply",
        "is_automatic"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "feedback": "POSITIVE",
    "rating": 5,
    "deleted_at": null,
    "created_at": "2022-12-12T12:12:12.000000Z",
    "updated_at": "2022-12-12T12:12:12.000000Z",
    "listing_id": 1,
    "invoice_id": 1,
    "store_id": 1,
    "metadata": null,
    "message": "This product changed my life. My ex-wife wanted me back, my kids started talking to me, and my boss gave me a raise too!",
    "reply": "The power of selling your soul to the Illuminati!",
    "is_automatic": 1
  }
}
```

# Search feedback (/docs/api/feedback/search-feedback)

Search feedback with filters, search terms, includes, and sort instructions in a JSON request body.

## Endpoint

- Method: `POST`

- Path: `/v1/feedback/search`

- Full URL: `https://sell.app/api/v1/feedback/search`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "filters": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "field": {
            "type": "string"
          },
          "operator": {
            "type": "string",
            "default": "="
          },
          "value": {},
          "type": {
            "type": "string",
            "enum": [
              "and",
              "or"
            ],
            "default": "and"
          },
          "nested": {
            "type": "array",
            "items": {
              "type": "object",
              "additionalProperties": true
            }
          }
        },
        "required": [
          "field"
        ]
      }
    },
    "sort": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "field": {
            "type": "string"
          },
          "direction": {
            "type": "string",
            "enum": [
              "asc",
              "desc"
            ],
            "default": "asc"
          }
        },
        "required": [
          "field"
        ]
      }
    },
    "search": {
      "type": "object",
      "properties": {
        "value": {
          "type": [
            "string",
            "null"
          ]
        },
        "case_sensitive": {
          "type": "boolean"
        }
      }
    },
    "includes": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "relation": {
            "type": "string"
          }
        },
        "required": [
          "relation"
        ]
      }
    }
  }
}
```

Example:

```json
{
  "filters": [
    {
      "field": "id",
      "operator": "=",
      "value": 1
    }
  ],
  "sort": [
    {
      "field": "created_at",
      "direction": "desc"
    }
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "feedback": {
            "type": "string"
          },
          "rating": {
            "type": "integer"
          },
          "deleted_at": {
            "type": "null"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "listing_id": {
            "type": "integer"
          },
          "invoice_id": {
            "type": "integer"
          },
          "store_id": {
            "type": "integer"
          },
          "metadata": {
            "type": "null"
          },
          "message": {
            "type": "string"
          },
          "reply": {
            "type": "string"
          },
          "is_automatic": {
            "type": "integer"
          }
        },
        "required": [
          "id",
          "feedback",
          "rating",
          "deleted_at",
          "created_at",
          "updated_at",
          "listing_id",
          "invoice_id",
          "store_id",
          "metadata",
          "message",
          "reply",
          "is_automatic"
        ]
      }
    },
    "links": {
      "type": "object",
      "properties": {}
    },
    "meta": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "data",
    "links",
    "meta"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "feedback": "POSITIVE",
      "rating": 5,
      "deleted_at": null,
      "created_at": "2022-12-12T12:12:12.000000Z",
      "updated_at": "2022-12-12T12:12:12.000000Z",
      "listing_id": 1,
      "invoice_id": 1,
      "store_id": 1,
      "metadata": null,
      "message": "This product changed my life. My ex-wife wanted me back, my kids started talking to me, and my boss gave me a raise too!",
      "reply": "The power of selling your soul to the Illuminati!",
      "is_automatic": 1
    }
  ],
  "links": {},
  "meta": {}
}
```

# Batch create coupons (/docs/api/coupons/batch-create-coupons)

Create multiple coupons in one request by sending a `resources` array.

## Endpoint

- Method: `POST`

- Path: `/v1/coupons/batch`

- Full URL: `https://sell.app/api/v1/coupons/batch`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "resources": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "code": {
            "type": "string"
          },
          "type": {
            "type": "string",
            "enum": [
              "PERCENTAGE",
              "AMOUNT"
            ]
          },
          "discount": {
            "type": "number"
          },
          "store_wide": {
            "type": "boolean"
          },
          "products": {
            "type": "array",
            "minItems": 1,
            "items": {
              "type": "integer"
            }
          },
          "limit": {
            "type": [
              "integer",
              "null"
            ]
          },
          "expires_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "minimum_amount": {
            "type": [
              "number",
              "null"
            ]
          }
        },
        "required": [
          "code",
          "type",
          "discount",
          "store_wide"
        ]
      }
    }
  },
  "required": [
    "resources"
  ]
}
```

Example:

```json
{
  "resources": [
    {
      "code": "BONANZA",
      "type": "PERCENTAGE",
      "discount": 80,
      "store_wide": true
    }
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "code": {
            "type": "string"
          },
          "type": {
            "type": "string"
          },
          "discount": {
            "type": "string"
          },
          "limit": {
            "type": "null"
          },
          "store_wide": {
            "type": "boolean"
          },
          "minimum_amount": {
            "type": "null"
          },
          "expires_at": {
            "type": "null"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "store_id": {
            "type": "integer"
          },
          "deleted_at": {
            "type": "null"
          }
        },
        "required": [
          "id",
          "code",
          "type",
          "discount",
          "limit",
          "store_wide",
          "minimum_amount",
          "expires_at",
          "created_at",
          "updated_at",
          "store_id",
          "deleted_at"
        ]
      }
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "code": "BONANZA",
      "type": "PERCENTAGE",
      "discount": "80",
      "limit": null,
      "store_wide": true,
      "minimum_amount": null,
      "expires_at": null,
      "created_at": "2022-12-12T12:12:12.000000Z",
      "updated_at": "2022-12-12T12:12:12.000000Z",
      "store_id": 1,
      "deleted_at": null
    }
  ]
}
```

# Batch delete coupons (/docs/api/coupons/batch-delete-coupons)

Delete multiple coupons in one request by sending the coupon IDs in `resources`.

## Endpoint

- Method: `DELETE`

- Path: `/v1/coupons/batch`

- Full URL: `https://sell.app/api/v1/coupons/batch`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "resources": {
      "type": "array",
      "items": {
        "type": "integer"
      }
    }
  },
  "required": [
    "resources"
  ]
}
```

Example:

```json
{
  "resources": [
    1,
    2
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "code": {
            "type": "string"
          },
          "type": {
            "type": "string"
          },
          "discount": {
            "type": "string"
          },
          "limit": {
            "type": "null"
          },
          "store_wide": {
            "type": "boolean"
          },
          "minimum_amount": {
            "type": "null"
          },
          "expires_at": {
            "type": "null"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "store_id": {
            "type": "integer"
          },
          "deleted_at": {
            "type": "null"
          }
        },
        "required": [
          "id",
          "code",
          "type",
          "discount",
          "limit",
          "store_wide",
          "minimum_amount",
          "expires_at",
          "created_at",
          "updated_at",
          "store_id",
          "deleted_at"
        ]
      }
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "code": "BONANZA",
      "type": "PERCENTAGE",
      "discount": "80",
      "limit": null,
      "store_wide": true,
      "minimum_amount": null,
      "expires_at": null,
      "created_at": "2022-12-12T12:12:12.000000Z",
      "updated_at": "2022-12-12T12:12:12.000000Z",
      "store_id": 1,
      "deleted_at": null
    }
  ]
}
```

# Batch update coupons (/docs/api/coupons/batch-update-coupons)

Update multiple coupons in one request by sending a `resources` object keyed by coupon ID.

## Endpoint

- Method: `PATCH`

- Path: `/v1/coupons/batch`

- Full URL: `https://sell.app/api/v1/coupons/batch`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "resources": {
      "type": "object",
      "additionalProperties": {
        "type": "object",
        "properties": {
          "code": {
            "type": "string"
          },
          "type": {
            "type": "string",
            "enum": [
              "PERCENTAGE",
              "AMOUNT"
            ]
          },
          "discount": {
            "type": "number"
          },
          "store_wide": {
            "type": "boolean"
          },
          "products": {
            "type": "array",
            "minItems": 1,
            "items": {
              "type": "integer"
            }
          },
          "limit": {
            "type": [
              "integer",
              "null"
            ]
          },
          "expires_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "minimum_amount": {
            "type": [
              "number",
              "null"
            ]
          }
        }
      }
    }
  },
  "required": [
    "resources"
  ]
}
```

Example:

```json
{
  "resources": {
    "1": {
      "code": "BONANZA",
      "type": "PERCENTAGE",
      "discount": 80,
      "store_wide": true
    }
  }
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "code": {
            "type": "string"
          },
          "type": {
            "type": "string"
          },
          "discount": {
            "type": "string"
          },
          "limit": {
            "type": "null"
          },
          "store_wide": {
            "type": "boolean"
          },
          "minimum_amount": {
            "type": "null"
          },
          "expires_at": {
            "type": "null"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "store_id": {
            "type": "integer"
          },
          "deleted_at": {
            "type": "null"
          }
        },
        "required": [
          "id",
          "code",
          "type",
          "discount",
          "limit",
          "store_wide",
          "minimum_amount",
          "expires_at",
          "created_at",
          "updated_at",
          "store_id",
          "deleted_at"
        ]
      }
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "code": "BONANZA",
      "type": "PERCENTAGE",
      "discount": "80",
      "limit": null,
      "store_wide": true,
      "minimum_amount": null,
      "expires_at": null,
      "created_at": "2022-12-12T12:12:12.000000Z",
      "updated_at": "2022-12-12T12:12:12.000000Z",
      "store_id": 1,
      "deleted_at": null
    }
  ]
}
```

# Create a coupon (/docs/api/coupons/create-a-coupon)

This endpoint allows you to create a new coupon. See the code examples for how to create a new coupon with the SellApp API.

## Endpoint

- Method: `POST`

- Path: `/v1/coupons`

- Full URL: `https://sell.app/api/v1/coupons`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "code": {
      "type": "string"
    },
    "type": {
      "type": "string",
      "enum": [
        "PERCENTAGE",
        "AMOUNT"
      ]
    },
    "discount": {
      "type": "number"
    },
    "store_wide": {
      "type": "boolean"
    },
    "products": {
      "type": "array",
      "minItems": 1,
      "items": {
        "type": "integer"
      }
    },
    "limit": {
      "type": [
        "integer",
        "null"
      ]
    },
    "expires_at": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time"
    },
    "minimum_amount": {
      "type": [
        "number",
        "null"
      ]
    }
  },
  "required": [
    "code",
    "type",
    "discount",
    "store_wide"
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "code": {
          "type": "string"
        },
        "type": {
          "type": "string"
        },
        "discount": {
          "type": "string"
        },
        "limit": {
          "type": "null"
        },
        "store_wide": {
          "type": "boolean"
        },
        "minimum_amount": {
          "type": "null"
        },
        "expires_at": {
          "type": "null"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "store_id": {
          "type": "integer"
        },
        "deleted_at": {
          "type": "null"
        }
      },
      "required": [
        "id",
        "code",
        "type",
        "discount",
        "limit",
        "store_wide",
        "minimum_amount",
        "expires_at",
        "created_at",
        "updated_at",
        "store_id",
        "deleted_at"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "code": "BONANZA",
    "type": "PERCENTAGE",
    "discount": "80",
    "limit": null,
    "store_wide": true,
    "minimum_amount": null,
    "expires_at": null,
    "created_at": "2022-12-12T12:12:12.000000Z",
    "updated_at": "2022-12-12T12:12:12.000000Z",
    "store_id": 1,
    "deleted_at": null
  }
}
```

# Delete a coupon (/docs/api/coupons/delete-a-coupon)

This endpoint allows you to delete a coupon.

<Warn>
  This will permanently delete the coupon.
</Warn>

## Endpoint

- Method: `DELETE`

- Path: `/v1/coupons/{coupon}`

- Full URL: `https://sell.app/api/v1/coupons/{coupon}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `coupon` (`integer`, required): The coupon path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "code": {
          "type": "string"
        },
        "type": {
          "type": "string"
        },
        "discount": {
          "type": "string"
        },
        "limit": {
          "type": "null"
        },
        "store_wide": {
          "type": "boolean"
        },
        "minimum_amount": {
          "type": "null"
        },
        "expires_at": {
          "type": "null"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "store_id": {
          "type": "integer"
        },
        "deleted_at": {
          "type": "null"
        }
      },
      "required": [
        "id",
        "code",
        "type",
        "discount",
        "limit",
        "store_wide",
        "minimum_amount",
        "expires_at",
        "created_at",
        "updated_at",
        "store_id",
        "deleted_at"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "code": "BONANZA",
    "type": "PERCENTAGE",
    "discount": "80",
    "limit": null,
    "store_wide": true,
    "minimum_amount": null,
    "expires_at": null,
    "created_at": "2022-12-12T12:12:12.000000Z",
    "updated_at": "2022-12-12T12:12:12.000000Z",
    "store_id": 1,
    "deleted_at": null
  }
}
```

# Overview (/docs/api/coupons)



Coupons help boost sales on your SellApp storefront — they allow you to attract new customers with exclusive offers and reward existing customers for their previous purchases.

On this page, we'll dive into the different coupon endpoints you can use to manage coupons programmatically. We'll look at how to create, update, and delete coupons.

## Endpoints [#endpoints]

* [List all coupons](/api/coupons/list-all-coupons)
* [Search coupons](/api/coupons/search-coupons)
* [Create a coupon](/api/coupons/create-a-coupon)
* [Batch create coupons](/api/coupons/batch-create-coupons)
* [Retrieve a coupon](/api/coupons/retrieve-a-coupon)
* [Update a coupon](/api/coupons/update-a-coupon)
* [Batch update coupons](/api/coupons/batch-update-coupons)
* [Batch delete coupons](/api/coupons/batch-delete-coupons)
* [Delete a coupon](/api/coupons/delete-a-coupon)

## The coupon model [#the-coupon-model]

The coupon model contains all the information about the coupons stores have, including the type, code, and discount amount.

### Properties [#properties]

<Properties>
  <Property name="id" type="integer">
    The unique identifier for the coupon.
  </Property>

  <Property name="code" type="string">
    The coupon code which the customer enters during checkout.
  </Property>

  <Property name="type" type="string">
    The type of coupon. Supported types:

    * PERCENTAGE
    * AMOUNT
  </Property>

  <Property name="discount" type="integer">
    The discount value related to the above type. Examples:

    * PERCENTAGE: `50&#x60; &#x2A;(in percentages)*
    * AMOUNT: `5&#x60; &#x2A;(in dollars)*
  </Property>

  <Property name="limit" type="integer">
    The total amount of times this coupon can be applied before it can no longer be used.
  </Property>

  <Property name="store_wide" type="boolean">
    The scope of the coupon; if true it applies to all products in your store. If false, it only applies to certain products.
  </Property>

  <Property name="products" type="integer[]">
    Product IDs this coupon applies to when `store_wide` is `false`. Send listing/product IDs here, not variant IDs. Store-wide coupons return an empty array because they apply to every product.
  </Property>

  <Property name="minimum_amount" type="integer">
    The minimum amount &#x2A;(in dollars)* at which the coupon can be applied.
  </Property>

  <Property name="expires_at" type="timestamp">
    The time at which this coupon stops being usable.
  </Property>

  <Property name="created_at" type="timestamp">
    The time at which this coupon was first created.
  </Property>

  <Property name="updated_at" type="timestamp">
    The time at which this coupon was last updated.
  </Property>

  <Property name="store_id" type="integer">
    The ID of the store this coupon belongs to.
  </Property>

  <Property name="deleted_at" type="timestamp">
    The time at which this coupon was deleted.
  </Property>
</Properties>

***


# List all coupons (/docs/api/coupons/list-all-coupons)

This endpoint allows you to retrieve a paginated list of all your coupons. By default, a maximum of fifteen coupons are shown per page.

## Endpoint

- Method: `GET`

- Path: `/v1/coupons`

- Full URL: `https://sell.app/api/v1/coupons`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
- `limit` (`integer`, optional): Limit the number of blacklist rules returned.
- `page` (`integer`, optional): The page number you are attempting to access.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "code": {
            "type": "string"
          },
          "type": {
            "type": "string"
          },
          "discount": {
            "type": "string"
          },
          "limit": {
            "type": "null"
          },
          "store_wide": {
            "type": "boolean"
          },
          "minimum_amount": {
            "type": "null"
          },
          "expires_at": {
            "type": "null"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "store_id": {
            "type": "integer"
          },
          "deleted_at": {
            "type": "null"
          }
        },
        "required": [
          "id",
          "code",
          "type",
          "discount",
          "limit",
          "store_wide",
          "minimum_amount",
          "expires_at",
          "created_at",
          "updated_at",
          "store_id",
          "deleted_at"
        ]
      }
    },
    "links": {
      "type": "object",
      "properties": {}
    },
    "meta": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "data",
    "links",
    "meta"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "code": "BONANZA",
      "type": "PERCENTAGE",
      "discount": "80",
      "limit": null,
      "store_wide": true,
      "minimum_amount": null,
      "expires_at": null,
      "created_at": "2022-12-12T12:12:12.000000Z",
      "updated_at": "2022-12-12T12:12:12.000000Z",
      "store_id": 1,
      "deleted_at": null
    }
  ],
  "links": {},
  "meta": {}
}
```

# Retrieve a coupon (/docs/api/coupons/retrieve-a-coupon)

This endpoint allows you to retrieve a specific coupon by providing the unique identifier. Refer to [the list](/api/coupons#the-coupon-model) to see which properties are included with coupon objects.

## Endpoint

- Method: `GET`

- Path: `/v1/coupons/{coupon}`

- Full URL: `https://sell.app/api/v1/coupons/{coupon}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `coupon` (`integer`, required): The coupon path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "code": {
          "type": "string"
        },
        "type": {
          "type": "string"
        },
        "discount": {
          "type": "string"
        },
        "limit": {
          "type": "null"
        },
        "store_wide": {
          "type": "boolean"
        },
        "minimum_amount": {
          "type": "null"
        },
        "expires_at": {
          "type": "null"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "store_id": {
          "type": "integer"
        },
        "deleted_at": {
          "type": "null"
        }
      },
      "required": [
        "id",
        "code",
        "type",
        "discount",
        "limit",
        "store_wide",
        "minimum_amount",
        "expires_at",
        "created_at",
        "updated_at",
        "store_id",
        "deleted_at"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "code": "BONANZA",
    "type": "PERCENTAGE",
    "discount": "80",
    "limit": null,
    "store_wide": true,
    "minimum_amount": null,
    "expires_at": null,
    "created_at": "2022-12-12T12:12:12.000000Z",
    "updated_at": "2022-12-12T12:12:12.000000Z",
    "store_id": 1,
    "deleted_at": null
  }
}
```

# Search coupons (/docs/api/coupons/search-coupons)

Search coupons with filters, search terms, includes, and sort instructions in a JSON request body.

## Endpoint

- Method: `POST`

- Path: `/v1/coupons/search`

- Full URL: `https://sell.app/api/v1/coupons/search`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "filters": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "field": {
            "type": "string"
          },
          "operator": {
            "type": "string",
            "default": "="
          },
          "value": {},
          "type": {
            "type": "string",
            "enum": [
              "and",
              "or"
            ],
            "default": "and"
          },
          "nested": {
            "type": "array",
            "items": {
              "type": "object",
              "additionalProperties": true
            }
          }
        },
        "required": [
          "field"
        ]
      }
    },
    "sort": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "field": {
            "type": "string"
          },
          "direction": {
            "type": "string",
            "enum": [
              "asc",
              "desc"
            ],
            "default": "asc"
          }
        },
        "required": [
          "field"
        ]
      }
    },
    "search": {
      "type": "object",
      "properties": {
        "value": {
          "type": [
            "string",
            "null"
          ]
        },
        "case_sensitive": {
          "type": "boolean"
        }
      }
    },
    "includes": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "relation": {
            "type": "string"
          }
        },
        "required": [
          "relation"
        ]
      }
    }
  }
}
```

Example:

```json
{
  "filters": [
    {
      "field": "id",
      "operator": "=",
      "value": 1
    }
  ],
  "sort": [
    {
      "field": "created_at",
      "direction": "desc"
    }
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "code": {
            "type": "string"
          },
          "type": {
            "type": "string"
          },
          "discount": {
            "type": "string"
          },
          "limit": {
            "type": "null"
          },
          "store_wide": {
            "type": "boolean"
          },
          "minimum_amount": {
            "type": "null"
          },
          "expires_at": {
            "type": "null"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "store_id": {
            "type": "integer"
          },
          "deleted_at": {
            "type": "null"
          }
        },
        "required": [
          "id",
          "code",
          "type",
          "discount",
          "limit",
          "store_wide",
          "minimum_amount",
          "expires_at",
          "created_at",
          "updated_at",
          "store_id",
          "deleted_at"
        ]
      }
    },
    "links": {
      "type": "object",
      "properties": {}
    },
    "meta": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "data",
    "links",
    "meta"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "code": "BONANZA",
      "type": "PERCENTAGE",
      "discount": "80",
      "limit": null,
      "store_wide": true,
      "minimum_amount": null,
      "expires_at": null,
      "created_at": "2022-12-12T12:12:12.000000Z",
      "updated_at": "2022-12-12T12:12:12.000000Z",
      "store_id": 1,
      "deleted_at": null
    }
  ],
  "links": {},
  "meta": {}
}
```

# Update a coupon (/docs/api/coupons/update-a-coupon)

This endpoint allows you to perform an update on a coupon.

To scope a coupon to specific products, set `store_wide` to `false` and send `products` as an array of product/listing IDs. Variant IDs are not supported for coupon scoping.

## Endpoint

- Method: `PATCH`

- Path: `/v1/coupons/{coupon}`

- Full URL: `https://sell.app/api/v1/coupons/{coupon}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `coupon` (`integer`, required): The coupon path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "code": {
      "type": "string"
    },
    "type": {
      "type": "string",
      "enum": [
        "PERCENTAGE",
        "AMOUNT"
      ]
    },
    "discount": {
      "type": "number"
    },
    "store_wide": {
      "type": "boolean"
    },
    "products": {
      "type": "array",
      "minItems": 1,
      "items": {
        "type": "integer"
      }
    },
    "limit": {
      "type": [
        "integer",
        "null"
      ]
    },
    "expires_at": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time"
    },
    "minimum_amount": {
      "type": [
        "number",
        "null"
      ]
    }
  }
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "code": {
          "type": "string"
        },
        "type": {
          "type": "string"
        },
        "discount": {
          "type": "string"
        },
        "limit": {
          "type": "null"
        },
        "store_wide": {
          "type": "boolean"
        },
        "minimum_amount": {
          "type": "null"
        },
        "expires_at": {
          "type": "null"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "store_id": {
          "type": "integer"
        },
        "deleted_at": {
          "type": "null"
        }
      },
      "required": [
        "id",
        "code",
        "type",
        "discount",
        "limit",
        "store_wide",
        "minimum_amount",
        "expires_at",
        "created_at",
        "updated_at",
        "store_id",
        "deleted_at"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "code": "BAZINGA",
    "type": "PERCENTAGE",
    "discount": "80",
    "limit": null,
    "store_wide": true,
    "minimum_amount": null,
    "expires_at": null,
    "created_at": "2022-12-12T12:12:12.000000Z",
    "updated_at": "2022-12-12T12:12:12.000000Z",
    "store_id": 1,
    "deleted_at": null
  }
}
```

# Add products to group (/docs/api/groups/add-products-to-group)

This endpoint allows you to add products to an existing group. See the code examples for how to add products to an existing group with the SellApp API.

## Endpoint

- Method: `POST`

- Path: `/v2/groups/{group}/products/attach`

- Full URL: `https://sell.app/api/v2/groups/{group}/products/attach`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `group` (`integer`, required): The group path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "resources": {
      "type": "array",
      "items": {
        "type": "integer"
      }
    }
  },
  "required": [
    "resources"
  ]
}
```

Example:

```json
{
  "resources": [
    1
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "attached": {
      "type": "array",
      "items": {
        "type": "integer"
      }
    }
  },
  "required": [
    "attached"
  ]
}
```

Example:

```json
{
  "attached": [
    1
  ]
}
```

# Create a group (/docs/api/groups/create-a-group)

This endpoint allows you to create a new group. See the code examples for how to create a new group with the SellApp API.

## Endpoint

- Method: `POST`

- Path: `/v2/groups`

- Full URL: `https://sell.app/api/v2/groups`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "title": {
      "type": "string"
    },
    "unlisted": {
      "type": "boolean"
    },
    "order": {
      "type": [
        "integer",
        "null"
      ]
    }
  },
  "required": [
    "title",
    "unlisted"
  ]
}
```

### Content Type: `multipart/form-data`

Schema:

```json
{
  "type": "object",
  "properties": {
    "title": {
      "type": "string"
    },
    "unlisted": {
      "type": "boolean"
    },
    "order": {
      "type": [
        "integer",
        "null"
      ]
    },
    "image": {
      "type": "string",
      "format": "binary"
    }
  },
  "required": [
    "title",
    "unlisted"
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "title": {
          "type": "string"
        },
        "order": {
          "type": "integer"
        },
        "image": {
          "type": "null"
        },
        "unlisted": {
          "type": "boolean"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "store_id": {
          "type": "integer"
        },
        "section_id": {
          "type": "null"
        },
        "section_order": {
          "type": "null"
        },
        "products_linked": {
          "type": "integer"
        },
        "products": {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      },
      "required": [
        "id",
        "title",
        "order",
        "image",
        "unlisted",
        "created_at",
        "updated_at",
        "store_id",
        "section_id",
        "section_order",
        "products_linked",
        "products"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "title": "Rat race",
    "order": 1,
    "image": null,
    "unlisted": false,
    "created_at": "2022-12-12T12:12:12.000000Z",
    "updated_at": "2022-12-12T12:12:12.000000Z",
    "store_id": 1,
    "section_id": null,
    "section_order": null,
    "products_linked": 0,
    "products": []
  }
}
```

# Delete a group (/docs/api/groups/delete-a-group)

This endpoint allows you to delete a group.

<Warn>
  This will permanently delete the group and its details.
</Warn>

## Endpoint

- Method: `DELETE`

- Path: `/v2/groups/{group}`

- Full URL: `https://sell.app/api/v2/groups/{group}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `group` (`integer`, required): The group path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "title": {
          "type": "string"
        },
        "order": {
          "type": "integer"
        },
        "image": {
          "type": "null"
        },
        "unlisted": {
          "type": "boolean"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "store_id": {
          "type": "integer"
        },
        "section_id": {
          "type": "null"
        },
        "section_order": {
          "type": "null"
        },
        "products_linked": {
          "type": "integer"
        },
        "products": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "title": {
                "type": "string"
              },
              "description": {
                "type": "string"
              }
            },
            "required": [
              "id",
              "title",
              "description"
            ]
          }
        }
      },
      "required": [
        "id",
        "title",
        "order",
        "image",
        "unlisted",
        "created_at",
        "updated_at",
        "store_id",
        "section_id",
        "section_order",
        "products_linked",
        "products"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "title": "Rat race",
    "order": 1,
    "image": null,
    "unlisted": false,
    "created_at": "2022-12-12T12:12:12.000000Z",
    "updated_at": "2022-12-12T12:12:12.000000Z",
    "store_id": 1,
    "section_id": null,
    "section_order": null,
    "products_linked": 1,
    "products": [
      {
        "id": "1",
        "title": "This will make me rich!",
        "description": "I am sure of it, Pinky."
      }
    ]
  }
}
```

# Overview (/docs/api/groups)



Groups are a way to help make your storefront navigable in SellApp — they are a collection of products you've grouped together in a tidy bunch.

On this page, we'll dive into the different group endpoints you can use to manage groups programmatically. We'll look at how to query, create, update, and delete groups, as well as how to add and remove products within groups.

## Endpoints [#endpoints]

* [List all groups](/api/groups/list-all-groups)
* [Search groups](/api/groups/search-groups)
* [Create a group](/api/groups/create-a-group)
* [Retrieve a group](/api/groups/retrieve-a-group)
* [Update a group](/api/groups/update-a-group)
* [Delete a group](/api/groups/delete-a-group)
* [Add products to group](/api/groups/add-products-to-group)
* [Remove products from group](/api/groups/remove-products-from-group)
* [List all products within group](/api/groups/list-all-products-within-group)
* [Search products within group](/api/groups/search-products-within-group)
* [List specific product within group](/api/groups/list-specific-product-within-group)

## The group model [#the-group-model]

The group model contains all the information about your groups, including what products are in the group and the group's name, description, and image.

### Properties [#properties]

<Properties>
  <Property name="id" type="integer">
    The unique identifier for the group.
  </Property>

  <Property name="title" type="string">
    The group title.
  </Property>

  <Property name="order" type="integer">
    The order rank of the group.
  </Property>

  <Property name="image" type="object">
    The image belonging to the group.
  </Property>

  <Property name="unlisted" type="boolean">
    Whether the group is unlisted or not. If set to true, the group will only be accessible via a direct link.
  </Property>

  <Property name="created_at" type="timestamp">
    The time at which this group was first created.
  </Property>

  <Property name="updated_at" type="timestamp">
    The time at which this group was last updated.
  </Property>

  <Property name="store_id" type="integer">
    The ID of the store this group belongs to.
  </Property>

  <Property name="section_id" type="integer">
    The ID of the section this group belongs to.
  </Property>

  <Property name="section_order" type="integer">
    The order rank of the group within the section it belongs to.
  </Property>

  <Property name="products_linked" type="integer">
    The amount of products linked to this group.
  </Property>

  <Property name="products" type="array">
    The products linked to this group, containing three types of info:

    * `id`: The product ID
    * `title`: The product title
    * `description`: The product description
  </Property>
</Properties>

***


# List all groups (/docs/api/groups/list-all-groups)

This endpoint allows you to retrieve a paginated list of all your groups. By default, a maximum of fifteen groups are shown per page.

## Endpoint

- Method: `GET`

- Path: `/v2/groups`

- Full URL: `https://sell.app/api/v2/groups`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
- `limit` (`integer`, optional): Limit the number of blacklist rules returned.
- `page` (`integer`, optional): The page number you are attempting to access.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          },
          "order": {
            "type": "integer"
          },
          "image": {
            "type": "null"
          },
          "unlisted": {
            "type": "boolean"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "store_id": {
            "type": "integer"
          },
          "section_id": {
            "type": "null"
          },
          "section_order": {
            "type": "null"
          },
          "products_linked": {
            "type": "integer"
          },
          "products": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "title": {
                  "type": "string"
                },
                "description": {
                  "type": "string"
                }
              },
              "required": [
                "id",
                "title",
                "description"
              ]
            }
          }
        },
        "required": [
          "id",
          "title",
          "order",
          "image",
          "unlisted",
          "created_at",
          "updated_at",
          "store_id",
          "section_id",
          "section_order",
          "products_linked",
          "products"
        ]
      }
    },
    "links": {
      "type": "object",
      "properties": {}
    },
    "meta": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "data",
    "links",
    "meta"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "title": "Rat race",
      "order": 1,
      "image": null,
      "unlisted": false,
      "created_at": "2022-12-12T12:12:12.000000Z",
      "updated_at": "2022-12-12T12:12:12.000000Z",
      "store_id": 1,
      "section_id": null,
      "section_order": null,
      "products_linked": 1,
      "products": [
        {
          "id": "1",
          "title": "This will make me rich!",
          "description": "I am sure of it, Pinky."
        }
      ]
    }
  ],
  "links": {},
  "meta": {}
}
```

# List all products within group (/docs/api/groups/list-all-products-within-group)

This endpoint allows you to retrieve a paginated list of all the products within your group. By default, a maximum of fifteen products are shown per page.

## Endpoint

- Method: `GET`

- Path: `/v2/groups/{group}/products`

- Full URL: `https://sell.app/api/v2/groups/{group}/products`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `group` (`integer`, required): The group path parameter.

## Query Parameters
- `limit` (`integer`, optional): Limit the number of blacklist rules returned.
- `page` (`integer`, optional): The page number you are attempting to access.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "images": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "order": {
            "type": "integer"
          },
          "visibility": {
            "type": "string"
          },
          "delivery_text": {
            "type": "null"
          },
          "additional_information": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "warranty": {
            "type": "object",
            "properties": {
              "text": {
                "type": "string"
              },
              "time": {
                "type": "null"
              },
              "preferredUnit": {
                "type": "string"
              }
            },
            "required": [
              "text",
              "time",
              "preferredUnit"
            ]
          },
          "other_settings": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "deleted_at": {
            "type": "null"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "store_id": {
            "type": "integer"
          },
          "category_id": {
            "type": "null"
          },
          "section_id": {
            "type": "null"
          },
          "section_order": {
            "type": "null"
          },
          "is_discoverable": {
            "type": "integer"
          },
          "pivot": {
            "type": "object",
            "properties": {
              "group_id": {
                "type": "integer"
              },
              "listing_id": {
                "type": "integer"
              },
              "order": {
                "type": "integer"
              }
            },
            "required": [
              "group_id",
              "listing_id",
              "order"
            ]
          },
          "default_price": {
            "type": "object",
            "properties": {
              "price": {
                "type": "string"
              },
              "currency": {
                "type": "string"
              }
            },
            "required": [
              "price",
              "currency"
            ]
          }
        },
        "required": [
          "id",
          "title",
          "slug",
          "description",
          "images",
          "order",
          "visibility",
          "delivery_text",
          "additional_information",
          "warranty",
          "other_settings",
          "deleted_at",
          "created_at",
          "updated_at",
          "store_id",
          "category_id",
          "section_id",
          "section_order",
          "is_discoverable",
          "pivot",
          "default_price"
        ]
      }
    },
    "links": {
      "type": "object",
      "properties": {}
    },
    "meta": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "data",
    "links",
    "meta"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "title": "This will make me rich!",
      "slug": "serial",
      "description": "<p>I am sure of it, Pinky.</p>",
      "images": [],
      "order": 1,
      "visibility": "PUBLIC",
      "delivery_text": null,
      "additional_information": [],
      "warranty": {
        "text": "",
        "time": null,
        "preferredUnit": "MINUTES"
      },
      "other_settings": [],
      "deleted_at": null,
      "created_at": "2022-12-12T12:12:12.000000Z",
      "updated_at": "2022-12-12T12:12:12.000000Z",
      "store_id": 1,
      "category_id": null,
      "section_id": null,
      "section_order": null,
      "is_discoverable": 1,
      "pivot": {
        "group_id": 1,
        "listing_id": 1,
        "order": 1
      },
      "default_price": {
        "price": "500",
        "currency": "USD"
      }
    }
  ],
  "links": {},
  "meta": {}
}
```

# List specific product within group (/docs/api/groups/list-specific-product-within-group)

This endpoint allows you to retrieve a specific product from within a group.

## Endpoint

- Method: `GET`

- Path: `/v2/groups/{group}/products/{product}`

- Full URL: `https://sell.app/api/v2/groups/{group}/products/{product}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `group` (`integer`, required): The group path parameter.
- `product` (`integer`, required): The product path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "title": {
          "type": "string"
        },
        "slug": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "images": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "order": {
          "type": "integer"
        },
        "visibility": {
          "type": "string"
        },
        "delivery_text": {
          "type": "null"
        },
        "additional_information": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "warranty": {
          "type": "object",
          "properties": {
            "text": {
              "type": "string"
            },
            "time": {
              "type": "null"
            },
            "preferredUnit": {
              "type": "string"
            }
          },
          "required": [
            "text",
            "time",
            "preferredUnit"
          ]
        },
        "other_settings": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "deleted_at": {
          "type": "null"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "store_id": {
          "type": "integer"
        },
        "category_id": {
          "type": "null"
        },
        "section_id": {
          "type": "null"
        },
        "section_order": {
          "type": "null"
        },
        "is_discoverable": {
          "type": "integer"
        },
        "pivot": {
          "type": "object",
          "properties": {
            "group_id": {
              "type": "integer"
            },
            "listing_id": {
              "type": "integer"
            },
            "order": {
              "type": "integer"
            }
          },
          "required": [
            "group_id",
            "listing_id",
            "order"
          ]
        }
      },
      "required": [
        "id",
        "title",
        "slug",
        "description",
        "images",
        "order",
        "visibility",
        "delivery_text",
        "additional_information",
        "warranty",
        "other_settings",
        "deleted_at",
        "created_at",
        "updated_at",
        "store_id",
        "category_id",
        "section_id",
        "section_order",
        "is_discoverable",
        "pivot"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "title": "This will make me rich!",
    "slug": "serial",
    "description": "<p>I am sure of it, Pinky.</p>",
    "images": [],
    "order": 1,
    "visibility": "PUBLIC",
    "delivery_text": null,
    "additional_information": [],
    "warranty": {
      "text": "",
      "time": null,
      "preferredUnit": "MINUTES"
    },
    "other_settings": [],
    "deleted_at": null,
    "created_at": "2022-12-12T12:12:12.000000Z",
    "updated_at": "2022-12-12T12:12:12.000000Z",
    "store_id": 1,
    "category_id": null,
    "section_id": null,
    "section_order": null,
    "is_discoverable": 1,
    "pivot": {
      "group_id": 1,
      "listing_id": 1,
      "order": 1
    }
  }
}
```

# Remove products from group (/docs/api/groups/remove-products-from-group)

This endpoint allows you to remove products from a group.

## Endpoint

- Method: `DELETE`

- Path: `/v2/groups/{group}/products/detach`

- Full URL: `https://sell.app/api/v2/groups/{group}/products/detach`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `group` (`integer`, required): The group path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "resources": {
      "type": "array",
      "items": {
        "type": "integer"
      }
    }
  },
  "required": [
    "resources"
  ]
}
```

Example:

```json
{
  "resources": [
    1
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "detached": {
      "type": "array",
      "items": {
        "type": "integer"
      }
    }
  },
  "required": [
    "detached"
  ]
}
```

Example:

```json
{
  "detached": [
    1
  ]
}
```

# Retrieve a group (/docs/api/groups/retrieve-a-group)

This endpoint allows you to retrieve a specific group by providing the unique identifier. Refer to [the list](/api/groups#the-group-model) to see which properties are included with group objects.

## Endpoint

- Method: `GET`

- Path: `/v2/groups/{group}`

- Full URL: `https://sell.app/api/v2/groups/{group}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `group` (`integer`, required): The group path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "title": {
          "type": "string"
        },
        "order": {
          "type": "integer"
        },
        "image": {
          "type": "null"
        },
        "unlisted": {
          "type": "boolean"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "store_id": {
          "type": "integer"
        },
        "section_id": {
          "type": "null"
        },
        "section_order": {
          "type": "null"
        },
        "products_linked": {
          "type": "integer"
        },
        "products": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "title": {
                "type": "string"
              },
              "description": {
                "type": "string"
              }
            },
            "required": [
              "id",
              "title",
              "description"
            ]
          }
        }
      },
      "required": [
        "id",
        "title",
        "order",
        "image",
        "unlisted",
        "created_at",
        "updated_at",
        "store_id",
        "section_id",
        "section_order",
        "products_linked",
        "products"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "title": "Rat race",
    "order": 1,
    "image": null,
    "unlisted": false,
    "created_at": "2022-12-12T12:12:12.000000Z",
    "updated_at": "2022-12-12T12:12:12.000000Z",
    "store_id": 1,
    "section_id": null,
    "section_order": null,
    "products_linked": 1,
    "products": [
      {
        "id": "1",
        "title": "This will make me rich!",
        "description": "I am sure of it, Pinky."
      }
    ]
  }
}
```

# Search groups (/docs/api/groups/search-groups)

Search groups with filters, search terms, includes, and sort instructions in a JSON request body.

## Endpoint

- Method: `POST`

- Path: `/v2/groups/search`

- Full URL: `https://sell.app/api/v2/groups/search`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "filters": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "field": {
            "type": "string"
          },
          "operator": {
            "type": "string",
            "default": "="
          },
          "value": {},
          "type": {
            "type": "string",
            "enum": [
              "and",
              "or"
            ],
            "default": "and"
          },
          "nested": {
            "type": "array",
            "items": {
              "type": "object",
              "additionalProperties": true
            }
          }
        },
        "required": [
          "field"
        ]
      }
    },
    "sort": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "field": {
            "type": "string"
          },
          "direction": {
            "type": "string",
            "enum": [
              "asc",
              "desc"
            ],
            "default": "asc"
          }
        },
        "required": [
          "field"
        ]
      }
    },
    "search": {
      "type": "object",
      "properties": {
        "value": {
          "type": [
            "string",
            "null"
          ]
        },
        "case_sensitive": {
          "type": "boolean"
        }
      }
    },
    "includes": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "relation": {
            "type": "string"
          }
        },
        "required": [
          "relation"
        ]
      }
    }
  }
}
```

Example:

```json
{
  "filters": [
    {
      "field": "id",
      "operator": "=",
      "value": 1
    }
  ],
  "sort": [
    {
      "field": "created_at",
      "direction": "desc"
    }
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          },
          "order": {
            "type": "integer"
          },
          "image": {
            "type": "null"
          },
          "unlisted": {
            "type": "boolean"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "store_id": {
            "type": "integer"
          },
          "section_id": {
            "type": "null"
          },
          "section_order": {
            "type": "null"
          },
          "products_linked": {
            "type": "integer"
          },
          "products": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "title": {
                  "type": "string"
                },
                "description": {
                  "type": "string"
                }
              },
              "required": [
                "id",
                "title",
                "description"
              ]
            }
          }
        },
        "required": [
          "id",
          "title",
          "order",
          "image",
          "unlisted",
          "created_at",
          "updated_at",
          "store_id",
          "section_id",
          "section_order",
          "products_linked",
          "products"
        ]
      }
    },
    "links": {
      "type": "object",
      "properties": {}
    },
    "meta": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "data",
    "links",
    "meta"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "title": "Rat race",
      "order": 1,
      "image": null,
      "unlisted": false,
      "created_at": "2022-12-12T12:12:12.000000Z",
      "updated_at": "2022-12-12T12:12:12.000000Z",
      "store_id": 1,
      "section_id": null,
      "section_order": null,
      "products_linked": 1,
      "products": [
        {
          "id": "1",
          "title": "This will make me rich!",
          "description": "I am sure of it, Pinky."
        }
      ]
    }
  ],
  "links": {},
  "meta": {}
}
```

# Search products within group (/docs/api/groups/search-products-within-group)

Search the products in a group with filters, search terms, includes, and sort instructions in a JSON request body.

## Endpoint

- Method: `POST`

- Path: `/v2/groups/{group}/products/search`

- Full URL: `https://sell.app/api/v2/groups/{group}/products/search`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `group` (`integer`, required): The group path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "filters": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "field": {
            "type": "string"
          },
          "operator": {
            "type": "string",
            "default": "="
          },
          "value": {},
          "type": {
            "type": "string",
            "enum": [
              "and",
              "or"
            ],
            "default": "and"
          },
          "nested": {
            "type": "array",
            "items": {
              "type": "object",
              "additionalProperties": true
            }
          }
        },
        "required": [
          "field"
        ]
      }
    },
    "sort": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "field": {
            "type": "string"
          },
          "direction": {
            "type": "string",
            "enum": [
              "asc",
              "desc"
            ],
            "default": "asc"
          }
        },
        "required": [
          "field"
        ]
      }
    },
    "search": {
      "type": "object",
      "properties": {
        "value": {
          "type": [
            "string",
            "null"
          ]
        },
        "case_sensitive": {
          "type": "boolean"
        }
      }
    },
    "includes": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "relation": {
            "type": "string"
          }
        },
        "required": [
          "relation"
        ]
      }
    }
  }
}
```

Example:

```json
{
  "filters": [
    {
      "field": "id",
      "operator": "=",
      "value": 1
    }
  ],
  "sort": [
    {
      "field": "created_at",
      "direction": "desc"
    }
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "images": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "order": {
            "type": "integer"
          },
          "visibility": {
            "type": "string"
          },
          "delivery_text": {
            "type": "null"
          },
          "additional_information": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "warranty": {
            "type": "object",
            "properties": {
              "text": {
                "type": "string"
              },
              "time": {
                "type": "null"
              },
              "preferredUnit": {
                "type": "string"
              }
            },
            "required": [
              "text",
              "time",
              "preferredUnit"
            ]
          },
          "other_settings": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "deleted_at": {
            "type": "null"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "store_id": {
            "type": "integer"
          },
          "category_id": {
            "type": "null"
          },
          "section_id": {
            "type": "null"
          },
          "section_order": {
            "type": "null"
          },
          "is_discoverable": {
            "type": "integer"
          },
          "pivot": {
            "type": "object",
            "properties": {
              "group_id": {
                "type": "integer"
              },
              "listing_id": {
                "type": "integer"
              },
              "order": {
                "type": "integer"
              }
            },
            "required": [
              "group_id",
              "listing_id",
              "order"
            ]
          },
          "default_price": {
            "type": "object",
            "properties": {
              "price": {
                "type": "string"
              },
              "currency": {
                "type": "string"
              }
            },
            "required": [
              "price",
              "currency"
            ]
          }
        },
        "required": [
          "id",
          "title",
          "slug",
          "description",
          "images",
          "order",
          "visibility",
          "delivery_text",
          "additional_information",
          "warranty",
          "other_settings",
          "deleted_at",
          "created_at",
          "updated_at",
          "store_id",
          "category_id",
          "section_id",
          "section_order",
          "is_discoverable",
          "pivot",
          "default_price"
        ]
      }
    },
    "links": {
      "type": "object",
      "properties": {}
    },
    "meta": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "data",
    "links",
    "meta"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "title": "This will make me rich!",
      "slug": "serial",
      "description": "<p>I am sure of it, Pinky.</p>",
      "images": [],
      "order": 1,
      "visibility": "PUBLIC",
      "delivery_text": null,
      "additional_information": [],
      "warranty": {
        "text": "",
        "time": null,
        "preferredUnit": "MINUTES"
      },
      "other_settings": [],
      "deleted_at": null,
      "created_at": "2022-12-12T12:12:12.000000Z",
      "updated_at": "2022-12-12T12:12:12.000000Z",
      "store_id": 1,
      "category_id": null,
      "section_id": null,
      "section_order": null,
      "is_discoverable": 1,
      "pivot": {
        "group_id": 1,
        "listing_id": 1,
        "order": 1
      },
      "default_price": {
        "price": "500",
        "currency": "USD"
      }
    }
  ],
  "links": {},
  "meta": {}
}
```

# Update a group (/docs/api/groups/update-a-group)

This endpoint allows you to perform an update on a group.

## Endpoint

- Method: `PATCH`

- Path: `/v2/groups/{group}`

- Full URL: `https://sell.app/api/v2/groups/{group}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `group` (`integer`, required): The group path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "title": {
      "type": "string"
    },
    "unlisted": {
      "type": "boolean"
    },
    "order": {
      "type": [
        "integer",
        "null"
      ]
    }
  }
}
```

### Content Type: `multipart/form-data`

Schema:

```json
{
  "type": "object",
  "properties": {
    "title": {
      "type": "string"
    },
    "unlisted": {
      "type": "boolean"
    },
    "order": {
      "type": [
        "integer",
        "null"
      ]
    },
    "image": {
      "type": "string",
      "format": "binary"
    }
  }
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "title": {
          "type": "string"
        },
        "order": {
          "type": "integer"
        },
        "image": {
          "type": "null"
        },
        "unlisted": {
          "type": "boolean"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "store_id": {
          "type": "integer"
        },
        "section_id": {
          "type": "null"
        },
        "section_order": {
          "type": "null"
        },
        "products_linked": {
          "type": "integer"
        },
        "products": {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      },
      "required": [
        "id",
        "title",
        "order",
        "image",
        "unlisted",
        "created_at",
        "updated_at",
        "store_id",
        "section_id",
        "section_order",
        "products_linked",
        "products"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "title": "Rat race",
    "order": 1,
    "image": null,
    "unlisted": true,
    "created_at": "2022-12-12T12:12:12.000000Z",
    "updated_at": "2022-12-12T12:12:12.000000Z",
    "store_id": 1,
    "section_id": null,
    "section_order": null,
    "products_linked": 0,
    "products": []
  }
}
```

# Overview (/docs/api/license-instances)



The Licenses API endpoints helps you manage licenses purchased through your store. You can activate licenses for specific instances, validate existing instances, and manage the associated instances. This is useful for integrating license checks directly into your software or external systems.

<Note>
  License instances are part of a [license key](/api/licenses). Each license key
  can be linked to multiple instances. Whenever you activate a license key, you
  create a new instance of the license key.
</Note>

## Endpoints [#endpoints]

* [List all license instances](/api/license-instances/list-all-license-instances)
* [List license instances for a license key](/api/license-instances/list-license-instances)
* [Retrieve a license instance](/api/license-instances/retrieve-a-license-instance)

## The license key model [#the-license-key-model]

The license key model represents a single license key purchased by a customer.

### Properties [#properties]

<Properties>
  <Property name="id" type="integer">
    *(read-only)* The unique identifier for the license key.
  </Property>

  <Property name="key" type="string">
    *(read-only)* The actual license key string
  </Property>

  <Property name="limit" type="integer | null">
    The maximum number of instances this key can be activated on. `null` means unlimited activations.
  </Property>

  <Property name="active" type="boolean">
    Whether the license key is currently active which you can modify via the API and which is unrelated to the status. Inactive keys cannot be activated or validated successfully.
  </Property>

  <Property name="status" type="string">
    *(read-only)* The status of the license key, one of: `ACTIVE`, `INACTIVE`, `EXPIRED`
  </Property>

  <Property name="expires_at" type="timestamp | null">
    The timestamp when the license key expires. `null` means the license will never expire.
  </Property>

  <Property name="is_expired" type="boolean">
    Whether the license key is expired.
  </Property>

  <Property name="store_id" type="integer">
    *(read-only)* The ID of the store this license key belongs to.
  </Property>

  <Property name="order_id" type="integer | null">
    *(read-only)* The ID of the order associated with this license key.
  </Property>

  <Property name="invoice_id" type="integer | null">
    *(read-only)* The ID of the associated invoice V2, if applicable.
  </Property>

  <Property name="product_id" type="integer">
    *(read-only)* The ID of the product this license is for.
  </Property>

  <Property name="variant_id" type="integer">
    *(read-only)* The ID of the specific product variant this license is for.
  </Property>

  <Property name="customer_id" type="integer">
    *(read-only)* The ID of the customer that purchased this license key.
  </Property>

  <Property name="subscription_id" type="integer | null">
    *(read-only)* The ID of the associated subscription, if applicable.
  </Property>

  <Property name="created_at" type="timestamp">
    *(read-only)* Time at which the license key was created.
  </Property>

  <Property name="updated_at" type="timestamp">
    *(read-only)* Time at which the license key was last updated.
  </Property>
</Properties>

## The license instance model [#the-license-instance-model]

The license instance model represents a single activation of a license key on a specific device or identifier.

### Properties [#properties-1]

<Properties>
  <Property name="id" type="string (uuid)">
    *(read-only)* The unique identifier (UUID) of the license instance. &#x2A;*This is the `instance_id` used for validation.**
  </Property>

  <Property name="license_key_id" type="integer">
    *(read-only)* The unique identifier for the parent license key which this instance is linked to.
  </Property>

  <Property name="name" type="string">
    *(read-only)* The name provided during activation, which you can use to identify this instance (e.g., the customer's email or HWID).
  </Property>

  <Property name="store_id" type="integer">
    *(read-only)* The ID of the store this instance belongs to.
  </Property>

  <Property name="created_at" type="timestamp">
    *(read-only)* Time at which the instance was created (activation time).
  </Property>

  <Property name="updated_at" type="timestamp">
    *(read-only)* Time at which the instance was last updated.
  </Property>
</Properties>

***


# List all license instances (/docs/api/license-instances/list-all-license-instances)

Retrieve a paginated list of license instances across your store.

## Endpoint

- Method: `GET`

- Path: `/v2/license-key-instances`

- Full URL: `https://sell.app/api/v2/license-key-instances`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
- `limit` (`integer`, optional): Limit the number of blacklist rules returned.
- `page` (`integer`, optional): The page number you are attempting to access.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "license_key_id": {
            "type": "integer"
          },
          "name": {
            "type": "string"
          },
          "store_id": {
            "type": "integer"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "id",
          "license_key_id",
          "name",
          "store_id",
          "created_at",
          "updated_at"
        ]
      }
    },
    "links": {
      "type": "object",
      "properties": {}
    },
    "meta": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "data",
    "links",
    "meta"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": "9ebd37af-2077-42f9-9f88-d96cfc6ef1a8",
      "license_key_id": 1,
      "name": "zezima@osrs.com",
      "store_id": 1,
      "created_at": "2025-04-22T20:53:22.000000Z",
      "updated_at": "2025-04-22T20:53:22.000000Z"
    }
  ],
  "links": {},
  "meta": {}
}
```

# List license instances (/docs/api/license-instances/list-license-instances)

Retrieves a paginated list of all active instances (activations) associated with a specific license key.

Refer to [the license instance model](../license-instances#the-license-instance-model) section for details on the returned object structure.

## Endpoint

- Method: `GET`

- Path: `/v2/license-keys/{license_key}/instances`

- Full URL: `https://sell.app/api/v2/license-keys/{license_key}/instances`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `license_key` (`integer`, required): The license key path parameter.

## Query Parameters
- `limit` (`integer`, optional): Limit the number of blacklist rules returned.
- `page` (`integer`, optional): The page number you are attempting to access.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "license_key_id": {
            "type": "integer"
          },
          "name": {
            "type": "string"
          },
          "store_id": {
            "type": "integer"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "id",
          "license_key_id",
          "name",
          "store_id",
          "created_at",
          "updated_at"
        ]
      }
    },
    "links": {
      "type": "object",
      "properties": {}
    },
    "meta": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "data",
    "links",
    "meta"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": "9ebd37af-2077-42f9-9f88-d96cfc6ef1a8",
      "license_key_id": 1,
      "name": "zezima@osrs.com",
      "store_id": 1,
      "created_at": "2025-04-22T20:53:22.000000Z",
      "updated_at": "2025-04-22T20:53:22.000000Z"
    }
  ],
  "links": {},
  "meta": {}
}
```

# Retrieve a license instance (/docs/api/license-instances/retrieve-a-license-instance)

Retrieves the details of a specific license instance using the license key ID and the instance's unique UUID.

Refer to [the license instance model](../license-instances#the-license-instance-model) section for details on the returned object structure.

## Endpoint

- Method: `GET`

- Path: `/v2/license-keys/{license_key}/instances/{instance}`

- Full URL: `https://sell.app/api/v2/license-keys/{license_key}/instances/{instance}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `license_key` (`integer`, required): The license key path parameter.
- `instance` (`string`, required): The instance path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string"
        },
        "license_key_id": {
          "type": "integer"
        },
        "name": {
          "type": "string"
        },
        "store_id": {
          "type": "integer"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        }
      },
      "required": [
        "id",
        "license_key_id",
        "name",
        "store_id",
        "created_at",
        "updated_at"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": "9ebd37af-2077-42f9-9f88-d96cfc6ef1a8",
    "license_key_id": 1,
    "name": "zezima@osrs.com",
    "store_id": 1,
    "created_at": "2025-04-22T20:53:22.000000Z",
    "updated_at": "2025-04-22T20:53:22.000000Z"
  }
}
```

# Activate a license key (/docs/api/licenses/activate-a-license-key)

This endpoint activates a given license key and creates an instance of the license key. Activation registers a unique identifier (instance name) against the license key. If the activation is successful, it returns the details of the newly created `LicenseKeyInstance`, including its unique `id` which should be stored by the client/application for future validation.

Activation can fail if:

* The license key does not exist.
* The license key is inactive (`active` is false).
* The license key has expired (`expires_at` is in the past).
* The activation limit (`limit`) has been reached.

## Endpoint

- Method: `POST`

- Path: `/v2/licenses/activate`

- Full URL: `https://sell.app/api/v2/licenses/activate`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "license_key": {
      "type": "string"
    },
    "instance_name": {
      "type": "string"
    }
  },
  "required": [
    "license_key",
    "instance_name"
  ]
}
```

Example:

```json
{
  "license_key": "01965f1d-f038-7116-b57f-9e7ecb4e7b8f",
  "instance_name": "zezima@osrs.com"
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string"
        },
        "license_key_id": {
          "type": "integer"
        },
        "name": {
          "type": "string"
        },
        "store_id": {
          "type": "integer"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        }
      },
      "required": [
        "id",
        "license_key_id",
        "name",
        "store_id",
        "created_at",
        "updated_at"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": "9ebd37af-2077-42f9-9f88-d96cfc6ef1a8",
    "license_key_id": 1,
    "name": "zezima@osrs.com",
    "store_id": 1,
    "created_at": "2025-04-22T20:53:22.000000Z",
    "updated_at": "2025-04-22T20:53:22.000000Z"
  }
}
```

# Overview (/docs/api/licenses)



The Licenses API endpoints helps you manage licenses purchased through your store.

<Note>
  [License instances](/api/license-instances) are part of a license key. Each
  license key can be linked to multiple instances. Whenever you activate a
  license key, you create a new instance of the license key.
</Note>

## Endpoints [#endpoints]

* [Activate a license key](/api/licenses/activate-a-license-key)
* [Validate a license key](/api/licenses/validate-a-license-key)
* [List all license keys](/api/licenses/list-all-license-keys)
* [Retrieve a license key](/api/licenses/retrieve-a-license-key)
* [Update a license key](/api/licenses/update-a-license-key)

## The license key model [#the-license-key-model]

The license key model represents a single license key purchased by a customer.

### Properties [#properties]

<Properties>
  <Property name="id" type="integer">
    *(read-only)* The unique identifier for the license key.
  </Property>

  <Property name="key" type="string">
    *(read-only)* The actual license key string
  </Property>

  <Property name="limit" type="integer | null">
    The maximum number of instances this key can be activated on. `null` means unlimited activations.
  </Property>

  <Property name="active" type="boolean">
    Whether the license key is currently active which you can modify via the API and which is unrelated to the status. Inactive keys cannot be activated or validated successfully.
  </Property>

  <Property name="status" type="string">
    *(read-only)* The status of the license key, one of: `ACTIVE`, `INACTIVE`, `EXPIRED`
  </Property>

  <Property name="expires_at" type="timestamp | null">
    The timestamp when the license key expires. `null` means the license will never expire.
  </Property>

  <Property name="is_expired" type="boolean">
    Whether the license key is expired.
  </Property>

  <Property name="store_id" type="integer">
    *(read-only)* The ID of the store this license key belongs to.
  </Property>

  <Property name="order_id" type="integer | null">
    *(read-only)* The ID of the order associated with this license key.
  </Property>

  <Property name="invoice_id" type="integer | null">
    *(read-only)* The ID of the associated invoice V2, if applicable.
  </Property>

  <Property name="product_id" type="integer">
    *(read-only)* The ID of the product this license is for.
  </Property>

  <Property name="variant_id" type="integer">
    *(read-only)* The ID of the specific product variant this license is for.
  </Property>

  <Property name="customer_id" type="integer">
    *(read-only)* The ID of the customer that purchased this license key.
  </Property>

  <Property name="subscription_id" type="integer | null">
    *(read-only)* The ID of the associated subscription, if applicable.
  </Property>

  <Property name="created_at" type="timestamp">
    *(read-only)* Time at which the license key was created.
  </Property>

  <Property name="updated_at" type="timestamp">
    *(read-only)* Time at which the license key was last updated.
  </Property>
</Properties>

## The license instance model [#the-license-instance-model]

The license instance model represents a single activation of a license key on a specific device or identifier.

### Properties [#properties-1]

<Properties>
  <Property name="id" type="string (uuid)">
    *(read-only)* The unique identifier (UUID) of the license instance. &#x2A;*This is the `instance_id` used for validation.**
  </Property>

  <Property name="license_key_id" type="integer">
    *(read-only)* The unique identifier for the parent license key which this instance is linked to.
  </Property>

  <Property name="name" type="string">
    *(read-only)* The name provided during activation, which you can use to identify this instance (e.g., the customer's email or HWID).
  </Property>

  <Property name="store_id" type="integer">
    *(read-only)* The ID of the store this instance belongs to.
  </Property>

  <Property name="created_at" type="timestamp">
    *(read-only)* Time at which the instance was created (activation time).
  </Property>

  <Property name="updated_at" type="timestamp">
    *(read-only)* Time at which the instance was last updated.
  </Property>
</Properties>

***


# List all license keys (/docs/api/licenses/list-all-license-keys)

Retrieves a paginated list of all license keys associated with your store. Standard pagination parameters (`limit`, `page`) can be used.

Refer to [the license key model](#the-license-key-model) section for details on the returned object structure.

### Optional Query Parameters [#optional-query-parameters]

<Properties>
  <Property name="limit" type="integer">
    Limit the number of license keys returned per page.
  </Property>

  <Property name="page" type="integer">
    The page number to retrieve.
  </Property>
</Properties>

## Endpoint

- Method: `GET`

- Path: `/v2/license-keys`

- Full URL: `https://sell.app/api/v2/license-keys`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
- `limit` (`integer`, optional): Limit the number of blacklist rules returned.
- `page` (`integer`, optional): The page number you are attempting to access.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "key": {
            "type": "string"
          },
          "limit": {
            "type": "integer"
          },
          "active": {
            "type": "integer"
          },
          "status": {
            "type": "string"
          },
          "expires_at": {
            "type": "string",
            "format": "date-time"
          },
          "is_expired": {
            "type": "integer"
          },
          "store_id": {
            "type": "integer"
          },
          "order_id": {
            "type": "integer"
          },
          "invoice_id": {
            "type": "integer"
          },
          "product_id": {
            "type": "integer"
          },
          "variant_id": {
            "type": "integer"
          },
          "customer_id": {
            "type": "integer"
          },
          "subscription_id": {
            "type": "null"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "id",
          "key",
          "limit",
          "active",
          "status",
          "expires_at",
          "is_expired",
          "store_id",
          "order_id",
          "invoice_id",
          "product_id",
          "variant_id",
          "customer_id",
          "subscription_id",
          "created_at",
          "updated_at"
        ]
      }
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "key": "01965f1d-f038-7116-b57f-9e7ecb4e7b8f",
      "limit": 4,
      "active": 1,
      "status": "ACTIVE",
      "expires_at": "2025-05-22T20:08:39.000000Z",
      "is_expired": 0,
      "store_id": 1,
      "order_id": 1,
      "invoice_id": 1,
      "product_id": 1,
      "variant_id": 1,
      "customer_id": 1,
      "subscription_id": null,
      "created_at": "2025-04-22T20:08:39.000000Z",
      "updated_at": "2025-04-22T20:08:39.000000Z"
    }
  ]
}
```

# Retrieve a license key (/docs/api/licenses/retrieve-a-license-key)

Retrieves the details of a specific license key by its unique ID (not key!)

Refer to [the license key model](../licenses#the-license-instance-model) section for details on the returned object structure.

## Endpoint

- Method: `GET`

- Path: `/v2/license-keys/{license_key}`

- Full URL: `https://sell.app/api/v2/license-keys/{license_key}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `license_key` (`integer`, required): The license key path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "key": {
          "type": "string"
        },
        "limit": {
          "type": "integer"
        },
        "active": {
          "type": "integer"
        },
        "status": {
          "type": "string"
        },
        "expires_at": {
          "type": "string",
          "format": "date-time"
        },
        "is_expired": {
          "type": "integer"
        },
        "store_id": {
          "type": "integer"
        },
        "order_id": {
          "type": "integer"
        },
        "invoice_id": {
          "type": "integer"
        },
        "product_id": {
          "type": "integer"
        },
        "variant_id": {
          "type": "integer"
        },
        "customer_id": {
          "type": "integer"
        },
        "subscription_id": {
          "type": "null"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        }
      },
      "required": [
        "id",
        "key",
        "limit",
        "active",
        "status",
        "expires_at",
        "is_expired",
        "store_id",
        "order_id",
        "invoice_id",
        "product_id",
        "variant_id",
        "customer_id",
        "subscription_id",
        "created_at",
        "updated_at"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "key": "01965f1d-f038-7116-b57f-9e7ecb4e7b8f",
    "limit": 4,
    "active": 1,
    "status": "ACTIVE",
    "expires_at": "2025-05-22T20:08:39.000000Z",
    "is_expired": 0,
    "store_id": 1,
    "order_id": 1,
    "invoice_id": 1,
    "product_id": 1,
    "variant_id": 1,
    "customer_id": 1,
    "subscription_id": null,
    "created_at": "2025-04-22T20:08:39.000000Z",
    "updated_at": "2025-04-22T20:08:39.000000Z"
  }
}
```

# Update a license key (/docs/api/licenses/update-a-license-key)

Updates specific properties of a license key. You can modify the activation limit, expiration date, and active status.

<Note>
  If you decrease the `limit` to a value lower than the current `instances_count`, the oldest instances will be automatically deleted to match the new limit.
</Note>

## Endpoint

- Method: `PATCH`

- Path: `/v2/license-keys/{license_key}`

- Full URL: `https://sell.app/api/v2/license-keys/{license_key}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `license_key` (`integer`, required): The license key path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "limit": {
      "type": [
        "integer",
        "null"
      ]
    },
    "expires_at": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time"
    },
    "active": {
      "type": [
        "boolean",
        "null"
      ]
    }
  }
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "key": {
          "type": "string"
        },
        "limit": {
          "type": "integer"
        },
        "active": {
          "type": "integer"
        },
        "status": {
          "type": "string"
        },
        "expires_at": {
          "type": "string",
          "format": "date-time"
        },
        "is_expired": {
          "type": "integer"
        },
        "store_id": {
          "type": "integer"
        },
        "order_id": {
          "type": "integer"
        },
        "invoice_id": {
          "type": "integer"
        },
        "product_id": {
          "type": "integer"
        },
        "variant_id": {
          "type": "integer"
        },
        "customer_id": {
          "type": "integer"
        },
        "subscription_id": {
          "type": "null"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "instances_count": {
          "type": "integer"
        }
      },
      "required": [
        "id",
        "key",
        "limit",
        "active",
        "status",
        "expires_at",
        "is_expired",
        "store_id",
        "order_id",
        "invoice_id",
        "product_id",
        "variant_id",
        "customer_id",
        "subscription_id",
        "created_at",
        "updated_at",
        "instances_count"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "key": "01965f1d-f038-7116-b57f-9e7ecb4e7b8f",
    "limit": 10,
    "active": 0,
    "status": "ACTIVE",
    "expires_at": "2025-05-03T20:00:00.000000Z",
    "is_expired": 0,
    "store_id": 1,
    "order_id": 1,
    "invoice_id": 1,
    "product_id": 1,
    "variant_id": 1,
    "customer_id": 1,
    "subscription_id": null,
    "created_at": "2025-04-22T20:08:39.000000Z",
    "updated_at": "2025-04-22T21:20:51.000000Z",
    "instances_count": 4
  }
}
```

# Validate a license key (/docs/api/licenses/validate-a-license-key)

Checks if a given license key and instance ID pair represents a valid, active license activation. This is the primary endpoint to use within your application to verify a user's license status periodically.

Validation checks if:

* The license key exists.
* The license key is currently `active`.
* The license key has not expired (`expires_at`).
* The provided `instance_id` matches an existing activation for that license key.

## Endpoint

- Method: `POST`

- Path: `/v2/licenses/validate`

- Full URL: `https://sell.app/api/v2/licenses/validate`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "license_key": {
      "type": "string"
    },
    "instance_id": {
      "type": "string"
    }
  },
  "required": [
    "license_key"
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "valid": {
          "type": "boolean"
        },
        "license_key": {
          "type": "object",
          "properties": {
            "id": {
              "type": "integer"
            },
            "key": {
              "type": "string"
            },
            "limit": {
              "type": "integer"
            },
            "active": {
              "type": "integer"
            },
            "status": {
              "type": "string"
            },
            "expires_at": {
              "type": "string",
              "format": "date-time"
            },
            "is_expired": {
              "type": "integer"
            },
            "store_id": {
              "type": "integer"
            },
            "order_id": {
              "type": "integer"
            },
            "invoice_id": {
              "type": "integer"
            },
            "product_id": {
              "type": "integer"
            },
            "variant_id": {
              "type": "integer"
            },
            "customer_id": {
              "type": "integer"
            },
            "subscription_id": {
              "type": "null"
            },
            "created_at": {
              "type": "string",
              "format": "date-time"
            },
            "updated_at": {
              "type": "string",
              "format": "date-time"
            },
            "instances_count": {
              "type": "integer"
            }
          },
          "required": [
            "id",
            "key",
            "limit",
            "active",
            "status",
            "expires_at",
            "is_expired",
            "store_id",
            "order_id",
            "invoice_id",
            "product_id",
            "variant_id",
            "customer_id",
            "subscription_id",
            "created_at",
            "updated_at",
            "instances_count"
          ]
        },
        "instance": {
          "type": "object",
          "properties": {
            "id": {
              "type": "string"
            },
            "license_key_id": {
              "type": "integer"
            },
            "name": {
              "type": "string"
            },
            "store_id": {
              "type": "integer"
            },
            "created_at": {
              "type": "string",
              "format": "date-time"
            },
            "updated_at": {
              "type": "string",
              "format": "date-time"
            }
          },
          "required": [
            "id",
            "license_key_id",
            "name",
            "store_id",
            "created_at",
            "updated_at"
          ]
        }
      },
      "required": [
        "valid",
        "license_key",
        "instance"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "valid": true,
    "license_key": {
      "id": 1,
      "key": "01965f1d-f038-7116-b57f-9e7ecb4e7b8f",
      "limit": 4,
      "active": 1,
      "status": "ACTIVE",
      "expires_at": "2025-05-22T20:08:39.000000Z",
      "is_expired": 0,
      "store_id": 1,
      "order_id": 1,
      "invoice_id": 1,
      "product_id": 218,
      "variant_id": 228,
      "customer_id": 1,
      "subscription_id": null,
      "created_at": "2025-04-22T20:08:39.000000Z",
      "updated_at": "2025-04-22T20:08:39.000000Z",
      "instances_count": 4
    },
    "instance": {
      "id": "9ebd3be0-de72-4da7-805e-bc99d1ac1186",
      "license_key_id": 1,
      "name": "zezima@osrs.com",
      "store_id": 1,
      "created_at": "2025-04-22T21:05:06.000000Z",
      "updated_at": "2025-04-22T21:05:06.000000Z"
    }
  }
}
```

# Create a checkout session (/docs/api/invoices/create-a-checkout-session)

This endpoint creates a checkout session for a pending invoice.

A practical example:

1. You first create an invoice via the [the create an invoice](#create-an-invoice) endpoint
2. Then generate a checkout session via this endpoint.
3. Finally, you retrieve the `payment_url` you receive in the response, and show this to your customer as a button, or redirect them to the respective URL.

<Note>
  If the invoice is priced as zero, which means it's a free product, the invoice will instead be marked as completed.
</Note>

See the code examples for how to create a new invoice payment URL with the SellApp API.

## Endpoint

- Method: `POST`

- Path: `/v2/invoices/{invoice}/checkout`

- Full URL: `https://sell.app/api/v2/invoices/{invoice}/checkout`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `invoice` (`integer`, required): The invoice path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "message": {
      "type": "string"
    },
    "payment_url": {
      "type": "string"
    },
    "invoice": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "payment": {
          "type": "object",
          "properties": {
            "fee": {
              "type": "object",
              "properties": {
                "base": {
                  "type": "string"
                },
                "currency": {
                  "type": "string"
                },
                "units": {
                  "type": "integer"
                },
                "vat": {
                  "type": "integer"
                },
                "total": {
                  "type": "object",
                  "properties": {
                    "exclusive": {
                      "type": "string"
                    },
                    "inclusive": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "exclusive",
                    "inclusive"
                  ]
                }
              },
              "required": [
                "base",
                "currency",
                "units",
                "vat",
                "total"
              ]
            },
            "gateway": {
              "type": "object",
              "properties": {
                "data": {
                  "type": "object",
                  "properties": {
                    "total": {
                      "type": "object",
                      "properties": {
                        "base": {
                          "type": "string"
                        },
                        "currency": {
                          "type": "string"
                        },
                        "units": {
                          "type": "integer"
                        },
                        "vat": {
                          "type": "integer"
                        },
                        "total": {
                          "type": "object",
                          "properties": {
                            "exclusive": {
                              "type": "string"
                            },
                            "inclusive": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "exclusive",
                            "inclusive"
                          ]
                        }
                      },
                      "required": [
                        "base",
                        "currency",
                        "units",
                        "vat",
                        "total"
                      ]
                    },
                    "customer_email": {
                      "type": "string"
                    },
                    "transaction_id": {
                      "type": "string"
                    },
                    "checkout_url": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "total",
                    "customer_email",
                    "transaction_id",
                    "checkout_url"
                  ]
                },
                "type": {
                  "type": "string"
                }
              },
              "required": [
                "data",
                "type"
              ]
            },
            "subtotal": {
              "type": "object",
              "properties": {
                "base": {
                  "type": "string"
                },
                "currency": {
                  "type": "string"
                },
                "units": {
                  "type": "integer"
                },
                "vat": {
                  "type": "integer"
                },
                "total": {
                  "type": "object",
                  "properties": {
                    "exclusive": {
                      "type": "string"
                    },
                    "inclusive": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "exclusive",
                    "inclusive"
                  ]
                }
              },
              "required": [
                "base",
                "currency",
                "units",
                "vat",
                "total"
              ]
            },
            "expires_at": {
              "type": "string",
              "format": "date-time"
            },
            "full_price": {
              "type": "object",
              "properties": {
                "base": {
                  "type": "string"
                },
                "currency": {
                  "type": "string"
                },
                "units": {
                  "type": "integer"
                },
                "vat": {
                  "type": "integer"
                },
                "total": {
                  "type": "object",
                  "properties": {
                    "exclusive": {
                      "type": "string"
                    },
                    "inclusive": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "exclusive",
                    "inclusive"
                  ]
                }
              },
              "required": [
                "base",
                "currency",
                "units",
                "vat",
                "total"
              ]
            },
            "original_amount": {
              "type": "object",
              "properties": {
                "base": {
                  "type": "string"
                },
                "currency": {
                  "type": "string"
                },
                "units": {
                  "type": "integer"
                },
                "vat": {
                  "type": "integer"
                },
                "total": {
                  "type": "object",
                  "properties": {
                    "exclusive": {
                      "type": "string"
                    },
                    "inclusive": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "exclusive",
                    "inclusive"
                  ]
                }
              },
              "required": [
                "base",
                "currency",
                "units",
                "vat",
                "total"
              ]
            }
          },
          "required": [
            "fee",
            "gateway",
            "subtotal",
            "expires_at",
            "full_price",
            "original_amount"
          ]
        },
        "status": {
          "type": "object",
          "properties": {
            "history": {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "status": {
              "type": "object",
              "properties": {
                "setAt": {
                  "type": "string",
                  "format": "date-time"
                },
                "status": {
                  "type": "string"
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time"
                }
              },
              "required": [
                "setAt",
                "status",
                "updatedAt"
              ]
            }
          },
          "required": [
            "history",
            "status"
          ]
        },
        "webhooks": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "feedback": {
          "type": "string"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "store_id": {
          "type": "integer"
        },
        "coupon_id": {
          "type": "null"
        },
        "subscription_id": {
          "type": "null"
        },
        "customer_information": {
          "type": "object",
          "properties": {
            "id": {
              "type": "integer"
            },
            "email": {
              "type": "string"
            },
            "country": {
              "type": "string"
            },
            "location": {
              "type": "string"
            },
            "ip": {
              "type": "string"
            },
            "proxied": {
              "type": "boolean"
            },
            "browser_agent": {
              "type": "string"
            },
            "vat": {
              "type": "object",
              "properties": {
                "amount": {
                  "type": "integer"
                },
                "country": {
                  "type": "string"
                }
              },
              "required": [
                "amount",
                "country"
              ]
            }
          },
          "required": [
            "id",
            "email",
            "country",
            "location",
            "ip",
            "proxied",
            "browser_agent",
            "vat"
          ]
        },
        "product_variants": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "id": {
                "type": "integer"
              },
              "product_id": {
                "type": "integer"
              },
              "title": {
                "type": "string"
              }
            },
            "required": [
              "id",
              "product_id",
              "title"
            ]
          }
        }
      },
      "required": [
        "id",
        "payment",
        "status",
        "webhooks",
        "feedback",
        "created_at",
        "updated_at",
        "store_id",
        "coupon_id",
        "subscription_id",
        "customer_information",
        "product_variants"
      ]
    }
  },
  "required": [
    "message",
    "invoice"
  ]
}
```

Example:

```json
{
  "message": "A new payment session has been generated.",
  "payment_url": "https://commerce.coinbase.com/charges/CQEGF35V",
  "invoice": {
    "id": 1,
    "payment": {
      "fee": {
        "base": "0",
        "currency": "USD",
        "units": 1,
        "vat": 0,
        "total": {
          "exclusive": "0",
          "inclusive": "0"
        }
      },
      "gateway": {
        "data": {
          "total": {
            "base": "1999",
            "currency": "USD",
            "units": 1,
            "vat": 0,
            "total": {
              "exclusive": "1999",
              "inclusive": "1999"
            }
          },
          "customer_email": "customer@example.com",
          "transaction_id": "CQEGF35V",
          "checkout_url": "https://commerce.coinbase.com/charges/CQEGF35V"
        },
        "type": "COINBASE"
      },
      "subtotal": {
        "base": "1999",
        "currency": "USD",
        "units": 1,
        "vat": 0,
        "total": {
          "exclusive": "1999",
          "inclusive": "1999"
        }
      },
      "expires_at": "2024-01-09T23:50:11.000000Z",
      "full_price": {
        "base": "1999",
        "currency": "USD",
        "units": 1,
        "vat": 0,
        "total": {
          "exclusive": "1999",
          "inclusive": "1999"
        }
      },
      "original_amount": {
        "base": "1999",
        "currency": "USD",
        "units": 1,
        "vat": 0,
        "total": {
          "exclusive": "1999",
          "inclusive": "1999"
        }
      }
    },
    "status": {
      "history": [],
      "status": {
        "setAt": "2024-01-09T14:50:11.000000Z",
        "status": "PENDING",
        "updatedAt": "2024-01-09T18:00:50.000000Z"
      }
    },
    "webhooks": [],
    "feedback": "",
    "created_at": "2024-01-09T14:50:11.000000Z",
    "updated_at": "2024-01-09T18:00:50.000000Z",
    "store_id": 1,
    "coupon_id": null,
    "subscription_id": null,
    "customer_information": {
      "id": 123,
      "email": "customer@example.com",
      "country": "Germany",
      "location": "Munich",
      "ip": "1.3.3.7",
      "proxied": false,
      "browser_agent": "Mozilla/4.9 (Windows 98; sl-SI; rv:1.9.1.20) Gecko/20110422 Firefox/21.0",
      "vat": {
        "amount": 0,
        "country": "DE"
      }
    },
    "product_variants": [
      {
        "id": 117214,
        "product_id": 97850,
        "title": "SellApp Platform Balance"
      }
    ]
  }
}
```

### 201

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "message": {
      "type": "string"
    },
    "payment_url": {
      "type": "string"
    },
    "invoice": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "payment": {
          "type": "object",
          "properties": {
            "fee": {
              "type": "object",
              "properties": {
                "base": {
                  "type": "string"
                },
                "currency": {
                  "type": "string"
                },
                "units": {
                  "type": "integer"
                },
                "vat": {
                  "type": "integer"
                },
                "total": {
                  "type": "object",
                  "properties": {
                    "exclusive": {
                      "type": "string"
                    },
                    "inclusive": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "exclusive",
                    "inclusive"
                  ]
                }
              },
              "required": [
                "base",
                "currency",
                "units",
                "vat",
                "total"
              ]
            },
            "gateway": {
              "type": "object",
              "properties": {
                "data": {
                  "type": "object",
                  "properties": {
                    "total": {
                      "type": "object",
                      "properties": {
                        "base": {
                          "type": "string"
                        },
                        "currency": {
                          "type": "string"
                        },
                        "units": {
                          "type": "integer"
                        },
                        "vat": {
                          "type": "integer"
                        },
                        "total": {
                          "type": "object",
                          "properties": {
                            "exclusive": {
                              "type": "string"
                            },
                            "inclusive": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "exclusive",
                            "inclusive"
                          ]
                        }
                      },
                      "required": [
                        "base",
                        "currency",
                        "units",
                        "vat",
                        "total"
                      ]
                    },
                    "customer_email": {
                      "type": "string"
                    },
                    "transaction_id": {
                      "type": "string"
                    },
                    "checkout_url": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "total",
                    "customer_email",
                    "transaction_id",
                    "checkout_url"
                  ]
                },
                "type": {
                  "type": "string"
                }
              },
              "required": [
                "data",
                "type"
              ]
            },
            "subtotal": {
              "type": "object",
              "properties": {
                "base": {
                  "type": "string"
                },
                "currency": {
                  "type": "string"
                },
                "units": {
                  "type": "integer"
                },
                "vat": {
                  "type": "integer"
                },
                "total": {
                  "type": "object",
                  "properties": {
                    "exclusive": {
                      "type": "string"
                    },
                    "inclusive": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "exclusive",
                    "inclusive"
                  ]
                }
              },
              "required": [
                "base",
                "currency",
                "units",
                "vat",
                "total"
              ]
            },
            "expires_at": {
              "type": "string",
              "format": "date-time"
            },
            "full_price": {
              "type": "object",
              "properties": {
                "base": {
                  "type": "string"
                },
                "currency": {
                  "type": "string"
                },
                "units": {
                  "type": "integer"
                },
                "vat": {
                  "type": "integer"
                },
                "total": {
                  "type": "object",
                  "properties": {
                    "exclusive": {
                      "type": "string"
                    },
                    "inclusive": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "exclusive",
                    "inclusive"
                  ]
                }
              },
              "required": [
                "base",
                "currency",
                "units",
                "vat",
                "total"
              ]
            },
            "original_amount": {
              "type": "object",
              "properties": {
                "base": {
                  "type": "string"
                },
                "currency": {
                  "type": "string"
                },
                "units": {
                  "type": "integer"
                },
                "vat": {
                  "type": "integer"
                },
                "total": {
                  "type": "object",
                  "properties": {
                    "exclusive": {
                      "type": "string"
                    },
                    "inclusive": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "exclusive",
                    "inclusive"
                  ]
                }
              },
              "required": [
                "base",
                "currency",
                "units",
                "vat",
                "total"
              ]
            }
          },
          "required": [
            "fee",
            "gateway",
            "subtotal",
            "expires_at",
            "full_price",
            "original_amount"
          ]
        },
        "status": {
          "type": "object",
          "properties": {
            "history": {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "status": {
              "type": "object",
              "properties": {
                "setAt": {
                  "type": "string",
                  "format": "date-time"
                },
                "status": {
                  "type": "string"
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time"
                }
              },
              "required": [
                "setAt",
                "status",
                "updatedAt"
              ]
            }
          },
          "required": [
            "history",
            "status"
          ]
        },
        "webhooks": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "feedback": {
          "type": "string"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "store_id": {
          "type": "integer"
        },
        "coupon_id": {
          "type": "null"
        },
        "subscription_id": {
          "type": "null"
        },
        "customer_information": {
          "type": "object",
          "properties": {
            "id": {
              "type": "integer"
            },
            "email": {
              "type": "string"
            },
            "country": {
              "type": "string"
            },
            "location": {
              "type": "string"
            },
            "ip": {
              "type": "string"
            },
            "proxied": {
              "type": "boolean"
            },
            "browser_agent": {
              "type": "string"
            },
            "vat": {
              "type": "object",
              "properties": {
                "amount": {
                  "type": "integer"
                },
                "country": {
                  "type": "string"
                }
              },
              "required": [
                "amount",
                "country"
              ]
            }
          },
          "required": [
            "id",
            "email",
            "country",
            "location",
            "ip",
            "proxied",
            "browser_agent",
            "vat"
          ]
        }
      },
      "required": [
        "id",
        "payment",
        "status",
        "webhooks",
        "feedback",
        "created_at",
        "updated_at",
        "store_id",
        "coupon_id",
        "subscription_id",
        "customer_information"
      ]
    }
  },
  "required": [
    "message",
    "invoice"
  ]
}
```

Example:

```json
{
  "message": "A new payment session has been generated.",
  "payment_url": "https://commerce.coinbase.com/charges/CQEGF35V",
  "invoice": {
    "id": 1,
    "payment": {
      "fee": {
        "base": "0",
        "currency": "USD",
        "units": 1,
        "vat": 0,
        "total": {
          "exclusive": "0",
          "inclusive": "0"
        }
      },
      "gateway": {
        "data": {
          "total": {
            "base": "1999",
            "currency": "USD",
            "units": 1,
            "vat": 0,
            "total": {
              "exclusive": "1999",
              "inclusive": "1999"
            }
          },
          "customer_email": "customer@example.com",
          "transaction_id": "CQEGF35V",
          "checkout_url": "https://commerce.coinbase.com/charges/CQEGF35V"
        },
        "type": "COINBASE"
      },
      "subtotal": {
        "base": "1999",
        "currency": "USD",
        "units": 1,
        "vat": 0,
        "total": {
          "exclusive": "1999",
          "inclusive": "1999"
        }
      },
      "expires_at": "2024-01-09T23:50:11.000000Z",
      "full_price": {
        "base": "1999",
        "currency": "USD",
        "units": 1,
        "vat": 0,
        "total": {
          "exclusive": "1999",
          "inclusive": "1999"
        }
      },
      "original_amount": {
        "base": "1999",
        "currency": "USD",
        "units": 1,
        "vat": 0,
        "total": {
          "exclusive": "1999",
          "inclusive": "1999"
        }
      }
    },
    "status": {
      "history": [],
      "status": {
        "setAt": "2024-01-09T14:50:11.000000Z",
        "status": "PENDING",
        "updatedAt": "2024-01-09T18:00:50.000000Z"
      }
    },
    "webhooks": [],
    "feedback": "",
    "created_at": "2024-01-09T14:50:11.000000Z",
    "updated_at": "2024-01-09T18:00:50.000000Z",
    "store_id": 1,
    "coupon_id": null,
    "subscription_id": null,
    "customer_information": {
      "id": 123,
      "email": "customer@example.com",
      "country": "Germany",
      "location": "Munich",
      "ip": "1.3.3.7",
      "proxied": false,
      "browser_agent": "Mozilla/4.9 (Windows 98; sl-SI; rv:1.9.1.20) Gecko/20110422 Firefox/21.0",
      "vat": {
        "amount": 0,
        "country": "DE"
      }
    }
  }
}
```

# Create an invoice (/docs/api/invoices/create-an-invoice)

This endpoint allows you to create a new invoice. See the code examples for how to create a new invoice with the SellApp API.

<Note>
  The response now includes a top-level `checkout` field when a checkout URL is already available for the newly created invoice.
</Note>

## Endpoint

- Method: `POST`

- Path: `/v2/invoices`

- Full URL: `https://sell.app/api/v2/invoices`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "customer_email": {
      "type": "string",
      "format": "email"
    },
    "customer_ip": {
      "type": [
        "string",
        "null"
      ]
    },
    "payment_method": {
      "type": "string",
      "enum": [
        "AUTHNET",
        "BTCPAY",
        "CASHAPP",
        "COINBASE",
        "PADDLE",
        "PAYDASH",
        "PAYPAL",
        "PAYSTACK",
        "SQUARE",
        "STRIPE",
        "VENMO",
        "NMI",
        "LIFI",
        "BTC",
        "LTC",
        "ETH",
        "XMR",
        "SOL",
        "ADA",
        "BNB",
        "TRX",
        "MATIC",
        "ETH_USDT",
        "ETH_USDC",
        "ETH_UNI",
        "ETH_SHIB",
        "ETH_DAI",
        "BNB_USDT",
        "BNB_USDC",
        "TRX_USDT",
        "TRX_USDC",
        "SOL_USDT",
        "SOL_USDC"
      ]
    },
    "coupon": {
      "type": "string"
    },
    "vat_id": {
      "type": "string"
    },
    "country": {
      "type": "string"
    },
    "affiliate": {
      "type": [
        "string",
        "null"
      ]
    },
    "extra": {
      "type": "object",
      "properties": {
        "amount": {
          "type": "integer"
        },
        "currency": {
          "type": "string"
        }
      },
      "required": [
        "amount",
        "currency"
      ]
    },
    "product_variants": {
      "type": "object",
      "additionalProperties": {
        "type": "object",
        "properties": {
          "quantity": {
            "type": "integer"
          },
          "additional_information": {
            "type": "object",
            "additionalProperties": true
          },
          "fill_once": {
            "type": "boolean"
          }
        },
        "required": [
          "quantity"
        ]
      }
    }
  },
  "required": [
    "customer_email",
    "payment_method",
    "product_variants"
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "payment": {
          "type": "object",
          "properties": {
            "fee": {
              "type": "object",
              "properties": {
                "base": {
                  "type": "string"
                },
                "currency": {
                  "type": "string"
                },
                "units": {
                  "type": "integer"
                },
                "vat": {
                  "type": "integer"
                },
                "total": {
                  "type": "object",
                  "properties": {
                    "exclusive": {
                      "type": "string"
                    },
                    "inclusive": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "exclusive",
                    "inclusive"
                  ]
                }
              },
              "required": [
                "base",
                "currency",
                "units",
                "vat",
                "total"
              ]
            },
            "gateway": {
              "type": "object",
              "properties": {
                "data": {
                  "type": "object",
                  "properties": {
                    "total": {
                      "type": "object",
                      "properties": {
                        "base": {
                          "type": "string"
                        },
                        "currency": {
                          "type": "string"
                        },
                        "units": {
                          "type": "integer"
                        },
                        "vat": {
                          "type": "integer"
                        },
                        "total": {
                          "type": "object",
                          "properties": {
                            "exclusive": {
                              "type": "string"
                            },
                            "inclusive": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "exclusive",
                            "inclusive"
                          ]
                        }
                      },
                      "required": [
                        "base",
                        "currency",
                        "units",
                        "vat",
                        "total"
                      ]
                    },
                    "customer_email": {
                      "type": "string"
                    },
                    "transaction_id": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "total",
                    "customer_email",
                    "transaction_id"
                  ]
                },
                "type": {
                  "type": "string"
                }
              },
              "required": [
                "data",
                "type"
              ]
            },
            "subtotal": {
              "type": "object",
              "properties": {
                "base": {
                  "type": "string"
                },
                "currency": {
                  "type": "string"
                },
                "units": {
                  "type": "integer"
                },
                "vat": {
                  "type": "integer"
                },
                "total": {
                  "type": "object",
                  "properties": {
                    "exclusive": {
                      "type": "string"
                    },
                    "inclusive": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "exclusive",
                    "inclusive"
                  ]
                }
              },
              "required": [
                "base",
                "currency",
                "units",
                "vat",
                "total"
              ]
            },
            "expires_at": {
              "type": "string",
              "format": "date-time"
            },
            "full_price": {
              "type": "object",
              "properties": {
                "base": {
                  "type": "string"
                },
                "currency": {
                  "type": "string"
                },
                "units": {
                  "type": "integer"
                },
                "vat": {
                  "type": "integer"
                },
                "total": {
                  "type": "object",
                  "properties": {
                    "exclusive": {
                      "type": "string"
                    },
                    "inclusive": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "exclusive",
                    "inclusive"
                  ]
                }
              },
              "required": [
                "base",
                "currency",
                "units",
                "vat",
                "total"
              ]
            },
            "original_amount": {
              "type": "object",
              "properties": {
                "base": {
                  "type": "string"
                },
                "currency": {
                  "type": "string"
                },
                "units": {
                  "type": "integer"
                },
                "vat": {
                  "type": "integer"
                },
                "total": {
                  "type": "object",
                  "properties": {
                    "exclusive": {
                      "type": "string"
                    },
                    "inclusive": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "exclusive",
                    "inclusive"
                  ]
                }
              },
              "required": [
                "base",
                "currency",
                "units",
                "vat",
                "total"
              ]
            }
          },
          "required": [
            "fee",
            "gateway",
            "subtotal",
            "expires_at",
            "full_price",
            "original_amount"
          ]
        },
        "status": {
          "type": "object",
          "properties": {
            "history": {
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "setAt": {
                    "type": "string",
                    "format": "date-time"
                  },
                  "status": {
                    "type": "string"
                  },
                  "updatedAt": {
                    "type": "string",
                    "format": "date-time"
                  }
                },
                "required": [
                  "setAt",
                  "status",
                  "updatedAt"
                ]
              }
            },
            "status": {
              "type": "object",
              "properties": {
                "setAt": {
                  "type": "string",
                  "format": "date-time"
                },
                "status": {
                  "type": "string"
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time"
                }
              },
              "required": [
                "setAt",
                "status",
                "updatedAt"
              ]
            }
          },
          "required": [
            "history",
            "status"
          ]
        },
        "webhooks": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "feedback": {
          "type": "string"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "store_id": {
          "type": "integer"
        },
        "coupon_id": {
          "type": "null"
        },
        "subscription_id": {
          "type": "null"
        },
        "checkout": {
          "type": "string"
        },
        "customer_information": {
          "type": "object",
          "properties": {
            "id": {
              "type": "integer"
            },
            "email": {
              "type": "string"
            },
            "country": {
              "type": "string"
            },
            "location": {
              "type": "string"
            },
            "ip": {
              "type": "string"
            },
            "proxied": {
              "type": "boolean"
            },
            "browser_agent": {
              "type": "string"
            },
            "vat": {
              "type": "object",
              "properties": {
                "amount": {
                  "type": "integer"
                },
                "country": {
                  "type": "string"
                }
              },
              "required": [
                "amount",
                "country"
              ]
            }
          },
          "required": [
            "id",
            "email",
            "country",
            "location",
            "ip",
            "proxied",
            "browser_agent",
            "vat"
          ]
        }
      },
      "required": [
        "id",
        "payment",
        "status",
        "webhooks",
        "feedback",
        "created_at",
        "updated_at",
        "store_id",
        "coupon_id",
        "subscription_id",
        "checkout",
        "customer_information"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "payment": {
      "fee": {
        "base": "0",
        "currency": "USD",
        "units": 1,
        "vat": 0,
        "total": {
          "exclusive": "0",
          "inclusive": "0"
        }
      },
      "gateway": {
        "data": {
          "total": {
            "base": "1999",
            "currency": "USD",
            "units": 1,
            "vat": 0,
            "total": {
              "exclusive": "1999",
              "inclusive": "1999"
            }
          },
          "customer_email": "customer@example.com",
          "transaction_id": "CQEGF35V"
        },
        "type": "COINBASE"
      },
      "subtotal": {
        "base": "1999",
        "currency": "USD",
        "units": 1,
        "vat": 0,
        "total": {
          "exclusive": "1999",
          "inclusive": "1999"
        }
      },
      "expires_at": "2024-01-09T23:50:11.000000Z",
      "full_price": {
        "base": "1999",
        "currency": "USD",
        "units": 1,
        "vat": 0,
        "total": {
          "exclusive": "1999",
          "inclusive": "1999"
        }
      },
      "original_amount": {
        "base": "1999",
        "currency": "USD",
        "units": 1,
        "vat": 0,
        "total": {
          "exclusive": "1999",
          "inclusive": "1999"
        }
      }
    },
    "status": {
      "history": [
        {
          "setAt": "2024-01-09T14:50:11.000000Z",
          "status": "PENDING",
          "updatedAt": "2024-01-09T18:00:50.000000Z"
        }
      ],
      "status": {
        "setAt": "2024-01-09T18:00:50.000000Z",
        "status": "COMPLETED",
        "updatedAt": "2024-01-09T18:00:50.000000Z"
      }
    },
    "webhooks": [],
    "feedback": "",
    "created_at": "2024-01-09T14:50:11.000000Z",
    "updated_at": "2024-01-09T18:00:50.000000Z",
    "store_id": 1,
    "coupon_id": null,
    "subscription_id": null,
    "checkout": "https://checkout.example.com/cashapp",
    "customer_information": {
      "id": 123,
      "email": "customer@example.com",
      "country": "Germany",
      "location": "Munich",
      "ip": "1.3.3.7",
      "proxied": false,
      "browser_agent": "Mozilla/4.9 (Windows 98; sl-SI; rv:1.9.1.20) Gecko/20110422 Firefox/21.0",
      "vat": {
        "amount": 0,
        "country": "DE"
      }
    }
  }
}
```

# Overview (/docs/api/invoices)



Invoices are orders placed by customers. They contain all the info you might need for each order, from the total purchase amount, customer information, and the product(s) delivered.

On this page, we'll dive into the different invoice endpoints you can use to manage invoices programmatically. We'll look at how to view, create, and update invoices.

## Endpoints [#endpoints]

* [List all invoices](/api/invoices/list-all-invoices)
* [Search invoices](/api/invoices/search-invoices)
* [Create an invoice](/api/invoices/create-an-invoice)
* [Retrieve an invoice](/api/invoices/retrieve-an-invoice)
* [Create a checkout session](/api/invoices/create-a-checkout-session)
* [View invoice deliverables](/api/invoices/view-invoice-deliverables)
* [Mark pending invoice completed](/api/invoices/mark-pending-invoice-completed)
* [Mark pending invoice voided](/api/invoices/mark-pending-invoice-voided)
* [Issue replacement for completed invoice](/api/invoices/issue-replacement-for-completed-invoice)

## The invoice model [#the-invoice-model]

The invoice model contains all the information about the invoices stores have, including the type, code, and discount amount.

### Properties [#properties]

<Properties>
  <Property name="id" type="integer">
    The unique identifier for the invoice.
  </Property>

  <Property name="payment" type="array">
    The array of general payment details. Consists of the following parts:

    * `fee` Displays the platform fee associated with this invoice.
    * `gateway` Contains payment gateway type, transaction ID, checkout URL, and payment-method-specific metadata such as crypto addresses and requested / received crypto amounts.
    * `subtotal` Payment subtotal calculation, contains currency, VAT, and total.
    * `expires_at` At which time the invoice expires and no longer becomes payable.
    * `full_price` Shows the full price of the invoice and includes modifiers such as extra amounts (Pay What You Want).
    * `original_amount` Displays the original amount of the invoice and excludes modifiers such as extra amounts (Pay What You Want).
  </Property>

  <Property name="status" type="array">
    The historical array of the invoice's status. Consists of two parts:

    * `history` Array of historical order statuses.
    * `status` Current order status details.
  </Property>

  <Property name="webhooks" type="array">
    The webhook details, if set.
  </Property>

  <Property name="feedback" type="string">
    The customer order feedback, if made.
  </Property>

  <Property name="created_at" type="timestamp">
    The time at which this invoice was first created.
  </Property>

  <Property name="updated_at" type="timestamp">
    The time at which this invoice was last updated.
  </Property>

  <Property name="store_id" type="integer">
    The ID of the store this invoice belongs to.
  </Property>

  <Property name="coupon_id" type="integer">
    The ID of the coupon applied to this order, if set.
  </Property>

  <Property name="subscription_id" type="integer">
    The ID of the subscription belonging to the invoice, if set.
  </Property>

  <Property name="customer_information" type="array">
    The associated customer's information, consists of:

    * `id&#x60; SellApp user ID &#x2A;(if logged in)*.
    * `email` Customer email.
    * `country` Customer country.
    * `location&#x60; Customer location &#x2A;(city level)*.
    * `ip` Customer IP.
    * `proxied` Boolean; whether the customer is using IP obfuscation software or not.
    * `browser_agent` Browser agent used to make the purchase.
    * `vat` Array of VAT details, consists of `amount` in cents and `country` as country code.
  </Property>

  <Property name="product_variants" type="array">
    The product variants included in the invoice, each containing:

    * `id` Product variant ID.
    * `product_id` Parent product ID.
    * `title` Product variant title captured for the invoice.
  </Property>
</Properties>


# Issue replacement for completed invoice (/docs/api/invoices/issue-replacement-for-completed-invoice)

In the event you want to replace the deliverables of an invoice, this endpoint lets you do so.

When you send a request to the endpoint, behind the scenes a new invoice gets created and immediately marked as completed. From there, the regular flow proceeds with a customer receiving a delivery email with a link to access their products, and you receiving a sales notification.

See the code examples for how to issue a replacement product for an existing invoice with the SellApp API.

## Endpoint

- Method: `PATCH`

- Path: `/v2/invoices/{invoice}/issue-replacement`

- Full URL: `https://sell.app/api/v2/invoices/{invoice}/issue-replacement`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `invoice` (`integer`, required): The invoice path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "product_variants": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "array",
          "items": {
            "type": "integer"
          }
        }
      ]
    }
  },
  "required": [
    "product_variants"
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "id": {
      "type": "integer"
    },
    "payment": {
      "type": "object",
      "properties": {
        "fee": {
          "type": "object",
          "properties": {
            "base": {
              "type": "string"
            },
            "currency": {
              "type": "string"
            },
            "units": {
              "type": "integer"
            },
            "vat": {
              "type": "integer"
            },
            "total": {
              "type": "object",
              "properties": {
                "exclusive": {
                  "type": "string"
                },
                "inclusive": {
                  "type": "string"
                }
              },
              "required": [
                "exclusive",
                "inclusive"
              ]
            }
          },
          "required": [
            "base",
            "currency",
            "units",
            "vat",
            "total"
          ]
        },
        "gateway": {
          "type": "object",
          "properties": {
            "data": {
              "type": "object",
              "properties": {
                "total": {
                  "type": "object",
                  "properties": {
                    "base": {
                      "type": "string"
                    },
                    "currency": {
                      "type": "string"
                    },
                    "units": {
                      "type": "integer"
                    },
                    "vat": {
                      "type": "integer"
                    },
                    "total": {
                      "type": "object",
                      "properties": {
                        "exclusive": {
                          "type": "string"
                        },
                        "inclusive": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "exclusive",
                        "inclusive"
                      ]
                    }
                  },
                  "required": [
                    "base",
                    "currency",
                    "units",
                    "vat",
                    "total"
                  ]
                },
                "customer_email": {
                  "type": "string"
                },
                "transaction_id": {
                  "type": "string"
                }
              },
              "required": [
                "total",
                "customer_email",
                "transaction_id"
              ]
            },
            "type": {
              "type": "string"
            }
          },
          "required": [
            "data",
            "type"
          ]
        },
        "subtotal": {
          "type": "object",
          "properties": {
            "base": {
              "type": "string"
            },
            "currency": {
              "type": "string"
            },
            "units": {
              "type": "integer"
            },
            "vat": {
              "type": "integer"
            },
            "total": {
              "type": "object",
              "properties": {
                "exclusive": {
                  "type": "string"
                },
                "inclusive": {
                  "type": "string"
                }
              },
              "required": [
                "exclusive",
                "inclusive"
              ]
            }
          },
          "required": [
            "base",
            "currency",
            "units",
            "vat",
            "total"
          ]
        },
        "expires_at": {
          "type": "string",
          "format": "date-time"
        },
        "full_price": {
          "type": "object",
          "properties": {
            "base": {
              "type": "string"
            },
            "currency": {
              "type": "string"
            },
            "units": {
              "type": "integer"
            },
            "vat": {
              "type": "integer"
            },
            "total": {
              "type": "object",
              "properties": {
                "exclusive": {
                  "type": "string"
                },
                "inclusive": {
                  "type": "string"
                }
              },
              "required": [
                "exclusive",
                "inclusive"
              ]
            }
          },
          "required": [
            "base",
            "currency",
            "units",
            "vat",
            "total"
          ]
        },
        "original_amount": {
          "type": "object",
          "properties": {
            "base": {
              "type": "string"
            },
            "currency": {
              "type": "string"
            },
            "units": {
              "type": "integer"
            },
            "vat": {
              "type": "integer"
            },
            "total": {
              "type": "object",
              "properties": {
                "exclusive": {
                  "type": "string"
                },
                "inclusive": {
                  "type": "string"
                }
              },
              "required": [
                "exclusive",
                "inclusive"
              ]
            }
          },
          "required": [
            "base",
            "currency",
            "units",
            "vat",
            "total"
          ]
        }
      },
      "required": [
        "fee",
        "gateway",
        "subtotal",
        "expires_at",
        "full_price",
        "original_amount"
      ]
    },
    "status": {
      "type": "object",
      "properties": {
        "history": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "setAt": {
                "type": "string",
                "format": "date-time"
              },
              "status": {
                "type": "string"
              },
              "updatedAt": {
                "type": "string",
                "format": "date-time"
              }
            },
            "required": [
              "setAt",
              "status",
              "updatedAt"
            ]
          }
        },
        "status": {
          "type": "object",
          "properties": {
            "setAt": {
              "type": "string",
              "format": "date-time"
            },
            "status": {
              "type": "string"
            },
            "updatedAt": {
              "type": "string",
              "format": "date-time"
            }
          },
          "required": [
            "setAt",
            "status",
            "updatedAt"
          ]
        }
      },
      "required": [
        "history",
        "status"
      ]
    },
    "webhooks": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "feedback": {
      "type": "string"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    },
    "store_id": {
      "type": "integer"
    },
    "coupon_id": {
      "type": "null"
    },
    "subscription_id": {
      "type": "null"
    },
    "customer_information": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "email": {
          "type": "string"
        },
        "country": {
          "type": "string"
        },
        "location": {
          "type": "string"
        },
        "ip": {
          "type": "string"
        },
        "proxied": {
          "type": "boolean"
        },
        "browser_agent": {
          "type": "string"
        },
        "vat": {
          "type": "object",
          "properties": {
            "amount": {
              "type": "integer"
            },
            "country": {
              "type": "string"
            }
          },
          "required": [
            "amount",
            "country"
          ]
        }
      },
      "required": [
        "id",
        "email",
        "country",
        "location",
        "ip",
        "proxied",
        "browser_agent",
        "vat"
      ]
    },
    "product_variants": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "product_id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "product_id",
          "title"
        ]
      }
    }
  },
  "required": [
    "id",
    "payment",
    "status",
    "webhooks",
    "feedback",
    "created_at",
    "updated_at",
    "store_id",
    "coupon_id",
    "subscription_id",
    "customer_information",
    "product_variants"
  ]
}
```

Example:

```json
{
  "id": 2,
  "payment": {
    "fee": {
      "base": "0",
      "currency": "USD",
      "units": 1,
      "vat": 0,
      "total": {
        "exclusive": "0",
        "inclusive": "0"
      }
    },
    "gateway": {
      "data": {
        "total": {
          "base": "1999",
          "currency": "USD",
          "units": 1,
          "vat": 0,
          "total": {
            "exclusive": "1999",
            "inclusive": "1999"
          }
        },
        "customer_email": "customer@example.com",
        "transaction_id": "CQEGF35V"
      },
      "type": "COINBASE"
    },
    "subtotal": {
      "base": "1999",
      "currency": "USD",
      "units": 1,
      "vat": 0,
      "total": {
        "exclusive": "1999",
        "inclusive": "1999"
      }
    },
    "expires_at": "2024-01-10T19:33:12.000000Z",
    "full_price": {
      "base": "1999",
      "currency": "USD",
      "units": 1,
      "vat": 0,
      "total": {
        "exclusive": "1999",
        "inclusive": "1999"
      }
    },
    "original_amount": {
      "base": "1999",
      "currency": "USD",
      "units": 1,
      "vat": 0,
      "total": {
        "exclusive": "1999",
        "inclusive": "1999"
      }
    }
  },
  "status": {
    "history": [
      {
        "setAt": "2024-01-09T19:33:12.000000Z",
        "status": "PENDING",
        "updatedAt": "2024-01-09T21:17:47.000000Z"
      }
    ],
    "status": {
      "setAt": "2024-01-09T21:17:47.000000Z",
      "status": "COMPLETED",
      "updatedAt": "2024-01-09T21:17:47.000000Z"
    }
  },
  "webhooks": [],
  "feedback": "",
  "created_at": "2024-01-09T19:33:12.000000Z",
  "updated_at": "2024-01-09T21:17:47.000000Z",
  "store_id": 1,
  "coupon_id": null,
  "subscription_id": null,
  "customer_information": {
    "id": 1034,
    "email": "customer@example.com",
    "country": "Germany",
    "location": "Munich",
    "ip": "1.3.3.7",
    "proxied": false,
    "browser_agent": "Mozilla/4.9 (Windows 98; sl-SI; rv:1.9.1.20) Gecko/20110422 Firefox/21.0",
    "vat": {
      "amount": 0,
      "country": "US"
    }
  },
  "product_variants": [
    {
      "id": 117214,
      "product_id": 97850,
      "title": "SellApp Platform Balance"
    }
  ]
}
```

# List all invoices (/docs/api/invoices/list-all-invoices)

This endpoint allows you to retrieve a paginated list of all your invoices. By default, a maximum of fifteen invoices are shown per page.

## Endpoint

- Method: `GET`

- Path: `/v2/invoices`

- Full URL: `https://sell.app/api/v2/invoices`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
- `limit` (`integer`, optional): Limit the number of blacklist rules returned.
- `page` (`integer`, optional): The page number you are attempting to access.
- `search` (`string`, optional): Free-text search term.
- `search_by` (`string`, optional): Which invoice field the search term should be matched against.
- `id` (`string`, optional): Filter by invoice ID.
- `email` (`string`, optional): Filter by customer email.
- `transaction_id` (`string`, optional): Filter by payment transaction ID.
- `serial_code` (`string`, optional): Filter by delivered serial.
- `additional_info` (`string`, optional): Filter by customer-provided additional information.
- `product_name` (`string`, optional): Filter by product or variant title.
- `discord_data` (`string`, optional): Filter by attached Discord data.
- `crypto_txid` (`string`, optional): Filter by crypto TXID.
- `crypto_address` (`string`, optional): Filter by crypto payment address.
- `coupon_code` (`string`, optional): Filter by coupon code.
- `status` (`array`, optional): Filter by one or more invoice statuses.
- `payment_methods` (`array`, optional): Filter by one or more payment methods.
- `sort` (`string`, optional): Sort order for the result set.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "payment": {
            "type": "object",
            "properties": {
              "fee": {
                "type": "object",
                "properties": {
                  "base": {
                    "type": "string"
                  },
                  "currency": {
                    "type": "string"
                  },
                  "units": {
                    "type": "integer"
                  },
                  "vat": {
                    "type": "integer"
                  },
                  "total": {
                    "type": "object",
                    "properties": {
                      "exclusive": {
                        "type": "string"
                      },
                      "inclusive": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "exclusive",
                      "inclusive"
                    ]
                  }
                },
                "required": [
                  "base",
                  "currency",
                  "units",
                  "vat",
                  "total"
                ]
              },
              "gateway": {
                "type": "object",
                "properties": {
                  "data": {
                    "type": "object",
                    "properties": {
                      "total": {
                        "type": "object",
                        "properties": {
                          "base": {
                            "type": "string"
                          },
                          "currency": {
                            "type": "string"
                          },
                          "units": {
                            "type": "integer"
                          },
                          "vat": {
                            "type": "integer"
                          },
                          "total": {
                            "type": "object",
                            "properties": {
                              "exclusive": {
                                "type": "string"
                              },
                              "inclusive": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "exclusive",
                              "inclusive"
                            ]
                          }
                        },
                        "required": [
                          "base",
                          "currency",
                          "units",
                          "vat",
                          "total"
                        ]
                      },
                      "customer_email": {
                        "type": "string"
                      },
                      "transaction_id": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "total",
                      "customer_email",
                      "transaction_id"
                    ]
                  },
                  "type": {
                    "type": "string"
                  }
                },
                "required": [
                  "data",
                  "type"
                ]
              },
              "subtotal": {
                "type": "object",
                "properties": {
                  "base": {
                    "type": "string"
                  },
                  "currency": {
                    "type": "string"
                  },
                  "units": {
                    "type": "integer"
                  },
                  "vat": {
                    "type": "integer"
                  },
                  "total": {
                    "type": "object",
                    "properties": {
                      "exclusive": {
                        "type": "string"
                      },
                      "inclusive": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "exclusive",
                      "inclusive"
                    ]
                  }
                },
                "required": [
                  "base",
                  "currency",
                  "units",
                  "vat",
                  "total"
                ]
              },
              "expires_at": {
                "type": "string",
                "format": "date-time"
              },
              "full_price": {
                "type": "object",
                "properties": {
                  "base": {
                    "type": "string"
                  },
                  "currency": {
                    "type": "string"
                  },
                  "units": {
                    "type": "integer"
                  },
                  "vat": {
                    "type": "integer"
                  },
                  "total": {
                    "type": "object",
                    "properties": {
                      "exclusive": {
                        "type": "string"
                      },
                      "inclusive": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "exclusive",
                      "inclusive"
                    ]
                  }
                },
                "required": [
                  "base",
                  "currency",
                  "units",
                  "vat",
                  "total"
                ]
              },
              "original_amount": {
                "type": "object",
                "properties": {
                  "base": {
                    "type": "string"
                  },
                  "currency": {
                    "type": "string"
                  },
                  "units": {
                    "type": "integer"
                  },
                  "vat": {
                    "type": "integer"
                  },
                  "total": {
                    "type": "object",
                    "properties": {
                      "exclusive": {
                        "type": "string"
                      },
                      "inclusive": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "exclusive",
                      "inclusive"
                    ]
                  }
                },
                "required": [
                  "base",
                  "currency",
                  "units",
                  "vat",
                  "total"
                ]
              }
            },
            "required": [
              "fee",
              "gateway",
              "subtotal",
              "expires_at",
              "full_price",
              "original_amount"
            ]
          },
          "status": {
            "type": "object",
            "properties": {
              "history": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "setAt": {
                      "type": "string",
                      "format": "date-time"
                    },
                    "status": {
                      "type": "string"
                    },
                    "updatedAt": {
                      "type": "string",
                      "format": "date-time"
                    }
                  },
                  "required": [
                    "setAt",
                    "status",
                    "updatedAt"
                  ]
                }
              },
              "status": {
                "type": "object",
                "properties": {
                  "setAt": {
                    "type": "string",
                    "format": "date-time"
                  },
                  "status": {
                    "type": "string"
                  },
                  "updatedAt": {
                    "type": "string",
                    "format": "date-time"
                  }
                },
                "required": [
                  "setAt",
                  "status",
                  "updatedAt"
                ]
              }
            },
            "required": [
              "history",
              "status"
            ]
          },
          "webhooks": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "feedback": {
            "type": "string"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "store_id": {
            "type": "integer"
          },
          "coupon_id": {
            "type": "null"
          },
          "subscription_id": {
            "type": "null"
          },
          "customer_information": {
            "type": "object",
            "properties": {
              "id": {
                "type": "integer"
              },
              "email": {
                "type": "string"
              },
              "country": {
                "type": "string"
              },
              "location": {
                "type": "string"
              },
              "ip": {
                "type": "string"
              },
              "proxied": {
                "type": "boolean"
              },
              "browser_agent": {
                "type": "string"
              },
              "vat": {
                "type": "object",
                "properties": {
                  "amount": {
                    "type": "integer"
                  },
                  "country": {
                    "type": "string"
                  }
                },
                "required": [
                  "amount",
                  "country"
                ]
              }
            },
            "required": [
              "id",
              "email",
              "country",
              "location",
              "ip",
              "proxied",
              "browser_agent",
              "vat"
            ]
          },
          "product_variants": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "integer"
                },
                "product_id": {
                  "type": "integer"
                },
                "title": {
                  "type": "string"
                }
              },
              "required": [
                "id",
                "product_id",
                "title"
              ]
            }
          }
        },
        "required": [
          "id",
          "payment",
          "status",
          "webhooks",
          "feedback",
          "created_at",
          "updated_at",
          "store_id",
          "coupon_id",
          "subscription_id",
          "customer_information",
          "product_variants"
        ]
      }
    },
    "links": {
      "type": "object",
      "properties": {}
    },
    "meta": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "data",
    "links",
    "meta"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "payment": {
        "fee": {
          "base": "0",
          "currency": "USD",
          "units": 1,
          "vat": 0,
          "total": {
            "exclusive": "0",
            "inclusive": "0"
          }
        },
        "gateway": {
          "data": {
            "total": {
              "base": "1999",
              "currency": "USD",
              "units": 1,
              "vat": 0,
              "total": {
                "exclusive": "1999",
                "inclusive": "1999"
              }
            },
            "customer_email": "customer@example.com",
            "transaction_id": "CQEGF35V"
          },
          "type": "COINBASE"
        },
        "subtotal": {
          "base": "1999",
          "currency": "USD",
          "units": 1,
          "vat": 0,
          "total": {
            "exclusive": "1999",
            "inclusive": "1999"
          }
        },
        "expires_at": "2024-01-09T23:50:11.000000Z",
        "full_price": {
          "base": "1999",
          "currency": "USD",
          "units": 1,
          "vat": 0,
          "total": {
            "exclusive": "1999",
            "inclusive": "1999"
          }
        },
        "original_amount": {
          "base": "1999",
          "currency": "USD",
          "units": 1,
          "vat": 0,
          "total": {
            "exclusive": "1999",
            "inclusive": "1999"
          }
        }
      },
      "status": {
        "history": [
          {
            "setAt": "2024-01-09T14:50:11.000000Z",
            "status": "PENDING",
            "updatedAt": "2024-01-09T18:00:50.000000Z"
          }
        ],
        "status": {
          "setAt": "2024-01-09T18:00:50.000000Z",
          "status": "COMPLETED",
          "updatedAt": "2024-01-09T18:00:50.000000Z"
        }
      },
      "webhooks": [],
      "feedback": "",
      "created_at": "2024-01-09T14:50:11.000000Z",
      "updated_at": "2024-01-09T18:00:50.000000Z",
      "store_id": 1,
      "coupon_id": null,
      "subscription_id": null,
      "customer_information": {
        "id": 123,
        "email": "customer@example.com",
        "country": "Germany",
        "location": "Munich",
        "ip": "1.3.3.7",
        "proxied": false,
        "browser_agent": "Mozilla/4.9 (Windows 98; sl-SI; rv:1.9.1.20) Gecko/20110422 Firefox/21.0",
        "vat": {
          "amount": 0,
          "country": "DE"
        }
      },
      "product_variants": [
        {
          "id": 117214,
          "product_id": 97850,
          "title": "SellApp Platform Balance"
        }
      ]
    }
  ],
  "links": {},
  "meta": {}
}
```

# Mark pending invoice completed (/docs/api/invoices/mark-pending-invoice-completed)

This endpoint allows you to update a pending invoice's status as completed. If marked as completed, the purchased product(s) would be delivered to the customer's email. See the code examples for how to mark a pending invoice as completed with the SellApp API.

<Warn>
  The SellApp platform automatically marks invoices as completed once payment has been confirmed.

  We advise not using this endpoint unless you are certain you have received the payment and/or there is another reason to mark the invoice as completed manually.
</Warn>

## Endpoint

- Method: `PATCH`

- Path: `/v2/invoices/{invoice}/mark-completed`

- Full URL: `https://sell.app/api/v2/invoices/{invoice}/mark-completed`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `invoice` (`integer`, required): The invoice path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "id": {
      "type": "integer"
    },
    "payment": {
      "type": "object",
      "properties": {
        "fee": {
          "type": "object",
          "properties": {
            "base": {
              "type": "string"
            },
            "currency": {
              "type": "string"
            },
            "units": {
              "type": "integer"
            },
            "vat": {
              "type": "integer"
            },
            "total": {
              "type": "object",
              "properties": {
                "exclusive": {
                  "type": "string"
                },
                "inclusive": {
                  "type": "string"
                }
              },
              "required": [
                "exclusive",
                "inclusive"
              ]
            }
          },
          "required": [
            "base",
            "currency",
            "units",
            "vat",
            "total"
          ]
        },
        "gateway": {
          "type": "object",
          "properties": {
            "data": {
              "type": "object",
              "properties": {
                "total": {
                  "type": "object",
                  "properties": {
                    "base": {
                      "type": "string"
                    },
                    "currency": {
                      "type": "string"
                    },
                    "units": {
                      "type": "integer"
                    },
                    "vat": {
                      "type": "integer"
                    },
                    "total": {
                      "type": "object",
                      "properties": {
                        "exclusive": {
                          "type": "string"
                        },
                        "inclusive": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "exclusive",
                        "inclusive"
                      ]
                    }
                  },
                  "required": [
                    "base",
                    "currency",
                    "units",
                    "vat",
                    "total"
                  ]
                },
                "customer_email": {
                  "type": "string"
                },
                "transaction_id": {
                  "type": "string"
                }
              },
              "required": [
                "total",
                "customer_email",
                "transaction_id"
              ]
            },
            "type": {
              "type": "string"
            }
          },
          "required": [
            "data",
            "type"
          ]
        },
        "subtotal": {
          "type": "object",
          "properties": {
            "base": {
              "type": "string"
            },
            "currency": {
              "type": "string"
            },
            "units": {
              "type": "integer"
            },
            "vat": {
              "type": "integer"
            },
            "total": {
              "type": "object",
              "properties": {
                "exclusive": {
                  "type": "string"
                },
                "inclusive": {
                  "type": "string"
                }
              },
              "required": [
                "exclusive",
                "inclusive"
              ]
            }
          },
          "required": [
            "base",
            "currency",
            "units",
            "vat",
            "total"
          ]
        },
        "expires_at": {
          "type": "string",
          "format": "date-time"
        },
        "full_price": {
          "type": "object",
          "properties": {
            "base": {
              "type": "string"
            },
            "currency": {
              "type": "string"
            },
            "units": {
              "type": "integer"
            },
            "vat": {
              "type": "integer"
            },
            "total": {
              "type": "object",
              "properties": {
                "exclusive": {
                  "type": "string"
                },
                "inclusive": {
                  "type": "string"
                }
              },
              "required": [
                "exclusive",
                "inclusive"
              ]
            }
          },
          "required": [
            "base",
            "currency",
            "units",
            "vat",
            "total"
          ]
        },
        "original_amount": {
          "type": "object",
          "properties": {
            "base": {
              "type": "string"
            },
            "currency": {
              "type": "string"
            },
            "units": {
              "type": "integer"
            },
            "vat": {
              "type": "integer"
            },
            "total": {
              "type": "object",
              "properties": {
                "exclusive": {
                  "type": "string"
                },
                "inclusive": {
                  "type": "string"
                }
              },
              "required": [
                "exclusive",
                "inclusive"
              ]
            }
          },
          "required": [
            "base",
            "currency",
            "units",
            "vat",
            "total"
          ]
        }
      },
      "required": [
        "fee",
        "gateway",
        "subtotal",
        "expires_at",
        "full_price",
        "original_amount"
      ]
    },
    "status": {
      "type": "object",
      "properties": {
        "history": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "setAt": {
                "type": "string",
                "format": "date-time"
              },
              "status": {
                "type": "string"
              },
              "updatedAt": {
                "type": "string",
                "format": "date-time"
              }
            },
            "required": [
              "setAt",
              "status",
              "updatedAt"
            ]
          }
        },
        "status": {
          "type": "object",
          "properties": {
            "setAt": {
              "type": "string",
              "format": "date-time"
            },
            "status": {
              "type": "string"
            },
            "updatedAt": {
              "type": "string",
              "format": "date-time"
            }
          },
          "required": [
            "setAt",
            "status",
            "updatedAt"
          ]
        }
      },
      "required": [
        "history",
        "status"
      ]
    },
    "webhooks": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "feedback": {
      "type": "string"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    },
    "store_id": {
      "type": "integer"
    },
    "coupon_id": {
      "type": "null"
    },
    "subscription_id": {
      "type": "null"
    },
    "customer_information": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "email": {
          "type": "string"
        },
        "country": {
          "type": "string"
        },
        "location": {
          "type": "string"
        },
        "ip": {
          "type": "string"
        },
        "proxied": {
          "type": "boolean"
        },
        "browser_agent": {
          "type": "string"
        },
        "vat": {
          "type": "object",
          "properties": {
            "amount": {
              "type": "integer"
            },
            "country": {
              "type": "string"
            }
          },
          "required": [
            "amount",
            "country"
          ]
        }
      },
      "required": [
        "id",
        "email",
        "country",
        "location",
        "ip",
        "proxied",
        "browser_agent",
        "vat"
      ]
    },
    "product_variants": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "product_id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "product_id",
          "title"
        ]
      }
    }
  },
  "required": [
    "id",
    "payment",
    "status",
    "webhooks",
    "feedback",
    "created_at",
    "updated_at",
    "store_id",
    "coupon_id",
    "subscription_id",
    "customer_information",
    "product_variants"
  ]
}
```

Example:

```json
{
  "id": 1,
  "payment": {
    "fee": {
      "base": "0",
      "currency": "USD",
      "units": 1,
      "vat": 0,
      "total": {
        "exclusive": "0",
        "inclusive": "0"
      }
    },
    "gateway": {
      "data": {
        "total": {
          "base": "1999",
          "currency": "USD",
          "units": 1,
          "vat": 0,
          "total": {
            "exclusive": "1999",
            "inclusive": "1999"
          }
        },
        "customer_email": "customer@example.com",
        "transaction_id": "CQEGF35V"
      },
      "type": "COINBASE"
    },
    "subtotal": {
      "base": "1999",
      "currency": "USD",
      "units": 1,
      "vat": 0,
      "total": {
        "exclusive": "1999",
        "inclusive": "1999"
      }
    },
    "expires_at": "2024-01-10T19:33:11.000000Z",
    "full_price": {
      "base": "1999",
      "currency": "USD",
      "units": 1,
      "vat": 0,
      "total": {
        "exclusive": "1999",
        "inclusive": "1999"
      }
    },
    "original_amount": {
      "base": "1999",
      "currency": "USD",
      "units": 1,
      "vat": 0,
      "total": {
        "exclusive": "1999",
        "inclusive": "1999"
      }
    }
  },
  "status": {
    "history": [
      {
        "setAt": "2024-01-09T19:33:11.000000Z",
        "status": "PENDING",
        "updatedAt": "2024-01-09T21:17:46.000000Z"
      }
    ],
    "status": {
      "setAt": "2024-01-09T21:17:46.000000Z",
      "status": "COMPLETED",
      "updatedAt": "2024-01-09T21:17:46.000000Z"
    }
  },
  "webhooks": [],
  "feedback": "",
  "created_at": "2024-01-09T19:33:11.000000Z",
  "updated_at": "2024-01-09T21:17:46.000000Z",
  "store_id": 1,
  "coupon_id": null,
  "subscription_id": null,
  "customer_information": {
    "id": 1034,
    "email": "customer@example.com",
    "country": "Germany",
    "location": "Munich",
    "ip": "1.3.3.7",
    "proxied": false,
    "browser_agent": "Mozilla/4.9 (Windows 98; sl-SI; rv:1.9.1.20) Gecko/20110422 Firefox/21.0",
    "vat": {
      "amount": 0,
      "country": "US"
    }
  },
  "product_variants": [
    {
      "id": 117214,
      "product_id": 97850,
      "title": "SellApp Platform Balance"
    }
  ]
}
```

# Mark pending invoice voided (/docs/api/invoices/mark-pending-invoice-voided)

This endpoint allows you to update a pending invoice's status as voided. If marked as voided, the purchased product(s) would not be delivered to the customer's email. See the code examples for how to mark a pending invoice as voided with the SellApp API.

## Endpoint

- Method: `PATCH`

- Path: `/v2/invoices/{invoice}/mark-voided`

- Full URL: `https://sell.app/api/v2/invoices/{invoice}/mark-voided`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `invoice` (`integer`, required): The invoice path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "id": {
      "type": "integer"
    },
    "payment": {
      "type": "object",
      "properties": {
        "fee": {
          "type": "object",
          "properties": {
            "base": {
              "type": "string"
            },
            "currency": {
              "type": "string"
            },
            "units": {
              "type": "integer"
            },
            "vat": {
              "type": "integer"
            },
            "total": {
              "type": "object",
              "properties": {
                "exclusive": {
                  "type": "string"
                },
                "inclusive": {
                  "type": "string"
                }
              },
              "required": [
                "exclusive",
                "inclusive"
              ]
            }
          },
          "required": [
            "base",
            "currency",
            "units",
            "vat",
            "total"
          ]
        },
        "gateway": {
          "type": "object",
          "properties": {
            "data": {
              "type": "object",
              "properties": {
                "total": {
                  "type": "object",
                  "properties": {
                    "base": {
                      "type": "string"
                    },
                    "currency": {
                      "type": "string"
                    },
                    "units": {
                      "type": "integer"
                    },
                    "vat": {
                      "type": "integer"
                    },
                    "total": {
                      "type": "object",
                      "properties": {
                        "exclusive": {
                          "type": "string"
                        },
                        "inclusive": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "exclusive",
                        "inclusive"
                      ]
                    }
                  },
                  "required": [
                    "base",
                    "currency",
                    "units",
                    "vat",
                    "total"
                  ]
                },
                "customer_email": {
                  "type": "string"
                },
                "transaction_id": {
                  "type": "string"
                }
              },
              "required": [
                "total",
                "customer_email",
                "transaction_id"
              ]
            },
            "type": {
              "type": "string"
            }
          },
          "required": [
            "data",
            "type"
          ]
        },
        "subtotal": {
          "type": "object",
          "properties": {
            "base": {
              "type": "string"
            },
            "currency": {
              "type": "string"
            },
            "units": {
              "type": "integer"
            },
            "vat": {
              "type": "integer"
            },
            "total": {
              "type": "object",
              "properties": {
                "exclusive": {
                  "type": "string"
                },
                "inclusive": {
                  "type": "string"
                }
              },
              "required": [
                "exclusive",
                "inclusive"
              ]
            }
          },
          "required": [
            "base",
            "currency",
            "units",
            "vat",
            "total"
          ]
        },
        "expires_at": {
          "type": "string",
          "format": "date-time"
        },
        "full_price": {
          "type": "object",
          "properties": {
            "base": {
              "type": "string"
            },
            "currency": {
              "type": "string"
            },
            "units": {
              "type": "integer"
            },
            "vat": {
              "type": "integer"
            },
            "total": {
              "type": "object",
              "properties": {
                "exclusive": {
                  "type": "string"
                },
                "inclusive": {
                  "type": "string"
                }
              },
              "required": [
                "exclusive",
                "inclusive"
              ]
            }
          },
          "required": [
            "base",
            "currency",
            "units",
            "vat",
            "total"
          ]
        },
        "original_amount": {
          "type": "object",
          "properties": {
            "base": {
              "type": "string"
            },
            "currency": {
              "type": "string"
            },
            "units": {
              "type": "integer"
            },
            "vat": {
              "type": "integer"
            },
            "total": {
              "type": "object",
              "properties": {
                "exclusive": {
                  "type": "string"
                },
                "inclusive": {
                  "type": "string"
                }
              },
              "required": [
                "exclusive",
                "inclusive"
              ]
            }
          },
          "required": [
            "base",
            "currency",
            "units",
            "vat",
            "total"
          ]
        }
      },
      "required": [
        "fee",
        "gateway",
        "subtotal",
        "expires_at",
        "full_price",
        "original_amount"
      ]
    },
    "status": {
      "type": "object",
      "properties": {
        "history": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "setAt": {
                "type": "string",
                "format": "date-time"
              },
              "status": {
                "type": "string"
              },
              "updatedAt": {
                "type": "string",
                "format": "date-time"
              }
            },
            "required": [
              "setAt",
              "status",
              "updatedAt"
            ]
          }
        },
        "status": {
          "type": "object",
          "properties": {
            "setAt": {
              "type": "string",
              "format": "date-time"
            },
            "status": {
              "type": "string"
            },
            "updatedAt": {
              "type": "string",
              "format": "date-time"
            }
          },
          "required": [
            "setAt",
            "status",
            "updatedAt"
          ]
        }
      },
      "required": [
        "history",
        "status"
      ]
    },
    "webhooks": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "feedback": {
      "type": "string"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    },
    "store_id": {
      "type": "integer"
    },
    "coupon_id": {
      "type": "null"
    },
    "subscription_id": {
      "type": "null"
    },
    "customer_information": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "email": {
          "type": "string"
        },
        "country": {
          "type": "string"
        },
        "location": {
          "type": "string"
        },
        "ip": {
          "type": "string"
        },
        "proxied": {
          "type": "boolean"
        },
        "browser_agent": {
          "type": "string"
        },
        "vat": {
          "type": "object",
          "properties": {
            "amount": {
              "type": "integer"
            },
            "country": {
              "type": "string"
            }
          },
          "required": [
            "amount",
            "country"
          ]
        }
      },
      "required": [
        "id",
        "email",
        "country",
        "location",
        "ip",
        "proxied",
        "browser_agent",
        "vat"
      ]
    },
    "product_variants": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "product_id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "product_id",
          "title"
        ]
      }
    }
  },
  "required": [
    "id",
    "payment",
    "status",
    "webhooks",
    "feedback",
    "created_at",
    "updated_at",
    "store_id",
    "coupon_id",
    "subscription_id",
    "customer_information",
    "product_variants"
  ]
}
```

Example:

```json
{
  "id": 1,
  "payment": {
    "fee": {
      "base": "0",
      "currency": "USD",
      "units": 1,
      "vat": 0,
      "total": {
        "exclusive": "0",
        "inclusive": "0"
      }
    },
    "gateway": {
      "data": {
        "total": {
          "base": "1999",
          "currency": "USD",
          "units": 1,
          "vat": 0,
          "total": {
            "exclusive": "1999",
            "inclusive": "1999"
          }
        },
        "customer_email": "customer@example.com",
        "transaction_id": "CQEGF35V"
      },
      "type": "COINBASE"
    },
    "subtotal": {
      "base": "1999",
      "currency": "USD",
      "units": 1,
      "vat": 0,
      "total": {
        "exclusive": "1999",
        "inclusive": "1999"
      }
    },
    "expires_at": "2024-01-10T19:33:11.000000Z",
    "full_price": {
      "base": "1999",
      "currency": "USD",
      "units": 1,
      "vat": 0,
      "total": {
        "exclusive": "1999",
        "inclusive": "1999"
      }
    },
    "original_amount": {
      "base": "1999",
      "currency": "USD",
      "units": 1,
      "vat": 0,
      "total": {
        "exclusive": "1999",
        "inclusive": "1999"
      }
    }
  },
  "status": {
    "history": [
      {
        "setAt": "2024-01-09T19:33:11.000000Z",
        "status": "PENDING",
        "updatedAt": "2024-01-09T21:17:46.000000Z"
      }
    ],
    "status": {
      "setAt": "2024-01-09T21:17:46.000000Z",
      "status": "VOIDED",
      "updatedAt": "2024-01-09T21:17:46.000000Z"
    }
  },
  "webhooks": [],
  "feedback": "",
  "created_at": "2024-01-09T19:33:11.000000Z",
  "updated_at": "2024-01-09T21:17:46.000000Z",
  "store_id": 1,
  "coupon_id": null,
  "subscription_id": null,
  "customer_information": {
    "id": 1034,
    "email": "customer@example.com",
    "country": "Germany",
    "location": "Munich",
    "ip": "1.3.3.7",
    "proxied": false,
    "browser_agent": "Mozilla/4.9 (Windows 98; sl-SI; rv:1.9.1.20) Gecko/20110422 Firefox/21.0",
    "vat": {
      "amount": 0,
      "country": "US"
    }
  },
  "product_variants": [
    {
      "id": 117214,
      "product_id": 97850,
      "title": "SellApp Platform Balance"
    }
  ]
}
```

# Retrieve an invoice (/docs/api/invoices/retrieve-an-invoice)

You can retrieve a specific invoice using this endpoint. By providing the unique identifier, the specific invoice's details will be returned.

Refer to [the list](/api/invoices#the-invoice-model) to see which properties are included with invoice objects.

## Endpoint

- Method: `GET`

- Path: `/v2/invoices/{invoice}`

- Full URL: `https://sell.app/api/v2/invoices/{invoice}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `invoice` (`integer`, required): The invoice path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "payment": {
          "type": "object",
          "properties": {
            "fee": {
              "type": "object",
              "properties": {
                "base": {
                  "type": "string"
                },
                "currency": {
                  "type": "string"
                },
                "units": {
                  "type": "integer"
                },
                "vat": {
                  "type": "integer"
                },
                "total": {
                  "type": "object",
                  "properties": {
                    "exclusive": {
                      "type": "string"
                    },
                    "inclusive": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "exclusive",
                    "inclusive"
                  ]
                }
              },
              "required": [
                "base",
                "currency",
                "units",
                "vat",
                "total"
              ]
            },
            "gateway": {
              "type": "object",
              "properties": {
                "data": {
                  "type": "object",
                  "properties": {
                    "total": {
                      "type": "object",
                      "properties": {
                        "base": {
                          "type": "string"
                        },
                        "currency": {
                          "type": "string"
                        },
                        "units": {
                          "type": "integer"
                        },
                        "vat": {
                          "type": "integer"
                        },
                        "total": {
                          "type": "object",
                          "properties": {
                            "exclusive": {
                              "type": "string"
                            },
                            "inclusive": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "exclusive",
                            "inclusive"
                          ]
                        }
                      },
                      "required": [
                        "base",
                        "currency",
                        "units",
                        "vat",
                        "total"
                      ]
                    },
                    "customer_email": {
                      "type": "string"
                    },
                    "transaction_id": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "total",
                    "customer_email",
                    "transaction_id"
                  ]
                },
                "type": {
                  "type": "string"
                }
              },
              "required": [
                "data",
                "type"
              ]
            },
            "subtotal": {
              "type": "object",
              "properties": {
                "base": {
                  "type": "string"
                },
                "currency": {
                  "type": "string"
                },
                "units": {
                  "type": "integer"
                },
                "vat": {
                  "type": "integer"
                },
                "total": {
                  "type": "object",
                  "properties": {
                    "exclusive": {
                      "type": "string"
                    },
                    "inclusive": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "exclusive",
                    "inclusive"
                  ]
                }
              },
              "required": [
                "base",
                "currency",
                "units",
                "vat",
                "total"
              ]
            },
            "expires_at": {
              "type": "string",
              "format": "date-time"
            },
            "full_price": {
              "type": "object",
              "properties": {
                "base": {
                  "type": "string"
                },
                "currency": {
                  "type": "string"
                },
                "units": {
                  "type": "integer"
                },
                "vat": {
                  "type": "integer"
                },
                "total": {
                  "type": "object",
                  "properties": {
                    "exclusive": {
                      "type": "string"
                    },
                    "inclusive": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "exclusive",
                    "inclusive"
                  ]
                }
              },
              "required": [
                "base",
                "currency",
                "units",
                "vat",
                "total"
              ]
            },
            "original_amount": {
              "type": "object",
              "properties": {
                "base": {
                  "type": "string"
                },
                "currency": {
                  "type": "string"
                },
                "units": {
                  "type": "integer"
                },
                "vat": {
                  "type": "integer"
                },
                "total": {
                  "type": "object",
                  "properties": {
                    "exclusive": {
                      "type": "string"
                    },
                    "inclusive": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "exclusive",
                    "inclusive"
                  ]
                }
              },
              "required": [
                "base",
                "currency",
                "units",
                "vat",
                "total"
              ]
            }
          },
          "required": [
            "fee",
            "gateway",
            "subtotal",
            "expires_at",
            "full_price",
            "original_amount"
          ]
        },
        "status": {
          "type": "object",
          "properties": {
            "history": {
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "setAt": {
                    "type": "string",
                    "format": "date-time"
                  },
                  "status": {
                    "type": "string"
                  },
                  "updatedAt": {
                    "type": "string",
                    "format": "date-time"
                  }
                },
                "required": [
                  "setAt",
                  "status",
                  "updatedAt"
                ]
              }
            },
            "status": {
              "type": "object",
              "properties": {
                "setAt": {
                  "type": "string",
                  "format": "date-time"
                },
                "status": {
                  "type": "string"
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time"
                }
              },
              "required": [
                "setAt",
                "status",
                "updatedAt"
              ]
            }
          },
          "required": [
            "history",
            "status"
          ]
        },
        "webhooks": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "feedback": {
          "type": "string"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "store_id": {
          "type": "integer"
        },
        "coupon_id": {
          "type": "null"
        },
        "subscription_id": {
          "type": "null"
        },
        "customer_information": {
          "type": "object",
          "properties": {
            "id": {
              "type": "integer"
            },
            "email": {
              "type": "string"
            },
            "country": {
              "type": "string"
            },
            "location": {
              "type": "string"
            },
            "ip": {
              "type": "string"
            },
            "proxied": {
              "type": "boolean"
            },
            "browser_agent": {
              "type": "string"
            },
            "vat": {
              "type": "object",
              "properties": {
                "amount": {
                  "type": "integer"
                },
                "country": {
                  "type": "string"
                }
              },
              "required": [
                "amount",
                "country"
              ]
            }
          },
          "required": [
            "id",
            "email",
            "country",
            "location",
            "ip",
            "proxied",
            "browser_agent",
            "vat"
          ]
        },
        "product_variants": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "id": {
                "type": "integer"
              },
              "product_id": {
                "type": "integer"
              },
              "title": {
                "type": "string"
              }
            },
            "required": [
              "id",
              "product_id",
              "title"
            ]
          }
        }
      },
      "required": [
        "id",
        "payment",
        "status",
        "webhooks",
        "feedback",
        "created_at",
        "updated_at",
        "store_id",
        "coupon_id",
        "subscription_id",
        "customer_information",
        "product_variants"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "payment": {
      "fee": {
        "base": "0",
        "currency": "USD",
        "units": 1,
        "vat": 0,
        "total": {
          "exclusive": "0",
          "inclusive": "0"
        }
      },
      "gateway": {
        "data": {
          "total": {
            "base": "1999",
            "currency": "USD",
            "units": 1,
            "vat": 0,
            "total": {
              "exclusive": "1999",
              "inclusive": "1999"
            }
          },
          "customer_email": "customer@example.com",
          "transaction_id": "CQEGF35V"
        },
        "type": "COINBASE"
      },
      "subtotal": {
        "base": "1999",
        "currency": "USD",
        "units": 1,
        "vat": 0,
        "total": {
          "exclusive": "1999",
          "inclusive": "1999"
        }
      },
      "expires_at": "2024-01-09T23:50:11.000000Z",
      "full_price": {
        "base": "1999",
        "currency": "USD",
        "units": 1,
        "vat": 0,
        "total": {
          "exclusive": "1999",
          "inclusive": "1999"
        }
      },
      "original_amount": {
        "base": "1999",
        "currency": "USD",
        "units": 1,
        "vat": 0,
        "total": {
          "exclusive": "1999",
          "inclusive": "1999"
        }
      }
    },
    "status": {
      "history": [
        {
          "setAt": "2024-01-09T14:50:11.000000Z",
          "status": "PENDING",
          "updatedAt": "2024-01-09T18:00:50.000000Z"
        }
      ],
      "status": {
        "setAt": "2024-01-09T18:00:50.000000Z",
        "status": "COMPLETED",
        "updatedAt": "2024-01-09T18:00:50.000000Z"
      }
    },
    "webhooks": [],
    "feedback": "",
    "created_at": "2024-01-09T14:50:11.000000Z",
    "updated_at": "2024-01-09T18:00:50.000000Z",
    "store_id": 1,
    "coupon_id": null,
    "subscription_id": null,
    "customer_information": {
      "id": 123,
      "email": "customer@example.com",
      "country": "Germany",
      "location": "Munich",
      "ip": "1.3.3.7",
      "proxied": false,
      "browser_agent": "Mozilla/4.9 (Windows 98; sl-SI; rv:1.9.1.20) Gecko/20110422 Firefox/21.0",
      "vat": {
        "amount": 0,
        "country": "DE"
      }
    },
    "product_variants": [
      {
        "id": 117214,
        "product_id": 97850,
        "title": "SellApp Platform Balance"
      }
    ]
  }
}
```

# Search invoices (/docs/api/invoices/search-invoices)

This endpoint is a backward-compatible search endpoint for invoice lookups. It accepts the same filters as the list endpoint, but in a JSON request body instead of query parameters.

Search responses return the same paginated invoice objects as the list endpoint.

## Endpoint

- Method: `POST`

- Path: `/v2/invoices/search`

- Full URL: `https://sell.app/api/v2/invoices/search`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "search": {
      "type": "string"
    },
    "search_by": {
      "type": "string",
      "enum": [
        "default",
        "transaction_id",
        "serial_code",
        "additional_info",
        "product_name",
        "discord_data",
        "crypto_txid",
        "crypto_address",
        "coupon_code"
      ]
    },
    "id": {
      "type": "string"
    },
    "email": {
      "type": "string"
    },
    "transaction_id": {
      "type": "string"
    },
    "serial_code": {
      "type": "string"
    },
    "additional_info": {
      "type": "string"
    },
    "product_name": {
      "type": "string"
    },
    "discord_data": {
      "type": "string"
    },
    "crypto_txid": {
      "type": "string"
    },
    "crypto_address": {
      "type": "string"
    },
    "coupon_code": {
      "type": "string"
    },
    "status": {
      "type": "array",
      "items": {
        "type": "string",
        "enum": [
          "PENDING",
          "REVERSED",
          "PARTIAL",
          "VOIDED",
          "REFUNDED",
          "PAID",
          "COMPLETED",
          "DISPUTING",
          "REVIEW",
          "FAILED"
        ]
      }
    },
    "payment_methods": {
      "type": "array",
      "items": {
        "type": "string",
        "enum": [
          "AUTHNET",
          "BTCPAY",
          "CASHAPP",
          "COINBASE",
          "PADDLE",
          "PAYDASH",
          "PAYPAL",
          "PAYSTACK",
          "SQUARE",
          "STRIPE",
          "VENMO",
          "NMI",
          "LIFI",
          "BTC",
          "LTC",
          "ETH",
          "XMR",
          "SOL",
          "ADA",
          "BNB",
          "TRX",
          "MATIC",
          "ETH_USDT",
          "ETH_USDC",
          "ETH_UNI",
          "ETH_SHIB",
          "ETH_DAI",
          "BNB_USDT",
          "BNB_USDC",
          "TRX_USDT",
          "TRX_USDC",
          "SOL_USDT",
          "SOL_USDC"
        ]
      }
    },
    "sort": {
      "type": "string",
      "enum": [
        "created_at",
        "-created_at"
      ]
    }
  }
}
```

Example:

```json
{
  "id": "3055526",
  "sort": "-created_at"
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "payment": {
            "type": "object",
            "properties": {
              "fee": {
                "type": "object",
                "properties": {
                  "base": {
                    "type": "string"
                  },
                  "currency": {
                    "type": "string"
                  },
                  "units": {
                    "type": "integer"
                  },
                  "vat": {
                    "type": "integer"
                  },
                  "total": {
                    "type": "object",
                    "properties": {
                      "exclusive": {
                        "type": "string"
                      },
                      "inclusive": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "exclusive",
                      "inclusive"
                    ]
                  }
                },
                "required": [
                  "base",
                  "currency",
                  "units",
                  "vat",
                  "total"
                ]
              },
              "gateway": {
                "type": "object",
                "properties": {
                  "data": {
                    "type": "object",
                    "properties": {
                      "total": {
                        "type": "object",
                        "properties": {
                          "base": {
                            "type": "string"
                          },
                          "currency": {
                            "type": "string"
                          },
                          "units": {
                            "type": "integer"
                          },
                          "vat": {
                            "type": "integer"
                          },
                          "total": {
                            "type": "object",
                            "properties": {
                              "exclusive": {
                                "type": "string"
                              },
                              "inclusive": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "exclusive",
                              "inclusive"
                            ]
                          }
                        },
                        "required": [
                          "base",
                          "currency",
                          "units",
                          "vat",
                          "total"
                        ]
                      },
                      "customer_email": {
                        "type": "string"
                      },
                      "transaction_id": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "total",
                      "customer_email",
                      "transaction_id"
                    ]
                  },
                  "type": {
                    "type": "string"
                  }
                },
                "required": [
                  "data",
                  "type"
                ]
              },
              "subtotal": {
                "type": "object",
                "properties": {
                  "base": {
                    "type": "string"
                  },
                  "currency": {
                    "type": "string"
                  },
                  "units": {
                    "type": "integer"
                  },
                  "vat": {
                    "type": "integer"
                  },
                  "total": {
                    "type": "object",
                    "properties": {
                      "exclusive": {
                        "type": "string"
                      },
                      "inclusive": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "exclusive",
                      "inclusive"
                    ]
                  }
                },
                "required": [
                  "base",
                  "currency",
                  "units",
                  "vat",
                  "total"
                ]
              },
              "expires_at": {
                "type": "string",
                "format": "date-time"
              },
              "full_price": {
                "type": "object",
                "properties": {
                  "base": {
                    "type": "string"
                  },
                  "currency": {
                    "type": "string"
                  },
                  "units": {
                    "type": "integer"
                  },
                  "vat": {
                    "type": "integer"
                  },
                  "total": {
                    "type": "object",
                    "properties": {
                      "exclusive": {
                        "type": "string"
                      },
                      "inclusive": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "exclusive",
                      "inclusive"
                    ]
                  }
                },
                "required": [
                  "base",
                  "currency",
                  "units",
                  "vat",
                  "total"
                ]
              },
              "original_amount": {
                "type": "object",
                "properties": {
                  "base": {
                    "type": "string"
                  },
                  "currency": {
                    "type": "string"
                  },
                  "units": {
                    "type": "integer"
                  },
                  "vat": {
                    "type": "integer"
                  },
                  "total": {
                    "type": "object",
                    "properties": {
                      "exclusive": {
                        "type": "string"
                      },
                      "inclusive": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "exclusive",
                      "inclusive"
                    ]
                  }
                },
                "required": [
                  "base",
                  "currency",
                  "units",
                  "vat",
                  "total"
                ]
              }
            },
            "required": [
              "fee",
              "gateway",
              "subtotal",
              "expires_at",
              "full_price",
              "original_amount"
            ]
          },
          "status": {
            "type": "object",
            "properties": {
              "history": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "setAt": {
                      "type": "string",
                      "format": "date-time"
                    },
                    "status": {
                      "type": "string"
                    },
                    "updatedAt": {
                      "type": "string",
                      "format": "date-time"
                    }
                  },
                  "required": [
                    "setAt",
                    "status",
                    "updatedAt"
                  ]
                }
              },
              "status": {
                "type": "object",
                "properties": {
                  "setAt": {
                    "type": "string",
                    "format": "date-time"
                  },
                  "status": {
                    "type": "string"
                  },
                  "updatedAt": {
                    "type": "string",
                    "format": "date-time"
                  }
                },
                "required": [
                  "setAt",
                  "status",
                  "updatedAt"
                ]
              }
            },
            "required": [
              "history",
              "status"
            ]
          },
          "webhooks": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "feedback": {
            "type": "string"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "store_id": {
            "type": "integer"
          },
          "coupon_id": {
            "type": "null"
          },
          "subscription_id": {
            "type": "null"
          },
          "customer_information": {
            "type": "object",
            "properties": {
              "id": {
                "type": "integer"
              },
              "email": {
                "type": "string"
              },
              "country": {
                "type": "string"
              },
              "location": {
                "type": "string"
              },
              "ip": {
                "type": "string"
              },
              "proxied": {
                "type": "boolean"
              },
              "browser_agent": {
                "type": "string"
              },
              "vat": {
                "type": "object",
                "properties": {
                  "amount": {
                    "type": "integer"
                  },
                  "country": {
                    "type": "string"
                  }
                },
                "required": [
                  "amount",
                  "country"
                ]
              }
            },
            "required": [
              "id",
              "email",
              "country",
              "location",
              "ip",
              "proxied",
              "browser_agent",
              "vat"
            ]
          },
          "product_variants": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "integer"
                },
                "product_id": {
                  "type": "integer"
                },
                "title": {
                  "type": "string"
                }
              },
              "required": [
                "id",
                "product_id",
                "title"
              ]
            }
          }
        },
        "required": [
          "id",
          "payment",
          "status",
          "webhooks",
          "feedback",
          "created_at",
          "updated_at",
          "store_id",
          "coupon_id",
          "subscription_id",
          "customer_information",
          "product_variants"
        ]
      }
    },
    "links": {
      "type": "object",
      "properties": {}
    },
    "meta": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "data",
    "links",
    "meta"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "payment": {
        "fee": {
          "base": "0",
          "currency": "USD",
          "units": 1,
          "vat": 0,
          "total": {
            "exclusive": "0",
            "inclusive": "0"
          }
        },
        "gateway": {
          "data": {
            "total": {
              "base": "1999",
              "currency": "USD",
              "units": 1,
              "vat": 0,
              "total": {
                "exclusive": "1999",
                "inclusive": "1999"
              }
            },
            "customer_email": "customer@example.com",
            "transaction_id": "CQEGF35V"
          },
          "type": "COINBASE"
        },
        "subtotal": {
          "base": "1999",
          "currency": "USD",
          "units": 1,
          "vat": 0,
          "total": {
            "exclusive": "1999",
            "inclusive": "1999"
          }
        },
        "expires_at": "2024-01-09T23:50:11.000000Z",
        "full_price": {
          "base": "1999",
          "currency": "USD",
          "units": 1,
          "vat": 0,
          "total": {
            "exclusive": "1999",
            "inclusive": "1999"
          }
        },
        "original_amount": {
          "base": "1999",
          "currency": "USD",
          "units": 1,
          "vat": 0,
          "total": {
            "exclusive": "1999",
            "inclusive": "1999"
          }
        }
      },
      "status": {
        "history": [
          {
            "setAt": "2024-01-09T14:50:11.000000Z",
            "status": "PENDING",
            "updatedAt": "2024-01-09T18:00:50.000000Z"
          }
        ],
        "status": {
          "setAt": "2024-01-09T18:00:50.000000Z",
          "status": "COMPLETED",
          "updatedAt": "2024-01-09T18:00:50.000000Z"
        }
      },
      "webhooks": [],
      "feedback": "",
      "created_at": "2024-01-09T14:50:11.000000Z",
      "updated_at": "2024-01-09T18:00:50.000000Z",
      "store_id": 1,
      "coupon_id": null,
      "subscription_id": null,
      "customer_information": {
        "id": 123,
        "email": "customer@example.com",
        "country": "Germany",
        "location": "Munich",
        "ip": "1.3.3.7",
        "proxied": false,
        "browser_agent": "Mozilla/4.9 (Windows 98; sl-SI; rv:1.9.1.20) Gecko/20110422 Firefox/21.0",
        "vat": {
          "amount": 0,
          "country": "DE"
        }
      },
      "product_variants": [
        {
          "id": 117214,
          "product_id": 97850,
          "title": "SellApp Platform Balance"
        }
      ]
    }
  ],
  "links": {},
  "meta": {}
}
```

# View invoice deliverables (/docs/api/invoices/view-invoice-deliverables)

This endpoint shows the deliverables that have been sent to the customer. If a customer has purchased multiple products, all of the deliverables will be shown.

See the code examples for how to display the deliverables for an existing invoice with the SellApp API.

The response is returned as a `data` array. Each item includes the invoice ID, product variant ID, deliverable payload, fulfilled quantity, and any additional information captured for that line item.

## Endpoint

- Method: `GET`

- Path: `/v2/invoices/{invoice}/deliverables`

- Full URL: `https://sell.app/api/v2/invoices/{invoice}/deliverables`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `invoice` (`integer`, required): The invoice path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "invoice_id": {
            "type": "integer"
          },
          "product_variant_id": {
            "type": "integer"
          },
          "deliverable": {
            "type": "object",
            "properties": {
              "types": {
                "type": "array",
                "items": {
                  "type": "string",
                  "enum": [
                    "DOWNLOADABLE",
                    "TEXT",
                    "DYNAMIC",
                    "MANUAL",
                    "LICENSE_KEY",
                    "BUNDLE"
                  ]
                }
              },
              "data": {
                "type": "object",
                "properties": {
                  "serials": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "delivered_files": {
                    "type": "array",
                    "items": {
                      "type": "string",
                      "format": "uri"
                    }
                  },
                  "dynamic": {
                    "type": "string"
                  },
                  "manual": {
                    "type": "string"
                  },
                  "license_keys": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  }
                }
              }
            },
            "required": [
              "types",
              "data"
            ]
          },
          "quantity": {
            "type": "integer"
          },
          "additional_information": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "key": {
                  "type": "string"
                },
                "type": {
                  "type": "string"
                },
                "label": {
                  "type": "string"
                },
                "value": {}
              },
              "required": [
                "key",
                "type",
                "label",
                "value"
              ]
            }
          }
        },
        "required": [
          "invoice_id",
          "product_variant_id",
          "deliverable",
          "quantity",
          "additional_information"
        ]
      }
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "invoice_id": 1234,
      "product_variant_id": 4321,
      "deliverable": {
        "types": [
          "MANUAL"
        ],
        "data": {
          "manual": "Thank you for your purchase!"
        }
      },
      "quantity": 1,
      "additional_information": [
        {
          "key": "1043ecaf066ae98d839b334b2ee274d5",
          "type": "text",
          "label": "Do you like biscuits?",
          "value": "Yes I do!"
        }
      ]
    }
  ]
}
```

# Batch create product variants (/docs/api/product-variants/batch-create-product-variants)

Create multiple variants for a product in one request by sending a `resources` array.

## Endpoint

- Method: `POST`

- Path: `/v2/products/{product}/variants/batch`

- Full URL: `https://sell.app/api/v2/products/{product}/variants/batch`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `product` (`integer`, required): The product path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "resources": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "title": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "deliverable": {
            "type": "object",
            "properties": {
              "types": {
                "type": "array",
                "items": {
                  "type": "string",
                  "enum": [
                    "DOWNLOADABLE",
                    "TEXT",
                    "DYNAMIC",
                    "MANUAL",
                    "LICENSE_KEY",
                    "BUNDLE"
                  ]
                }
              },
              "data": {
                "type": "object",
                "properties": {
                  "stock": {
                    "type": [
                      "integer",
                      "null"
                    ]
                  },
                  "serials": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "removeDuplicate": {
                    "type": "boolean"
                  },
                  "parsingMode": {
                    "type": "string",
                    "enum": [
                      "COMMA",
                      "NEW_LINE",
                      "SPACE",
                      "CUSTOM"
                    ]
                  },
                  "comment": {
                    "type": "string"
                  },
                  "webhook": {
                    "type": "string",
                    "format": "uri"
                  }
                }
              }
            },
            "required": [
              "types",
              "data"
            ]
          },
          "pricing": {
            "type": "object",
            "properties": {
              "humble": {
                "type": "boolean"
              },
              "price": {
                "type": "object",
                "properties": {
                  "price": {
                    "type": "integer"
                  },
                  "currency": {
                    "type": "string"
                  }
                },
                "required": [
                  "price",
                  "currency"
                ]
              }
            },
            "required": [
              "humble",
              "price"
            ]
          },
          "minimum_purchase_quantity": {
            "type": "integer"
          },
          "maximum_purchase_quantity": {
            "type": [
              "integer",
              "null"
            ]
          },
          "bulk_discount": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "minimum_purchase_amount": {
                  "type": "integer"
                },
                "discount_percentage": {
                  "type": "integer"
                }
              },
              "required": [
                "minimum_purchase_amount",
                "discount_percentage"
              ]
            }
          },
          "payment_methods": {
            "type": "array",
            "minItems": 1,
            "items": {
              "type": "string",
              "enum": [
                "AUTHNET",
                "BTCPAY",
                "CASHAPP",
                "COINBASE",
                "PADDLE",
                "PAYDASH",
                "PAYPAL",
                "PAYSTACK",
                "SQUARE",
                "STRIPE",
                "VENMO",
                "NMI",
                "LIFI",
                "BTC",
                "LTC",
                "ETH",
                "XMR",
                "SOL",
                "ADA",
                "BNB",
                "TRX",
                "MATIC",
                "ETH_USDT",
                "ETH_USDC",
                "ETH_UNI",
                "ETH_SHIB",
                "ETH_DAI",
                "BNB_USDT",
                "BNB_USDC",
                "TRX_USDT",
                "TRX_USDC",
                "SOL_USDT",
                "SOL_USDC"
              ]
            }
          },
          "other_settings": {
            "type": "object",
            "properties": {
              "quantity_increments": {
                "type": "integer"
              }
            }
          }
        },
        "required": [
          "title",
          "description",
          "deliverable",
          "pricing",
          "payment_methods"
        ]
      }
    }
  },
  "required": [
    "resources"
  ]
}
```

Example:

```json
{
  "resources": [
    {
      "title": "Default",
      "description": "Default product variant.",
      "deliverable": {
        "types": [
          "TEXT"
        ],
        "data": {
          "serials": [
            "SERIAL-001"
          ],
          "parsingMode": "NEW_LINE",
          "removeDuplicate": true
        }
      },
      "pricing": {
        "humble": false,
        "price": {
          "price": 1000,
          "currency": "USD"
        }
      },
      "payment_methods": [
        "PAYPAL"
      ]
    }
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "product_id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "deliverable": {
            "type": "object",
            "properties": {
              "data": {
                "type": "object",
                "properties": {
                  "removeDuplicate": {
                    "type": "boolean"
                  },
                  "parsingMode": {
                    "type": "string"
                  },
                  "stock": {
                    "type": "integer"
                  },
                  "comment": {
                    "type": "string"
                  },
                  "serials": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  }
                },
                "required": [
                  "removeDuplicate",
                  "parsingMode",
                  "stock",
                  "comment",
                  "serials"
                ]
              },
              "types": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              }
            },
            "required": [
              "data",
              "types"
            ]
          },
          "pricing": {
            "type": "object",
            "properties": {
              "humble": {
                "type": "boolean"
              },
              "frequency": {
                "type": "object",
                "properties": {
                  "value": {
                    "type": "integer"
                  },
                  "interval": {
                    "type": "string"
                  }
                },
                "required": [
                  "value",
                  "interval"
                ]
              },
              "type": {
                "type": "string"
              },
              "price": {
                "type": "object",
                "properties": {
                  "price": {
                    "type": "string"
                  },
                  "currency": {
                    "type": "string"
                  }
                },
                "required": [
                  "price",
                  "currency"
                ]
              }
            },
            "required": [
              "humble",
              "frequency",
              "type",
              "price"
            ]
          },
          "minimum_purchase_quantity": {
            "type": "integer"
          },
          "maximum_purchase_quantity": {
            "type": "integer"
          },
          "bulk_discount": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "discount_percentage": {
                  "type": "integer"
                },
                "minimum_purchase_amount": {
                  "type": "integer"
                }
              },
              "required": [
                "discount_percentage",
                "minimum_purchase_amount"
              ]
            }
          },
          "payment_methods": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "other_settings": {
            "type": "object",
            "properties": {
              "quantity_increments": {
                "type": "integer"
              },
              "discord_data_required": {
                "type": "boolean"
              }
            },
            "required": [
              "quantity_increments",
              "discord_data_required"
            ]
          },
          "order": {
            "type": "integer"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "deleted_at": {
            "type": "null"
          },
          "product": {
            "type": "object",
            "properties": {
              "additional_information": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "required": {
                      "type": "boolean"
                    },
                    "key": {
                      "type": "string"
                    },
                    "type": {
                      "type": "string"
                    },
                    "label": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "required",
                    "key",
                    "type",
                    "label"
                  ]
                }
              }
            },
            "required": [
              "additional_information"
            ]
          }
        },
        "required": [
          "id",
          "product_id",
          "title",
          "description",
          "deliverable",
          "pricing",
          "minimum_purchase_quantity",
          "maximum_purchase_quantity",
          "bulk_discount",
          "payment_methods",
          "other_settings",
          "order",
          "created_at",
          "updated_at",
          "deleted_at",
          "product"
        ]
      }
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 2,
      "product_id": 1,
      "title": "Variant Title",
      "description": "Variant Description",
      "deliverable": {
        "data": {
          "removeDuplicate": false,
          "parsingMode": "COMMA",
          "stock": 3,
          "comment": "Thanks for the purchase! I'll send you a contract by email. Make sure to sign it with your blood.",
          "serials": [
            "1",
            "2",
            "3"
          ]
        },
        "types": [
          "TEXT",
          "MANUAL"
        ]
      },
      "pricing": {
        "humble": true,
        "frequency": {
          "value": 1,
          "interval": "MONTH"
        },
        "type": "SINGLE_PAYMENT",
        "price": {
          "price": "1999",
          "currency": "USD"
        }
      },
      "minimum_purchase_quantity": 1,
      "maximum_purchase_quantity": 3,
      "bulk_discount": [
        {
          "discount_percentage": 10,
          "minimum_purchase_amount": 10
        }
      ],
      "payment_methods": [
        "BTC",
        "STRIPE"
      ],
      "other_settings": {
        "quantity_increments": 2,
        "discord_data_required": false
      },
      "order": 1,
      "created_at": "2024-01-10T18:47:22.000000Z",
      "updated_at": "2024-01-10T18:47:22.000000Z",
      "deleted_at": null,
      "product": {
        "additional_information": [
          {
            "required": true,
            "key": "5ebae238c0afae7f4a4b96b30ff6f34c",
            "type": "CHECKBOX",
            "label": "I agree to handing over my soul"
          }
        ]
      }
    }
  ]
}
```

# Batch delete product variants (/docs/api/product-variants/batch-delete-product-variants)

Delete multiple product variants in one request by sending the variant IDs in `resources`.

## Endpoint

- Method: `DELETE`

- Path: `/v2/products/{product}/variants/batch`

- Full URL: `https://sell.app/api/v2/products/{product}/variants/batch`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `product` (`integer`, required): The product path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "resources": {
      "type": "array",
      "items": {
        "type": "integer"
      }
    }
  },
  "required": [
    "resources"
  ]
}
```

Example:

```json
{
  "resources": [
    1,
    2
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "product_id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "deliverable": {
            "type": "object",
            "properties": {
              "data": {
                "type": "object",
                "properties": {
                  "removeDuplicate": {
                    "type": "boolean"
                  },
                  "parsingMode": {
                    "type": "string"
                  },
                  "stock": {
                    "type": "integer"
                  },
                  "comment": {
                    "type": "string"
                  },
                  "serials": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  }
                },
                "required": [
                  "removeDuplicate",
                  "parsingMode",
                  "stock",
                  "comment",
                  "serials"
                ]
              },
              "types": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              }
            },
            "required": [
              "data",
              "types"
            ]
          },
          "pricing": {
            "type": "object",
            "properties": {
              "humble": {
                "type": "boolean"
              },
              "frequency": {
                "type": "object",
                "properties": {
                  "value": {
                    "type": "integer"
                  },
                  "interval": {
                    "type": "string"
                  }
                },
                "required": [
                  "value",
                  "interval"
                ]
              },
              "type": {
                "type": "string"
              },
              "price": {
                "type": "object",
                "properties": {
                  "price": {
                    "type": "string"
                  },
                  "currency": {
                    "type": "string"
                  }
                },
                "required": [
                  "price",
                  "currency"
                ]
              }
            },
            "required": [
              "humble",
              "frequency",
              "type",
              "price"
            ]
          },
          "minimum_purchase_quantity": {
            "type": "integer"
          },
          "maximum_purchase_quantity": {
            "type": "integer"
          },
          "bulk_discount": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "discount_percentage": {
                  "type": "integer"
                },
                "minimum_purchase_amount": {
                  "type": "integer"
                }
              },
              "required": [
                "discount_percentage",
                "minimum_purchase_amount"
              ]
            }
          },
          "payment_methods": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "other_settings": {
            "type": "object",
            "properties": {
              "quantity_increments": {
                "type": "integer"
              },
              "discord_data_required": {
                "type": "boolean"
              }
            },
            "required": [
              "quantity_increments",
              "discord_data_required"
            ]
          },
          "order": {
            "type": "integer"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "deleted_at": {
            "type": "null"
          },
          "product": {
            "type": "object",
            "properties": {
              "additional_information": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "required": {
                      "type": "boolean"
                    },
                    "key": {
                      "type": "string"
                    },
                    "type": {
                      "type": "string"
                    },
                    "label": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "required",
                    "key",
                    "type",
                    "label"
                  ]
                }
              }
            },
            "required": [
              "additional_information"
            ]
          }
        },
        "required": [
          "id",
          "product_id",
          "title",
          "description",
          "deliverable",
          "pricing",
          "minimum_purchase_quantity",
          "maximum_purchase_quantity",
          "bulk_discount",
          "payment_methods",
          "other_settings",
          "order",
          "created_at",
          "updated_at",
          "deleted_at",
          "product"
        ]
      }
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 2,
      "product_id": 1,
      "title": "Variant Title",
      "description": "Variant Description",
      "deliverable": {
        "data": {
          "removeDuplicate": false,
          "parsingMode": "COMMA",
          "stock": 3,
          "comment": "Thanks for the purchase! I'll send you a contract by email. Make sure to sign it with your blood.",
          "serials": [
            "1",
            "2",
            "3"
          ]
        },
        "types": [
          "TEXT",
          "MANUAL"
        ]
      },
      "pricing": {
        "humble": true,
        "frequency": {
          "value": 1,
          "interval": "MONTH"
        },
        "type": "SINGLE_PAYMENT",
        "price": {
          "price": "1999",
          "currency": "USD"
        }
      },
      "minimum_purchase_quantity": 1,
      "maximum_purchase_quantity": 3,
      "bulk_discount": [
        {
          "discount_percentage": 10,
          "minimum_purchase_amount": 10
        }
      ],
      "payment_methods": [
        "BTC",
        "STRIPE"
      ],
      "other_settings": {
        "quantity_increments": 2,
        "discord_data_required": false
      },
      "order": 1,
      "created_at": "2024-01-10T18:47:22.000000Z",
      "updated_at": "2024-01-10T18:47:22.000000Z",
      "deleted_at": null,
      "product": {
        "additional_information": [
          {
            "required": true,
            "key": "5ebae238c0afae7f4a4b96b30ff6f34c",
            "type": "CHECKBOX",
            "label": "I agree to handing over my soul"
          }
        ]
      }
    }
  ]
}
```

# Batch update product variants (/docs/api/product-variants/batch-update-product-variants)

Update multiple product variants in one request by sending a `resources` object keyed by variant ID.

## Endpoint

- Method: `PATCH`

- Path: `/v2/products/{product}/variants/batch`

- Full URL: `https://sell.app/api/v2/products/{product}/variants/batch`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `product` (`integer`, required): The product path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "resources": {
      "type": "object",
      "additionalProperties": {
        "type": "object",
        "properties": {
          "title": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "deliverable": {
            "type": "object",
            "properties": {
              "types": {
                "type": "array",
                "items": {
                  "type": "string",
                  "enum": [
                    "DOWNLOADABLE",
                    "TEXT",
                    "DYNAMIC",
                    "MANUAL",
                    "LICENSE_KEY",
                    "BUNDLE"
                  ]
                }
              },
              "data": {
                "type": "object",
                "properties": {
                  "stock": {
                    "type": [
                      "integer",
                      "null"
                    ]
                  },
                  "serials": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "removeDuplicate": {
                    "type": "boolean"
                  },
                  "parsingMode": {
                    "type": "string",
                    "enum": [
                      "COMMA",
                      "NEW_LINE",
                      "SPACE",
                      "CUSTOM"
                    ]
                  },
                  "comment": {
                    "type": "string"
                  },
                  "webhook": {
                    "type": "string",
                    "format": "uri"
                  }
                }
              }
            },
            "required": [
              "types",
              "data"
            ]
          },
          "pricing": {
            "type": "object",
            "properties": {
              "humble": {
                "type": "boolean"
              },
              "price": {
                "type": "object",
                "properties": {
                  "price": {
                    "type": "integer"
                  },
                  "currency": {
                    "type": "string"
                  }
                },
                "required": [
                  "price",
                  "currency"
                ]
              }
            },
            "required": [
              "humble",
              "price"
            ]
          },
          "minimum_purchase_quantity": {
            "type": "integer"
          },
          "maximum_purchase_quantity": {
            "type": [
              "integer",
              "null"
            ]
          },
          "bulk_discount": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "minimum_purchase_amount": {
                  "type": "integer"
                },
                "discount_percentage": {
                  "type": "integer"
                }
              },
              "required": [
                "minimum_purchase_amount",
                "discount_percentage"
              ]
            }
          },
          "payment_methods": {
            "type": "array",
            "minItems": 1,
            "items": {
              "type": "string",
              "enum": [
                "AUTHNET",
                "BTCPAY",
                "CASHAPP",
                "COINBASE",
                "PADDLE",
                "PAYDASH",
                "PAYPAL",
                "PAYSTACK",
                "SQUARE",
                "STRIPE",
                "VENMO",
                "NMI",
                "LIFI",
                "BTC",
                "LTC",
                "ETH",
                "XMR",
                "SOL",
                "ADA",
                "BNB",
                "TRX",
                "MATIC",
                "ETH_USDT",
                "ETH_USDC",
                "ETH_UNI",
                "ETH_SHIB",
                "ETH_DAI",
                "BNB_USDT",
                "BNB_USDC",
                "TRX_USDT",
                "TRX_USDC",
                "SOL_USDT",
                "SOL_USDC"
              ]
            }
          },
          "other_settings": {
            "type": "object",
            "properties": {
              "quantity_increments": {
                "type": "integer"
              }
            }
          }
        }
      }
    }
  },
  "required": [
    "resources"
  ]
}
```

Example:

```json
{
  "resources": {
    "1": {
      "title": "Updated variant"
    }
  }
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "product_id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "deliverable": {
            "type": "object",
            "properties": {
              "data": {
                "type": "object",
                "properties": {
                  "removeDuplicate": {
                    "type": "boolean"
                  },
                  "parsingMode": {
                    "type": "string"
                  },
                  "stock": {
                    "type": "integer"
                  },
                  "comment": {
                    "type": "string"
                  },
                  "serials": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  }
                },
                "required": [
                  "removeDuplicate",
                  "parsingMode",
                  "stock",
                  "comment",
                  "serials"
                ]
              },
              "types": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              }
            },
            "required": [
              "data",
              "types"
            ]
          },
          "pricing": {
            "type": "object",
            "properties": {
              "humble": {
                "type": "boolean"
              },
              "frequency": {
                "type": "object",
                "properties": {
                  "value": {
                    "type": "integer"
                  },
                  "interval": {
                    "type": "string"
                  }
                },
                "required": [
                  "value",
                  "interval"
                ]
              },
              "type": {
                "type": "string"
              },
              "price": {
                "type": "object",
                "properties": {
                  "price": {
                    "type": "string"
                  },
                  "currency": {
                    "type": "string"
                  }
                },
                "required": [
                  "price",
                  "currency"
                ]
              }
            },
            "required": [
              "humble",
              "frequency",
              "type",
              "price"
            ]
          },
          "minimum_purchase_quantity": {
            "type": "integer"
          },
          "maximum_purchase_quantity": {
            "type": "integer"
          },
          "bulk_discount": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "discount_percentage": {
                  "type": "integer"
                },
                "minimum_purchase_amount": {
                  "type": "integer"
                }
              },
              "required": [
                "discount_percentage",
                "minimum_purchase_amount"
              ]
            }
          },
          "payment_methods": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "other_settings": {
            "type": "object",
            "properties": {
              "quantity_increments": {
                "type": "integer"
              },
              "discord_data_required": {
                "type": "boolean"
              }
            },
            "required": [
              "quantity_increments",
              "discord_data_required"
            ]
          },
          "order": {
            "type": "integer"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "deleted_at": {
            "type": "null"
          },
          "product": {
            "type": "object",
            "properties": {
              "additional_information": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "required": {
                      "type": "boolean"
                    },
                    "key": {
                      "type": "string"
                    },
                    "type": {
                      "type": "string"
                    },
                    "label": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "required",
                    "key",
                    "type",
                    "label"
                  ]
                }
              }
            },
            "required": [
              "additional_information"
            ]
          }
        },
        "required": [
          "id",
          "product_id",
          "title",
          "description",
          "deliverable",
          "pricing",
          "minimum_purchase_quantity",
          "maximum_purchase_quantity",
          "bulk_discount",
          "payment_methods",
          "other_settings",
          "order",
          "created_at",
          "updated_at",
          "deleted_at",
          "product"
        ]
      }
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 2,
      "product_id": 1,
      "title": "Variant Title",
      "description": "Variant Description",
      "deliverable": {
        "data": {
          "removeDuplicate": false,
          "parsingMode": "COMMA",
          "stock": 3,
          "comment": "Thanks for the purchase! I'll send you a contract by email. Make sure to sign it with your blood.",
          "serials": [
            "1",
            "2",
            "3"
          ]
        },
        "types": [
          "TEXT",
          "MANUAL"
        ]
      },
      "pricing": {
        "humble": true,
        "frequency": {
          "value": 1,
          "interval": "MONTH"
        },
        "type": "SINGLE_PAYMENT",
        "price": {
          "price": "1999",
          "currency": "USD"
        }
      },
      "minimum_purchase_quantity": 1,
      "maximum_purchase_quantity": 3,
      "bulk_discount": [
        {
          "discount_percentage": 10,
          "minimum_purchase_amount": 10
        }
      ],
      "payment_methods": [
        "BTC",
        "STRIPE"
      ],
      "other_settings": {
        "quantity_increments": 2,
        "discord_data_required": false
      },
      "order": 1,
      "created_at": "2024-01-10T18:47:22.000000Z",
      "updated_at": "2024-01-10T18:47:22.000000Z",
      "deleted_at": null,
      "product": {
        "additional_information": [
          {
            "required": true,
            "key": "5ebae238c0afae7f4a4b96b30ff6f34c",
            "type": "CHECKBOX",
            "label": "I agree to handing over my soul"
          }
        ]
      }
    }
  ]
}
```

# Create a product variant (/docs/api/product-variants/create-a-product-variant)

This endpoint allows you to create a new product variant. See the code examples for how to create a new product variant with the SellApp API.

## Endpoint

- Method: `POST`

- Path: `/v2/products/{product}/variants`

- Full URL: `https://sell.app/api/v2/products/{product}/variants`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `product` (`integer`, required): The product path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "title": {
      "type": "string"
    },
    "description": {
      "type": "string"
    },
    "deliverable": {
      "type": "object",
      "properties": {
        "types": {
          "type": "array",
          "items": {
            "type": "string",
            "enum": [
              "DOWNLOADABLE",
              "TEXT",
              "DYNAMIC",
              "MANUAL",
              "LICENSE_KEY",
              "BUNDLE"
            ]
          }
        },
        "data": {
          "type": "object",
          "properties": {
            "stock": {
              "type": [
                "integer",
                "null"
              ]
            },
            "serials": {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "removeDuplicate": {
              "type": "boolean"
            },
            "parsingMode": {
              "type": "string",
              "enum": [
                "COMMA",
                "NEW_LINE",
                "SPACE",
                "CUSTOM"
              ]
            },
            "comment": {
              "type": "string"
            },
            "webhook": {
              "type": "string",
              "format": "uri"
            }
          }
        }
      },
      "required": [
        "types",
        "data"
      ]
    },
    "pricing": {
      "type": "object",
      "properties": {
        "humble": {
          "type": "boolean"
        },
        "price": {
          "type": "object",
          "properties": {
            "price": {
              "type": "integer"
            },
            "currency": {
              "type": "string"
            }
          },
          "required": [
            "price",
            "currency"
          ]
        }
      },
      "required": [
        "humble",
        "price"
      ]
    },
    "minimum_purchase_quantity": {
      "type": "integer"
    },
    "maximum_purchase_quantity": {
      "type": [
        "integer",
        "null"
      ]
    },
    "bulk_discount": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "minimum_purchase_amount": {
            "type": "integer"
          },
          "discount_percentage": {
            "type": "integer"
          }
        },
        "required": [
          "minimum_purchase_amount",
          "discount_percentage"
        ]
      }
    },
    "payment_methods": {
      "type": "array",
      "minItems": 1,
      "items": {
        "type": "string",
        "enum": [
          "AUTHNET",
          "BTCPAY",
          "CASHAPP",
          "COINBASE",
          "PADDLE",
          "PAYDASH",
          "PAYPAL",
          "PAYSTACK",
          "SQUARE",
          "STRIPE",
          "VENMO",
          "NMI",
          "LIFI",
          "BTC",
          "LTC",
          "ETH",
          "XMR",
          "SOL",
          "ADA",
          "BNB",
          "TRX",
          "MATIC",
          "ETH_USDT",
          "ETH_USDC",
          "ETH_UNI",
          "ETH_SHIB",
          "ETH_DAI",
          "BNB_USDT",
          "BNB_USDC",
          "TRX_USDT",
          "TRX_USDC",
          "SOL_USDT",
          "SOL_USDC"
        ]
      }
    },
    "other_settings": {
      "type": "object",
      "properties": {
        "quantity_increments": {
          "type": "integer"
        }
      }
    }
  },
  "required": [
    "title",
    "description",
    "deliverable",
    "pricing",
    "payment_methods"
  ]
}
```

### Content Type: `multipart/form-data`

Schema:

```json
{
  "type": "object",
  "properties": {
    "title": {
      "type": "string"
    },
    "description": {
      "type": "string"
    },
    "deliverable": {
      "type": "object",
      "properties": {
        "types": {
          "type": "array",
          "items": {
            "type": "string",
            "enum": [
              "DOWNLOADABLE",
              "TEXT",
              "DYNAMIC",
              "MANUAL",
              "LICENSE_KEY",
              "BUNDLE"
            ]
          }
        },
        "data": {
          "type": "object",
          "properties": {
            "stock": {
              "type": [
                "integer",
                "null"
              ]
            },
            "serials": {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "removeDuplicate": {
              "type": "boolean"
            },
            "parsingMode": {
              "type": "string",
              "enum": [
                "COMMA",
                "NEW_LINE",
                "SPACE",
                "CUSTOM"
              ]
            },
            "comment": {
              "type": "string"
            },
            "webhook": {
              "type": "string",
              "format": "uri"
            },
            "file": {
              "type": "string",
              "format": "binary"
            },
            "files": {
              "type": "array",
              "items": {
                "type": "string",
                "format": "binary"
              }
            }
          }
        }
      },
      "required": [
        "types",
        "data"
      ]
    },
    "pricing": {
      "type": "object",
      "properties": {
        "humble": {
          "type": "boolean"
        },
        "price": {
          "type": "object",
          "properties": {
            "price": {
              "type": "integer"
            },
            "currency": {
              "type": "string"
            }
          },
          "required": [
            "price",
            "currency"
          ]
        }
      },
      "required": [
        "humble",
        "price"
      ]
    },
    "minimum_purchase_quantity": {
      "type": "integer"
    },
    "maximum_purchase_quantity": {
      "type": [
        "integer",
        "null"
      ]
    },
    "bulk_discount": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "minimum_purchase_amount": {
            "type": "integer"
          },
          "discount_percentage": {
            "type": "integer"
          }
        },
        "required": [
          "minimum_purchase_amount",
          "discount_percentage"
        ]
      }
    },
    "payment_methods": {
      "type": "array",
      "minItems": 1,
      "items": {
        "type": "string",
        "enum": [
          "AUTHNET",
          "BTCPAY",
          "CASHAPP",
          "COINBASE",
          "PADDLE",
          "PAYDASH",
          "PAYPAL",
          "PAYSTACK",
          "SQUARE",
          "STRIPE",
          "VENMO",
          "NMI",
          "LIFI",
          "BTC",
          "LTC",
          "ETH",
          "XMR",
          "SOL",
          "ADA",
          "BNB",
          "TRX",
          "MATIC",
          "ETH_USDT",
          "ETH_USDC",
          "ETH_UNI",
          "ETH_SHIB",
          "ETH_DAI",
          "BNB_USDT",
          "BNB_USDC",
          "TRX_USDT",
          "TRX_USDC",
          "SOL_USDT",
          "SOL_USDC"
        ]
      }
    },
    "other_settings": {
      "type": "object",
      "properties": {
        "quantity_increments": {
          "type": "integer"
        }
      }
    }
  },
  "required": [
    "title",
    "description",
    "deliverable",
    "pricing",
    "payment_methods"
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "product_id": {
          "type": "integer"
        },
        "title": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "deliverable": {
          "type": "object",
          "properties": {
            "data": {
              "type": "object",
              "properties": {
                "removeDuplicate": {
                  "type": "boolean"
                },
                "parsingMode": {
                  "type": "string"
                },
                "stock": {
                  "type": "integer"
                },
                "comment": {
                  "type": "string"
                },
                "serials": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                }
              },
              "required": [
                "removeDuplicate",
                "parsingMode",
                "stock",
                "comment",
                "serials"
              ]
            },
            "types": {
              "type": "array",
              "items": {
                "type": "string"
              }
            }
          },
          "required": [
            "data",
            "types"
          ]
        },
        "pricing": {
          "type": "object",
          "properties": {
            "humble": {
              "type": "boolean"
            },
            "frequency": {
              "type": "object",
              "properties": {
                "value": {
                  "type": "integer"
                },
                "interval": {
                  "type": "string"
                }
              },
              "required": [
                "value",
                "interval"
              ]
            },
            "type": {
              "type": "string"
            },
            "price": {
              "type": "object",
              "properties": {
                "price": {
                  "type": "string"
                },
                "currency": {
                  "type": "string"
                }
              },
              "required": [
                "price",
                "currency"
              ]
            }
          },
          "required": [
            "humble",
            "frequency",
            "type",
            "price"
          ]
        },
        "minimum_purchase_quantity": {
          "type": "integer"
        },
        "maximum_purchase_quantity": {
          "type": "integer"
        },
        "bulk_discount": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "discount_percentage": {
                "type": "integer"
              },
              "minimum_purchase_amount": {
                "type": "integer"
              }
            },
            "required": [
              "discount_percentage",
              "minimum_purchase_amount"
            ]
          }
        },
        "payment_methods": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "other_settings": {
          "type": "object",
          "properties": {
            "quantity_increments": {
              "type": "integer"
            },
            "discord_data_required": {
              "type": "boolean"
            }
          },
          "required": [
            "quantity_increments",
            "discord_data_required"
          ]
        },
        "order": {
          "type": "integer"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "deleted_at": {
          "type": "null"
        },
        "product": {
          "type": "object",
          "properties": {
            "additional_information": {
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "required": {
                    "type": "boolean"
                  },
                  "key": {
                    "type": "string"
                  },
                  "type": {
                    "type": "string"
                  },
                  "label": {
                    "type": "string"
                  }
                },
                "required": [
                  "required",
                  "key",
                  "type",
                  "label"
                ]
              }
            }
          },
          "required": [
            "additional_information"
          ]
        }
      },
      "required": [
        "id",
        "product_id",
        "title",
        "description",
        "deliverable",
        "pricing",
        "minimum_purchase_quantity",
        "maximum_purchase_quantity",
        "bulk_discount",
        "payment_methods",
        "other_settings",
        "order",
        "created_at",
        "updated_at",
        "deleted_at",
        "product"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 2,
    "product_id": 1,
    "title": "Variant Title",
    "description": "Variant Description",
    "deliverable": {
      "data": {
        "removeDuplicate": false,
        "parsingMode": "COMMA",
        "stock": 3,
        "comment": "Thanks for the purchase! I will send you a contract by email. Make sure to sign it with your blood.",
        "serials": [
          "1",
          "2",
          "3"
        ]
      },
      "types": [
        "TEXT",
        "MANUAL"
      ]
    },
    "pricing": {
      "humble": true,
      "frequency": {
        "value": 1,
        "interval": "MONTH"
      },
      "type": "SINGLE_PAYMENT",
      "price": {
        "price": "1999",
        "currency": "USD"
      }
    },
    "minimum_purchase_quantity": 1,
    "maximum_purchase_quantity": 3,
    "bulk_discount": [
      {
        "discount_percentage": 10,
        "minimum_purchase_amount": 10
      }
    ],
    "payment_methods": [
      "BTC",
      "STRIPE"
    ],
    "other_settings": {
      "quantity_increments": 2,
      "discord_data_required": false
    },
    "order": 1,
    "created_at": "2024-01-10T18:47:22.000000Z",
    "updated_at": "2024-01-10T18:47:22.000000Z",
    "deleted_at": null,
    "product": {
      "additional_information": [
        {
          "required": true,
          "key": "5ebae238c0afae7f4a4b96b30ff6f34c",
          "type": "CHECKBOX",
          "label": "I agree to handing over my soul"
        }
      ]
    }
  }
}
```

# Delete a product variant (/docs/api/product-variants/delete-a-product-variant)

This endpoint allows you to delete a product variant.

<Warn>
  This will permanently delete the product variant and all of its details, including the sensitive deliverables, will no longer be retrievable.
</Warn>

## Endpoint

- Method: `DELETE`

- Path: `/v2/products/{product}/variants/{variant}`

- Full URL: `https://sell.app/api/v2/products/{product}/variants/{variant}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `product` (`integer`, required): The product path parameter.
- `variant` (`integer`, required): The variant path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "product_id": {
          "type": "integer"
        },
        "title": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "deliverable": {
          "type": "object",
          "properties": {
            "data": {
              "type": "object",
              "properties": {
                "removeDuplicate": {
                  "type": "boolean"
                },
                "parsingMode": {
                  "type": "string"
                },
                "stock": {
                  "type": "integer"
                },
                "comment": {
                  "type": "string"
                },
                "serials": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                }
              },
              "required": [
                "removeDuplicate",
                "parsingMode",
                "stock",
                "comment",
                "serials"
              ]
            },
            "types": {
              "type": "array",
              "items": {
                "type": "string"
              }
            }
          },
          "required": [
            "data",
            "types"
          ]
        },
        "pricing": {
          "type": "object",
          "properties": {
            "humble": {
              "type": "boolean"
            },
            "frequency": {
              "type": "object",
              "properties": {
                "value": {
                  "type": "integer"
                },
                "interval": {
                  "type": "string"
                }
              },
              "required": [
                "value",
                "interval"
              ]
            },
            "type": {
              "type": "string"
            },
            "price": {
              "type": "object",
              "properties": {
                "price": {
                  "type": "string"
                },
                "currency": {
                  "type": "string"
                }
              },
              "required": [
                "price",
                "currency"
              ]
            }
          },
          "required": [
            "humble",
            "frequency",
            "type",
            "price"
          ]
        },
        "minimum_purchase_quantity": {
          "type": "integer"
        },
        "maximum_purchase_quantity": {
          "type": "integer"
        },
        "bulk_discount": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "discount_percentage": {
                "type": "integer"
              },
              "minimum_purchase_amount": {
                "type": "integer"
              }
            },
            "required": [
              "discount_percentage",
              "minimum_purchase_amount"
            ]
          }
        },
        "payment_methods": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "other_settings": {
          "type": "object",
          "properties": {
            "quantity_increments": {
              "type": "integer"
            },
            "discord_data_required": {
              "type": "boolean"
            }
          },
          "required": [
            "quantity_increments",
            "discord_data_required"
          ]
        },
        "order": {
          "type": "integer"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "deleted_at": {
          "type": "null"
        },
        "product": {
          "type": "object",
          "properties": {
            "additional_information": {
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "required": {
                    "type": "boolean"
                  },
                  "key": {
                    "type": "string"
                  },
                  "type": {
                    "type": "string"
                  },
                  "label": {
                    "type": "string"
                  }
                },
                "required": [
                  "required",
                  "key",
                  "type",
                  "label"
                ]
              }
            }
          },
          "required": [
            "additional_information"
          ]
        }
      },
      "required": [
        "id",
        "product_id",
        "title",
        "description",
        "deliverable",
        "pricing",
        "minimum_purchase_quantity",
        "maximum_purchase_quantity",
        "bulk_discount",
        "payment_methods",
        "other_settings",
        "order",
        "created_at",
        "updated_at",
        "deleted_at",
        "product"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 2,
    "product_id": 1,
    "title": "Variant Title",
    "description": "Variant Description",
    "deliverable": {
      "data": {
        "removeDuplicate": false,
        "parsingMode": "COMMA",
        "stock": 3,
        "comment": "Thanks for the purchase! I'll send you a contract by email. Make sure to sign it with your blood.",
        "serials": [
          "1",
          "2",
          "3"
        ]
      },
      "types": [
        "TEXT",
        "MANUAL"
      ]
    },
    "pricing": {
      "humble": true,
      "frequency": {
        "value": 1,
        "interval": "MONTH"
      },
      "type": "SINGLE_PAYMENT",
      "price": {
        "price": "1999",
        "currency": "USD"
      }
    },
    "minimum_purchase_quantity": 1,
    "maximum_purchase_quantity": 3,
    "bulk_discount": [
      {
        "discount_percentage": 10,
        "minimum_purchase_amount": 10
      }
    ],
    "payment_methods": [
      "BTC",
      "STRIPE"
    ],
    "other_settings": {
      "quantity_increments": 2,
      "discord_data_required": false
    },
    "order": 1,
    "created_at": "2024-01-10T18:47:22.000000Z",
    "updated_at": "2024-01-10T18:47:22.000000Z",
    "deleted_at": null,
    "product": {
      "additional_information": [
        {
          "required": true,
          "key": "5ebae238c0afae7f4a4b96b30ff6f34c",
          "type": "CHECKBOX",
          "label": "I agree to handing over my soul"
        }
      ]
    }
  }
}
```

# Overview (/docs/api/product-variants)



Product variants are intertwined with products. It's what contains all data pertaining to deliverables and pricing.

As you might have already noticed, one product is able to have multiple variants which each can have their unique deliverables and pricing.

On this page, we'll dive into the different product variant endpoints you can use to manage products programmatically. We'll look at how to create, update, and delete product variants.

## Endpoints [#endpoints]

* [List all product variants](/api/product-variants/list-all-product-variants)
* [Search product variants](/api/product-variants/search-product-variants)
* [Create a product variant](/api/product-variants/create-a-product-variant)
* [Batch create product variants](/api/product-variants/batch-create-product-variants)
* [Retrieve a product variant](/api/product-variants/retrieve-a-product-variant)
* [Update a product variant](/api/product-variants/update-a-product-variant)
* [Batch update product variants](/api/product-variants/batch-update-product-variants)
* [Delete a product variant](/api/product-variants/delete-a-product-variant)
* [Batch delete product variants](/api/product-variants/batch-delete-product-variants)

## The product variant model [#the-product-variant-model]

The product variant model contains all the information about the product variants located within a product, including the price and deliverables.

### Properties [#properties]

<Properties>
  <Property name="id" type="integer">
    The unique identifier for the product.
  </Property>

  <Property name="product_id" type="integer">
    The unique product identified this variant is linked to.
  </Property>

  <Property name="title" type="string">
    The product variant title.
  </Property>

  <Property name="description" type="string">
    The product variant description.
  </Property>

  <Property name="deliverable" type="array">
    Deliverable details of the product variant, consists of the following:

    * `data` Array of deliverable data to be delivered. Consists of the following:
      * `serials` Only applicable if `deliverable.types` contains `TEXT`. This array should contain all of your serials, separated by the delimiter you set in `parsingMode`.
      * `removeDuplicate` Whether duplicate `TEXT` values should be removed.
      * `parsingMode`  In which way `TEXT` values are separated/parsed.
      * `comment` Only applicable if `deliverable.types` contains `MANUAL`. This string should specify what the next steps are for the manual delivery to be completed.
      * `file` Only applicable if `deliverable.types` contains `DOWNLOADABLE`. If wanting to upload a file, make sure to send the request as a Multipart form instead of JSON.
      * `webhook` Only applicable if `deliverable.types` contains `DYNAMIC`. This string should be your dynamic webhook endpoint, which we ping following a successful purchase.
      * `stock` Specifies how much stock there is for the deliverable. Not required if `deliverable.types` contains `TEXT` as it is calculated automatically. If not present, stock will be set to infinite.
    * `types` Array with values of the deliverable type(s) this product variant contains. Supported values:
      * `DOWNLOADABLE` Downloadable file of any type.
      * `TEXT` Text products delivered one-by-one.
      * `DYNAMIC` Generate a product via your webhook URL.
      * `MANUAL` A product that is manually carried out and/or delivered.
  </Property>

  <Property name="pricing" type="array">
    The product variant pricing array, contains the following values:

    * `humble` Whether the product is of a "Pay what you want" type. If set to `true`, the customer can add an extra amount of their choosing on top of the price.
    * `frequency` array that specifies how often a product should be charged. Consists of two values:
      * `value` that specifies the period duration
      * `interval` that specifies the interval between values. Can be days, weeks, months. Up to 1 year.
    * `type` that contains a string of the charge frequency. One of two values:
      * `SINGLE_PAYMENT` for one-off charges
      * `SUBSCRIPTION` for recurring charges
        * At the moment, only Stripe is supported for subscriptions
    * `price` which contains the product price array. Consists of two values:
      * `price` product price, in cents
      * `currency` Country ISO code of the currency the product is priced in
  </Property>

  <Property name="minimum_purchase_quantity" type="integer">
    The minimum amount of stock a customer is required to purchase.
  </Property>

  <Property name="maximum_purchase_quantity" type="integer">
    The maximum amount of stock a customer is allowed to purchase. If set to null, the customer can purchase an unlimited amount of quantity.
  </Property>

  <Property name="bulk_discount" type="object">
    The bulk discount values of the product. Array consists of:

    * `minimum_purchase_amount` The quantity at which the bulk discount gets triggered.
    * `discount_percentage` The discount value (in percentage) that gets applied to the product price.
  </Property>

  <Property name="payment_methods" type="array">
    This specifies which payment methods are available for the customer to check out with. Your store has to have a payment method activated in order for these to be set.

    * Consists of at least one of the below values:
      * `PAYPAL` PayPal
      * `STRIPE` Stripe
      * `CASHAPP` Cash App
      * `PADDLE` Paddle
      * `AUTHNET` Authorize.net
      * `SQUARE` Square
    * Cryptocurrency payment methods:
      * `BTC` Bitcoin
      * `LTC` Litecoin
      * `ETH` Ethereum
      * `XMR` Monero
      * `BNB` Binance BNB
      * `TRX` Tron
      * `MATIC` Polygon
      * `ETH_USDT` USDT (ETH network)
      * `ETH_USDC` USDC (ETH network)
      * `ETH_UNI` UNI (ETH network)
      * `ETH_SHIB` Shiba (ETH network)
      * `ETH_DAI` DAI (ETH network)
      * `BNB_USDT` USDT (BSC network)
      * `BNB_USDC` USDC (BSC network)
      * `TRX_USDT` USDT (TRX network)
      * `TRX_USDC` USDC (TRX network)
  </Property>

  <Property name="other_settings" type="array">
    Array of additional settings pertaining to the product variant. Consists of:

    * `quantity_increments` that specifies by how much a product can be incremented.
      * The default is 1, which lets a customer purchase a quantity of 1,2,3 and so on
      * When set to e.g. 2, the customer can only purchase a quantity of 1,3,5 and so on. A quantity of 2 would end up not being allowed.
    * `discord_data_required` which specifies whether a customer is required to authorize their Discord account before proceeding with the purchase. If enabled, a customer can not check out before linking their Discord account.
  </Property>

  <Property name="order" type="integer">
    The order of this variant relative to all other variants within the product
  </Property>

  <Property name="created_at" type="timestamp">
    The time at which this product variant was first created.
  </Property>

  <Property name="updated_at" type="timestamp">
    The time at which this product variant was last updated.
  </Property>

  <Property name="deleted_at" type="timestamp">
    The time at which this product variant was deleted.
  </Property>

  <Property name="product" type="array">
    The relevant product details attached to this variant (readonly). Consists of additional information input(s) of the product. Additional information input array consists of:

    * `required` specifying whether the additional information is required
    * `key` unique key of the additional information input
    * `type` One of the following
      * `TEXT`
      * `NUMBER`
      * `HIDDEN`
      * `TEXTAREA`
      * `CHECKBOX`
    * `label` specifying what the customer needs to enter. Examples below
      * `TEXT` What is your in-game username?
      * `NUMBER` To what mobile number do you want this delivered?
      * `HIDDEN&#x60; n.a. &#x2A;(as this is a hidden input not visible to the end-user)*
      * `TEXTAREA` Please specify what your website should look like.
      * `CHECKBOX` Would you like a complimentary drink?
  </Property>
</Properties>

***


# List all product variants (/docs/api/product-variants/list-all-product-variants)

This endpoint allows you to retrieve a paginated list of all your product variants. By default, a maximum of fifteen product variants are shown per page.

## Endpoint

- Method: `GET`

- Path: `/v2/products/{product}/variants`

- Full URL: `https://sell.app/api/v2/products/{product}/variants`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `product` (`integer`, required): The product path parameter.

## Query Parameters
- `limit` (`integer`, optional): Limit the number of blacklist rules returned.
- `page` (`integer`, optional): The page number you are attempting to access.
- `with_drafts` (`boolean`, optional): Include draft variants alongside published variants.
- `only_drafts` (`boolean`, optional): Return only draft variants.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "product_id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "deliverable": {
            "type": "object",
            "properties": {
              "data": {
                "type": "object",
                "properties": {
                  "removeDuplicate": {
                    "type": "boolean"
                  },
                  "parsingMode": {
                    "type": "string"
                  },
                  "stock": {
                    "type": "integer"
                  },
                  "comment": {
                    "type": "string"
                  }
                },
                "required": [
                  "removeDuplicate",
                  "parsingMode",
                  "stock",
                  "comment"
                ]
              },
              "types": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              }
            },
            "required": [
              "data",
              "types"
            ]
          },
          "pricing": {
            "type": "object",
            "properties": {
              "humble": {
                "type": "boolean"
              },
              "frequency": {
                "type": "object",
                "properties": {
                  "value": {
                    "type": "integer"
                  },
                  "interval": {
                    "type": "string"
                  }
                },
                "required": [
                  "value",
                  "interval"
                ]
              },
              "type": {
                "type": "string"
              },
              "price": {
                "type": "object",
                "properties": {
                  "price": {
                    "type": "string"
                  },
                  "currency": {
                    "type": "string"
                  }
                },
                "required": [
                  "price",
                  "currency"
                ]
              }
            },
            "required": [
              "humble",
              "frequency",
              "type",
              "price"
            ]
          },
          "minimum_purchase_quantity": {
            "type": "integer"
          },
          "maximum_purchase_quantity": {
            "type": "null"
          },
          "bulk_discount": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "discount_percentage": {
                  "type": "integer"
                },
                "minimum_purchase_amount": {
                  "type": "integer"
                }
              },
              "required": [
                "discount_percentage",
                "minimum_purchase_amount"
              ]
            }
          },
          "payment_methods": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "other_settings": {
            "type": "object",
            "properties": {
              "quantity_increments": {
                "type": "integer"
              },
              "discord_data_required": {
                "type": "boolean"
              }
            },
            "required": [
              "quantity_increments",
              "discord_data_required"
            ]
          },
          "order": {
            "type": "integer"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "deleted_at": {
            "type": "null"
          },
          "product": {
            "type": "object",
            "properties": {
              "additional_information": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "required": {
                      "type": "boolean"
                    },
                    "key": {
                      "type": "string"
                    },
                    "type": {
                      "type": "string"
                    },
                    "label": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "required",
                    "key",
                    "type",
                    "label"
                  ]
                }
              }
            },
            "required": [
              "additional_information"
            ]
          }
        },
        "required": [
          "id",
          "product_id",
          "title",
          "description",
          "deliverable",
          "pricing",
          "minimum_purchase_quantity",
          "maximum_purchase_quantity",
          "bulk_discount",
          "payment_methods",
          "other_settings",
          "order",
          "created_at",
          "updated_at",
          "deleted_at",
          "product"
        ]
      }
    },
    "links": {
      "type": "object",
      "properties": {}
    },
    "meta": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "data",
    "links",
    "meta"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "product_id": 1,
      "title": "Default",
      "description": "default variant",
      "deliverable": {
        "data": {
          "removeDuplicate": false,
          "parsingMode": "COMMA",
          "stock": 15,
          "comment": "Thanks for the purchase! I'll send you a contract by email. Make sure to sign it with your blood."
        },
        "types": [
          "MANUAL"
        ]
      },
      "pricing": {
        "humble": false,
        "frequency": {
          "value": 1,
          "interval": "MONTH"
        },
        "type": "SINGLE_PAYMENT",
        "price": {
          "price": "1999",
          "currency": "USD"
        }
      },
      "minimum_purchase_quantity": 1,
      "maximum_purchase_quantity": null,
      "bulk_discount": [
        {
          "discount_percentage": 5,
          "minimum_purchase_amount": 2
        },
        {
          "discount_percentage": 10,
          "minimum_purchase_amount": 5
        }
      ],
      "payment_methods": [
        "STRIPE"
      ],
      "other_settings": {
        "quantity_increments": 1,
        "discord_data_required": false
      },
      "order": 1,
      "created_at": "2024-01-09T23:13:16.000000Z",
      "updated_at": "2024-01-10T17:27:01.000000Z",
      "deleted_at": null,
      "product": {
        "additional_information": [
          {
            "required": true,
            "key": "3aecffd000e00e2211e94558007ffc37",
            "type": "CHECKBOX",
            "label": "Do you agree to handing your soul over?"
          }
        ]
      }
    }
  ],
  "links": {},
  "meta": {}
}
```

# Retrieve a product variant (/docs/api/product-variants/retrieve-a-product-variant)

This endpoint allows you to retrieve a specific product variant by providing the unique identifiers of both the product and variant. Refer to [the list](/api/product-variants#the-product-variant-model) to see which properties are included with product variant objects.

## Endpoint

- Method: `GET`

- Path: `/v2/products/{product}/variants/{variant}`

- Full URL: `https://sell.app/api/v2/products/{product}/variants/{variant}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `product` (`integer`, required): The product path parameter.
- `variant` (`integer`, required): The variant path parameter.

## Query Parameters
- `with_drafts` (`boolean`, optional): Include draft variants alongside published variants.
- `only_drafts` (`boolean`, optional): Return only draft variants.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "product_id": {
          "type": "integer"
        },
        "title": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "deliverable": {
          "type": "object",
          "properties": {
            "data": {
              "type": "object",
              "properties": {
                "removeDuplicate": {
                  "type": "boolean"
                },
                "parsingMode": {
                  "type": "string"
                },
                "stock": {
                  "type": "integer"
                },
                "comment": {
                  "type": "string"
                },
                "serials": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                }
              },
              "required": [
                "removeDuplicate",
                "parsingMode",
                "stock",
                "comment",
                "serials"
              ]
            },
            "types": {
              "type": "array",
              "items": {
                "type": "string"
              }
            }
          },
          "required": [
            "data",
            "types"
          ]
        },
        "pricing": {
          "type": "object",
          "properties": {
            "humble": {
              "type": "boolean"
            },
            "frequency": {
              "type": "object",
              "properties": {
                "value": {
                  "type": "integer"
                },
                "interval": {
                  "type": "string"
                }
              },
              "required": [
                "value",
                "interval"
              ]
            },
            "type": {
              "type": "string"
            },
            "price": {
              "type": "object",
              "properties": {
                "price": {
                  "type": "string"
                },
                "currency": {
                  "type": "string"
                }
              },
              "required": [
                "price",
                "currency"
              ]
            }
          },
          "required": [
            "humble",
            "frequency",
            "type",
            "price"
          ]
        },
        "minimum_purchase_quantity": {
          "type": "integer"
        },
        "maximum_purchase_quantity": {
          "type": "integer"
        },
        "bulk_discount": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "discount_percentage": {
                "type": "integer"
              },
              "minimum_purchase_amount": {
                "type": "integer"
              }
            },
            "required": [
              "discount_percentage",
              "minimum_purchase_amount"
            ]
          }
        },
        "payment_methods": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "other_settings": {
          "type": "object",
          "properties": {
            "quantity_increments": {
              "type": "integer"
            },
            "discord_data_required": {
              "type": "boolean"
            }
          },
          "required": [
            "quantity_increments",
            "discord_data_required"
          ]
        },
        "order": {
          "type": "integer"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "deleted_at": {
          "type": "null"
        },
        "product": {
          "type": "object",
          "properties": {
            "additional_information": {
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "required": {
                    "type": "boolean"
                  },
                  "key": {
                    "type": "string"
                  },
                  "type": {
                    "type": "string"
                  },
                  "label": {
                    "type": "string"
                  }
                },
                "required": [
                  "required",
                  "key",
                  "type",
                  "label"
                ]
              }
            }
          },
          "required": [
            "additional_information"
          ]
        }
      },
      "required": [
        "id",
        "product_id",
        "title",
        "description",
        "deliverable",
        "pricing",
        "minimum_purchase_quantity",
        "maximum_purchase_quantity",
        "bulk_discount",
        "payment_methods",
        "other_settings",
        "order",
        "created_at",
        "updated_at",
        "deleted_at",
        "product"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 2,
    "product_id": 1,
    "title": "Variant Title",
    "description": "Variant Description",
    "deliverable": {
      "data": {
        "removeDuplicate": false,
        "parsingMode": "COMMA",
        "stock": 3,
        "comment": "Thanks for the purchase! I'll send you a contract by email. Make sure to sign it with your blood.",
        "serials": [
          "1",
          "2",
          "3"
        ]
      },
      "types": [
        "TEXT",
        "MANUAL"
      ]
    },
    "pricing": {
      "humble": true,
      "frequency": {
        "value": 1,
        "interval": "MONTH"
      },
      "type": "SINGLE_PAYMENT",
      "price": {
        "price": "1999",
        "currency": "USD"
      }
    },
    "minimum_purchase_quantity": 1,
    "maximum_purchase_quantity": 3,
    "bulk_discount": [
      {
        "discount_percentage": 10,
        "minimum_purchase_amount": 10
      }
    ],
    "payment_methods": [
      "BTC",
      "STRIPE"
    ],
    "other_settings": {
      "quantity_increments": 2,
      "discord_data_required": false
    },
    "order": 1,
    "created_at": "2024-01-10T18:47:22.000000Z",
    "updated_at": "2024-01-10T18:47:22.000000Z",
    "deleted_at": null,
    "product": {
      "additional_information": [
        {
          "required": true,
          "key": "5ebae238c0afae7f4a4b96b30ff6f34c",
          "type": "CHECKBOX",
          "label": "I agree to handing over my soul"
        }
      ]
    }
  }
}
```

# Search product variants (/docs/api/product-variants/search-product-variants)

Search a product's variants with filters, search terms, includes, and sort instructions in a JSON request body.

## Endpoint

- Method: `POST`

- Path: `/v2/products/{product}/variants/search`

- Full URL: `https://sell.app/api/v2/products/{product}/variants/search`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `product` (`integer`, required): The product path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "filters": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "field": {
            "type": "string"
          },
          "operator": {
            "type": "string",
            "default": "="
          },
          "value": {},
          "type": {
            "type": "string",
            "enum": [
              "and",
              "or"
            ],
            "default": "and"
          },
          "nested": {
            "type": "array",
            "items": {
              "type": "object",
              "additionalProperties": true
            }
          }
        },
        "required": [
          "field"
        ]
      }
    },
    "sort": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "field": {
            "type": "string"
          },
          "direction": {
            "type": "string",
            "enum": [
              "asc",
              "desc"
            ],
            "default": "asc"
          }
        },
        "required": [
          "field"
        ]
      }
    },
    "search": {
      "type": "object",
      "properties": {
        "value": {
          "type": [
            "string",
            "null"
          ]
        },
        "case_sensitive": {
          "type": "boolean"
        }
      }
    },
    "includes": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "relation": {
            "type": "string"
          }
        },
        "required": [
          "relation"
        ]
      }
    }
  }
}
```

Example:

```json
{
  "filters": [
    {
      "field": "id",
      "operator": "=",
      "value": 1
    }
  ],
  "sort": [
    {
      "field": "created_at",
      "direction": "desc"
    }
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "product_id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "deliverable": {
            "type": "object",
            "properties": {
              "data": {
                "type": "object",
                "properties": {
                  "removeDuplicate": {
                    "type": "boolean"
                  },
                  "parsingMode": {
                    "type": "string"
                  },
                  "stock": {
                    "type": "integer"
                  },
                  "comment": {
                    "type": "string"
                  }
                },
                "required": [
                  "removeDuplicate",
                  "parsingMode",
                  "stock",
                  "comment"
                ]
              },
              "types": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              }
            },
            "required": [
              "data",
              "types"
            ]
          },
          "pricing": {
            "type": "object",
            "properties": {
              "humble": {
                "type": "boolean"
              },
              "frequency": {
                "type": "object",
                "properties": {
                  "value": {
                    "type": "integer"
                  },
                  "interval": {
                    "type": "string"
                  }
                },
                "required": [
                  "value",
                  "interval"
                ]
              },
              "type": {
                "type": "string"
              },
              "price": {
                "type": "object",
                "properties": {
                  "price": {
                    "type": "string"
                  },
                  "currency": {
                    "type": "string"
                  }
                },
                "required": [
                  "price",
                  "currency"
                ]
              }
            },
            "required": [
              "humble",
              "frequency",
              "type",
              "price"
            ]
          },
          "minimum_purchase_quantity": {
            "type": "integer"
          },
          "maximum_purchase_quantity": {
            "type": "null"
          },
          "bulk_discount": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "discount_percentage": {
                  "type": "integer"
                },
                "minimum_purchase_amount": {
                  "type": "integer"
                }
              },
              "required": [
                "discount_percentage",
                "minimum_purchase_amount"
              ]
            }
          },
          "payment_methods": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "other_settings": {
            "type": "object",
            "properties": {
              "quantity_increments": {
                "type": "integer"
              },
              "discord_data_required": {
                "type": "boolean"
              }
            },
            "required": [
              "quantity_increments",
              "discord_data_required"
            ]
          },
          "order": {
            "type": "integer"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "deleted_at": {
            "type": "null"
          },
          "product": {
            "type": "object",
            "properties": {
              "additional_information": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "required": {
                      "type": "boolean"
                    },
                    "key": {
                      "type": "string"
                    },
                    "type": {
                      "type": "string"
                    },
                    "label": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "required",
                    "key",
                    "type",
                    "label"
                  ]
                }
              }
            },
            "required": [
              "additional_information"
            ]
          }
        },
        "required": [
          "id",
          "product_id",
          "title",
          "description",
          "deliverable",
          "pricing",
          "minimum_purchase_quantity",
          "maximum_purchase_quantity",
          "bulk_discount",
          "payment_methods",
          "other_settings",
          "order",
          "created_at",
          "updated_at",
          "deleted_at",
          "product"
        ]
      }
    },
    "links": {
      "type": "object",
      "properties": {}
    },
    "meta": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "data",
    "links",
    "meta"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "product_id": 1,
      "title": "Default",
      "description": "default variant",
      "deliverable": {
        "data": {
          "removeDuplicate": false,
          "parsingMode": "COMMA",
          "stock": 15,
          "comment": "Thanks for the purchase! I'll send you a contract by email. Make sure to sign it with your blood."
        },
        "types": [
          "MANUAL"
        ]
      },
      "pricing": {
        "humble": false,
        "frequency": {
          "value": 1,
          "interval": "MONTH"
        },
        "type": "SINGLE_PAYMENT",
        "price": {
          "price": "1999",
          "currency": "USD"
        }
      },
      "minimum_purchase_quantity": 1,
      "maximum_purchase_quantity": null,
      "bulk_discount": [
        {
          "discount_percentage": 5,
          "minimum_purchase_amount": 2
        },
        {
          "discount_percentage": 10,
          "minimum_purchase_amount": 5
        }
      ],
      "payment_methods": [
        "STRIPE"
      ],
      "other_settings": {
        "quantity_increments": 1,
        "discord_data_required": false
      },
      "order": 1,
      "created_at": "2024-01-09T23:13:16.000000Z",
      "updated_at": "2024-01-10T17:27:01.000000Z",
      "deleted_at": null,
      "product": {
        "additional_information": [
          {
            "required": true,
            "key": "3aecffd000e00e2211e94558007ffc37",
            "type": "CHECKBOX",
            "label": "Do you agree to handing your soul over?"
          }
        ]
      }
    }
  ],
  "links": {},
  "meta": {}
}
```

# Update a product variant (/docs/api/product-variants/update-a-product-variant)

This endpoint allows you to update a product variant's details.

## Endpoint

- Method: `PATCH`

- Path: `/v2/products/{product}/variants/{variant}`

- Full URL: `https://sell.app/api/v2/products/{product}/variants/{variant}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `product` (`integer`, required): The product path parameter.
- `variant` (`integer`, required): The variant path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "title": {
      "type": "string"
    },
    "description": {
      "type": "string"
    },
    "deliverable": {
      "type": "object",
      "properties": {
        "types": {
          "type": "array",
          "items": {
            "type": "string",
            "enum": [
              "DOWNLOADABLE",
              "TEXT",
              "DYNAMIC",
              "MANUAL",
              "LICENSE_KEY",
              "BUNDLE"
            ]
          }
        },
        "data": {
          "type": "object",
          "properties": {
            "stock": {
              "type": [
                "integer",
                "null"
              ]
            },
            "serials": {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "removeDuplicate": {
              "type": "boolean"
            },
            "parsingMode": {
              "type": "string",
              "enum": [
                "COMMA",
                "NEW_LINE",
                "SPACE",
                "CUSTOM"
              ]
            },
            "comment": {
              "type": "string"
            },
            "webhook": {
              "type": "string",
              "format": "uri"
            }
          }
        }
      },
      "required": [
        "types",
        "data"
      ]
    },
    "pricing": {
      "type": "object",
      "properties": {
        "humble": {
          "type": "boolean"
        },
        "price": {
          "type": "object",
          "properties": {
            "price": {
              "type": "integer"
            },
            "currency": {
              "type": "string"
            }
          },
          "required": [
            "price",
            "currency"
          ]
        }
      },
      "required": [
        "humble",
        "price"
      ]
    },
    "minimum_purchase_quantity": {
      "type": "integer"
    },
    "maximum_purchase_quantity": {
      "type": [
        "integer",
        "null"
      ]
    },
    "bulk_discount": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "minimum_purchase_amount": {
            "type": "integer"
          },
          "discount_percentage": {
            "type": "integer"
          }
        },
        "required": [
          "minimum_purchase_amount",
          "discount_percentage"
        ]
      }
    },
    "payment_methods": {
      "type": "array",
      "minItems": 1,
      "items": {
        "type": "string",
        "enum": [
          "AUTHNET",
          "BTCPAY",
          "CASHAPP",
          "COINBASE",
          "PADDLE",
          "PAYDASH",
          "PAYPAL",
          "PAYSTACK",
          "SQUARE",
          "STRIPE",
          "VENMO",
          "NMI",
          "LIFI",
          "BTC",
          "LTC",
          "ETH",
          "XMR",
          "SOL",
          "ADA",
          "BNB",
          "TRX",
          "MATIC",
          "ETH_USDT",
          "ETH_USDC",
          "ETH_UNI",
          "ETH_SHIB",
          "ETH_DAI",
          "BNB_USDT",
          "BNB_USDC",
          "TRX_USDT",
          "TRX_USDC",
          "SOL_USDT",
          "SOL_USDC"
        ]
      }
    },
    "other_settings": {
      "type": "object",
      "properties": {
        "quantity_increments": {
          "type": "integer"
        }
      }
    }
  }
}
```

### Content Type: `multipart/form-data`

Schema:

```json
{
  "type": "object",
  "properties": {
    "title": {
      "type": "string"
    },
    "description": {
      "type": "string"
    },
    "deliverable": {
      "type": "object",
      "properties": {
        "types": {
          "type": "array",
          "items": {
            "type": "string",
            "enum": [
              "DOWNLOADABLE",
              "TEXT",
              "DYNAMIC",
              "MANUAL",
              "LICENSE_KEY",
              "BUNDLE"
            ]
          }
        },
        "data": {
          "type": "object",
          "properties": {
            "stock": {
              "type": [
                "integer",
                "null"
              ]
            },
            "serials": {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "removeDuplicate": {
              "type": "boolean"
            },
            "parsingMode": {
              "type": "string",
              "enum": [
                "COMMA",
                "NEW_LINE",
                "SPACE",
                "CUSTOM"
              ]
            },
            "comment": {
              "type": "string"
            },
            "webhook": {
              "type": "string",
              "format": "uri"
            },
            "file": {
              "type": "string",
              "format": "binary"
            },
            "files": {
              "type": "array",
              "items": {
                "type": "string",
                "format": "binary"
              }
            }
          }
        }
      },
      "required": [
        "types",
        "data"
      ]
    },
    "pricing": {
      "type": "object",
      "properties": {
        "humble": {
          "type": "boolean"
        },
        "price": {
          "type": "object",
          "properties": {
            "price": {
              "type": "integer"
            },
            "currency": {
              "type": "string"
            }
          },
          "required": [
            "price",
            "currency"
          ]
        }
      },
      "required": [
        "humble",
        "price"
      ]
    },
    "minimum_purchase_quantity": {
      "type": "integer"
    },
    "maximum_purchase_quantity": {
      "type": [
        "integer",
        "null"
      ]
    },
    "bulk_discount": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "minimum_purchase_amount": {
            "type": "integer"
          },
          "discount_percentage": {
            "type": "integer"
          }
        },
        "required": [
          "minimum_purchase_amount",
          "discount_percentage"
        ]
      }
    },
    "payment_methods": {
      "type": "array",
      "minItems": 1,
      "items": {
        "type": "string",
        "enum": [
          "AUTHNET",
          "BTCPAY",
          "CASHAPP",
          "COINBASE",
          "PADDLE",
          "PAYDASH",
          "PAYPAL",
          "PAYSTACK",
          "SQUARE",
          "STRIPE",
          "VENMO",
          "NMI",
          "LIFI",
          "BTC",
          "LTC",
          "ETH",
          "XMR",
          "SOL",
          "ADA",
          "BNB",
          "TRX",
          "MATIC",
          "ETH_USDT",
          "ETH_USDC",
          "ETH_UNI",
          "ETH_SHIB",
          "ETH_DAI",
          "BNB_USDT",
          "BNB_USDC",
          "TRX_USDT",
          "TRX_USDC",
          "SOL_USDT",
          "SOL_USDC"
        ]
      }
    },
    "other_settings": {
      "type": "object",
      "properties": {
        "quantity_increments": {
          "type": "integer"
        }
      }
    }
  }
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "product_id": {
          "type": "integer"
        },
        "title": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "deliverable": {
          "type": "object",
          "properties": {
            "data": {
              "type": "object",
              "properties": {
                "removeDuplicate": {
                  "type": "boolean"
                },
                "parsingMode": {
                  "type": "string"
                },
                "stock": {
                  "type": "integer"
                },
                "comment": {
                  "type": "string"
                },
                "serials": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                }
              },
              "required": [
                "removeDuplicate",
                "parsingMode",
                "stock",
                "comment",
                "serials"
              ]
            },
            "types": {
              "type": "array",
              "items": {
                "type": "string"
              }
            }
          },
          "required": [
            "data",
            "types"
          ]
        },
        "pricing": {
          "type": "object",
          "properties": {
            "humble": {
              "type": "boolean"
            },
            "frequency": {
              "type": "object",
              "properties": {
                "value": {
                  "type": "integer"
                },
                "interval": {
                  "type": "string"
                }
              },
              "required": [
                "value",
                "interval"
              ]
            },
            "type": {
              "type": "string"
            },
            "price": {
              "type": "object",
              "properties": {
                "price": {
                  "type": "string"
                },
                "currency": {
                  "type": "string"
                }
              },
              "required": [
                "price",
                "currency"
              ]
            }
          },
          "required": [
            "humble",
            "frequency",
            "type",
            "price"
          ]
        },
        "minimum_purchase_quantity": {
          "type": "integer"
        },
        "maximum_purchase_quantity": {
          "type": "integer"
        },
        "bulk_discount": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "discount_percentage": {
                "type": "integer"
              },
              "minimum_purchase_amount": {
                "type": "integer"
              }
            },
            "required": [
              "discount_percentage",
              "minimum_purchase_amount"
            ]
          }
        },
        "payment_methods": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "other_settings": {
          "type": "object",
          "properties": {
            "quantity_increments": {
              "type": "integer"
            },
            "discord_data_required": {
              "type": "boolean"
            }
          },
          "required": [
            "quantity_increments",
            "discord_data_required"
          ]
        },
        "order": {
          "type": "integer"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "deleted_at": {
          "type": "null"
        },
        "product": {
          "type": "object",
          "properties": {
            "additional_information": {
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "required": {
                    "type": "boolean"
                  },
                  "key": {
                    "type": "string"
                  },
                  "type": {
                    "type": "string"
                  },
                  "label": {
                    "type": "string"
                  }
                },
                "required": [
                  "required",
                  "key",
                  "type",
                  "label"
                ]
              }
            }
          },
          "required": [
            "additional_information"
          ]
        }
      },
      "required": [
        "id",
        "product_id",
        "title",
        "description",
        "deliverable",
        "pricing",
        "minimum_purchase_quantity",
        "maximum_purchase_quantity",
        "bulk_discount",
        "payment_methods",
        "other_settings",
        "order",
        "created_at",
        "updated_at",
        "deleted_at",
        "product"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 2,
    "product_id": 1,
    "title": "Updated Title",
    "description": "Variant Description",
    "deliverable": {
      "data": {
        "removeDuplicate": false,
        "parsingMode": "COMMA",
        "stock": 3,
        "comment": "Thanks for the purchase! I'll send you a contract by email. Make sure to sign it with your blood.",
        "serials": [
          "1",
          "2",
          "3"
        ]
      },
      "types": [
        "TEXT",
        "MANUAL"
      ]
    },
    "pricing": {
      "humble": true,
      "frequency": {
        "value": 1,
        "interval": "MONTH"
      },
      "type": "SINGLE_PAYMENT",
      "price": {
        "price": "1999",
        "currency": "USD"
      }
    },
    "minimum_purchase_quantity": 1,
    "maximum_purchase_quantity": 3,
    "bulk_discount": [
      {
        "discount_percentage": 10,
        "minimum_purchase_amount": 10
      }
    ],
    "payment_methods": [
      "BTC",
      "STRIPE"
    ],
    "other_settings": {
      "quantity_increments": 2,
      "discord_data_required": false
    },
    "order": 1,
    "created_at": "2024-01-10T18:47:22.000000Z",
    "updated_at": "2024-01-10T18:47:22.000000Z",
    "deleted_at": null,
    "product": {
      "additional_information": [
        {
          "required": true,
          "key": "5ebae238c0afae7f4a4b96b30ff6f34c",
          "type": "CHECKBOX",
          "label": "I agree to handing over my soul"
        }
      ]
    }
  }
}
```

# Batch create sections (/docs/api/sections/batch-create-sections)

Create multiple sections in one request by sending a `resources` array.

## Endpoint

- Method: `POST`

- Path: `/v1/sections/batch`

- Full URL: `https://sell.app/api/v1/sections/batch`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "resources": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "title": {
            "type": "string"
          },
          "hidden": {
            "type": "boolean"
          }
        },
        "required": [
          "title",
          "hidden"
        ]
      }
    }
  },
  "required": [
    "resources"
  ]
}
```

Example:

```json
{
  "resources": [
    {
      "title": "Featured",
      "hidden": false
    }
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "hidden": {
            "type": "boolean"
          },
          "order": {
            "type": "integer"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "store_id": {
            "type": "integer"
          },
          "groups_linked": {
            "type": "integer"
          },
          "products_linked": {
            "type": "integer"
          },
          "groups": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "integer"
                },
                "title": {
                  "type": "string"
                },
                "group_products": {
                  "type": "integer"
                }
              },
              "required": [
                "id",
                "title",
                "group_products"
              ]
            }
          },
          "products": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "title": {
                  "type": "string"
                },
                "description": {
                  "type": "string"
                }
              },
              "required": [
                "id",
                "title",
                "description"
              ]
            }
          }
        },
        "required": [
          "id",
          "title",
          "slug",
          "hidden",
          "order",
          "created_at",
          "updated_at",
          "store_id",
          "groups_linked",
          "products_linked",
          "groups",
          "products"
        ]
      }
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "title": "Dissection",
      "slug": "dissection",
      "hidden": false,
      "order": 1,
      "created_at": "2022-12-12T12:12:12.000000Z",
      "updated_at": "2022-12-12T12:12:12.000000Z",
      "store_id": 1,
      "groups_linked": 1,
      "products_linked": 1,
      "groups": [
        {
          "id": 1,
          "title": "Rat race",
          "group_products": 1
        }
      ],
      "products": [
        {
          "id": "1",
          "title": "This will make me rich!",
          "description": "I am sure of it, Pinky."
        }
      ]
    }
  ]
}
```

# Batch delete sections (/docs/api/sections/batch-delete-sections)

Delete multiple sections in one request by sending the section IDs in `resources`.

## Endpoint

- Method: `DELETE`

- Path: `/v1/sections/batch`

- Full URL: `https://sell.app/api/v1/sections/batch`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "resources": {
      "type": "array",
      "items": {
        "type": "integer"
      }
    }
  },
  "required": [
    "resources"
  ]
}
```

Example:

```json
{
  "resources": [
    1,
    2
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "hidden": {
            "type": "boolean"
          },
          "order": {
            "type": "integer"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "store_id": {
            "type": "integer"
          },
          "groups_linked": {
            "type": "integer"
          },
          "products_linked": {
            "type": "integer"
          },
          "groups": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "integer"
                },
                "title": {
                  "type": "string"
                },
                "group_products": {
                  "type": "integer"
                }
              },
              "required": [
                "id",
                "title",
                "group_products"
              ]
            }
          },
          "products": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "title": {
                  "type": "string"
                },
                "description": {
                  "type": "string"
                }
              },
              "required": [
                "id",
                "title",
                "description"
              ]
            }
          }
        },
        "required": [
          "id",
          "title",
          "slug",
          "hidden",
          "order",
          "created_at",
          "updated_at",
          "store_id",
          "groups_linked",
          "products_linked",
          "groups",
          "products"
        ]
      }
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "title": "Dissection",
      "slug": "dissection",
      "hidden": false,
      "order": 1,
      "created_at": "2022-12-12T12:12:12.000000Z",
      "updated_at": "2022-12-12T12:12:12.000000Z",
      "store_id": 1,
      "groups_linked": 1,
      "products_linked": 1,
      "groups": [
        {
          "id": 1,
          "title": "Rat race",
          "group_products": 1
        }
      ],
      "products": [
        {
          "id": "1",
          "title": "This will make me rich!",
          "description": "I am sure of it, Pinky."
        }
      ]
    }
  ]
}
```

# Batch update sections (/docs/api/sections/batch-update-sections)

Update multiple sections in one request by sending a `resources` object keyed by section ID.

## Endpoint

- Method: `PATCH`

- Path: `/v1/sections/batch`

- Full URL: `https://sell.app/api/v1/sections/batch`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "resources": {
      "type": "object",
      "additionalProperties": {
        "type": "object",
        "properties": {
          "title": {
            "type": "string"
          },
          "hidden": {
            "type": "boolean"
          }
        }
      }
    }
  },
  "required": [
    "resources"
  ]
}
```

Example:

```json
{
  "resources": {
    "1": {
      "title": "Featured",
      "hidden": false
    }
  }
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "hidden": {
            "type": "boolean"
          },
          "order": {
            "type": "integer"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "store_id": {
            "type": "integer"
          },
          "groups_linked": {
            "type": "integer"
          },
          "products_linked": {
            "type": "integer"
          },
          "groups": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "integer"
                },
                "title": {
                  "type": "string"
                },
                "group_products": {
                  "type": "integer"
                }
              },
              "required": [
                "id",
                "title",
                "group_products"
              ]
            }
          },
          "products": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "title": {
                  "type": "string"
                },
                "description": {
                  "type": "string"
                }
              },
              "required": [
                "id",
                "title",
                "description"
              ]
            }
          }
        },
        "required": [
          "id",
          "title",
          "slug",
          "hidden",
          "order",
          "created_at",
          "updated_at",
          "store_id",
          "groups_linked",
          "products_linked",
          "groups",
          "products"
        ]
      }
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "title": "Dissection",
      "slug": "dissection",
      "hidden": false,
      "order": 1,
      "created_at": "2022-12-12T12:12:12.000000Z",
      "updated_at": "2022-12-12T12:12:12.000000Z",
      "store_id": 1,
      "groups_linked": 1,
      "products_linked": 1,
      "groups": [
        {
          "id": 1,
          "title": "Rat race",
          "group_products": 1
        }
      ],
      "products": [
        {
          "id": "1",
          "title": "This will make me rich!",
          "description": "I am sure of it, Pinky."
        }
      ]
    }
  ]
}
```

# Create a section (/docs/api/sections/create-a-section)

This endpoint allows you to create a new section. See the code examples for how to create a new section with the SellApp API.

## Endpoint

- Method: `POST`

- Path: `/v1/sections`

- Full URL: `https://sell.app/api/v1/sections`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "title": {
      "type": "string"
    },
    "hidden": {
      "type": "boolean"
    }
  },
  "required": [
    "title",
    "hidden"
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "title": {
          "type": "string"
        },
        "slug": {
          "type": "string"
        },
        "hidden": {
          "type": "boolean"
        },
        "order": {
          "type": "integer"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "store_id": {
          "type": "integer"
        },
        "groups_linked": {
          "type": "integer"
        },
        "products_linked": {
          "type": "integer"
        },
        "groups": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "products": {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      },
      "required": [
        "id",
        "title",
        "slug",
        "hidden",
        "order",
        "created_at",
        "updated_at",
        "store_id",
        "groups_linked",
        "products_linked",
        "groups",
        "products"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 2,
    "title": "Developer Goodies",
    "slug": "developer-goodies",
    "hidden": false,
    "order": 1,
    "created_at": "2022-12-12T12:12:12.000000Z",
    "updated_at": "2022-12-12T12:12:12.000000Z",
    "store_id": 1,
    "groups_linked": 0,
    "products_linked": 0,
    "groups": [],
    "products": []
  }
}
```

# Delete a section (/docs/api/sections/delete-a-section)

This endpoint allows you to delete a section.

<Warn>
  This will permanently delete the section and its details.
</Warn>

## Endpoint

- Method: `DELETE`

- Path: `/v1/sections/{section}`

- Full URL: `https://sell.app/api/v1/sections/{section}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `section` (`integer`, required): The section path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "title": {
          "type": "string"
        },
        "slug": {
          "type": "string"
        },
        "hidden": {
          "type": "boolean"
        },
        "order": {
          "type": "integer"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "store_id": {
          "type": "integer"
        },
        "groups_linked": {
          "type": "integer"
        },
        "products_linked": {
          "type": "integer"
        },
        "groups": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "id": {
                "type": "integer"
              },
              "title": {
                "type": "string"
              },
              "group_products": {
                "type": "integer"
              }
            },
            "required": [
              "id",
              "title",
              "group_products"
            ]
          }
        },
        "products": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "title": {
                "type": "string"
              },
              "description": {
                "type": "string"
              }
            },
            "required": [
              "id",
              "title",
              "description"
            ]
          }
        }
      },
      "required": [
        "id",
        "title",
        "slug",
        "hidden",
        "order",
        "created_at",
        "updated_at",
        "store_id",
        "groups_linked",
        "products_linked",
        "groups",
        "products"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "title": "Dissection",
    "slug": "dissection",
    "hidden": false,
    "order": 1,
    "created_at": "2022-12-12T12:12:12.000000Z",
    "updated_at": "2022-12-12T12:12:12.000000Z",
    "store_id": 1,
    "groups_linked": 1,
    "products_linked": 1,
    "groups": [
      {
        "id": 1,
        "title": "Rat race",
        "group_products": 1
      }
    ],
    "products": [
      {
        "id": "1",
        "title": "This will make me rich!",
        "description": "I am sure of it, Pinky."
      }
    ]
  }
}
```

# Overview (/docs/api/sections)



Sections are another way to make your SellApp storefront more navigable — they allow you to subdivide your storefront into overviewable parts/sections to streamline the customer browsing experience.

On this page, we'll dive into the different section endpoints you can use to manage sections programmatically. We'll look at how to create, update, and delete sections.

## Endpoints [#endpoints]

* [List all sections](/api/sections/list-all-sections)
* [Search sections](/api/sections/search-sections)
* [Create a section](/api/sections/create-a-section)
* [Batch create sections](/api/sections/batch-create-sections)
* [Retrieve a section](/api/sections/retrieve-a-section)
* [Update a section](/api/sections/update-a-section)
* [Batch update sections](/api/sections/batch-update-sections)
* [Batch delete sections](/api/sections/batch-delete-sections)
* [Delete a section](/api/sections/delete-a-section)

## The section model [#the-section-model]

The section model contains all the information about the sections stores have, including the type, code, and discount amount.

### Properties [#properties]

<Properties>
  <Property name="id" type="integer">
    The unique identifier for the section.
  </Property>

  <Property name="title" type="string">
    The section title.
  </Property>

  <Property name="slug" type="string">
    The section slug.
  </Property>

  <Property name="hidden" type="boolean">
    The section visibility. One of two values:

    * `false`: Section is not hidden and can be seen publicly.
    * `true`: Section is hidden and can only be seen via direct link.
  </Property>

  <Property name="order" type="integer">
    The order of the section.
  </Property>

  <Property name="created_at" type="timestamp">
    The time at which this section was first created.
  </Property>

  <Property name="updated_at" type="timestamp">
    The time at which this section was last updated.
  </Property>

  <Property name="store_id" type="integer">
    The ID of the store this section belongs to.
  </Property>

  <Property name="groups_linked" type="integer">
    The amount of groups linked to the section.
  </Property>

  <Property name="products_linked" type="integer">
    The amount of products linked to the section.
  </Property>

  <Property name="groups" type="array">
    An array of groups linked to the section, containing three types of info:

    * `id`: The group ID.
    * `title`: The group title.
    * `group_product`: The amount of products linked to the group.
  </Property>

  <Property name="products" type="array">
    An array of products linked to the section, containing three types of info:

    * `id`: The product ID.
    * `title`: The product title.
    * `description`: The product description.
  </Property>
</Properties>

***


# List all sections (/docs/api/sections/list-all-sections)

This endpoint allows you to retrieve a paginated list of all your sections. By default, a maximum of fifteen sections are shown per page.

## Endpoint

- Method: `GET`

- Path: `/v1/sections`

- Full URL: `https://sell.app/api/v1/sections`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
- `limit` (`integer`, optional): Limit the number of blacklist rules returned.
- `page` (`integer`, optional): The page number you are attempting to access.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "hidden": {
            "type": "boolean"
          },
          "order": {
            "type": "integer"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "store_id": {
            "type": "integer"
          },
          "groups_linked": {
            "type": "integer"
          },
          "products_linked": {
            "type": "integer"
          },
          "groups": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "integer"
                },
                "title": {
                  "type": "string"
                },
                "group_products": {
                  "type": "integer"
                }
              },
              "required": [
                "id",
                "title",
                "group_products"
              ]
            }
          },
          "products": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "title": {
                  "type": "string"
                },
                "description": {
                  "type": "string"
                }
              },
              "required": [
                "id",
                "title",
                "description"
              ]
            }
          }
        },
        "required": [
          "id",
          "title",
          "slug",
          "hidden",
          "order",
          "created_at",
          "updated_at",
          "store_id",
          "groups_linked",
          "products_linked",
          "groups",
          "products"
        ]
      }
    },
    "links": {
      "type": "object",
      "properties": {}
    },
    "meta": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "data",
    "links",
    "meta"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "title": "Dissection",
      "slug": "dissection",
      "hidden": false,
      "order": 1,
      "created_at": "2022-12-12T12:12:12.000000Z",
      "updated_at": "2022-12-12T12:12:12.000000Z",
      "store_id": 1,
      "groups_linked": 1,
      "products_linked": 1,
      "groups": [
        {
          "id": 1,
          "title": "Rat race",
          "group_products": 1
        }
      ],
      "products": [
        {
          "id": "1",
          "title": "This will make me rich!",
          "description": "I am sure of it, Pinky."
        }
      ]
    }
  ],
  "links": {},
  "meta": {}
}
```

# Retrieve a section (/docs/api/sections/retrieve-a-section)

This endpoint allows you to retrieve a specific section by providing the unique identifier. Refer to [the list](/api/sections#the-section-model) to see which properties are included with section objects.

## Endpoint

- Method: `GET`

- Path: `/v1/sections/{section}`

- Full URL: `https://sell.app/api/v1/sections/{section}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `section` (`integer`, required): The section path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "title": {
          "type": "string"
        },
        "slug": {
          "type": "string"
        },
        "hidden": {
          "type": "boolean"
        },
        "order": {
          "type": "integer"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "store_id": {
          "type": "integer"
        },
        "groups_linked": {
          "type": "integer"
        },
        "products_linked": {
          "type": "integer"
        },
        "groups": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "id": {
                "type": "integer"
              },
              "title": {
                "type": "string"
              },
              "group_products": {
                "type": "integer"
              }
            },
            "required": [
              "id",
              "title",
              "group_products"
            ]
          }
        },
        "products": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "title": {
                "type": "string"
              },
              "description": {
                "type": "string"
              }
            },
            "required": [
              "id",
              "title",
              "description"
            ]
          }
        }
      },
      "required": [
        "id",
        "title",
        "slug",
        "hidden",
        "order",
        "created_at",
        "updated_at",
        "store_id",
        "groups_linked",
        "products_linked",
        "groups",
        "products"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "title": "Dissection",
    "slug": "dissection",
    "hidden": false,
    "order": 1,
    "created_at": "2022-12-12T12:12:12.000000Z",
    "updated_at": "2022-12-12T12:12:12.000000Z",
    "store_id": 1,
    "groups_linked": 1,
    "products_linked": 1,
    "groups": [
      {
        "id": 1,
        "title": "Rat race",
        "group_products": 1
      }
    ],
    "products": [
      {
        "id": "1",
        "title": "This will make me rich!",
        "description": "I am sure of it, Pinky."
      }
    ]
  }
}
```

# Search sections (/docs/api/sections/search-sections)

Search sections with filters, search terms, includes, and sort instructions in a JSON request body.

## Endpoint

- Method: `POST`

- Path: `/v1/sections/search`

- Full URL: `https://sell.app/api/v1/sections/search`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "filters": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "field": {
            "type": "string"
          },
          "operator": {
            "type": "string",
            "default": "="
          },
          "value": {},
          "type": {
            "type": "string",
            "enum": [
              "and",
              "or"
            ],
            "default": "and"
          },
          "nested": {
            "type": "array",
            "items": {
              "type": "object",
              "additionalProperties": true
            }
          }
        },
        "required": [
          "field"
        ]
      }
    },
    "sort": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "field": {
            "type": "string"
          },
          "direction": {
            "type": "string",
            "enum": [
              "asc",
              "desc"
            ],
            "default": "asc"
          }
        },
        "required": [
          "field"
        ]
      }
    },
    "search": {
      "type": "object",
      "properties": {
        "value": {
          "type": [
            "string",
            "null"
          ]
        },
        "case_sensitive": {
          "type": "boolean"
        }
      }
    },
    "includes": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "relation": {
            "type": "string"
          }
        },
        "required": [
          "relation"
        ]
      }
    }
  }
}
```

Example:

```json
{
  "filters": [
    {
      "field": "id",
      "operator": "=",
      "value": 1
    }
  ],
  "sort": [
    {
      "field": "created_at",
      "direction": "desc"
    }
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "hidden": {
            "type": "boolean"
          },
          "order": {
            "type": "integer"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "store_id": {
            "type": "integer"
          },
          "groups_linked": {
            "type": "integer"
          },
          "products_linked": {
            "type": "integer"
          },
          "groups": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "integer"
                },
                "title": {
                  "type": "string"
                },
                "group_products": {
                  "type": "integer"
                }
              },
              "required": [
                "id",
                "title",
                "group_products"
              ]
            }
          },
          "products": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "title": {
                  "type": "string"
                },
                "description": {
                  "type": "string"
                }
              },
              "required": [
                "id",
                "title",
                "description"
              ]
            }
          }
        },
        "required": [
          "id",
          "title",
          "slug",
          "hidden",
          "order",
          "created_at",
          "updated_at",
          "store_id",
          "groups_linked",
          "products_linked",
          "groups",
          "products"
        ]
      }
    },
    "links": {
      "type": "object",
      "properties": {}
    },
    "meta": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "data",
    "links",
    "meta"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "title": "Dissection",
      "slug": "dissection",
      "hidden": false,
      "order": 1,
      "created_at": "2022-12-12T12:12:12.000000Z",
      "updated_at": "2022-12-12T12:12:12.000000Z",
      "store_id": 1,
      "groups_linked": 1,
      "products_linked": 1,
      "groups": [
        {
          "id": 1,
          "title": "Rat race",
          "group_products": 1
        }
      ],
      "products": [
        {
          "id": "1",
          "title": "This will make me rich!",
          "description": "I am sure of it, Pinky."
        }
      ]
    }
  ],
  "links": {},
  "meta": {}
}
```

# Update a section (/docs/api/sections/update-a-section)

This endpoint allows you to perform an update on a section.

## Endpoint

- Method: `PATCH`

- Path: `/v1/sections/{section}`

- Full URL: `https://sell.app/api/v1/sections/{section}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `section` (`integer`, required): The section path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "title": {
      "type": "string"
    },
    "hidden": {
      "type": "boolean"
    }
  }
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "title": {
          "type": "string"
        },
        "slug": {
          "type": "string"
        },
        "hidden": {
          "type": "boolean"
        },
        "order": {
          "type": "integer"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "store_id": {
          "type": "integer"
        },
        "groups_linked": {
          "type": "integer"
        },
        "products_linked": {
          "type": "integer"
        },
        "groups": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "products": {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      },
      "required": [
        "id",
        "title",
        "slug",
        "hidden",
        "order",
        "created_at",
        "updated_at",
        "store_id",
        "groups_linked",
        "products_linked",
        "groups",
        "products"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 2,
    "title": "Developer Goodies V2",
    "slug": "developer-goodies-v2",
    "hidden": false,
    "order": 1,
    "created_at": "2022-12-12T12:12:12.000000Z",
    "updated_at": "2022-12-12T12:12:12.000000Z",
    "store_id": 1,
    "groups_linked": 0,
    "products_linked": 0,
    "groups": [],
    "products": []
  }
}
```

# Cancel a subscription immediately with a refund (/docs/api/subscriptions/cancel-a-subscription-immediately-with-a-refund)

To cancel immediately and refund the latest subscription payment, send `cancel_at_period_end: false` with `refund_last_payment: true`.

Set `pro_rated_refund: true` if you want a pro-rated refund instead of a full refund.

## Endpoint

- Method: `PATCH`

- Path: `/v2/subscriptions/{subscription}/cancel`

- Full URL: `https://sell.app/api/v2/subscriptions/{subscription}/cancel`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `subscription` (`integer`, required): The subscription path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "cancel_at_period_end": {
      "type": "boolean"
    },
    "refund_last_payment": {
      "type": "boolean"
    },
    "pro_rated_refund": {
      "type": "boolean"
    }
  },
  "required": [
    "cancel_at_period_end"
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "invoice_id": {
          "type": "integer"
        },
        "provider": {
          "type": "string"
        },
        "subscription_id": {
          "type": "string"
        },
        "customer_id": {
          "type": "string"
        },
        "customer_email": {
          "type": "string"
        },
        "status": {
          "type": "string"
        },
        "current_period_start": {
          "type": "string",
          "format": "date-time"
        },
        "current_period_end": {
          "type": "string",
          "format": "date-time"
        },
        "cancel_at_period_end": {
          "type": "boolean"
        },
        "cancellation_in_progress": {
          "type": "boolean"
        },
        "store_id": {
          "type": "integer"
        },
        "product_variant_id": {
          "type": "integer"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        }
      },
      "required": [
        "id",
        "invoice_id",
        "provider",
        "subscription_id",
        "customer_id",
        "customer_email",
        "status",
        "current_period_start",
        "current_period_end",
        "cancel_at_period_end",
        "cancellation_in_progress",
        "store_id",
        "product_variant_id",
        "created_at",
        "updated_at"
      ]
    },
    "message": {
      "type": "string"
    }
  },
  "required": [
    "data",
    "message"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 123,
    "invoice_id": 456,
    "provider": "stripe",
    "subscription_id": "sub_1QwertyExample",
    "customer_id": "cus_Example123",
    "customer_email": "customer@example.com",
    "status": "ACTIVE",
    "current_period_start": "2026-03-01T00:00:00.000000Z",
    "current_period_end": "2026-04-01T00:00:00.000000Z",
    "cancel_at_period_end": true,
    "cancellation_in_progress": false,
    "store_id": 1,
    "product_variant_id": 99,
    "created_at": "2026-03-01T00:00:00.000000Z",
    "updated_at": "2026-03-23T00:00:00.000000Z"
  },
  "message": "Subscription will be cancelled at the end of the current period."
}
```

# Cancel a subscription (/docs/api/subscriptions/cancel-a-subscription)

This endpoint lets you cancel an active subscription programmatically.

You can either:

1. Schedule the cancellation for the end of the current billing period.
2. Cancel immediately.
3. Optionally refund the most recent payment when canceling immediately.

<Note>
  Refund options are only supported for immediate cancellations. If you send `cancel_at_period_end: true`, you should not include refund flags.
</Note>

## Endpoint

- Method: `PATCH`

- Path: `/v2/subscriptions/{subscription}/cancel`

- Full URL: `https://sell.app/api/v2/subscriptions/{subscription}/cancel`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `subscription` (`integer`, required): The subscription path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "cancel_at_period_end": {
      "type": "boolean"
    },
    "refund_last_payment": {
      "type": "boolean"
    },
    "pro_rated_refund": {
      "type": "boolean"
    }
  },
  "required": [
    "cancel_at_period_end"
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "invoice_id": {
          "type": "integer"
        },
        "provider": {
          "type": "string"
        },
        "subscription_id": {
          "type": "string"
        },
        "customer_id": {
          "type": "string"
        },
        "customer_email": {
          "type": "string"
        },
        "status": {
          "type": "string"
        },
        "current_period_start": {
          "type": "string",
          "format": "date-time"
        },
        "current_period_end": {
          "type": "string",
          "format": "date-time"
        },
        "cancel_at_period_end": {
          "type": "boolean"
        },
        "cancellation_in_progress": {
          "type": "boolean"
        },
        "store_id": {
          "type": "integer"
        },
        "product_variant_id": {
          "type": "integer"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        }
      },
      "required": [
        "id",
        "invoice_id",
        "provider",
        "subscription_id",
        "customer_id",
        "customer_email",
        "status",
        "current_period_start",
        "current_period_end",
        "cancel_at_period_end",
        "cancellation_in_progress",
        "store_id",
        "product_variant_id",
        "created_at",
        "updated_at"
      ]
    },
    "message": {
      "type": "string"
    }
  },
  "required": [
    "data",
    "message"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 123,
    "invoice_id": 456,
    "provider": "stripe",
    "subscription_id": "sub_1QwertyExample",
    "customer_id": "cus_Example123",
    "customer_email": "customer@example.com",
    "status": "ACTIVE",
    "current_period_start": "2026-03-01T00:00:00.000000Z",
    "current_period_end": "2026-04-01T00:00:00.000000Z",
    "cancel_at_period_end": true,
    "cancellation_in_progress": false,
    "store_id": 1,
    "product_variant_id": 99,
    "created_at": "2026-03-01T00:00:00.000000Z",
    "updated_at": "2026-03-23T00:00:00.000000Z"
  },
  "message": "Subscription will be cancelled at the end of the current period."
}
```

# Overview (/docs/api/subscriptions)



Subscriptions represent recurring product purchases made through your store. The V2 subscriptions API currently exposes one cancellation route, which can either cancel immediately or schedule cancellation for the end of the current billing period depending on the request body you send.

<Note>
  Both endpoint pages below document the same `PATCH /v2/subscriptions/{subscription}/cancel`
  route. They are split out to show the two main request-body patterns.
</Note>

## Endpoints [#endpoints]

* [Cancel a subscription](/api/subscriptions/cancel-a-subscription)
* [Cancel a subscription immediately with a refund](/api/subscriptions/cancel-a-subscription-immediately-with-a-refund)

## The subscription model [#the-subscription-model]

The subscription model contains the key billing and customer details associated with a recurring subscription.

### Properties [#properties]

<Properties>
  <Property name="id" type="integer">
    *(read-only)* The unique identifier for the subscription record.
  </Property>

  <Property name="invoice_id" type="integer | null">
    *(read-only)* The original invoice ID linked to this subscription, if available.
  </Property>

  <Property name="provider" type="string">
    *(read-only)* The billing provider handling the subscription, such as `stripe` or `paypal`.
  </Property>

  <Property name="subscription_id" type="string">
    *(read-only)* The provider subscription identifier.
  </Property>

  <Property name="customer_id" type="string">
    *(read-only)* The provider customer identifier.
  </Property>

  <Property name="customer_email" type="string">
    *(read-only)* The customer email associated with the subscription.
  </Property>

  <Property name="status" type="string">
    *(read-only)* The current subscription status, such as `ACTIVE` or `CANCELED`.
  </Property>

  <Property name="current_period_start" type="timestamp | null">
    *(read-only)* When the current billing period started.
  </Property>

  <Property name="current_period_end" type="timestamp | null">
    *(read-only)* When the current billing period ends or ended.
  </Property>

  <Property name="cancel_at_period_end" type="boolean">
    *(read-only)* Whether the subscription is scheduled to cancel at the end of the current billing period.
  </Property>

  <Property name="cancellation_in_progress" type="boolean">
    *(read-only)* Whether an immediate cancellation request has been accepted and is still waiting on provider webhook sync.
  </Property>

  <Property name="store_id" type="integer">
    *(read-only)* The ID of the store this subscription belongs to.
  </Property>

  <Property name="product_variant_id" type="integer | null">
    *(read-only)* The ID of the subscribed product variant.
  </Property>

  <Property name="created_at" type="timestamp">
    *(read-only)* Time at which the subscription record was created.
  </Property>

  <Property name="updated_at" type="timestamp">
    *(read-only)* Time at which the subscription record was last updated.
  </Property>
</Properties>

***


# Batch create products (/docs/api/products/batch-create-products)

Create multiple products in one request by sending a `resources` array.

## Endpoint

- Method: `POST`

- Path: `/v2/products/batch`

- Full URL: `https://sell.app/api/v2/products/batch`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "resources": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "title": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "visibility": {
            "type": "string",
            "enum": [
              "PUBLIC",
              "ON_HOLD",
              "HIDDEN",
              "PRIVATE"
            ]
          },
          "slug": {
            "type": "string"
          },
          "type": {
            "type": "string",
            "enum": [
              "product",
              "bundle"
            ]
          },
          "section": {
            "type": [
              "integer",
              "null"
            ]
          },
          "additional_information": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "type": {
                  "type": "string",
                  "enum": [
                    "text",
                    "number",
                    "email",
                    "phone",
                    "currency",
                    "link",
                    "textarea",
                    "select",
                    "radio",
                    "checkbox-group",
                    "pillbox",
                    "checkbox",
                    "switch",
                    "date",
                    "date-range",
                    "hidden"
                  ]
                },
                "required": {
                  "type": "boolean"
                },
                "label": {
                  "type": "string"
                },
                "key": {
                  "type": "string"
                },
                "options": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                },
                "placeholder": {
                  "type": "string"
                },
                "description": {
                  "type": "string"
                },
                "variant": {
                  "type": "string"
                },
                "date_options": {
                  "type": "object",
                  "additionalProperties": true
                }
              },
              "required": [
                "type",
                "required",
                "label"
              ]
            }
          },
          "other_settings": {
            "type": "object",
            "properties": {
              "redirect_url": {
                "type": "string",
                "format": "uri"
              },
              "video_url": {
                "type": "string",
                "format": "uri"
              },
              "product_title": {
                "type": "string"
              },
              "product_description": {
                "type": "string"
              },
              "faq": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "question": {
                      "type": "string"
                    },
                    "answer": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "question",
                    "answer"
                  ]
                }
              }
            }
          }
        },
        "required": [
          "title",
          "description",
          "visibility"
        ]
      }
    }
  },
  "required": [
    "resources"
  ]
}
```

Example:

```json
{
  "resources": [
    {
      "title": "Example product",
      "description": "An example product created through the API.",
      "visibility": "PUBLIC",
      "type": "product"
    }
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "images": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "path": {
                  "type": "string"
                },
                "metadata": {
                  "type": "object",
                  "properties": {
                    "size": {
                      "type": "integer"
                    },
                    "filename": {
                      "type": "string"
                    },
                    "extension": {
                      "type": "string"
                    },
                    "mime_type": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "size",
                    "filename",
                    "extension",
                    "mime_type"
                  ]
                }
              },
              "required": [
                "path",
                "metadata"
              ]
            }
          },
          "order": {
            "type": "integer"
          },
          "visibility": {
            "type": "string"
          },
          "delivery_text": {
            "type": "string"
          },
          "additional_information": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "required": {
                  "type": "boolean"
                },
                "key": {
                  "type": "string"
                },
                "type": {
                  "type": "string"
                },
                "label": {
                  "type": "string"
                }
              },
              "required": [
                "required",
                "key",
                "type",
                "label"
              ]
            }
          },
          "other_settings": {
            "type": "object",
            "properties": {
              "faq": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "answer": {
                      "type": "string"
                    },
                    "question": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "answer",
                    "question"
                  ]
                }
              },
              "video_url": {
                "type": "string"
              },
              "redirect_url": {
                "type": "string"
              },
              "product_title": {
                "type": "string"
              },
              "product_description": {
                "type": "string"
              }
            },
            "required": [
              "faq",
              "video_url",
              "redirect_url",
              "product_title",
              "product_description"
            ]
          },
          "deleted_at": {
            "type": "null"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "store_id": {
            "type": "integer"
          },
          "category_id": {
            "type": "null"
          },
          "section_id": {
            "type": "null"
          },
          "section_order": {
            "type": "null"
          },
          "is_discoverable": {
            "type": "integer"
          },
          "variants": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "integer"
                },
                "title": {
                  "type": "string"
                }
              },
              "required": [
                "id",
                "title"
              ]
            }
          },
          "url": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "title",
          "slug",
          "description",
          "images",
          "order",
          "visibility",
          "delivery_text",
          "additional_information",
          "other_settings",
          "deleted_at",
          "created_at",
          "updated_at",
          "store_id",
          "category_id",
          "section_id",
          "section_order",
          "is_discoverable",
          "variants",
          "url"
        ]
      }
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "title": "Elixir of immortality",
      "slug": "elixir-of-immortality",
      "description": "<p>Want to live forever? Buy this now and I'll send a digital elixir that converts your soul into an NFT that will roam the internet for eternity!</p>",
      "images": [
        {
          "path": "store/1/listings/NM6TBKIMzpFJq1MKTV24oMJ1W4UrKCo7NS98nt4K.png",
          "metadata": {
            "size": 39289,
            "filename": "NM6TBKIMzpFJq1MKTV24oMJ1W4UrKCo7NS98nt4K",
            "extension": "png",
            "mime_type": "image/png"
          }
        },
        {
          "path": "store/1/listings/ov6XMb68tRr80zl7sqfN1or7xfqqH5WbZygDEQ8X.png",
          "metadata": {
            "size": 422373,
            "filename": "ov6XMb68tRr80zl7sqfN1or7xfqqH5WbZygDEQ8X",
            "extension": "png",
            "mime_type": "image/png"
          }
        }
      ],
      "order": 1,
      "visibility": "PUBLIC",
      "delivery_text": "Thanks again bud!",
      "additional_information": [
        {
          "required": true,
          "key": "3aecffd000e00e2211e94558007ffc37",
          "type": "checkbox",
          "label": "Do you agree to handing your soul over?"
        }
      ],
      "other_settings": {
        "faq": [
          {
            "answer": "Yes, trust me!",
            "question": "Will I really live forever?"
          }
        ],
        "video_url": "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
        "redirect_url": "https://666.com/transfer-soul?customer_email=[customer_email]&order_id=[order_id]",
        "product_title": "The real elixir of immortality",
        "product_description": "Live forever, online."
      },
      "deleted_at": null,
      "created_at": "2024-01-09T22:56:49.000000Z",
      "updated_at": "2024-01-10T10:00:28.000000Z",
      "store_id": 1,
      "category_id": null,
      "section_id": null,
      "section_order": null,
      "is_discoverable": 1,
      "variants": [
        {
          "id": 1,
          "title": "Default"
        }
      ],
      "url": "https://example.sell.app/product/elixir-of-immortality"
    }
  ]
}
```

# Batch delete products (/docs/api/products/batch-delete-products)

Delete multiple products in one request by sending the product IDs in `resources`.

## Endpoint

- Method: `DELETE`

- Path: `/v2/products/batch`

- Full URL: `https://sell.app/api/v2/products/batch`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "resources": {
      "type": "array",
      "items": {
        "type": "integer"
      }
    }
  },
  "required": [
    "resources"
  ]
}
```

Example:

```json
{
  "resources": [
    1,
    2
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "images": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "path": {
                  "type": "string"
                },
                "metadata": {
                  "type": "object",
                  "properties": {
                    "size": {
                      "type": "integer"
                    },
                    "filename": {
                      "type": "string"
                    },
                    "extension": {
                      "type": "string"
                    },
                    "mime_type": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "size",
                    "filename",
                    "extension",
                    "mime_type"
                  ]
                }
              },
              "required": [
                "path",
                "metadata"
              ]
            }
          },
          "order": {
            "type": "integer"
          },
          "visibility": {
            "type": "string"
          },
          "delivery_text": {
            "type": "string"
          },
          "additional_information": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "required": {
                  "type": "boolean"
                },
                "key": {
                  "type": "string"
                },
                "type": {
                  "type": "string"
                },
                "label": {
                  "type": "string"
                }
              },
              "required": [
                "required",
                "key",
                "type",
                "label"
              ]
            }
          },
          "other_settings": {
            "type": "object",
            "properties": {
              "faq": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "answer": {
                      "type": "string"
                    },
                    "question": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "answer",
                    "question"
                  ]
                }
              },
              "video_url": {
                "type": "string"
              },
              "redirect_url": {
                "type": "string"
              },
              "product_title": {
                "type": "string"
              },
              "product_description": {
                "type": "string"
              }
            },
            "required": [
              "faq",
              "video_url",
              "redirect_url",
              "product_title",
              "product_description"
            ]
          },
          "deleted_at": {
            "type": "null"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "store_id": {
            "type": "integer"
          },
          "category_id": {
            "type": "null"
          },
          "section_id": {
            "type": "null"
          },
          "section_order": {
            "type": "null"
          },
          "is_discoverable": {
            "type": "integer"
          },
          "variants": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "integer"
                },
                "title": {
                  "type": "string"
                }
              },
              "required": [
                "id",
                "title"
              ]
            }
          },
          "url": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "title",
          "slug",
          "description",
          "images",
          "order",
          "visibility",
          "delivery_text",
          "additional_information",
          "other_settings",
          "deleted_at",
          "created_at",
          "updated_at",
          "store_id",
          "category_id",
          "section_id",
          "section_order",
          "is_discoverable",
          "variants",
          "url"
        ]
      }
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "title": "Elixir of immortality",
      "slug": "elixir-of-immortality",
      "description": "<p>Want to live forever? Buy this now and I'll send a digital elixir that converts your soul into an NFT that will roam the internet for eternity!</p>",
      "images": [
        {
          "path": "store/1/listings/NM6TBKIMzpFJq1MKTV24oMJ1W4UrKCo7NS98nt4K.png",
          "metadata": {
            "size": 39289,
            "filename": "NM6TBKIMzpFJq1MKTV24oMJ1W4UrKCo7NS98nt4K",
            "extension": "png",
            "mime_type": "image/png"
          }
        },
        {
          "path": "store/1/listings/ov6XMb68tRr80zl7sqfN1or7xfqqH5WbZygDEQ8X.png",
          "metadata": {
            "size": 422373,
            "filename": "ov6XMb68tRr80zl7sqfN1or7xfqqH5WbZygDEQ8X",
            "extension": "png",
            "mime_type": "image/png"
          }
        }
      ],
      "order": 1,
      "visibility": "PUBLIC",
      "delivery_text": "Thanks again bud!",
      "additional_information": [
        {
          "required": true,
          "key": "3aecffd000e00e2211e94558007ffc37",
          "type": "checkbox",
          "label": "Do you agree to handing your soul over?"
        }
      ],
      "other_settings": {
        "faq": [
          {
            "answer": "Yes, trust me!",
            "question": "Will I really live forever?"
          }
        ],
        "video_url": "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
        "redirect_url": "https://666.com/transfer-soul?customer_email=[customer_email]&order_id=[order_id]",
        "product_title": "The real elixir of immortality",
        "product_description": "Live forever, online."
      },
      "deleted_at": null,
      "created_at": "2024-01-09T22:56:49.000000Z",
      "updated_at": "2024-01-10T10:00:28.000000Z",
      "store_id": 1,
      "category_id": null,
      "section_id": null,
      "section_order": null,
      "is_discoverable": 1,
      "variants": [
        {
          "id": 1,
          "title": "Default"
        }
      ],
      "url": "https://example.sell.app/product/elixir-of-immortality"
    }
  ]
}
```

# Batch update products (/docs/api/products/batch-update-products)

Update multiple products in one request by sending a `resources` object keyed by product ID.

## Endpoint

- Method: `PATCH`

- Path: `/v2/products/batch`

- Full URL: `https://sell.app/api/v2/products/batch`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "resources": {
      "type": "object",
      "additionalProperties": {
        "type": "object",
        "properties": {
          "title": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "visibility": {
            "type": "string",
            "enum": [
              "PUBLIC",
              "ON_HOLD",
              "HIDDEN",
              "PRIVATE"
            ]
          },
          "slug": {
            "type": "string"
          },
          "section": {
            "type": [
              "integer",
              "null"
            ]
          },
          "additional_information": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "type": {
                  "type": "string",
                  "enum": [
                    "text",
                    "number",
                    "email",
                    "phone",
                    "currency",
                    "link",
                    "textarea",
                    "select",
                    "radio",
                    "checkbox-group",
                    "pillbox",
                    "checkbox",
                    "switch",
                    "date",
                    "date-range",
                    "hidden"
                  ]
                },
                "required": {
                  "type": "boolean"
                },
                "label": {
                  "type": "string"
                },
                "key": {
                  "type": "string"
                },
                "options": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                },
                "placeholder": {
                  "type": "string"
                },
                "description": {
                  "type": "string"
                },
                "variant": {
                  "type": "string"
                },
                "date_options": {
                  "type": "object",
                  "additionalProperties": true
                }
              },
              "required": [
                "type",
                "required",
                "label"
              ]
            }
          },
          "other_settings": {
            "type": "object",
            "properties": {
              "redirect_url": {
                "type": "string",
                "format": "uri"
              },
              "video_url": {
                "type": "string",
                "format": "uri"
              },
              "product_title": {
                "type": "string"
              },
              "product_description": {
                "type": "string"
              },
              "faq": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "question": {
                      "type": "string"
                    },
                    "answer": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "question",
                    "answer"
                  ]
                }
              }
            }
          }
        }
      }
    }
  },
  "required": [
    "resources"
  ]
}
```

Example:

```json
{
  "resources": {
    "1": {
      "title": "Updated product",
      "visibility": "PUBLIC"
    }
  }
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "images": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "path": {
                  "type": "string"
                },
                "metadata": {
                  "type": "object",
                  "properties": {
                    "size": {
                      "type": "integer"
                    },
                    "filename": {
                      "type": "string"
                    },
                    "extension": {
                      "type": "string"
                    },
                    "mime_type": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "size",
                    "filename",
                    "extension",
                    "mime_type"
                  ]
                }
              },
              "required": [
                "path",
                "metadata"
              ]
            }
          },
          "order": {
            "type": "integer"
          },
          "visibility": {
            "type": "string"
          },
          "delivery_text": {
            "type": "string"
          },
          "additional_information": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "required": {
                  "type": "boolean"
                },
                "key": {
                  "type": "string"
                },
                "type": {
                  "type": "string"
                },
                "label": {
                  "type": "string"
                }
              },
              "required": [
                "required",
                "key",
                "type",
                "label"
              ]
            }
          },
          "other_settings": {
            "type": "object",
            "properties": {
              "faq": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "answer": {
                      "type": "string"
                    },
                    "question": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "answer",
                    "question"
                  ]
                }
              },
              "video_url": {
                "type": "string"
              },
              "redirect_url": {
                "type": "string"
              },
              "product_title": {
                "type": "string"
              },
              "product_description": {
                "type": "string"
              }
            },
            "required": [
              "faq",
              "video_url",
              "redirect_url",
              "product_title",
              "product_description"
            ]
          },
          "deleted_at": {
            "type": "null"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "store_id": {
            "type": "integer"
          },
          "category_id": {
            "type": "null"
          },
          "section_id": {
            "type": "null"
          },
          "section_order": {
            "type": "null"
          },
          "is_discoverable": {
            "type": "integer"
          },
          "variants": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "integer"
                },
                "title": {
                  "type": "string"
                }
              },
              "required": [
                "id",
                "title"
              ]
            }
          },
          "url": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "title",
          "slug",
          "description",
          "images",
          "order",
          "visibility",
          "delivery_text",
          "additional_information",
          "other_settings",
          "deleted_at",
          "created_at",
          "updated_at",
          "store_id",
          "category_id",
          "section_id",
          "section_order",
          "is_discoverable",
          "variants",
          "url"
        ]
      }
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "title": "Elixir of immortality",
      "slug": "elixir-of-immortality",
      "description": "<p>Want to live forever? Buy this now and I'll send a digital elixir that converts your soul into an NFT that will roam the internet for eternity!</p>",
      "images": [
        {
          "path": "store/1/listings/NM6TBKIMzpFJq1MKTV24oMJ1W4UrKCo7NS98nt4K.png",
          "metadata": {
            "size": 39289,
            "filename": "NM6TBKIMzpFJq1MKTV24oMJ1W4UrKCo7NS98nt4K",
            "extension": "png",
            "mime_type": "image/png"
          }
        },
        {
          "path": "store/1/listings/ov6XMb68tRr80zl7sqfN1or7xfqqH5WbZygDEQ8X.png",
          "metadata": {
            "size": 422373,
            "filename": "ov6XMb68tRr80zl7sqfN1or7xfqqH5WbZygDEQ8X",
            "extension": "png",
            "mime_type": "image/png"
          }
        }
      ],
      "order": 1,
      "visibility": "PUBLIC",
      "delivery_text": "Thanks again bud!",
      "additional_information": [
        {
          "required": true,
          "key": "3aecffd000e00e2211e94558007ffc37",
          "type": "checkbox",
          "label": "Do you agree to handing your soul over?"
        }
      ],
      "other_settings": {
        "faq": [
          {
            "answer": "Yes, trust me!",
            "question": "Will I really live forever?"
          }
        ],
        "video_url": "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
        "redirect_url": "https://666.com/transfer-soul?customer_email=[customer_email]&order_id=[order_id]",
        "product_title": "The real elixir of immortality",
        "product_description": "Live forever, online."
      },
      "deleted_at": null,
      "created_at": "2024-01-09T22:56:49.000000Z",
      "updated_at": "2024-01-10T10:00:28.000000Z",
      "store_id": 1,
      "category_id": null,
      "section_id": null,
      "section_order": null,
      "is_discoverable": 1,
      "variants": [
        {
          "id": 1,
          "title": "Default"
        }
      ],
      "url": "https://example.sell.app/product/elixir-of-immortality"
    }
  ]
}
```

# Create a product (/docs/api/products/create-a-product)

Programmatically create a product using the following endpoint. See the code examples for how to create a new product with the SellApp API.

<Note>
  Unlike other endpoints, we will be using Multipart instead of JSON so we can add a product image.

  If you do not wish to add a product image, you may modify the request and use JSON instead.
</Note>

<Note>
  This will create a **draft** product. To complete the product, create a
  variant via [Create a product variant](../product-variants/create-a-product-variant).
</Note>

## Endpoint

- Method: `POST`

- Path: `/v2/products`

- Full URL: `https://sell.app/api/v2/products`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "title": {
      "type": "string"
    },
    "description": {
      "type": "string"
    },
    "visibility": {
      "type": "string",
      "enum": [
        "PUBLIC",
        "ON_HOLD",
        "HIDDEN",
        "PRIVATE"
      ]
    },
    "slug": {
      "type": "string"
    },
    "type": {
      "type": "string",
      "enum": [
        "product",
        "bundle"
      ]
    },
    "section": {
      "type": [
        "integer",
        "null"
      ]
    },
    "additional_information": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "text",
              "number",
              "email",
              "phone",
              "currency",
              "link",
              "textarea",
              "select",
              "radio",
              "checkbox-group",
              "pillbox",
              "checkbox",
              "switch",
              "date",
              "date-range",
              "hidden"
            ]
          },
          "required": {
            "type": "boolean"
          },
          "label": {
            "type": "string"
          },
          "key": {
            "type": "string"
          },
          "options": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "placeholder": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "variant": {
            "type": "string"
          },
          "date_options": {
            "type": "object",
            "additionalProperties": true
          }
        },
        "required": [
          "type",
          "required",
          "label"
        ]
      }
    },
    "other_settings": {
      "type": "object",
      "properties": {
        "redirect_url": {
          "type": "string",
          "format": "uri"
        },
        "video_url": {
          "type": "string",
          "format": "uri"
        },
        "product_title": {
          "type": "string"
        },
        "product_description": {
          "type": "string"
        },
        "faq": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "question": {
                "type": "string"
              },
              "answer": {
                "type": "string"
              }
            },
            "required": [
              "question",
              "answer"
            ]
          }
        }
      }
    }
  },
  "required": [
    "title",
    "description",
    "visibility"
  ]
}
```

### Content Type: `multipart/form-data`

Schema:

```json
{
  "type": "object",
  "properties": {
    "title": {
      "type": "string"
    },
    "description": {
      "type": "string"
    },
    "visibility": {
      "type": "string",
      "enum": [
        "PUBLIC",
        "ON_HOLD",
        "HIDDEN",
        "PRIVATE"
      ]
    },
    "slug": {
      "type": "string"
    },
    "type": {
      "type": "string",
      "enum": [
        "product",
        "bundle"
      ]
    },
    "section": {
      "type": [
        "integer",
        "null"
      ]
    },
    "additional_information": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "text",
              "number",
              "email",
              "phone",
              "currency",
              "link",
              "textarea",
              "select",
              "radio",
              "checkbox-group",
              "pillbox",
              "checkbox",
              "switch",
              "date",
              "date-range",
              "hidden"
            ]
          },
          "required": {
            "type": "boolean"
          },
          "label": {
            "type": "string"
          },
          "key": {
            "type": "string"
          },
          "options": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "placeholder": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "variant": {
            "type": "string"
          },
          "date_options": {
            "type": "object",
            "additionalProperties": true
          }
        },
        "required": [
          "type",
          "required",
          "label"
        ]
      }
    },
    "other_settings": {
      "type": "object",
      "properties": {
        "redirect_url": {
          "type": "string",
          "format": "uri"
        },
        "video_url": {
          "type": "string",
          "format": "uri"
        },
        "product_title": {
          "type": "string"
        },
        "product_description": {
          "type": "string"
        },
        "faq": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "question": {
                "type": "string"
              },
              "answer": {
                "type": "string"
              }
            },
            "required": [
              "question",
              "answer"
            ]
          }
        }
      }
    },
    "images": {
      "type": "array",
      "items": {
        "type": "string",
        "format": "binary"
      },
      "maxItems": 4
    }
  },
  "required": [
    "title",
    "description",
    "visibility"
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "title": {
          "type": "string"
        },
        "slug": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "images": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "path": {
                "type": "string"
              },
              "metadata": {
                "type": "object",
                "properties": {
                  "size": {
                    "type": "integer"
                  },
                  "filename": {
                    "type": "string"
                  },
                  "extension": {
                    "type": "string"
                  },
                  "mime_type": {
                    "type": "string"
                  }
                },
                "required": [
                  "size",
                  "filename",
                  "extension",
                  "mime_type"
                ]
              }
            },
            "required": [
              "path",
              "metadata"
            ]
          }
        },
        "order": {
          "type": "integer"
        },
        "visibility": {
          "type": "string"
        },
        "delivery_text": {
          "type": "string"
        },
        "additional_information": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "required": {
                "type": "boolean"
              },
              "key": {
                "type": "string"
              },
              "type": {
                "type": "string"
              },
              "label": {
                "type": "string"
              }
            },
            "required": [
              "required",
              "key",
              "type",
              "label"
            ]
          }
        },
        "other_settings": {
          "type": "object",
          "properties": {
            "faq": {
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "answer": {
                    "type": "string"
                  },
                  "question": {
                    "type": "string"
                  }
                },
                "required": [
                  "answer",
                  "question"
                ]
              }
            },
            "video_url": {
              "type": "string"
            },
            "redirect_url": {
              "type": "string"
            },
            "product_title": {
              "type": "string"
            },
            "product_description": {
              "type": "string"
            }
          },
          "required": [
            "faq",
            "video_url",
            "redirect_url",
            "product_title",
            "product_description"
          ]
        },
        "deleted_at": {
          "type": "null"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "store_id": {
          "type": "integer"
        },
        "category_id": {
          "type": "null"
        },
        "section_id": {
          "type": "null"
        },
        "section_order": {
          "type": "null"
        },
        "is_discoverable": {
          "type": "integer"
        },
        "variants": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "url": {
          "type": "string"
        }
      },
      "required": [
        "id",
        "title",
        "slug",
        "description",
        "images",
        "order",
        "visibility",
        "delivery_text",
        "additional_information",
        "other_settings",
        "deleted_at",
        "created_at",
        "updated_at",
        "store_id",
        "category_id",
        "section_id",
        "section_order",
        "is_discoverable",
        "variants",
        "url"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 2,
    "title": "Immortality Elixir",
    "slug": "immortality-elixir",
    "description": "Want to live forever? Buy this now and I'll send a digital elixir that converts your soul into an NFT that will roam the internet for eternity!",
    "images": [
      {
        "path": "store/1/listings/qXZHzR15vs09zbfn3yui5jO6QK0IbQP4M6QVydUn.png",
        "metadata": {
          "size": 39289,
          "filename": "qXZHzR15vs09zbfn3yui5jO6QK0IbQP4M6QVydUn",
          "extension": "png",
          "mime_type": "image/png"
        }
      }
    ],
    "order": 2,
    "visibility": "PUBLIC",
    "delivery_text": "Thanks for purchasing! Here is a 20% off coupon for your next purchase: 20FREE24",
    "additional_information": [
      {
        "required": true,
        "key": "5ebae238c0afae7f4a4b96b30ff6f34c",
        "type": "checkbox",
        "label": "I agree to handing over my soul"
      },
      {
        "required": true,
        "key": "soul_transfer_email",
        "type": "email",
        "label": "Soul Transfer Email",
        "placeholder": "your.soul@example.com",
        "description": "We will send your digital elixir here"
      }
    ],
    "other_settings": {
      "faq": [
        {
          "answer": "Yes, trust me!",
          "question": "Will I really live forever?"
        }
      ],
      "video_url": "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
      "redirect_url": "https://666.com/transfer-soul?customer_email=[customer_email]&order_id=[order_id]",
      "product_title": "The real elixir of immortality",
      "product_description": "Live forever, online."
    },
    "deleted_at": null,
    "created_at": "2024-01-10T12:16:10.000000Z",
    "updated_at": "2024-01-10T12:16:10.000000Z",
    "store_id": 1,
    "category_id": null,
    "section_id": null,
    "section_order": null,
    "is_discoverable": 1,
    "variants": [],
    "url": "https://example.sell.app/product/immortality-elixir"
  }
}
```

# Delete a product (/docs/api/products/delete-a-product)

This endpoint allows you to delete a product.

<Warn>
  This will permanently delete the product and its associated data.
</Warn>

## Endpoint

- Method: `DELETE`

- Path: `/v2/products/{product}`

- Full URL: `https://sell.app/api/v2/products/{product}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `product` (`integer`, required): The product path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "title": {
          "type": "string"
        },
        "slug": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "images": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "path": {
                "type": "string"
              },
              "metadata": {
                "type": "object",
                "properties": {
                  "size": {
                    "type": "integer"
                  },
                  "filename": {
                    "type": "string"
                  },
                  "extension": {
                    "type": "string"
                  },
                  "mime_type": {
                    "type": "string"
                  }
                },
                "required": [
                  "size",
                  "filename",
                  "extension",
                  "mime_type"
                ]
              }
            },
            "required": [
              "path",
              "metadata"
            ]
          }
        },
        "order": {
          "type": "integer"
        },
        "visibility": {
          "type": "string"
        },
        "delivery_text": {
          "type": "string"
        },
        "additional_information": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "required": {
                "type": "boolean"
              },
              "key": {
                "type": "string"
              },
              "type": {
                "type": "string"
              },
              "label": {
                "type": "string"
              }
            },
            "required": [
              "required",
              "key",
              "type",
              "label"
            ]
          }
        },
        "other_settings": {
          "type": "object",
          "properties": {
            "faq": {
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "answer": {
                    "type": "string"
                  },
                  "question": {
                    "type": "string"
                  }
                },
                "required": [
                  "answer",
                  "question"
                ]
              }
            },
            "video_url": {
              "type": "string"
            },
            "redirect_url": {
              "type": "string"
            },
            "product_title": {
              "type": "string"
            },
            "product_description": {
              "type": "string"
            }
          },
          "required": [
            "faq",
            "video_url",
            "redirect_url",
            "product_title",
            "product_description"
          ]
        },
        "deleted_at": {
          "type": "null"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "store_id": {
          "type": "integer"
        },
        "category_id": {
          "type": "null"
        },
        "section_id": {
          "type": "null"
        },
        "section_order": {
          "type": "null"
        },
        "is_discoverable": {
          "type": "integer"
        },
        "variants": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "id": {
                "type": "integer"
              },
              "title": {
                "type": "string"
              }
            },
            "required": [
              "id",
              "title"
            ]
          }
        },
        "url": {
          "type": "string"
        }
      },
      "required": [
        "id",
        "title",
        "slug",
        "description",
        "images",
        "order",
        "visibility",
        "delivery_text",
        "additional_information",
        "other_settings",
        "deleted_at",
        "created_at",
        "updated_at",
        "store_id",
        "category_id",
        "section_id",
        "section_order",
        "is_discoverable",
        "variants",
        "url"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "title": "Elixir of immortality",
    "slug": "elixir-of-immortality",
    "description": "<p>Want to live forever? Buy this now and I'll send a digital elixir that converts your soul into an NFT that will roam the internet for eternity!</p>",
    "images": [
      {
        "path": "store/1/listings/NM6TBKIMzpFJq1MKTV24oMJ1W4UrKCo7NS98nt4K.png",
        "metadata": {
          "size": 39289,
          "filename": "NM6TBKIMzpFJq1MKTV24oMJ1W4UrKCo7NS98nt4K",
          "extension": "png",
          "mime_type": "image/png"
        }
      },
      {
        "path": "store/1/listings/ov6XMb68tRr80zl7sqfN1or7xfqqH5WbZygDEQ8X.png",
        "metadata": {
          "size": 422373,
          "filename": "ov6XMb68tRr80zl7sqfN1or7xfqqH5WbZygDEQ8X",
          "extension": "png",
          "mime_type": "image/png"
        }
      }
    ],
    "order": 1,
    "visibility": "PUBLIC",
    "delivery_text": "Thanks again bud!",
    "additional_information": [
      {
        "required": true,
        "key": "3aecffd000e00e2211e94558007ffc37",
        "type": "checkbox",
        "label": "Do you agree to handing your soul over?"
      }
    ],
    "other_settings": {
      "faq": [
        {
          "answer": "Yes, trust me!",
          "question": "Will I really live forever?"
        }
      ],
      "video_url": "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
      "redirect_url": "https://666.com/transfer-soul?customer_email=[customer_email]&order_id=[order_id]",
      "product_title": "The real elixir of immortality",
      "product_description": "Live forever, online."
    },
    "deleted_at": null,
    "created_at": "2024-01-09T22:56:49.000000Z",
    "updated_at": "2024-01-10T10:00:28.000000Z",
    "store_id": 1,
    "category_id": null,
    "section_id": null,
    "section_order": null,
    "is_discoverable": 1,
    "variants": [
      {
        "id": 1,
        "title": "Default"
      }
    ],
    "url": "https://example.sell.app/product/elixir-of-immortality"
  }
}
```

# Overview (/docs/api/products)



Products are objects containing variants. When a customer purchases a product, they are sent the respetive deliverable(s) that product's variant contains.

One product can have many variants, each of which have their own price, product deliverable, and pricing.

On this page, we'll dive into the different product endpoints you can use to manage products - and product variants - programmatically. We'll look at how to create, update, and delete products.

## Endpoints [#endpoints]

* [List all products](/api/products/list-all-products)
* [Search products](/api/products/search-products)
* [Create a product](/api/products/create-a-product)
* [Batch create products](/api/products/batch-create-products)
* [Retrieve a product](/api/products/retrieve-a-product)
* [Update a product](/api/products/update-a-product)
* [Batch update products](/api/products/batch-update-products)
* [Batch delete products](/api/products/batch-delete-products)
* [Delete a product](/api/products/delete-a-product)

## The product model [#the-product-model]

The product model contains all the information about the products stores have, including the price, media, and customization options.

### Properties [#properties]

<Properties>
  <Property name="id" type="integer">
    The unique product identifier
  </Property>

  <Property name="title" type="string">
    The product title.
  </Property>

  <Property name="slug" type="string">
    The unique product slug.
  </Property>

  <Property name="description" type="string">
    The product description.
  </Property>

  <Property name="images" type="object">
    The array of product images, displays the following information:

    * `path` image path
    * `metadata` array of image metadata
      * `size` size in bytes
      * `filename` file name
      * `extension` file extension
      * `mime_type` file mime type
  </Property>

  <Property name="order" type="integer">
    The order of the product relative to all other products in your storefront.
  </Property>

  <Property name="visibility" type="string">
    The product visibility. One of four values:

    * `PUBLIC` Product can be visited and purchased.
    * `ON_HOLD` Product can be visited but not be purchased.
    * `HIDDEN` Product can be only visited via direct link and purchased.
    * `PRIVATE` Product cannot be visited nor purchased.
  </Property>

  <Property name="delivery_text" type="string">
    The product delivery text, shown to customers in addition to the variant deliverables. Useful as a thank you note or offering a discount.
  </Property>

  <Property name="additional_information" type="array">
    The additional information input(s) of the product. The field supports **16 field types** organized into the following categories:

    **Text Input Fields:**

    * `text` - Single-line text input
    * `number` - Numeric input with validation
    * `email` - Email address with RFC 5321 validation
    * `phone` - Phone number with country selector and E.164 formatting
    * `currency` - Currency amount with currency selector
    * `link` - Website URL with validation
    * `textarea` - Multi-line text input

    **Selection Fields:**

    * `select` - Dropdown selection (single or multiple)
    * `radio` - Radio button group with visual variants
    * `checkbox-group` - Multiple checkbox selection with visual variants
    * `pillbox` - Tag-style multi-select with removable pills

    **Boolean Fields:**

    * `checkbox` - Single yes/no checkbox
    * `switch` - Toggle switch (on/off)

    **Date Fields:**

    * `date` - Single date picker with constraints
    * `date-range` - Date range selector with validation

    **Special:**

    * `hidden` - Hidden field not visible to customer

    Each additional\_information field supports the following properties:

    **Required Properties (all field types):**

    * `type` (string) - Field type from the list above
    * `label` (string) - Display label (2-100 characters, must be unique)
    * `required` (boolean) - Whether the field is mandatory for checkout

    **Optional Properties:**

    * `key` (string) - Custom identifier for invoice data (2-100 chars, letters/underscores only). Auto-generated from label if omitted
    * `placeholder` (string) - Placeholder text for applicable field types (2-255 characters)
    * `description` (string) - Help text displayed below the field (2-255 characters)
    * `options` (array) - Available options for selection fields (required for select, radio, checkbox-group, pillbox)
    * `variant` (string) - Visual style variant for selection fields and switch
    * `date_options` (object) - Date-specific configuration for date and date-range fields
  </Property>

  <Property name="other_settings" type="array">
    Customization settings of the product, with the following options:

    * `faq` Object containing an array of frequently asked questions to be displayed on the product page. Consists of:
      * `question` FAQ question.
      * `answer` FAQ answer.
    * `video_url` URL of a product video, will be displayed on the product page.  Supported services: YouTube, Vimeo, Dailymotion, Slideshare, Miro
    * `redirect_url` URL you want to redirect your customers to after a successful purchase. The redirect URL can utilize the following dynamic values:
      * `[order_id]` ID of the order
      * `[customer_email]` email of the customer who placed the order
    * `product_title` Meta title tag of the product, will appear in search engines and social media.
    * `product_description` Meta description tag of the product, will appear in search engines and social media.
  </Property>

  <Property name="deleted_at" type="timestamp">
    The time at which this product was deleted.
  </Property>

  <Property name="created_at" type="timestamp">
    The time at which this product was first created.
  </Property>

  <Property name="updated_at" type="timestamp">
    The time at which this product was last updated.
  </Property>

  <Property name="store_id" type="integer">
    The ID of the store this product belongs to.
  </Property>

  <Property name="category_id" type="integer">
    The ID of the category this product belongs to.
  </Property>

  <Property name="section_id" type="integer">
    The ID of the section this product belongs to.
  </Property>

  <Property name="section_order" type="integer">
    The order of the product within the section.
  </Property>

  <Property name="is_discoverable" type="integer">
    Whether the product can be discovered. One of two values:

    * `1` It can be discovered.
    * `0` It cannot be discovered.
  </Property>

  <Property name="variants" type="object">
    Variants object containing a number of variant arrays. Variant arrays consist of:

    * `id` Variant ID
    * `title` Variant title
  </Property>

  <Property name="url" type="string">
    Displays the full product URL, including storefront domain.
  </Property>
</Properties>

## Field Type Details [#field-type-details]

### Text Input Fields [#text-input-fields]

#### `text` [#text]

Single-line text input with optional placeholder.

**Supported properties:** `placeholder`, `description`
&#x2A;*Max length:** 255 characters

**Example:**

```json
{
  "type": "text",
  "label": "In-Game Username",
  "required": true,
  "placeholder": "Enter your username",
  "description": "Must match your game account"
}
```

***

#### `number` [#number]

Numeric input with range validation.

**Supported properties:** `placeholder`, `description`
&#x2A;*Range:** -9,007,199,254,740,991 to 9,007,199,254,740,991

**Example:**

```json
{
  "type": "number",
  "label": "Quantity",
  "required": true,
  "placeholder": "0"
}
```

***

#### `email` [#email]

Email input.

**Supported properties:** `placeholder`, `description`
&#x2A;*Max length:** 255 characters

**Example:**

```json
{
  "type": "email",
  "label": "Recovery Email",
  "required": false,
  "placeholder": "user@example.com",
  "description": "For account recovery"
}
```

***

#### `phone` [#phone]

Phone number input with country selector.

**Supported properties:** `description`
&#x2A;*Max length:** 25 characters
&#x2A;*Format:** Automatically normalized to E.164 (+1234567890)

**Example:**

```json
{
  "type": "phone",
  "label": "Mobile Number",
  "required": true,
  "description": "For SMS delivery notifications"
}
```

***

#### `currency` [#currency]

Currency amount with currency selector.

**Supported properties:** `description`
&#x2A;*Format:** Stores amount in minor units (cents) with currency code

**Example:**

```json
{
  "type": "currency",
  "label": "Budget",
  "required": true,
  "description": "Your maximum budget"
}
```

***

#### `link` [#link]

URL input with validation. Automatically prepends `https://` if missing.

**Supported properties:** `placeholder`, `description`
&#x2A;*Max length:** 2048 characters

**Example:**

```json
{
  "type": "link",
  "label": "Portfolio Website",
  "required": false,
  "placeholder": "https://example.com"
}
```

***

#### `textarea` [#textarea]

Multi-line text input.

**Supported properties:** `placeholder`, `description`
&#x2A;*Max length:** 2048 characters

**Example:**

```json
{
  "type": "textarea",
  "label": "Special Instructions",
  "required": false,
  "placeholder": "Enter any special requirements...",
  "description": "Tell us about customization needs"
}
```

***

### Selection Fields [#selection-fields]

Selection fields require an `options` array and support two formats:

**Simple format (string array):**

```json
"options": ["Option A", "Option B", "Option C"]
```

**Enhanced format (objects with metadata):**
Only supported for `radio`, `checkbox-group`, and `switch` (fieldset variant).

```json
"options": [
{
"label": "Basic Plan",
"value": "basic",
"description": "Perfect for individuals"
},
{
"label": "Pro Plan",
"value": "pro",
"description": "Designed for teams"
}
]
```

**Enhanced option properties:**

* `label` (required) - Display text (1-100 characters)
* `value` (optional) - Stored value (defaults to label if omitted)
* `description` (optional) - Helper text (max 255 characters, only displays in compatible variants)

***

#### `select` [#select]

Dropdown selection field.

**Supported properties:** `placeholder`, `description`, `variant`, `options` (required)
&#x2A;*Options format:** String array only

**Variants:**

* `single` (default) - Single selection
* `multiple` - Multiple selection

**Example:**

```json
{
  "type": "select",
  "label": "Preferred Region",
  "required": true,
  "variant": "single",
  "options": [
    "North America",
    "Europe",
    "Asia"
  ],
  "placeholder": "Select your region..."
}
```

***

#### `radio` [#radio]

Radio button group for single selection.

**Supported properties:** `description`, `variant` (required), `options` (required)
&#x2A;*Options format:** String array or enhanced objects (for default and cards variants)

**Variants:**

* `default` - Standard radio buttons (supports descriptions)
* `cards` - Card-style options (supports descriptions)
* `row` - Inline horizontal layout
* `pills` - Pill-shaped options
* `buttons` - Button-style options
* `segmented` - Segmented control

**Example with enhanced options:**

```json
{
  "type": "radio",
  "label": "Subscription Plan",
  "required": true,
  "variant": "cards",
  "options": [
    {
      "label": "Starter",
      "value": "starter",
      "description": "$9/month - For individuals"
    },
    {
      "label": "Pro",
      "value": "pro",
      "description": "$29/month - For teams"
    }
  ]
}
```

***

#### `checkbox-group` [#checkbox-group]

Checkbox group for multiple selections.

**Supported properties:** `description`, `variant` (required), `options` (required)
&#x2A;*Options format:** String array or enhanced objects (for default and cards variants)

**Variants:**

* `default` - Standard checkboxes (supports descriptions)
* `cards` - Card-style checkboxes (supports descriptions)
* `fieldset` - Horizontal inline group
* `pills` - Pill-shaped checkboxes
* `buttons` - Button-style checkboxes

**Example:**

```json
{
  "type": "checkbox-group",
  "label": "Add-on Services",
  "required": false,
  "variant": "default",
  "options": [
    "Gift Wrapping",
    "Express Shipping",
    "Insurance"
  ]
}
```

***

#### `pillbox` [#pillbox]

Multi-select with removable pill-shaped tags.

**Supported properties:** `placeholder`, `description`, `options` (required)
&#x2A;*Options format:** String array only

**Example:**

```json
{
  "type": "pillbox",
  "label": "Programming Languages",
  "required": true,
  "options": [
    "JavaScript",
    "Python",
    "Java",
    "Go"
  ],
  "placeholder": "Choose languages..."
}
```

***

### Boolean Fields [#boolean-fields]

#### `checkbox` [#checkbox]

Single yes/no checkbox.

**Supported properties:** `description`

**Example:**

```json
{
  "type": "checkbox",
  "label": "I agree to the Terms of Service",
  "required": true,
  "description": "You must accept to proceed"
}
```

***

#### `switch` [#switch]

Toggle switch (on/off).

**Supported properties:** `description`, `variant` (required)
&#x2A;*Options:** Only required for `fieldset` variant (supports enhanced format)

**Variants:**

* `single` - Single on/off toggle
* `fieldset` - Multiple switches in a group (requires options)

**Important:** Switch fields are typically **not required** because they represent on/off states where "off" (false) is a valid value. While you can technically set `required: true`, it rarely makes semantic sense for a toggle.

**Example - Single:**

```json
{
  "type": "switch",
  "label": "Enable Notifications",
  "required": false,
  "variant": "single"
}
```

**Example - Fieldset:**

```json
{
  "type": "switch",
  "label": "Privacy Settings",
  "required": false,
  "variant": "fieldset",
  "options": [
    {
      "label": "Profile Visibility",
      "value": "profile_public",
      "description": "Make profile public"
    },
    {
      "label": "Activity Feed",
      "value": "show_activity",
      "description": "Display recent activity"
    }
  ]
}
```

***

### Date Fields [#date-fields]

Date fields support advanced configuration via the `date_options` object:

**Common date\_options properties:**

* `min_date` (string) - Minimum date: "today" or "YYYY-MM-DD"
* `max_date` (string) - Maximum date: "today" or "YYYY-MM-DD"
* `start_day` (integer) - First day of week (0=Sunday, 1=Monday, ..., 6=Saturday, default: 1)
* `clearable` (boolean) - Show clear button (default: false)
* `week_numbers` (boolean) - Display week numbers (default: false)
* `selectable_header` (boolean) - Clickable month/year header (default: false)

**Additional properties for date-range:**

* `min_range` (integer) - Minimum range in days (≥1)
* `max_range` (integer) - Maximum range in days (≥1)
* `with_presets` (boolean) - Show preset buttons (default: false)
* `with_inputs` (boolean) - Show date inputs (default: false)
* `presets` (string) - Space-separated preset list

**Available presets:** `today`, `yesterday`, `thisWeek`, `lastWeek`, `last7Days`, `last14Days`, `last30Days`, `thisMonth`, `lastMonth`, `last3Months`, `last6Months`, `thisQuarter`, `lastQuarter`, `thisYear`, `lastYear`, `yearToDate`

***

#### `date` [#date]

Single date picker.

**Supported properties:** `placeholder`, `description`, `date_options`

**Example:**

```json
{
  "type": "date",
  "label": "Delivery Date",
  "required": true,
  "placeholder": "Select a date...",
  "date_options": {
    "min_date": "today",
    "max_date": "2025-12-31",
    "start_day": 1,
    "clearable": true
  }
}
```

***

#### `date-range` [#date-range]

Date range picker.

**Supported properties:** `placeholder`, `description`, `date_options`

**Example:**

```json
{
  "type": "date-range",
  "label": "Rental Period",
  "required": true,
  "placeholder": "Select rental period...",
  "description": "Minimum 3 days, maximum 30 days",
  "date_options": {
    "min_date": "today",
    "max_date": "2026-06-30",
    "min_range": 3,
    "max_range": 30,
    "start_day": 1,
    "clearable": true,
    "with_presets": true,
    "presets": "last7Days last14Days last30Days thisMonth"
  }
}
```

***

### Special Fields [#special-fields]

#### `hidden` [#hidden]

Hidden field not visible to customers.

**Supported properties:** None
&#x2A;*Note:** Still requires a `label` for internal identification.

**Example:**

```json
{
  "type": "hidden",
  "label": "Campaign Source",
  "required": false,
  "key": "utm_source"
}
```

***

## Validation Rules [#validation-rules]

### Field-Level Validation [#field-level-validation]

* `type` - Must be a valid field type from the supported list
* `label` - Required, 2-100 characters, must be unique, cannot use reserved names
* `required` - Required, must be boolean
* `key` - Optional, 2-100 characters, letters and underscores only, must be unique
* `placeholder` - Optional, 2-255 characters (only for supported field types)
* `description` - Optional, 2-255 characters (only for supported field types)
* `options` - Required for select, radio, checkbox-group, pillbox. Required for switch with fieldset variant
* `variant` - Required for select, radio, checkbox-group, switch. Must be valid variant for the field type

### Reserved Field Labels [#reserved-field-labels]

These labels are reserved and cannot be used:

* `purchase_quantity`
* `customer_email`
* `payment_method`
* `extra`

### Options Validation [#options-validation]

**String options:**

* Each option: 1-100 characters

**Enhanced options (objects):**

* `label` - Required, 1-100 characters
* `value` - Optional, 1-100 characters (defaults to label)
* `description` - Optional, max 255 characters

### Date Options Validation [#date-options-validation]

* `min_date` / `max_date` - Must be "today" or valid `YYYY-MM-DD` format
* `min_date` must be ≤ `max_date` when both are specific dates
* `start_day` - Integer 0-6
* `min_range` / `max_range` - Positive integers ≥1
* `min_range` must be ≤ `max_range`
* Boolean options must be `true` or `false`
* `presets` - Space-separated string of valid preset values

***


# List all products (/docs/api/products/list-all-products)

This endpoint allows you to retrieve a paginated list of all your products. By default, a maximum of fifteen products are shown per page.

## Endpoint

- Method: `GET`

- Path: `/v2/products`

- Full URL: `https://sell.app/api/v2/products`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
- `limit` (`integer`, optional): Limit the number of blacklist rules returned.
- `page` (`integer`, optional): The page number you are attempting to access.
- `with_drafts` (`boolean`, optional): Include draft products alongside published products.
- `only_drafts` (`boolean`, optional): Return only draft products.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "images": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "path": {
                  "type": "string"
                },
                "metadata": {
                  "type": "object",
                  "properties": {
                    "size": {
                      "type": "integer"
                    },
                    "filename": {
                      "type": "string"
                    },
                    "extension": {
                      "type": "string"
                    },
                    "mime_type": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "size",
                    "filename",
                    "extension",
                    "mime_type"
                  ]
                }
              },
              "required": [
                "path",
                "metadata"
              ]
            }
          },
          "order": {
            "type": "integer"
          },
          "visibility": {
            "type": "string"
          },
          "delivery_text": {
            "type": "string"
          },
          "additional_information": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "required": {
                  "type": "boolean"
                },
                "key": {
                  "type": "string"
                },
                "type": {
                  "type": "string"
                },
                "label": {
                  "type": "string"
                }
              },
              "required": [
                "required",
                "key",
                "type",
                "label"
              ]
            }
          },
          "other_settings": {
            "type": "object",
            "properties": {
              "faq": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "answer": {
                      "type": "string"
                    },
                    "question": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "answer",
                    "question"
                  ]
                }
              },
              "video_url": {
                "type": "string"
              },
              "redirect_url": {
                "type": "string"
              },
              "product_title": {
                "type": "string"
              },
              "product_description": {
                "type": "string"
              }
            },
            "required": [
              "faq",
              "video_url",
              "redirect_url",
              "product_title",
              "product_description"
            ]
          },
          "deleted_at": {
            "type": "null"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "store_id": {
            "type": "integer"
          },
          "category_id": {
            "type": "null"
          },
          "section_id": {
            "type": "null"
          },
          "section_order": {
            "type": "null"
          },
          "is_discoverable": {
            "type": "integer"
          },
          "variants": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "integer"
                },
                "title": {
                  "type": "string"
                }
              },
              "required": [
                "id",
                "title"
              ]
            }
          },
          "url": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "title",
          "slug",
          "description",
          "images",
          "order",
          "visibility",
          "delivery_text",
          "additional_information",
          "other_settings",
          "deleted_at",
          "created_at",
          "updated_at",
          "store_id",
          "category_id",
          "section_id",
          "section_order",
          "is_discoverable",
          "variants",
          "url"
        ]
      }
    },
    "links": {
      "type": "object",
      "properties": {}
    },
    "meta": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "data",
    "links",
    "meta"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "title": "Elixir of immortality",
      "slug": "elixir-of-immortality",
      "description": "<p>Want to live forever? Buy this now and I'll send a digital elixir that converts your soul into an NFT that will roam the internet for eternity!</p>",
      "images": [
        {
          "path": "store/1/listings/NM6TBKIMzpFJq1MKTV24oMJ1W4UrKCo7NS98nt4K.png",
          "metadata": {
            "size": 39289,
            "filename": "NM6TBKIMzpFJq1MKTV24oMJ1W4UrKCo7NS98nt4K",
            "extension": "png",
            "mime_type": "image/png"
          }
        },
        {
          "path": "store/1/listings/ov6XMb68tRr80zl7sqfN1or7xfqqH5WbZygDEQ8X.png",
          "metadata": {
            "size": 422373,
            "filename": "ov6XMb68tRr80zl7sqfN1or7xfqqH5WbZygDEQ8X",
            "extension": "png",
            "mime_type": "image/png"
          }
        }
      ],
      "order": 1,
      "visibility": "PUBLIC",
      "delivery_text": "Thanks again bud!",
      "additional_information": [
        {
          "required": true,
          "key": "3aecffd000e00e2211e94558007ffc37",
          "type": "checkbox",
          "label": "Do you agree to handing your soul over?"
        }
      ],
      "other_settings": {
        "faq": [
          {
            "answer": "Yes, trust me!",
            "question": "Will I really live forever?"
          }
        ],
        "video_url": "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
        "redirect_url": "https://666.com/transfer-soul?customer_email=[customer_email]&order_id=[order_id]",
        "product_title": "The real elixir of immortality",
        "product_description": "Live forever, online."
      },
      "deleted_at": null,
      "created_at": "2024-01-09T22:56:49.000000Z",
      "updated_at": "2024-01-10T10:00:28.000000Z",
      "store_id": 1,
      "category_id": null,
      "section_id": null,
      "section_order": null,
      "is_discoverable": 1,
      "variants": [
        {
          "id": 1,
          "title": "Default"
        }
      ],
      "url": "https://example.sell.app/product/elixir-of-immortality"
    }
  ],
  "links": {},
  "meta": {}
}
```

# Retrieve a product (/docs/api/products/retrieve-a-product)

This endpoint allows you to retrieve a specific product by providing the unique identifier. Refer to [the list](/api/products#the-product-model) to see which properties are included with product objects.

## Endpoint

- Method: `GET`

- Path: `/v2/products/{product}`

- Full URL: `https://sell.app/api/v2/products/{product}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `product` (`integer`, required): The product path parameter.

## Query Parameters
- `with_drafts` (`boolean`, optional): Include draft products alongside published products.
- `only_drafts` (`boolean`, optional): Return only draft products.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "title": {
          "type": "string"
        },
        "slug": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "images": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "path": {
                "type": "string"
              },
              "metadata": {
                "type": "object",
                "properties": {
                  "size": {
                    "type": "integer"
                  },
                  "filename": {
                    "type": "string"
                  },
                  "extension": {
                    "type": "string"
                  },
                  "mime_type": {
                    "type": "string"
                  }
                },
                "required": [
                  "size",
                  "filename",
                  "extension",
                  "mime_type"
                ]
              }
            },
            "required": [
              "path",
              "metadata"
            ]
          }
        },
        "order": {
          "type": "integer"
        },
        "visibility": {
          "type": "string"
        },
        "delivery_text": {
          "type": "string"
        },
        "additional_information": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "required": {
                "type": "boolean"
              },
              "key": {
                "type": "string"
              },
              "type": {
                "type": "string"
              },
              "label": {
                "type": "string"
              }
            },
            "required": [
              "required",
              "key",
              "type",
              "label"
            ]
          }
        },
        "other_settings": {
          "type": "object",
          "properties": {
            "faq": {
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "answer": {
                    "type": "string"
                  },
                  "question": {
                    "type": "string"
                  }
                },
                "required": [
                  "answer",
                  "question"
                ]
              }
            },
            "video_url": {
              "type": "string"
            },
            "redirect_url": {
              "type": "string"
            },
            "product_title": {
              "type": "string"
            },
            "product_description": {
              "type": "string"
            }
          },
          "required": [
            "faq",
            "video_url",
            "redirect_url",
            "product_title",
            "product_description"
          ]
        },
        "deleted_at": {
          "type": "null"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "store_id": {
          "type": "integer"
        },
        "category_id": {
          "type": "null"
        },
        "section_id": {
          "type": "null"
        },
        "section_order": {
          "type": "null"
        },
        "is_discoverable": {
          "type": "integer"
        },
        "variants": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "id": {
                "type": "integer"
              },
              "title": {
                "type": "string"
              }
            },
            "required": [
              "id",
              "title"
            ]
          }
        },
        "url": {
          "type": "string"
        }
      },
      "required": [
        "id",
        "title",
        "slug",
        "description",
        "images",
        "order",
        "visibility",
        "delivery_text",
        "additional_information",
        "other_settings",
        "deleted_at",
        "created_at",
        "updated_at",
        "store_id",
        "category_id",
        "section_id",
        "section_order",
        "is_discoverable",
        "variants",
        "url"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "title": "Elixir of immortality",
    "slug": "elixir-of-immortality",
    "description": "<p>Want to live forever? Buy this now and I'll send a digital elixir that converts your soul into an NFT that will roam the internet for eternity!</p>",
    "images": [
      {
        "path": "store/1/listings/NM6TBKIMzpFJq1MKTV24oMJ1W4UrKCo7NS98nt4K.png",
        "metadata": {
          "size": 39289,
          "filename": "NM6TBKIMzpFJq1MKTV24oMJ1W4UrKCo7NS98nt4K",
          "extension": "png",
          "mime_type": "image/png"
        }
      },
      {
        "path": "store/1/listings/ov6XMb68tRr80zl7sqfN1or7xfqqH5WbZygDEQ8X.png",
        "metadata": {
          "size": 422373,
          "filename": "ov6XMb68tRr80zl7sqfN1or7xfqqH5WbZygDEQ8X",
          "extension": "png",
          "mime_type": "image/png"
        }
      }
    ],
    "order": 1,
    "visibility": "PUBLIC",
    "delivery_text": "Thanks again bud!",
    "additional_information": [
      {
        "required": true,
        "key": "3aecffd000e00e2211e94558007ffc37",
        "type": "checkbox",
        "label": "Do you agree to handing your soul over?"
      }
    ],
    "other_settings": {
      "faq": [
        {
          "answer": "Yes, trust me!",
          "question": "Will I really live forever?"
        }
      ],
      "video_url": "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
      "redirect_url": "https://666.com/transfer-soul?customer_email=[customer_email]&order_id=[order_id]",
      "product_title": "The real elixir of immortality",
      "product_description": "Live forever, online."
    },
    "deleted_at": null,
    "created_at": "2024-01-09T22:56:49.000000Z",
    "updated_at": "2024-01-10T10:00:28.000000Z",
    "store_id": 1,
    "category_id": null,
    "section_id": null,
    "section_order": null,
    "is_discoverable": 1,
    "variants": [
      {
        "id": 1,
        "title": "Default"
      }
    ],
    "url": "https://example.sell.app/product/elixir-of-immortality"
  }
}
```

# Search products (/docs/api/products/search-products)

Search products with filters, search terms, includes, and sort instructions in a JSON request body.

## Endpoint

- Method: `POST`

- Path: `/v2/products/search`

- Full URL: `https://sell.app/api/v2/products/search`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "filters": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "field": {
            "type": "string"
          },
          "operator": {
            "type": "string",
            "default": "="
          },
          "value": {},
          "type": {
            "type": "string",
            "enum": [
              "and",
              "or"
            ],
            "default": "and"
          },
          "nested": {
            "type": "array",
            "items": {
              "type": "object",
              "additionalProperties": true
            }
          }
        },
        "required": [
          "field"
        ]
      }
    },
    "sort": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "field": {
            "type": "string"
          },
          "direction": {
            "type": "string",
            "enum": [
              "asc",
              "desc"
            ],
            "default": "asc"
          }
        },
        "required": [
          "field"
        ]
      }
    },
    "search": {
      "type": "object",
      "properties": {
        "value": {
          "type": [
            "string",
            "null"
          ]
        },
        "case_sensitive": {
          "type": "boolean"
        }
      }
    },
    "includes": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "relation": {
            "type": "string"
          }
        },
        "required": [
          "relation"
        ]
      }
    }
  }
}
```

Example:

```json
{
  "filters": [
    {
      "field": "id",
      "operator": "=",
      "value": 1
    }
  ],
  "sort": [
    {
      "field": "created_at",
      "direction": "desc"
    }
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "images": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "path": {
                  "type": "string"
                },
                "metadata": {
                  "type": "object",
                  "properties": {
                    "size": {
                      "type": "integer"
                    },
                    "filename": {
                      "type": "string"
                    },
                    "extension": {
                      "type": "string"
                    },
                    "mime_type": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "size",
                    "filename",
                    "extension",
                    "mime_type"
                  ]
                }
              },
              "required": [
                "path",
                "metadata"
              ]
            }
          },
          "order": {
            "type": "integer"
          },
          "visibility": {
            "type": "string"
          },
          "delivery_text": {
            "type": "string"
          },
          "additional_information": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "required": {
                  "type": "boolean"
                },
                "key": {
                  "type": "string"
                },
                "type": {
                  "type": "string"
                },
                "label": {
                  "type": "string"
                }
              },
              "required": [
                "required",
                "key",
                "type",
                "label"
              ]
            }
          },
          "other_settings": {
            "type": "object",
            "properties": {
              "faq": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "answer": {
                      "type": "string"
                    },
                    "question": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "answer",
                    "question"
                  ]
                }
              },
              "video_url": {
                "type": "string"
              },
              "redirect_url": {
                "type": "string"
              },
              "product_title": {
                "type": "string"
              },
              "product_description": {
                "type": "string"
              }
            },
            "required": [
              "faq",
              "video_url",
              "redirect_url",
              "product_title",
              "product_description"
            ]
          },
          "deleted_at": {
            "type": "null"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "store_id": {
            "type": "integer"
          },
          "category_id": {
            "type": "null"
          },
          "section_id": {
            "type": "null"
          },
          "section_order": {
            "type": "null"
          },
          "is_discoverable": {
            "type": "integer"
          },
          "variants": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "integer"
                },
                "title": {
                  "type": "string"
                }
              },
              "required": [
                "id",
                "title"
              ]
            }
          },
          "url": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "title",
          "slug",
          "description",
          "images",
          "order",
          "visibility",
          "delivery_text",
          "additional_information",
          "other_settings",
          "deleted_at",
          "created_at",
          "updated_at",
          "store_id",
          "category_id",
          "section_id",
          "section_order",
          "is_discoverable",
          "variants",
          "url"
        ]
      }
    },
    "links": {
      "type": "object",
      "properties": {}
    },
    "meta": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "data",
    "links",
    "meta"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "title": "Elixir of immortality",
      "slug": "elixir-of-immortality",
      "description": "<p>Want to live forever? Buy this now and I'll send a digital elixir that converts your soul into an NFT that will roam the internet for eternity!</p>",
      "images": [
        {
          "path": "store/1/listings/NM6TBKIMzpFJq1MKTV24oMJ1W4UrKCo7NS98nt4K.png",
          "metadata": {
            "size": 39289,
            "filename": "NM6TBKIMzpFJq1MKTV24oMJ1W4UrKCo7NS98nt4K",
            "extension": "png",
            "mime_type": "image/png"
          }
        },
        {
          "path": "store/1/listings/ov6XMb68tRr80zl7sqfN1or7xfqqH5WbZygDEQ8X.png",
          "metadata": {
            "size": 422373,
            "filename": "ov6XMb68tRr80zl7sqfN1or7xfqqH5WbZygDEQ8X",
            "extension": "png",
            "mime_type": "image/png"
          }
        }
      ],
      "order": 1,
      "visibility": "PUBLIC",
      "delivery_text": "Thanks again bud!",
      "additional_information": [
        {
          "required": true,
          "key": "3aecffd000e00e2211e94558007ffc37",
          "type": "checkbox",
          "label": "Do you agree to handing your soul over?"
        }
      ],
      "other_settings": {
        "faq": [
          {
            "answer": "Yes, trust me!",
            "question": "Will I really live forever?"
          }
        ],
        "video_url": "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
        "redirect_url": "https://666.com/transfer-soul?customer_email=[customer_email]&order_id=[order_id]",
        "product_title": "The real elixir of immortality",
        "product_description": "Live forever, online."
      },
      "deleted_at": null,
      "created_at": "2024-01-09T22:56:49.000000Z",
      "updated_at": "2024-01-10T10:00:28.000000Z",
      "store_id": 1,
      "category_id": null,
      "section_id": null,
      "section_order": null,
      "is_discoverable": 1,
      "variants": [
        {
          "id": 1,
          "title": "Default"
        }
      ],
      "url": "https://example.sell.app/product/elixir-of-immortality"
    }
  ],
  "links": {},
  "meta": {}
}
```

# Update a product (/docs/api/products/update-a-product)

Update a product's details with the following endpoint.

## Endpoint

- Method: `PATCH`

- Path: `/v2/products/{product}`

- Full URL: `https://sell.app/api/v2/products/{product}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `product` (`integer`, required): The product path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "title": {
      "type": "string"
    },
    "description": {
      "type": "string"
    },
    "visibility": {
      "type": "string",
      "enum": [
        "PUBLIC",
        "ON_HOLD",
        "HIDDEN",
        "PRIVATE"
      ]
    },
    "slug": {
      "type": "string"
    },
    "section": {
      "type": [
        "integer",
        "null"
      ]
    },
    "additional_information": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "text",
              "number",
              "email",
              "phone",
              "currency",
              "link",
              "textarea",
              "select",
              "radio",
              "checkbox-group",
              "pillbox",
              "checkbox",
              "switch",
              "date",
              "date-range",
              "hidden"
            ]
          },
          "required": {
            "type": "boolean"
          },
          "label": {
            "type": "string"
          },
          "key": {
            "type": "string"
          },
          "options": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "placeholder": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "variant": {
            "type": "string"
          },
          "date_options": {
            "type": "object",
            "additionalProperties": true
          }
        },
        "required": [
          "type",
          "required",
          "label"
        ]
      }
    },
    "other_settings": {
      "type": "object",
      "properties": {
        "redirect_url": {
          "type": "string",
          "format": "uri"
        },
        "video_url": {
          "type": "string",
          "format": "uri"
        },
        "product_title": {
          "type": "string"
        },
        "product_description": {
          "type": "string"
        },
        "faq": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "question": {
                "type": "string"
              },
              "answer": {
                "type": "string"
              }
            },
            "required": [
              "question",
              "answer"
            ]
          }
        }
      }
    }
  }
}
```

### Content Type: `multipart/form-data`

Schema:

```json
{
  "type": "object",
  "properties": {
    "title": {
      "type": "string"
    },
    "description": {
      "type": "string"
    },
    "visibility": {
      "type": "string",
      "enum": [
        "PUBLIC",
        "ON_HOLD",
        "HIDDEN",
        "PRIVATE"
      ]
    },
    "slug": {
      "type": "string"
    },
    "section": {
      "type": [
        "integer",
        "null"
      ]
    },
    "additional_information": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "text",
              "number",
              "email",
              "phone",
              "currency",
              "link",
              "textarea",
              "select",
              "radio",
              "checkbox-group",
              "pillbox",
              "checkbox",
              "switch",
              "date",
              "date-range",
              "hidden"
            ]
          },
          "required": {
            "type": "boolean"
          },
          "label": {
            "type": "string"
          },
          "key": {
            "type": "string"
          },
          "options": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "placeholder": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "variant": {
            "type": "string"
          },
          "date_options": {
            "type": "object",
            "additionalProperties": true
          }
        },
        "required": [
          "type",
          "required",
          "label"
        ]
      }
    },
    "other_settings": {
      "type": "object",
      "properties": {
        "redirect_url": {
          "type": "string",
          "format": "uri"
        },
        "video_url": {
          "type": "string",
          "format": "uri"
        },
        "product_title": {
          "type": "string"
        },
        "product_description": {
          "type": "string"
        },
        "faq": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "question": {
                "type": "string"
              },
              "answer": {
                "type": "string"
              }
            },
            "required": [
              "question",
              "answer"
            ]
          }
        }
      }
    },
    "images": {
      "type": "array",
      "items": {
        "type": "string",
        "format": "binary"
      },
      "maxItems": 4
    }
  }
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "title": {
          "type": "string"
        },
        "slug": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "images": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "path": {
                "type": "string"
              },
              "metadata": {
                "type": "object",
                "properties": {
                  "size": {
                    "type": "integer"
                  },
                  "filename": {
                    "type": "string"
                  },
                  "extension": {
                    "type": "string"
                  },
                  "mime_type": {
                    "type": "string"
                  }
                },
                "required": [
                  "size",
                  "filename",
                  "extension",
                  "mime_type"
                ]
              }
            },
            "required": [
              "path",
              "metadata"
            ]
          }
        },
        "order": {
          "type": "integer"
        },
        "visibility": {
          "type": "string"
        },
        "delivery_text": {
          "type": "string"
        },
        "additional_information": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "required": {
                "type": "boolean"
              },
              "key": {
                "type": "string"
              },
              "type": {
                "type": "string"
              },
              "label": {
                "type": "string"
              }
            },
            "required": [
              "required",
              "key",
              "type",
              "label"
            ]
          }
        },
        "other_settings": {
          "type": "object",
          "properties": {
            "faq": {
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "answer": {
                    "type": "string"
                  },
                  "question": {
                    "type": "string"
                  }
                },
                "required": [
                  "answer",
                  "question"
                ]
              }
            },
            "video_url": {
              "type": "string"
            },
            "redirect_url": {
              "type": "string"
            },
            "product_title": {
              "type": "string"
            },
            "product_description": {
              "type": "string"
            }
          },
          "required": [
            "faq",
            "video_url",
            "redirect_url",
            "product_title",
            "product_description"
          ]
        },
        "deleted_at": {
          "type": "null"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "store_id": {
          "type": "integer"
        },
        "category_id": {
          "type": "null"
        },
        "section_id": {
          "type": "null"
        },
        "section_order": {
          "type": "null"
        },
        "is_discoverable": {
          "type": "integer"
        },
        "variants": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "url": {
          "type": "string"
        }
      },
      "required": [
        "id",
        "title",
        "slug",
        "description",
        "images",
        "order",
        "visibility",
        "delivery_text",
        "additional_information",
        "other_settings",
        "deleted_at",
        "created_at",
        "updated_at",
        "store_id",
        "category_id",
        "section_id",
        "section_order",
        "is_discoverable",
        "variants",
        "url"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 2,
    "title": "Immortality Elixir",
    "slug": "immortality-elixir",
    "description": "Updated Description",
    "images": [
      {
        "path": "store/1/listings/qXZHzR15vs09zbfn3yui5jO6QK0IbQP4M6QVydUn.png",
        "metadata": {
          "size": 39289,
          "filename": "qXZHzR15vs09zbfn3yui5jO6QK0IbQP4M6QVydUn",
          "extension": "png",
          "mime_type": "image/png"
        }
      }
    ],
    "order": 2,
    "visibility": "PUBLIC",
    "delivery_text": "Thanks for purchasing! Here is a 20% off coupon for your next purchase: 20FREE24",
    "additional_information": [
      {
        "required": true,
        "key": "5ebae238c0afae7f4a4b96b30ff6f34c",
        "type": "checkbox",
        "label": "I agree to handing over my soul"
      }
    ],
    "other_settings": {
      "faq": [
        {
          "answer": "Yes, trust me!",
          "question": "Will I really live forever?"
        }
      ],
      "video_url": "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
      "redirect_url": "https://666.com/transfer-soul?customer_email=[customer_email]&order_id=[order_id]",
      "product_title": "The real elixir of immortality",
      "product_description": "Live forever, online."
    },
    "deleted_at": null,
    "created_at": "2024-01-10T12:16:10.000000Z",
    "updated_at": "2024-01-10T12:16:10.000000Z",
    "store_id": 1,
    "category_id": null,
    "section_id": null,
    "section_order": null,
    "is_discoverable": 1,
    "variants": [],
    "url": "https://example.sell.app/product/immortality-elixir"
  }
}
```

# Overview (/docs/api/tickets)



Tickets are a way to communicate with visitors and customers alike. They help answer questions from potential customers, and streamline post-purchase conversations with existing customers.

On this page, we'll dive into the different ticket endpoints you can use to manage tickets programmatically. We'll look at how to query and reply to tickets.

## Endpoints [#endpoints]

* [List all tickets](/api/tickets/list-all-tickets)
* [Search tickets](/api/tickets/search-tickets)
* [Retrieve specific ticket](/api/tickets/retrieve-specific-ticket)
* [List all ticket messages](/api/tickets/list-all-ticket-messages)
* [Search ticket messages](/api/tickets/search-ticket-messages)
* [Reply to ticket](/api/tickets/reply-to-ticket)
* [Retrieve specific ticket message](/api/tickets/retrieve-specific-ticket-message)

## The ticket model [#the-ticket-model]

The ticket model contains all the information about your store's tickets, including the ticket's title, status, and customer details.

### Properties [#properties]

<Properties>
  <Property name="id" type="integer">
    The unique identifier for the ticket.
  </Property>

  <Property name="title" type="string">
    The title of the ticket.
  </Property>

  <Property name="status" type="string">
    The ticket status. One of two statuses:

    * `OPEN`
    * `CLOSED`
  </Property>

  <Property name="customer" type="array">
    Array of customer details consisting of two types of information:

    * `id`: Unique customer identifier
    * `email`: Email associated to the customer's ticket.
  </Property>

  <Property name="reference" type="array">
    Array of order details if ticket is associated with an order. Consists of two types of information:

    * `id`: Order ID
    * `type`: Order model
  </Property>

  <Property name="created_at" type="timestamp">
    The time at which this ticket was first created.
  </Property>

  <Property name="updated_at" type="timestamp">
    The time at which this ticket was last updated.
  </Property>

  <Property name="store_id" type="integer">
    The ID of the store this ticket belongs to.
  </Property>

  <Property name="read_by" type="integer">
    The ID of the user who read the ticket last.
  </Property>

  <Property name="archived" type="integer">
    Whether the ticket has been archived, one of two:

    * `1`: Ticket is archived.
    * `0`: Ticket is not archived.
  </Property>
</Properties>

## The ticket message model [#the-ticket-message-model]

A ticket has many messages. Each ticket message model contains all the information about that specific message, including the ticket's author, content, and ticket ID.

### Properties [#properties-1]

<Properties>
  <Property name="id" type="integer">
    The unique identifier for the ticket message.
  </Property>

  <Property name="author" type="string">
    The author of the ticket message. One of two statuses:

    * `STORE`
    * `CUSTOMER`
  </Property>

  <Property name="sender" type="string">
    The details of the ticket message sender. One of two possibilities:

    * Username: For users logged into SellApp.
    * Email: For users not logged into SellApp.
  </Property>

  <Property name="content" type="string">
    The ticket message content; the actual message that is sent.
  </Property>

  <Property name="created_at" type="timestamp">
    The time at which this ticket was first created.
  </Property>

  <Property name="updated_at" type="timestamp">
    The time at which this ticket was last updated.
  </Property>

  <Property name="ticket_id" type="integer">
    The ID of the ticket this ticket message belongs to.
  </Property>
</Properties>

***


# List all ticket messages (/docs/api/tickets/list-all-ticket-messages)

This endpoint allows you to retrieve a paginated list of all your ticket messages within a specific ticket received. By default, a maximum of fifteen ticket messages are shown per page.

## Endpoint

- Method: `GET`

- Path: `/v1/tickets/{ticket}/messages`

- Full URL: `https://sell.app/api/v1/tickets/{ticket}/messages`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `ticket` (`integer`, required): The ticket path parameter.

## Query Parameters
- `limit` (`integer`, optional): Limit the number of blacklist rules returned.
- `page` (`integer`, optional): The page number you are attempting to access.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "author": {
            "type": "string"
          },
          "sender": {
            "type": "string"
          },
          "content": {
            "type": "string"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "ticket_id": {
            "type": "integer"
          }
        },
        "required": [
          "id",
          "author",
          "sender",
          "content",
          "created_at",
          "updated_at",
          "ticket_id"
        ]
      }
    },
    "links": {
      "type": "object",
      "properties": {}
    },
    "meta": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "data",
    "links",
    "meta"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "author": "CUSTOMER",
      "sender": "e@x.com",
      "content": "Hi. I want to buy sell app. do you accept doge?",
      "created_at": "2022-12-12T12:12:12.000000Z",
      "updated_at": "2022-12-12T12:12:12.000000Z",
      "ticket_id": 1
    }
  ],
  "links": {},
  "meta": {}
}
```

# List all tickets (/docs/api/tickets/list-all-tickets)

This endpoint allows you to retrieve a paginated list of all your tickets received. By default, a maximum of fifteen tickets are shown per page.

## Endpoint

- Method: `GET`

- Path: `/v1/tickets`

- Full URL: `https://sell.app/api/v1/tickets`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
- `limit` (`integer`, optional): Limit the number of blacklist rules returned.
- `page` (`integer`, optional): The page number you are attempting to access.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          },
          "status": {
            "type": "string"
          },
          "customer": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "email": {
                "type": "string"
              }
            },
            "required": [
              "id",
              "email"
            ]
          },
          "reference": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "store_id": {
            "type": "integer"
          },
          "read_by": {
            "type": "integer"
          },
          "archived": {
            "type": "integer"
          }
        },
        "required": [
          "id",
          "title",
          "status",
          "customer",
          "reference",
          "created_at",
          "updated_at",
          "store_id",
          "read_by",
          "archived"
        ]
      }
    },
    "links": {
      "type": "object",
      "properties": {}
    },
    "meta": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "data",
    "links",
    "meta"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "title": "acquisition.",
      "status": "OPEN",
      "customer": {
        "id": "cfbbf27a-0595-3234-953d-5f6629fccc9d",
        "email": "e@x.com"
      },
      "reference": [],
      "created_at": "2022-12-12T12:12:12.000000Z",
      "updated_at": "2022-12-12T12:12:12.000000Z",
      "store_id": 1,
      "read_by": 1,
      "archived": 0
    }
  ],
  "links": {},
  "meta": {}
}
```

# Reply to ticket (/docs/api/tickets/reply-to-ticket)

This endpoint allows you to add a reply to a given ticket.

## Endpoint

- Method: `POST`

- Path: `/v1/tickets/{ticket}/messages`

- Full URL: `https://sell.app/api/v1/tickets/{ticket}/messages`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `ticket` (`integer`, required): The ticket path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "content": {
      "type": "string"
    }
  },
  "required": [
    "content"
  ]
}
```

Example:

```json
{
  "content": "Hey thanks for reaching out but we do not accept doge."
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "author": {
          "type": "string"
        },
        "sender": {
          "type": "null"
        },
        "content": {
          "type": "string"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "ticket_id": {
          "type": "integer"
        }
      },
      "required": [
        "id",
        "author",
        "sender",
        "content",
        "created_at",
        "updated_at",
        "ticket_id"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 2,
    "author": "STORE",
    "sender": null,
    "content": "Hey thanks for reaching out but we do not accept doge.",
    "created_at": "2022-12-12T12:12:12.000000Z",
    "updated_at": "2022-12-12T12:12:12.000000Z",
    "ticket_id": 1
  }
}
```

# Retrieve specific ticket message (/docs/api/tickets/retrieve-specific-ticket-message)

This endpoint allows you to retrieve a specific ticket message by providing the unique identifier. Refer to [the list](/api/tickets#the-ticket-message-model) to see which properties are included with ticket message objects.

## Endpoint

- Method: `GET`

- Path: `/v1/tickets/{ticket}/messages/{message}`

- Full URL: `https://sell.app/api/v1/tickets/{ticket}/messages/{message}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `ticket` (`integer`, required): The ticket path parameter.
- `message` (`integer`, required): The message path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "author": {
          "type": "string"
        },
        "sender": {
          "type": "null"
        },
        "content": {
          "type": "string"
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "ticket_id": {
          "type": "integer"
        }
      },
      "required": [
        "id",
        "author",
        "sender",
        "content",
        "created_at",
        "updated_at",
        "ticket_id"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 2,
    "author": "STORE",
    "sender": null,
    "content": "Hey thanks for reaching out but we do not accept doge.",
    "created_at": "2022-12-12T12:12:12.000000Z",
    "updated_at": "2022-12-12T12:12:12.000000Z",
    "ticket_id": 1
  }
}
```

# Retrieve specific ticket (/docs/api/tickets/retrieve-specific-ticket)

This endpoint allows you to retrieve a specific ticket by providing the unique identifier. Refer to [the list](/api/tickets#the-ticket-model) to see which properties are included with ticket objects.

## Endpoint

- Method: `GET`

- Path: `/v1/tickets/{ticket}`

- Full URL: `https://sell.app/api/v1/tickets/{ticket}`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `ticket` (`integer`, required): The ticket path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body
No request body.

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "title": {
          "type": "string"
        },
        "status": {
          "type": "string"
        },
        "customer": {
          "type": "object",
          "properties": {
            "id": {
              "type": "string"
            },
            "email": {
              "type": "string"
            }
          },
          "required": [
            "id",
            "email"
          ]
        },
        "reference": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        },
        "store_id": {
          "type": "integer"
        },
        "read_by": {
          "type": "integer"
        },
        "archived": {
          "type": "integer"
        }
      },
      "required": [
        "id",
        "title",
        "status",
        "customer",
        "reference",
        "created_at",
        "updated_at",
        "store_id",
        "read_by",
        "archived"
      ]
    }
  },
  "required": [
    "data"
  ]
}
```

Example:

```json
{
  "data": {
    "id": 1,
    "title": "acquisition.",
    "status": "OPEN",
    "customer": {
      "id": "cfbbf27a-0595-3234-953d-5f6629fccc9d",
      "email": "e@x.com"
    },
    "reference": [],
    "created_at": "2022-12-12T12:12:12.000000Z",
    "updated_at": "2022-12-12T12:12:12.000000Z",
    "store_id": 1,
    "read_by": 1,
    "archived": 0
  }
}
```

# Search ticket messages (/docs/api/tickets/search-ticket-messages)

Search a ticket's messages with filters, search terms, includes, and sort instructions in a JSON request body.

## Endpoint

- Method: `POST`

- Path: `/v1/tickets/{ticket}/messages/search`

- Full URL: `https://sell.app/api/v1/tickets/{ticket}/messages/search`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
- `ticket` (`integer`, required): The ticket path parameter.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "filters": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "field": {
            "type": "string"
          },
          "operator": {
            "type": "string",
            "default": "="
          },
          "value": {},
          "type": {
            "type": "string",
            "enum": [
              "and",
              "or"
            ],
            "default": "and"
          },
          "nested": {
            "type": "array",
            "items": {
              "type": "object",
              "additionalProperties": true
            }
          }
        },
        "required": [
          "field"
        ]
      }
    },
    "sort": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "field": {
            "type": "string"
          },
          "direction": {
            "type": "string",
            "enum": [
              "asc",
              "desc"
            ],
            "default": "asc"
          }
        },
        "required": [
          "field"
        ]
      }
    },
    "search": {
      "type": "object",
      "properties": {
        "value": {
          "type": [
            "string",
            "null"
          ]
        },
        "case_sensitive": {
          "type": "boolean"
        }
      }
    },
    "includes": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "relation": {
            "type": "string"
          }
        },
        "required": [
          "relation"
        ]
      }
    }
  }
}
```

Example:

```json
{
  "filters": [
    {
      "field": "id",
      "operator": "=",
      "value": 1
    }
  ],
  "sort": [
    {
      "field": "created_at",
      "direction": "desc"
    }
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "author": {
            "type": "string"
          },
          "sender": {
            "type": "string"
          },
          "content": {
            "type": "string"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "ticket_id": {
            "type": "integer"
          }
        },
        "required": [
          "id",
          "author",
          "sender",
          "content",
          "created_at",
          "updated_at",
          "ticket_id"
        ]
      }
    },
    "links": {
      "type": "object",
      "properties": {}
    },
    "meta": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "data",
    "links",
    "meta"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "author": "CUSTOMER",
      "sender": "e@x.com",
      "content": "Hi. I want to buy sell app. do you accept doge?",
      "created_at": "2022-12-12T12:12:12.000000Z",
      "updated_at": "2022-12-12T12:12:12.000000Z",
      "ticket_id": 1
    }
  ],
  "links": {},
  "meta": {}
}
```

# Search tickets (/docs/api/tickets/search-tickets)

Search tickets with filters, search terms, includes, and sort instructions in a JSON request body.

## Endpoint

- Method: `POST`

- Path: `/v1/tickets/search`

- Full URL: `https://sell.app/api/v1/tickets/search`

- Authentication: `Bearer` token required

## Code Samples

- Available languages: `curl`, `JavaScript`, `Go`, `Python`, `Java`, `C#`.

- PHP code samples are not generated for this API reference.

## Path Parameters
None.

## Query Parameters
None.

## Header Parameters
None.

## Request Body

- Required: Yes

### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "filters": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "field": {
            "type": "string"
          },
          "operator": {
            "type": "string",
            "default": "="
          },
          "value": {},
          "type": {
            "type": "string",
            "enum": [
              "and",
              "or"
            ],
            "default": "and"
          },
          "nested": {
            "type": "array",
            "items": {
              "type": "object",
              "additionalProperties": true
            }
          }
        },
        "required": [
          "field"
        ]
      }
    },
    "sort": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "field": {
            "type": "string"
          },
          "direction": {
            "type": "string",
            "enum": [
              "asc",
              "desc"
            ],
            "default": "asc"
          }
        },
        "required": [
          "field"
        ]
      }
    },
    "search": {
      "type": "object",
      "properties": {
        "value": {
          "type": [
            "string",
            "null"
          ]
        },
        "case_sensitive": {
          "type": "boolean"
        }
      }
    },
    "includes": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "relation": {
            "type": "string"
          }
        },
        "required": [
          "relation"
        ]
      }
    }
  }
}
```

Example:

```json
{
  "filters": [
    {
      "field": "id",
      "operator": "=",
      "value": 1
    }
  ],
  "sort": [
    {
      "field": "created_at",
      "direction": "desc"
    }
  ]
}
```

## Responses

### 200

Successful response.

#### Content Type: `application/json`

Schema:

```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          },
          "status": {
            "type": "string"
          },
          "customer": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "email": {
                "type": "string"
              }
            },
            "required": [
              "id",
              "email"
            ]
          },
          "reference": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "store_id": {
            "type": "integer"
          },
          "read_by": {
            "type": "integer"
          },
          "archived": {
            "type": "integer"
          }
        },
        "required": [
          "id",
          "title",
          "status",
          "customer",
          "reference",
          "created_at",
          "updated_at",
          "store_id",
          "read_by",
          "archived"
        ]
      }
    },
    "links": {
      "type": "object",
      "properties": {}
    },
    "meta": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "data",
    "links",
    "meta"
  ]
}
```

Example:

```json
{
  "data": [
    {
      "id": 1,
      "title": "acquisition.",
      "status": "OPEN",
      "customer": {
        "id": "cfbbf27a-0595-3234-953d-5f6629fccc9d",
        "email": "e@x.com"
      },
      "reference": [],
      "created_at": "2022-12-12T12:12:12.000000Z",
      "updated_at": "2022-12-12T12:12:12.000000Z",
      "store_id": 1,
      "read_by": 1,
      "archived": 0
    }
  ],
  "links": {},
  "meta": {}
}
```