Skip to content
Discussion options

You must be logged in to vote

Resolved

I found this doc of eBay developers program, followed it and successfully listed an item via eBay's REST API.

eBayListItem.ts:

import eBayApi from "ebay-api";
import dotenv from "dotenv";
dotenv.config();

// Initialize eBay API client with credentials
const ebay = new eBayApi({
  appId: process.env.EBAY_APP_ID,
  certId: process.env.EBAY_CERT_ID,
  sandbox: false, // Set to true for testing in eBay's sandbox environment
  marketplaceId: eBayApi.MarketplaceId.EBAY_US,
});

// Set OAuth token for authentication
const token = process.env.EBAY_TOKEN_PROD;
ebay.OAuth2.setCredentials(token);

// Define inventory item details
const sku = "test-01";
const merchantLocationKey = process.env.

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by NorkzYT
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant