Infrastructure User Identities

Infrastructure User Identities are the external accounts your infrastructure providers report, linked to Drata Users. Use the actions endpoint to link or unlink a User and to mark an identity a service account. The admin and database access fields are read-only here. Version control accounts are documented separately under Version Control User Identities.

List Infrastructure User Identities

List the external accounts reported by your infrastructure Connections.

🔒 Requires Connections: Manage Infrastructure User Identities permission.

Securitybearer
Request
path Parameters
workspaceId
required
number

The Workspace ID associated to the Account

query Parameters
cursor
string

This parameter is used to paginate through results. No value is needed for the first request. If there are additional results, the response will contain a pagination.cursor value that can be used in the subsequent request to retrieve the next page of results

size
number [ 1 .. 500 ]
Default: 50

Number of results to return

sort
string (SortTypeLimitedEnum)

Which field to sort by

Enum: "createdAt" "updatedAt"
sortDir
string (SortDirectionEnum)

The direction to sort the data

Enum: "ASC" "DESC"
includeTotalCount
boolean

Include total count of all matching records in response. Only honored on first page (when cursor is null).

Example: includeTotalCount=false
expand[]
Array of strings (UserIdentityExpandEnum)

List of sub-objects to expand

Items Enum: "user" "serviceAccountDesignator" "connection"
identityId
string

Filter by the external service unique ID (exact match)

Example: identityId=1a2b3c
username
string

Filter by the external service username (prefix match)

Example: username=jdoe
email
string

Filter by the external service email (prefix match)

clientType
string (ClientTypeEnum)

Filter by the provider the identity was synced from

Enum: "GOOGLE" "OKTA" "MICROSOFT_365" "AWS" "GCP" "AZURE" "HEROKU" "GITHUB" "GITLAB" "BITBUCKET" "SHORTCUT" "JIRA" "ASANA" "GUSTO" "KARMACHECK" "GITHUB_ISSUES" "RIPPLING" "CERTN" "MERGEDEV_ADP_WORKFORCE_NOW" "MERGEDEV_BAMBOO_HR" "MERGEDEV_HR_PARTNER" "MERGEDEV_HI_BOB" "MERGEDEV_HUMAANS" "MERGEDEV_PERSONIO" "MERGEDEV_SAGE" "DIGITAL_OCEAN" "MERGEDEV_KALLIDUS" "MERGEDEV_TRINET" "MERGEDEV_TRINET_HR" "MERGEDEV_FRESHTEAM" "MERGEDEV_SAP_SUCCESSFACTORS" "TRELLO" "GITLAB_ISSUES" "MERGEDEV_JUSTWORKS" "LINEAR" "PIVOTAL_TRACKER" "WORK_OS" "MERGEDEV_PAYLOCITY" "MONGO_DB_ATLAS" "TARGET_PROCESS" "CLICKUP" "CHECKR" "MERGEDEV_WORKDAY" "ZOHO" "CLOUDFLARE" "JAMF" "AZURE_BOARDS" "AZURE_REPOS" "MERGEDEV_HR_CLOUD" "INTUNE" "OKTA_IDENTITY" "GOODHIRE" "KANDJI" "AWS_CODECOMMIT" "FIBERY" "CURRICULA" "JUMPCLOUD" "HEXNODE_UEM" "RIPPLING_MDM" "AWS_ORG_UNITS" "KNOWBE4" "MERGEDEV_UKG_PRO" "MERGEDEV_UKG_READY" "DATADOG" "SLACK" "DOCUSIGN" "MICROSOFT_TEAMS" "AWS_INSPECTOR" "MERGEDEV_ONELOGIN" "MERGEDEV_JUMPCLOUD" "CONFLUENCE" "WORKSPACE_ONE" "NEW_RELIC" "MERGEDEV_SERVICENOW" "RAPID7" "MERGEDEV_AHA" "MERGEDEV_BASECAMP" "MERGEDEV_BITBUCKET" "MERGEDEV_FRESHDESK" "MERGEDEV_FRESHSERVICE" "MERGEDEV_HEIGHT" "MERGEDEV_HIVE" "MERGEDEV_TEAMWORK" "MERGEDEV_WRIKE" "MERGEDEV_ZENDESK" "CSV_IDP" "APIDECK" "AWS_GOV_CLOUD" "SENTINEL_ONE" "MERGEDEV_NAMELY" "MERGEDEV_INSPERITY_PREMIER" "MERGEDEV_DAYFORCE" "MERGEDEV_ALEXISHR" "MERGEDEV_BREATHE" "MERGEDEV_CHARLIE" "MERGEDEV_CHARTHOP" "MERGEDEV_DEEL" "MERGEDEV_FACTORIAL" "MERGEDEV_INTELLIHR" "MERGEDEV_KEKA" "MERGEDEV_LUCCA" "MERGEDEV_OFFICIENT" "MERGEDEV_PAYCHEX" "MERGEDEV_PEOPLE_HR" "MERGEDEV_OYSTERHR" "MERGEDEV_PAYCOR" "HUBSPOT" "ZOOM" "AUTH0" "SENTRY" "ZAPIER" "SNOWFLAKE" "MIRO" "MERGEDEV_EMPLOYMENT_HERO" "SEGMENT" "WIZ" "XERO" "GITHUB_CODE" "ATLASSIAN" "PAGER_DUTY" "STACKONE_SMARTRECRUITERS" "STACKONE_TEAMTAILOR" "CROWDSTRIKE" "GITHUB_ENTERPRISE" "NOTION" "STACKONE_KLAVIYO" "STACKONE_LASTPASS" "STACKONE_LEAPSOME" "STACKONE_LEVER" "STACKONE_ORACLEHCM" "STACKONE_PINPOINT" "STACKONE_PIPEDRIVE" "STACKONE_RECRUITEE" "STACKONE_WEBEX" "STACKONE_WORKABLE" "STACKONE_ZELT" "STACKONE_BITWARDEN" "STACKONE_SALESLOFT" "STACKONE_DIXA" "STACKONE_FRESHSALES" "STACKONE_CANVA" "STACKONE_GREENHOUSE" "STACKONE_ASHBY" "STACKONE_ATTIO" "STACKONE_CONTENTFUL" "COVERDASH" "MERGEDEV_FRONT" "SALESFORCE" "STACKONE_ELASTIC" "STACKONE_RENDER" "STACKONE_TERRAFORM" "STACKONE_DOMO" "STACKONE_ENVOY" "STACKONE_SCALEWAY" "STACKONE_JETBRAINS" "STACKONE_FIVETRAN" "STACKONE_INTERCOM" "STACKONE_AUTODESK" "GITHUB_ACTIONS" "AZURE_ORG_UNITS" "MICROSOFT_365_GCC_HIGH" "STACKONE_AIRCALL" "STACKONE_15FIVE" "STACKONE_ROLLBAR" "STACKONE_EGNYTE" "STACKONE_QLIK" "STACKONE_BULLHORN" "STACKONE_OPENVPN" "STACKONE_SOPHOS" "STACKONE_MEISTERTASK" "STACKONE_TALENTLMS" "STACKONE_ONEFLOW" "STACKONE_RING_CENTRAL" "STACKONE_ARTICULATE" "STACKONE_DIALPAD" "STACKONE_TABLEAU" "AZURE_DEVOPS" "STACKONE_1PASSWORD" "STACKONE_MIXPANEL" "STACKONE_SONARCLOUD" "STACKONE_TWILIO" "STACKONE_ANSIBLE" "STACKONE_LATTICE" "STACKONE_WEBFLOW" "STACKONE_LACEWORK" "STACKONE_DATABRICKS" "STACKONE_IFS" "STACKONE_TRAVISCI" "STACKONE_MATILLIONETL" "STACKONE_OPTIMIZELY" "UAR_CSV" "STERLING" "HIRERIGHT" "VETTY" "MERGEDEV_CYBERARK" "SALESFORCE_UAR" "GOOGLE_ADMIN_CONSOLE" "VERCEL" "STACKONE_DUO" "STACKONE_GONG" "STACKONE_IRONCLAD" "STACKONE_SCORO" "STACKONE_TEAMVIEWER_REMOTE" "STACKONE_SPOTDRAFT" "STACKONE_SPENDESK" "STACKONE_SENDGRID" "STACKONE_SMARTSHEET" "STACKONE_CHECKMK" "LEEN_TENABLE" "LEEN_QUALYS" "LEEN_SEMGREP" "LEEN_SNYK" "LEEN_CROWDSTRIKE_VMS" "LEEN_MS_DEFENDER_VMS" "LEEN_SENTINELONE_VMS" "GITLAB_ON_PREM" "CUSTOM" "LEEN_RAPID7_VMS" "BAMBOO_HR" "GITLAB_ISSUES_ON_PREM" "GITHUB_ISSUES_ENTERPRISE" "BITBUCKET_CODE" "LEEN_ARNICA" "STACKONE_NETLIFY" "STACKONE_OPENAI" "KOLIDE" "MERGEDEV_JIRA_DATA_CENTER" "MERGEDEV_PINGONE" "GOOGLE_ADMIN_CONSOLE_OAUTH" "GOOGLE_OAUTH" "STACKONE_ANTHROPIC" "INTUNE_GCC_HIGH" "STACKONE_DROPBOX" "STACKONE_DROPBOX_SIGN" "STACKONE_HARVEST" "STACKONE_KAMELEOON" "STACKONE_MAKE" "STACKONE_RETOOL" "STACKONE_TOGGL" "STACKONE_BOX" "MERGEDEV_ZOHO_PEOPLE" "MERGEDEV_ZOHO_DESK" "LEEN_WIZ_VMS" "LEEN_WIZ_CODE" "LEEN_AIKIDO" "MERGEDEV_LATTICE_HRIS" "MERGEDEV_DARWINBOX" "MERGEDEV_PAYCOM" "AZURE_GCC_HIGH" "AZURE_MG_GCC_HIGH" "STACKONE_EASY_LLAMA" "MERGEDEV_LEAPSOME" "CUSTOM_XFA" "LEEN_MS_DEFENDER_VMS_GCC_HIGH" "STACKONE_CORNERSTONE" "STACKONE_DOCEBO" "STACKONE_GO1" "STACKONE_LINKEDIN_LEARNING" "STACKONE_SAP_LEARNING" "STACKONE_WORKDAY_LEARNING" "STACKONE_360LEARNING" "STACKONE_BRAINIER" "STACKONE_COURSERA" "STACKONE_XYLEME" "STACKONE_INFOSEC" "STACKONE_PEOPLE_FLUENT" "STACKONE_UDEMY" "AIKIDO" "AZURE_ENTRA_ID" "GOOGLE_CLOUD_IDENTITY" "HYPERCOMPLY" "INTRUDER" "IRIS_AI" "JIT" "TINES" "TORQ" "TRAY" "SWIF" "LEEN_ORCA_SECURITY" "ZIP" "CUSTOM_MDM" "LEEN_UPWIND" "WORK_OS_SCIM" "LEEN_GITLAB_VMS" "NINJAONE_MDM" "FIELDGUIDE" "OKTA_OAUTH" "IRONCLAD_VENDOR" "CUSTOM_HRIS" "RAMP" "TROPIC_VENDOR" "AZURE_BOARDS_ENTRA" "AZURE_REPOS_ENTRA" "AZURE_DEVOPS_ENTRA" "CERTN_CENTRIC" "ZINC" "DATAGRAIL" "LEEN_SOCKET" "VENDOR_CSV_UPLOAD" "VENDOR_PUBLIC_API" "X_ANALYTICS"
connectionId
number

Filter by Connection ID. More granular than clientType

Example: connectionId=1
Responses
200
400

Malformed data and/or validation errors

401

Invalid Authorization

403

You are not allowed to perform this action

412

You must accept the Drata terms and conditions to use the API

500

Internal server error

get/workspaces/{workspaceId}/infrastructure-user-identities
Request samples
Response samples
application/json
{
  • "data": [
    • {
      • "id": 1,
      • "identityId": "1a2b3c",
      • "username": "jdoe",
      • "email": "[email protected]",
      • "connectedAt": "2025-07-01T16:45:55.246Z",
      • "disconnectedAt": "2025-07-01T16:45:55.246Z",
      • "serviceAccount": "2025-07-01T16:45:55.246Z",
      • "serviceAccountReason": "This user is used to deploy code",
      • "hasMfa": true,
      • "lastCheckedAt": "2025-07-01T16:45:55.246Z",
      • "userId": 0,
      • "connectionId": 0,
      • "createdAt": "2025-07-01T16:45:55.246Z",
      • "updatedAt": "2025-07-01T16:45:55.246Z",
      • "user": {
        • "id": 1,
        • "email": "[email protected]",
        • "firstName": "Sally",
        • "lastName": "Smith",
        • "createdAt": "2025-07-01T16:45:55.246Z",
        • "updatedAt": "2025-07-01T16:45:55.246Z"
        },
      • "serviceAccountDesignator": {
        • "id": 1,
        • "email": "[email protected]",
        • "firstName": "Sally",
        • "lastName": "Smith",
        • "createdAt": "2025-07-01T16:45:55.246Z",
        • "updatedAt": "2025-07-01T16:45:55.246Z"
        },
      • "connection": {
        • "id": "1",
        • "clientType": "GOOGLE",
        • "clientId": "drata.com",
        • "clientAlias": "My-connection-alias-1",
        • "state": "ACTIVE",
        • "createdAt": "2025-07-01T16:45:55.246Z",
        • "updatedAt": "2025-07-01T16:45:55.246Z",
        • "connectedAt": "2025-07-01T16:45:55.246Z",
        • "failedAt": "2025-07-01T16:45:55.246Z",
        • "deletedAt": "2025-07-01T16:45:55.246Z"
        },
      • "adminAccess": "2025-07-01T16:45:55.246Z",
      • "dbAccess": "2025-07-01T16:45:55.246Z",
      • "resourceArn": "arn:aws:iam::123456789012:user/jdoe"
      }
    ],
  • "pagination": {
    • "cursor": "string",
    • "totalCount": 0
    }
}

Get Infrastructure User Identity

Get the full detail of an Infrastructure User Identity.

🔒 Requires Connections: Manage Infrastructure User Identities permission.

Securitybearer
Request
path Parameters
workspaceId
required
number

The Workspace ID associated to the Account

identityId
required
number
query Parameters
expand[]
Array of strings (UserIdentityExpandEnum)

List of sub-objects to expand

Items Enum: "user" "serviceAccountDesignator" "connection"
Responses
200
401

Invalid Authorization

403

You are not allowed to perform this action

404

Not Found

412

You must accept the Drata terms and conditions to use the API

500

Internal server error

get/workspaces/{workspaceId}/infrastructure-user-identities/{identityId}
Request samples
Response samples
application/json
{
  • "id": 1,
  • "identityId": "1a2b3c",
  • "username": "jdoe",
  • "email": "[email protected]",
  • "connectedAt": "2025-07-01T16:45:55.246Z",
  • "disconnectedAt": "2025-07-01T16:45:55.246Z",
  • "serviceAccount": "2025-07-01T16:45:55.246Z",
  • "serviceAccountReason": "This user is used to deploy code",
  • "hasMfa": true,
  • "lastCheckedAt": "2025-07-01T16:45:55.246Z",
  • "userId": 0,
  • "connectionId": 0,
  • "createdAt": "2025-07-01T16:45:55.246Z",
  • "updatedAt": "2025-07-01T16:45:55.246Z",
  • "user": {
    • "id": 1,
    • "email": "[email protected]",
    • "firstName": "Sally",
    • "lastName": "Smith",
    • "createdAt": "2025-07-01T16:45:55.246Z",
    • "updatedAt": "2025-07-01T16:45:55.246Z"
    },
  • "serviceAccountDesignator": {
    • "id": 1,
    • "email": "[email protected]",
    • "firstName": "Sally",
    • "lastName": "Smith",
    • "createdAt": "2025-07-01T16:45:55.246Z",
    • "updatedAt": "2025-07-01T16:45:55.246Z"
    },
  • "connection": {
    • "id": "1",
    • "clientType": "GOOGLE",
    • "clientId": "drata.com",
    • "clientAlias": "My-connection-alias-1",
    • "state": "ACTIVE",
    • "createdAt": "2025-07-01T16:45:55.246Z",
    • "updatedAt": "2025-07-01T16:45:55.246Z",
    • "connectedAt": "2025-07-01T16:45:55.246Z",
    • "failedAt": "2025-07-01T16:45:55.246Z",
    • "deletedAt": "2025-07-01T16:45:55.246Z"
    },
  • "adminAccess": "2025-07-01T16:45:55.246Z",
  • "dbAccess": "2025-07-01T16:45:55.246Z",
  • "resourceArn": "arn:aws:iam::123456789012:user/jdoe"
}

List Infrastructure User Identity Actions

List the actions currently performable on an Infrastructure User Identity. The set depends on its state and on the caller: a service account cannot be linked to a User until it is unmarked, and actions the caller lacks permission for are omitted.

🔒 Requires Connections: Manage Infrastructure User Identities permission.

Securitybearer
Request
path Parameters
workspaceId
required
number

The Workspace ID associated to the Account

identityId
required
number
Responses
200
401

Invalid Authorization

403

You are not allowed to perform this action

404

Not Found

412

You must accept the Drata terms and conditions to use the API

500

Internal server error

get/workspaces/{workspaceId}/infrastructure-user-identities/{identityId}/actions
Request samples
Response samples
application/json
{
  • "data": [
    • {
      • "action": "linkUser",
      • "label": "Link User",
      • "description": "Link this external account to a Drata User",
      • "payloadSchema": [
        • {
          • "name": "reason",
          • "type": "string",
          • "required": true,
          • "description": "Reason for requesting changes"
          }
        ]
      }
    ]
}

Perform Infrastructure User Identity Action

Perform an action on an Infrastructure User Identity. markServiceAccount also clears any linked User and requires a reason. linkUser requires a userId.

🔒 Requires Connections: Manage Infrastructure User Identities, Connections: Manage Infrastructure User Identities permission.

Securitybearer
Request
path Parameters
workspaceId
required
number

The Workspace ID associated to the Account

identityId
required
number
Request Body schema: application/json
required
action
required
string

Action to perform on the Infrastructure User Identity. markServiceAccount also clears any linked User.

Enum: "linkUser" "unlinkUser" "markServiceAccount" "unmarkServiceAccount"
userId
number

The ID of the Drata User to link. Required when action is linkUser

reason
string <= 30000 characters

Why this identity is a service account. Required when action is markServiceAccount

Responses
200
400

Malformed data and/or validation errors

401

Invalid Authorization

403

You are not allowed to perform this action

404

Not Found

409

There is a conflict in the business rules with this request

412

You must accept the Drata terms and conditions to use the API

500

Internal server error

post/workspaces/{workspaceId}/infrastructure-user-identities/{identityId}/actions
Request samples
application/json
{
  • "action": "linkUser",
  • "userId": 1,
  • "reason": "This user is used to deploy code"
}
Response samples
application/json
{
  • "id": 1,
  • "identityId": "1a2b3c",
  • "username": "jdoe",
  • "email": "[email protected]",
  • "connectedAt": "2025-07-01T16:45:55.246Z",
  • "disconnectedAt": "2025-07-01T16:45:55.246Z",
  • "serviceAccount": "2025-07-01T16:45:55.246Z",
  • "serviceAccountReason": "This user is used to deploy code",
  • "hasMfa": true,
  • "lastCheckedAt": "2025-07-01T16:45:55.246Z",
  • "userId": 0,
  • "connectionId": 0,
  • "createdAt": "2025-07-01T16:45:55.246Z",
  • "updatedAt": "2025-07-01T16:45:55.246Z",
  • "user": {
    • "id": 1,
    • "email": "[email protected]",
    • "firstName": "Sally",
    • "lastName": "Smith",
    • "createdAt": "2025-07-01T16:45:55.246Z",
    • "updatedAt": "2025-07-01T16:45:55.246Z"
    },
  • "serviceAccountDesignator": {
    • "id": 1,
    • "email": "[email protected]",
    • "firstName": "Sally",
    • "lastName": "Smith",
    • "createdAt": "2025-07-01T16:45:55.246Z",
    • "updatedAt": "2025-07-01T16:45:55.246Z"
    },
  • "connection": {
    • "id": "1",
    • "clientType": "GOOGLE",
    • "clientId": "drata.com",
    • "clientAlias": "My-connection-alias-1",
    • "state": "ACTIVE",
    • "createdAt": "2025-07-01T16:45:55.246Z",
    • "updatedAt": "2025-07-01T16:45:55.246Z",
    • "connectedAt": "2025-07-01T16:45:55.246Z",
    • "failedAt": "2025-07-01T16:45:55.246Z",
    • "deletedAt": "2025-07-01T16:45:55.246Z"
    },
  • "adminAccess": "2025-07-01T16:45:55.246Z",
  • "dbAccess": "2025-07-01T16:45:55.246Z",
  • "resourceArn": "arn:aws:iam::123456789012:user/jdoe"
}