> ## Documentation Index
> Fetch the complete documentation index at: https://docs.member.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Quickstart

> Make your first Membership.io API calls.

This quickstart shows the basic platform-admin flow: log in, find a team, then list hubs.

## 1. Set your base URL

Use the production API base URL for all requests.

```bash theme={null}
export MIO_BASE_URL="https://api.member.dev"
```

Use `/api/v1` paths for current integrations. The older `/api` paths still work as a compatibility alias during the alpha period, but they are not the documented contract.

## 2. Log in as a platform user

Platform users are creator-side users: owners, admins, and staff.

<Note>
  The platform auth token endpoints currently return a flat token body. Most other endpoints return JSON:API documents.
</Note>

```bash theme={null}
export MIO_ACCESS_TOKEN=$(
  curl -s -X POST "$MIO_BASE_URL/api/v1/auth/login" \
    -H "Content-Type: application/vnd.api+json" \
    -d '{
      "email": "admin@example.com",
      "password": "password"
    }' | jq -r '.access_token'
)
```

## 3. List your teams

```bash theme={null}
curl -s "$MIO_BASE_URL/api/v1/teams" \
  -H "Authorization: Bearer $MIO_ACCESS_TOKEN" \
  -H "Accept: application/vnd.api+json" | jq
```

The response is a JSON:API document:

```json theme={null}
{
  "data": [
    {
      "id": "0197...",
      "type": "teams",
      "attributes": {
        "name": "Acme Team",
        "slug": "acme-team"
      }
    }
  ]
}
```

## 4. Use a team-scoped endpoint

Many admin endpoints include `team_id` in the path.

```bash theme={null}
export TEAM_ID="replace-with-team-id"

curl -s "$MIO_BASE_URL/api/v1/teams/$TEAM_ID/hubs" \
  -H "Authorization: Bearer $MIO_ACCESS_TOKEN" \
  -H "Accept: application/vnd.api+json" | jq
```

## 5. Use the API reference

Open the generated endpoint pages under **API reference -> Generated endpoints** for exact request bodies, path parameters, query parameters, and response schemas.
