v1

latestOpenAPI 3.1.02026-07-227350156.5 KB
Category Personalization

Create a custom integration-level category

Create a custom integration-level category.

This category will be available to all users of your integration.

To learn more about category personalization, please read the Category Personalization Guide.

post/categories

Request body

namestring required

The name of the category (must be unique per integration / user).

parentIdstring required

The ID of the new category's parent. Can be a Spade category ID (e.g. "011-000-000-000") or a custom category ID (e.g. "e4cf5379-583f-44ed-b625-366044e666e6").

Example request

{
  "name": "Kitchen Remodel",
  "parentId": "011-000-000-000"
}

Response

Successful operation

idstring

A unique identifier for this category.

namestring

The category's name

iconstring url nullable

The category's icon, potentially inherited from the parent category.

Example response

{
  "id": "4d5419f1-bcde-40f5-9168-7f8989b9c55f",
  "name": "Kitchen Remodel",
  "icon": "https://static.v2.spadeapi.com/categories/ee4ee39fd5474d31ac42f9e606b9040a/light.png",
  "fullCategoryHierarchy": [
    {
      "id": "011-000-000-000",
      "name": "Retail",
      "icon": "https://static.v2.spadeapi.com/categories/ee4ee39fd5474d31ac42f9e606b9040a/light.png"
    },
    {
      "id": "4d5419f1-bcde-40f5-9168-7f8989b9c55f",
      "name": "Kitchen Remodel",
      "icon": "https://static.v2.spadeapi.com/categories/ee4ee39fd5474d31ac42f9e606b9040a/light.png"
    }
  ]
}