Add an item
Changed onCreates an item in your catalog keyed by your own id. Sending an ID that already exists fails with PRODUCT_ALREADY_EXISTS — use Update an item to change the catalog record. Items are also created automatically when a document references an unknown item id.
Request
- Base URLhttps://app.getswipe.in/api/partner
- URLhttps://app.getswipe.in/api/partner/v2/product
- AuthHTTP bearer
Query parameters
Unique id for each item
Name of the Product
Opening Quantity
Price per item without Tax
Tax percentage for each item
Price per item with Tax
Purchase Price per item with Tax
Item Description
HSN Code
Product or Service enum
Item quantity unit
Cess Percent of the Item
Cess Amount of the Item
Barcode
Category
JSON string of alternative units
JSON string of custom fields
JSON string of product preferences
Request body multipart/form-data
Response
Success
Example response
{
"success": true,
"message": "Message",
"data": {
"id": "ITEM123",
"name": "Item Name",
"quantity": 1,
"unit_price": 100,
"tax_rate": 18,
"price_with_tax": 118,
"purchase_price_with_tax": 118,
"description": "Item Description",
"hsn_code": "1234",
"item_type": "Product",
"unit": "kg",
"barcode": "2273546838467",
"category": "Electronics",
"alternative_units": [
{
"alternative_unit": "g",
"conversion_rate": 1000
}
],
"custom_columns": [
{
"label": "Custom Label",
"value": "Custom Value"
}
],
"preferences": {
"discount_percent": 10
},
"visibility": 1
}
}Changes
- breaking
added the new required
queryrequest parameterid - breaking
added the new required
queryrequest parameteritem_type - breaking
added the new required
queryrequest parametername - breaking
added the new required
queryrequest parameterprice_with_tax - breaking
added the new required
queryrequest parameterquantity - breaking
added the new required
queryrequest parameterunit_price - breaking
removed the media type
application/jsonfrom the request body - breaking
the
/response's property type changed fromobjectto no type for status - warning
removed the request property
- warning
removed the request property
- warning
removed the request property
- warning
removed the request property
- warning
removed the request property
- warning
removed the request property
- warning
removed the request property
- warning
removed the request property
- warning
removed the request property
- warning
removed the request property
- warning
removed the request property
- warning
removed the request property
- warning
removed the request property
- warning
removed the request property
- warning
removed the request property
- warning
removed the request property
- warning
removed the request property
- warning
removed the request property
- warning
removed the request property
- info
api operation id
v2_post_productremoved and replaced withpost_product - info
added the new optional
queryrequest parameteralternative_units - info
added the new optional
queryrequest parameterbarcode - info
added the new optional
queryrequest parametercategory - info
added the new optional
queryrequest parametercess_amount - info
added the new optional
queryrequest parametercess_rate - info
added the new optional
queryrequest parametercustom_columns - info
added the new optional
queryrequest parameterdescription - info
added the new optional
queryrequest parameterhsn_code - info
added the new optional
queryrequest parameterpreferences - info
added the new optional
queryrequest parameterpurchase_price_with_tax - info
added the new optional
queryrequest parametertax_rate - info
added the new optional
queryrequest parameterunit - info
request body became optional
- info
added the optional property
/to the response with the status
- breaking