{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/everpop-app/json-schema/everpop-app-publish-destinations-envelope-schema.json",
  "title": "PublishDestinationsEnvelope",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/everpop-app-publish-api-openapi.yml#/components/schemas/PublishDestinationsEnvelope",
  "type": "object",
  "properties": {
    "ok": {
      "const": true
    },
    "data": {
      "type": "object",
      "properties": {
        "destinations": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/PublishDestination"
          },
          "description": "Connected destinations whose grant is live (not waiting for a reconnect), oldest first."
        }
      },
      "required": [
        "destinations"
      ]
    }
  },
  "required": [
    "ok",
    "data"
  ],
  "$defs": {
    "PublishDestination": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "description": "The id POST /api/v1/publish takes in destinationIds."
        },
        "platform": {
          "type": "string",
          "enum": [
            "TIKTOK",
            "INSTAGRAM_REELS",
            "YOUTUBE_SHORTS",
            "FACEBOOK_REELS",
            "THREADS"
          ]
        },
        "displayName": {
          "type": "string",
          "description": "The connected account's name — show it to the user before they confirm."
        }
      },
      "required": [
        "id",
        "platform",
        "displayName"
      ]
    }
  }
}