# How to Create OAuth Credentials for eBay

This guide will help you set up your eBay OAuth app to connect with Apideck. eBay is the world's online marketplace where you can buy and sell electronics, cars, clothes, collectibles, and more.

To create a connection with eBay, you need to complete the following steps:

1. [Enable the eBay connector in Apideck](#1-enable-the-ebay-connector-in-apideck)
2. [Create OAuth App in eBay Developer Portal](#2-create-oauth-app-in-ebay-developer-portal)
3. [Configure OAuth RuName (Redirect URL Name)](#3-configure-oauth-runame-redirect-url-name)
4. [Configure connector in Apideck](#4-configure-connector-in-apideck)
5. [Test the connection](#5-test-the-connection)

## Prerequisites

Before you begin, make sure you have the following:

1. An eBay Developer account - Sign up at [eBay Developer Program](https://developer.ebay.com/)
2. An Apideck account
3. Access to create and manage OAuth applications in the eBay Developer Portal

## 1. Enable the eBay connector in Apideck

First, enable the eBay connector in your Apideck dashboard:

- Go to your [Apideck dashboard](https://platform.apideck.com/)
- Navigate to **Configuration > Ecommerce > eBay**
- The connector will be available for configuration


## 2. Create OAuth App in eBay Developer Portal

### Login to eBay Developer Portal

- Go to the [eBay Developer Portal](https://developer.ebay.com/)
- Sign in with your eBay Developer account credentials

### Navigate to Application Keys

- After logging in, navigate to **My Account** in the top navigation
- Click on **Application Keysets** from the dropdown menu

![eBay My Account Menu](https://res.cloudinary.com/apideck/image/upload/v1765979138/docs/connectors/ebay/ebay-application-keysets.png)

### Create a Keyset

- Click on **Create a keyset** button
- Select your environment:
  - **Sandbox** - For testing and development
  - **Production** - For live applications

![eBay Create Keyset](https://res.cloudinary.com/apideck/image/upload/v1765978789/docs/connectors/ebay/ebay-api-application-key.png)

**💡 TIP**: Start with the Sandbox environment to test your integration before moving to Production.

### Configure Application Details

Fill out the application information:

- **Application Title**: Enter a descriptive name for your application (e.g., "Apideck Integration")
- **Application Type**: Select OAuth as the type
- Click **Create** to generate your keyset

### Copy OAuth Credentials

After creating your keyset, you'll see the following credentials:

- **App ID** (Client ID) - This is your OAuth Client ID
- **Cert ID** (Client Secret) - This is your OAuth Client Secret

![eBay OAuth Credentials](https://res.cloudinary.com/apideck/image/upload/v1765978790/docs/connectors/ebay/ebay-api-credentials.png)

## 3. Configure OAuth RuName (Redirect URL Name)

eBay uses a unique OAuth configuration called "RuName" (Redirect URL Name) instead of a traditional redirect URI. This is a required step for eBay OAuth setup.

### Navigate to User Tokens

- In the **Application Keys** section, locate your newly created application
- Click on **User Tokens** link next to your App ID

![eBay User Tokens Link](https://res.cloudinary.com/apideck/image/upload/v1765979425/docs/connectors/ebay/ebay-user-token.png)

### Add eBay Redirect URL

- Under the **"Get a Token from eBay via Your Application"** section, click on **"+ Add eBay Redirect URL"**

![eBay Get Token Section](https://res.cloudinary.com/apideck/image/upload/v1765979680/docs/connectors/ebay/ebay-redirect-url.png)


### Configure Redirect URL Settings

Fill out the redirect URL configuration:

- **Display Title**: Enter a descriptive name for your redirect URL (e.g., "Apideck Vault Callback")
- **Your auth accepted URL**: Enter the Apideck Vault callback URL:
  ```
  https://unify.apideck.com/vault/callback
  ```
- **Your auth declined URL**: Enter a URL for declined authentications (optional, can be the same as accepted URL)
- **OAuth Enabled**: Check this box to enable OAuth for this redirect URL

![eBay Get Token Section](https://res.cloudinary.com/apideck/image/upload/v1765980106/docs/connectors/ebay/ebay-auth-accepted-url.png)


### Save and Get RuName

- Click **Save** to store your redirect URL configuration
- After saving, eBay will generate a **RuName** (Redirect URL Name) for this configuration
- Copy the **RuName** - it will look something like: `Acme-Corp-RuName-v1` or `YourApp-RuName-12345`

![eBay RuName Display](https://res.cloudinary.com/apideck/image/upload/v1765980683/docs/connectors/ebay/ebay-runame.png)

**⚠️ Important**: The RuName is not a URL - it's an identifier that eBay uses to reference your redirect URL configuration. You'll need this RuName value in the next step.

## 4. Configure connector in Apideck

Now that you've successfully created your eBay OAuth app and configured the RuName, you can add the credentials in the Apideck connector configuration.

### Add OAuth Credentials

- Go to your Apideck dashboard at [https://platform.apideck.com/](https://platform.apideck.com/)
- Navigate to **Configuration > Ecommerce > eBay**
- Enter the following credentials:
  - **Client ID**: Paste the **App ID** you copied from eBay
  - **Client Secret**: Paste the **Cert ID** you copied from eBay

![eBay Apideck Credentials](https://res.cloudinary.com/apideck/image/upload/v1765981249/docs/connectors/ebay/apideck-dashboard.png)

### Configure Integration Settings

- Enter your **OAuth RuName (Redirect URL Name)**: Paste the RuName you copied from eBay (e.g., `Acme-Corp-RuName-v1`)
- Under **Environment Configuration**, select the environment:
  - **Production** - For live eBay data
  - **Sandbox** - For testing with test data
  - Click **Save settings** to save your configuration


![eBay Apideck RuName Configuration](https://res.cloudinary.com/apideck/image/upload/v1765980903/docs/connectors/ebay/apideck-dashboard2.png)

**💡 TIP**: The RuName field expects the identifier name (like `Acme-Corp-RuName-v1`), not the full redirect URL.


## 5. Test the connection

You can test your eBay connector by clicking **Test Vault** in the Apideck dashboard.
- Click **Authorize** to start the OAuth flow
- You'll be redirected to eBay's authorization page

![eBay Test Vault](https://res.cloudinary.com/apideck/image/upload/v1765978790/docs/connectors/ebay/vault-unauthorized.png)

- Once it is authorized successfully, select the eBay Site from the dropdown
- Click  **Save** and your connection should now show as **Connected**

![eBay Connection Status](https://res.cloudinary.com/apideck/image/upload/v1765978790/docs/connectors/ebay/vault-authorized.png)

## Do your first API call to the eBay API

Test with this call:

```bash
curl --location 'https://unify.apideck.com/ecommerce/orders' \
  --header 'x-apideck-consumer-id: test-consumer' \
  --header 'x-apideck-app-id: {APIDECK_APP_ID}' \
  --header 'x-apideck-service-id: ebay' \
  --header 'Authorization: Bearer {APIDECK_API_KEY}'
```

Your eBay OAuth credentials are now configured and ready to use! 🎉
