{
    "schemes": [
        "https"
    ],
    "swagger": "2.0",
    "info": {
        "description": "This is the WebhookRelay API.",
        "title": "WebhookRelay API reference",
        "contact": {
            "name": "WebhookRelay support",
            "url": "https://my.webhookrelay.com/",
            "email": "info@webhookrelay.com"
        },
        "version": "0.1"        
    },
    "host": "my.webhookrelay.com",
    "paths": {
        "/v1/account/api-key": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Get the account API key. If no key exists, a new one will be generated.",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "account"
                ],
                "summary": "Get account API key",
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.AccountAPIKey"
                        }
                    },
                    "401": {
                        "description": "Unauthorized",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "500": {
                        "description": "Internal server error",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            },
            "put": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Enable or disable the account API key without regenerating it.",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "account"
                ],
                "summary": "Enable or disable account API key",
                "parameters": [
                    {
                        "description": "API key status",
                        "name": "request",
                        "in": "body",
                        "required": true,
                        "schema": {
                            "$ref": "#/definitions/structs.UpdateAPIKeyStatusRequest"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.UpdateAPIKeyStatusResponse"
                        }
                    },
                    "400": {
                        "description": "Bad request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "401": {
                        "description": "Unauthorized",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "500": {
                        "description": "Internal server error",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            },
            "post": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Generate a new API key for the account, replacing the existing one.",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "account"
                ],
                "summary": "Regenerate account API key",
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.AccountAPIKey"
                        }
                    },
                    "401": {
                        "description": "Unauthorized",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "500": {
                        "description": "Internal server error",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/billing-details": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Get the billing details for the authenticated account",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "billing"
                ],
                "summary": "Get billing details",
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.BillingDetails"
                        }
                    },
                    "404": {
                        "description": "Not Found",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "500": {
                        "description": "Internal Server Error",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            },
            "put": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Update the billing details for the authenticated account",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "billing"
                ],
                "summary": "Update billing details",
                "parameters": [
                    {
                        "description": "Billing details",
                        "name": "billingDetails",
                        "in": "body",
                        "required": true,
                        "schema": {
                            "$ref": "#/definitions/structs.BillingDetails"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.BillingDetails"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "404": {
                        "description": "Not Found",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "412": {
                        "description": "Precondition Failed",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "500": {
                        "description": "Internal Server Error",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/buckets": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Get list of all buckets for the authenticated account",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "buckets"
                ],
                "summary": "List account buckets",
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "type": "array",
                            "items": {
                                "$ref": "#/definitions/structs.Bucket"
                            }
                        }
                    }
                }
            },
            "post": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Create a new webhook bucket for the authenticated account",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "buckets"
                ],
                "summary": "Create a new bucket",
                "parameters": [
                    {
                        "description": "Bucket configuration",
                        "name": "bucket",
                        "in": "body",
                        "required": true,
                        "schema": {
                            "$ref": "#/definitions/structs.Bucket"
                        }
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Created",
                        "schema": {
                            "$ref": "#/definitions/structs.Bucket"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "412": {
                        "description": "Precondition Failed",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/buckets/{id}": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Get details of a specific bucket by ID",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "buckets"
                ],
                "summary": "Get bucket details",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Bucket ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.Bucket"
                        }
                    },
                    "403": {
                        "description": "Forbidden",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "404": {
                        "description": "Not Found",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            },
            "put": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Update an existing bucket configuration",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "buckets"
                ],
                "summary": "Update bucket",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Bucket ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    },
                    {
                        "description": "Updated bucket configuration",
                        "name": "bucket",
                        "in": "body",
                        "required": true,
                        "schema": {
                            "$ref": "#/definitions/structs.Bucket"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.Bucket"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "404": {
                        "description": "Not Found",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "412": {
                        "description": "Precondition Failed",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            },
            "delete": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Delete a bucket by ID. Bucket must not have any inputs or outputs unless force parameter is used",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "buckets"
                ],
                "summary": "Delete bucket",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Bucket ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    },
                    {
                        "type": "boolean",
                        "description": "Force delete even if bucket has inputs or outputs",
                        "name": "force",
                        "in": "query"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/api.Response"
                        }
                    },
                    "403": {
                        "description": "Forbidden",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "404": {
                        "description": "Not Found",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "412": {
                        "description": "Precondition Failed",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/buckets/{id}/inputs": {
            "post": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Create a new input endpoint for a bucket",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "inputs"
                ],
                "summary": "Create input",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Bucket ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    },
                    {
                        "description": "Input configuration",
                        "name": "input",
                        "in": "body",
                        "required": true,
                        "schema": {
                            "$ref": "#/definitions/structs.Input"
                        }
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Created",
                        "schema": {
                            "$ref": "#/definitions/structs.Input"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "412": {
                        "description": "Precondition Failed",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/buckets/{id}/inputs/{detailed}": {
            "put": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Update an existing input endpoint configuration",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "inputs"
                ],
                "summary": "Update input",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Bucket ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    },
                    {
                        "type": "string",
                        "description": "Input ID",
                        "name": "detailed",
                        "in": "path",
                        "required": true
                    },
                    {
                        "description": "Updated input configuration",
                        "name": "input",
                        "in": "body",
                        "required": true,
                        "schema": {
                            "$ref": "#/definitions/structs.Input"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.Input"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "404": {
                        "description": "Not Found",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "412": {
                        "description": "Precondition Failed",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            },
            "delete": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Delete an input endpoint by ID",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "inputs"
                ],
                "summary": "Delete input",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Bucket ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    },
                    {
                        "type": "string",
                        "description": "Input ID",
                        "name": "detailed",
                        "in": "path",
                        "required": true
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/api.Response"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "404": {
                        "description": "Not Found",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/buckets/{id}/outputs": {
            "post": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Create a new output destination for a bucket",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "outputs"
                ],
                "summary": "Create output",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Bucket ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    },
                    {
                        "description": "Output configuration",
                        "name": "output",
                        "in": "body",
                        "required": true,
                        "schema": {
                            "$ref": "#/definitions/structs.Output"
                        }
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Created",
                        "schema": {
                            "$ref": "#/definitions/structs.Output"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "402": {
                        "description": "Payment Required",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "404": {
                        "description": "Not Found",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "412": {
                        "description": "Precondition Failed",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/buckets/{id}/outputs/{detailed}": {
            "put": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Update an existing output destination configuration",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "outputs"
                ],
                "summary": "Update output",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Bucket ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    },
                    {
                        "type": "string",
                        "description": "Output ID",
                        "name": "detailed",
                        "in": "path",
                        "required": true
                    },
                    {
                        "description": "Updated output configuration",
                        "name": "output",
                        "in": "body",
                        "required": true,
                        "schema": {
                            "$ref": "#/definitions/structs.Output"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.Output"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "404": {
                        "description": "Not Found",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "412": {
                        "description": "Precondition Failed",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            },
            "delete": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Delete an output destination by ID",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "outputs"
                ],
                "summary": "Delete output",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Bucket ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    },
                    {
                        "type": "string",
                        "description": "Output ID",
                        "name": "detailed",
                        "in": "path",
                        "required": true
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/api.Response"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "404": {
                        "description": "Not Found",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/buckets/{id}/outputs/{detailed}/rules": {
            "put": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Update filtering rules for an output destination",
                "tags": [
                    "outputs"
                ],
                "summary": "Update output rules",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Bucket ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    },
                    {
                        "type": "string",
                        "description": "Output ID",
                        "name": "detailed",
                        "in": "path",
                        "required": true
                    },
                    {
                        "description": "Output rules configuration",
                        "name": "rules",
                        "in": "body",
                        "required": true,
                        "schema": {
                            "type": "object"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.Output"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "404": {
                        "description": "Not Found",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            },
            "delete": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Delete filtering rules from an output destination",
                "tags": [
                    "outputs"
                ],
                "summary": "Delete output rules",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Bucket ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    },
                    {
                        "type": "string",
                        "description": "Output ID",
                        "name": "detailed",
                        "in": "path",
                        "required": true
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.Output"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "404": {
                        "description": "Not Found",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/checkout": {
            "post": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Initiates stripe checkout session, new subscription will be created",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "billing"
                ],
                "summary": "Initiates stripe checkout session, new subscription will be created",
                "parameters": [
                    {
                        "description": "Plan request",
                        "name": "planReq",
                        "in": "body",
                        "required": true,
                        "schema": {
                            "$ref": "#/definitions/api.planChangeRequest"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/api.planChangeResponse"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "404": {
                        "description": "Not Found",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "412": {
                        "description": "Precondition Failed",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "500": {
                        "description": "Internal Server Error",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/checkout-setup": {
            "post": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Start a checkout session setup for the authenticated account",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "billing"
                ],
                "summary": "Start checkout session setup",
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/api.planChangeResponse"
                        }
                    },
                    "500": {
                        "description": "Internal Server Error",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/config": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Get the server config",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "config"
                ],
                "summary": "Get server config",
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/api.ServerConfig"
                        }
                    }
                }
            }
        },
        "/v1/connected-clients": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Get list of all connected clients for the authenticated account",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "connected-clients"
                ],
                "summary": "Get connected clients",
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.ConnectedClient"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/crons": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Get list of all cron jobs for the authenticated account",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "crons"
                ],
                "summary": "List cron jobs",
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "type": "array",
                            "items": {
                                "$ref": "#/definitions/structs.Cron"
                            }
                        }
                    }
                }
            },
            "post": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Create a new scheduled cron job",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "crons"
                ],
                "summary": "Create cron job",
                "parameters": [
                    {
                        "description": "Cron job configuration",
                        "name": "cron",
                        "in": "body",
                        "required": true,
                        "schema": {
                            "$ref": "#/definitions/structs.Cron"
                        }
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Created",
                        "schema": {
                            "$ref": "#/definitions/structs.Cron"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/crons/{id}": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Get details of a specific cron job by ID",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "crons"
                ],
                "summary": "Get cron job",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Cron ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.Cron"
                        }
                    },
                    "404": {
                        "description": "Not Found",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            },
            "put": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Update an existing cron job configuration",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "crons"
                ],
                "summary": "Update cron job",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Cron ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    },
                    {
                        "description": "Updated cron job configuration",
                        "name": "cron",
                        "in": "body",
                        "required": true,
                        "schema": {
                            "$ref": "#/definitions/structs.Cron"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.Cron"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "404": {
                        "description": "Not Found",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            },
            "delete": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Delete a cron job by ID",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "crons"
                ],
                "summary": "Delete cron job",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Cron ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    }
                ],
                "responses": {
                    "204": {
                        "description": "No Content",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "404": {
                        "description": "Not Found",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/domains": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Get list of all domains for the authenticated account",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "domains"
                ],
                "summary": "List account domains",
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "type": "array",
                            "items": {
                                "$ref": "#/definitions/structs.Domain"
                            }
                        }
                    }
                }
            },
            "post": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Reserve a domain for the authenticated account. Domain must be valid and not already taken.",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "domains"
                ],
                "summary": "Create domain reservation",
                "parameters": [
                    {
                        "description": "Domain configuration",
                        "name": "domain",
                        "in": "body",
                        "required": true,
                        "schema": {
                            "$ref": "#/definitions/structs.Domain"
                        }
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Created",
                        "schema": {
                            "$ref": "#/definitions/structs.Domain"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "412": {
                        "description": "Precondition Failed",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "451": {
                        "description": "Unavailable For Legal Reasons",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/domains/{id}": {
            "delete": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Delete a reserved domain by ID. Domain must not be in use by any inputs or tunnels.",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "domains"
                ],
                "summary": "Delete domain reservation",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Domain ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/api.Response"
                        }
                    },
                    "404": {
                        "description": "Not Found",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "412": {
                        "description": "Precondition Failed",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/functions": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "List the functions for the authenticated account",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "functions"
                ],
                "summary": "List functions",
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "type": "array",
                            "items": {
                                "$ref": "#/definitions/structs.Function"
                            }
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "500": {
                        "description": "Internal Server Error",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            },
            "post": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Create a new function",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "functions"
                ],
                "summary": "Create function",
                "parameters": [
                    {
                        "description": "Function configuration",
                        "name": "functionPayload",
                        "in": "body",
                        "required": true,
                        "schema": {
                            "$ref": "#/definitions/structs.CreateFunctionRequest"
                        }
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Created",
                        "schema": {
                            "$ref": "#/definitions/structs.Function"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "500": {
                        "description": "Internal Server Error",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/functions-generate": {
            "post": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Generate a new function based on the provided input and output payloads",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "functions"
                ],
                "summary": "Generate function",
                "parameters": [
                    {
                        "description": "Function generation request",
                        "name": "generateRequest",
                        "in": "body",
                        "required": true,
                        "schema": {
                            "$ref": "#/definitions/structs.GenerateFunctionRequest"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.GenerateFunctionResponse"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "500": {
                        "description": "Internal Server Error",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/functions/{id}": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Get a function by its ID",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "functions"
                ],
                "summary": "Get function",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Function ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.Function"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "500": {
                        "description": "Internal Server Error",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            },
            "put": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Update an existing function",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "functions"
                ],
                "summary": "Update function",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Function ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    },
                    {
                        "description": "Function configuration",
                        "name": "functionPayload",
                        "in": "body",
                        "required": true,
                        "schema": {
                            "$ref": "#/definitions/structs.UpdateFunctionRequest"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.Function"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "500": {
                        "description": "Internal Server Error",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            },
            "delete": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Delete a function by its ID",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "functions"
                ],
                "summary": "Delete function",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Function ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.DeleteFunctionResponse"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "500": {
                        "description": "Internal Server Error",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/functions/{id}/config": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "List the configuration values for a given function",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "functions"
                ],
                "summary": "List function config",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Function ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "type": "array",
                            "items": {
                                "$ref": "#/definitions/structs.Variable"
                            }
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "500": {
                        "description": "Internal Server Error",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            },
            "put": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Set the configuration value for a given function",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "functions"
                ],
                "summary": "Set function config",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Function ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    },
                    {
                        "description": "Configuration value",
                        "name": "config",
                        "in": "body",
                        "required": true,
                        "schema": {
                            "$ref": "#/definitions/api.setFunctionConfigRequest"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.Variable"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "500": {
                        "description": "Internal Server Error",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/functions/{id}/config/{key}": {
            "delete": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Delete the configuration value for a given function",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "functions"
                ],
                "summary": "Delete function config value",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Function ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    },
                    {
                        "type": "string",
                        "description": "Configuration key",
                        "name": "key",
                        "in": "path",
                        "required": true
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.DeleteVariableResponse"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "500": {
                        "description": "Internal Server Error",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/functions/{id}/invoke": {
            "post": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Invoke a function by its ID",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "functions"
                ],
                "summary": "Invoke function",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Function ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.ExecuteResponse"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "500": {
                        "description": "Internal Server Error",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/functions/{id}/logs": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Get the logs for a function",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "functions"
                ],
                "summary": "Get function logs",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Function ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.ExecuteLogResponse"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "500": {
                        "description": "Internal Server Error",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/functions/{id}/logs/{logId}": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Get the logs for a function",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "functions"
                ],
                "summary": "Get function logs",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Function ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.ExecuteLogResponse"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "500": {
                        "description": "Internal Server Error",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/logs": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Get paginated list of webhook logs from warehouse for the authenticated account",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "logs"
                ],
                "summary": "List webhook logs from warehouse (paginated)",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Filter by bucket ID",
                        "name": "bucket",
                        "in": "query"
                    },
                    {
                        "type": "integer",
                        "description": "Number of results per page",
                        "name": "limit",
                        "in": "query"
                    },
                    {
                        "type": "integer",
                        "description": "Offset for pagination",
                        "name": "offset",
                        "in": "query"
                    },
                    {
                        "type": "string",
                        "description": "From date (YYYY-MM-DD or RFC3339)",
                        "name": "from",
                        "in": "query"
                    },
                    {
                        "type": "string",
                        "description": "To date (YYYY-MM-DD or RFC3339)",
                        "name": "to",
                        "in": "query"
                    },
                    {
                        "type": "string",
                        "description": "Filter by status (sent, failed, stalled, received, rejected)",
                        "name": "status",
                        "in": "query"
                    },
                    {
                        "type": "boolean",
                        "description": "Return overview without request/response body",
                        "name": "overview",
                        "in": "query"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/api.logsResponse"
                        }
                    }
                }
            }
        },
        "/v1/logs-stats": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Get account log statistics",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "logs"
                ],
                "summary": "Get account log statistics",
                "parameters": [
                    {
                        "type": "string",
                        "description": "From date (YYYY-MM-DD)",
                        "name": "from",
                        "in": "query"
                    },
                    {
                        "type": "string",
                        "description": "To date (YYYY-MM-DD)",
                        "name": "to",
                        "in": "query"
                    },
                    {
                        "type": "string",
                        "description": "Filter by bucket ID",
                        "name": "bucketId",
                        "in": "query"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "type": "array",
                            "items": {
                                "$ref": "#/definitions/structs.LogsStats"
                            }
                        }
                    }
                }
            }
        },
        "/v1/logs/{id}": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Get detailed information about a specific webhook log from warehouse",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "logs"
                ],
                "summary": "Get log details from warehouse",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Log ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.Log"
                        }
                    },
                    "404": {
                        "description": "Not Found",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            },
            "put": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Update a webhook log. Can be used to update status, response body, headers and status code. Only modifiable within first 10 seconds.",
                "tags": [
                    "logs"
                ],
                "summary": "Update log",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Log ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    },
                    {
                        "description": "Updated log data",
                        "name": "log",
                        "in": "body",
                        "required": true,
                        "schema": {
                            "$ref": "#/definitions/structs.Log"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "404": {
                        "description": "Not Found",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/logs/{id}/action": {
            "post": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Perform an action on a webhook log from warehouse (e.g., resend)",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "logs"
                ],
                "summary": "Perform action on log from warehouse",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Log ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    },
                    {
                        "description": "Action request",
                        "name": "action",
                        "in": "body",
                        "required": true,
                        "schema": {
                            "$ref": "#/definitions/api.actionLogRequest"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "404": {
                        "description": "Not Found",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/managed-certs": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Get list of all managed certificates for the authenticated account",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "managed-certs"
                ],
                "summary": "List managed certificates",
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "type": "array",
                            "items": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "post": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Create a new managed SSL certificate for a domain",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "managed-certs"
                ],
                "summary": "Create managed certificate",
                "parameters": [
                    {
                        "description": "Managed certificate configuration",
                        "name": "cert",
                        "in": "body",
                        "required": true,
                        "schema": {
                            "$ref": "#/definitions/api.createManagedCertRequest"
                        }
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Created",
                        "schema": {
                            "$ref": "#/definitions/api.Response"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "451": {
                        "description": "Unavailable For Legal Reasons",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/managed-certs/{id}": {
            "delete": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Delete a managed certificate by ID",
                "tags": [
                    "managed-certs"
                ],
                "summary": "Delete managed certificate",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Managed certificate ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/api.Response"
                        }
                    }
                }
            }
        },
        "/v1/news": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Get all news entries",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "news"
                ],
                "summary": "Get news entries",
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "type": "array",
                            "items": {
                                "$ref": "#/definitions/structs.NewsEntry"
                            }
                        }
                    },
                    "500": {
                        "description": "Internal Server Error",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            },
            "post": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Create a new news entry",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "news"
                ],
                "summary": "Create news entry",
                "parameters": [
                    {
                        "description": "News entry",
                        "name": "newsEntry",
                        "in": "body",
                        "required": true,
                        "schema": {
                            "$ref": "#/definitions/structs.NewsEntryCreateRequest"
                        }
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Created",
                        "schema": {
                            "$ref": "#/definitions/api.Response"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "500": {
                        "description": "Internal Server Error",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/news/{id}": {
            "delete": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Delete a news entry by ID",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "news"
                ],
                "summary": "Delete news entry",
                "parameters": [
                    {
                        "type": "string",
                        "description": "News entry ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/api.Response"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "500": {
                        "description": "Internal Server Error",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/sub-accounts": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Get list of all sub-accounts for the authenticated account",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "sub-accounts"
                ],
                "summary": "Get sub-accounts",
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "type": "array",
                            "items": {
                                "$ref": "#/definitions/structs.SubAccount"
                            }
                        }
                    }
                }
            },
            "post": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Create a new sub-account for the authenticated account",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "sub-accounts"
                ],
                "summary": "Create sub-account",
                "parameters": [
                    {
                        "description": "Sub-account configuration",
                        "name": "subAccount",
                        "in": "body",
                        "schema": {
                            "$ref": "#/definitions/structs.SubAccountCreateRequest"
                        }
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Created",
                        "schema": {
                            "$ref": "#/definitions/structs.SubAccountCreateResponse"
                        }
                    }
                }
            }
        },
        "/v1/sub-accounts/{id}": {
            "delete": {
                "description": "Delete a sub-account for the authenticated account",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "sub-accounts"
                ],
                "summary": "Delete sub-account",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Sub-account ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/v1/sub-accounts/{id}/reset-password": {
            "post": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Reset the password for a sub-account",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "sub-accounts"
                ],
                "summary": "Reset sub-account password",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Sub-account ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Created",
                        "schema": {
                            "$ref": "#/definitions/structs.SubAccountCreateResponse"
                        }
                    }
                }
            }
        },
        "/v1/subscription": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Returns current subscription info",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "subscriptions"
                ],
                "summary": "Returns current subscription info",
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.SubscriptionResponse"
                        }
                    }
                }
            }
        },
        "/v1/subscription-metadata": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Returns subscription metadata",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "subscriptions"
                ],
                "summary": "Returns subscription metadata",
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.PlanMeta"
                        }
                    }
                }
            }
        },
        "/v1/tokens": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Get list of all access tokens for the authenticated account",
                "tags": [
                    "tokens"
                ],
                "summary": "List access tokens",
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "type": "array",
                            "items": {
                                "$ref": "#/definitions/structs.AccessToken"
                            }
                        }
                    }
                }
            },
            "post": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Create a new access token for the authenticated account",
                "tags": [
                    "tokens"
                ],
                "summary": "Create access token",
                "parameters": [
                    {
                        "description": "Access token configuration",
                        "name": "token",
                        "in": "body",
                        "schema": {
                            "$ref": "#/definitions/api.createAccessTokenRequest"
                        }
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Created",
                        "schema": {
                            "$ref": "#/definitions/api.accessTokenCreateResponse"
                        }
                    },
                    "412": {
                        "description": "Precondition Failed",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/tokens/{id}": {
            "put": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Update an existing access token configuration",
                "tags": [
                    "tokens"
                ],
                "summary": "Update access token",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Access token ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    },
                    {
                        "description": "Updated access token configuration",
                        "name": "token",
                        "in": "body",
                        "required": true,
                        "schema": {
                            "$ref": "#/definitions/api.updateAccessTokenRequest"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.AccessToken"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "404": {
                        "description": "Not Found",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            },
            "delete": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Delete an access token by ID",
                "tags": [
                    "tokens"
                ],
                "summary": "Delete access token",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Access token ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "404": {
                        "description": "Not Found",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/tunnels": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Get list of all tunnels for the authenticated account",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "tunnels"
                ],
                "summary": "List tunnels",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Filter by host",
                        "name": "host",
                        "in": "query"
                    },
                    {
                        "type": "string",
                        "description": "Filter by name",
                        "name": "name",
                        "in": "query"
                    },
                    {
                        "type": "string",
                        "description": "Filter by group",
                        "name": "group",
                        "in": "query"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "type": "array",
                            "items": {
                                "$ref": "#/definitions/structs.Tunnel"
                            }
                        }
                    }
                }
            },
            "post": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Create a new tunnel for the authenticated account",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "tunnels"
                ],
                "summary": "Create tunnel",
                "parameters": [
                    {
                        "description": "Tunnel configuration",
                        "name": "tunnel",
                        "in": "body",
                        "required": true,
                        "schema": {
                            "$ref": "#/definitions/structs.CreateTunnelRequest"
                        }
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Created",
                        "schema": {
                            "$ref": "#/definitions/structs.Tunnel"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "412": {
                        "description": "Precondition Failed",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/tunnels/{id}": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Get details of a specific tunnel by ID",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "tunnels"
                ],
                "summary": "Get tunnel details",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Tunnel ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.Tunnel"
                        }
                    },
                    "404": {
                        "description": "Not Found",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            },
            "put": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Update an existing tunnel configuration",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "tunnels"
                ],
                "summary": "Update tunnel",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Tunnel ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    },
                    {
                        "description": "Updated tunnel configuration",
                        "name": "tunnel",
                        "in": "body",
                        "required": true,
                        "schema": {
                            "$ref": "#/definitions/structs.Tunnel"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.Tunnel"
                        }
                    },
                    "400": {
                        "description": "Bad Request",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "404": {
                        "description": "Not Found",
                        "schema": {
                            "type": "string"
                        }
                    },
                    "412": {
                        "description": "Precondition Failed",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            },
            "delete": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Delete a tunnel by ID",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "tunnels"
                ],
                "summary": "Delete tunnel",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Tunnel ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/api.Response"
                        }
                    },
                    "404": {
                        "description": "Not Found",
                        "schema": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "/v1/usage": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Get usage for the authenticated account",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "usage"
                ],
                "summary": "Get current account usage",
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.CombinedUsage"
                        }
                    }
                }
            }
        },
        "/v1/usages/{id}": {
            "get": {
                "security": [
                    {
                        "BearerAuth": []
                    }
                ],
                "description": "Get usage for a specific account",
                "consumes": [
                    "application/json"
                ],
                "produces": [
                    "application/json"
                ],
                "tags": [
                    "usage"
                ],
                "summary": "Get account usage",
                "parameters": [
                    {
                        "type": "string",
                        "description": "Account ID",
                        "name": "id",
                        "in": "path",
                        "required": true
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/structs.CombinedUsage"
                        }
                    }
                }
            }
        }
    },
    "definitions": {
        "api.Response": {
            "type": "object",
            "properties": {
                "id": {
                    "type": "string"
                },
                "status": {
                    "type": "string"
                }
            }
        },
        "api.ServerConfig": {
            "type": "object",
            "properties": {
                "turnstile_disabled": {
                    "type": "boolean"
                },
                "version": {
                    "type": "string"
                }
            }
        },
        "api.accessTokenCreateResponse": {
            "type": "object",
            "properties": {
                "key": {
                    "type": "string"
                },
                "secret": {
                    "type": "string"
                }
            }
        },
        "api.actionLogRequest": {
            "type": "object",
            "properties": {
                "action": {
                    "type": "string"
                },
                "output": {
                    "description": "output ID, if not specified defaults to original output",
                    "type": "string"
                },
                "process_policy": {
                    "description": "skip/force",
                    "type": "string"
                }
            }
        },
        "api.createAccessTokenRequest": {
            "type": "object",
            "properties": {
                "api_access": {
                    "type": "string"
                },
                "description": {
                    "type": "string"
                },
                "scopes": {
                    "$ref": "#/definitions/api.tokenScopes"
                }
            }
        },
        "api.createManagedCertRequest": {
            "type": "object",
            "properties": {
                "domain": {
                    "type": "string"
                },
                "name": {
                    "type": "string"
                },
                "options": {
                    "type": "object",
                    "additionalProperties": {
                        "type": "string"
                    }
                },
                "provider": {
                    "type": "string"
                }
            }
        },
        "api.logsResponse": {
            "type": "object",
            "properties": {
                "data": {
                    "type": "array",
                    "items": {
                        "$ref": "#/definitions/structs.Log"
                    }
                },
                "limit": {
                    "type": "integer"
                },
                "offset": {
                    "type": "integer"
                },
                "total": {
                    "type": "integer"
                }
            }
        },
        "api.planChangeRequest": {
            "type": "object",
            "properties": {
                "plan_id": {
                    "type": "string"
                }
            }
        },
        "api.planChangeResponse": {
            "type": "object",
            "properties": {
                "checkout_required": {
                    "description": "usually true, this is when frontend should call stripe lib",
                    "type": "boolean"
                },
                "publishable_key": {
                    "type": "string"
                },
                "session_id": {
                    "type": "string"
                }
            }
        },
        "api.setFunctionConfigRequest": {
            "type": "object",
            "properties": {
                "key": {
                    "type": "string"
                },
                "value": {
                    "type": "string"
                }
            }
        },
        "api.tokenScopes": {
            "type": "object",
            "properties": {
                "buckets": {
                    "type": "array",
                    "items": {
                        "type": "string"
                    }
                },
                "tunnels": {
                    "type": "array",
                    "items": {
                        "type": "string"
                    }
                }
            }
        },
        "api.updateAccessTokenRequest": {
            "type": "object",
            "properties": {
                "api_access": {
                    "type": "string"
                },
                "description": {
                    "type": "string"
                },
                "scopes": {
                    "$ref": "#/definitions/api.tokenScopes"
                }
            }
        },
        "structs.APIAccess": {
            "type": "integer",
            "enum": [
                0,
                1,
                2
            ],
            "x-enum-varnames": [
                "APIAccessNone",
                "APIAccessDisabled",
                "APIAccessEnabled"
            ]
        },
        "structs.AccessToken": {
            "type": "object",
            "properties": {
                "active": {
                    "type": "boolean"
                },
                "api_access": {
                    "$ref": "#/definitions/structs.APIAccess"
                },
                "created_at": {
                    "type": "string"
                },
                "deleted_at": {
                    "type": "string"
                },
                "description": {
                    "type": "string"
                },
                "id": {
                    "type": "string"
                },
                "last_login": {
                    "type": "string"
                },
                "scopes": {
                    "$ref": "#/definitions/structs.Metadata"
                },
                "updated_at": {
                    "type": "string"
                }
            }
        },
        "structs.Account": {
            "type": "object",
            "properties": {
                "access_tokens": {
                    "type": "array",
                    "items": {
                        "$ref": "#/definitions/structs.AccessToken"
                    }
                },
                "active": {
                    "type": "boolean"
                },
                "auth_type": {
                    "description": "authentication type (regular/github/google)",
                    "allOf": [
                        {
                            "$ref": "#/definitions/structs.AccountAuthType"
                        }
                    ]
                },
                "avatar_url": {
                    "type": "string"
                },
                "buckets": {
                    "type": "array",
                    "items": {
                        "$ref": "#/definitions/structs.Bucket"
                    }
                },
                "company_name": {
                    "type": "string"
                },
                "created_at": {
                    "type": "string"
                },
                "current_period_end": {
                    "type": "integer"
                },
                "current_period_start": {
                    "description": "subscription period start and end, updated by stripe",
                    "type": "integer"
                },
                "deleted_at": {
                    "type": "string"
                },
                "domains": {
                    "type": "array",
                    "items": {
                        "$ref": "#/definitions/structs.Domain"
                    }
                },
                "email": {
                    "type": "string"
                },
                "email_verified": {
                    "type": "boolean"
                },
                "failed_login_attempts": {
                    "type": "integer"
                },
                "first_name": {
                    "type": "string"
                },
                "id": {
                    "type": "string"
                },
                "last_failed_login": {
                    "type": "string"
                },
                "last_login_at": {
                    "type": "string"
                },
                "last_name": {
                    "type": "string"
                },
                "plan_id": {
                    "description": "desired plan ID, used when registering new account\nto create new subscription in Stripe after\nemail is verified",
                    "type": "string"
                },
                "plan_meta": {
                    "$ref": "#/definitions/structs.Metadata"
                },
                "role": {
                    "type": "string"
                },
                "sub_accounts": {
                    "type": "array",
                    "items": {
                        "$ref": "#/definitions/structs.SubAccount"
                    }
                },
                "subscription_created": {
                    "description": "Unix ts",
                    "type": "integer"
                },
                "subscription_meta": {
                    "$ref": "#/definitions/structs.Metadata"
                },
                "subscription_status": {
                    "description": "Subscription status and fields",
                    "type": "string"
                },
                "suspend_protection": {
                    "description": "SuspendProtection prevents account's buckets from being suspended for\noveruse",
                    "type": "boolean"
                },
                "tunnels": {
                    "type": "array",
                    "items": {
                        "$ref": "#/definitions/structs.Tunnel"
                    }
                },
                "updated_at": {
                    "type": "string"
                },
                "usage_alerts": {
                    "type": "boolean"
                },
                "usage_alerts_email": {
                    "type": "string"
                },
                "use_case": {
                    "description": "Why have they registered?",
                    "type": "string"
                },
                "use_case_completed": {
                    "type": "boolean"
                },
                "username": {
                    "type": "string"
                },
                "webhookCounts": {
                    "type": "array",
                    "items": {
                        "$ref": "#/definitions/structs.WebhooksCount"
                    }
                }
            }
        },
        "structs.AccountAPIKey": {
            "type": "object",
            "properties": {
                "api_key": {
                    "type": "string"
                }
            }
        },
        "structs.AccountAuthType": {
            "type": "string",
            "enum": [
                "regular",
                "github",
                "google",
                "saml"
            ],
            "x-enum-varnames": [
                "AccountAuthTypeRegular",
                "AccountAuthTypeGithub",
                "AccountAuthTypeGoogle",
                "AccountAuthTypeSAML"
            ]
        },
        "structs.AuthType": {
            "type": "integer",
            "enum": [
                0,
                1,
                2
            ],
            "x-enum-varnames": [
                "AuthTypeNone",
                "AuthTypeBasic",
                "AuthTypeToken"
            ]
        },
        "structs.BillingDetails": {
            "type": "object",
            "properties": {
                "city": {
                    "type": "string"
                },
                "country": {
                    "type": "string"
                },
                "customer_id": {
                    "type": "string"
                },
                "email": {
                    "type": "string"
                },
                "line1": {
                    "type": "string"
                },
                "line2": {
                    "type": "string"
                },
                "name": {
                    "description": "Customer full name or business name",
                    "type": "string"
                },
                "postal_code": {
                    "type": "string"
                },
                "state": {
                    "type": "string"
                },
                "tax_id": {
                    "description": "Value of the tax ID.",
                    "type": "string"
                },
                "tax_id_type": {
                    "description": "Type of the tax ID, one of `ae_trn`, `au_abn`, `au_arn`, `bg_uic`, `br_cnpj`, `br_cpf`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `ch_vat`, `cl_tin`, `es_cif`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `hk_br`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `kr_brn`, `li_uid`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `no_vat`, `nz_gst`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `th_vat`, `tw_vat`, `ua_vat`, `us_ein`, or `za_vat`",
                    "type": "string"
                }
            }
        },
        "structs.Bucket": {
            "type": "object",
            "properties": {
                "account_id": {
                    "type": "string"
                },
                "auth": {
                    "$ref": "#/definitions/structs.BucketAuth"
                },
                "created_at": {
                    "type": "integer"
                },
                "cron_id": {
                    "type": "string"
                },
                "description": {
                    "type": "string"
                },
                "ephemeral": {
                    "description": "If true, doesn't save request body, query or headers",
                    "type": "boolean"
                },
                "id": {
                    "type": "string"
                },
                "inputs": {
                    "type": "array",
                    "items": {
                        "$ref": "#/definitions/structs.Input"
                    }
                },
                "integration_configurations": {
                    "type": "array",
                    "items": {
                        "$ref": "#/definitions/structs.IntegrationConfiguration"
                    }
                },
                "large_webhooks": {
                    "description": "LargeWebhooks - if set, we allow larger than 3MB webhooks\nto be sent to the bucket. This is useful for large file uploads",
                    "type": "boolean"
                },
                "name": {
                    "type": "string"
                },
                "outputs": {
                    "type": "array",
                    "items": {
                        "$ref": "#/definitions/structs.Output"
                    }
                },
                "static_ip": {
                    "description": "StaticIP - if set, the bucket will use a static IP (routing through forwarding proxy)",
                    "type": "boolean"
                },
                "stream": {
                    "description": "enable/disable websocket streaming for the bucket",
                    "type": "boolean"
                },
                "suspended": {
                    "description": "Set to TRUE by the curator if accounts goes over the\nwebhook limit",
                    "type": "boolean"
                },
                "updated_at": {
                    "type": "integer"
                }
            }
        },
        "structs.BucketAuth": {
            "type": "object",
            "properties": {
                "created_at": {
                    "type": "integer"
                },
                "id": {
                    "type": "string"
                },
                "password": {
                    "type": "string"
                },
                "token": {
                    "type": "string"
                },
                "type": {
                    "$ref": "#/definitions/structs.AuthType"
                },
                "updated_at": {
                    "type": "integer"
                },
                "username": {
                    "type": "string"
                }
            }
        },
        "structs.CombinedUsage": {
            "type": "object",
            "properties": {
                "plan_meta": {
                    "$ref": "#/definitions/structs.PlanMeta"
                },
                "usage": {
                    "$ref": "#/definitions/structs.Usage"
                }
            }
        },
        "structs.ConnectedClient": {
            "type": "object",
            "properties": {
                "tunnel_clients": {
                    "type": "array",
                    "items": {
                        "$ref": "#/definitions/structs.ConnectedTunnelClient"
                    }
                },
                "webhook_clients": {
                    "type": "array",
                    "items": {
                        "$ref": "#/definitions/structs.ConnectedWebhookClient"
                    }
                }
            }
        },
        "structs.ConnectedTunnelClient": {
            "type": "object",
            "properties": {
                "access_token_key": {
                    "type": "string"
                },
                "client_ip": {
                    "type": "string"
                },
                "client_version": {
                    "type": "string"
                },
                "subscribed_at": {
                    "type": "integer"
                },
                "tunnels": {
                    "type": "array",
                    "items": {
                        "type": "string"
                    }
                }
            }
        },
        "structs.ConnectedWebhookClient": {
            "type": "object",
            "properties": {
                "access_token_key": {
                    "type": "string"
                },
                "buckets": {
                    "type": "array",
                    "items": {
                        "type": "string"
                    }
                },
                "client_ip": {
                    "type": "string"
                },
                "client_type": {
                    "type": "string"
                },
                "client_version": {
                    "type": "string"
                },
                "destination": {
                    "type": "string"
                },
                "subscribed_at": {
                    "type": "integer"
                }
            }
        },
        "structs.CreateFunctionRequest": {
            "type": "object",
            "properties": {
                "driver": {
                    "type": "string"
                },
                "name": {
                    "type": "string"
                },
                "payload": {
                    "type": "string"
                }
            }
        },
        "structs.CreateTunnelRequest": {
            "type": "object",
            "properties": {
                "addr": {
                    "description": "Addr specifies TCP address server would listen on, it's required\nfor TCP tunnels.",
                    "type": "string"
                },
                "agent_id": {
                    "type": "string"
                },
                "auth": {
                    "$ref": "#/definitions/structs.TunnelAuth"
                },
                "crypto": {
                    "type": "string"
                },
                "description": {
                    "type": "string"
                },
                "destination": {
                    "type": "string"
                },
                "features": {
                    "$ref": "#/definitions/structs.Features"
                },
                "group": {
                    "type": "string"
                },
                "host": {
                    "type": "string"
                },
                "ingress_rules": {
                    "$ref": "#/definitions/structs.IngressRules"
                },
                "name": {
                    "type": "string"
                },
                "protocol": {
                    "type": "string"
                },
                "region": {
                    "type": "string"
                },
                "subdomain": {
                    "type": "string"
                }
            }
        },
        "structs.Cron": {
            "type": "object",
            "properties": {
                "account_id": {
                    "type": "string"
                },
                "bucket": {
                    "$ref": "#/definitions/structs.Bucket"
                },
                "created_at": {
                    "type": "string"
                },
                "destination": {
                    "description": "URL to send the webhook to",
                    "type": "string"
                },
                "enabled": {
                    "type": "boolean"
                },
                "ends_at": {
                    "type": "string"
                },
                "function_id": {
                    "description": "Function ID attached to the output",
                    "type": "string"
                },
                "headers": {
                    "$ref": "#/definitions/structs.Headers"
                },
                "id": {
                    "type": "string"
                },
                "method": {
                    "description": "Payload and headers injected into the Bucket. Outputs\nare still used to send the webhook",
                    "type": "string"
                },
                "name": {
                    "type": "string"
                },
                "next_run": {
                    "description": "Populated by the handler for UI to display",
                    "type": "string"
                },
                "payload": {
                    "type": "string"
                },
                "recurring": {
                    "type": "boolean"
                },
                "schedule": {
                    "type": "string"
                },
                "starts_at": {
                    "description": "Dates from which the cron job starts and ends",
                    "type": "string"
                },
                "timezone": {
                    "type": "string"
                },
                "updated_at": {
                    "type": "string"
                }
            }
        },
        "structs.DeleteFunctionResponse": {
            "type": "object"
        },
        "structs.DeleteVariableResponse": {
            "type": "object"
        },
        "structs.Domain": {
            "type": "object",
            "properties": {
                "created_at": {
                    "type": "integer"
                },
                "domain": {
                    "description": "Domain can be any 3rd party domain such as\nuser.example.com",
                    "type": "string"
                },
                "id": {
                    "type": "string"
                },
                "updated_at": {
                    "type": "integer"
                }
            }
        },
        "structs.Endpoint": {
            "type": "object",
            "properties": {
                "address": {
                    "type": "string"
                }
            }
        },
        "structs.ExecuteLog": {
            "type": "object",
            "properties": {
                "account_id": {
                    "type": "string"
                },
                "configuration_id": {
                    "type": "string"
                },
                "created": {
                    "type": "integer"
                },
                "duration": {
                    "type": "integer"
                },
                "execute_request": {
                    "$ref": "#/definitions/structs.ExecuteRequest"
                },
                "execute_response": {
                    "$ref": "#/definitions/structs.ExecuteResponse"
                },
                "function_id": {
                    "type": "string"
                },
                "id": {
                    "type": "string"
                },
                "status": {
                    "$ref": "#/definitions/structs.ExecutionStatus"
                },
                "updated": {
                    "type": "integer"
                }
            }
        },
        "structs.ExecuteLogResponse": {
            "type": "object",
            "properties": {
                "execute_logs": {
                    "type": "array",
                    "items": {
                        "$ref": "#/definitions/structs.ExecuteLog"
                    }
                },
                "limit": {
                    "type": "integer"
                },
                "offset": {
                    "type": "integer"
                },
                "total": {
                    "type": "integer"
                }
            }
        },
        "structs.ExecuteRequest": {
            "type": "object",
            "properties": {
                "account_id": {
                    "type": "string"
                },
                "configuration_id": {
                    "type": "string"
                },
                "function_id": {
                    "type": "string"
                },
                "request": {
                    "$ref": "#/definitions/structs.Request"
                },
                "request_id": {
                    "type": "string"
                },
                "response_body_path": {
                    "type": "string"
                }
            }
        },
        "structs.ExecuteResponse": {
            "type": "object",
            "properties": {
                "error": {
                    "type": "string"
                },
                "function_id": {
                    "type": "string"
                },
                "request": {
                    "$ref": "#/definitions/structs.Request"
                },
                "request_id": {
                    "type": "string"
                },
                "request_modified": {
                    "type": "boolean"
                },
                "response": {
                    "$ref": "#/definitions/structs.Response"
                },
                "response_modified": {
                    "type": "boolean"
                },
                "stop_forwarding": {
                    "type": "boolean"
                }
            }
        },
        "structs.ExecutionStatus": {
            "type": "string",
            "enum": [
                "none",
                "success",
                "error"
            ],
            "x-enum-comments": {
                "ExecutionStatusError": "2",
                "ExecutionStatusNone": "0",
                "ExecutionStatusSuccess": "1"
            },
            "x-enum-varnames": [
                "ExecutionStatusNone",
                "ExecutionStatusSuccess",
                "ExecutionStatusError"
            ]
        },
        "structs.Features": {
            "type": "object",
            "properties": {
                "rewrite_host_header": {
                    "type": "string"
                },
                "skip_insecure_verify": {
                    "description": "validate TLS certificate",
                    "type": "boolean"
                }
            }
        },
        "structs.Function": {
            "type": "object",
            "properties": {
                "account_id": {
                    "type": "string"
                },
                "compression": {
                    "type": "string"
                },
                "created": {
                    "type": "integer"
                },
                "driver": {
                    "type": "string"
                },
                "id": {
                    "type": "string"
                },
                "metadata": {
                    "type": "object",
                    "additionalProperties": {
                        "type": "string"
                    }
                },
                "name": {
                    "type": "string"
                },
                "payload": {
                    "type": "string"
                },
                "payload_size": {
                    "type": "integer"
                },
                "updated": {
                    "type": "integer"
                }
            }
        },
        "structs.GenerateFunctionRequest": {
            "type": "object",
            "properties": {
                "additional_info": {
                    "description": "Additional information about the function",
                    "type": "string"
                },
                "input_payload": {
                    "type": "string"
                },
                "output_payload": {
                    "description": "Desired output payload",
                    "type": "string"
                }
            }
        },
        "structs.GenerateFunctionResponse": {
            "type": "object",
            "properties": {
                "code": {
                    "description": "Function code",
                    "type": "string"
                },
                "validation_err": {
                    "description": "Validation error message",
                    "type": "string"
                },
                "validation_ok": {
                    "description": "Indicates if the function is valid",
                    "type": "boolean"
                }
            }
        },
        "structs.Header": {
            "type": "object",
            "properties": {
                "values": {
                    "type": "array",
                    "items": {
                        "type": "string"
                    }
                }
            }
        },
        "structs.Headers": {
            "type": "object",
            "additionalProperties": true
        },
        "structs.IngressRule": {
            "type": "object",
            "properties": {
                "endpoints": {
                    "description": "Endpoints",
                    "type": "array",
                    "items": {
                        "$ref": "#/definitions/structs.Endpoint"
                    }
                },
                "name": {
                    "description": "Name is an option identifier for the ingress rule, it usually is a service name\nif used with webrelay-ingress",
                    "type": "string"
                },
                "path": {
                    "description": "Path is an extended POSIX regex as defined by IEEE Std 1003.1,\n(i.e this follows the egrep/unix syntax, not the perl syntax)\nmatched against the path of an incoming request. Currently it can\ncontain characters disallowed from the conventional \"path\"\npart of a URL as defined by RFC 3986. Paths must begin with\na '/'. If unspecified, the path defaults to a catch all sending\ntraffic to the backend.\n+optional",
                    "type": "string"
                }
            }
        },
        "structs.IngressRules": {
            "type": "object",
            "properties": {
                "rules": {
                    "type": "array",
                    "items": {
                        "$ref": "#/definitions/structs.IngressRule"
                    }
                }
            }
        },
        "structs.Input": {
            "type": "object",
            "properties": {
                "body": {
                    "type": "array",
                    "items": {
                        "type": "integer"
                    }
                },
                "bucket_id": {
                    "description": "BucketID is a foreign key",
                    "type": "string"
                },
                "created_at": {
                    "type": "integer"
                },
                "created_by": {
                    "type": "string"
                },
                "custom_domain": {
                    "description": "Input's domain name, can be set to work with the CNAMEs\nso WHR will fetch a cert from LE\n(make sure you create a CNAME DNS record for your domain to stats.uptimerobot.com.\nAnd, it can take up to 30 mins for the custom domain to be activated.)",
                    "type": "string"
                },
                "description": {
                    "type": "string"
                },
                "function_id": {
                    "type": "string"
                },
                "headers": {
                    "description": "response details",
                    "allOf": [
                        {
                            "$ref": "#/definitions/structs.Headers"
                        }
                    ]
                },
                "id": {
                    "type": "string"
                },
                "name": {
                    "type": "string"
                },
                "path_prefix": {
                    "description": "PathPrefix only works when CustomDomain is set",
                    "type": "string"
                },
                "response_from_output": {
                    "description": "either output ID or \"anyOutput\" to indicate that the first response\nfrom any output is good enough. Empty string",
                    "type": "string"
                },
                "status_code": {
                    "type": "integer"
                },
                "strip_path_prefix": {
                    "description": "StripPathPrefix indicates whether full path should be included when\nforwarding the webhook. If the path prefix is /abc and the webhook\narrives at /abc/foo, then by default the full path will be /abc/foo",
                    "type": "boolean"
                },
                "updated_at": {
                    "type": "integer"
                }
            }
        },
        "structs.IntegrationConfiguration": {
            "type": "object",
            "properties": {
                "buckets": {
                    "type": "array",
                    "items": {
                        "$ref": "#/definitions/structs.Bucket"
                    }
                },
                "configuration": {
                    "description": "notification plugin configuration, free form JSON. Each plugin parses whatever configuration\nit wants",
                    "allOf": [
                        {
                            "$ref": "#/definitions/structs.Metadata"
                        }
                    ]
                },
                "created_at": {
                    "type": "string"
                },
                "description": {
                    "type": "string"
                },
                "disabled": {
                    "description": "optionally disable notification (when you want to turn off events)",
                    "type": "boolean"
                },
                "events": {
                    "description": "event types, such as schedules.import.error",
                    "type": "array",
                    "items": {
                        "type": "string"
                    }
                },
                "id": {
                    "type": "string"
                },
                "message": {
                    "description": "read-only field populated by the plugin",
                    "type": "string"
                },
                "plugin": {
                    "description": "plugin to use, such as Slack, Webhook, Email",
                    "allOf": [
                        {
                            "$ref": "#/definitions/structs.IntegrationPlugin"
                        }
                    ]
                },
                "status": {
                    "description": "read-only field populated by the plugin",
                    "type": "string"
                },
                "updated_at": {
                    "type": "string"
                }
            }
        },
        "structs.IntegrationPlugin": {
            "type": "string",
            "enum": [
                "webhook",
                "slack"
            ],
            "x-enum-varnames": [
                "IntegrationPluginWebhook",
                "IntegrationPluginSlack"
            ]
        },
        "structs.JSONB": {
            "type": "object",
            "additionalProperties": true
        },
        "structs.Log": {
            "type": "object",
            "properties": {
                "account_id": {
                    "type": "string"
                },
                "body": {
                    "description": "Body is either set or populated from BodyBytes during MarshalJSON()",
                    "type": "string"
                },
                "bucket_id": {
                    "type": "string"
                },
                "compression": {
                    "description": "Compression indicates what compression type\nwas used",
                    "type": "string"
                },
                "created_at": {
                    "type": "integer"
                },
                "deleted_at": {
                    "type": "string"
                },
                "duration_ms": {
                    "type": "integer"
                },
                "ephemeral": {
                    "description": "If true, doesn't save request body, query or headers,\ninherits from the bucket configuration",
                    "type": "boolean"
                },
                "extra_path": {
                    "type": "string"
                },
                "headers": {
                    "description": "request details",
                    "allOf": [
                        {
                            "$ref": "#/definitions/structs.Headers"
                        }
                    ]
                },
                "id": {
                    "type": "string"
                },
                "input_id": {
                    "type": "string"
                },
                "internal": {
                    "type": "boolean"
                },
                "ip_address": {
                    "type": "string"
                },
                "method": {
                    "type": "string"
                },
                "output_id": {
                    "type": "string"
                },
                "raw_query": {
                    "type": "string"
                },
                "response_body": {
                    "type": "array",
                    "items": {
                        "type": "integer"
                    }
                },
                "response_headers": {
                    "$ref": "#/definitions/structs.Headers"
                },
                "retries": {
                    "type": "integer"
                },
                "status": {
                    "$ref": "#/definitions/structs.RequestStatus"
                },
                "status_code": {
                    "type": "integer"
                },
                "updated_at": {
                    "type": "integer"
                }
            }
        },
        "structs.LogsStats": {
            "type": "object",
            "properties": {
                "day": {
                    "type": "string"
                },
                "failures": {
                    "type": "integer"
                },
                "received": {
                    "type": "integer"
                },
                "success": {
                    "type": "integer"
                }
            }
        },
        "structs.Metadata": {
            "type": "object",
            "additionalProperties": true
        },
        "structs.NewsEntry": {
            "type": "object",
            "properties": {
                "created_at": {
                    "type": "string"
                },
                "id": {
                    "type": "string"
                },
                "message": {
                    "type": "string"
                },
                "message_of_the_day": {
                    "type": "boolean"
                },
                "timestamp": {
                    "description": "what date to show",
                    "type": "integer"
                },
                "updated_at": {
                    "type": "string"
                },
                "url": {
                    "type": "string"
                },
                "visible": {
                    "type": "boolean"
                }
            }
        },
        "structs.NewsEntryCreateRequest": {
            "type": "object",
            "properties": {
                "date": {
                    "description": "what date to show",
                    "type": "string"
                },
                "message": {
                    "type": "string"
                },
                "message_of_the_day": {
                    "type": "boolean"
                },
                "url": {
                    "type": "string"
                },
                "visible": {
                    "type": "boolean"
                }
            }
        },
        "structs.Output": {
            "type": "object",
            "properties": {
                "bucket_id": {
                    "description": "BucketID is a foreign key",
                    "type": "string"
                },
                "created_at": {
                    "type": "integer"
                },
                "created_by": {
                    "type": "string"
                },
                "cron_id": {
                    "type": "string"
                },
                "description": {
                    "type": "string"
                },
                "destination": {
                    "type": "string"
                },
                "disabled": {
                    "description": "Enable/disable output destinations",
                    "type": "boolean"
                },
                "function_id": {
                    "description": "FunctionID is used to indicate whethera code snippet should be used to\nmodify this webhook",
                    "type": "string"
                },
                "headers": {
                    "description": "Headers that will overwrite any existing headers\nfrom the incoming request",
                    "allOf": [
                        {
                            "$ref": "#/definitions/structs.Headers"
                        }
                    ]
                },
                "id": {
                    "type": "string"
                },
                "internal": {
                    "description": "internal outputs will only be relayed by agents",
                    "type": "boolean"
                },
                "lock_path": {
                    "description": "LockPath ensures that the request path cannot be changed from what is\nspecified in the destination. For example if request is coming to /v1/webhooks/xxx/github-jenkins,\nwith lock path 'false' and destination 'http://localhost:8080' it would go to http://localhost:8080/github-jenkins.\nHowever, with lock path 'true', it will be sent to 'http://localhost:8080'",
                    "type": "boolean"
                },
                "name": {
                    "type": "string"
                },
                "retries": {
                    "description": "additional retries (after the first 3 times fail). Setting\nto -1 disables retries",
                    "type": "integer"
                },
                "rules": {
                    "$ref": "#/definitions/structs.JSONB"
                },
                "timeout": {
                    "description": "response timeout",
                    "type": "integer"
                },
                "tls_verification": {
                    "description": "Controls TLS verification of the certs for public\nwebhooks",
                    "type": "boolean"
                },
                "updated_at": {
                    "type": "integer"
                }
            }
        },
        "structs.PlanMeta": {
            "type": "object",
            "properties": {
                "agents": {
                    "type": "integer"
                },
                "custom_hostnames": {
                    "type": "boolean"
                },
                "custom_subdomains": {
                    "type": "boolean"
                },
                "functions": {
                    "type": "integer"
                },
                "https_tunnels": {
                    "type": "boolean"
                },
                "inputs": {
                    "type": "integer"
                },
                "integration_configurations": {
                    "type": "integer"
                },
                "logs_retention": {
                    "type": "integer"
                },
                "managed_domains": {
                    "type": "integer"
                },
                "outputs": {
                    "type": "integer"
                },
                "overage": {
                    "type": "number"
                },
                "public": {
                    "description": "whether plan should be visible to public",
                    "type": "boolean"
                },
                "reserved_domains": {
                    "type": "integer"
                },
                "sub_accounts": {
                    "type": "integer"
                },
                "tls_tunnels": {
                    "type": "boolean"
                },
                "tokens": {
                    "type": "integer"
                },
                "tunnels": {
                    "type": "integer"
                },
                "webhooks": {
                    "type": "integer"
                }
            }
        },
        "structs.Request": {
            "type": "object",
            "properties": {
                "body": {
                    "type": "array",
                    "items": {
                        "type": "integer"
                    }
                },
                "body_modified": {
                    "type": "boolean"
                },
                "body_path": {
                    "type": "string"
                },
                "header": {
                    "type": "object",
                    "additionalProperties": {
                        "$ref": "#/definitions/structs.Header"
                    }
                },
                "header_modified": {
                    "type": "boolean"
                },
                "metadata": {
                    "type": "object",
                    "additionalProperties": {
                        "type": "string"
                    }
                },
                "method": {
                    "type": "string"
                },
                "method_modified": {
                    "type": "boolean"
                },
                "modified_body_path": {
                    "type": "string"
                },
                "path": {
                    "type": "string"
                },
                "path_modified": {
                    "type": "boolean"
                },
                "raw_query": {
                    "type": "string"
                },
                "raw_query_modified": {
                    "type": "boolean"
                }
            }
        },
        "structs.RequestStatus": {
            "type": "integer",
            "enum": [
                0,
                1,
                2,
                3,
                4,
                5
            ],
            "x-enum-comments": {
                "RequestStatusFailed": "2",
                "RequestStatusPreparing": "0",
                "RequestStatusReceived": "4",
                "RequestStatusRejected": "5",
                "RequestStatusSent": "1",
                "RequestStatusStalled": "3 - if request destination wasn't listening - incoming requests will be stalled"
            },
            "x-enum-varnames": [
                "RequestStatusPreparing",
                "RequestStatusSent",
                "RequestStatusFailed",
                "RequestStatusStalled",
                "RequestStatusReceived",
                "RequestStatusRejected"
            ]
        },
        "structs.Response": {
            "type": "object",
            "properties": {
                "body": {
                    "type": "array",
                    "items": {
                        "type": "integer"
                    }
                },
                "body_path": {
                    "type": "string"
                },
                "header": {
                    "type": "object",
                    "additionalProperties": {
                        "$ref": "#/definitions/structs.Header"
                    }
                },
                "status": {
                    "type": "integer"
                }
            }
        },
        "structs.SubAccount": {
            "type": "object",
            "properties": {
                "account": {
                    "$ref": "#/definitions/structs.Account"
                },
                "account_id": {
                    "type": "string"
                },
                "auth_type": {
                    "description": "authentication type (regular/github/google)",
                    "allOf": [
                        {
                            "$ref": "#/definitions/structs.AccountAuthType"
                        }
                    ]
                },
                "avatar_url": {
                    "type": "string"
                },
                "created_at": {
                    "type": "string"
                },
                "deleted_at": {
                    "type": "string"
                },
                "email": {
                    "type": "string"
                },
                "failed_login_attempts": {
                    "type": "integer"
                },
                "id": {
                    "type": "string"
                },
                "last_failed_login": {
                    "type": "string"
                },
                "last_login_at": {
                    "type": "string"
                },
                "saml_sso_org_id": {
                    "type": "string"
                },
                "update_password": {
                    "description": "If set, user will be asked to change the password after login",
                    "type": "boolean"
                },
                "updated_at": {
                    "type": "string"
                },
                "username": {
                    "type": "string"
                }
            }
        },
        "structs.SubAccountCreateRequest": {
            "type": "object",
            "properties": {
                "auth_type": {
                    "$ref": "#/definitions/structs.AccountAuthType"
                },
                "email": {
                    "type": "string"
                },
                "username": {
                    "type": "string"
                }
            }
        },
        "structs.SubAccountCreateResponse": {
            "type": "object",
            "properties": {
                "password": {
                    "type": "string"
                },
                "sub_account": {
                    "$ref": "#/definitions/structs.SubAccount"
                },
                "username": {
                    "type": "string"
                }
            }
        },
        "structs.SubscriptionResponse": {
            "type": "object",
            "properties": {
                "amount": {
                    "type": "integer"
                },
                "currency": {
                    "type": "string"
                },
                "current_period_end": {
                    "type": "integer"
                },
                "current_period_start": {
                    "type": "integer"
                },
                "meta_data": {
                    "$ref": "#/definitions/structs.PlanMeta"
                },
                "plan": {
                    "type": "string"
                },
                "plan_id": {
                    "type": "string"
                },
                "status": {
                    "type": "string"
                },
                "trial_end": {
                    "type": "integer"
                },
                "trial_start": {
                    "type": "integer"
                }
            }
        },
        "structs.Tunnel": {
            "type": "object",
            "properties": {
                "account_id": {
                    "type": "string"
                },
                "addr": {
                    "description": "Addr specifies TCP address server would listen on, it's required\nfor TCP tunnels.",
                    "type": "string"
                },
                "agent_id": {
                    "description": "AgentID is used by the ingress controller and is\nrandomly generated on startup. Once controller is running\nit will send periodic updates to indicate that it's still running.",
                    "type": "string"
                },
                "auth": {
                    "$ref": "#/definitions/structs.TunnelAuth"
                },
                "created_at": {
                    "type": "integer"
                },
                "crypto": {
                    "description": "crypto types, used to issue lets encrypt certs",
                    "type": "string"
                },
                "description": {
                    "type": "string"
                },
                "destination": {
                    "description": "destination host, defaults to 127.0.0.1:8000",
                    "type": "string"
                },
                "features": {
                    "$ref": "#/definitions/structs.Metadata"
                },
                "group": {
                    "description": "optional tunnel group, primarily used by the ingress to subscribe\nto specific group of tunnels",
                    "type": "string"
                },
                "host": {
                    "description": "tunnel's subdomain, random for free tier\nor named for paid subs",
                    "type": "string"
                },
                "id": {
                    "type": "string"
                },
                "ingress_rules": {
                    "$ref": "#/definitions/structs.JSONB"
                },
                "mode": {
                    "$ref": "#/definitions/structs.TunnelMode"
                },
                "name": {
                    "description": "tunnel name",
                    "type": "string"
                },
                "protocol": {
                    "description": "tunnel protocol - http/tcp",
                    "type": "string"
                },
                "region": {
                    "description": "optional tunnel region",
                    "type": "string"
                },
                "updated_at": {
                    "type": "integer"
                }
            }
        },
        "structs.TunnelAuth": {
            "type": "object",
            "properties": {
                "created_at": {
                    "type": "integer"
                },
                "id": {
                    "type": "string"
                },
                "password": {
                    "type": "string"
                },
                "token": {
                    "type": "string"
                },
                "type": {
                    "$ref": "#/definitions/structs.AuthType"
                },
                "updated_at": {
                    "type": "integer"
                },
                "username": {
                    "type": "string"
                }
            }
        },
        "structs.TunnelMode": {
            "type": "integer",
            "enum": [
                0,
                1
            ],
            "x-enum-varnames": [
                "TunnelModeInactive",
                "TunnelModeActive"
            ]
        },
        "structs.UpdateAPIKeyStatusRequest": {
            "type": "object",
            "properties": {
                "enabled": {
                    "type": "boolean"
                }
            }
        },
        "structs.UpdateAPIKeyStatusResponse": {
            "type": "object",
            "properties": {
                "enabled": {
                    "type": "boolean"
                }
            }
        },
        "structs.UpdateFunctionRequest": {
            "type": "object",
            "properties": {
                "account_id": {
                    "type": "string"
                },
                "driver": {
                    "type": "string"
                },
                "id": {
                    "type": "string"
                },
                "name": {
                    "type": "string"
                },
                "payload": {
                    "type": "string"
                }
            }
        },
        "structs.Usage": {
            "type": "object",
            "properties": {
                "account_id": {
                    "type": "string"
                },
                "agents": {
                    "description": "agents currently connected",
                    "type": "integer"
                },
                "created_at": {
                    "type": "string"
                },
                "inputs": {
                    "type": "integer"
                },
                "outputs": {
                    "type": "integer"
                },
                "tokens": {
                    "type": "integer"
                },
                "tunnels": {
                    "type": "integer"
                },
                "webhooks": {
                    "type": "integer"
                }
            }
        },
        "structs.Variable": {
            "type": "object",
            "properties": {
                "account_id": {
                    "type": "string"
                },
                "created_at": {
                    "type": "string"
                },
                "function_id": {
                    "type": "string"
                },
                "key": {
                    "type": "string"
                },
                "updated_at": {
                    "type": "string"
                },
                "value": {
                    "type": "string"
                }
            }
        },
        "structs.WebhooksCount": {
            "type": "object",
            "properties": {
                "account_id": {
                    "description": "account that it belongs to",
                    "type": "string"
                },
                "created_at": {
                    "type": "string"
                },
                "date": {
                    "description": "beginning of the day for which the webhooks are calculated",
                    "type": "string"
                },
                "failed": {
                    "type": "integer"
                },
                "id": {
                    "type": "string"
                },
                "preparing": {
                    "description": "Potential webhook statuses",
                    "type": "integer"
                },
                "received": {
                    "type": "integer"
                },
                "rejected": {
                    "type": "integer"
                },
                "sent": {
                    "type": "integer"
                },
                "stalled": {
                    "type": "integer"
                },
                "term": {
                    "description": "daily/monthly term of the calculation",
                    "allOf": [
                        {
                            "$ref": "#/definitions/structs.WebhooksCountTerm"
                        }
                    ]
                },
                "updated_at": {
                    "type": "string"
                }
            }
        },
        "structs.WebhooksCountTerm": {
            "type": "integer",
            "enum": [
                0,
                1
            ],
            "x-enum-varnames": [
                "WebhooksCountTermDaily",
                "WebhooksCountTermMonthly"
            ]
        }
    }
}