{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/cosmicjs-com/json-schema/cosmicjs-com-object-create-schema.json",
  "title": "ObjectCreate",
  "x-generated": "2026-11-04",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/cosmicjs-com-openapi.yml#/components/schemas/ObjectCreate",
  "type": "object",
  "required": [
    "title",
    "type"
  ],
  "properties": {
    "title": {
      "type": "string"
    },
    "type": {
      "type": "string",
      "description": "Object type slug. The type must already exist."
    },
    "slug": {
      "type": "string",
      "description": "Derived from `title` when omitted."
    },
    "status": {
      "type": "string",
      "enum": [
        "published",
        "draft"
      ]
    },
    "content": {
      "type": "string",
      "deprecated": true
    },
    "metadata": {
      "$ref": "#/$defs/Metadata"
    },
    "thumbnail": {
      "type": "string",
      "description": "Media `name`. The media must already exist in the Bucket."
    },
    "locale": {
      "type": "string"
    },
    "publish_at": {
      "type": [
        "string",
        "number"
      ],
      "description": "UNIX millisecond timestamp."
    },
    "unpublish_at": {
      "type": [
        "string",
        "number"
      ],
      "description": "UNIX millisecond timestamp."
    },
    "trigger_webhook": {
      "type": "boolean",
      "description": "Fire the corresponding Object webhook."
    }
  },
  "additionalProperties": false,
  "$defs": {
    "Metadata": {
      "type": "object",
      "description": "Values of the Metafields defined on the Object type, keyed by Metafield `key`.\n\nThe value shape follows the Metafield type, and differs between write and read for two of them:\n\n- Text, textarea, markdown, and HTML Metafields are strings. Number Metafields are numbers, switches are booleans, dates are ISO 8601 strings.\n- Object Relationship Metafields are written as an Object `id` string (or an array of ids for the multiple variant) and returned as a nested Object (or array of Objects) once `depth` is at least 1.\n- File and Image Metafields are written as a media `name` string (or an array of names) and returned as an object with `url` and `imgix_url`, plus `alt_text`, `width`, and `height` when requested via `props`.\n- Repeater Metafields are arrays of objects keyed by the child Metafield keys.",
      "additionalProperties": true
    }
  }
}