<!-- llms.txt: https://workos.com/llms.txt -->

# Provider

A provider represents a third-party service that users can connect to through Pipes. Providers are configured in the WorkOS Dashboard and define the OAuth scopes and credentials used during the authorization flow.

When listed for a specific user, each provider includes a `connected_account` field showing the user's connection status.

## Configure a provider for an organization

Creates or updates an organization's provider configuration. Use this endpoint to enable or disable a provider, set custom OAuth scopes, or supply organization-managed OAuth credentials.

:::code-group

```bash language="curl" title="Request" tab="1"
curl --request PUT \
  --url "https://api.workos.com/organizations/org_01EHZNVPK3SFK441A1RGBFSHRT/data_integration_configurations/github" \
  --header "Authorization: Bearer sk_example_123456789" \
  --header "Content-Type: application/json" \
  -d @- <<'BODY'
    {
        "enabled": true,
        "scopes": [
            "repo",
            "user:email"
        ],
        "client_id": "client_01EHZNVPK3SFK441A1RGBFSHRT",
        "client_secret": "••••••••",
        "config": {
            "account": "myorg-myaccount"
        }
    }
BODY
```

```rb language="ruby" title="Request" tab="1"
require "workos"

WorkOS.configure do |config|
  config.api_key = "sk_example_123456789"
end

WorkOS.client.pipes_provider.update_organization_data_integration_configuration(
  organization_id: "org_01EHZNVPK3SFK441A1RGBFSHRT",
  slug: "github"
)
```

```py language="python" title="Request" tab="1"
from workos import WorkOSClient

client = WorkOSClient(api_key="sk_example_123456789", client_id="client_123456789")

client.pipes_provider.update_organization_data_integration_configuration(
    organization_id="org_01EHZNVPK3SFK441A1RGBFSHRT", slug="github"
)
```

```go language="go" title="Request" tab="1"
package main

import (
	"context"

	"github.com/workos/workos-go/v10"
)

func main() {
	client := workos.NewClient("sk_example_123456789")

	_, err := client.PipesProvider().UpdateOrganizationDataIntegrationConfiguration(context.Background(), "org_01EHZNVPK3SFK441A1RGBFSHRT", "github")
	if err != nil {
		panic(err)
	}
}
```

```php language="php" title="Request" tab="1"
<?php

use WorkOS\WorkOS;

$workos = new WorkOS(
    apiKey: "sk_example_123456789",
    clientId: "client_123456789",
);

$workos
    ->pipesProvider()
    ->updateOrganizationDataIntegrationConfiguration(
        organizationId: "org_01EHZNVPK3SFK441A1RGBFSHRT",
        slug: "github",
    );
```

```java language="java" title="Request" tab="1"
import com.workos.WorkOS;

WorkOS workos = new WorkOS("sk_example_123456789");

workos.pipesProvider.updateOrganizationDataIntegrationConfiguration(
    "org_01EHZNVPK3SFK441A1RGBFSHRT", "github");
```

```cs language="dotnet" title="Request" tab="1"
using WorkOS;

var client = new WorkOSClient(new WorkOSOptions {
    ApiKey = "sk_example_123456789",
    ClientId = "client_123456789",
});

await client.PipesProvider.UpdateOrganizationDataIntegrationConfigurationAsync("org_01EHZNVPK3SFK441A1RGBFSHRT",
                                                                               "github");
```

```rust language="rust" title="Request" tab="1"
use workos::Client;

#[tokio::main]
async fn main() -> Result<(), workos::Error> {
    let client = Client::builder()
        .api_key("sk_example_123456789")
        .client_id("client_123456789")
        .build();

    let _result = client
        .pipes_provider()
        .update_organization_data_integration_configuration(
            "org_01EHZNVPK3SFK441A1RGBFSHRT",
            "github"
        )
        .await?;

    Ok(())
}
```

```json language="json" title="Response" tab="2"
{
  "object": "data_integration_configuration",
  "id": "data_integration_01EHZNVPK3SFK441A1RGBFSHRT",
  "organization_id": "org_01EHZNVPK3SFK441A1RGBFSHRT",
  "slug": "github",
  "name": "GitHub",
  "enabled": true,
  "scopes": [
    "repo",
    "user:email"
  ],
  "config": {
    "account": "myorg-myaccount"
  },
  "created_at": "2024-01-15T10:30:00.000Z",
  "updated_at": "2024-01-15T10:30:00.000Z",
  "credentials": {
    "credentials_type": "organization",
    "has_credentials": true,
    "client_id": "client_01EHZNVPK3SFK441A1RGBFSHRT",
    "client_secret_last_four": "1a2b",
    "redirect_uri": "https://api.workos.com/data-integrations/github/dik_01EHZNVPK3SFK441A1RGBFSHRT/callback"
  }
}
```

:::

## List providers for an organization

Returns a list of all providers available to the specified organization, along with any configured custom OAuth scopes, enabled state, and organization-managed credentials where applicable.

:::code-group

```bash language="curl" title="Request" tab="1"
curl "https://api.workos.com/organizations/org_01EHZNVPK3SFK441A1RGBFSHRT/data_integration_configurations" \
  --header "Authorization: Bearer sk_example_123456789"
```

```rb language="ruby" title="Request" tab="1"
require "workos"

WorkOS.configure do |config|
  config.api_key = "sk_example_123456789"
end

WorkOS.client.pipes_provider.list_organization_data_integration_configurations(organization_id: "org_01EHZNVPK3SFK441A1RGBFSHRT")
```

```py language="python" title="Request" tab="1"
from workos import WorkOSClient

client = WorkOSClient(api_key="sk_example_123456789", client_id="client_123456789")

client.pipes_provider.list_organization_data_integration_configurations(
    organization_id="org_01EHZNVPK3SFK441A1RGBFSHRT"
)
```

```go language="go" title="Request" tab="1"
package main

import (
	"context"

	"github.com/workos/workos-go/v10"
)

func main() {
	client := workos.NewClient("sk_example_123456789")

	_, err := client.PipesProvider().ListOrganizationDataIntegrationConfigurations(context.Background(), "org_01EHZNVPK3SFK441A1RGBFSHRT")
	if err != nil {
		panic(err)
	}
}
```

```php language="php" title="Request" tab="1"
<?php

use WorkOS\WorkOS;

$workos = new WorkOS(
    apiKey: "sk_example_123456789",
    clientId: "client_123456789",
);

$workos
    ->pipesProvider()
    ->listOrganizationDataIntegrationConfigurations(
        organizationId: "org_01EHZNVPK3SFK441A1RGBFSHRT",
    );
```

```java language="java" title="Request" tab="1"
import com.workos.WorkOS;

WorkOS workos = new WorkOS("sk_example_123456789");

workos.pipesProvider.listOrganizationDataIntegrationConfigurations(
    "org_01EHZNVPK3SFK441A1RGBFSHRT");
```

```cs language="dotnet" title="Request" tab="1"
using WorkOS;

var client = new WorkOSClient(new WorkOSOptions {
    ApiKey = "sk_example_123456789",
    ClientId = "client_123456789",
});

await client.PipesProvider.ListOrganizationDataIntegrationConfigurationsAsync("org_01EHZNVPK3SFK441A1RGBFSHRT");
```

```rust language="rust" title="Request" tab="1"
use workos::Client;

#[tokio::main]
async fn main() -> Result<(), workos::Error> {
    let client = Client::builder()
        .api_key("sk_example_123456789")
        .client_id("client_123456789")
        .build();

    let _result = client
        .pipes_provider()
        .list_organization_data_integration_configurations("org_01EHZNVPK3SFK441A1RGBFSHRT")
        .await?;

    Ok(())
}
```

```json language="json" title="Response" tab="2"
{
  "object": "list",
  "data": [
    {
      "object": "data_integration_configuration",
      "id": "data_integration_01EHZNVPK3SFK441A1RGBFSHRT",
      "organization_id": "org_01EHZNVPK3SFK441A1RGBFSHRT",
      "slug": "github",
      "name": "GitHub",
      "enabled": true,
      "scopes": [
        "repo",
        "user:email"
      ],
      "config": {
        "account": "myorg-myaccount"
      },
      "created_at": "2024-01-15T10:30:00.000Z",
      "updated_at": "2024-01-15T10:30:00.000Z",
      "credentials": {
        "credentials_type": "organization",
        "has_credentials": true,
        "client_id": "client_01EHZNVPK3SFK441A1RGBFSHRT",
        "client_secret_last_four": "1a2b",
        "redirect_uri": "https://api.workos.com/data-integrations/github/dik_01EHZNVPK3SFK441A1RGBFSHRT/callback"
      }
    }
  ]
}
```

:::

## List providers for a user

Retrieves a list of available providers and the user's connection status for each. Returns all providers configured for your environment, along with the user's [connected account](https://workos.com/docs/reference/pipes/connected-account) information where applicable.

:::code-group

```bash language="curl" title="Request" tab="1"
curl "https://api.workos.com/user_management/users/user_01EHZNVPK3SFK441A1RGBFSHRT/data_providers" \
  --header "Authorization: Bearer sk_example_123456789"
```

```js language="js" title="Request" tab="1"
import { WorkOS } from '@workos-inc/node';

const workos = new WorkOS('sk_example_123456789');

const providers = await workos.pipes.listUserDataProviders({
  userId: 'user_01EHZNVPK3SFK441A1RGBFSHRT',
});
```

```rb language="ruby" title="Request" tab="1"
require "workos"

WorkOS.configure do |config|
  config.api_key = "sk_example_123456789"
end

WorkOS.client.pipes.list_user_data_providers(user_id: "user_01EHZNVPK3SFK441A1RGBFSHRT")
```

```py language="python" title="Request" tab="1"
from workos import WorkOSClient

client = WorkOSClient(api_key="sk_example_123456789", client_id="client_123456789")

client.pipes.list_user_data_providers(user_id="user_01EHZNVPK3SFK441A1RGBFSHRT")
```

```go language="go" title="Request" tab="1"
package main

import (
	"context"

	"github.com/workos/workos-go/v10"
)

func main() {
	client := workos.NewClient("sk_example_123456789")

	_, err := client.Pipes().ListUserDataProviders(context.Background(), "user_01EHZNVPK3SFK441A1RGBFSHRT")
	if err != nil {
		panic(err)
	}
}
```

```php language="php" title="Request" tab="1"
<?php

use WorkOS\WorkOS;

$workos = new WorkOS(
    apiKey: "sk_example_123456789",
    clientId: "client_123456789",
);

$workos
    ->pipes()
    ->listUserDataProviders(userId: "user_01EHZNVPK3SFK441A1RGBFSHRT");
```

```java language="java" title="Request" tab="1"
import com.workos.WorkOS;

WorkOS workos = new WorkOS("sk_example_123456789");

workos.pipes.listUserDataProviders("user_01EHZNVPK3SFK441A1RGBFSHRT");
```

```cs language="dotnet" title="Request" tab="1"
using WorkOS;

var client = new WorkOSClient(new WorkOSOptions {
    ApiKey = "sk_example_123456789",
    ClientId = "client_123456789",
});

await client.Pipes.ListUserDataProvidersAsync("user_01EHZNVPK3SFK441A1RGBFSHRT");
```

```rust language="rust" title="Request" tab="1"
use workos::Client;

#[tokio::main]
async fn main() -> Result<(), workos::Error> {
    let client = Client::builder()
        .api_key("sk_example_123456789")
        .client_id("client_123456789")
        .build();

    let _result = client
        .pipes()
        .list_user_data_providers("user_01EHZNVPK3SFK441A1RGBFSHRT")
        .await?;

    Ok(())
}
```

```json language="json" title="Response" tab="2"
{
  "object": "list",
  "data": [
    {
      "object": "data_provider",
      "id": "data_integration_01EHZNVPK3SFK441A1RGBFSHRT",
      "name": "GitHub",
      "description": "Connect your GitHub account to access repositories.",
      "slug": "github",
      "integration_type": "github",
      "credentials_type": "oauth2",
      "scopes": [
        "repo",
        "user:email"
      ],
      "auth_methods": [
        "oauth"
      ],
      "ownership": "userland_user",
      "created_at": "2024-01-15T10:30:00.000Z",
      "updated_at": "2024-01-15T10:30:00.000Z",
      "connected_account": {
        "object": "connected_account",
        "id": "data_installation_01EHZNVPK3SFK441A1RGBFSHRT",
        "user_id": "user_01EHZNVPK3SFK441A1RGBFSHRT",
        "organization_id": null,
        "scopes": [
          "repo",
          "user:email"
        ],
        "auth_method": "oauth",
        "api_key_last_4": null,
        "client_id": "3MVG9dZJodJWxft2VoStSCVwPFsx0eDcpVc",
        "client_secret_last_4": "cdef",
        "config": {
          "instance_url": "https://example.my.salesforce.com"
        },
        "state": "connected",
        "created_at": "2024-01-16T14:20:00.000Z",
        "updated_at": "2024-01-16T14:20:00.000Z"
      }
    }
  ]
}
```

:::

### provider

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `object` | "data_provider" | Yes | Distinguishes the provider object. |
| `id` | string | Yes | The unique identifier of the provider. |
| `name` | string | Yes | The display name of the provider (e.g., "GitHub", "Slack"). |
| `description` | string \| null | Yes | A description of the provider explaining how it will be used, if configured. |
| `slug` | string | Yes | The slug identifier used in API calls (e.g., `github`, `slack`, `notion`). |
| `integration_type` | string | Yes | The type of integration (e.g., `github`, `slack`). |
| `credentials_type` | string | Yes | The type of credentials used by the provider (e.g., `oauth2`). |
| `scopes` | string[] \| null | Yes | The OAuth scopes configured for this provider, or `null` if none are configured. |
| `created_at` | string | Yes | The timestamp when the provider was created. |
| `updated_at` | string | Yes | The timestamp when the provider was last updated. |
| `connected_account` | connected_account \| null | Yes | The user's [connected account](/reference/pipes/connected-account) for this provider, or `null` if the user has not connected. |

### PUT /organizations/{organizationId}/data_integration_configurations/{slug}

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `enabled` | boolean | No | Whether the provider is enabled for the organization. |
| `scopes` | string[] | No | The OAuth scopes to request for the organization. Pass `null` to inherit the provider scopes. |
| `client_id` | string | No | The OAuth client ID of the organization's own application. Must be provided together with `client_secret`, and only for providers whose credentials are supplied by the organization. |
| `client_secret` | string | No | The OAuth client secret of the organization's own application. Must be provided together with `client_id`. |
| `config` | object | No | Provider-specific config values to set for the organization, keyed by config field. Only fields the provider declares are accepted, and each value must match that field's pattern. Accepted only for providers whose credentials are organization-managed; for shared or custom credential providers, config belongs on the integration itself (via the data-integrations API) and supplying it here is rejected. |

#### Parameters

| Parameter | Type | Required | Description |
| --- | --- | --- | --- |
| `organizationId` | string | Yes | An [Organization](/reference/organization) identifier to configure the provider for. |
| `slug` | string | Yes | The slug identifier of the provider to configure (e.g., `github`, `slack`, `notion`). |

#### Returns

| Field | Type | Description |
| --- | --- | --- |
| `data_integration_configuration` | object | Distinguishes the data integration configuration object. |

### GET /organizations/{organizationId}/data_integration_configurations

#### Parameters

| Parameter | Type | Required | Description |
| --- | --- | --- | --- |
| `organizationId` | string | Yes | An [Organization](/reference/organization) identifier to list provider configurations for. |

#### Returns

| Field | Type | Description |
| --- | --- | --- |
| `list` | object | Indicates this is a list response. |

### GET /user_management/users/{user_id}/data_providers

#### Parameters

| Parameter | Type | Required | Description |
| --- | --- | --- | --- |
| `user_id` | string | Yes | A [User](/reference/authkit/user) identifier to list providers and connected accounts for. |
| `organization_id` | string | No | An [Organization](/reference/organization) identifier. Optional parameter to filter connections for a specific organization. |

#### Returns

| Field | Type | Description |
| --- | --- | --- |
| `list` | object | Indicates this is a list response. |