# List all warehouse sources

Returns a paginated list of all Warehouse sources for your team.

[endpoint]
base_url = "https://warehouse.betterstack.com"
path = "/api/v1/sources"
method = "GET"

[[query_param]]
name = "page"
description = "The page number to retrieve. Defaults to 1."
required = false
type = "integer"

[[query_param]]
name = "per_page"
description = "The number of items per page. Defaults to 50, maximum of 100."
required = false
type = "integer"

[[query_param]]
name = "name"
description = "Filter sources by name (case-insensitive partial match)."
required = false
type = "string"

[[header]]
name = "Authorization"
description = "Bearer `$TOKEN`"
required = true
type = "string"
[/endpoint]

[responses]
[[response]]
status = 200
description = '''A paginated list of Warehouse sources.'''
body = '''{
  "data": [
    {
      "id": "5678",
      "type": "warehouse_source",
      "attributes": {
        "warehouse_source_group_id": 1234,
        "team_id": 123456,
        "team_name": "example-team",
        "name": "Warehouse test",
        "table_name": "warehouse_test",
        "token": "abc123def456ghi789jkl012",
        "ingesting_paused": false,
        "ingesting_host": "s5678.us-east-9.betterstackdata.com",
        "created_at": "2025-10-06T09:24:10.776Z",
        "updated_at": "2025-10-21T16:38:50.712Z",
        "events_retention": 90,
        "time_series_retention": 180,
        "live_tail_pattern": "{status} {message}",
        "data_region": "us-east-9",
        "custom_bucket": null,
        "vrl_transformation": ""
      }
    }
  ],
  "pagination": {
    "first": "https://warehouse.betterstack.com/api/v1/sources?page=1",
    "last": "https://warehouse.betterstack.com/api/v1/sources?page=1",
    "prev": null,
    "next": null
  }
}'''

[[response]]
status = 401
description = '''Unauthorized'''
body = '''{
  "errors":"Invalid Team API token. How to find your Team API token: https://betterstack.com/docs/logs/api/getting-started/#obtaining-a-logtail-api-token"
}'''
[/responses]

#### Example cURL

```shell
[label Example]
curl --request GET \
  --url https://warehouse.betterstack.com/api/v1/sources \
  --header "Authorization: Bearer $TOKEN"
```
