# Anaconda.org API

> Conda package metadata, versions and files by channel from anaconda.org package pages.

Category: Developer & Tech. Region: Global. 3 endpoints at `https://api.hoshime.com/v1/anaconda/<endpoint>`, `GET` with query parameters, answering `{data, meta}` (see https://hoshime.com/docs/responses.md). Reference: https://hoshime.com/docs/platforms/anaconda
## GET /v1/anaconda/package

One package of an anaconda.org channel: its latest version, versions and downloads.

Scope: `social:read` · Units: 1 · Cached: 60 min

| Parameter | Type | Required | Description |
|---|---|---|---|
| `channel` | string | no | Channel name, such as conda-forge. (default conda-forge; e.g. conda-forge) |
| `name` | string | yes | Package name, such as numpy. (e.g. numpy) |
| `tunnel` | string | no | Id or name of one of your tunnels: the call reads the source from the machine that runs `hoshime tunnel`, through its own connection. Fails with 409 tunnel_unavailable when no machine is connected. Cannot be combined with proxy. |
| `proxy` | string | no | Your own http:// or https:// proxy, such as http://user:pass@proxy.example.com:8080, on a public address. The call reads the source only through it. |
| `profileId` | string | no | Browser profile whose login the call sends (its cookies), so the source answers as that account. Without tunnel or proxy it leaves through the profile's own residential IP. Needs the browser:read scope. Data read logged in is for your account only. |

Response data fields: `channel` (string), `downloads` (integer (int64)), `homepage` (string), `latestVersion` (string), `license` (string), `name` (string), `owner` (string), `packageTypes` (PackageType[]), `packageTypes[].name` (string), `public` (boolean), `summary` (string), `updatedAt` (string), `versions` (Version[]), `versions[].name` (string)

```bash
curl "https://api.hoshime.com/v1/anaconda/package?channel=conda-forge&name=numpy" -H "Authorization: Bearer $HOSHIME_TOKEN"
```

## GET /v1/anaconda/search

Packages with exactly this name on anaconda.org, across every owner and channel.

Scope: `social:read` · Units: 1 · Cached: 30 min · Paginated: cursor

| Parameter | Type | Required | Description |
|---|---|---|---|
| `name` | string | yes | Exact package name, such as numpy. (e.g. numpy) |
| `limit` | integer | no | Items per page, 1 to 100. (default 20) |
| `tunnel` | string | no | Id or name of one of your tunnels: the call reads the source from the machine that runs `hoshime tunnel`, through its own connection. Fails with 409 tunnel_unavailable when no machine is connected. Cannot be combined with proxy. |
| `proxy` | string | no | Your own http:// or https:// proxy, such as http://user:pass@proxy.example.com:8080, on a public address. The call reads the source only through it. |
| `profileId` | string | no | Browser profile whose login the call sends (its cookies), so the source answers as that account. Without tunnel or proxy it leaves through the profile's own residential IP. Needs the browser:read scope. Data read logged in is for your account only. |

Response data fields: `downloads` (integer (int64)), `fullName` (string), `latestVersion` (string), `name` (string), `owner` (string), `packageTypes` (PackageType[]), `packageTypes[].name` (string), `summary` (string), `url` (string)

```bash
curl "https://api.hoshime.com/v1/anaconda/search?name=numpy" -H "Authorization: Bearer $HOSHIME_TOKEN"
```

## GET /v1/anaconda/files

The files of one anaconda.org package, newest first as the channel lists them. Page with cursor.

Scope: `social:read` · Units: 1 · Cached: 60 min · Paginated: cursor

| Parameter | Type | Required | Description |
|---|---|---|---|
| `channel` | string | yes | Channel or owner, such as conda-forge. (e.g. conda-forge) |
| `name` | string | yes | Package name, such as numpy. (e.g. numpy) |
| `limit` | integer | no | Number of files, from 1 to 100. (default 20) |
| `cursor` | string | no | meta.pagination.nextCursor of the previous page. Omit it for the first page. |
| `tunnel` | string | no | Id or name of one of your tunnels: the call reads the source from the machine that runs `hoshime tunnel`, through its own connection. Fails with 409 tunnel_unavailable when no machine is connected. Cannot be combined with proxy. |
| `proxy` | string | no | Your own http:// or https:// proxy, such as http://user:pass@proxy.example.com:8080, on a public address. The call reads the source only through it. |
| `profileId` | string | no | Browser profile whose login the call sends (its cookies), so the source answers as that account. Without tunnel or proxy it leaves through the profile's own residential IP. Needs the browser:read scope. Data read logged in is for your account only. |

Response data fields: `basename` (string), `downloads` (integer (int64)), `md5` (string), `platform` (string), `sha256` (string), `size` (integer (int64)), `type` (string), `uploadedAt` (string), `url` (string), `version` (string)

```bash
curl "https://api.hoshime.com/v1/anaconda/files?channel=conda-forge&name=numpy" -H "Authorization: Bearer $HOSHIME_TOKEN"
```
