1. Home
  2. Docs
  3. Employee Sync
  4. Deactivating/Reactivating an Employee
  5. PUT Structure for Deactivating/Reactivating a User

PUT Structure for Deactivating/Reactivating a User

Setting the active field to false will deactivate the user in 7shifts, which will prevent the user from being able to log into 7shifts. Please ensure this field is only being set when the user is truly deactivated in your system

Similarly, setting the active field to true for a user that had it previously set to false will reactivate the user, and will allow them to log back into 7shifts using the old login credentials. This should also only be set when a user has been truly reactivated in your system, or it could allow ex-employees to log back into the 7shifts company.

An example PUT request to deactivate the previously created employee with ID 5252552 would look as follows:

Request URL

PUT https://api.7shifts.com/v1/users/5252552

Request body

    "user": {
        "active": false

Similarly, changing the active field value to true would activate the user.