---
descriptions:
  identity:
    type: The type of the identity.
    idp_id: The unique ID of the user in the external identity provider.
    provider: |
      The type of OAuth provider for the identity.

      Possible values:
      - `AppleOAuth`
      - `GitHubOAuth`
      - `GoogleOAuth`
      - `MicrosoftOAuth`
reference:
  json:
    - url: /reference/authkit/identity
      key: identity
      id: identity
      title: identity
      properties:
        - key: idp_id
          type: string
          description: (identity.idp_id)
        - key: type
          type: '"OAuth"'
          description: (identity.type)
        - key: provider
          type: enum
          description: (identity.provider)
  java:
    - url: /reference/authkit/identity
      key: Identity
      id: identity
      title: class Identity
      properties:
        - key: idpId
          type: String
          description: (identity.idp_id)
        - key: type
          type: '"OAuth"'
          description: (identity.type)
        - key: provider
          type: IdentityProviderEnumType
          description: (identity.provider)
  js:
    - url: /reference/authkit/identity
      key: Identity
      id: identity
      title: interface Identity
      properties:
        - key: idpId
          type: String
          description: (identity.idp_id)
        - key: type
          type: '"OAuth"'
          description: (identity.type)
        - key: provider
          type: '"AppleOAuth" | "GoogleOAuth" | "GitHubOAuth" | "MicrosoftOAuth"'
          description: (identity.provider)
originalPath: .tmp-workos-clone/packages/docs/content/reference/authkit/identity/index.mdx
---

# Identities

Represents [User](/reference/authkit/user) identities obtained from external identity providers.

When a user authenticates using an external provider like [Google OAuth](/integrations/google-oauth), information from that provider will be made available as one of the user's Identities. You can read more about the process in our [identity linking guide](/authkit/identity-linking).

> Applications should check the `type` before making assumptions about the shape of the identity. Currently only `OAuth` identities are supported, but more types may be added in the future.

<CodeBlock title="Identity" referenceId="identity" file="identity" />
