Docs : SDK : deleteItem
deleteItem lets you delete an item from a user's database. This API will return a promise that gets resolved once the item has been durably deleted from the database.
userbase.deleteItem({ databaseName, itemId })
.then(() => {
// item deleted
})
.catch((e) => console.error(e))
Parameters
-
databaseName [string | Len: 1-50] - The database name to use.
-
itemId [string | Len: 1-100] - The unique identifier of the item to delete.
Errors
- ParamsMustBeObject
- DatabaseNotOpen
- DatabaseNameMustBeString
- DatabaseNameCannotBeBlank
- DatabaseNameTooLong
- ItemIdMustBeString
- ItemIdCannotBeBlank
- ItemIdTooLong
- ItemDoesNotExist
- ItemUpdateConflict
- UserNotSignedIn
- UserNotFound
- ServiceUnavailable