{ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "#/components/schemas/AbTestAction", "title": "AbTestAction", "type": "object", "properties": { "id": { "description": "The real ID of an action. Not allowed on create.", "type": "string", "example": "123", "nullable": true }, "temporary_id": { "description": "A temporary ID to use only during a create operation. Existing actions should use the id field.", "type": "string", "example": "action-1", "nullable": true, "writeOnly": true }, "type": { "type": "string", "enum": [ "ab-test" ] }, "links": { "$ref": "#/components/schemas/Link", "nullable": true }, "data": { "type": "object", "properties": { "status": { "description": "Flow action status.", "type": "string", "example": "draft", "default": "draft", "enum": [ "disabled", "draft", "live", "manual" ] }, "experiment_status": { "description": "Not allowed on create.", "type": "string", "example": "draft", "default": "draft", "enum": [ "completed", "draft", "live" ] }, "main_action": { "oneOf": [ { "$ref": "#/components/schemas/SendEmailAction" }, { "$ref": "#/components/schemas/SendSmsAction" } ] }, "current_experiment": { "type": "object", "nullable": true, "properties": { "id": { "description": "Not allowed on create.", "type": "string", "nullable": true }, "name": { "type": "string", "nullable": true }, "variations": { "type": "array", "items": { "oneOf": [ { "$ref": "#/components/schemas/SendEmailAction" }, { "$ref": "#/components/schemas/SendSmsAction" } ] } }, "allocations": { "type": "object", "nullable": true }, "started": { "type": "string", "format": "date-time", "example": "2022-11-08T00:00:00+00:00", "nullable": true, "readOnly": true }, "winner_metric": { "description": "The metric to use to determine the winner of the A/B test action.\n\nNote that this is different from the metrics used as a flow trigger.", "type": "string", "enum": [ "submission", "unique-clicks", "unique-opens", "unique-placed-orders" ], "nullable": true }, "automatic_winner_selection_settings": { "$ref": "#/components/schemas/AutomaticWinnerSelectionSettings", "nullable": true } }, "required": [ "variations" ] } }, "required": [ "main_action" ] } }, "required": [ "type", "data" ] }