Skip to content

Delete Setting

Deletes one custom setting identified by its account login and key. Other settings are retained. The stored value can be any supported type, including boolean.

DELETE

https://{some_domain}/setting

Authorization

Include the session JWT in the Authorization header:

Authorization: <JWT_TOKEN>

User, customer, manager, administrator, and dealer sessions are supported. The login field is required for every session. For a user session, the server deletes the setting for the authenticated account login, regardless of the supplied login. Customer and staff sessions use the supplied login. Staff sessions need the access_backoffice scope and set_accounts permission; a SuperAdmin bypasses these staff scope and permission checks.

Request

Content-Type: application/json

Body Parameters

Field Type Required Description
login integer Yes Account login. Required even when the authenticated user login is used.
key string Yes Name of the setting to delete.

No value field is required.

Request Example

{
  "login": 7777864,
  "key": "soundNotify"
}

Response

Response Fields

Field Type Description
data string OK when the setting is deleted. Present on success.
error string Error identifier. Present on failure.
message string Error description. Returned for validation, login resolution, permission, and deletion failures.

Error Responses

HTTP Error Description
400 INVALID_DATA A required field is missing or has an invalid type.
401 PERMISSION_DENIED The session does not satisfy the action's access requirements.
403 INVALID_ACCESS The target login could not be resolved.
403 RET_NOT_ENOUGH_RIGHTS A staff session lacks the required scope or permission.
500 INVALID_DEL_SETTING Deletion failed, including when the setting key does not exist.

Deleting a missing key is not treated as a successful no-op. The current handler returns HTTP 500 with INVALID_DEL_SETTING rather than HTTP 404.

Persistence failure example:

{
  "error": "INVALID_DEL_SETTING",
  "message": "Common error"
}

Success (200)

{
  "data": "OK"
}

Use Get Settings By Login to read the remaining settings, or Set Setting to create or replace a setting.