---
title: Retrieve a Single Data Source
description: Retrieve a single data source by `id`.
url: https://www.storyblok.com/docs/api/content-delivery/v2/data-sources/retrieve-a-single-data-source
---

# Retrieve a Single Data Source

Retrieve a single data source by `id`.

GET

```html
https://api.storyblok.com/v2/cdn/datasources/:id
```

## Path parameters

-   `:id` (required) (string)
    
    The data source’s ID. Examples: `labels` (Full slug), `66252740648132` (Numeric ID).
    

## Query parameters

-   `version` (string)
    
    Filter by the story’s publication status.
    
-   `cv` (integer)
    
    Cached version Unix timestamp. Learn more in the [Caching concept](https://www.storyblok.com/docs/concepts/caching).
    
-   `token` (required) (string)
    
    A preview or public [access token](https://www.storyblok.com/docs/concepts/access-tokens) configured in a space.
    

## Response properties

-   `datasource` (Datasource)
    
    Show child properties
    
    -   `id` (integer)
        
        Data source ID.
        
    -   `name` (string)
        
        Data source name.
        
    -   `slug` (string)
        
        Data source `slug`.
        
    -   `dimensions` (array<Dimension>)
        
        An array listing the dimensions defined for the data source.
        
        Show child properties
        
        -   `id` (integer)
            
            Dimension ID.
            
        -   `name` (string)
            
            Dimension name.
            
        -   `entry_value` (string)
            
            Dimension value.
            
        -   `datasource_id` (integer)
            
            The `id` of the data source that contains this dimension.
            
        -   `created_at` (string)
            
            Creation timestamp. Supports ISO 8601.
            
        -   `updated_at` (string)
            
            Latest update timestamp. Supports ISO 8601.
            
        
    -   `created_at` (string)
        
        Creation timestamp. Supports ISO 8601.
        
    -   `updated_at` (string)
        
        Latest update timestamp. Supports ISO 8601.
        
    
-   `cv` (integer | null)
    
    Cached version Unix timestamp. Learn more in the [Caching concept](https://www.storyblok.com/docs/concepts/caching).
    

## Examples

-   cURL
    
    ```shellscript
    curl "https://api.storyblok.com/v2/cdn/datasources/:id\
    ?token=ask9soUkv02QqbZgmZdeDAtt"
    ```
    
-   JS
    
    ```javascript
    // storyblok-js-client@>=7, node@>=18
    import Storyblok from "storyblok-js-client";
    
    const storyblok = new Storyblok({
      accessToken: "krcV6QGxWORpYLUWt12xKQtt",
    });
    
    try {
      const response = await storyblok.get('cdn/datasources/:id', {})
      console.log({ response })
    } catch (error) {
      console.log(error)
    }
    ```
    
-   PHP
    
    ```php
    $client = new \Storyblok\Client('YOUR_STORYBLOK_SPACE_ACCESS_TOKEN');
    
    $client->get('datasources/:id')->getBody();
    ```
    
-   Java
    
    ```java
    HttpResponse<String> response = Unirest.get("https://api.storyblok.com/v2/cdn/datasources/:id?token=ask9soUkv02QqbZgmZdeDAtt")
      .asString();
    ```
    
-   C#
    
    ```csharp
    var client = new RestClient("https://api.storyblok.com/v2/cdn/datasources/:id?token=ask9soUkv02QqbZgmZdeDAtt");
    var request = new RestRequest(Method.GET);
    
    IRestResponse response = client.Execute(request);
    ```
    
-   Python
    
    ```python
    import requests
    
    url = "https://api.storyblok.com/v2/cdn/datasources/:id"
    
    querystring = {"token":"ask9soUkv02QqbZgmZdeDAtt"}
    
    payload = ""
    headers = {}
    
    response = requests.request("GET", url, data=payload, headers=headers, params=querystring)
    
    print(response.text)
    ```
    
-   Ruby
    
    ```ruby
    require 'storyblok'
    client = Storyblok::Client.new(token: 'YOUR_TOKEN')
    
    client.get('datasources/:id')
    ```
    
-   Swift
    
    ```swift
    let storyblok = URLSession(storyblok: .cdn(accessToken: "ask9soUkv02QqbZgmZdeDAtt"))
    let request = URLRequest(storyblok: storyblok, path: "datasources/:id")
    let (data, _) = try await storyblok.data(for: request)
    print(try JSONSerialization.jsonObject(with: data))
    ```
    
-   Kotlin
    
    ```kotlin
    val client = HttpClient {
        install(Storyblok(CDN)) {
            accessToken = "ask9soUkv02QqbZgmZdeDAtt"
        }
    }
    
    val response = client.get("datasources/:id")
    
    println(response.body<JsonElement>())
    ```

Response

```json
{
"datasource": {
  "id": 1123,
  "name": "Labels",
  "slug": "labels",
  "dimensions": [
    {
      "id": 1,
      "name": "en",
      "entry_value": "en",
      "datasource_id": 1123
    }
  ],
  "created_at": "2025-02-10T08:12:00.000Z",
  "updated_at": "2025-02-10T08:12:00.000Z"
},
"cv": 1541863983
}
```

## Pagination

-   [Previous: Retrieve Multiple Data Sources](/docs/api/content-delivery/v2/data-sources/retrieve-multiple-data-sources)
-   [Next: Retrieve Running Experiments](/docs/api/content-delivery/v2/experiments/retrieve-running-experiments)
