# Draft API / SCT Endpoints

Source: https://dev.arcxp.com/custom-content/reference/draft-api-sct-endpoints/

The Structured Content Types (SCT) API is part of the Arc XP **Draft API**. It exposes two resource groups: **schema types** (the templates that define your content structure) and **documents** (the individual records that conform to a schema). Both groups are managed through the same authenticated API used for story content in Arc XP.

## Schema Management Endpoints

| Method           | Path                                  | Description                                                                                                                                           |
| ---------------- | ------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- |
| POST             | /draft/v1/schema-type                 | Create a new schema                                                                                                                                   |
| GET              | /draft/v1/schema-type                 | List schemas in the org, 25 per page (page). Sort with sort\_by \= name, display\_name, created\_at or updated\_at and sort\_direction \= asc or desc |
| GET              | /draft/v1/schema-type/{name}          | Get a single schema by name                                                                                                                           |
| PATCH            | /draft/v1/schema-type/{name}          | Update a schema (non-breaking only)                                                                                                                   |
| DELETE           | /draft/v1/schema-type/{name}          | Delete a schema (no records may exist, and no other schema may reference it)                                                                          |
| GET              | /draft/v1/schema-usage                | Schema and indexed-field counts against the org’s limits, and per-schema field and record counts                                                      |
| PUT, GET, DELETE | /draft/v1/schema-type/{name}/settings | Data Center settings for a schema: preview\_url, schema\_display\_field and list\_fields (up to 8 columns shown in the record list)                   |

## Schema, Document Management Endpoints

| Method | Path                                                 | Description                                                                      |
| ------ | ---------------------------------------------------- | -------------------------------------------------------------------------------- |
| POST   | /draft/v1/document/schema                            | Create a new record (schema\_name, schema\_content and contributors in the body) |
| GET    | /draft/v1/schema-type/{name}/projections             | List records for a schema                                                        |
| GET    | /draft/v1/document/schema/{id}                       | Get a single record                                                              |
| PUT    | /draft/v1/document/schema/{id}/revision/draft        | Update a record’s draft                                                          |
| POST   | /draft/v1/document/schema/{id}/revision/published    | Publish a record                                                                 |
| DELETE | /draft/v1/document/schema/{id}/revision/published    | Unpublish a record                                                               |
| PUT    | /draft/v1/document/schema/{id}/circulation/{website} | Circulate a record to a website                                                  |
| DELETE | /draft/v1/document/schema/{id}                       | Delete a record                                                                  |

See https://alc-swagger-template.s3.amazonaws.com/docs/swagger/arc-products/prod.draft.json for Open API specs
