Skip to content

Delete Attribute Set

Request

Deletes the attribute set identified by id (a positive integer). The tenant's default attribute set cannot be deleted.

Authentication

Requires a valid API key in the X-API-KEY header.

Query Parameters

ParameterRequiredDescription
deleteAssociatedProductsAndVariants❌ NoWhen true, products and variants associated to the attribute set are deleted along with it. When false or omitted, those products and variants are reassigned to the tenant's default attribute set.

Response

  • 200 OK — Attribute set deleted; the response body (DeleteAttributeSet2Response) summarises the operation.
  • 204 No Content — Nothing to delete (idempotent success).

Error Responses

  • 400 Bad Request — id is not a positive integer or the request is otherwise invalid (ValidationFailureRepresentation).
  • 401 Unauthorized — Missing or invalid API key. Returned by the API gateway as { "message": "Unauthorized", "request_id": "d8aafa5b8f3e400b60bea0123dd33317" }.
  • 403 Forbidden — The API key does not have write permissions for this operation.
  • 404 Not Found — No attribute set with the given identifier exists for this tenant.
  • 500 Internal Server Error — Unexpected technical error.

Example

Request:

DELETE /v2/AttributeSets(7)?deleteAssociatedProductsAndVariants=false HTTP/1.1
X-API-KEY: your-api-key-here

Response:

HTTP/1.1 200 OK
Content-Type: application/json
Path
idinteger, (int32)required

Attribute set identifier (positive integer).

Query
deleteAssociatedProductsAndVariantsboolean

When true, also deletes associated products and variants. When false or omitted, those products and variants are reassigned to the default attribute set.

DELETE
/v2/AttributeSets({id})
curl -i -X DELETE \
  'https://api2.saleslayer.com/catalog/v2/AttributeSets({id})?deleteAssociatedProductsAndVariants=true'

Responses

OK

Bodyapplication/json
@etagstring or null
@contextstring or null
valueany or null
Response
{ "@readLink": "string", "@editLink": "string", "@etag": "string", "@navigationLinks": [ { … } ], "@associationLinks": [ { … } ], "@context": "string", "value": null }