# Agency directory

> Agencies Storeware has listed, open to anyone with no token.

Source: https://storeware.ai/docs/api-reference/rest/agency-directory

## Search the agency directory

`GET /api/v1/public/partners`

Listed agencies only, with no token. `best`, the default, ranks by a Bayesian rating score; nothing in the order is paid for.

Open to anyone: it needs no token and no permission.

**Parameters**

| Parameter | In | Type | Description |
| --- | --- | --- | --- |
| `q` | query | string | Words to search names and what agencies say about themselves. |
| `country` | query | string | A two letter country code the agency is in or serves. |
| `language` | query | string | A language code, such as `en` or `de`. |
| `service` | query | string | One of `shop_setup`, `design`, `moving_from_another_platform`, `apps_and_integrations`, `marketing`, `search`, `photography`, `ongoing_care`. |
| `price` | query | string | One of `small`, `medium`, `large`. |
| `sort` | query | string | One of `best`, `newest`, `name`. |
| `limit` | query | integer | From 1 to 50. |
| `offset` | query | integer | At least 0. |

**Answers** `200`

| Field | Type | Description |
| --- | --- | --- |
| `data` | object |  |
| `data.partners` | array of [PublicPartnerCard](https://storeware.ai/docs/api-reference/rest/objects#publicpartnercard) |  |
| `data.total` | integer |  |

```bash
curl "https://api.storeware.ai/api/v1/public/partners" \
  -H "Authorization: Bearer $TOKEN"
```

## Get a listed agency

`GET /api/v1/public/partners/{slug}`

Its card, all it says about itself, the address that opens a shop credited to it, what its ratings add up to and the newest ten.

Open to anyone: it needs no token and no permission.

**Parameters**

| Parameter | In | Type | Description |
| --- | --- | --- | --- |
| `slug` | path | string | The slug. |

**Answers** `200`

| Field | Type | Description |
| --- | --- | --- |
| `data` | object |  |
| `data.slug` | string |  |
| `data.displayName` | string |  |
| `data.websiteUrl` | string or null |  |
| `data.country` | string or null | Where the agency is, as a two letter country code. |
| `data.summary` | string or null | The first lines of what the agency says about itself. |
| `data.services` | array of string |  |
| `data.languages` | array of string |  |
| `data.countriesServed` | array of string |  |
| `data.priceBand` | string or null | One of `small`, `medium`, `large`. |
| `data.clients` | integer | Organisations the agency looks after or is credited with now. |
| `data.rating` | object |  |
| `data.rating.average` | number or null | Average stars to one decimal, or null with none. |
| `data.rating.count` | integer |  |
| `data.listedAt` | string (date-time) or null |  |
| `data.about` | string or null |  |
| `data.startUrl` | string | Opens a new shop on Storeware credited to this agency. |
| `data.ratings` | object |  |
| `data.ratings.summary` | object |  |
| `data.ratings.summary.average` | number or null |  |
| `data.ratings.summary.count` | integer |  |
| `data.ratings.summary.distribution` | array of integer | How many ratings gave 5, 4, 3, 2 and 1 stars, in that order. Up to 5 items. At least 5 items. |
| `data.ratings.recent` | array of [PublicPartnerRating](https://storeware.ai/docs/api-reference/rest/objects#publicpartnerrating) |  |

```bash
curl "https://api.storeware.ai/api/v1/public/partners/$SLUG" \
  -H "Authorization: Bearer $TOKEN"
```

## List a listed agency’s ratings

`GET /api/v1/public/partners/{slug}/ratings`

Newest first. Ratings come only from businesses the agency looked after, with a paid plan or an open shop.

Open to anyone: it needs no token and no permission.

**Parameters**

| Parameter | In | Type | Description |
| --- | --- | --- | --- |
| `slug` | path | string | The slug. |
| `limit` | query | integer | From 1 to 50. |
| `offset` | query | integer | At least 0. |

**Answers** `200`

| Field | Type | Description |
| --- | --- | --- |
| `data` | object |  |
| `data.summary` | object |  |
| `data.summary.average` | number or null |  |
| `data.summary.count` | integer |  |
| `data.summary.distribution` | array of integer | How many ratings gave 5, 4, 3, 2 and 1 stars, in that order. Up to 5 items. At least 5 items. |
| `data.ratings` | array of [PublicPartnerRating](https://storeware.ai/docs/api-reference/rest/objects#publicpartnerrating) |  |

```bash
curl "https://api.storeware.ai/api/v1/public/partners/$SLUG/ratings" \
  -H "Authorization: Bearer $TOKEN"
```
