Update a Category

Update a Category by ID

PUT https://api.moltin.com/v2/categories/:id

Headers

NameTypeDescription

Authorization

string

The Bearer token to gran access to the API

Request Body

NameTypeDescription

id

string

ID of the category to update.

type

string

Represents the type of the object being returned, e.g. category

{
    "data": {
        "id": "57fbb8eb-34cc-4076-8ec8-7e6f52c07100",
        "type": "category",
        "status": "live",
        "name": "Womens",
        "slug": "Womens",
        "description": "Womens clothing",
        "meta": {
            "timestamps": {
                "created_at": "2018-10-05T15:18:48+00:00",
                "updated_at": "2018-10-05T15:18:48+00:00"
            }
        },
        "relationships": {}
    }
}
curl -X PUT https://api.moltin.com/v2/categories/:id \
    -H "Authorization: Bearer XXXX" \
    -H "Content-Type: application/json" \
    -d $'{
      "data": {
          "type": "category",
          "id": "645f97aa-ae63-4ee9-9259-062e570ba064",
          "name": "Category #1 Updated",
          "slug": "category-1-update",
          "description": "First category updated",
          "status": "live"
      }
    }'

Last updated