Plainrouter · Schema

ActionRuleDetailRead

CompanyAdvertisingDeveloper ToolsPaidAds

Properties

Name Type Description
rule object
View JSON Schema on GitHub

JSON Schema

plainrouter-action-rule-detail-read-schema.json Raw ↑
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/plainrouter/main/json-schema/plainrouter-action-rule-detail-read-schema.json",
  "title": "ActionRuleDetailRead",
  "x-generated": "2026-10-18",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/plainrouter-openapi.json#/components/schemas/ActionRuleDetailRead",
  "type": "object",
  "properties": {
    "rule": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string"
        },
        "workspace_id": {
          "type": "integer"
        },
        "platform_ad_account_id": {
          "type": "integer"
        },
        "name": {
          "type": "string"
        },
        "enabled": {
          "type": "boolean"
        },
        "suspended_at": {
          "type": [
            "string",
            "null"
          ],
          "format": "date-time"
        },
        "suspended_reason": {
          "type": [
            "string",
            "null"
          ]
        },
        "window": {
          "type": "object",
          "properties": {
            "days": {
              "type": "integer",
              "enum": [
                3
              ]
            },
            "kind": {
              "type": "string",
              "enum": [
                "last_complete_days"
              ]
            },
            "timezone": {
              "type": "string"
            }
          },
          "required": [
            "days",
            "kind",
            "timezone"
          ]
        },
        "current_revision": {
          "type": "object",
          "properties": {
            "id": {
              "type": "string"
            },
            "target_level": {
              "type": "string",
              "enum": [
                "ad",
                "ad_set",
                "campaign"
              ]
            },
            "action": {
              "type": "string",
              "enum": [
                "pause",
                "increase_budget",
                "decrease_budget"
              ]
            },
            "budget_change_percent": {
              "type": [
                "integer",
                "null"
              ]
            },
            "minimum_counted_arrivals": {
              "type": "integer"
            },
            "cost_comparison": {
              "type": "string",
              "enum": [
                "at_least",
                "at_most"
              ]
            },
            "cost_ratio": {
              "type": "string"
            },
            "author_type": {
              "type": "string",
              "enum": [
                "user",
                "agent"
              ]
            },
            "created_at": {
              "type": "string",
              "format": "date-time"
            }
          },
          "required": [
            "id",
            "target_level",
            "action",
            "budget_change_percent",
            "minimum_counted_arrivals",
            "cost_comparison",
            "cost_ratio",
            "author_type",
            "created_at"
          ]
        },
        "revisions": {
          "type": "array",
          "description": "Present on show and write responses.",
          "items": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "target_level": {
                "type": "string",
                "enum": [
                  "ad",
                  "ad_set",
                  "campaign"
                ]
              },
              "action": {
                "type": "string",
                "enum": [
                  "pause",
                  "increase_budget",
                  "decrease_budget"
                ]
              },
              "budget_change_percent": {
                "type": [
                  "integer",
                  "null"
                ]
              },
              "minimum_counted_arrivals": {
                "type": "integer"
              },
              "cost_comparison": {
                "type": "string",
                "enum": [
                  "at_least",
                  "at_most"
                ]
              },
              "cost_ratio": {
                "type": "string"
              },
              "author_type": {
                "type": "string",
                "enum": [
                  "user",
                  "agent"
                ]
              },
              "created_at": {
                "type": "string",
                "format": "date-time"
              }
            },
            "required": [
              "id",
              "target_level",
              "action",
              "budget_change_percent",
              "minimum_counted_arrivals",
              "cost_comparison",
              "cost_ratio",
              "author_type",
              "created_at"
            ]
          }
        },
        "runs": {
          "type": "array",
          "description": "Show only; at most five recent runs, each with at most 100 decisions.",
          "items": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "revision_id": {
                "type": "string"
              },
              "window_start": {
                "type": "string",
                "format": "date-time"
              },
              "window_end": {
                "type": "string",
                "format": "date-time"
              },
              "timezone": {
                "type": "string"
              },
              "status": {
                "type": "string"
              },
              "reason": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "account_spend_minor": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "account_counted_arrivals": {
                "type": [
                  "integer",
                  "null"
                ]
              },
              "evaluated_at": {
                "type": [
                  "string",
                  "null"
                ],
                "format": "date-time"
              },
              "decisions": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "id": {
                      "type": "string"
                    },
                    "target_type": {
                      "type": "string"
                    },
                    "target_id": {
                      "type": "string"
                    },
                    "target_name": {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "target_spend_minor": {
                      "type": "string"
                    },
                    "target_counted_arrivals": {
                      "type": "integer"
                    },
                    "decision": {
                      "type": "string"
                    },
                    "reason": {
                      "type": "string"
                    },
                    "action_type": {
                      "type": "string"
                    },
                    "new_daily_budget_minor": {
                      "type": [
                        "integer",
                        "null"
                      ]
                    },
                    "action_batch_id": {
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  },
                  "required": [
                    "id",
                    "target_type",
                    "target_id",
                    "target_name",
                    "target_spend_minor",
                    "target_counted_arrivals",
                    "decision",
                    "reason",
                    "action_type",
                    "new_daily_budget_minor",
                    "action_batch_id"
                  ]
                }
              },
              "decisions_truncated": {
                "type": "boolean"
              }
            },
            "required": [
              "id",
              "revision_id",
              "window_start",
              "window_end",
              "timezone",
              "status",
              "reason",
              "account_spend_minor",
              "account_counted_arrivals",
              "evaluated_at",
              "decisions",
              "decisions_truncated"
            ]
          }
        }
      },
      "required": [
        "id",
        "workspace_id",
        "platform_ad_account_id",
        "name",
        "enabled",
        "suspended_at",
        "suspended_reason",
        "window",
        "current_revision",
        "revisions",
        "runs"
      ]
    }
  },
  "required": [
    "rule"
  ]
}

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.
All 92 tools →

Call it yourself

curl for this page
This JSON Schema
curl "https://apis.io/api/v1/json-schemas/plainrouter-action-rule-detail-read"
All schemas
curl "https://apis.io/api/v1/json-schemas?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

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. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.