Work with this as data
Every API here is available over the APIs.io API and to AI agents over MCP.
MCP server
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
Tools for apis
7 MCP tools reach this
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.
Call it yourself
curl for this page
This API
curl "https://apis.io/api/v1/apis/snipcart-discounts-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"
Discovery needs no key. Ratings and market analysis are Pro.
Get an API key
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
OpenAPI Specification
openapi: 3.2.0
info:
title: Snipcart REST AbandonedCarts Discounts API
description: 'The Snipcart REST API provides programmatic access to your store''s data including orders, customers, products, discounts, notifications, abandoned carts, domains, refunds, user sessions, and custom shipping methods. Authentication uses HTTP Basic Auth with a secret API key generated from the merchant dashboard. All requests must include an Accept: application/json header.
'
version: '3.0'
contact:
name: Snipcart Support
url: https://snipcart.com
license:
name: Proprietary
url: https://snipcart.com/terms-of-service
servers:
- url: https://app.snipcart.com/api
description: Snipcart API
security:
- basicAuth: []
tags:
- name: Discounts
description: Manage discount codes and promotions
paths:
/discounts:
get:
summary: List discounts
operationId: listDiscounts
description: Returns all discounts for your account.
tags:
- Discounts
responses:
'200':
description: List of discounts
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/Discount'
post:
summary: Create discount
operationId: createDiscount
description: Creates a new discount.
tags:
- Discounts
requestBody:
required: true
content:
application/json:
schema:
type: object
required:
- name
- type
properties:
name:
type: string
code:
type: string
type:
type: string
enum:
- FixedAmount
- Rate
- AlternatePrice
- Shipping
amount:
type: number
format: float
rate:
type: number
format: float
maxNumberOfUsages:
type: integer
expirationDate:
type: string
format: date-time
responses:
'201':
description: Created discount
content:
application/json:
schema:
$ref: '#/components/schemas/Discount'
/discounts/{id}:
get:
summary: Get discount
operationId: getDiscount
description: Returns a particular discount.
tags:
- Discounts
parameters:
- $ref: '#/components/parameters/discountId'
responses:
'200':
description: Discount details
content:
application/json:
schema:
$ref: '#/components/schemas/Discount'
'404':
description: Discount not found
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
put:
summary: Update discount
operationId: updateDiscount
description: Updates an existing discount.
tags:
- Discounts
parameters:
- $ref: '#/components/parameters/discountId'
requestBody:
required: true
content:
application/json:
schema:
type: object
properties:
name:
type: string
code:
type: string
amount:
type: number
format: float
rate:
type: number
format: float
maxNumberOfUsages:
type: integer
expirationDate:
type: string
format: date-time
responses:
'200':
description: Updated discount
content:
application/json:
schema:
$ref: '#/components/schemas/Discount'
delete:
summary: Delete discount
operationId: deleteDiscount
description: Deletes an existing discount. Discounts already used in completed orders cannot be deleted.
tags:
- Discounts
parameters:
- $ref: '#/components/parameters/discountId'
responses:
'200':
description: Discount deleted successfully
'400':
description: Cannot delete discount already used in completed orders
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
components:
schemas:
Discount:
type: object
properties:
id:
type: string
name:
type: string
code:
type: string
description: Discount code customers enter at checkout
type:
type: string
enum:
- FixedAmount
- Rate
- AlternatePrice
- Shipping
amount:
type: number
format: float
rate:
type: number
format: float
description: Discount rate as percentage (0-100)
maxNumberOfUsages:
type: integer
numberOfUsages:
type: integer
expirationDate:
type: string
format: date-time
Error:
type: object
properties:
message:
type: string
details:
type: array
items:
type: string
parameters:
discountId:
name: id
in: path
required: true
description: Unique discount identifier
schema:
type: string
securitySchemes:
basicAuth:
type: http
scheme: basic
description: 'Use your secret API key as the username with an empty password. Base64-encode as {API_KEY}: and pass as Authorization: Basic {encoded}.
'