User Tools

Site Tools


api:product:delete

API : Product Delete

Introduction

This request will delete the specified product.

If the product is a reseller product, it can only be deleted if no customers are using it. If the product is a master product, then it can only be deleted if no reseller products inherits from it.

Request

URL https://api.telecomx.dk/product/PRODUCT_ID
Method DELETE
Access level RESELLER if product is a reseller or customer product.
RESELLER_ADMIN with FINANCE feature or ADMIN for any product, reseller or master.
Param PRODUCT_ID Id of the product (24-char hex string)

Query example

DELETE https://api.telecomx.dk/product/123457890ABCDEF12345678

Response

Json object
success Boolean True on success

Example

{
  success: true
}

Errors

Error code Message Description
400 bad_request Id not found in request URI
404 product Product not found
403 access_denied Insufficient access level
409 _id Product is used as a config product for '123456780ABCDEF12345678' and cannot be deleted
409 _id Product is inherited by X reseller products and cannot be deleted
500 internal_error <Unspecified>
api/product/delete.txt · Last modified: 2023/10/30 22:31 by Per Møller

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki