Get in touch

Get in touch

Prefer using email? Say hi at hello@moveshelf.com

This section explains how to delete a session from Moveshelf using the Moveshelf API, based on the session's ID.
Prerequisites
Before implementing this example, ensure that your processing script includes all necessary setup steps. In particular, you should have:
Implementation
To delete an existing session, add the following lines of code to your processing script:
## README: this example shows how we can delete a session from Moveshelf 
# using the Moveshelf API.

# Delete a session by ID
session_id = "<sessionId>" # session["id"]
result = api.deleteSession(session_id)

if result:
    print(f"Session {session_id} deleted successfully")
else:
    print(f"Failed to delete session {session_id}")