{ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "#/components/schemas/WebExperimentsAPI", "title": "WebExperimentsAPI", "type": "object", "description": "Serializer for the exposed /api/web_experiments endpoint, to be used in posthog-js and for headless APIs.", "properties": { "id": { "type": "integer", "readOnly": true }, "name": { "type": "string", "maxLength": 400 }, "created_at": { "type": "string", "format": "date-time" }, "feature_flag_key": { "type": "string", "readOnly": true }, "variants": { "description": "Variants for the web experiment. Example:\n\n {\n \"control\": {\n \"transforms\": [\n {\n \"text\": \"Here comes Superman!\",\n \"html\": \"\",\n \"selector\": \"#page > #body > .header h1\"\n }\n ],\n \"conditions\": \"None\",\n \"rollout_percentage\": 50\n },\n }" } }, "required": [ "feature_flag_key", "id", "name", "variants" ] }