Monitoring & Reporting Write
Create a monitoring alert for your campaigns
POST https://api.adspirer.ai/api/v1/tools/create_monitor/execute
Authorization: Bearer sk_live_... — your Adspirer API key (required)Content-Type: application/json (required)Idempotency-Key: <uuid> — recommended for write operations to make retries safeAll tool arguments are wrapped in an arguments object.
| Field | Type | Description |
|---|---|---|
name | string required | Name for this alert (e.g., 'High CPA Auto-Pause', 'ROAS Scaling Rule') |
monitor_type | string optional | Type: 'performance_drop', 'budget_pace', 'anomaly_detection', 'spend_threshold', 'conversion_tracking' default: "performance_drop" |
conditions | array optional | List of conditions. Multiple conditions are evaluated with AND logic by default. For OR logic, set conditions_logic='OR'. If not provided, use the single-condition fields (metric, operator, threshold) below. |
conditions_logic | string optional | How multiple conditions combine: 'AND' (all must be true) or 'OR' (any must be true). Default: 'AND'. default: "AND" |
metric | string optional | Single condition metric (shorthand). Use 'conditions' array for multiple conditions. |
operator | string optional | Single condition operator (shorthand). |
threshold | number optional | Single condition threshold (shorthand). |
timeframe | string optional | Single condition timeframe (shorthand). |
consecutive_days | integer optional | Single condition consecutive days (shorthand). |
platforms | array optional | Platforms to monitor: ['google_ads'], ['meta_ads'], ['google_ads', 'meta_ads'], etc. Default: all connected platforms. |
campaign_ids | array optional | Specific campaign IDs to monitor. Default: all campaigns. Get IDs from list_campaigns/list_meta_campaigns tools. |
scope_level | string optional | What level to monitor: 'campaign' (default), 'ad_set' (ad group level), or 'ad' (individual ad/creative level). default: "campaign" |
alert_method | string optional | How to notify: 'email', 'slack', 'webhook'. Default: email. default: "email" |
alert_destination | string optional | Where to send alerts: email address, Slack webhook URL, etc. If not provided, uses the user's account email. |
auto_action | string optional | Automatic action when triggered: 'pause_campaign', 'increase_budget', 'decrease_budget', 'notify_only'. Default: notify_only (no automatic changes). |
auto_action_value | number optional | Value for auto-action: percentage for budget changes (e.g., 20 for +20%), ignored for pause/notify. |
check_frequency | string optional | How often to check: 'daily' — checks once per day using data through yesterday. This is the only available frequency currently. default: "daily" |
{
"arguments": {
"name": "string",
"monitor_type": "performance_drop",
"conditions": [
{
"metric": "string",
"operator": "string",
"threshold": 1.0,
"timeframe": "string",
"consecutive_days": 1,
"threshold_type": "string",
"threshold_multiplier": 1.0,
"threshold_timeframe": "string",
"direction": "string"
}
],
"conditions_logic": "AND",
"metric": "string",
"operator": "string",
"threshold": 1.0
}
}
{
"success": true,
"data": {
"text": "(tool-specific textual output for create_monitor)",
"quota": {
"used": 42,
"limit": 150,
"tier": "plus",
"period_end": "2026-05-01"
}
},
"tool": "create_monitor"
}
{
"success": false,
"error": "You have 25 meta_ads accounts connected. Please specify which account to use by passing the ad_account_id parameter:\n - Acme Holdings (ad_account_id=\"act_123456789\")\n - Acme EU (ad_account_id=\"act_987654321\")",
"is_error": true,
"tool": "create_monitor"
}
{
"success": false,
"error": "\ud83d\udea8 Monthly limit reached (150/150 tool calls on Plus tier).\nUpgrade to Pro at https://adspirer.ai to keep building.",
"is_error": true,
"tool": "create_monitor",
"quota": {
"used": 150,
"limit": 150,
"tier": "plus",
"period_end": "2026-05-01",
"upgrade_url": "https://adspirer.ai"
}
}
Interactive: Swagger UI
Machine-readable: OpenAPI 3.1 spec · llms-full.txt
More tools: Monitoring & Reporting · All tools
Adspirer REST API — get an API key at adspirer.ai/keys · adspirer.ai