- Fix inaccuracies in API-Endpoints-Overview.md: * Mark bassCapabilities, trackInfo, and SetName as implemented * Update zone management and WebSocket status to implemented * Correct official API coverage from 94% to 84% - Update README.md API coverage table: * Add missing implemented endpoints (bassCapabilities, trackInfo, SetName) * Add missing official endpoints with proper status * Update implementation percentage to reflect actual coverage - Add comprehensive API-COVERAGE-ANALYSIS.md: * Complete analysis of 16/19 official endpoints implemented (84%) * Document 5 extended features beyond official API v1.0 * Detailed impact assessment of 3 missing professional endpoints * Analysis of superior zone management implementation * Testing coverage and recommendations Key findings: - All essential functionality is 100% implemented - Missing endpoints are low-impact professional/audiophile features - Zone management uses superior high-level API vs low-level official approach - Extended features include balance, clock, and network management - Comprehensive WebSocket event system implemented
10 KiB
Bose SoundTouch Web API - Endpoints Overview
This document provides a comprehensive overview of the available API endpoints verified against the official Bose SoundTouch Web API v1.0 specification (January 7, 2026).
Implementation Status Legend
- ✅ Implemented - Fully implemented with tests and real device validation
- ❌ Missing - Documented in official API but not implemented
- 🔍 Extra - Implemented but not in official API v1.0 (may be newer version or undocumented)
- ⚠️ Different - Implemented with different approach than official API
API Basics
- Protocol: HTTP REST-like
- Data Format: XML Request/Response
- Standard Port: 8090
- Base URL:
http://<device-ip>:8090/ - Authentication: No complex authentication required
- Real-time Updates: WebSocket connection available
Device Information
GET /info ✅ Implemented
Retrieves basic device information.
Response XML Structure:
<info deviceID="..." type="..." name="..." ...>
<name>Device Name</name>
<type>Device Type</type>
<margeAccountUUID>UUID</margeAccountUUID>
<components>...</components>
</info>
Playback Control
GET /now_playing ✅ Implemented
Retrieves information about the currently playing music.
Response XML Structure:
<nowPlaying deviceID="..." source="...">
<ContentItem source="..." type="..." location="..." sourceAccount="...">
<itemName>Track Name</itemName>
<containerArt>Album Art URL</containerArt>
</ContentItem>
<track>Track Name</track>
<artist>Artist Name</artist>
<album>Album Name</album>
<stationName>Station Name</stationName>
<art artImageStatus="...">Art URL</art>
<playStatus>PLAY_STATE</playStatus>
<shuffleSetting>...</shuffleSetting>
<repeatSetting>...</repeatSetting>
</nowPlaying>
POST /key ✅ Implemented
Sends key commands to the device.
Important: Proper key simulation requires sending both press and release states:
Request XML (Press + Release):
<key state="press" sender="Gabbo">KEY_NAME</key>
<key state="release" sender="Gabbo">KEY_NAME</key>
Available Keys:
Playback Controls:
PLAY- Start playbackPAUSE- Pause current playbackSTOP- Stop current playbackPREV_TRACK- Go to previous trackNEXT_TRACK- Go to next track
Rating and Bookmark Controls:
THUMBS_UP- Rate current content positively (Pandora, etc.)THUMBS_DOWN- Rate current content negativelyBOOKMARK- Bookmark current content
Power and System Controls:
POWER- Toggle device power stateMUTE- Toggle mute state
Volume Controls:
VOLUME_UP- Increase volumeVOLUME_DOWN- Decrease volume
Preset Controls:
PRESET_1toPRESET_6- Select preset 1-6
Input Controls:
AUX_INPUT- Switch to auxiliary input
Shuffle Controls:
SHUFFLE_OFF- Turn shuffle mode offSHUFFLE_ON- Turn shuffle mode on
Repeat Controls:
REPEAT_OFF- Turn repeat mode offREPEAT_ONE- Repeat current trackREPEAT_ALL- Repeat all tracks in playlist
Volume Control
GET /volume ✅ Implemented
Retrieves the current volume.
Response XML:
<volume deviceID="...">
<targetvolume>50</targetvolume>
<actualvolume>50</actualvolume>
<muteenabled>false</muteenabled>
</volume>
POST /volume ✅ Implemented
Sets the volume.
Request XML:
<volume>50</volume>
Bass Settings
GET /bass ✅ Implemented
Retrieves the current bass settings.
Response XML:
<bass deviceID="...">
<targetbass>0</targetbass>
<actualbass>0</actualbass>
</bass>
POST /bass ✅ Implemented
Sets the bass settings (-9 to +9).
Request XML:
<bass>0</bass>
Source Management
GET /sources ✅ Implemented
Retrieves the available audio sources.
Response XML:
<sources deviceID="...">
<sourceItem source="SPOTIFY" sourceAccount="..." status="READY" multiroomallowed="true">
<itemName>Spotify</itemName>
</sourceItem>
<sourceItem source="BLUETOOTH" status="READY" multiroomallowed="false">
<itemName>Bluetooth</itemName>
</sourceItem>
<!-- Additional sources -->
</sources>
Typical Sources:
SPOTIFYAMAZONPANDORAIHEARTRADIOTUNEINBLUETOOTHAUXSTORED_MUSIC
POST /select ✅ Implemented
Selects an audio source.
Request XML:
<ContentItem source="SPOTIFY" sourceAccount="...">
<itemName>Spotify</itemName>
</ContentItem>
Preset Management
GET /presets ✅ Implemented
Retrieves the configured presets.
Response XML:
<presets deviceID="...">
<preset id="1" createdOn="..." updatedOn="...">
<ContentItem source="..." sourceAccount="..." location="...">
<itemName>Preset Name</itemName>
<containerArt>Art URL</containerArt>
</ContentItem>
</preset>
<!-- Additional presets -->
</presets>
POST /presets ❌ Not Supported
Creates or updates a preset.
Status: According to the official Bose SoundTouch API documentation, POST operations on /presets are marked as "N/A" - this endpoint officially does not support preset creation or modification via API.
Alternative Methods:
- Use the official Bose SoundTouch mobile app
- Use physical preset buttons on the device (long-press while content is playing)
- Changes made via these methods will be visible through the GET endpoint
Advanced Features
GET /getZone ✅ Implemented
Retrieves multiroom zone information.
POST /setZone ✅ Implemented
Configures multiroom zones.
GET /balance ✅ Implemented
Retrieves balance settings (stereo devices).
POST /balance ✅ Implemented
Sets balance settings.
GET /clockTime ✅ Implemented
Retrieves the device time.
POST /clockTime ✅ Implemented
Sets the device time.
GET /clockDisplay ✅ Implemented
Retrieves clock display settings.
POST /clockDisplay ✅ Implemented
Configures the clock display.
WebSocket Connection
WebSocket / ✅ Implemented
Establishes a persistent connection for live updates.
Event Types:
nowPlayingUpdatedvolumeUpdatedconnectionStateUpdatedpresetUpdated
Network and System
GET /networkInfo ✅ Implemented
Retrieves network information.
GET /capabilities ✅ Implemented
Retrieves device capabilities.
GET /name 🔍 Extra
Retrieves the device name.
Note: Official API only documents POST /name for setting device name. Our GET implementation appears to be an undocumented extension.
POST /name ✅ Implemented
Sets the device name via SetName() method.
Official Request Format:
<name>$STRING</name>
GET /bassCapabilities ✅ Implemented
Checks if bass customization is supported on the device.
Official Response Format:
<bassCapabilities deviceID="$MACADDR">
<bassAvailable>$BOOL</bassAvailable>
<bassMin>$INT</bassMin>
<bassMax>$INT</bassMax>
<bassDefault>$INT</bassDefault>
</bassCapabilities>
GET /trackInfo ✅ Implemented
Gets track information (duplicate of /now_playing per official API).
Implementation: Available via GetTrackInfo() method with identical response format to /now_playing.
Zone Slave Management ⚠️ Different Implementation
Our implementation uses high-level methods instead of official endpoints:
- Official:
/addZoneSlave(POST) - Add slave to zone - Official:
/removeZoneSlave(POST) - Remove slave from zone - Our Implementation:
AddToZone()andRemoveFromZone()methods via/setZone
Status: Functionally equivalent and arguably cleaner approach.
Advanced Audio Controls ❌ Missing
Professional/high-end device features (only available via /capabilities check):
/audiodspcontrols - GET/POST
Access DSP settings including audio modes and video sync delay.
/audioproducttonecontrols - GET/POST
Advanced bass and treble controls (beyond basic /bass endpoint).
/audioproductlevelcontrols - GET/POST
Speaker level controls for front-center and rear-surround speakers.
Clock and Network Endpoints 🔍 Extra
These endpoints work with real hardware but are NOT in official API v1.0:
GET/POST /clockTime✅ Implemented - Device time managementGET/POST /clockDisplay✅ Implemented - Clock display settingsGET /networkInfo✅ Implemented - Network information
Balance Control 🔍 Extra
GET/POST /balance✅ Implemented - Stereo balance adjustment
Note: Not documented in official API v1.0 but works with real devices.
Coverage Summary
Official API Coverage: 84%
- Total Official Endpoints: 19
- Implemented: 16 (84%)
- Missing Low-Impact: 3 (16%)
Feature Coverage: 100%
- ✅ All essential user functionality implemented
- ✅ All core device operations supported
- ✅ Complete WebSocket event system
- ✅ Full multiroom capabilities
- 🔍 Additional features beyond official specification
Error Handling
The API uses standard HTTP status codes:
200 OK- Successful request400 Bad Request- Invalid request404 Not Found- Endpoint or resource not found500 Internal Server Error- Internal device error
Example Implementation
// Example for a GET request
func GetNowPlaying(deviceIP string) (*NowPlaying, error) {
url := fmt.Sprintf("http://%s:8090/now_playing", deviceIP)
resp, err := http.Get(url)
if err != nil {
return nil, err
}
defer resp.Body.Close()
var nowPlaying NowPlaying
err = xml.NewDecoder(resp.Body).Decode(&nowPlaying)
return &nowPlaying, err
}
// Example for a POST request
func SendKey(deviceIP string, key string) error {
url := fmt.Sprintf("http://%s:8090/key", deviceIP)
xmlData := fmt.Sprintf(`<key state="press" sender="GoClient">%s</key>`, key)
resp, err := http.Post(url, "application/xml", strings.NewReader(xmlData))
if err != nil {
return err
}
resp.Body.Close()
return nil
}
Notes
- XML Namespace: Most responses use no explicit XML namespace
- Encoding: UTF-8 is used for all XML documents
- Timeouts: Recommended timeout for HTTP requests: 10 seconds
- Rate Limiting: No explicit limits documented, but moderate usage recommended
- Device Discovery: Devices can be found via UPnP on the local network
Reference
Based on the official Bose SoundTouch Web API documentation: https://assets.bosecreative.com/m/496577402d128874/original/SoundTouch-Web-API.pdf