# Quickstart


## 1. Create an API key

Open **Settings → Personal → API keys** and create a key. A key acts as you: choose **Full account**, or restrict it to the Organizations, Workspaces, and permissions your integration needs. Copy the key when it is shown; it starts with `szp_` and is not shown again. Keys created before personal keys (`sk_…`) keep working until rotated or expired; `sz_…` keys are no longer accepted.

## 2. Store the key

```bash
export SCHEDULER_ZERO_API_KEY="szp_your_api_key_here"
```

Use a secret manager in production. Do not commit API keys to a repository or include them in client-side browser code.

## 3. Verify the credential

```bash
curl https://api.schedulerzero.com/v1/me \
  -H "x-api-key: $SCHEDULER_ZERO_API_KEY"
```

## 4. Find a Workspace

One key can reach several Workspaces, so Workspace operations name theirs in
the path. List the Organizations the key can see, then their Workspaces:

```bash
curl https://api.schedulerzero.com/v1/organizations \
  -H "x-api-key: $SCHEDULER_ZERO_API_KEY"

curl https://api.schedulerzero.com/v1/organizations/$ORGANIZATION_ID/workspaces \
  -H "x-api-key: $SCHEDULER_ZERO_API_KEY"
```

## 5. Call an operation

```bash
curl https://api.schedulerzero.com/v1/workspaces/$WORKSPACE_ID/campaigns \
  -H "x-api-key: $SCHEDULER_ZERO_API_KEY"
```

See the [API reference](/rest-api/reference) for request parameters, bodies, responses, and required scopes.

