Return to developer resources

Removed Users

API - Removing Users

Save time in revoking booking permissions whenever someone leaves. Automate user removal with our API.

EndPoint

https://wiggledesk.com/api/remove_membership/

Overview

Our remove_membership endpoint automates the removal of existing users in WiggleDesk.

If you have thousands of users it can add more overhead to your offboarding teams when removing their set up with internal services. WiggleDesk saves time by automating the provision of access to your spaces.

Behaviour

The API endpoint listens for POST requests containing an email addresses of users that you'd like to remove.

The removed user's historical data will still exist but they will not be able to make new bookings.

This is equivilent to removing a user via our 'Manage Users' page:

Removed Users

Before We Begin

First grab your API key from your profile page. If you don't see it, you'll need to double check with a WiggleDesk Admin that your account has been given access and that the steps outlined in our 'Getting started' page have been followed.

WiggleDesk's API can be tested with httpie which is a basic http client written in Python.

You can install httpie using pip:

pip install httpie

Access API Via Code

The below example uses HTTPIE to illustrate how to connect to this endpoint. Simply swap out 'YOUR_SECRET_TOKEN' with your secret token and 'EXAMPLE@EXAMPLE.COM' with the email address of the user that you'd like to invite.

http POST https://wiggledesk.com/api/remove_membership/ "Authorization: token YOUR_SECRET_TOKEN" email_invited=EXAMPLE@EXAMPLE.COM

Response

A successful response will return something like this:

HTTP/1.1 201 Created

Allow: POST, HEAD, OPTIONS

Content-Length: 119

Content-Type: application/json

Date: Tue, 14 Jun 2022 09:24:17 GMT

Location: https://wiggledesk.com/api/remove_membership/membership_id/

Referrer-Policy: same-origin

Server: Google Frontend

Vary: Accept

X-Cloud-Trace-Context:

X-Content-Type-Options: nosniff

X-Frame-Options: SAMEORIGIN

{

"email_invited": "example@example.com",

"url": "https://wiggledesk.com/api/remove_membership/membership_id/"

}

Published June 18, 2022

Tagged Adding Users API


What is WiggleDesk?

WiggleDesk is the easiest way to roll out and manage hybrid working in your organisation.

Get set up in 10 minutes, more info here.