Contents

Vendre API · v1

Connect your app to your store

Create products, customers and orders in a Vendre store from your own website, mobile app or back office. Everything you create shows up in the admin straight away, with the same stock, discount and invoice rules.

Introduction

The API is JSON over HTTPS. Every request goes to one base URL, and your API key decides which store it acts on.

Base URL

https://vendre.in/api/v1
  • Send and receive JSON. Use Content-Type: application/json on requests with a body.
  • Amounts are numbers in Indian rupees, e.g. 1499 or 24.5.
  • Ids are strings. Times are ISO 8601 in UTC, like 2026-11-19T10:24:00.000Z.
  • Successful responses wrap the result in data; lists add pagination.
  • Unknown fields are rejected, so a typo in a field name is reported instead of being ignored.

Quick start

  1. 1

    Create an API key

    In your store's admin, open Settings → API keys and choose Create key. Give it a name and the permissions it needs, then copy the key. It's shown only once. Only the store owner or an admin can create keys.

  2. 2

    Check the key works

    curl "https://vendre.in/api/v1/store" \
      -H "Authorization: Bearer $VENDRE_API_KEY"
  3. 3

    Create your first product

    curl -X POST "https://vendre.in/api/v1/products" \
      -H "Authorization: Bearer $VENDRE_API_KEY" \
      -H "Content-Type: application/json" \
      -d '{
      "title": "Cotton Tee",
      "status": "active",
      "price": 599,
      "options": [
        {
          "name": "Size",
          "values": [
            "S",
            "M"
          ]
        },
        {
          "name": "Color",
          "values": [
            "Black"
          ]
        }
      ],
      "variants": [
        {
          "options": [
            "S",
            "Black"
          ],
          "quantity": 5,
          "sku": "TEE-S-BLK"
        },
        {
          "options": [
            "M",
            "Black"
          ],
          "price": 649,
          "quantity": 3,
          "sku": "TEE-M-BLK"
        }
      ],
      "tags": [
        "cotton",
        "basics"
      ]
    }'

    Then add a customer and place an order for them. The order takes stock off, issues an invoice and appears in the admin.

Authentication

Send your key in the Authorization header of every request:

Authorization: Bearer vnd_live_…

Keep keys on your server. A key in a website's browser code or a mobile app bundle can be read by anyone, so call the API from your backend and give each app its own key. If a key leaks, revoke it in Settings → API keys; it stops working at once.

Each key has permissions per resource. Write includes read.

PermissionAllows
products:readList and get products
products:writeEverything in read, plus create, change and delete products
customers:readList and get customers
customers:writeEverything in read, plus create, change and delete customers
orders:readList and get orders
orders:writeEverything in read, plus create, change and delete orders

Errors

Errors use standard HTTP status codes and always have the same shape. code is stable to check in your code; message is for people; fields names each field that needs fixing.

{
  "error": {
    "code": "validation_error",
    "message": "Some fields are missing or invalid.",
    "fields": {
      "lines.0.quantity": "Only 3 in stock",
      "phone": "Another customer already uses this mobile number."
    }
  }
}
StatusCodeMeaning
400invalid_jsonThe body isn't valid JSON
401missing_key · invalid_key · revoked_keyNo key, a wrong key, or a revoked key
403insufficient_scopeThe key doesn't have the permission the endpoint needs
404not_foundNo such record in this store (records of other stores are never visible)
409invalid_transitionAn order can't make that status change
422validation_error · unprocessableA field is missing or invalid, or a business rule failed (stock, unique email…)
429rate_limitedToo many requests; wait for Retry-After seconds
500server_errorSomething went wrong on our side; it's safe to retry

Rate limits

Each key can make 120 requests a minute. Every response says where you stand; past the limit you get a 429 with aRetry-After header in seconds.

X-RateLimit-Limit: 120
X-RateLimit-Remaining: 117
X-RateLimit-Reset: 1795091940

Pagination

List endpoints take page (from 1) and pageSize (1–50, default 20), and return where you are. Keep requesting the next page until page reaches pageCount.

{
  "data": [
    "…"
  ],
  "pagination": {
    "page": 1,
    "pageSize": 20,
    "total": 134,
    "pageCount": 7
  }
}

Idempotent orders

Networks drop. If a create-order request times out you can't tell whether the order was made, so send anIdempotency-Key header with a value unique to that order, such as a UUID or your own order id. If the same key arrives again, the API returns the order it already created (status 200, withIdempotency-Replayed: true) instead of making a second one. Reuse a key only to retry the same request.

Store

Check your key

GET/api/v1/storeAny valid key

Returns the store your API key belongs to and the permissions it has. Any valid key can call it, so it's the quickest way to confirm your setup.

Request
curl "https://vendre.in/api/v1/store" \
  -H "Authorization: Bearer $VENDRE_API_KEY"
Response · 200
{
  "data": {
    "id": "jf9vmOVtx2cS5azPgxT8oBkiukbocEal",
    "name": "Armani",
    "slug": "mh9rwd8v9a",
    "scopes": [
      "products:write",
      "orders:read"
    ]
  }
}

Products

List products

GET/api/v1/productsNeeds products:read

The store's products, most recently changed first. Each item is a summary; fetch a product for its variants.

Query

pageintegerPage number, from 1 (default 1)
pageSizeintegerItems per page, 1–50 (default 20)
searchstringText to search for
statusstringdraft, active or archived
sortstringtitle, createdAt or updatedAt; prefix with - for descending (default -updatedAt)
Request
curl "https://vendre.in/api/v1/products?page=1&pageSize=20" \
  -H "Authorization: Bearer $VENDRE_API_KEY"
Response · 200
{
  "data": [
    {
      "id": "cmwnoy41e000sjwxu4adhd9ot",
      "title": "Cotton Tee",
      "status": "active",
      "category": null,
      "productType": "T-shirt",
      "imageUrl": null,
      "variantCount": 2,
      "minPrice": 599,
      "maxPrice": 649,
      "trackQuantity": true,
      "stock": 8,
      "lowStock": false,
      "createdAt": "2026-11-19T10:24:00.000Z",
      "updatedAt": "2026-11-19T10:24:00.000Z"
    }
  ],
  "pagination": {
    "page": 1,
    "pageSize": 20,
    "total": 1,
    "pageCount": 1
  }
}

Create a product

POST/api/v1/productsNeeds products:write

Creates a product. For sizes or colours, send options: a variant is created for every combination, and variants sets the price, stock and SKU of specific ones. A product without options gets a single variant from price, quantity and sku. Opening stock is recorded in the stock history.

Body

FieldTypeDescription
titlerequiredstringProduct nameUp to 150 characters
descriptionrequiredstringHTML (p, h2-h4, strong, em, u, s, ul, ol, li, blockquote, code, pre, a) or plain text, which becomes paragraphs. Other tags are removed. Up to 5000 characters of textUp to 30000 characters
statusstringdraft is hidden from shoppers; new products default to draftOne of: draft, active, archived
handlestringURL part, unique in the store; made from the title when left outUp to 80 characters · Pattern ^[a-z0-9]+(?:-[a-z0-9]+)*$
pricenumberPrice in rupees. Required unless every variant has a price
compareAtPricenumber | nullOriginal price, shown crossed out; must be above price
costPerItemnumber | nullWhat it costs you; never shown to customers
chargeTaxbooleanCharge tax on this product (default true)
skustring | nullSKU for a product without variantsUp to 64 characters
barcodestring | nullISBN, UPC or GTIN for a product without variantsUp to 32 characters
trackQuantitybooleanCount stock down as orders come in (default true)
quantityintegerUnits in stock, for a product without variants
lowStockAtinteger | nullShow as low stock at or below this number
continueSellingbooleanKeep selling when stock reaches 0 (default false)
optionsarray of objectsUp to 3 options, like Size and Color. A variant is created for every combinationUp to 3 items
options[].namerequiredstringOption nameUp to 40 characters
options[].valuesrequiredarray of stringsIts values, up to 20Up to 20 items
variantsarray of objectsPrice, stock and SKU for specific combinations; others keep or default their valuesUp to 100 items
variants[].optionsrequiredarray of stringsWhich variant: one value per option, in option order
variants[].pricenumberPrice in rupees; defaults to the product's price
variants[].quantityintegerUnits in stock
variants[].skustring | nullStock-keeping code, unique in the storeUp to 64 characters
categoryIdstring | nullId of one of the store's categoriesUp to 64 characters
productTypestring | nullFree-text type, like ShirtUp to 60 characters
vendorstring | nullBrand or makerUp to 60 characters
tagsarray of stringsUp to 30 tagsUp to 30 items
physicalbooleanNeeds shipping (default true)
weightnumber | nullShipping weight, in weightUnit
weightUnitstringkg (default), g, lb or ozOne of: kg, g, lb, oz
lengthnumber | nullPackage length in cm
breadthnumber | nullPackage breadth in cm
heightnumber | nullPackage height in cm
originCountrystring | nullCountry of originUp to 56 characters
hsCodestring | nullHS code for customs, 6 to 10 digitsUp to 12 characters
seoTitlestring | nullSearch engine titleUp to 70 characters
seoDescriptionstring | nullSearch engine descriptionUp to 160 characters
Request
curl -X POST "https://vendre.in/api/v1/products" \
  -H "Authorization: Bearer $VENDRE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "title": "Cotton Tee",
  "status": "active",
  "price": 599,
  "options": [
    {
      "name": "Size",
      "values": [
        "S",
        "M"
      ]
    },
    {
      "name": "Color",
      "values": [
        "Black"
      ]
    }
  ],
  "variants": [
    {
      "options": [
        "S",
        "Black"
      ],
      "quantity": 5,
      "sku": "TEE-S-BLK"
    },
    {
      "options": [
        "M",
        "Black"
      ],
      "price": 649,
      "quantity": 3,
      "sku": "TEE-M-BLK"
    }
  ],
  "tags": [
    "cotton",
    "basics"
  ]
}'
Response · 201
{
  "data": {
    "id": "cmwnoy41e000sjwxu4adhd9ot",
    "title": "Cotton Tee",
    "handle": "cotton-tee",
    "status": "active",
    "description": "Soft combed cotton, regular fit.",
    "categoryId": null,
    "productType": "T-shirt",
    "vendor": "Armani",
    "tags": [
      "cotton",
      "basics"
    ],
    "chargeTax": true,
    "trackQuantity": true,
    "continueSelling": false,
    "lowStockAt": 5,
    "physical": true,
    "weight": 0.2,
    "weightUnit": "kg",
    "length": 30,
    "breadth": 25,
    "height": 4,
    "originCountry": "India",
    "hsCode": null,
    "seoTitle": null,
    "seoDescription": null,
    "options": [
      {
        "name": "Size",
        "values": [
          "S",
          "M"
        ]
      },
      {
        "name": "Color",
        "values": [
          "Black"
        ]
      }
    ],
    "variants": [
      {
        "id": "cmwnoy41f000tjwxu1k2v9a7b",
        "title": "S / Black",
        "options": [
          "S",
          "Black"
        ],
        "price": 599,
        "compareAtPrice": null,
        "costPerItem": null,
        "sku": "TEE-S-BLK",
        "barcode": null,
        "quantity": 5,
        "images": []
      },
      {
        "id": "cmwnoy41f000ujwxu8h3c2d4e",
        "title": "M / Black",
        "options": [
          "M",
          "Black"
        ],
        "price": 649,
        "compareAtPrice": null,
        "costPerItem": null,
        "sku": "TEE-M-BLK",
        "barcode": null,
        "quantity": 3,
        "images": []
      }
    ],
    "images": [],
    "currency": "INR",
    "createdAt": "2026-11-19T10:24:00.000Z",
    "updatedAt": "2026-11-19T10:24:00.000Z"
  }
}
  • 422 validation_errorA field is missing or invalid, the handle or a SKU is taken, or a variant isn't a combination of the options

Get a product

GET/api/v1/products/{id}Needs products:read

One product with its options, variants and images.

Path

idrequiredstringThe product's id
Request
curl "https://vendre.in/api/v1/products/cmwnoy41e000sjwxu4adhd9ot" \
  -H "Authorization: Bearer $VENDRE_API_KEY"
Response · 200
{
  "data": {
    "id": "cmwnoy41e000sjwxu4adhd9ot",
    "title": "Cotton Tee",
    "handle": "cotton-tee",
    "status": "active",
    "description": "Soft combed cotton, regular fit.",
    "categoryId": null,
    "productType": "T-shirt",
    "vendor": "Armani",
    "tags": [
      "cotton",
      "basics"
    ],
    "chargeTax": true,
    "trackQuantity": true,
    "continueSelling": false,
    "lowStockAt": 5,
    "physical": true,
    "weight": 0.2,
    "weightUnit": "kg",
    "length": 30,
    "breadth": 25,
    "height": 4,
    "originCountry": "India",
    "hsCode": null,
    "seoTitle": null,
    "seoDescription": null,
    "options": [
      {
        "name": "Size",
        "values": [
          "S",
          "M"
        ]
      },
      {
        "name": "Color",
        "values": [
          "Black"
        ]
      }
    ],
    "variants": [
      {
        "id": "cmwnoy41f000tjwxu1k2v9a7b",
        "title": "S / Black",
        "options": [
          "S",
          "Black"
        ],
        "price": 599,
        "compareAtPrice": null,
        "costPerItem": null,
        "sku": "TEE-S-BLK",
        "barcode": null,
        "quantity": 5,
        "images": []
      },
      {
        "id": "cmwnoy41f000ujwxu8h3c2d4e",
        "title": "M / Black",
        "options": [
          "M",
          "Black"
        ],
        "price": 649,
        "compareAtPrice": null,
        "costPerItem": null,
        "sku": "TEE-M-BLK",
        "barcode": null,
        "quantity": 3,
        "images": []
      }
    ],
    "images": [],
    "currency": "INR",
    "createdAt": "2026-11-19T10:24:00.000Z",
    "updatedAt": "2026-11-19T10:24:00.000Z"
  }
}
  • 404 not_foundNo product with this id in the store

Update a product

PATCH/api/v1/products/{id}Needs products:write

Changes only the fields you send. Send variants to change the price, stock or SKU of specific combinations; send options to reshape them (variants for removed combinations are deleted). Stock changes are recorded in the stock history.

Path

idrequiredstringThe product's id

Body

FieldTypeDescription
titlestringProduct nameUp to 150 characters
descriptionstringHTML (p, h2-h4, strong, em, u, s, ul, ol, li, blockquote, code, pre, a) or plain text, which becomes paragraphs. Other tags are removed. Up to 5000 characters of textUp to 30000 characters
statusstringdraft is hidden from shoppers; new products default to draftOne of: draft, active, archived
handlestringURL part, unique in the store; made from the title when left outUp to 80 characters · Pattern ^[a-z0-9]+(?:-[a-z0-9]+)*$
pricenumberPrice in rupees. Required unless every variant has a price
compareAtPricenumber | nullOriginal price, shown crossed out; must be above price
costPerItemnumber | nullWhat it costs you; never shown to customers
chargeTaxbooleanCharge tax on this product (default true)
skustring | nullSKU for a product without variantsUp to 64 characters
barcodestring | nullISBN, UPC or GTIN for a product without variantsUp to 32 characters
trackQuantitybooleanCount stock down as orders come in (default true)
quantityintegerUnits in stock, for a product without variants
lowStockAtinteger | nullShow as low stock at or below this number
continueSellingbooleanKeep selling when stock reaches 0 (default false)
optionsarray of objectsUp to 3 options, like Size and Color. A variant is created for every combinationUp to 3 items
options[].namerequiredstringOption nameUp to 40 characters
options[].valuesrequiredarray of stringsIts values, up to 20Up to 20 items
variantsarray of objectsPrice, stock and SKU for specific combinations; others keep or default their valuesUp to 100 items
variants[].optionsrequiredarray of stringsWhich variant: one value per option, in option order
variants[].pricenumberPrice in rupees; defaults to the product's price
variants[].quantityintegerUnits in stock
variants[].skustring | nullStock-keeping code, unique in the storeUp to 64 characters
categoryIdstring | nullId of one of the store's categoriesUp to 64 characters
productTypestring | nullFree-text type, like ShirtUp to 60 characters
vendorstring | nullBrand or makerUp to 60 characters
tagsarray of stringsUp to 30 tagsUp to 30 items
physicalbooleanNeeds shipping (default true)
weightnumber | nullShipping weight, in weightUnit
weightUnitstringkg (default), g, lb or ozOne of: kg, g, lb, oz
lengthnumber | nullPackage length in cm
breadthnumber | nullPackage breadth in cm
heightnumber | nullPackage height in cm
originCountrystring | nullCountry of originUp to 56 characters
hsCodestring | nullHS code for customs, 6 to 10 digitsUp to 12 characters
seoTitlestring | nullSearch engine titleUp to 70 characters
seoDescriptionstring | nullSearch engine descriptionUp to 160 characters
Request
curl -X PATCH "https://vendre.in/api/v1/products/cmwnoy41e000sjwxu4adhd9ot" \
  -H "Authorization: Bearer $VENDRE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "status": "active",
  "variants": [
    {
      "options": [
        "M",
        "Black"
      ],
      "quantity": 30
    }
  ]
}'
Response · 200
{
  "data": {
    "id": "cmwnoy41e000sjwxu4adhd9ot",
    "title": "Cotton Tee",
    "handle": "cotton-tee",
    "status": "active",
    "description": "Soft combed cotton, regular fit.",
    "categoryId": null,
    "productType": "T-shirt",
    "vendor": "Armani",
    "tags": [
      "cotton",
      "basics"
    ],
    "chargeTax": true,
    "trackQuantity": true,
    "continueSelling": false,
    "lowStockAt": 5,
    "physical": true,
    "weight": 0.2,
    "weightUnit": "kg",
    "length": 30,
    "breadth": 25,
    "height": 4,
    "originCountry": "India",
    "hsCode": null,
    "seoTitle": null,
    "seoDescription": null,
    "options": [
      {
        "name": "Size",
        "values": [
          "S",
          "M"
        ]
      },
      {
        "name": "Color",
        "values": [
          "Black"
        ]
      }
    ],
    "variants": [
      {
        "id": "cmwnoy41f000tjwxu1k2v9a7b",
        "title": "S / Black",
        "options": [
          "S",
          "Black"
        ],
        "price": 599,
        "compareAtPrice": null,
        "costPerItem": null,
        "sku": "TEE-S-BLK",
        "barcode": null,
        "quantity": 5,
        "images": []
      },
      {
        "id": "cmwnoy41f000ujwxu8h3c2d4e",
        "title": "M / Black",
        "options": [
          "M",
          "Black"
        ],
        "price": 649,
        "compareAtPrice": null,
        "costPerItem": null,
        "sku": "TEE-M-BLK",
        "barcode": null,
        "quantity": 3,
        "images": []
      }
    ],
    "images": [],
    "currency": "INR",
    "createdAt": "2026-11-19T10:24:00.000Z",
    "updatedAt": "2026-11-19T10:24:00.000Z"
  }
}
  • 404 not_foundNo product with this id in the store
  • 422 validation_errorA field is invalid

Delete a product

DELETE/api/v1/products/{id}Needs products:write

Deletes the product with its variants and photos. Past orders and stock history keep their copies of the product's name. To hide a product instead, set its status to archived.

Path

idrequiredstringThe product's id
Request
curl -X DELETE "https://vendre.in/api/v1/products/cmwnoy41e000sjwxu4adhd9ot" \
  -H "Authorization: Bearer $VENDRE_API_KEY"
Response · 200
{
  "data": {
    "id": "cmwnoy41e000sjwxu4adhd9ot",
    "deleted": true
  }
}
  • 404 not_foundNo product with this id in the store

Customers

List customers

GET/api/v1/customersNeeds customers:read

The store's customers, newest first. Search matches name, email, mobile and tags.

Query

pageintegerPage number, from 1 (default 1)
pageSizeintegerItems per page, 1–50 (default 20)
searchstringText to search for
subscribedbooleantrue for customers who agreed to marketing, false for the rest
sortstringname or createdAt; prefix with - for descending (default -createdAt)
Request
curl "https://vendre.in/api/v1/customers?page=1&pageSize=20" \
  -H "Authorization: Bearer $VENDRE_API_KEY"
Response · 200
{
  "data": [
    {
      "id": "cmwnp0c2a0012jwxu0q4n5m6p",
      "name": "Asha Rao",
      "email": "[email protected]",
      "phone": "+919876543210",
      "location": "Mumbai, Maharashtra",
      "subscribed": false,
      "tags": [
        "vip"
      ],
      "source": "storefront",
      "createdAt": "2026-11-19T10:30:00.000Z"
    }
  ],
  "pagination": {
    "page": 1,
    "pageSize": 20,
    "total": 1,
    "pageCount": 1
  }
}

Create a customer

POST/api/v1/customersNeeds customers:write

Adds a customer, for example when someone signs up on your website or app. Needs an email or a mobile number; both are unique in the store. The first address is the default unless another is marked isDefault.

Body

FieldTypeDescription
firstNamerequiredstringFirst nameUp to 50 characters
lastNamestring | nullLast nameUp to 50 characters
emailstring | nullEmail, unique in the store. An email or a phone is requiredUp to 120 characters · Pattern ^(?:[A-Za-z0-9_'+\-]+\.)*[A-Za-z0-9_'+\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$
phonestring | null10-digit Indian mobile, unique in the store; +91 is optionalUp to 16 characters
emailMarketingbooleanAgreed to marketing emails (default false)
smsMarketingbooleanAgreed to SMS and WhatsApp offers (default false)
notestring | nullNote only your team seesUp to 1000 characters
tagsarray of stringsUp to 30 tagsUp to 30 items
passwordstringLets the customer log in to the store; at least 8 charactersUp to 128 characters
addressesarray of objectsUp to 10 addresses. On update, this replaces the whole listUp to 10 items
addresses[].idstringOn update: an existing address's id, to keep it. Leave out to add a new addressUp to 40 characters
addresses[].namestring | nullRecipient; defaults to the customer's nameUp to 100 characters
addresses[].phonestring | nullRecipient's 10-digit mobile; defaults to the customer'sUp to 16 characters
addresses[].companystring | nullCompany nameUp to 100 characters
addresses[].line1requiredstringHouse, building and streetUp to 150 characters
addresses[].line2string | nullArea or localityUp to 150 characters
addresses[].landmarkstring | nullNearby landmarkUp to 100 characters
addresses[].cityrequiredstringCityUp to 80 characters
addresses[].staterequiredstringState or union territory, full nameOne of 36 values, e.g. Andaman and Nicobar Islands, Andhra Pradesh, Arunachal Pradesh
addresses[].pincoderequiredstring6-digit PIN codePattern ^[1-9]\d{5}$
addresses[].isDefaultbooleanUse as the default address (the first address is the default otherwise)
sourcestringWhere they came from (default storefront)One of: storefront, checkout, admin
Request
curl -X POST "https://vendre.in/api/v1/customers" \
  -H "Authorization: Bearer $VENDRE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "firstName": "Asha",
  "lastName": "Rao",
  "email": "[email protected]",
  "phone": "9876543210",
  "addresses": [
    {
      "line1": "Flat 4B, Sea View, Carter Road",
      "line2": "Bandra West",
      "city": "Mumbai",
      "state": "Maharashtra",
      "pincode": "400050"
    }
  ]
}'
Response · 201
{
  "data": {
    "id": "cmwnp0c2a0012jwxu0q4n5m6p",
    "firstName": "Asha",
    "lastName": "Rao",
    "email": "[email protected]",
    "phone": "+919876543210",
    "emailMarketing": false,
    "smsMarketing": false,
    "note": null,
    "tags": [
      "vip"
    ],
    "source": "storefront",
    "hasPassword": false,
    "avatarUrl": null,
    "addresses": [
      {
        "id": "cmwnp0c2b0013jwxu7a8b9c0d",
        "name": "Asha Rao",
        "phone": "+919876543210",
        "company": null,
        "line1": "Flat 4B, Sea View, Carter Road",
        "line2": "Bandra West",
        "landmark": null,
        "city": "Mumbai",
        "state": "Maharashtra",
        "pincode": "400050",
        "country": "IN",
        "isDefault": true
      }
    ],
    "lastLoginAt": null,
    "createdAt": "2026-11-19T10:30:00.000Z",
    "updatedAt": "2026-11-19T10:30:00.000Z"
  }
}
  • 422 validation_errorA field is invalid, neither email nor phone was sent, or another customer already uses them

Get a customer

GET/api/v1/customers/{id}Needs customers:read

One customer with all their saved addresses.

Path

idrequiredstringThe customer's id
Request
curl "https://vendre.in/api/v1/customers/cmwnp0c2a0012jwxu0q4n5m6p" \
  -H "Authorization: Bearer $VENDRE_API_KEY"
Response · 200
{
  "data": {
    "id": "cmwnp0c2a0012jwxu0q4n5m6p",
    "firstName": "Asha",
    "lastName": "Rao",
    "email": "[email protected]",
    "phone": "+919876543210",
    "emailMarketing": false,
    "smsMarketing": false,
    "note": null,
    "tags": [
      "vip"
    ],
    "source": "storefront",
    "hasPassword": false,
    "avatarUrl": null,
    "addresses": [
      {
        "id": "cmwnp0c2b0013jwxu7a8b9c0d",
        "name": "Asha Rao",
        "phone": "+919876543210",
        "company": null,
        "line1": "Flat 4B, Sea View, Carter Road",
        "line2": "Bandra West",
        "landmark": null,
        "city": "Mumbai",
        "state": "Maharashtra",
        "pincode": "400050",
        "country": "IN",
        "isDefault": true
      }
    ],
    "lastLoginAt": null,
    "createdAt": "2026-11-19T10:30:00.000Z",
    "updatedAt": "2026-11-19T10:30:00.000Z"
  }
}
  • 404 not_foundNo customer with this id in the store

Update a customer

PATCH/api/v1/customers/{id}Needs customers:write

Changes only the fields you send. addresses, when sent, is the full new list: include an existing address's id to keep it, and addresses you leave out are removed. Setting a password signs the customer out of other devices.

Path

idrequiredstringThe customer's id

Body

FieldTypeDescription
firstNamestringFirst nameUp to 50 characters
lastNamestring | nullLast nameUp to 50 characters
emailstring | nullEmail, unique in the store. An email or a phone is requiredUp to 120 characters · Pattern ^(?:[A-Za-z0-9_'+\-]+\.)*[A-Za-z0-9_'+\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$
phonestring | null10-digit Indian mobile, unique in the store; +91 is optionalUp to 16 characters
emailMarketingbooleanAgreed to marketing emails (default false)
smsMarketingbooleanAgreed to SMS and WhatsApp offers (default false)
notestring | nullNote only your team seesUp to 1000 characters
tagsarray of stringsUp to 30 tagsUp to 30 items
passwordstringLets the customer log in to the store; at least 8 charactersUp to 128 characters
addressesarray of objectsUp to 10 addresses. On update, this replaces the whole listUp to 10 items
addresses[].idstringOn update: an existing address's id, to keep it. Leave out to add a new addressUp to 40 characters
addresses[].namestring | nullRecipient; defaults to the customer's nameUp to 100 characters
addresses[].phonestring | nullRecipient's 10-digit mobile; defaults to the customer'sUp to 16 characters
addresses[].companystring | nullCompany nameUp to 100 characters
addresses[].line1requiredstringHouse, building and streetUp to 150 characters
addresses[].line2string | nullArea or localityUp to 150 characters
addresses[].landmarkstring | nullNearby landmarkUp to 100 characters
addresses[].cityrequiredstringCityUp to 80 characters
addresses[].staterequiredstringState or union territory, full nameOne of 36 values, e.g. Andaman and Nicobar Islands, Andhra Pradesh, Arunachal Pradesh
addresses[].pincoderequiredstring6-digit PIN codePattern ^[1-9]\d{5}$
addresses[].isDefaultbooleanUse as the default address (the first address is the default otherwise)
Request
curl -X PATCH "https://vendre.in/api/v1/customers/cmwnp0c2a0012jwxu0q4n5m6p" \
  -H "Authorization: Bearer $VENDRE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "note": "Prefers evening delivery",
  "addresses": [
    {
      "id": "cmwnp0c2b0013jwxu7a8b9c0d",
      "line1": "Flat 4B, Sea View, Carter Road",
      "city": "Mumbai",
      "state": "Maharashtra",
      "pincode": "400050"
    },
    {
      "name": "Asha (office)",
      "line1": "WeWork, BKC",
      "city": "Mumbai",
      "state": "Maharashtra",
      "pincode": "400051",
      "isDefault": true
    }
  ]
}'
Response · 200
{
  "data": {
    "id": "cmwnp0c2a0012jwxu0q4n5m6p",
    "firstName": "Asha",
    "lastName": "Rao",
    "email": "[email protected]",
    "phone": "+919876543210",
    "emailMarketing": false,
    "smsMarketing": false,
    "note": null,
    "tags": [
      "vip"
    ],
    "source": "storefront",
    "hasPassword": false,
    "avatarUrl": null,
    "addresses": [
      {
        "id": "cmwnp0c2b0013jwxu7a8b9c0d",
        "name": "Asha Rao",
        "phone": "+919876543210",
        "company": null,
        "line1": "Flat 4B, Sea View, Carter Road",
        "line2": "Bandra West",
        "landmark": null,
        "city": "Mumbai",
        "state": "Maharashtra",
        "pincode": "400050",
        "country": "IN",
        "isDefault": true
      }
    ],
    "lastLoginAt": null,
    "createdAt": "2026-11-19T10:30:00.000Z",
    "updatedAt": "2026-11-19T10:30:00.000Z"
  }
}
  • 404 not_foundNo customer with this id in the store
  • 422 validation_errorA field is invalid

Delete a customer

DELETE/api/v1/customers/{id}Needs customers:write

Removes the customer, their addresses and their store login. Their orders stay, with the name they ordered under.

Path

idrequiredstringThe customer's id
Request
curl -X DELETE "https://vendre.in/api/v1/customers/cmwnp0c2a0012jwxu0q4n5m6p" \
  -H "Authorization: Bearer $VENDRE_API_KEY"
Response · 200
{
  "data": {
    "id": "cmwnp0c2a0012jwxu0q4n5m6p",
    "deleted": true
  }
}
  • 404 not_foundNo customer with this id in the store

Orders

List orders

GET/api/v1/ordersNeeds orders:read

The store's orders, newest first. Search matches the order number, customer name, email and mobile.

Query

pageintegerPage number, from 1 (default 1)
pageSizeintegerItems per page, 1–50 (default 20)
searchstringText to search for
statusstringto_ship, shipped, delivered, unpaid or cancelled (cancelled includes refunded)
Request
curl "https://vendre.in/api/v1/orders?page=1&pageSize=20" \
  -H "Authorization: Bearer $VENDRE_API_KEY"
Response · 200
{
  "data": [
    {
      "id": "cmwnp2x9k001ajwxu3e4f5g6h",
      "number": 1042,
      "status": "confirmed",
      "paymentStatus": "paid",
      "paymentMethod": "upi",
      "customerId": "cmwnp0c2a0012jwxu0q4n5m6p",
      "customerName": "Asha Rao",
      "itemCount": 2,
      "total": 1397,
      "currency": "INR",
      "createdAt": "2026-11-19T11:02:00.000Z"
    }
  ],
  "pagination": {
    "page": 1,
    "pageSize": 20,
    "total": 1,
    "pageCount": 1
  }
}

Create an order

POST/api/v1/ordersNeeds orders:write

Places an order exactly as the admin does: stock is taken off (and locked so two orders can't sell the last item), the discount code is checked and counted, and an invoice is issued. Prices default to each variant's current price and the address to the customer's default. Send an Idempotency-Key header so a retry never creates a second order.

Headers

Idempotency-KeystringOptional. A unique value per order, like a UUID. Repeating it returns the order it created (200, with Idempotency-Replayed: true)

Body

FieldTypeDescription
customerIdrequiredstringThe customer placing the orderUp to 40 characters
linesrequiredarray of objectsWhat's ordered, up to 100 lines. Each variant onceUp to 100 items
lines[].variantIdrequiredstringA product variant's id (a product without options has one variant)Up to 40 characters
lines[].quantityrequiredintegerHow many
lines[].pricenumberUnit price in rupees; defaults to the variant's current price
addressobjectShipping address; defaults to the customer's default address
address.namerequiredstringRecipientUp to 100 characters
address.phonerequiredstringRecipient's 10-digit mobileUp to 16 characters
address.line1requiredstringHouse, building and streetUp to 150 characters
address.line2string | nullArea or localityUp to 150 characters
address.landmarkstring | nullNearby landmarkUp to 100 characters
address.cityrequiredstringCityUp to 80 characters
address.staterequiredstringState, full nameOne of 36 values, e.g. Andaman and Nicobar Islands, Andhra Pradesh, Arunachal Pradesh
address.pincoderequiredstring6-digit PIN codePattern ^[1-9]\d{5}$
saveAddressbooleanAlso save a sent address to the customer (default true; duplicates are skipped)
shippingnumberShipping charge in rupees (default 0)
discountCodestringA discount code to applyUp to 30 characters
statusstringStarting status (default confirmed)One of: confirmed, shipped, delivered
paidbooleanPayment already received (default false). Can't be true with cod
paymentMethodrequiredstringHow the customer paysOne of: cod, upi, card, bank_transfer, cash
notestring | nullNote only your team seesUp to 1000 characters
Request
curl -X POST "https://vendre.in/api/v1/orders" \
  -H "Authorization: Bearer $VENDRE_API_KEY" \
  -H "Idempotency-Key: order-7f3a9c" \
  -H "Content-Type: application/json" \
  -d '{
  "customerId": "cmwnp0c2a0012jwxu0q4n5m6p",
  "lines": [
    {
      "variantId": "cmwnoy41f000ujwxu8h3c2d4e",
      "quantity": 2
    }
  ],
  "shipping": 99,
  "paymentMethod": "upi",
  "paid": true
}'
Response · 201
{
  "data": {
    "id": "cmwnp2x9k001ajwxu3e4f5g6h",
    "number": 1042,
    "status": "confirmed",
    "paymentStatus": "paid",
    "paymentMethod": "upi",
    "source": "api",
    "customer": {
      "id": "cmwnp0c2a0012jwxu0q4n5m6p",
      "name": "Asha Rao",
      "email": "[email protected]",
      "phone": "+919876543210"
    },
    "shippingAddress": {
      "name": "Asha Rao",
      "phone": "+919876543210",
      "line1": "Flat 4B, Sea View, Carter Road",
      "line2": "Bandra West",
      "landmark": null,
      "city": "Mumbai",
      "state": "Maharashtra",
      "pincode": "400050",
      "country": "IN"
    },
    "lines": [
      {
        "id": "cmwnp2x9m001bjwxu1a2b3c4d",
        "variantId": "cmwnoy41f000ujwxu8h3c2d4e",
        "productId": "cmwnoy41e000sjwxu4adhd9ot",
        "title": "Cotton Tee",
        "variantTitle": "M / Black",
        "sku": "TEE-M-BLK",
        "imageUrl": null,
        "price": 649,
        "quantity": 2,
        "total": 1298
      }
    ],
    "subtotal": 1298,
    "discountTotal": 0,
    "discountCode": null,
    "shippingTotal": 99,
    "total": 1397,
    "currency": "INR",
    "note": null,
    "invoice": {
      "number": "INV-1042",
      "status": "paid"
    },
    "createdAt": "2026-11-19T11:02:00.000Z",
    "paidAt": "2026-11-19T11:02:00.000Z",
    "shippedAt": null,
    "deliveredAt": null,
    "cancelledAt": null,
    "refundedAt": null
  }
}
  • 422 validation_errorA field is invalid, a variant is out of stock (fields name the line), the discount doesn't apply, or the customer has no address and none was sent

Get an order

GET/api/v1/orders/{id}Needs orders:read

One order with its lines, shipping address, totals and invoice.

Path

idrequiredstringThe order's id
Request
curl "https://vendre.in/api/v1/orders/cmwnp2x9k001ajwxu3e4f5g6h" \
  -H "Authorization: Bearer $VENDRE_API_KEY"
Response · 200
{
  "data": {
    "id": "cmwnp2x9k001ajwxu3e4f5g6h",
    "number": 1042,
    "status": "confirmed",
    "paymentStatus": "paid",
    "paymentMethod": "upi",
    "source": "api",
    "customer": {
      "id": "cmwnp0c2a0012jwxu0q4n5m6p",
      "name": "Asha Rao",
      "email": "[email protected]",
      "phone": "+919876543210"
    },
    "shippingAddress": {
      "name": "Asha Rao",
      "phone": "+919876543210",
      "line1": "Flat 4B, Sea View, Carter Road",
      "line2": "Bandra West",
      "landmark": null,
      "city": "Mumbai",
      "state": "Maharashtra",
      "pincode": "400050",
      "country": "IN"
    },
    "lines": [
      {
        "id": "cmwnp2x9m001bjwxu1a2b3c4d",
        "variantId": "cmwnoy41f000ujwxu8h3c2d4e",
        "productId": "cmwnoy41e000sjwxu4adhd9ot",
        "title": "Cotton Tee",
        "variantTitle": "M / Black",
        "sku": "TEE-M-BLK",
        "imageUrl": null,
        "price": 649,
        "quantity": 2,
        "total": 1298
      }
    ],
    "subtotal": 1298,
    "discountTotal": 0,
    "discountCode": null,
    "shippingTotal": 99,
    "total": 1397,
    "currency": "INR",
    "note": null,
    "invoice": {
      "number": "INV-1042",
      "status": "paid"
    },
    "createdAt": "2026-11-19T11:02:00.000Z",
    "paidAt": "2026-11-19T11:02:00.000Z",
    "shippedAt": null,
    "deliveredAt": null,
    "cancelledAt": null,
    "refundedAt": null
  }
}
  • 404 not_foundNo order with this id in the store

Change an order's status

POST/api/v1/orders/{id}/statusNeeds orders:write

Moves the order on: confirmed → shipped → delivered, or to cancelled or refunded. Cancelling or refunding puts the stock back, gives the discount its use back and voids or refunds the invoice. Refunding needs a paid order.

Path

idrequiredstringThe order's id

Body

FieldTypeDescription
statusrequiredstringThe new status. Refunded needs a paid orderOne of: shipped, delivered, cancelled, refunded
Request
curl -X POST "https://vendre.in/api/v1/orders/cmwnp2x9k001ajwxu3e4f5g6h/status" \
  -H "Authorization: Bearer $VENDRE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "status": "shipped"
}'
Response · 200
{
  "data": {
    "id": "cmwnp2x9k001ajwxu3e4f5g6h",
    "number": 1042,
    "status": "shipped",
    "paymentStatus": "paid",
    "paymentMethod": "upi",
    "source": "api",
    "customer": {
      "id": "cmwnp0c2a0012jwxu0q4n5m6p",
      "name": "Asha Rao",
      "email": "[email protected]",
      "phone": "+919876543210"
    },
    "shippingAddress": {
      "name": "Asha Rao",
      "phone": "+919876543210",
      "line1": "Flat 4B, Sea View, Carter Road",
      "line2": "Bandra West",
      "landmark": null,
      "city": "Mumbai",
      "state": "Maharashtra",
      "pincode": "400050",
      "country": "IN"
    },
    "lines": [
      {
        "id": "cmwnp2x9m001bjwxu1a2b3c4d",
        "variantId": "cmwnoy41f000ujwxu8h3c2d4e",
        "productId": "cmwnoy41e000sjwxu4adhd9ot",
        "title": "Cotton Tee",
        "variantTitle": "M / Black",
        "sku": "TEE-M-BLK",
        "imageUrl": null,
        "price": 649,
        "quantity": 2,
        "total": 1298
      }
    ],
    "subtotal": 1298,
    "discountTotal": 0,
    "discountCode": null,
    "shippingTotal": 99,
    "total": 1397,
    "currency": "INR",
    "note": null,
    "invoice": {
      "number": "INV-1042",
      "status": "paid"
    },
    "createdAt": "2026-11-19T11:02:00.000Z",
    "paidAt": "2026-11-19T11:02:00.000Z",
    "shippedAt": "2026-11-20T09:15:00.000Z",
    "deliveredAt": null,
    "cancelledAt": null,
    "refundedAt": null
  }
}
  • 404 not_foundNo order with this id in the store
  • 409 invalid_transitionThe order can't make that move, e.g. delivered → shipped

Mark an order paid

POST/api/v1/orders/{id}/mark-paidNeeds orders:write

Records that a pending payment was received, for example cash on delivery. The invoice becomes paid too.

Path

idrequiredstringThe order's id
Request
curl -X POST "https://vendre.in/api/v1/orders/cmwnp2x9k001ajwxu3e4f5g6h/mark-paid" \
  -H "Authorization: Bearer $VENDRE_API_KEY"
Response · 200
{
  "data": {
    "id": "cmwnp2x9k001ajwxu3e4f5g6h",
    "number": 1042,
    "status": "confirmed",
    "paymentStatus": "paid",
    "paymentMethod": "cod",
    "source": "api",
    "customer": {
      "id": "cmwnp0c2a0012jwxu0q4n5m6p",
      "name": "Asha Rao",
      "email": "[email protected]",
      "phone": "+919876543210"
    },
    "shippingAddress": {
      "name": "Asha Rao",
      "phone": "+919876543210",
      "line1": "Flat 4B, Sea View, Carter Road",
      "line2": "Bandra West",
      "landmark": null,
      "city": "Mumbai",
      "state": "Maharashtra",
      "pincode": "400050",
      "country": "IN"
    },
    "lines": [
      {
        "id": "cmwnp2x9m001bjwxu1a2b3c4d",
        "variantId": "cmwnoy41f000ujwxu8h3c2d4e",
        "productId": "cmwnoy41e000sjwxu4adhd9ot",
        "title": "Cotton Tee",
        "variantTitle": "M / Black",
        "sku": "TEE-M-BLK",
        "imageUrl": null,
        "price": 649,
        "quantity": 2,
        "total": 1298
      }
    ],
    "subtotal": 1298,
    "discountTotal": 0,
    "discountCode": null,
    "shippingTotal": 99,
    "total": 1397,
    "currency": "INR",
    "note": null,
    "invoice": {
      "number": "INV-1042",
      "status": "paid"
    },
    "createdAt": "2026-11-19T11:02:00.000Z",
    "paidAt": "2026-11-19T11:02:00.000Z",
    "shippedAt": null,
    "deliveredAt": null,
    "cancelledAt": null,
    "refundedAt": null
  }
}
  • 404 not_foundNo order with this id in the store
  • 409 invalid_transitionThe order is already paid, cancelled or refunded

Ready to connect?

Create a key in Settings → API keys and make your first request in a minute.