{
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "$id": "https://kailiniai.com/become-a-partner/apply.schema.json",
 "title": "Kailiniai.com partner expert application",
 "type": "object",
 "description": "POST application/json to /api/partner-apply. Do not invent audience numbers. Only submit data about the person you act for.",
 "required": [
  "full_name",
  "public_name",
  "email",
  "country",
  "languages",
  "niche",
  "bio_short",
  "products",
  "mini_offer_type",
  "mini_offer_description",
  "weekly_video_commitment",
  "accepts_affiliate_links_beside_video",
  "promotes_kailiniai_products_on_site",
  "terms_accepted",
  "consent_public_profile",
  "age18"
 ],
 "anyOf": [
  {
   "required": [
    "website_url"
   ]
  },
  {
   "required": [
    "instagram_url"
   ]
  },
  {
   "required": [
    "youtube_url"
   ]
  },
  {
   "required": [
    "tiktok_url"
   ]
  },
  {
   "required": [
    "x_url"
   ]
  },
  {
   "required": [
    "linkedin_url"
   ]
  }
 ],
 "properties": {
  "full_name": {
   "type": "string",
   "maxLength": 200
  },
  "public_name": {
   "type": "string",
   "maxLength": 200,
   "description": "name shown in the catalog"
  },
  "email": {
   "type": "string",
   "format": "email",
   "description": "contact only, never shown"
  },
  "country": {
   "type": "string",
   "pattern": "^[A-Za-z]{2}$",
   "description": "ISO 3166-1 alpha-2"
  },
  "languages": {
   "type": "array",
   "items": {
    "type": "string",
    "pattern": "^[a-z]{2,3}$"
   },
   "minItems": 1,
   "description": "ISO 639 codes"
  },
  "niche": {
   "enum": [
    "ai_work",
    "ecommerce",
    "marketing",
    "video",
    "voice",
    "data",
    "other"
   ]
  },
  "bio_short": {
   "type": "string",
   "maxLength": 300
  },
  "mini_offer_type": {
   "enum": [
    "lesson",
    "prompt_pack",
    "hacks",
    "template"
   ]
  },
  "mini_offer_description": {
   "type": "string",
   "maxLength": 600
  },
  "products": {
   "type": "array",
   "minItems": 1,
   "maxItems": 3,
   "items": {
    "type": "object",
    "required": [
     "title",
     "url",
     "type"
    ],
    "properties": {
     "title": {
      "type": "string"
     },
     "url": {
      "type": "string",
      "format": "uri"
     },
     "type": {
      "enum": [
       "course",
       "prompts",
       "hacks",
       "template"
      ]
     }
    }
   }
  },
  "weekly_video_commitment": {
   "const": true
  },
  "accepts_affiliate_links_beside_video": {
   "const": true
  },
  "promotes_kailiniai_products_on_site": {
   "const": true
  },
  "terms_accepted": {
   "const": true
  },
  "consent_public_profile": {
   "const": true
  },
  "age18": {
   "const": true
  },
  "referral_code_preference": {
   "type": "string",
   "pattern": "^[a-z0-9-]{0,20}$"
  },
  "submitted_by_agent": {
   "type": "boolean"
  },
  "agent_name": {
   "type": "string",
   "maxLength": 100
  },
  "utm_source": {
   "type": "string"
  },
  "utm_medium": {
   "type": "string"
  },
  "utm_campaign": {
   "type": "string"
  },
  "utm_content": {
   "type": "string"
  },
  "landing_url": {
   "type": "string"
  },
  "referrer": {
   "type": "string"
  },
  "company_website": {
   "type": "string",
   "maxLength": 0,
   "description": "honeypot, must stay empty"
  },
  "website_url": {
   "type": "string",
   "format": "uri"
  },
  "instagram_url": {
   "type": "string",
   "format": "uri"
  },
  "youtube_url": {
   "type": "string",
   "format": "uri"
  },
  "tiktok_url": {
   "type": "string",
   "format": "uri"
  },
  "x_url": {
   "type": "string",
   "format": "uri"
  },
  "linkedin_url": {
   "type": "string",
   "format": "uri"
  }
 },
 "additionalProperties": false
}