# Activities

> Canonical URL: https://docs.mountaya.com/en/apis/map-studio/reference/activities/
> Last updated: 2026-11-26
> Rules for agents: https://docs.mountaya.com/llms.txt#rules-for-agents

The activity catalog (hiking, ski touring, road cycling and the rest) grouped by category.

 Each activity declares what routing is available for it, which is what decides whether a segment can be auto-routed or has to be drawn by hand.

## The Activity object

An outdoor activity type with its capabilities.

- `capabilities` (object, required): What the routing engine can do for this activity. Read it before offering a mode: an activity that cannot be routed accepts linestring segments only, and a client that offers directions anyway produces a request the server refuses.
  - `analysis` (boolean, required): Whether surface and way type analysis is available for this activity.
  - `default_speed` (number (double), required): Default travel speed in km/h used to seed a segment's speed for this activity.
  - `directions` (boolean, required): Whether turn-by-turn routing via the directions engine is available.
  - `linestring` (boolean, required): Whether freehand line editing is available for this activity.

- `id` (string (uuid), required): Unique identifier of the activity.

- `locales` (object, required): The activity's display name per language. Render from here rather than from `slug`: the slug is a stable identifier and is not translated.
  - `de` (LocaleMap | null, required): The German strings for this legend. Null when the legend carries no German translation, which is the case a client falls back from rather than renders.
  - `en` (LocaleMap | null, required): The English strings for this legend. Null when the legend carries no English translation, which is the case a client falls back from rather than renders.
  - `es` (LocaleMap | null, required): The Spanish strings for this legend. Null when the legend carries no Spanish translation, which is the case a client falls back from rather than renders.
  - `fr` (LocaleMap | null, required): The French strings for this legend. Null when the legend carries no French translation, which is the case a client falls back from rather than renders.
  - `it` (LocaleMap | null, required): The Italian strings for this legend. Null when the legend carries no Italian translation, which is the case a client falls back from rather than renders.
  - `ja` (LocaleMap | null, required): The Japanese strings for this legend. Null when the legend carries no Japanese translation, which is the case a client falls back from rather than renders.
  - `zh` (LocaleMap | null, required): The Chinese strings for this legend. Null when the legend carries no Chinese translation, which is the case a client falls back from rather than renders.

- `slug` (string, required, one of: `hiking-and-trail`, `professional-trail`, `running`, `road-cycling`, `gravel-bike`, `mountain-bike`, `backcountry-skiing`, `ski-touring`, `cross-country-skiing`, `snowshoe-walking`): Stable identifier for the activity, the same on every surface and safe to store. `id` is the value operations take; this is the value a human reads in a URL or a config file.

### An example Activity

```json
{
  "id": "a1c4e7b2-3d59-4f08-8b6a-2e5c9d0f7134",
  "slug": "hiking-and-trail",
  "capabilities": {
    "analysis": true,
    "default_speed": 4.5,
    "directions": true,
    "linestring": false
  },
  "locales": {
    "en": {
      "name": "Hiking and trail"
    },
    "fr": {
      "name": "Randonnée et trail"
    },
    "es": null,
    "it": null,
    "de": null,
    "zh": null,
    "ja": null
  }
}
```

## List all activity categories and their activities

### GET /v1/activities

- Operation: `getActivities`
- Requires: scope `publishing`
- Behavior: idempotent, safe to retry · answers within 30000 ms or times out

Returns all available activities grouped by category. Each activity includes its capabilities (e.g., routing support, elevation profiles). It is a catalog, the same for every caller, so it is not paged: every category comes back at once.

Reads are limited per minute. A publishable key sent without a session token, or with one minted without `user_id`, is held to 600 per client IP address and then 6000 per organization; a key with a session token naming a user to 1200 per user the token names and then 6000 per organization, counted apart from the reads made under the key alone; and a share token to 600 per client IP address and then 6000 per organization that owns the link. Past any of them the read is a `429` carrying `Retry-After`. A share token not resolved moments earlier is refused the same way when its client IP address has had 60 unknown share tokens refused within the minute.

Requires a publishable key with the `publishing` scope, or the `studio-embedded` scope that includes it, or a share token: a share view names each segment's activity from the same catalog an embed does.

Also takes `Accept-Language`, as every operation of this API does: the [overview](https://docs.mountaya.com/en/apis/map-studio/reference.md) describes it.

**Response** `200`

The activity catalog, grouped by category. Each activity declares what the routing can do for it.

- `extensions` (object): Top-level extensions map for 2xx responses. Mirrors the GraphQL-spec response extensions: a free-form map for response-scoped metadata.
  - `metadata` (object): Response-scoped metadata. Its shape is per-operation: the operation that emits it names the schema, and an operation that documents none never emits this field.

- `data` (array of CategoryActivities, required)
  - `children` (array of Activity, required): The activities in this group. These are the selectable entries; the group itself is not.

    See [the Activity object](https://docs.mountaya.com/en/apis/map-studio/reference/activities.md#activity-object).
  - `id` (string (uuid), required): Identifier of the activity group.
  - `locales` (object, required): The category's display name per language. Render from here rather than from `slug`: the slug is a stable identifier and is not translated.
    - `de` (LocaleMap | null, required): The German strings for this legend. Null when the legend carries no German translation, which is the case a client falls back from rather than renders.
    - `en` (LocaleMap | null, required): The English strings for this legend. Null when the legend carries no English translation, which is the case a client falls back from rather than renders.
    - `es` (LocaleMap | null, required): The Spanish strings for this legend. Null when the legend carries no Spanish translation, which is the case a client falls back from rather than renders.
    - `fr` (LocaleMap | null, required): The French strings for this legend. Null when the legend carries no French translation, which is the case a client falls back from rather than renders.
    - `it` (LocaleMap | null, required): The Italian strings for this legend. Null when the legend carries no Italian translation, which is the case a client falls back from rather than renders.
    - `ja` (LocaleMap | null, required): The Japanese strings for this legend. Null when the legend carries no Japanese translation, which is the case a client falls back from rather than renders.
    - `zh` (LocaleMap | null, required): The Chinese strings for this legend. Null when the legend carries no Chinese translation, which is the case a client falls back from rather than renders.
  - `slug` (string, required): Stable, URL-safe identifier of the activity group. Unlike the display name in `locales`, it does not change between languages or releases. Lowercase letters, digits and single hyphens, the same shape every slug on this surface carries.

**Errors** `400`, `401`, `402`, `403`, `429`, `500`, `504`. See [Errors](https://docs.mountaya.com/en/apis/conventions/errors.md).

- `400`: Bad Request
- `401`: Unauthorized
- `402`: A plain `PAYMENT_REQUIRED`, with no per-entry refinement: the organization does not hold Map Publishing, the product the `publishing` scope belongs to. Map Publishing is granted by the organization's agreement with Mountaya, so this is answered to an organization whose agreement does not include it, and it clears when the agreement changes rather than when the request does. The product is checked before the key's scopes, so a key that lacks the scope as well is answered this rather than a `403`. A share token is never refused this way. Under a key carrying `studio-embedded`, the organization is refused for Map Publishing only when it holds neither Map Publishing nor Embedded Studio with Map Studio, so an organization that edits in an Embedded Studio reads its work back without Map Publishing.
- `403`: The credential is valid and this operation is not open to it: the key carries neither the `publishing` scope nor the `studio-embedded` scope that includes it. The blanket refusal in the [order of checks](https://docs.mountaya.com/en/apis/conventions/errors.md#which-refusal-you-get-first), an `Origin` or `Referer` the organization does not allow, answers here as well.
- `429`: `TooManyRequests`, given in full at the end of this page.
- `500`: Internal Server Error
- `504`: Gateway Timeout

**cURL**

```bash
curl -s https://api.mountaya.com/v1/activities \
  -H "X-API-Key: pk_your_publishable_key" | jq '.data'
```

**TypeScript**

```typescript
import { Mountaya } from "@mountaya/client";

const mountaya = new Mountaya({
  credential: { publishableKey },
});

const { data } = await mountaya.studio.activities.getActivities();

console.log(data);
```

**Python**

```python
import requests

response = requests.get(
    "https://api.mountaya.com/v1/activities",
    headers={
        "X-API-Key": "pk_your_publishable_key",
    },
    timeout=30,
)
response.raise_for_status()
print(response.json()["data"])
```

Response 200:

```json
{
  "data": [
    {
      "id": "8f2c6b41-0d75-4a39-9e18-c3b5a7d02f96",
      "slug": "foot",
      "locales": {
        "de": null,
        "en": {
          "name": "On foot"
        },
        "es": null,
        "fr": {
          "name": "À pied"
        },
        "it": null,
        "ja": null,
        "zh": null
      },
      "children": [
        {
          "id": "a1c4e7b2-3d59-4f08-8b6a-2e5c9d0f7134",
          "slug": "hiking-and-trail",
          "locales": {
            "de": null,
            "en": {
              "name": "Hiking & trail"
            },
            "es": null,
            "fr": {
              "name": "Randonnée et trail"
            },
            "it": null,
            "ja": null,
            "zh": null
          },
          "capabilities": {
            "analysis": true,
            "default_speed": 4.5,
            "directions": true,
            "linestring": true
          }
        }
      ]
    }
  ]
}
```

**Error answers the operations of this page share**

- `TooManyRequests` (`429`): A limit on this operation's requests is spent: the [rate limits](https://docs.mountaya.com/en/apis/conventions/rate-limits.md) page lists every one, the unknown publishable keys one address may present among them, and the operation's description names any of its own. The request was counted and nothing was done. `Retry-After` says how long until the limit lifts; wait that long, with a little jitter of your own, and send the request again. Where the operation takes an `Idempotency-Key`, a write sent again with the same key runs once.
