{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/utmkit-co/json-schema/utmkit-co-link-schema.json",
  "title": "Link",
  "x-generated": "2026-11-27",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/utmkit-co-openapi.yml#/components/schemas/Link",
  "properties": {
    "android_url": {
      "type": [
        "string",
        "null"
      ]
    },
    "campaign_id": {
      "type": [
        "integer",
        "null"
      ]
    },
    "created_at": {
      "format": "date-time",
      "type": "string"
    },
    "created_by": {
      "properties": {
        "api_token_id": {
          "type": [
            "integer",
            "null"
          ]
        },
        "user_id": {
          "type": "integer"
        }
      },
      "type": "object"
    },
    "destination": {
      "type": "string"
    },
    "expires_at": {
      "format": "date-time",
      "type": [
        "string",
        "null"
      ]
    },
    "id": {
      "type": "integer"
    },
    "ios_url": {
      "type": [
        "string",
        "null"
      ]
    },
    "note": {
      "type": [
        "string",
        "null"
      ]
    },
    "qr_url": {
      "description": "the short URL with the scan marker",
      "format": "uri",
      "type": "string"
    },
    "short_code": {
      "type": "string"
    },
    "short_url": {
      "format": "uri",
      "type": "string"
    },
    "state": {
      "enum": [
        "live",
        "pending",
        "blocked",
        "expired"
      ],
      "type": "string"
    },
    "tags": {
      "description": "the link's tags, by name without regard to case",
      "items": {
        "properties": {
          "color": {
            "enum": [
              "gray",
              "red",
              "orange",
              "amber",
              "green",
              "teal",
              "blue",
              "purple"
            ],
            "type": "string"
          },
          "name": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "type": "array"
    },
    "utm_campaign": {
      "type": [
        "string",
        "null"
      ]
    },
    "utm_content": {
      "type": [
        "string",
        "null"
      ]
    },
    "utm_medium": {
      "type": [
        "string",
        "null"
      ]
    },
    "utm_source": {
      "type": [
        "string",
        "null"
      ]
    },
    "utm_term": {
      "type": [
        "string",
        "null"
      ]
    }
  },
  "type": "object"
}