{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/creavily/json-schema/creavily-publishing-profile-save-request-schema.json",
  "title": "PublishingProfileSaveRequest",
  "x-generated": "2026-11-02",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/creavily-openapi.json#/components/schemas/PublishingProfileSaveRequest",
  "type": "object",
  "properties": {
    "organizationId": {
      "type": "string",
      "minLength": 1
    },
    "brandId": {
      "type": "string",
      "minLength": 1
    },
    "profileId": {
      "type": "string",
      "minLength": 1
    },
    "name": {
      "type": "string",
      "minLength": 1,
      "maxLength": 120
    },
    "slug": {
      "type": "string",
      "minLength": 1,
      "maxLength": 120
    },
    "description": {
      "anyOf": [
        {
          "type": "string",
          "maxLength": 500
        },
        {
          "type": "null"
        }
      ]
    },
    "isDefault": {
      "default": false,
      "type": "boolean"
    },
    "scheduleSettings": {
      "default": {},
      "type": "object",
      "propertyNames": {
        "type": "string"
      },
      "additionalProperties": {}
    },
    "commentSettings": {
      "default": {},
      "type": "object",
      "propertyNames": {
        "type": "string"
      },
      "additionalProperties": {}
    },
    "channels": {
      "default": [],
      "maxItems": 100,
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "channelAccountId": {
            "type": "string",
            "minLength": 1
          },
          "platform": {
            "type": "string",
            "enum": [
              "instagram_business",
              "instagram_standalone",
              "facebook_page",
              "threads",
              "youtube",
              "pinterest",
              "tiktok",
              "x"
            ]
          },
          "position": {
            "type": "integer",
            "minimum": 0,
            "maximum": 1000
          },
          "enabled": {
            "type": "boolean"
          },
          "settings": {
            "default": {},
            "type": "object",
            "propertyNames": {
              "type": "string"
            },
            "additionalProperties": {}
          }
        },
        "required": [
          "channelAccountId",
          "platform"
        ]
      }
    }
  },
  "required": [
    "organizationId",
    "brandId",
    "name"
  ]
}