{
 "openapi": "3.1.0",
 "info": {
  "title": "PingWise API",
  "version": "1.0.0",
  "description": "Monitors, incidents, groups, alert channels and status pages of a PingWise account.\n\nAuthenticate with an API key from Team → API keys: `Authorization: Bearer pw_…`. Owners make keys; a key is read only or read and write. JSON in and out; times are ISO 8601 in UTC.\n\nLimits per key: 120 reads, 20 writes and 10 checks a minute; every answer carries X-RateLimit-Limit, X-RateLimit-Remaining and X-RateLimit-Reset (Unix time), and over the limit you get 429 with Retry-After. Reads cost nothing; a monitor costs its credits, whether made here or in the panel.\n\nLists return {\"data\": […], \"next_cursor\": …}: pass next_cursor as ?cursor= until it is null. ?limit= is 1–100, 50 by default.\n\nResellers: send X-Account with a customer account’s id or slug to act inside it with your key. Each change appears in that customer’s support log as “API key “name””.",
  "contact": {
   "name": "PingWise",
   "url": "https://pingwise.com/docs/api/"
  }
 },
 "servers": [
  {
   "url": "https://app.pingwise.com/api/v1"
  }
 ],
 "security": [
  {
   "bearer": []
  }
 ],
 "tags": [
  {
   "name": "Account"
  },
  {
   "name": "Monitors"
  },
  {
   "name": "Incidents"
  },
  {
   "name": "Groups"
  },
  {
   "name": "Channels"
  },
  {
   "name": "Status pages"
  },
  {
   "name": "Probes"
  },
  {
   "name": "Reseller"
  },
  {
   "name": "Meta"
  }
 ],
 "paths": {
  "/openapi.json": {
   "get": {
    "summary": "This document",
    "tags": [
     "Meta"
    ],
    "security": [],
    "responses": {
     "200": {
      "description": "OpenAPI 3.1",
      "content": {
       "application/json": {
        "schema": {
         "type": "object"
        }
       }
      }
     }
    }
   }
  },
  "/account": {
   "get": {
    "summary": "The account the key acts in, with its credits",
    "tags": [
     "Account"
    ],
    "responses": {
     "200": {
      "description": "The account",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Account"
        }
       }
      }
     },
     "401": {
      "description": "No key, or an unknown or revoked one",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "429": {
      "description": "Over the rate limit (see Retry-After)",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    }
   },
   "parameters": [
    {
     "$ref": "#/components/parameters/xaccount"
    }
   ]
  },
  "/monitors": {
   "get": {
    "summary": "List monitors",
    "tags": [
     "Monitors"
    ],
    "responses": {
     "200": {
      "description": "A page of monitors",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "data",
          "next_cursor"
         ],
         "properties": {
          "data": {
           "type": "array",
           "items": {
            "$ref": "#/components/schemas/Monitor"
           }
          },
          "next_cursor": {
           "type": [
            "string",
            "null"
           ]
          }
         }
        }
       }
      }
     },
     "422": {
      "description": "Invalid input: fields lists the problems",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "401": {
      "description": "No key, or an unknown or revoked one",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "429": {
      "description": "Over the rate limit (see Retry-After)",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "description": "Oldest first. Paging with limit=100 and the cursor exports every monitor.",
    "parameters": [
     {
      "name": "state",
      "in": "query",
      "required": false,
      "description": "up, down (down or partial), slow or paused",
      "schema": {
       "type": "string",
       "enum": [
        "up",
        "down",
        "slow",
        "paused"
       ]
      }
     },
     {
      "name": "group",
      "in": "query",
      "required": false,
      "description": "A group id, or none",
      "schema": {
       "type": "string"
      }
     },
     {
      "name": "type",
      "in": "query",
      "required": false,
      "description": "A monitor type",
      "schema": {
       "type": "string"
      }
     },
     {
      "name": "q",
      "in": "query",
      "required": false,
      "description": "Part of the name, URL or host",
      "schema": {
       "type": "string"
      }
     },
     {
      "$ref": "#/components/parameters/limit"
     },
     {
      "$ref": "#/components/parameters/cursor"
     }
    ]
   },
   "post": {
    "summary": "Add a monitor",
    "tags": [
     "Monitors"
    ],
    "responses": {
     "201": {
      "description": "The new monitor; its first check is running",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Monitor"
        }
       }
      }
     },
     "422": {
      "description": "Invalid input: fields lists the problems",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "401": {
      "description": "No key, or an unknown or revoked one",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "403": {
      "description": "Read-only key on a write, or the account is frozen",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "429": {
      "description": "Over the rate limit (see Retry-After)",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "description": "The same rules as the panel’s New monitor form, with its messages: e.g. other ports than 80 and 443 and some check types need a verified domain. It costs credits_per_month.",
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "$ref": "#/components/schemas/MonitorInput"
       }
      }
     }
    }
   },
   "parameters": [
    {
     "$ref": "#/components/parameters/xaccount"
    }
   ]
  },
  "/monitors/{id}": {
   "get": {
    "summary": "A monitor, with uptime and its open incident",
    "tags": [
     "Monitors"
    ],
    "responses": {
     "200": {
      "description": "The monitor",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Monitor"
        }
       }
      }
     },
     "404": {
      "description": "Not found in this account",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "401": {
      "description": "No key, or an unknown or revoked one",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "429": {
      "description": "Over the rate limit (see Retry-After)",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "$ref": "#/components/parameters/id"
     }
    ]
   },
   "patch": {
    "summary": "Change a monitor",
    "tags": [
     "Monitors"
    ],
    "responses": {
     "200": {
      "description": "The monitor",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Monitor"
        }
       }
      }
     },
     "404": {
      "description": "Not found in this account",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "422": {
      "description": "Invalid input: fields lists the problems",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "401": {
      "description": "No key, or an unknown or revoked one",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "403": {
      "description": "Read-only key on a write, or the account is frozen",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "429": {
      "description": "Over the rate limit (see Retry-After)",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "description": "Only the fields sent change. On a monitor a hosting panel manages, its customer’s own key may change name, alert_partial and notes only.",
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "$ref": "#/components/schemas/MonitorInput"
       }
      }
     }
    },
    "parameters": [
     {
      "$ref": "#/components/parameters/id"
     }
    ]
   },
   "delete": {
    "summary": "Delete a monitor",
    "tags": [
     "Monitors"
    ],
    "responses": {
     "204": {
      "description": "Deleted"
     },
     "404": {
      "description": "Not found in this account",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "401": {
      "description": "No key, or an unknown or revoked one",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "403": {
      "description": "Read-only key on a write, or the account is frozen",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "429": {
      "description": "Over the rate limit (see Retry-After)",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "$ref": "#/components/parameters/id"
     }
    ]
   },
   "parameters": [
    {
     "$ref": "#/components/parameters/xaccount"
    }
   ]
  },
  "/monitors/{id}/pause": {
   "post": {
    "summary": "Pause",
    "tags": [
     "Monitors"
    ],
    "responses": {
     "200": {
      "description": "The monitor",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Monitor"
        }
       }
      }
     },
     "404": {
      "description": "Not found in this account",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "401": {
      "description": "No key, or an unknown or revoked one",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "403": {
      "description": "Read-only key on a write, or the account is frozen",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "429": {
      "description": "Over the rate limit (see Retry-After)",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "$ref": "#/components/parameters/id"
     }
    ]
   },
   "parameters": [
    {
     "$ref": "#/components/parameters/xaccount"
    }
   ]
  },
  "/monitors/{id}/resume": {
   "post": {
    "summary": "Resume",
    "tags": [
     "Monitors"
    ],
    "responses": {
     "200": {
      "description": "The monitor",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Monitor"
        }
       }
      }
     },
     "404": {
      "description": "Not found in this account",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "401": {
      "description": "No key, or an unknown or revoked one",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "403": {
      "description": "Read-only key on a write, or the account is frozen",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "429": {
      "description": "Over the rate limit (see Retry-After)",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "$ref": "#/components/parameters/id"
     }
    ]
   },
   "parameters": [
    {
     "$ref": "#/components/parameters/xaccount"
    }
   ]
  },
  "/monitors/{id}/check": {
   "post": {
    "summary": "Check now",
    "tags": [
     "Monitors"
    ],
    "responses": {
     "202": {
      "description": "Requested",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Check"
        }
       }
      }
     },
     "404": {
      "description": "Not found in this account",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "409": {
      "description": "Not possible now (see detail)",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "401": {
      "description": "No key, or an unknown or revoked one",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "403": {
      "description": "Read-only key on a write, or the account is frozen",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "429": {
      "description": "Over the rate limit (see Retry-After)",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "description": "One extra round by every healthy probe through the normal quorum, charged like a scheduled round. Once a minute per monitor, 30 an hour per account (shared with the panel), 10 a minute per key.",
    "parameters": [
     {
      "$ref": "#/components/parameters/id"
     }
    ]
   },
   "parameters": [
    {
     "$ref": "#/components/parameters/xaccount"
    }
   ]
  },
  "/monitors/{id}/incidents": {
   "get": {
    "summary": "A monitor’s incidents, newest first",
    "tags": [
     "Incidents"
    ],
    "responses": {
     "200": {
      "description": "A page of incidents",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "data",
          "next_cursor"
         ],
         "properties": {
          "data": {
           "type": "array",
           "items": {
            "$ref": "#/components/schemas/Incident"
           }
          },
          "next_cursor": {
           "type": [
            "string",
            "null"
           ]
          }
         }
        }
       }
      }
     },
     "404": {
      "description": "Not found in this account",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "401": {
      "description": "No key, or an unknown or revoked one",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "429": {
      "description": "Over the rate limit (see Retry-After)",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "$ref": "#/components/parameters/id"
     },
     {
      "name": "status",
      "in": "query",
      "required": false,
      "description": "open or resolved",
      "schema": {
       "type": "string"
      }
     },
     {
      "name": "since",
      "in": "query",
      "required": false,
      "description": "ISO 8601: started or resolved since, or still open",
      "schema": {
       "type": "string"
      }
     },
     {
      "$ref": "#/components/parameters/limit"
     },
     {
      "$ref": "#/components/parameters/cursor"
     }
    ]
   },
   "parameters": [
    {
     "$ref": "#/components/parameters/xaccount"
    }
   ]
  },
  "/incidents": {
   "get": {
    "summary": "Incidents, newest first",
    "tags": [
     "Incidents"
    ],
    "responses": {
     "200": {
      "description": "A page of incidents",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "data",
          "next_cursor"
         ],
         "properties": {
          "data": {
           "type": "array",
           "items": {
            "$ref": "#/components/schemas/Incident"
           }
          },
          "next_cursor": {
           "type": [
            "string",
            "null"
           ]
          }
         }
        }
       }
      }
     },
     "422": {
      "description": "Invalid input: fields lists the problems",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "401": {
      "description": "No key, or an unknown or revoked one",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "429": {
      "description": "Over the rate limit (see Retry-After)",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "name": "status",
      "in": "query",
      "required": false,
      "description": "open or resolved",
      "schema": {
       "type": "string",
       "enum": [
        "open",
        "resolved"
       ]
      }
     },
     {
      "name": "since",
      "in": "query",
      "required": false,
      "description": "ISO 8601: started or resolved since, or still open",
      "schema": {
       "type": "string"
      }
     },
     {
      "name": "monitor",
      "in": "query",
      "required": false,
      "description": "A monitor id",
      "schema": {
       "type": "string"
      }
     },
     {
      "$ref": "#/components/parameters/limit"
     },
     {
      "$ref": "#/components/parameters/cursor"
     }
    ]
   },
   "parameters": [
    {
     "$ref": "#/components/parameters/xaccount"
    }
   ]
  },
  "/incidents/{id}": {
   "get": {
    "summary": "An incident",
    "tags": [
     "Incidents"
    ],
    "responses": {
     "200": {
      "description": "The incident",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Incident"
        }
       }
      }
     },
     "404": {
      "description": "Not found in this account",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "401": {
      "description": "No key, or an unknown or revoked one",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "429": {
      "description": "Over the rate limit (see Retry-After)",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "$ref": "#/components/parameters/id"
     }
    ]
   },
   "parameters": [
    {
     "$ref": "#/components/parameters/xaccount"
    }
   ]
  },
  "/groups": {
   "get": {
    "summary": "Monitor groups",
    "tags": [
     "Groups"
    ],
    "responses": {
     "200": {
      "description": "A page of groups",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "data",
          "next_cursor"
         ],
         "properties": {
          "data": {
           "type": "array",
           "items": {
            "$ref": "#/components/schemas/Group"
           }
          },
          "next_cursor": {
           "type": [
            "string",
            "null"
           ]
          }
         }
        }
       }
      }
     },
     "401": {
      "description": "No key, or an unknown or revoked one",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "429": {
      "description": "Over the rate limit (see Retry-After)",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "$ref": "#/components/parameters/limit"
     },
     {
      "$ref": "#/components/parameters/cursor"
     }
    ]
   },
   "post": {
    "summary": "Add a group",
    "tags": [
     "Groups"
    ],
    "responses": {
     "201": {
      "description": "The group",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Group"
        }
       }
      }
     },
     "422": {
      "description": "Invalid input: fields lists the problems",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "401": {
      "description": "No key, or an unknown or revoked one",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "403": {
      "description": "Read-only key on a write, or the account is frozen",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "429": {
      "description": "Over the rate limit (see Retry-After)",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "$ref": "#/components/schemas/GroupInput"
       }
      }
     }
    }
   },
   "parameters": [
    {
     "$ref": "#/components/parameters/xaccount"
    }
   ]
  },
  "/groups/{id}": {
   "patch": {
    "summary": "Rename or move a group",
    "tags": [
     "Groups"
    ],
    "responses": {
     "200": {
      "description": "The group",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Group"
        }
       }
      }
     },
     "404": {
      "description": "Not found in this account",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "422": {
      "description": "Invalid input: fields lists the problems",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "401": {
      "description": "No key, or an unknown or revoked one",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "403": {
      "description": "Read-only key on a write, or the account is frozen",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "429": {
      "description": "Over the rate limit (see Retry-After)",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "$ref": "#/components/schemas/GroupInput"
       }
      }
     }
    },
    "parameters": [
     {
      "$ref": "#/components/parameters/id"
     }
    ]
   },
   "delete": {
    "summary": "Delete a group",
    "tags": [
     "Groups"
    ],
    "responses": {
     "204": {
      "description": "Deleted; its monitors stay, without a group"
     },
     "404": {
      "description": "Not found in this account",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "401": {
      "description": "No key, or an unknown or revoked one",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "403": {
      "description": "Read-only key on a write, or the account is frozen",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "429": {
      "description": "Over the rate limit (see Retry-After)",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "$ref": "#/components/parameters/id"
     }
    ]
   },
   "parameters": [
    {
     "$ref": "#/components/parameters/xaccount"
    }
   ]
  },
  "/channels": {
   "get": {
    "summary": "Alert channels (read only; addresses and secrets are never returned)",
    "tags": [
     "Channels"
    ],
    "responses": {
     "200": {
      "description": "A page of channels",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "data",
          "next_cursor"
         ],
         "properties": {
          "data": {
           "type": "array",
           "items": {
            "$ref": "#/components/schemas/Channel"
           }
          },
          "next_cursor": {
           "type": [
            "string",
            "null"
           ]
          }
         }
        }
       }
      }
     },
     "401": {
      "description": "No key, or an unknown or revoked one",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "429": {
      "description": "Over the rate limit (see Retry-After)",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "$ref": "#/components/parameters/limit"
     },
     {
      "$ref": "#/components/parameters/cursor"
     }
    ]
   },
   "parameters": [
    {
     "$ref": "#/components/parameters/xaccount"
    }
   ]
  },
  "/status-pages": {
   "get": {
    "summary": "Status pages (read only)",
    "tags": [
     "Status pages"
    ],
    "responses": {
     "200": {
      "description": "A page of status pages",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "data",
          "next_cursor"
         ],
         "properties": {
          "data": {
           "type": "array",
           "items": {
            "$ref": "#/components/schemas/StatusPage"
           }
          },
          "next_cursor": {
           "type": [
            "string",
            "null"
           ]
          }
         }
        }
       }
      }
     },
     "401": {
      "description": "No key, or an unknown or revoked one",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "429": {
      "description": "Over the rate limit (see Retry-After)",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "parameters": [
     {
      "$ref": "#/components/parameters/limit"
     },
     {
      "$ref": "#/components/parameters/cursor"
     }
    ]
   },
   "parameters": [
    {
     "$ref": "#/components/parameters/xaccount"
    }
   ]
  },
  "/probes": {
   "get": {
    "summary": "The probes that vote, with their addresses for allow-lists",
    "tags": [
     "Probes"
    ],
    "responses": {
     "200": {
      "description": "All of them",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "data",
          "next_cursor"
         ],
         "properties": {
          "data": {
           "type": "array",
           "items": {
            "$ref": "#/components/schemas/Probe"
           }
          },
          "next_cursor": {
           "type": [
            "string",
            "null"
           ]
          }
         }
        }
       }
      }
     },
     "401": {
      "description": "No key, or an unknown or revoked one",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "429": {
      "description": "Over the rate limit (see Retry-After)",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    }
   },
   "parameters": [
    {
     "$ref": "#/components/parameters/xaccount"
    }
   ]
  },
  "/accounts": {
   "get": {
    "summary": "Your customer accounts",
    "tags": [
     "Reseller"
    ],
    "responses": {
     "200": {
      "description": "A page of customers",
      "content": {
       "application/json": {
        "schema": {
         "type": "object",
         "required": [
          "data",
          "next_cursor"
         ],
         "properties": {
          "data": {
           "type": "array",
           "items": {
            "$ref": "#/components/schemas/Customer"
           }
          },
          "next_cursor": {
           "type": [
            "string",
            "null"
           ]
          }
         }
        }
       }
      }
     },
     "404": {
      "description": "Not found in this account",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "401": {
      "description": "No key, or an unknown or revoked one",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "429": {
      "description": "Over the rate limit (see Retry-After)",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "description": "Reseller accounts only (404 otherwise, and while reselling is not switched on). Not with X-Account.",
    "parameters": [
     {
      "$ref": "#/components/parameters/limit"
     },
     {
      "$ref": "#/components/parameters/cursor"
     }
    ]
   },
   "post": {
    "summary": "Add a customer account",
    "tags": [
     "Reseller"
    ],
    "responses": {
     "201": {
      "description": "The customer",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Customer"
        }
       }
      }
     },
     "404": {
      "description": "Not found in this account",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "422": {
      "description": "Invalid input: fields lists the problems",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "401": {
      "description": "No key, or an unknown or revoked one",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "403": {
      "description": "Read-only key on a write, or the account is frozen",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "429": {
      "description": "Over the rate limit (see Retry-After)",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "description": "Reseller accounts only (404 otherwise, and while reselling is not switched on). Not with X-Account.",
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "$ref": "#/components/schemas/CustomerInput"
       }
      }
     }
    }
   },
   "parameters": [
    {
     "$ref": "#/components/parameters/xaccount"
    }
   ]
  },
  "/accounts/{id}": {
   "patch": {
    "summary": "Change a customer account",
    "tags": [
     "Reseller"
    ],
    "responses": {
     "200": {
      "description": "The customer",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Customer"
        }
       }
      }
     },
     "404": {
      "description": "Not found in this account",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "422": {
      "description": "Invalid input: fields lists the problems",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "401": {
      "description": "No key, or an unknown or revoked one",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "403": {
      "description": "Read-only key on a write, or the account is frozen",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "429": {
      "description": "Over the rate limit (see Retry-After)",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "description": "Reseller accounts only (404 otherwise, and while reselling is not switched on). Not with X-Account. panel_org_id can’t change.",
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "$ref": "#/components/schemas/CustomerInput"
       }
      }
     }
    },
    "parameters": [
     {
      "$ref": "#/components/parameters/account"
     }
    ]
   },
   "parameters": [
    {
     "$ref": "#/components/parameters/xaccount"
    }
   ]
  },
  "/accounts/{id}/invites": {
   "post": {
    "summary": "Invite someone to a customer account",
    "tags": [
     "Reseller"
    ],
    "responses": {
     "201": {
      "description": "Sent",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Invite"
        }
       }
      }
     },
     "404": {
      "description": "Not found in this account",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "409": {
      "description": "Not possible now (see detail)",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "422": {
      "description": "Invalid input: fields lists the problems",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "401": {
      "description": "No key, or an unknown or revoked one",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "403": {
      "description": "Read-only key on a write, or the account is frozen",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     },
     "429": {
      "description": "Over the rate limit (see Retry-After)",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Error"
        }
       }
      }
     }
    },
    "description": "Reseller accounts only (404 otherwise, and while reselling is not switched on). Not with X-Account. The invitation email the panel sends; 409 terms_missing until your brand has its terms and privacy links.",
    "requestBody": {
     "required": true,
     "content": {
      "application/json": {
       "schema": {
        "$ref": "#/components/schemas/InviteInput"
       }
      }
     }
    },
    "parameters": [
     {
      "$ref": "#/components/parameters/account"
     }
    ]
   },
   "parameters": [
    {
     "$ref": "#/components/parameters/xaccount"
    }
   ]
  }
 },
 "components": {
  "securitySchemes": {
   "bearer": {
    "type": "http",
    "scheme": "bearer",
    "bearerFormat": "pw_ followed by 40 characters"
   }
  },
  "parameters": {
   "id": {
    "name": "id",
    "in": "path",
    "required": true,
    "schema": {
     "type": "string"
    }
   },
   "account": {
    "name": "id",
    "in": "path",
    "required": true,
    "description": "A customer account’s id or slug",
    "schema": {
     "type": "string"
    }
   },
   "limit": {
    "name": "limit",
    "in": "query",
    "required": false,
    "description": "Rows per page, 1–100",
    "schema": {
     "type": "integer",
     "minimum": 1,
     "maximum": 100,
     "default": 50
    }
   },
   "cursor": {
    "name": "cursor",
    "in": "query",
    "required": false,
    "description": "next_cursor of the previous page",
    "schema": {
     "type": "string"
    }
   },
   "xaccount": {
    "name": "X-Account",
    "in": "header",
    "required": false,
    "description": "Resellers: a customer account’s id or slug to act in.",
    "schema": {
     "type": "string"
    }
   }
  },
  "schemas": {
   "Error": {
    "type": "object",
    "required": [
     "error"
    ],
    "properties": {
     "error": {
      "type": "string",
      "enum": [
       "unauthorized",
       "forbidden",
       "account_frozen",
       "not_found",
       "invalid",
       "bad_request",
       "rate_limited",
       "not_possible",
       "terms_missing",
       "method_not_allowed"
      ]
     },
     "detail": {
      "type": "string"
     },
     "fields": {
      "type": "object",
      "additionalProperties": {
       "type": "array",
       "items": {
        "type": "string"
       }
      }
     },
     "retry_after": {
      "type": "integer"
     }
    }
   },
   "MonitorInput": {
    "type": "object",
    "additionalProperties": false,
    "properties": {
     "name": {
      "type": "string",
      "maxLength": 120,
      "description": "Defaults to the URL or host."
     },
     "type": {
      "type": "string",
      "enum": [
       "http",
       "tls",
       "tcp",
       "smtp",
       "dns",
       "ping",
       "heartbeat"
      ],
      "default": "http"
     },
     "url": {
      "type": [
       "string",
       "null"
      ],
      "maxLength": 2000,
      "description": "http: the full http(s) address."
     },
     "host": {
      "type": [
       "string",
       "null"
      ],
      "maxLength": 253,
      "description": "tls, tcp, smtp, dns, ping: the hostname."
     },
     "port": {
      "type": [
       "integer",
       "null"
      ],
      "minimum": 1,
      "maximum": 65535
     },
     "interval": {
      "type": "integer",
      "enum": [
       15,
       30,
       60,
       300,
       900,
       1800,
       3600
      ],
      "default": 60,
      "description": "Seconds between checks."
     },
     "timeout": {
      "type": "integer",
      "minimum": 1,
      "maximum": 30,
      "default": 10
     },
     "ip_version": {
      "type": "string",
      "enum": [
       "auto",
       "4",
       "6"
      ],
      "default": "auto"
     },
     "expect": {
      "type": "array",
      "items": {
       "type": "integer"
      },
      "description": "Accepted status codes; [] = any 2xx."
     },
     "keyword": {
      "type": "string",
      "maxLength": 200,
      "description": "http: text the page must contain."
     },
     "keyword_absent": {
      "type": "boolean",
      "description": "Down when the keyword IS found."
     },
     "follow_redirects": {
      "type": "boolean",
      "default": true
     },
     "verify_tls": {
      "type": "boolean",
      "default": true
     },
     "detect_error_pages": {
      "type": "boolean",
      "default": true
     },
     "cert_warn_days": {
      "type": "integer",
      "minimum": 0,
      "maximum": 90,
      "default": 14
     },
     "starttls": {
      "type": "boolean"
     },
     "expect_banner": {
      "type": "string",
      "maxLength": 200
     },
     "qname": {
      "type": "string",
      "maxLength": 253
     },
     "rtype": {
      "type": "string",
      "default": "A"
     },
     "dev_mode": {
      "type": "boolean",
      "description": "401/403/404 count as up, and no alerts are sent."
     },
     "method": {
      "type": "string",
      "enum": [
       "GET",
       "HEAD",
       "POST",
       "PUT",
       "PATCH",
       "DELETE",
       "OPTIONS"
      ],
      "default": "GET",
      "description": "Anything but GET and HEAD is sent from every probe each round and may change data."
     },
     "req_headers": {
      "oneOf": [
       {
        "type": "array",
        "items": {
         "type": "array",
         "items": {
          "type": "string"
         },
         "minItems": 2,
         "maxItems": 2
        }
       },
       {
        "type": "object",
        "additionalProperties": {
         "type": "string"
        }
       }
      ],
      "description": "Shown in the panel."
     },
     "req_body": {
      "type": "string",
      "maxLength": 10240
     },
     "req_content_type": {
      "type": "string"
     },
     "basic_user": {
      "type": "string",
      "maxLength": 200
     },
     "hb_period": {
      "type": [
       "integer",
       "null"
      ],
      "description": "heartbeat: how often the job runs (seconds)."
     },
     "hb_grace": {
      "type": [
       "integer",
       "null"
      ],
      "description": "heartbeat: how late it may be (seconds)."
     },
     "audience": {
      "type": [
       "array",
       "null"
      ],
      "items": {
       "type": "string",
       "enum": [
        "eu",
        "na",
        "sa",
        "as",
        "af",
        "oc"
       ]
      },
      "description": "Visitors’ continents; null = the account default."
     },
     "slow_ms": {
      "type": [
       "integer",
       "null"
      ],
      "minimum": 50,
      "maximum": 60000
     },
     "slow_metric": {
      "type": "string",
      "enum": [
       "ttfb",
       "server",
       "total"
      ]
     },
     "slow_scope": {
      "type": "string",
      "enum": [
       "auto",
       "audience",
       "all"
      ]
     },
     "alert_slow": {
      "type": "boolean"
     },
     "alert_partial": {
      "type": "boolean"
     },
     "excluded_continents": {
      "type": [
       "array",
       "null"
      ],
      "items": {
       "type": "string",
       "enum": [
        "eu",
        "na",
        "sa",
        "as",
        "af",
        "oc"
       ]
      },
      "description": "Continents whose probes don’t vote; null = the account default."
     },
     "group": {
      "type": [
       "integer",
       "null"
      ],
      "description": "A group id (GET /groups), or null."
     },
     "notes": {
      "type": "string",
      "maxLength": 2000,
      "description": "Plain text for your team (contact person, what to do). Sent with down alerts and reminders; never on status pages."
     },
     "secret_headers": {
      "description": "Write only: stored encrypted, never returned. [] or null removes them.",
      "oneOf": [
       {
        "type": "array",
        "items": {
         "type": "array",
         "items": {
          "type": "string"
         },
         "minItems": 2,
         "maxItems": 2
        }
       },
       {
        "type": "object",
        "additionalProperties": {
         "type": "string"
        }
       },
       {
        "type": "null"
       }
      ]
     },
     "basic_password": {
      "type": [
       "string",
       "null"
      ],
      "description": "Write only: stored encrypted."
     },
     "channels": {
      "type": "array",
      "items": {
       "type": "string",
       "format": "uuid"
      },
      "description": "Alert channels that should name this monitor. A channel that alerts for all monitors is left as it is."
     }
    }
   },
   "Monitor": {
    "type": "object",
    "properties": {
     "name": {
      "type": "string",
      "maxLength": 120,
      "description": "Defaults to the URL or host."
     },
     "type": {
      "type": "string",
      "enum": [
       "http",
       "tls",
       "tcp",
       "smtp",
       "dns",
       "ping",
       "heartbeat"
      ],
      "default": "http"
     },
     "url": {
      "type": [
       "string",
       "null"
      ],
      "maxLength": 2000,
      "description": "http: the full http(s) address."
     },
     "host": {
      "type": [
       "string",
       "null"
      ],
      "maxLength": 253,
      "description": "tls, tcp, smtp, dns, ping: the hostname."
     },
     "port": {
      "type": [
       "integer",
       "null"
      ],
      "minimum": 1,
      "maximum": 65535
     },
     "interval": {
      "type": "integer",
      "enum": [
       15,
       30,
       60,
       300,
       900,
       1800,
       3600
      ],
      "default": 60,
      "description": "Seconds between checks."
     },
     "timeout": {
      "type": "integer",
      "minimum": 1,
      "maximum": 30,
      "default": 10
     },
     "ip_version": {
      "type": "string",
      "enum": [
       "auto",
       "4",
       "6"
      ],
      "default": "auto"
     },
     "expect": {
      "type": "array",
      "items": {
       "type": "integer"
      },
      "description": "Accepted status codes; [] = any 2xx."
     },
     "keyword": {
      "type": "string",
      "maxLength": 200,
      "description": "http: text the page must contain."
     },
     "keyword_absent": {
      "type": "boolean",
      "description": "Down when the keyword IS found."
     },
     "follow_redirects": {
      "type": "boolean",
      "default": true
     },
     "verify_tls": {
      "type": "boolean",
      "default": true
     },
     "detect_error_pages": {
      "type": "boolean",
      "default": true
     },
     "cert_warn_days": {
      "type": "integer",
      "minimum": 0,
      "maximum": 90,
      "default": 14
     },
     "starttls": {
      "type": "boolean"
     },
     "expect_banner": {
      "type": "string",
      "maxLength": 200
     },
     "qname": {
      "type": "string",
      "maxLength": 253
     },
     "rtype": {
      "type": "string",
      "default": "A"
     },
     "dev_mode": {
      "type": "boolean",
      "description": "401/403/404 count as up, and no alerts are sent."
     },
     "method": {
      "type": "string",
      "enum": [
       "GET",
       "HEAD",
       "POST",
       "PUT",
       "PATCH",
       "DELETE",
       "OPTIONS"
      ],
      "default": "GET",
      "description": "Anything but GET and HEAD is sent from every probe each round and may change data."
     },
     "req_headers": {
      "oneOf": [
       {
        "type": "array",
        "items": {
         "type": "array",
         "items": {
          "type": "string"
         },
         "minItems": 2,
         "maxItems": 2
        }
       },
       {
        "type": "object",
        "additionalProperties": {
         "type": "string"
        }
       }
      ],
      "description": "Shown in the panel."
     },
     "req_body": {
      "type": "string",
      "maxLength": 10240
     },
     "req_content_type": {
      "type": "string"
     },
     "basic_user": {
      "type": "string",
      "maxLength": 200
     },
     "hb_period": {
      "type": [
       "integer",
       "null"
      ],
      "description": "heartbeat: how often the job runs (seconds)."
     },
     "hb_grace": {
      "type": [
       "integer",
       "null"
      ],
      "description": "heartbeat: how late it may be (seconds)."
     },
     "audience": {
      "type": [
       "array",
       "null"
      ],
      "items": {
       "type": "string",
       "enum": [
        "eu",
        "na",
        "sa",
        "as",
        "af",
        "oc"
       ]
      },
      "description": "Visitors’ continents; null = the account default."
     },
     "slow_ms": {
      "type": [
       "integer",
       "null"
      ],
      "minimum": 50,
      "maximum": 60000
     },
     "slow_metric": {
      "type": "string",
      "enum": [
       "ttfb",
       "server",
       "total"
      ]
     },
     "slow_scope": {
      "type": "string",
      "enum": [
       "auto",
       "audience",
       "all"
      ]
     },
     "alert_slow": {
      "type": "boolean"
     },
     "alert_partial": {
      "type": "boolean"
     },
     "excluded_continents": {
      "type": [
       "array",
       "null"
      ],
      "items": {
       "type": "string",
       "enum": [
        "eu",
        "na",
        "sa",
        "as",
        "af",
        "oc"
       ]
      },
      "description": "Continents whose probes don’t vote; null = the account default."
     },
     "group": {
      "type": [
       "integer",
       "null"
      ],
      "description": "A group id (GET /groups), or null."
     },
     "notes": {
      "type": "string",
      "maxLength": 2000,
      "description": "Plain text for your team (contact person, what to do). Sent with down alerts and reminders; never on status pages."
     },
     "id": {
      "type": "string",
      "format": "uuid"
     },
     "has_secret_headers": {
      "type": "boolean"
     },
     "has_basic_password": {
      "type": "boolean"
     },
     "ping_url": {
      "type": [
       "string",
       "null"
      ],
      "description": "heartbeat: the URL your job calls."
     },
     "channels": {
      "type": "array",
      "items": {
       "type": "string",
       "format": "uuid"
      },
      "description": "Enabled channels that alert for it."
     },
     "paused": {
      "type": "boolean"
     },
     "managed": {
      "type": "boolean",
      "description": "Kept in sync by a hosting panel integration."
     },
     "state": {
      "type": "string",
      "enum": [
       "pending",
       "up",
       "slow",
       "down",
       "partial",
       "unconfirmed",
       "blocked",
       "maintenance",
       "paused"
      ]
     },
     "since": {
      "type": [
       "string",
       "null"
      ],
      "format": "date-time"
     },
     "last_check_at": {
      "type": [
       "string",
       "null"
      ],
      "format": "date-time"
     },
     "credits_per_month": {
      "type": "integer",
      "description": "What it costs a month at its interval (0 when paused or a heartbeat)."
     },
     "created_at": {
      "type": "string",
      "format": "date-time"
     },
     "updated_at": {
      "type": "string",
      "format": "date-time"
     },
     "uptime": {
      "type": "object",
      "description": "GET /monitors/{id} only.",
      "properties": {
       "24h": {
        "type": [
         "number",
         "null"
        ]
       },
       "7d": {
        "type": [
         "number",
         "null"
        ]
       },
       "30d": {
        "type": [
         "number",
         "null"
        ]
       }
      }
     },
     "open_incident": {
      "type": [
       "integer",
       "null"
      ],
      "description": "GET /monitors/{id} only."
     }
    }
   },
   "Account": {
    "type": "object",
    "properties": {
     "id": {
      "type": "string",
      "format": "uuid"
     },
     "name": {
      "type": "string"
     },
     "slug": {
      "type": "string"
     },
     "timezone": {
      "type": "string"
     },
     "billing": {
      "type": "string"
     },
     "is_reseller": {
      "type": "boolean"
     },
     "parent": {
      "oneOf": [
       {
        "type": "object",
        "properties": {
         "id": {
          "type": "string",
          "format": "uuid"
         },
         "name": {
          "type": "string"
         }
        }
       },
       {
        "type": "null"
       }
      ]
     },
     "credits": {
      "type": "object",
      "properties": {
       "balance": {
        "type": "integer"
       },
       "month_used": {
        "type": "integer"
       },
       "free_left": {
        "type": "integer"
       },
       "daily": {
        "type": "integer"
       },
       "days_left": {
        "type": [
         "integer",
         "null"
        ]
       }
      }
     }
    }
   },
   "Incident": {
    "type": "object",
    "properties": {
     "id": {
      "type": "integer"
     },
     "monitor": {
      "type": "object",
      "properties": {
       "id": {
        "type": "string",
        "format": "uuid"
       },
       "name": {
        "type": "string"
       }
      }
     },
     "status": {
      "type": "string",
      "enum": [
       "open",
       "resolved"
      ]
     },
     "reason": {
      "type": "string"
     },
     "detail": {
      "type": "string"
     },
     "started_at": {
      "type": "string",
      "format": "date-time"
     },
     "confirmed_at": {
      "type": "string",
      "format": "date-time"
     },
     "resolved_at": {
      "type": [
       "string",
       "null"
      ],
      "format": "date-time"
     },
     "duration_s": {
      "type": [
       "integer",
       "null"
      ]
     },
     "explanation": {
      "oneOf": [
       {
        "type": "object",
        "properties": {
         "headline": {
          "type": "string"
         },
         "what_happened": {
          "type": "string"
         },
         "likely_cause": {
          "type": "string"
         },
         "what_to_do": {
          "type": "array",
          "items": {
           "type": "string"
          }
         },
         "scope": {
          "type": "string"
         },
         "confidence": {
          "type": "string"
         }
        }
       },
       {
        "type": "null"
       }
      ],
      "description": "Accounts with AI explanations only."
     }
    }
   },
   "Group": {
    "type": "object",
    "properties": {
     "id": {
      "type": "integer"
     },
     "name": {
      "type": "string",
      "maxLength": 120
     },
     "position": {
      "type": "integer"
     },
     "monitors": {
      "type": "integer"
     }
    }
   },
   "GroupInput": {
    "type": "object",
    "additionalProperties": false,
    "properties": {
     "name": {
      "type": "string",
      "maxLength": 120
     },
     "position": {
      "type": "integer",
      "minimum": 0
     }
    }
   },
   "Channel": {
    "type": "object",
    "properties": {
     "id": {
      "type": "string",
      "format": "uuid"
     },
     "kind": {
      "type": "string"
     },
     "name": {
      "type": "string"
     },
     "enabled": {
      "type": "boolean"
     },
     "verified": {
      "type": "boolean"
     },
     "all_monitors": {
      "type": "boolean"
     },
     "monitors": {
      "type": "array",
      "items": {
       "type": "string",
       "format": "uuid"
      }
     },
     "groups": {
      "type": "array",
      "items": {
       "type": "integer"
      }
     }
    }
   },
   "StatusPage": {
    "type": "object",
    "properties": {
     "id": {
      "type": "integer"
     },
     "name": {
      "type": "string"
     },
     "slug": {
      "type": "string"
     },
     "url": {
      "type": "string"
     },
     "visibility": {
      "type": "string",
      "enum": [
       "public",
       "protected",
       "private"
      ]
     },
     "brand": {
      "type": "object",
      "properties": {
       "id": {
        "type": "integer"
       },
       "name": {
        "type": "string"
       }
      }
     },
     "entries": {
      "type": "array",
      "items": {
       "type": "object",
       "properties": {
        "id": {
         "type": "integer"
        },
        "name": {
         "type": "string"
        },
        "section": {
         "type": "string"
        },
        "group": {
         "type": [
          "integer",
          "null"
         ]
        },
        "monitors": {
         "type": "array",
         "items": {
          "type": "string",
          "format": "uuid"
         }
        }
       }
      }
     }
    }
   },
   "Probe": {
    "type": "object",
    "properties": {
     "name": {
      "type": "string"
     },
     "location": {
      "type": "string"
     },
     "continent": {
      "type": "string"
     },
     "provider": {
      "type": "string"
     },
     "ipv4": {
      "type": [
       "string",
       "null"
      ]
     },
     "ipv6": {
      "type": [
       "string",
       "null"
      ]
     },
     "rdns": {
      "type": [
       "string",
       "null"
      ]
     }
    }
   },
   "Check": {
    "type": "object",
    "properties": {
     "id": {
      "type": "integer"
     },
     "monitor": {
      "type": "string",
      "format": "uuid"
     },
     "status": {
      "type": "string"
     },
     "requested_at": {
      "type": "string",
      "format": "date-time"
     }
    }
   },
   "Customer": {
    "type": "object",
    "properties": {
     "id": {
      "type": "string",
      "format": "uuid"
     },
     "slug": {
      "type": "string"
     },
     "name": {
      "type": "string"
     },
     "contact_email": {
      "type": [
       "string",
       "null"
      ]
     },
     "monthly_cap": {
      "type": [
       "integer",
       "null"
      ]
     },
     "month_used": {
      "type": "integer"
     },
     "monitors": {
      "type": "integer"
     },
     "open_incidents": {
      "type": "integer"
     },
     "panel_org_id": {
      "type": [
       "string",
       "null"
      ]
     },
     "joined": {
      "type": "boolean"
     },
     "invited": {
      "type": "boolean"
     },
     "created_at": {
      "type": "string",
      "format": "date-time"
     }
    }
   },
   "CustomerInput": {
    "type": "object",
    "additionalProperties": false,
    "properties": {
     "name": {
      "type": "string",
      "maxLength": 150
     },
     "contact_email": {
      "type": [
       "string",
       "null"
      ],
      "format": "email"
     },
     "monthly_cap": {
      "type": [
       "integer",
       "null"
      ],
      "minimum": 1,
      "description": "Credits a month this customer may use; null = no cap."
     },
     "panel_org_id": {
      "type": "string",
      "description": "POST only: an Enhance organisation whose websites are in your account; they move to the new customer and stay in sync."
     }
    }
   },
   "InviteInput": {
    "type": "object",
    "additionalProperties": false,
    "required": [
     "email"
    ],
    "properties": {
     "email": {
      "type": "string",
      "format": "email"
     },
     "role": {
      "type": "string",
      "enum": [
       "owner",
       "member",
       "viewer"
      ],
      "default": "owner"
     }
    }
   },
   "Invite": {
    "type": "object",
    "properties": {
     "id": {
      "type": "integer"
     },
     "account": {
      "type": "string",
      "format": "uuid"
     },
     "email": {
      "type": "string"
     },
     "role": {
      "type": "string"
     },
     "created_at": {
      "type": "string",
      "format": "date-time"
     },
     "expires_in_days": {
      "type": "integer"
     }
    }
   }
  }
 }
}