# Pinduoduo Open Platform MCP

> Pinduoduo Open Platform MCP Server connects your AI agent directly to the DDK affiliate ecosystem. You can search millions of Pinduoduo goods using keywords or categories. It generates custom tracking links, pulls real-time order status, and identifies top-selling products to maximize commissions. Use this server anytime you need to manage e-commerce promotions on Pinduoduo.

## Overview
- **Category:** industry-titans
- **Price:** Free
- **Tags:** pinduoduo-api, ddk-affiliate, goods-search, promotion-links, order-tracking, e-commerce-china

## Description

You'll connect your AI agent right into the **Pinduoduo Open Platform**, giving you direct access to everything needed for affiliate marketing on DDK. This server gives your agent ten specific tools, letting it handle product discovery, commission tracking, and link building—all without you having to leave your chat interface.

### Finding What's Hot

You can run a full search across the entire Pinduoduo catalog using `search_goods`, feeding it keywords or filters. Need to browse? You've got tools like `list_categories` that pull all available product groupings, and you can check out `list_themes` to see what marketing themes are active right now.

Once you narrow down a search, your agent doesn't stop there. It pulls specific data using `get_goods_details`, giving you pricing, coupon codes, and deep info on any single product ID. To find the big winners, it runs `query_top_goods` to get a real-time ranking of popular items, or it uses `get_recommendations` to pull suggested products from configured channels.

### Building Your Commission Links

To make money, you gotta track that commission. First, the agent handles the setup by running `generate_pid`, which creates a unique Promotion ID (PID) so you can accurately track sales. After you've got that PID, it builds your specific tracking link using `generate_promotion_url` for any product ID you give it.

### Tracking and Syncing Sales

For the money part, the server lets you keep tabs on orders. You can pull complete details for a specific promotion order by feeding its ID into `get_order_details`. To make sure your records are current, running `sync_increment_orders` fetches all recent orders based on the last update time stamp.

This setup means that whether you're researching new goods with keyword searches or checking yesterday’s commission payouts, your agent handles it. It makes managing promotions on Pinduoduo direct and actionable.

## Tools

### generate_pid
Creates unique Promotion IDs (PIDs) necessary to track commissions.

### generate_promotion_url
Builds a specific tracking link for any given product ID.

### list_categories
Lists all existing product categories on the platform for browsing.

### get_goods_details
Retrieves all detailed information, including pricing and coupons, for one specified product.

### get_order_details
Pulls complete details for a specific promotion order ID you provide.

### get_recommendations
Gets suggested products available through various configured channels.

### list_themes
Retrieves a list of available marketing themes or promotion groupings.

### query_top_goods
Queries and returns the current, real-time ranking of the most popular products.

### search_goods
Runs a full search across Pinduoduo for goods using keywords or specific filters.

### sync_increment_orders
Fetches recent orders by querying the system based on the last update timestamp.

## Prompt Examples

**Prompt:** 
```
Search Pinduoduo for 'smart watches' with a minimum commission rate of 20%.
```

**Response:** 
```
I've searched Pinduoduo for smart watches. Here are the top results with at least 20% commission: 1. GT-Pro Smartwatch (Price: 199 CNY, Commission: 25%), 2. Sport Band X (Price: 89 CNY, Commission: 22%)... Would you like me to generate promotion links for these?
```

**Prompt:** 
```
Generate a promotion link for product 'p_abc123' using PID 'pid_777'.
```

**Response:** 
```
Generating tracking link... Success! Here is your custom promotion URL for 'Wireless Earbuds': [https://p.pinduoduo.com/abc...]. All sales through this link will be attributed to PID 'pid_777'.
```

**Prompt:** 
```
List the top 5 hot products in the 'Electronics' category.
```

**Response:** 
```
Retrieving trending items... I've found the top 5 hot products in Electronics: 1. Tablet Pro Max (ID: t1), 2. Noise Cancelling Headset (ID: t2), 3. Quick Charge Hub (ID: t3)... Would you like the commission details for these?
```

## Capabilities

### Search Product Catalog
Your AI client searches Pinduoduo for products based on keywords, categories, or specific filters.

### Create Tracking Links
It generates various promotion URLs required for affiliate marketing using a specified Promotion ID (PID).

### Pull Product Data
You retrieve granular details, including pricing, coupon codes, and historical sales volume for any given product.

### Synchronize Order Status
The agent retrieves recent orders by pulling data based on the last update time to ensure your records are current.

### Identify Trends and Top Goods
You query real-time rankings and popular product lists to find high-demand items across the platform.

## Use Cases

### Launching a Flash Sale Campaign
A marketer needs 50 product links for an upcoming sale. They instruct their agent to first use `query_top_goods` to identify the best sellers, then loop through those results using `get_goods_details` to confirm pricing, and finally feed all that data into `generate_promotion_url` to create a bulk list of tracking links.

### Auditing Failed Conversions
An operations manager notices sales are dropping. They tell their agent to use `sync_increment_orders` with the last 24 hours as the timeframe, then run `get_order_details` on any suspicious order ID to check if commission data is missing or incorrect.

### Researching a New Niche
A data analyst wants to sell smartwatches. They prompt their agent with 'Show me electronics that sell well.' The agent uses `list_categories` first, then runs `search_goods` with the keyword and filters by minimum commission rate.

### Verifying Product Viability
Before pitching a product to a client, an affiliate marketer uses their agent to call `get_goods_details` for three different items. The AI reads back the coupon status and historical sales volume from each one so they can choose the most profitable option.

## Benefits

- Track orders in real-time. Instead of checking multiple dashboards, use `sync_increment_orders` or `get_order_details` to pull immediate commission status updates directly into your agent's response.
- Build promotion links quickly. You don't need a separate link tool; `generate_promotion_url` takes a product ID and creates the exact tracking URL you need for any campaign.
- Find hot products instantly. Use `query_top_goods` to get real-time rankings, so your agent doesn't waste time searching low-potential items—it jumps straight to what sells right now.
- Deep dive into product data. The `get_goods_details` tool pulls everything—pricing, coupons, history—so you can vet a product’s viability before committing to a link.
- Automate discovery. Instead of manually clicking through categories, let your agent use `search_goods` and `list_categories` simultaneously to map out entire niche opportunities.

## How It Works

The bottom line is: once you provide valid DDK credentials, your AI agent can execute complex e-commerce tasks directly against Pinduoduo's live data streams.

1. Subscribe to this server. Then, log into the Pinduoduo Open Platform site.
2. Register as a DDK Affiliate and obtain your Client ID and Client Secret credentials.
3. Generate an Access Token via the OAuth 2.0 flow, then insert all required keys and tokens below to activate the affiliate backend.

## Frequently Asked Questions

**How do I use generate_promotion_url in the Pinduoduo Open Platform MCP Server?**
You give it a specific product ID and your desired PID. The tool returns the complete, unique tracking link instantly. This is how you ensure all sales are properly attributed.

**Does get_goods_details only show pricing?**
No, `get_goods_details` pulls a full data packet. It provides pricing details, available coupons, and historical sales volume—everything you need to judge profitability right away.

**What if I want to see orders from last week? Should I use sync_increment_orders?**
Yes, `sync_increment_orders` is designed for this. You specify the time window (like 'last 7 days'), and it retrieves all related order data for you.

**Can search_goods filter by commission rate?**
The tool lets you use keywords and categories to narrow down your search, but filtering specifically by commission percentage requires first pulling the detailed product information using `get_goods_details` on the results.

**What credentials do I need to use the `search_goods` tool?**
You must provide a valid Access Token, along with your Client ID and Secret. The server uses these three elements to authenticate the request and authorize access to Pinduoduo’s live product data.

**How do I find all available categories before using `search_goods`?**
Run the `list_categories` tool first. This call provides a structured list of every primary and secondary category ID, letting you narrow down your search parameters for better results.

**When should I use `query_top_goods` versus the `get_recommendations` tool?**
`query_top_goods` gives you a real-time ranking of popular items across the platform. Conversely, `get_recommendations` pulls suggestions specifically tailored to certain designated marketing channels.

**What happens if I try to sync too many orders using `sync_increment_orders`?**
The system handles rate limiting by returning a status code and the next required update timestamp. You should process order synchronization in batches, checking the returned cursor value for subsequent calls.

**Can my AI automatically generate promotion links for multiple products?**
Yes! Use the `generate_promotion_url` tool with the `goods_sign` of the target product. Your agent can iterate through multiple products to create personalized tracking links in seconds.

**What is a 'goods_sign' and how do I get it?**
The `goods_sign` is a unique identifier for a product on the Pinduoduo platform. You can obtain it by running the `search_goods` or `query_top_goods` tools.

**How do I track commissions for my generated links?**
Use the `sync_increment_orders` tool to retrieve orders associated with your PIDs. It will return the order status and the calculated commission for each successful transaction.