For the complete documentation index, see llms.txt. This page is also available as Markdown.

Schema Types

Administrative endpoints for schema types — the registry that maps a model (a Django content type) to a JSON-schema definition describing the structured attribute data allowed for that model's instances. There is exactly one schema type per content type. Schema types back the dynamic/EAV attribute data used by products, attributes, subscriptions, order requests, menu items, bundle chapters, and other models.

Core Capabilities

1. Listing & Filtering

  • Retrieve a paginated list of schema types.

  • Filter by app_label or model.

  • Order results with the sort parameter.

2. Create & Update

  • Create a schema type for a content type.

  • Retrieve a single schema type — addressed by model name, not by numeric identifier (see Addressing a Record).

  • Fully or partially update the schema of an existing record.

Delete is not supported — there is no DELETE route (405 Method Not Allowed).

Schema Type Fields

Field
Type
Description

pk

integer

The unique identifier of the record. Read-only.

content_type

integer

The identifier of the Django content type (model) this schema describes. Required on create; unique across all schema types. Not writable on update.

schema

object

The JSON-schema document describing the model's structured attribute data. Required on create and on update.

model

string

Read-only. The model name of the content type (for example product).

created_date

string (date-time)

Read-only. When the record was created.

modified_date

string (date-time)

Read-only. When the record was last modified.

Addressing a Record

Detail operations key on the model name of the content type, not the numeric identifier: /schema_types/{content_type__model}/ — for example /schema_types/product/. The additional /schema_types/{content_type__model}/detailed/ route returns the same representation as retrieve.

Filtering & Ordering

Parameter
Match

app_label

Exact match on the content type's app label (for example products).

model

Exact match on the content type's model name (for example product).

Use the sort parameter to order the results; any field is orderable. Prefix a field with a hyphen for descending order.

Dynamic Settings & Environment Variables

No dynamic settings (dj_dynamic_settings) are read by these endpoints, and no environment variables are read directly.

Last updated

Was this helpful?