canonical: https://jentic.com/apis/sonos.com/sonos

# Sonos Control API

Jentic publishes the only available OpenAPI specification for the Sonos Control API, keeping it validated and agent-ready. The Sonos Control API controls Sonos speakers in a user's home through the Sonos cloud: it discovers households, groups speakers together, starts, pauses, and skips playback, and sets group or per-player volume. It also loads Sonos favorites onto a group, plays short audio clips on a single speaker, and reads or changes home theater options such as night mode and dialog enhancement.

## For AI agents

Discover a user's Sonos households and speaker groups, control playback and volume, load favorites, play audio clips on a speaker, and adjust home theater settings.

## Scope

Does not handle music search, playlist creation, or speaker setup and Wi-Fi configuration. Use for controlling playback, grouping, and volume on Sonos speakers only.

## Capabilities

- Discover the households linked to a Sonos account and the groups and players inside each one
- Start, pause, toggle, skip, and seek playback on a speaker group, and set repeat, shuffle, and crossfade play modes
- Set absolute or relative group volume, mute a group, or set the volume of a single player
- Group speakers together or add and remove players from an existing group
- Load a saved Sonos favorite onto a group, with optional play modes
- Play a short audio clip such as an announcement on one player, with LOW or HIGH priority
- Read and set night mode and dialog enhancement on a home theater player

## Use cases

### Voice-free speaker control from an agent

A home assistant agent turns requests like 'pause the kitchen' into Sonos Control API calls through Jentic. It lists households, reads the groups and players in the chosen household to resolve 'kitchen' to a groupId, and then calls the pause operation on that group. A rule can keep the agent to playback and volume operations for that one group, so it cannot regroup speakers or change home theater settings.

Example prompt: Call GET /households, then GET `/households/{householdId}/groups` to find the group named Kitchen, then POST `/groups/{groupId}/playback/pause` on that group

### Morning routine playback

A scheduled routine starts the day by loading a household favorite onto a bedroom group and setting a gentle volume. The favorites list comes from the household, loading a favorite requires its favoriteId, and play modes such as shuffle can be set at load time.

Example prompt: Call GET `/households/{householdId}/favorites`, pick the favorite named Morning Mix, call POST `/groups/{groupId}/favorites` with its favoriteId and playOnCompletion true, then POST `/groups/{groupId}/groupVolume/setVolume` with volume 20

### Spoken alerts and chimes

Doorbells, timers, and home alerts can sound on a single Sonos speaker using the audio clip operation, which takes a name, an appId, an optional streamUrl, and a LOW or HIGH priority, and can duck the music already playing rather than stopping it.

Example prompt: Call POST `/players/{playerId}/audioClip` on the hallway player with name 'doorbell', appId 'com.example.home', priority HIGH, and a streamUrl pointing at the chime file

### Multi-room grouping

For a party or a whole-home announcement, an agent creates a new group from a list of playerIds in a household, or adds and removes players from an existing group, and then reads playback metadata to confirm what the new group is playing.

Example prompt: Call POST `/households/{householdId}/groups/createGroup` with the playerIds of the kitchen and dining room players, then GET `/groups/{groupId}/playbackMetadata` on the new group

## Key endpoints

| Method | Path | Description |
| --- | --- | --- |
| GET | `/households` | List households |
| GET | `/households/{householdId}/groups` | List groups and players |
| POST | `/groups/{groupId}/playback/play` | Start playback on a group |
| POST | `/groups/{groupId}/playback/pause` | Pause a group |
| POST | `/groups/{groupId}/groupVolume/setVolume` | Set group volume |
| POST | `/groups/{groupId}/favorites` | Load a favorite |
| POST | `/players/{playerId}/audioClip` | Play an audio clip on a player |

## Key resources

- **Households** — List households, their groups and players, and their Sonos favorites.
- **Groups** — Create groups, change group membership, and control playback, play modes, and group volume.
- **Players** — Per-speaker volume, audio clips, and home theater options.

## AI readiness

This API is usable in Jentic One now. Its AI-readiness score against Jentic's framework shows where it stands today and where improvements would make it even easier for agents to use.

- **Score:** 67 / 100
- **Maturity:** AI-Aware
- **Dimensions:**
  - Foundational Compliance: 87 / 100
  - Developer Experience & Jentic Compatibility: 63 / 100
  - AI-Readiness & Agent Experience: 44 / 100
  - Agent Usability: 94 / 100
  - Security: 90 / 100
  - AI Discoverability: 76 / 100
- **View full report:** https://jentic.com/apis/sonos.com/sonos/scorecard
- **How the score is calculated:** https://docs.jentic.com/reference/api-readiness-framework/overview/
- **More about the dimensions:** https://docs.jentic.com/reference/api-readiness-framework/specification/#dimensional-model-overview

### Score it yourself

Every API in the directory is allowlisted, so you can re-score it with no key required.

- **Score your own API:** https://jentic.com/scorecard.md
- **Scoring CLI agent skill:** https://github.com/jentic/jentic-api-scorecard/blob/main/skills/jentic-api-scorecard/SKILL.md

```sh
npx @jentic/api-scorecard-cli score <openapi-url>
```

## Why Jentic

- **Setup:** Wiring Sonos by hand means enrolling in the developer program, running the OAuth authorization code flow against the Sonos login service, refreshing tokens, and resolving household and group ids before any playback call. Through Jentic you install once, import Sonos from the API Directory, connect your account once, and your agent calls it.
- **Permission scoping:** Sonos puts the householdId, groupId, and playerId in the URL path, so a rule can pin your agent to one group or one player. You choose the operations it may call, so ones like group membership changes or home theater settings are not included unless you add them.
- **Credential handling:** Your Sonos OAuth token is stored once, encrypted, by your own Jentic One instance and injected at execution time. It never enters the agent's prompt, logs, or context.
- **Discovery method:** Agents search Jentic by intent such as 'pause the music' or 'set speaker volume', and Jentic returns the matching Sonos operation with its input schema so the agent calls the right endpoint without browsing the reference docs.

## Related APIs

- **Spotify Web API** — Track and album search plus playback control across Spotify Connect devices.
- **SmartThings API** — Hub-based control of many smart home device types, scenes, and rooms.
- **LIFX HTTP API** — Control LIFX smart bulbs and groups.

## FAQ

### Why is there no official OpenAPI spec for the Sonos Control API?

Sonos does not publish an OpenAPI specification. Jentic generates and maintains this spec so that AI agents and developers can call the Sonos Control API via structured tooling. It is validated against the live API and kept up to date. To run it on your own infrastructure, install Jentic One from its GitHub repo.

### What authentication does the Sonos Control API use?

The Sonos Control API authenticates with OAuth 2.0 authorization code per its OpenAPI spec, using `https://api.sonos.com/login/v3/oauth` to authorize, `https://api.sonos.com/login/v3/oauth/token` to issue tokens, and the playback-control-all scope. The spec notes that developer program enrollment is required. Through Jentic the OAuth token is stored encrypted by your own Jentic One instance and injected at call time, so it never enters the agent's context.

### Can I play an announcement on one Sonos speaker with the Sonos Control API?

Yes. POST `/players/{playerId}/audioClip` plays a clip on a single player. The request requires name and appId, and accepts a streamUrl, a volume, and a priority of LOW or HIGH, so the clip can play over current music rather than replacing the queue.

### What are the rate limits for the Sonos Control API?

The OpenAPI spec does not specify rate limits. Check the Sonos developer documentation at `developer.sonos.com` for current limits.

### How do I pause a Sonos group through Jentic?

Install Jentic One, import the Sonos Control API from the Jentic API Directory, and connect your Sonos account through OAuth once. Your agent searches for 'pause music on a Sonos speaker', gets POST `/groups/{groupId}/playback/pause` with its input schema, resolves the groupId from GET `/households/{householdId}/groups`, and calls it.

### Is there a Sonos MCP server?

You don't need an MCP server to give your agent the Sonos Control API. Jentic connects it directly from the API Directory: import it, connect your account once, and your agent calls it. Operations are discovered by intent when they are needed, so no extra tool definitions are loaded into the agent's context.

### Can I limit what my agent is allowed to do with the Sonos Control API?

Yes. Write a rule that allows only the play, pause, and setVolume operations under the kids' room groupId. The agent can start, stop, and adjust music in that room and nothing else: it cannot regroup speakers, play audio clips, or touch other rooms, and every call it makes is logged.
