{
  "service": "influxdb_cloud",
  "displayName": "InfluxDB Cloud",
  "categories": [
    "Data",
    "Developer Tools"
  ],
  "authTypes": [
    "api_key"
  ],
  "auth": [
    {
      "type": "api_key",
      "label": "API Token",
      "placeholder": "INFLUX_TOKEN",
      "description": "InfluxDB Cloud API token sent with the Token authorization scheme. Create it from Load Data > API Tokens in the InfluxDB UI: https://docs.influxdata.com/influxdb3/cloud-serverless/admin/tokens/create-token/",
      "extraFields": [
        {
          "key": "apiBaseUrl",
          "label": "API Base URL",
          "inputType": "text",
          "required": true,
          "secret": false,
          "placeholder": "https://us-east-1-1.aws.cloud2.influxdata.com",
          "description": "Official API URL for your InfluxDB Cloud Serverless region: https://docs.influxdata.com/influxdb3/cloud-serverless/reference/regions/"
        }
      ]
    }
  ],
  "homepageUrl": "https://www.influxdata.com/products/influxdb-cloud/",
  "actions": [
    {
      "id": "influxdb_cloud.get_bucket",
      "service": "influxdb_cloud",
      "name": "get_bucket",
      "description": "Retrieve one InfluxDB Cloud Serverless bucket by ID.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "bucketId": {
            "type": "string",
            "minLength": 1,
            "description": "The InfluxDB bucket ID."
          }
        },
        "additionalProperties": false,
        "required": [
          "bucketId"
        ],
        "description": "Input for retrieving an InfluxDB Cloud bucket."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "bucket": {
            "type": "object",
            "properties": {},
            "additionalProperties": true,
            "description": "An InfluxDB Cloud bucket."
          }
        },
        "additionalProperties": false,
        "required": [
          "bucket"
        ],
        "description": "An InfluxDB Cloud bucket response."
      }
    },
    {
      "id": "influxdb_cloud.list_buckets",
      "service": "influxdb_cloud",
      "name": "list_buckets",
      "description": "List InfluxDB Cloud Serverless buckets visible to the connected API token.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "limit": {
            "type": "integer",
            "minimum": 1,
            "maximum": 100,
            "description": "Maximum number of buckets to return."
          },
          "offset": {
            "type": "integer",
            "minimum": 0,
            "description": "Number of buckets to skip before returning results."
          },
          "after": {
            "type": "string",
            "minLength": 1,
            "description": "Bucket ID after which to begin the page."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "description": "Return only buckets with this exact name."
          },
          "id": {
            "type": "string",
            "minLength": 1,
            "description": "Return only the bucket with this ID."
          }
        },
        "additionalProperties": false,
        "description": "Input for listing InfluxDB Cloud buckets."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "buckets": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {},
              "additionalProperties": true,
              "description": "An InfluxDB Cloud bucket."
            },
            "description": "Buckets returned by InfluxDB Cloud."
          },
          "links": {
            "type": "object",
            "properties": {
              "self": {
                "type": "string",
                "description": "The link to the current resource or page."
              },
              "next": {
                "type": "string",
                "description": "The link to the next page when available."
              },
              "prev": {
                "type": "string",
                "description": "The link to the previous page when available."
              }
            },
            "additionalProperties": true,
            "description": "Pagination and resource links returned by InfluxDB Cloud."
          }
        },
        "additionalProperties": false,
        "required": [
          "buckets",
          "links"
        ],
        "description": "A page of InfluxDB Cloud buckets."
      },
      "followUpActions": [
        "influxdb_cloud.get_bucket"
      ]
    },
    {
      "id": "influxdb_cloud.query_influxql",
      "service": "influxdb_cloud",
      "name": "query_influxql",
      "description": "Query an InfluxDB Cloud Serverless bucket with the v1-compatible InfluxQL HTTP API.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "database": {
            "type": "string",
            "minLength": 1,
            "description": "Bucket name mapped to the InfluxDB v1 database parameter."
          },
          "query": {
            "type": "string",
            "minLength": 1,
            "description": "InfluxQL query to execute."
          },
          "retentionPolicy": {
            "type": "string",
            "minLength": 1,
            "description": "Optional retention policy name for the database-retention policy mapping."
          },
          "epoch": {
            "type": "string",
            "enum": [
              "ns",
              "us",
              "ms",
              "s",
              "m",
              "h"
            ],
            "description": "Optional timestamp precision for unix epoch results."
          }
        },
        "additionalProperties": false,
        "required": [
          "database",
          "query"
        ],
        "description": "Input for querying InfluxDB Cloud with InfluxQL."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "results": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "statement_id": {
                  "type": "integer",
                  "minimum": 0,
                  "description": "The zero-based statement index."
                },
                "series": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string",
                        "description": "The measurement name."
                      },
                      "columns": {
                        "type": "array",
                        "items": {
                          "type": "string",
                          "minLength": 1
                        },
                        "description": "Column names for each returned row."
                      },
                      "values": {
                        "type": "array",
                        "items": {
                          "type": "array",
                          "items": {
                            "description": "One column value."
                          },
                          "description": "One result row."
                        },
                        "description": "Rows returned for the series."
                      }
                    },
                    "additionalProperties": true,
                    "description": "One InfluxQL series result."
                  },
                  "description": "Series returned by the statement."
                },
                "error": {
                  "type": "string",
                  "description": "An InfluxQL statement error."
                }
              },
              "additionalProperties": true,
              "description": "One InfluxQL statement result returned by InfluxDB Cloud."
            },
            "description": "InfluxQL statement results."
          }
        },
        "additionalProperties": false,
        "required": [
          "results"
        ],
        "description": "InfluxQL statement results returned by InfluxDB Cloud."
      }
    },
    {
      "id": "influxdb_cloud.write_line_protocol",
      "service": "influxdb_cloud",
      "name": "write_line_protocol",
      "description": "Synchronously write line protocol data to an InfluxDB Cloud Serverless bucket.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "database": {
            "type": "string",
            "minLength": 1,
            "description": "Bucket name mapped to the InfluxDB v1 database parameter."
          },
          "lineProtocol": {
            "type": "string",
            "minLength": 1,
            "description": "One or more newline-delimited line protocol points."
          },
          "retentionPolicy": {
            "type": "string",
            "minLength": 1,
            "description": "Optional retention policy name."
          },
          "precision": {
            "type": "string",
            "enum": [
              "ns",
              "us",
              "ms",
              "s"
            ],
            "description": "Timestamp precision used by the line protocol body."
          }
        },
        "additionalProperties": false,
        "required": [
          "database",
          "lineProtocol"
        ],
        "description": "Input for writing line protocol data to InfluxDB Cloud."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "written": {
            "type": "boolean",
            "description": "Whether at least one point was written."
          },
          "partial": {
            "type": "boolean",
            "description": "Whether InfluxDB rejected some points from the batch."
          },
          "rejected": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "code": {
                    "type": "string",
                    "description": "The provider error code."
                  },
                  "message": {
                    "type": "string",
                    "description": "The partial write error message."
                  }
                },
                "additionalProperties": true,
                "description": "Details about points rejected from a partially successful line protocol write."
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "additionalProperties": false,
        "required": [
          "written",
          "partial",
          "rejected"
        ],
        "description": "The synchronous InfluxDB Cloud write result."
      },
      "followUpActions": [
        "influxdb_cloud.query_influxql"
      ]
    }
  ]
}
