> For the complete documentation index, see [llms.txt](https://chembl.gitbook.io/unichem/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://chembl.gitbook.io/unichem/api/sources.md).

# Sources

Detail information from the sources, where our compound references are pointing to, can be access programatically through our web services:

* Single source: `https://www.ebi.ac.uk/unichem/api/v1/sources/{source_id}`
* All sources: `https://www.ebi.ac.uk/unichem/api/v1/sources/`

### Single Source

Every source is assigned a unique numeric identifier in our database, with this ID a single source details can be fetch.

A <mark style="color:blue;">**GET**</mark> call to /sources/{source\_id} where {source\_id} is the unique identifier for that source.

![Example of get source](https://1911127213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LswQ6nYY3FF-U9wayJ5%2Fuploads%2Fn9xjGJPqD7qS1Aio4YkZ%2FScreenshot%202022-03-24%20at%2011.10.20.png?alt=media\&token=dc7ae80b-3900-4939-9e25-41d394811039)

#### Simple usage example

{% tabs %}
{% tab title="Curl" %}

```shell
curl --request GET \
  --url https://www.ebi.ac.uk/unichem/api/v1/sources/1
```

{% endtab %}

{% tab title="Python" %}

```python
import requests

url = "https://www.ebi.ac.uk/unichem/api/v1/sources/1"

payload = ""
response = requests.request("GET", url, data=payload)

print(response.text)
```

{% endtab %}
{% endtabs %}

Detail information on the response payload and usage [here](https://www.ebi.ac.uk/unichem/beta/api/docs#/Sources/get_unichem_beta_api_v1_sources_).&#x20;

### All Sources

An array of all the sources in our database can be fetch using <mark style="color:blue;">**GET**</mark> to /sources.

![All sources example call](https://1911127213-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LswQ6nYY3FF-U9wayJ5%2Fuploads%2FwVTGEFnUNI80zyaDNEMS%2FScreenshot%202022-03-24%20at%2011.43.20.png?alt=media\&token=c9f7e1bd-ef5f-4d3a-a5ff-b4fd99705427)

#### Simple usage example

{% tabs %}
{% tab title="Curl" %}

```shell
curl --request GET \
  --url https://www.ebi.ac.uk/unichem/api/v1/sources
```

{% endtab %}

{% tab title="Python" %}

```python
import requests

url = "https://www.ebi.ac.uk/unichem/api/v1/sources"

payload = ""
response = requests.request("GET", url, data=payload)

print(response.text)
```

{% endtab %}
{% endtabs %}

Detail information on the response payload and usage [here](https://www.ebi.ac.uk/unichem/api/docs#/Sources).&#x20;
