KashierDevelopersKashier Developers
Accept payments

Product catalog

Create and manage the products and categories used to build itemized payment links and checkout pages

Kashier keeps a per-merchant product catalog — products and the categories that organize them — under /v2/products and /v2/category. It's the same catalog used when a payment page or payment link is built from line items instead of a single flat amount, and every stock-affecting change to a product is recorded on an append-only timeline you can inspect after the fact.

Scope of this page

This page covers the routes for managing your catalog under /v2/products and /v2/category, all called with your secret key.

Product fields

Product fields are listed below. Use the "Try it" panel on each route to inspect a live response on a test account.

FieldTypeSettable via APINotes
productNamestringyesMust be unique within your catalog per currency — you can't have two products with the same name in the same currency.
productDescriptionstringyesFree-text description.
productReferencestringyesYour own SKU/reference.
unitPricenumberyesMinimum 0.
currencystringyesDefaults to EGP.
quantitynumberyesStock quantity. Minimum 0.
productImagestringyesProduct image reference; echoed back as productImageUrl.
isVariantbooleanyesWhether the product has size variants. Defaults to false.
variantsTypestring (size)yesVariant dimension, when isVariant is true.
isShippablebooleanyesDefaults to false.
dimensions.height / .width / .length / .weight / .notesnumber / stringyesShipping dimensions.
productVariants[]arrayyesEmbedded size variants, each with variantType, name, quantity, unitPrice (minimum 0.1), variantReference, status, variantDimensions.
categories[]array of category IDsyesCategories this product belongs to.
productStatusstring (available | outOfStock)system-managedDerived from stock levels.
reservedQuantity / purchasedQuantity / totalRevenuenumbersystem-managedRunning totals.
merchantId / creationDate—system-managedSet automatically.

Category fields

FieldTypeSettable via APINotes
namestringyesRequired.
slugstringsystem-managedDerived from name; two of your categories can't resolve to the same slug, so names have to differ.
numberOfProductsnumbersystem-managedNumber of products tagged with this category.
merchantId / createdAt / updatedAt—system-managed

List merchant products

Returns the merchant's products.

curl --location 'https://test-api.kashier.io/v2/products/' \
  --header 'Authorization: YOUR_TEST_SECRET_KEY'

Headers

KeyDescription
AuthorizationThe Authorization is a secret key that is used to identify the merchant. You can obtain it from Kashier's dashboard. Learn more about Authorization.

Response

Returns a 200 with the merchant's products — individual items follow the Product fields shape above. Use the "Try it" panel above against a test account to inspect a live response.

Create product

Creates a new product in the merchant's catalog.

Body parameters

See Product fields for the full settable set. productName, currency and isVariant are required; unitPrice is required for a non-variant product. A minimal example:

curl --location 'https://test-api.kashier.io/v2/products/' \
  --header 'Authorization: YOUR_TEST_SECRET_KEY' \
  --header 'Content-Type: application/json' \
  --data '{
    "productName": "Wireless Mouse",
    "productReference": "SKU-1001",
    "currency": "EGP",
    "unitPrice": 350,
    "quantity": 100,
    "isVariant": false
  }'

Two uniqueness constraints to work around

productReference is optional, but it is your merchant-wide SKU and it must be unique, so add your own value when you need one. productName must also be unique per currency, so use a different name for each product you create.

Headers

KeyDescription
AuthorizationThe Authorization is a secret key that is used to identify the merchant. You can obtain it from Kashier's dashboard. Learn more about Authorization.

Response

Returns a 201 with the created product, in the Product fields shape — including the system-managed fields (productStatus, merchantId, timestamps, and so on).

Get product details

Fetch a single product by ID.

curl --location 'https://test-api.kashier.io/v2/products/:id' \
  --header 'Authorization: YOUR_TEST_SECRET_KEY'

Headers

KeyDescription
AuthorizationThe Authorization is a secret key that is used to identify the merchant. You can obtain it from Kashier's dashboard. Learn more about Authorization.

Response

Returns a 200 with the product in the Product fields shape.

Update product

Update fields on an existing product.

Body parameters

Same settable fields as Create product — see Product fields.

curl --location --request PUT 'https://test-api.kashier.io/v2/products/:id' \
  --header 'Authorization: YOUR_TEST_SECRET_KEY' \
  --header 'Content-Type: application/json' \
  --data '{
    "unitPrice": 375,
    "quantity": 80
  }'

Headers

KeyDescription
AuthorizationThe Authorization is a secret key that is used to identify the merchant. You can obtain it from Kashier's dashboard. Learn more about Authorization.

Response

Returns the updated product in the same shape as Get product details.

Get product timeline

Returns the append-only audit/inventory timeline for a single product — every stock created / added / reduced / reserved / purchased / updated event, in order.

curl --location 'https://test-api.kashier.io/v2/products/:id/timeline' \
  --header 'Authorization: YOUR_TEST_SECRET_KEY'

Headers

KeyDescription
AuthorizationThe Authorization is a secret key that is used to identify the merchant. You can obtain it from Kashier's dashboard. Learn more about Authorization.

Response

Returns a 200 with a list of timeline entries. Each entry carries operation (created | reduced | added | purchased | updated | reserved), numOfUnit (the quantity delta), actionDate, and actionBy (the user who made the change). For events that came from a sale, the entry also references the related transaction and order. Use the "Try it" panel above against a test account to inspect the response envelope.

Assign categories to product

Adds or removes categories on one or more products, in bulk.

Body parameters

KeyRequiredDescription
categoryIdsyesArray of category IDs to apply. Get them from Get all categories.
productIdsyesArray of product IDs to apply them to. Get them from List merchant products.
operationyesassign or unassign.
curl --location --request PUT 'https://test-api.kashier.io/v2/products/assign/categories' \
  --header 'Authorization: YOUR_TEST_SECRET_KEY' \
  --header 'Content-Type: application/json' \
  --data '{
    "categoryIds": ["507f1f77bcf86cd799439011"],
    "productIds": ["507f1f77bcf86cd799439012"],
    "operation": "assign"
  }'

Headers

KeyDescription
AuthorizationThe Authorization is a secret key that is used to identify the merchant. You can obtain it from Kashier's dashboard. Learn more about Authorization.

Response

Returns a 200.

No 'Try it' panel for this one

Both IDs have to be real objects in your own catalog, and the call rewrites the categories[] of every product you name. Run the curl above with IDs from your own account instead. The route adds to a product's existing categories[] (or removes from it, with operation: "unassign"). Confirm the behaviour on a test product before relying on it in production.

Change product categories

A second, related route for managing a product's categories, alongside Assign categories to product.

Body parameters

The same categoryIds and productIds arrays as Assign categories to product, both required — but no operation, which is the one structural difference between the two routes.

KeyRequiredDescription
categoryIdsyesArray of category IDs.
productIdsyesArray of product IDs.
curl --location --request PUT 'https://test-api.kashier.io/v2/products/categories/change' \
  --header 'Authorization: YOUR_TEST_SECRET_KEY' \
  --header 'Content-Type: application/json' \
  --data '{
    "categoryIds": ["507f1f77bcf86cd799439011"],
    "productIds": ["507f1f77bcf86cd799439012"]
  }'

Headers

KeyDescription
AuthorizationThe Authorization is a secret key that is used to identify the merchant. You can obtain it from Kashier's dashboard. Learn more about Authorization.

No 'Try it' panel for this one

Same reason as Assign categories to product: the call needs real product and category IDs from your own catalog and rewrites the products it names, so there is no safe placeholder body to ship. If your integration depends on whether this route replaces a product's category set or adds to it, verify that behaviour on a test product first.

Export merchant products

Downloads the merchant's product catalog as a file.

curl --location 'https://test-api.kashier.io/v2/products/export' \
  --header 'Authorization: YOUR_TEST_SECRET_KEY' \
  --output products.xlsx

Headers

KeyDescription
AuthorizationThe Authorization is a secret key that is used to identify the merchant. You can obtain it from Kashier's dashboard. Learn more about Authorization.

Export merchant products asynchronously

Same export, run as a background job instead of a synchronous download — useful for large catalogs. Rather than returning the file directly, it queues the export and is intended to email a download link once the file is ready.

curl --location 'https://test-api.kashier.io/v2/products/export-async' \
  --header 'Authorization: YOUR_TEST_SECRET_KEY'

Headers

KeyDescription
AuthorizationThe Authorization is a secret key that is used to identify the merchant. You can obtain it from Kashier's dashboard. Learn more about Authorization.

Response

Returns a 200 acknowledging the export job was queued. Use the "Try it" panel above against a test account to see the acknowledgment body.

Upload product file

Uploads a file associated with the merchant's catalog, for example a product image.

curl --location 'https://test-api.kashier.io/v2/products/upload/' \
  --header 'Authorization: YOUR_TEST_SECRET_KEY' \
  --form 'file=@"/path/to/file"'

Headers

KeyDescription
AuthorizationThe Authorization is a secret key that is used to identify the merchant. You can obtain it from Kashier's dashboard. Learn more about Authorization.

Get all categories

Returns the merchant's product categories.

Query parameters

sortBy is required.

KeyRequiredDescription
sortByyesField to sort by, for example name or createdAt.
sortTypenoSort order: 1 ascending, -1 descending.
pagenoPage number.
limitnoResults per page.
qnoSearch query.
from / tonoDate range, DD-MM-YYYY.
curl --location 'https://test-api.kashier.io/v2/category/?sortBy=createdAt&sortType=-1&page=1&limit=20' \
  --header 'Authorization: YOUR_TEST_SECRET_KEY'

Headers

KeyDescription
AuthorizationThe Authorization is a secret key that is used to identify the merchant. You can obtain it from Kashier's dashboard. Learn more about Authorization.

Response

Returns a 200 with the merchant's categories — individual items follow the Category fields shape above, alongside pagination. Use the "Try it" panel above against a test account to see the exact list envelope.

Create product category

Creates a new category.

Body parameters

KeyDescription
nameCategory name. Required, and unique per merchant once slugified — see Category fields. Use a unique name for each category.
curl --location 'https://test-api.kashier.io/v2/category/' \
  --header 'Authorization: YOUR_TEST_SECRET_KEY' \
  --header 'Content-Type: application/json' \
  --data '{
    "name": "Electronics"
  }'

Headers

KeyDescription
AuthorizationThe Authorization is a secret key that is used to identify the merchant. You can obtain it from Kashier's dashboard. Learn more about Authorization.

Response

Returns a 201 with the created category, in the Category fields shape — including the system-managed slug (derived from name) and numberOfProducts (starts at 0).

Get category details

Fetch a single category by ID.

curl --location 'https://test-api.kashier.io/v2/category/:id' \
  --header 'Authorization: YOUR_TEST_SECRET_KEY'

Headers

KeyDescription
AuthorizationThe Authorization is a secret key that is used to identify the merchant. You can obtain it from Kashier's dashboard. Learn more about Authorization.

Response

Returns a 200 with the category in the Category fields shape.

Update product category

Update a category's name.

Body parameters

KeyDescription
nameNew category name. Changing it re-derives slug.
curl --location --request PUT 'https://test-api.kashier.io/v2/category/:id' \
  --header 'Authorization: YOUR_TEST_SECRET_KEY' \
  --header 'Content-Type: application/json' \
  --data '{
    "name": "Electronics & Accessories"
  }'

Headers

KeyDescription
AuthorizationThe Authorization is a secret key that is used to identify the merchant. You can obtain it from Kashier's dashboard. Learn more about Authorization.

Response

Returns the updated category in the same shape as Get category details.

Delete product category

Delete a category.

curl --location --request DELETE 'https://test-api.kashier.io/v2/category/:id' \
  --header 'Authorization: YOUR_TEST_SECRET_KEY'

Headers

KeyDescription
AuthorizationThe Authorization is a secret key that is used to identify the merchant. You can obtain it from Kashier's dashboard. Learn more about Authorization.

Response

Returns a 200 confirming deletion. Use the "Try it" panel above against a test account to see the response body.

Products deleted from a category

Deleting a category doesn't delete the products tagged with it. If your integration depends on how a deleted category affects each product's categories[], verify that on a test account.

On this page