Update the mode order
const url = 'https://example.com/api/v1/preferences/mode-order';const options = { method: 'PUT', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"mode_order":["example"]}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request PUT \ --url https://example.com/api/v1/preferences/mode-order \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "mode_order": [ "example" ] }'Updates the mode order. It requires a signed-in User with the account scope. It can return 400 if the request is invalid, 401 if the session is missing or expired, 403 if access is denied, 409 if the request conflicts with the current state, 413 if the request is too large and 503 if the service is temporarily unavailable. Route: /api/v1/preferences/mode-order. Inputs: . Do not automatically replay this operation after an uncertain result.
Authorizations
Section titled “Authorizations”Request Bodyrequired
Section titled “Request Bodyrequired”One validated order. Unknown Plugin IDs stay in the list so a later Plugin can return to its saved position without moving the User’s other modes.
object
Stable Plugin IDs in the User’s chosen order.
Examplegenerated
{ "mode_order": [ "example" ]}Responses
Section titled “Responses”The mode order was saved for this User
The current User ID lets the Installation keep its local first-paint cache attached to the right User when several people sign in on one browser.
object
None means no Installation has saved a custom order yet.
Immutable ID of the authenticated User.
Examplegenerated
{ "mode_order": [ "example" ], "user_id": "example"}The mode order contains invalid Plugin IDs
The standard API error response: { "error": { ... } }.
object
Example
{ "error": { "code": "bad_request" }}Authentication required
The standard API error response: { "error": { ... } }.
object
Example
{ "error": { "code": "bad_request" }}Account scope required
The standard API error response: { "error": { ... } }.
object
Example
{ "error": { "code": "bad_request" }}User settings could not be merged
The standard API error response: { "error": { ... } }.
object
Example
{ "error": { "code": "bad_request" }}The request body exceeds 8 KiB
User settings could not be saved
The standard API error response: { "error": { ... } }.
object
Example
{ "error": { "code": "bad_request" }}