> ## Documentation Index
> Fetch the complete documentation index at: https://nango.dev/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# CDW - How do I link my account?

# Overview

To authenticate with CDW, you need a **Subscription Key**. CDW's [API Management developer portal](https://portal.apiconnect.cdw.com/) is self-serve — anyone can create an account, subscribe to a product, and generate a key.

### Prerequisites

* You must sign up for a CDW API Management developer portal account (open to anyone) and subscribe to the product(s) you need.

### Instructions

#### Step 1: Creating a developer portal account

1. Go to the [CDW API Management developer portal](https://portal.apiconnect.cdw.com/) and sign up for an account.
2. Once approved, sign in.

#### Step 2: Subscribing to a product and generating a subscription key

1. Go to **Products** and open the product you need (for example, **Customers**, which includes the Customer Order API).
2. Click **Subscribe** and give the subscription a name.
3. Go to your **Profile**. Under **Subscriptions**, find the subscription you just created, click the **...** menu, and select **Show keys**.
4. Copy the **Primary key** (or **Secondary key** — either works as the subscription key).

<img src="https://mintcdn.com/nango/kDQRsM2otfX2N713/api-integrations/cdw/products.png?fit=max&auto=format&n=kDQRsM2otfX2N713&q=85&s=98e4275473beaa6c43cf7f53080dabcd" width="1280" height="900" data-path="api-integrations/cdw/products.png" />

<img src="https://mintcdn.com/nango/kDQRsM2otfX2N713/api-integrations/cdw/subscribe.png?fit=max&auto=format&n=kDQRsM2otfX2N713&q=85&s=e8ffee04eb4866c5cdd159160ceec65e" width="1280" height="900" data-path="api-integrations/cdw/subscribe.png" />

<img src="https://mintcdn.com/nango/kDQRsM2otfX2N713/api-integrations/cdw/show-keys.png?fit=max&auto=format&n=kDQRsM2otfX2N713&q=85&s=c64a5ad4e5fb59707f767d4ee9bd4af4" width="1280" height="900" data-path="api-integrations/cdw/show-keys.png" />

<Note>
  CDW automatically rotates subscription keys every 30 days. If your Nango connection starts failing with an authentication error, sign back in to the developer portal, retrieve the new key from your profile, and update the connection.
</Note>

#### Step 3: Choosing your Base URL

Choose the Base URL that matches where you created your product subscription:

* `apiconnect.cdw.com/b2b` is CDW's production gateway. Use it for live subscriptions and real orders.
* `apiconnect.preprod.cdw.com/pprd/b2b` is CDW's PreProd sandbox. It has separate products, subscriptions, and keys, so only use it if you subscribed through PreProd.

#### Step 4: Enter credentials in the Connect UI

Once you have your **Subscription Key**:

1. Open the form where you need to authenticate with CDW.
2. Enter your **Subscription Key** in the field provided.
3. Select the **Environment** that matches the Base URL described above.
4. Submit the form, and you should be successfully authenticated.

<img src="https://mintcdn.com/nango/kDQRsM2otfX2N713/api-integrations/cdw/connect-form.png?fit=max&auto=format&n=kDQRsM2otfX2N713&q=85&s=6d3caebb7446fb2a0c12d1e56c05a1a2" style={{maxWidth: "450px" }} width="498" height="637" data-path="api-integrations/cdw/connect-form.png" />

You are now connected to CDW.
