Properties
| Name | Type | Description |
|---|---|---|
| rules | object |
JSON Schema
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://artifacts.apis.io/sending-dev/json-schema/sending-dev-segment-preview-body-schema.json",
"title": "SegmentPreviewBody",
"x-generated": "2026-11-24",
"x-method": "derived",
"x-generator": "derive-json-schema.py",
"x-source": "openapi/sending-dev-openapi.json#/components/schemas/SegmentPreviewBody",
"type": "object",
"properties": {
"rules": {
"type": "object",
"properties": {
"combinator": {
"type": "string",
"enum": [
"and",
"or"
]
},
"rules": {
"type": "array",
"items": {
"anyOf": [
{
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"attribute"
]
},
"field": {
"type": "string",
"minLength": 1,
"maxLength": 64
},
"op": {
"type": "string",
"enum": [
"eq",
"neq",
"contains",
"gt",
"lt",
"gte",
"lte",
"exists",
"not_exists"
]
},
"value": {
"anyOf": [
{
"type": "string"
},
{
"type": "number"
},
{
"type": "boolean"
}
]
}
},
"required": [
"type",
"field",
"op"
]
},
{
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"tag"
]
},
"op": {
"type": "string",
"enum": [
"has",
"not_has"
]
},
"tagId": {
"type": "string",
"format": "uuid"
}
},
"required": [
"type",
"op",
"tagId"
]
},
{
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"list"
]
},
"op": {
"type": "string",
"enum": [
"in",
"not_in"
]
},
"listId": {
"type": "string",
"format": "uuid"
}
},
"required": [
"type",
"op",
"listId"
]
},
{
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"consent"
]
},
"channel": {
"type": "string",
"enum": [
"email",
"whatsapp",
"telegram"
]
},
"status": {
"type": "string",
"enum": [
"unknown",
"opted_in",
"opted_out",
"not_subscribed"
]
}
},
"required": [
"type",
"channel",
"status"
]
},
{
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"activity"
]
},
"kind": {
"type": "string",
"enum": [
"opened",
"clicked",
"sent",
"not_opened",
"not_clicked",
"never_sent",
"placed_order",
"not_placed_order"
]
},
"withinDays": {
"type": "integer",
"minimum": 1,
"maximum": 365
}
},
"required": [
"type",
"kind",
"withinDays"
]
},
{
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"commerce"
]
},
"metric": {
"type": "string",
"enum": [
"orders_count",
"total_spent",
"days_since_last_order"
]
},
"op": {
"type": "string",
"enum": [
">",
">=",
"<",
"<=",
"=="
]
},
"value": {
"type": "number"
}
},
"required": [
"type",
"metric",
"op",
"value"
]
},
{
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"group"
]
},
"combinator": {
"type": "string",
"enum": [
"and",
"or"
]
},
"rules": {
"type": "array",
"items": {
"anyOf": [
{
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"attribute"
]
},
"field": {
"type": "string",
"minLength": 1,
"maxLength": 64
},
"op": {
"type": "string",
"enum": [
"eq",
"neq",
"contains",
"gt",
"lt",
"gte",
"lte",
"exists",
"not_exists"
]
},
"value": {
"anyOf": [
{
"type": "string"
},
{
"type": "number"
},
{
"type": "boolean"
}
]
}
},
"required": [
"type",
"field",
"op"
]
},
{
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"tag"
]
},
"op": {
"type": "string",
"enum": [
"has",
"not_has"
]
},
"tagId": {
"type": "string",
"format": "uuid"
}
},
"required": [
"type",
"op",
"tagId"
]
},
{
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"list"
]
},
"op": {
"type": "string",
"enum": [
"in",
"not_in"
]
},
"listId": {
"type": "string",
"format": "uuid"
}
},
"required": [
"type",
"op",
"listId"
]
},
{
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"consent"
]
},
"channel": {
"type": "string",
"enum": [
"email",
"whatsapp",
"telegram"
]
},
"status": {
"type": "string",
"enum": [
"unknown",
"opted_in",
"opted_out",
"not_subscribed"
]
}
},
"required": [
"type",
"channel",
"status"
]
},
{
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"activity"
]
},
"kind": {
"type": "string",
"enum": [
"opened",
"clicked",
"sent",
"not_opened",
"not_clicked",
"never_sent",
"placed_order",
"not_placed_order"
]
},
"withinDays": {
"type": "integer",
"minimum": 1,
"maximum": 365
}
},
"required": [
"type",
"kind",
"withinDays"
]
},
{
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"commerce"
]
},
"metric": {
"type": "string",
"enum": [
"orders_count",
"total_spent",
"days_since_last_order"
]
},
"op": {
"type": "string",
"enum": [
">",
">=",
"<",
"<=",
"=="
]
},
"value": {
"type": "number"
}
},
"required": [
"type",
"metric",
"op",
"value"
]
}
]
},
"minItems": 1,
"maxItems": 20
}
},
"required": [
"type",
"combinator",
"rules"
]
}
]
},
"minItems": 1,
"maxItems": 20
}
},
"required": [
"combinator",
"rules"
]
}
},
"required": [
"rules"
]
}
Work with this as data
Every JSON Schema here is available over the APIs.io API and to AI agents over MCP.
MCP server
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
Tools for schemas
4 MCP tools reach this
find_json_schemasBrowse and filter every JSON Schema in the catalog.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.
Call it yourself
curl for this page
This JSON Schema
curl "https://apis.io/api/v1/json-schemas/sending-dev-segment-preview-body"
All schemas
curl "https://apis.io/api/v1/json-schemas?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Get an API key
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.