Skip to main content
POST
/
workspace
/
devices
Create a CLI Device
curl --request POST \
  --url https://wks-a1b2c3d4.provisionr.io/api/v1/workspace/devices \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "workspace_user_id": "<string>",
  "app_composer_path": "<string>",
  "app_composer_version": "<string>",
  "app_cli_version": "<string>",
  "app_php_path": "<string>",
  "app_php_version": "<string>",
  "ip_address": "<string>",
  "os_chipset": "<string>",
  "os_hostname": "<string>",
  "os_platform": "macOS",
  "os_serial": "<string>",
  "os_uuid": "<string>",
  "os_version": "<string>"
}
'
{
  "id": "<string>",
  "app_composer_path": "<string>",
  "app_composer_version": "<string>",
  "app_cli_version": "<string>",
  "app_php_path": "<string>",
  "app_php_version": "<string>",
  "ip_address": "<string>",
  "os_chipset": "<string>",
  "os_hostname": "<string>",
  "os_platform": "<string>",
  "os_serial": "<string>",
  "os_uuid": "<string>",
  "os_version": "<string>",
  "count": {
    "workspace_logs_parent": 123,
    "workspace_logs_record": 123,
    "workspace_logs_related": 123
  },
  "timestamp": {
    "created_at": "<string>",
    "updated_at": "<string>",
    "deleted_at": "<string>"
  },
  "included": {
    "refresh_token": {
      "workspace_id": "<string>",
      "workspace_token_id": "<string>",
      "token_type": "cli_activation",
      "created_at": "2023-11-07T05:31:56Z",
      "last_used_at": "2023-11-07T05:31:56Z",
      "expires_at": "2023-11-07T05:31:56Z",
      "expires_at_mins": 123,
      "requested_at": "2023-11-07T05:31:56Z"
    },
    "workspace_user": {
      "id": "<string>",
      "state": "staged",
      "provider": "google",
      "provider_id": "<string>",
      "name": "<string>",
      "handle": "<string>",
      "email": "<string>"
    }
  },
  "links": {
    "self": "<string>",
    "refresh_token": "<string>",
    "workspace_user": "<string>",
    "workspace_logs_parent": "<string>",
    "workspace_logs_record": "<string>",
    "workspace_logs_related": "<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.

Body

application/json

CreateWorkspaceDeviceRequestData

workspace_user_id
string
required
Pattern: ^wsusr_[0-9a-hjkmnp-tv-z]{26}$
Example:

"wsusr_01hq8xyzabc123def456ghi789"

app_composer_path
string
required

The path to the Composer installation on the client.

If it starts with /Users/, the username portion of the path is masked for privacy. The only exposed data is in the os_hostname which is used for device trust verification by some organizations

Maximum string length: 255
Example:

"/Users/masked/Library/Application Support/Herd/bin//composer"

app_composer_version
string
required
Example:

"x.y.z"

app_cli_version
string
required
Maximum string length: 55
Example:

"x.y.z"

app_php_path
string
required

The path to the PHP installation on the client.

If it starts with /Users/, the username portion of the path is masked for privacy. The only exposed data is in the os_hostname which is used for device trust verification by some organizations

Maximum string length: 255
Example:

"/Users/masked/Library/Application Support/Herd/bin//php"

app_php_version
string
required
Example:

"x.y.z"

ip_address
string
required
Example:

"1.2.3.4"

os_chipset
string
required
Maximum string length: 55
Example:

"Apple M1 Pro"

os_hostname
string
required
Maximum string length: 256
Example:

"dmurphy-laptop"

os_platform
enum<string>
required
Available options:
macOS
Maximum string length: 55
Example:

"macOS"

os_serial
string
required
Required string length: 8 - 14
Example:

"A1B2C3D4E5F6G7"

os_uuid
string
required
Example:

"A1B2C3D4-E5F6-G7H8-I9J0-K1L2M3N4O5P6"

os_version
string
required
Example:

"x.y.z"

Response

WorkspaceDeviceDetailedResponseData

id
string
required
Example:

"wsdev_01hq8xyzabc123def456ghi789"

app_composer_path
string | null
required
Example:

"/opt/homebrew/bin/composer"

app_composer_version
string | null
required
Example:

"x.y.z"

app_cli_version
string | null
required
Example:

"x.y.z"

app_php_path
string | null
required
Example:

"/opt/homebrew/bin/php"

app_php_version
string | null
required
Example:

"x.y.z"

ip_address
string | null
required
Example:

"1.2.3.4"

os_chipset
string | null
required
Example:

"Apple M1 Pro"

os_hostname
string | null
required
Example:

"dmurphy-laptop"

os_platform
string | null
required
Example:

"macOS"

os_serial
string | null
required
Example:

"A1B2C3D4E5F6G7"

os_uuid
string | null
required
Example:

"A1B2C3D4-E5F6-G7H8-I9J0-K1L2M3N4O5P6"

os_version
string | null
required
Example:

"x.y.z"

count
object
required

Count of related records

timestamp
object
required

The timestamps for the workspace device record

Example:
{
"created_at": "2024-03-15T10:30:00.000000Z",
"updated_at": "2024-03-15T14:22:00.000000Z",
"deleted_at": null
}
included
object
required

Included related resources for the workspace device record

API hyperlinks related to the workspace device record

Example:
{
"self": "https://ws-a1b2c3.provisionr.io/api/v1/workspace/devices/wsdev_01hq8xyzabc123def456ghi789"
}