Skip to main content
GET
/
v1
/
categories
/
{slug}
Python
import os
from channel3_sdk import Channel3

client = Channel3(
    api_key=os.environ.get("CHANNEL3_API_KEY"),  # This is the default and can be omitted
)
category = client.categories.retrieve(
    "slug",
)
print(category.has_children)
{
  "slug": "<string>",
  "title": "<string>",
  "has_children": true,
  "path": [
    {
      "slug": "<string>",
      "title": "<string>"
    }
  ],
  "description": "<string>",
  "children": [
    {
      "slug": "<string>",
      "title": "<string>"
    }
  ],
  "attributes": [
    {
      "slug": "<string>",
      "name": "<string>",
      "values": [
        "<string>"
      ]
    }
  ]
}

Documentation Index

Fetch the complete documentation index at: https://docs.trychannel3.com/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

x-api-key
string
header
required

Path Parameters

slug
string
required

Response

Successful Response

Full category representation used in detail responses.

slug
string
required

URL-friendly slug (e.g. 'sofas')

title
string
required

Human-readable category title

has_children
boolean
required

Whether this category has subcategories

path
CategoryRef · object[]

Hierarchical path as a structured list, root first; the last entry is this category itself

description
string | null

Natural-language description of products in this category

children
CategoryRef · object[]

Direct subcategories only (one level)

attributes
CategoryAttribute · object[]

Structured attributes applicable to this category