Remove Profile Information

POST {work user id}/remove_profile_information

This endpoint can be used to remove profile fields from deactivated users on Workplace.

By calling this endpoint, personal information on a user's profile such as name and profile image will be removed. A full list of fields that will be removed is provided below. All posts and comments made by this person will still be available on Workplace.

Profile fields can be removed 4 or more days after account deactivation.

Removing personal information is permanent and can't be undone.

Profile field information removed via API cannot be restored later, even if the same individual returns back to the organisation.

Affected Fields

The following is the full list of affected fields:

  • External ID
  • Username
  • Formatted name
  • Family name
  • Given name
  • Middle name
  • Honorific prefix
  • Honorific suffix
  • Display name
  • Nicknames
  • Profile URL
  • Preferred language
  • Locale
  • Profile languages
  • Timezone
  • Employee number
  • Entitlements
  • Hire date
  • Termination date
  • Roles
  • Emails
  • IMs
  • Phone numbers
  • Addresses
  • Manager email
  • Manager external ID
  • Manager
  • Skills
  • Bio
  • Frontline settings
  • Total report count
  • Custom pronoun text
  • Division
  • Department
  • Job title
  • Org
  • Cost Center
  • IDP import settings
  • Creation invite
  • Unlaunched login attempt
  • X509 certificates
  • Cover photo
  • Profile picture
  • Follows
  • Birthday
  • Name pronunciation

Required Permissions

The Remove Profile Information endpoint requires the permission remove_profile_information.

Result

Following a successful call to this endpoint, a deactivated profile will appear on Workplace with the anonymised name "Former Member", and all of the profile fields listed under Affected Fields will be empty.

Request Parameters

None

Example

Sample Request

POST {work user id}/remove_profile_information

Endpoint Response

When the end user is deactivated more than 4 days ago:

{"success":true}

When the user is deactivated, but fewer than 4 days have passed since deactivation:

{
  "error":
  {
    "message":"Deactivation Grace Period is Not Over",
    "type":"OAuthException",
    "code":2624063,
    "error_subcode":2624063,
    "is_transient":false,
    "error_user_title":"Deactivation Grace Period is Not Over",
    "error_user_msg":"Profile information can only be removed 4 days after an account has been deactivated. Try again after 4 days has passed."
  }
}

When the user is still active:

{
  "error":
  {
    "message":"Account Not Eligible For Anonymisation",
    "type":"OAuthException",
    "code":2624064,
    "error_subcode":2624056,
    "is_transient":false,
    "error_user_title":"Account Not Eligible For Anonymisation",
    "error_user_msg":"Account is not eligible for profile anonymisation. User should be deactivated already and grace period should be over. Company should be eligible to use this feature."
  }
}

When the user is still active and a community admin:

{
  "error":
  {
    "message":"An unknown error occurred",
    "type":"OAuthException",
    "code":1,"error_subcode":1855201,
    "is_transient":false,
    "error_user_title":"Unable to Deactivate Admin Profiles",
    "error_user_msg":"You'll need to make sure this person is not an admin before you can deactivate their profile."
  }
}
      

When the user has already had their profile fields removed:


{
  "error":
  {
    "message":"Account Not Eligible For Anonymisation",
    "type":"OAuthException",
    "code":2624064,
    "error_subcode":2624056,
    "is_transient":false,
    "error_user_title":"Account Not Eligible For Anonymisation",
    "error_user_msg":"Account is not eligible for profile anonymisation. User should be deactivated already and grace period should be over. Company should be eligible to use this feature."
  }
}