V1 and V2Products (V2 beta)
Assign a product family
Assign family to a product. It will return the id of the product and the modification date.
| parameter | description | mandatory |
|---|---|---|
| product_family_id | id of the product family that is going to be assigned to the product | yes |
Important notes:
-
Changing product family might cause data loss
-
Product families cannot be assigned to Variant products
-
Changing the product family will change the same fields of the variants
Authorization
bearerAuth AuthorizationBearer <token>
Obtain a token via POST /auth/api/get-token (15 minute lifetime), then send it as Authorization: Bearer <token>.
In: header
Path Parameters
product_id*string
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
curl -X POST 'https://example.com/api/v2/products/string/family' \ -H 'Content-Type: application/json' \ --data-raw '{ "product_family_id": "<product_family_id>"}'{ "data": [ { "id": "641887f2d10eec81d978e10e", "created": "2023-03-21T13:33:06.925000+00:00", "modified": "2023-03-22T13:33:06.925000+00:00", "created_user_audit": { "type": "API", "user_email": "api", "user_id": "67191ed7d6e8e300016f1414", "user_name": "api" }, "modified_user_audit": { "type": "API", "user_email": "api", "user_id": "67191ed7d6e8e300016f1414", "user_name": "api" } } ]}