mirror of
https://github.com/owntone/owntone-server.git
synced 2025-11-07 04:42:58 -05:00
[player/jsonapi/db] Add interface to get and set an output format
This commit is contained in:
@@ -341,6 +341,7 @@ GET /api/outputs
|
||||
| requires_auth | boolean | `true` if output requires authentication |
|
||||
| needs_auth_key | boolean | `true` if output requires an authorization key (device verification) |
|
||||
| volume | integer | Volume in percent (0 - 100) |
|
||||
| format | string | Stream format |
|
||||
|
||||
**Example**
|
||||
|
||||
@@ -359,7 +360,8 @@ curl -X GET "http://localhost:3689/api/outputs"
|
||||
"has_password": false,
|
||||
"requires_auth": false,
|
||||
"needs_auth_key": false,
|
||||
"volume": 0
|
||||
"volume": 0,
|
||||
"format": "alac"
|
||||
},
|
||||
{
|
||||
"id": "0",
|
||||
@@ -369,7 +371,8 @@ curl -X GET "http://localhost:3689/api/outputs"
|
||||
"has_password": false,
|
||||
"requires_auth": false,
|
||||
"needs_auth_key": false,
|
||||
"volume": 19
|
||||
"volume": 19,
|
||||
"format": "pcm"
|
||||
},
|
||||
{
|
||||
"id": "100",
|
||||
@@ -379,7 +382,8 @@ curl -X GET "http://localhost:3689/api/outputs"
|
||||
"has_password": false,
|
||||
"requires_auth": false,
|
||||
"needs_auth_key": false,
|
||||
"volume": 0
|
||||
"volume": 0,
|
||||
"format": "pcm"
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -448,6 +452,7 @@ curl -X GET "http://localhost:3689/api/outputs/0"
|
||||
"requires_auth": false,
|
||||
"needs_auth_key": false,
|
||||
"volume": 3
|
||||
"format": "pcm",
|
||||
}
|
||||
```
|
||||
|
||||
@@ -474,6 +479,7 @@ PUT /api/outputs/{id}
|
||||
| selected | boolean | *(Optional)* `true` to enable and `false` to disable the output |
|
||||
| volume | integer | *(Optional)* Volume in percent (0 - 100) |
|
||||
| pin | string | *(Optional)* PIN for device verification |
|
||||
| format | string | *(Optional)* Stream format |
|
||||
|
||||
**Response**
|
||||
|
||||
|
||||
Reference in New Issue
Block a user