Skip to main content
PATCH
/
workspace
/
users
/
{user}
/
restore
Restore a Deprovisioned User
curl --request PATCH \
  --url https://wks-a1b2c3d4.provisionr.io/api/v1/workspace/users/{user}/restore \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "roles": true
}'
{
  "id": "<string>",
  "state": "staged",
  "provider": "google",
  "provider_id": "<string>",
  "name": "<string>",
  "handle": "<string>",
  "email": "<string>",
  "ui_mode": "<string>",
  "ui_color": "<string>",
  "timestamp": {
    "created_at": "<string>",
    "updated_at": "<string>",
    "expires_at": "<string>",
    "last_authenticated_at": "<string>",
    "last_activity_at": "<string>",
    "deleted_at": "<string>"
  },
  "count": {
    "workspace_devices": 123,
    "workspace_roles": 123,
    "workspace_services": 123,
    "workspace_logs_actor": 123,
    "workspace_logs_parent": 123,
    "workspace_logs_record": 123,
    "workspace_logs_related": 123,
    "workspace_logs_subject": 123
  },
  "included": [
    "<string>"
  ],
  "links": {
    "self": "<string>",
    "directory_user": "<string>",
    "workspace_devices": "<string>",
    "workspace_roles": "<string>",
    "workspace_services": "<string>",
    "workspace_tokens": "<string>"
  }
}

Documentation Index

Fetch the complete documentation index at: https://docs.provisionr.io/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

user
string
required

Workspace User ID

Body

application/json

RestoreWorkspaceUserRequestData

roles
boolean
required

Response

WorkspaceUserDetailedResponseData

id
string
required
Example:

"wsusr_01hq8xyzabc123def456ghi789"

state
enum<string>
required
staged
The record is staged and is only visible to administrators or in the API. Use the activate method during your change window.
active
The record is active.
expiring
The expires_at value is set in the future for the record. You can run the activate action to remove the scheduled expiration.
expired
The expires_at value is in the past and the record was deactivated.
deactivated
The record was deactivated manually by an administrator.
Available options:
staged,
active,
expiring,
expired,
deactivated
provider
enum<string>
required
google
Google Account (not Workspace specific)
fleetdock
Provisionr Fleetdock
okta
Okta Workforce Identity
Available options:
google,
fleetdock,
okta
provider_id
string | null
required

The ID of the user from the IdP SSO Response

name
string
required

The first and last name of the user from the IdP SSO Response

handle
string
required

The username of the user. Unless overridden, this is usually the email address handle

email
string
required

The email address of the user

ui_mode
string | null
required

Provisionr has UI color accessibility features that allows each user to choose light or dark mode

ui_color
string | null
required

Provisionr has UI color accessibility features that allows each user to choose any color theme that they prefer and light or dark mode for the application UI. The sign in page and the default color theme for users is usually based on your company branding or logo color.

You can see all of the colors in the Tailwind CSS docs: https://tailwindcss.com/docs/colors

timestamp
object
required

The timestamps for the workspace user record

Example:
{
"created_at": "2024-03-15T10:30:00.000000Z",
"updated_at": "2024-03-15T14:22:00.000000Z",
"expires_at": null,
"last_authenticated_at": "2024-03-16T08:00:00.000000Z",
"last_activity_at": "2024-03-16T09:30:00.000000Z",
"deleted_at": null
}
count
object
required

Count of related records

included
string[]
required

API hyperlinks related to the workspace user record