---
title: "Find a Drain by id"
method: GET
path: "/v1/drains/{id}"
tags: ["drains"]
---

# Find a Drain by id

`GET /v1/drains/{id}`

## Request

- Base URL: `https://api.vercel.com`
- URL: `https://api.vercel.com/v1/drains/{id}`
- Auth: HTTP bearer

Get the information for a specific Drain by passing the drain id in the URL.

## Path parameters

- `id` string, required

## Query parameters

- `includeDeliveryStats` boolean: Include `deliveryStats` with the delivery health of the drain over the last 24 hours.
- `teamId` string
- `slug` string

## Response `200`

- object
  - `createdAt` number, required
  - `delivery` union, required
    - object
      - `compression` 'gzip' | 'none'
      - `encoding` 'json' | 'ndjson', required
      - `endpoint` string, required
      - `headers` object, required
      - `secret` union
        - string
        - object
          - `kind` 'INTEGRATION_SECRET', required
      - `type` 'http', required
    - object
      - `encoding` 'json' | 'proto', required
      - `endpoint` object, required
        - `traces` string, required
      - `headers` object, required
      - `secret` union
        - string
        - object
          - `kind` 'INTEGRATION_SECRET', required
      - `type` 'otlphttp', required
    - object
      - `endpoint` string, required
      - `table` string, required
      - `type` 'clickhouse', required
    - object
      - `compression` 'none', required
      - `encoding` 'json' | 'ndjson', required
      - `endpoint` string, required
      - `fileStructure` 'hive', required
      - `objectAcl` 'authenticated-read' | 'aws-exec-read' | 'bucket-owner-full-control' | 'bucket-owner-read' | 'private' | 'public-read' | 'public-read-write'
      - `region` string, required
      - `roleArn` string, required
      - `serverSideEncryption` 'AES256' | 'aws:kms' | 'aws:kms:dsse'
      - `type` 's3', required
    - object
      - `target` 'vercel-otel-traces-db', required
      - `type` 'internal', required
  - `disabledAt` number
  - `disabledBy` string
  - `disabledReason` 'account-plan-downgrade' | 'disabled-by-admin' | 'disabled-by-owner' | 'feature-not-available' | 'limits-exceeded'
  - `firstErrorTimestamp` number
  - `id` string, required
  - `name` string, required
  - `ownerId` string, required
  - `projectIds` string[]
  - `sampling` object[]
    - `env` 'preview' | 'production'
    - `rate` number, required
    - `requestPath` string
    - `type` 'head_sampling', required
  - `schemas` object, required
    - `ai_gateway` object
    - `analytics` object
    - `audit_log` object
    - `connect` object
    - `log` object
    - `speed_insights` object
    - `trace` object
  - `source` union, required
    - object
      - `defaultFor` 'eve-tracing': Informational marker for a system-owned default drain.
      - `kind` 'self-served', required
    - object
      - `externalResourceId` string
      - `integrationConfigurationId` string, required
      - `integrationId` string, required
      - `kind` 'integration', required
      - `resourceId` string
  - `status` 'disabled' | 'enabled' | 'errored'
  - `teamId` string, nullable
  - `updatedAt` number, required
  - `deliveryStats` object: Delivery health of a drain over the last 24 hours: `failing` when more than 5 delivery attempts and at least 1% of all attempts did not succeed, `healthy` otherwise, and `unknown` when there were no attempts or the stats could not be loaded.
    - `attempts` number, required: All delivery attempts in the window.
    - `failures` number, required: Delivery attempts that did not succeed in the window.
    - `state` 'failing' | 'healthy' | 'unknown', required
    - `window` '24h', required
  - `filterV2` object
    - `filter` union, required
      - object
        - `deployment` object
          - `environments` string[]
        - `log` object
          - `legacy_excludeCachedStaticAssetLogs` false | true
          - `sources` string[]
        - `project` object
          - `ids` string[]
        - `type` 'basic', required
      - object
        - `text` string, required
        - `type` 'odata', required
    - `version` 'v2', required

## Other responses

- `400`: One of the provided values in the request query is invalid.
- `401`: The request is not authorized.
- `403`: You do not have permission to access this resource.
- `404`
- `410`
- `503`: The delivery stats could not be loaded. Retry, or omit `includeDeliveryStats`.

## Changes

- **2026-10-22** `e93418e871dc`: 1 info
  - added the non-success response with the status `503`
- **2026-10-22** `4686ebfcdc1e`: 1 breaking, 20 info
  - the response's body type changed from no type to `object` for status `200`
  - added the new optional `query` request parameter `includeDeliveryStats`
  - removed `subschema #1, subschema #2` from the response body `oneOf` list for the response status `200`
  - added the optional property `deliveryStats` to the response with the `200` status
  - …17 more
- **2026-09-22** `0f7ea3d3b39b`: 1 breaking, 1 info
  - added `subschema #1, subschema #2` to the response body `oneOf` list for the response status `200`
  - removed `subschema #1, subschema #2` from the response body `oneOf` list for the response status `200`
- **2026-08-21** `915cc4809c98`: 1 breaking, 1 info
  - added `subschema #1, subschema #2` to the response body `oneOf` list for the response status `200`
  - removed `subschema #1, subschema #2` from the response body `oneOf` list for the response status `200`
- **2026-07-26** `01c71864fa50`: 1 breaking, 1 info
  - added `subschema #1, subschema #2` to the response body `oneOf` list for the response status `200`
  - removed `subschema #1, subschema #2` from the response body `oneOf` list for the response status `200`

[Operation history](https://skmtc.dev/vercel/apis/vercel-api/changes/v1/drains/:id/get.md)

---

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