Data Methodsstorage.remove

storage.remove

Deletes one key from your app's own storage.

Removes a key. Removing a key that does not exist is not an error.

PropertyValue
ScopeNone (open method)
Who can use itAny developer
StatusAvailable

Parameters

NameTypeRequiredDescription
keystringYesA key is 1 to 128 characters: letters, digits and . _ : -.

Result

FieldTypeDescription
okbooleantrue when the key is gone.

Errors

CodeWhen
-32602A parameter is missing, has the wrong type or is over its limit.
4200Storage cannot be written: there is no signed-in account, or the device store failed.
4290More than 30 requests in 10 seconds.

See Error Codes for every code and how they reach your page.

Example

js
await window.aksa.request({ method: "storage.remove", params: { key: "draft" } });

With AksaMini

If your page embeds aksa-mini.js, use its wrapper:

js
await AksaMini.store.remove("draft");

Used By

Ready To Build Or Ship?

Check your files, preview on an iPhone frame, and submit in the Developer Studio.