Skip to main content
POST
/
templates
Create a template
curl --request POST \
  --url https://api-joy.joyfill.io/v1/templates \
  --header 'Content-Type: application/json' \
  --data '{
  "identifier": "<string>",
  "name": "<string>",
  "files": [
    "<any>"
  ],
  "fields": [
    "<any>"
  ],
  "group": "<string>",
  "stage": "published"
}'
"{\n  \"type\": \"String\",\n  \"identifer\": \"String\",\n  \"name\": \"String\",\n  \"group\": \"String\",\n  \"stage\": \"String\",\n  \"files\": [\"JoyDocFile\",\"etc.\"],\n   \n}"

Headers

Authorization
string

Supports both API Key and User Access Token authorization. See https://joyfill.mintlify.app/api/authentication

Body

application/json
files
any[]
required

Array of JoyDoc file objects. See the JoyDoc data structure under the guides section.

fields
any[]
required

Array of JoyDoc field objects. See the JoyDoc data structure under the guides section to learn more.

identifier
string

Specifies a template's unique ID. Maximum length is 80 characters. Identifier cannot be changed after creation. Leave the identifier param empty to have Joyfill auto generate an identifier.

name
string
group
string

The group identifier of the group that you would like to create the document for.

stage
enum<string>
default:published
Available options:
draft,
published

Response

200 - application/json

200

The response is of type any.