---
descriptions:
  connection:
    self: 'The SSO [Connection](/reference/sso/connection) object.'
    deleted: 'The [Connection](/reference/sso/connection) that was deleted.'
    object: Distinguishes the Connection object.
    id: Unique identifier for the Connection.
    organization_id: Unique identifier for the Organization in which the Connection resides.
    connection_type: >
      The type of the SSO Connection used to authenticate the user. The
      Connection type may be used to dynamically generate authorization URLs.


      Possible values:

      - `ADFSSAML`

      - `AdpOidc`

      - `AppleOAuth`

      - `Auth0SAML`

      - `AzureSAML`

      - `CasSAML`

      - `ClassLinkSAML`

      - `CloudflareSAML`

      - `CyberArkSAML`

      - `DuoSAML`

      - `GenericOIDC`

      - `GenericSAML`

      - `GitHubOAuth`

      - `GoogleOAuth`

      - `GoogleSAML`

      - `JumpCloudSAML`

      - `KeycloakSAML`

      - `LastPassSAML`

      - `LoginGovOidc`

      - `MagicLink`

      - `MicrosoftOAuth`

      - `MiniOrangeSAML`

      - `NetIqSAML`

      - `OktaSAML`

      - `OneLoginSAML`

      - `OracleSAML`

      - `PingFederateSAML`

      - `PingOneSAML`

      - `RipplingSAML`

      - `SalesforceSAML`

      - `ShibbolethGenericSAML`

      - `ShibbolethSAML`

      - `SimpleSamlPhpSAML`

      - `VMwareSAML`
    name: >-
      A human-readable name for the Connection. This will most commonly be the
      organization's name.
    state:
      lowercase: >
        Indicates whether a Connection is able to authenticate users. Possible
        values:

        - `active`

        - `inactive`

        - `validating`


        Connections that can’t authenticate users are `inactive`. When a new
        connection is configured, it transitions to the `validating` state until
        its first successful authentication. After it successfully authorizes a
        user for the first time, the connection state changes to `active`.
      titlecase: >
        Indicates whether a Connection is able to authenticate users. Possible
        values:

        - `Active`

        - `Inactive`

        - `Validating`


        Connections that can’t authenticate users are `inactive`. When a new
        connection is configured, it transitions to the `validating` state until
        its first successful authentication. After it successfully authorizes a
        user for the first time, the connection state changes to `active`.
    domains: 'List of [Organization Domains](/reference/domain-verification).'
    created_at: The timestamp when the Connection was created.
    updated_at: The timestamp when the Connection was last updated.
reference:
  curl:
    - url: /reference/sso/connection
      key: connection
      id: connection
      title: connection
      properties:
        - key: object
          type: '"connection"'
          description: (connection.object)
        - key: id
          type: string
          description: (connection.id)
        - key: organization_id
          optional: true
          type: string
          description: (connection.organization_id)
        - key: connection_type
          type: enum
          description: (connection.connection_type)
        - key: name
          type: string
          description: (connection.name)
        - key: state
          type: enum
          description: (connection.state.lowercase)
        - key: created_at
          type: string
          description: (connection.created_at)
        - key: updated_at
          type: string
          description: (connection.updated_at)
        - key: domains
          type: array
          description: (connection.domains)
  dotnet:
    - url: /reference/sso/connection
      key: Connection
      id: connection
      title: class Connection
      properties:
        - key: Object
          type: '"connection"'
          description: (connection.object)
        - key: Id
          type: string
          description: (connection.id)
        - key: OrganizationId
          optional: true
          type: string
          description: (connection.organization_id)
        - key: Type
          type: string
          description: (connection.connection_type)
        - key: Name
          type: string
          description: (connection.name)
        - key: State
          type: ConnectionState
          description: (connection.state.titlecase)
        - key: CreatedAt
          type: string
          description: (connection.created_at)
        - key: UpdatedAt
          type: string
          description: (connection.updated_at)
  php:
    - url: /reference/sso/connection
      key: Connection
      id: connection
      title: WorkOS\Resource\Connection
      properties:
        - key: id
          type: string
          description: (connection.id)
        - key: organizationId
          optional: true
          type: string
          description: (connection.organization_id)
        - key: connectionType
          type: string
          optional: true
          description: (connection.connection_type)
        - key: name
          type: string
          description: (connection.name)
        - key: state
          type: string
          description: (connection.state.lowercase)
        - key: createdAt
          type: string
          description: (connection.created_at)
        - key: updatedAt
          type: string
          description: (connection.updated_at)
  ruby:
    - url: /reference/sso/connection
      key: Connection
      id: connection
      title: class Connection
      properties:
        - key: id
          type: String
          description: (connection.id)
        - key: organization_id
          optional: true
          type: String
          description: (connection.organization_id)
        - key: connection_type
          type: String
          description: (connection.connection_type)
        - key: name
          type: String
          description: (connection.name)
        - key: state
          type: String
          description: (connection.state.lowercase)
        - key: created_at
          type: String
          description: (connection.created_at)
        - key: updated_at
          type: String
          description: (connection.updated_at)
        - key: domains
          type: 'Array[Hash]'
          description: (connection.domains)
  python:
    - url: /reference/sso/connection
      key: Connection
      id: connection
      title: ConnectionWithDomains
      properties:
        - key: id
          type: str
          description: (connection.id)
        - key: organization_id
          optional: true
          type: str
          description: (connection.organization_id)
        - key: connection_type
          type: ConnectionType
          description: (connection.connection_type)
        - key: name
          type: str
          description: (connection.name)
        - key: state
          type: str
          description: (connection.state.lowercase)
        - key: created_at
          type: str
          description: (connection.created_at)
        - key: updated_at
          type: str
          description: (connection.updated_at)
        - key: domains
          type: 'list[ConnectionDomain]'
          description: (connection.domains)
  js:
    - url: /reference/sso/connection
      key: Connection
      id: connection
      title: interface Connection
      properties:
        - key: id
          type: string
          description: (connection.id)
        - key: organizationId
          optional: true
          type: string
          description: (connection.organization_id)
        - key: type
          type: string
          optional: true
          description: (connection.connection_type)
        - key: name
          type: string
          description: (connection.name)
        - key: state
          type: string
          description: (connection.state.lowercase)
        - key: createdAt
          type: string
          description: (connection.created_at)
        - key: updatedAt
          type: string
          description: (connection.updated_at)
        - key: domains
          type: 'OrganizationDomain[]'
          description: (connection.domains)
  go:
    - url: /reference/sso/connection
      key: Connection
      id: connection
      title: sso.Connection
      properties:
        - key: ID
          type: string
          description: (connection.id)
        - key: OrganizationID
          optional: true
          type: string
          description: (connection.organization_id)
        - key: ConnectionType
          type: sso.ConnectionType
          description: (connection.connection_type)
        - key: Name
          type: string
          description: (connection.name)
        - key: State
          type: sso.ConnectionState
          description: (connection.state.lowercase)
        - key: CreatedAt
          type: string
          description: (connection.created_at)
        - key: UpdatedAt
          type: string
          description: (connection.updated_at)
        - key: Domains
          type: '[]sso.ConnectionDomain'
          description: (connection.domains)
  java:
    - url: /reference/sso/connection
      key: Connection
      id: connection
      title: class Connection
      properties:
        - key: obj
          type: '"connection"'
          description: (connection.object)
        - key: id
          type: String
          description: (connection.id)
        - key: organizationId
          optional: true
          type: String
          description: (connection.organization_id)
        - key: connectionType
          type: ConnectionType
          optional: true
          description: (connection.connection_type)
        - key: domains
          type: List<ConnectionDomain>
          description: (connection.domains)
        - key: name
          type: String
          description: (connection.name)
        - key: state
          type: ConnectionState
          description: (connection.state.titlecase)
        - key: createdAt
          type: String
          description: (connection.created_at)
        - key: updatedAt
          type: String
          description: (connection.updated_at)
originalPath: .tmp-workos-clone/packages/docs/content/reference/sso/connection/index.mdx
---

# Connection

A connection represents the relationship between WorkOS and any collection of application users. This collection of application users may include personal or enterprise identity providers. As a layer of abstraction, a WorkOS connection rests between an application and its users, separating an application from the implementation details required by specific standards like [OAuth 2.0](/glossary/oauth-2-0) and [SAML](/glossary/saml).

See the [events reference](/events/connection) documentation for the connection events.

<CodeBlock
  title="Example Connection"
  file="connection"
  referenceId="connection"
/>
