---
title: "Create a DBaaS Thanos service"
method: POST
path: "/dbaas-thanos/{name}"
tags: ["dbaas"]
---

# Create a DBaaS Thanos service

`POST /dbaas-thanos/{name}`

## Request

- Base URL: `https://api-ch-gva-2.exoscale.com/v2`
- URL: `https://api-ch-gva-2.exoscale.com/v2/dbaas-thanos/{name}`
- Auth: none declared
- TypeScript: <https://skmtc.dev/exoscale/apis/exoscale-api/docs/dbaas-thanos/:name/post.ts> (a function with typed inputs; its response is checked against the schema)

Create a DBaaS Thanos service

## Path parameters

- `name` string, required

## Request body

- object
  - `maintenance` object: Automatic maintenance settings
    - `dow` 'saturday' | 'tuesday' | 'never' | 'wednesday' | 'sunday' | 'friday' | 'monday' | 'thursday', required: Day of week for installing updates
    - `time` string, required: Time for installing updates, UTC
  - `plan` string, required: Subscription plan
  - `termination-protection` boolean: Service is protected against termination and powering off
  - `ip-filter` string[]: Allowed CIDR address blocks for incoming connections
  - `thanos-settings` JsonSchemaThanos
    - `compactor` object: Configuration options for Thanos Compactor.
      - `retention.days` integer: Retention time for data in days for each resolution (5m, 1h, raw)
    - `query` object: Configuration options for Thanos Query.
      - `query.default-evaluation-interval` string: Set the default evaluation interval for subqueries.
      - `query.lookback-delta` string: The maximum lookback duration for retrieving metrics during expression evaluations in PromQL. PromQL always evaluates the query for a certain timestamp, and it looks back for the given amount of time to get the latest sample. If it exceeds the maximum lookback delta, it assumes the series is stale and returns none (a gap). The lookback delta should be set to at least 2 times the slowest scrape interval. If unset, it will use the promql default of 5m.
      - `query.metadata.default-time-range` string: The default metadata time range duration for retrieving labels through Labels and Series API when the range parameters are not specified. The zero value means the range covers the time since the beginning.
      - `query.timeout` string: Maximum time to process a query by the query node.
      - `store.limits.request-samples` integer: The maximum samples allowed for a single Series request. The Series call fails if this limit is exceeded. Set to 0 for no limit. NOTE: For efficiency, the limit is internally implemented as 'chunks limit' considering each chunk contains a maximum of 120 samples. The default value is 100 * store.limits.request-series.
      - `store.limits.request-series` integer: The maximum series allowed for a single Series request. The Series call fails if this limit is exceeded. Set to 0 for no limit. The default value is 1000 * cpu_count.
    - `query-frontend` object: Configuration options for Thanos Query Frontend.
      - `query-range.align-range-with-step` boolean: Whether to align the query range boundaries with the step. If enabled, the query range boundaries will be aligned to the step, providing more accurate results for queries with high-resolution data.

## Response `200`

200

- Operation: Operation
  - `id` string, uuid: Operation ID
  - `reason` 'incorrect' | 'unknown' | 'unavailable' | 'forbidden' | 'busy' | 'fault' | 'partial' | 'not-found' | 'interrupted' | 'unsupported' | 'conflict': Operation failure reason
  - `reference` object: Related resource reference
    - `id` string, uuid: Reference ID
    - `link` string: Link to the referenced resource
    - `command` string: Command name
  - `message` string: Operation message
  - `state` 'failure' | 'pending' | 'success' | 'timeout': Operation status

## Changes

- **2026-03-16** `e05707a7b346`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/exoscale/apis/exoscale-api/changes/dbaas-thanos/:name/post.md)

---

[API](https://skmtc.dev/exoscale/apis/exoscale-api.md) - [All operations](https://skmtc.dev/exoscale/apis/exoscale-api/llms.txt) - [OpenAPI document](https://skmtc.dev/exoscale/apis/exoscale-api/revisions/63da6f74c845?raw)
