### Product Details GET Request Example Source: https://developers.cjdropshipping.com/en/api/api2/api/product.html This example demonstrates how to make a GET request to retrieve product details using a product ID. Ensure you include your CJ-Access-Token in the headers. ```curl curl --location --request GET 'https://developers.cjdropshipping.com/api2.0/v1/product/query?pid=000B9312-456A-4D31-94BD-B083E2A198E8' \ --header 'CJ-Access-Token: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx' ``` -------------------------------- ### Successful Response for Get Settings Source: https://developers.cjdropshipping.com/en/api/api2/api/setting.html This is an example of a successful response when retrieving account settings. It includes details about quota limits, QPS limits, and callback configurations. ```json { "code": 200, "result": true, "message": "Success", "data": { "openId": 1, "openName": "121 2322", "openEmail": "v0pjsw5t@linshiyouxiang.net", "setting": { "quotaLimits": [ { "quotaUrl": "/api2.0/v1/setting/account/get", "quotaLimit": 74, "quotaType": 0 } ], "qpsLimit": 100 }, "callback": { "product": { "type": "ENABLE", "urls": ["https://your-domain.com/api2.0/"] },"order": { "type": "CANCEL", "urls": [] } }, "root": "GENERAL", "isSandbox": false }, "requestId": "ea5896b0-273d-4b49-8c54-ad8f025a49b8" } ``` -------------------------------- ### Shop List Response Example Source: https://developers.cjdropshipping.com/en/api/api2/api/shop.html Example JSON response structure for the Get Shop List endpoint, detailing shop information. ```json { "code": 200, "result": true, "message": "Success", "data": [ { "id": "1424608189734850560", "createDate": "2024-01-01 12:00:00", "name": "MyShop", "status": 1, "type": "shopify", "updateDate": "2024-06-01 12:00:00", "individuationNum": "001", "fulfillmentStatus": "auto", "shopifyPodSettings": "{}", "marketplace": "us", "aliasName": "Alias", "syncInventory": 1, "syncInventoryRate": 100, "isCb": 0, "trackUrlTemplate": "https://example.com/track/{number}", "emailNotification": 1, "email": "user@example.com", "countryCode": "US", "storeCountry": "United States", "platformLogoUrl": "https://example.com/logo.png", "currencyCode": "USD", "businessType": 1, "deliveryProfileOpen": 1, "haveDeliveryProfileScopes": 1, "deliveryProfileSpecifiedShop": 1, "deliveryProfileNewShop": 0 } ], "requestId": "ae543fd1-cdd7-4a61-974a-1340fea678c6" } ``` -------------------------------- ### Query Product Connection List (GET) - CURL Example Source: https://developers.cjdropshipping.com/en/api/api2/api/product.html This CURL command demonstrates how to query product connection records. It includes parameters for filtering by shop, product ID, and pagination. ```curl curl --location --request GET 'https://developers.cjdropshipping.com/api2.0/v1/product/conn/connection?shopId=xxx&platformProductId=yyy&page=1&pageSize=10' \ --header 'CJ-Access-Token: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx' ``` -------------------------------- ### Error Response for Get Settings Source: https://developers.cjdropshipping.com/en/api/api2/api/setting.html This example shows an error response, specifically when a user is not found. The response includes an error code, a message, and a request ID for tracking. ```json { "code": 1601000, "result": false, "message": "User not find", "data": null, "requestId": "a18c9793-7c99-42f9-970b-790eecdceba2" } ``` -------------------------------- ### Get Makeup List Request Example Source: https://developers.cjdropshipping.com/en/api/api2/api/shopping.html Send a POST request with pagination and type parameters to retrieve makeup order information. Ensure the 'type' parameter is set correctly for the desired makeup order category. ```json { "pageNum": 1, "pageSize": 20, "type": 0 } ``` -------------------------------- ### Storage Info Response Example Source: https://developers.cjdropshipping.com/en/api/api2/api/storage.html Example of a successful response when retrieving storage information, detailing warehouse attributes and supported logistics brands. ```json { "code": 200, "result": true, "message": "Success", "data": { "id": "201e67f6ba4644c0a36d63bf4989dd70", "name": "Cranbury Warehouse", "areaId": 2, "areaCountryCode": "US", "address1": "Cranbury, New Jersey ", "address2": null, "contacts": null, "phone": "+1-9095862127", "city": "Cranbury", "province": "New Jersey", "logisticsBrandList": [ { "id": "USPS", "name": "USPS" }, { "id": "FedEx", "name": "FedEx" }, { "id": "UPS", "name": "UPS" }, { "id": "GOFO", "name": "GOFO" }, { "id": "DHL", "name": "DHL" }, { "id": "UniUni", "name": "UniUni" }, { "id": "CBT", "name": "CBT" } ], "isSelfPickup": null, "zipCode": null }, "requestId": "2b97f15603384fe4832e85617cf07d9c", "success": true } ``` -------------------------------- ### Get Settings Source: https://developers.cjdropshipping.com/en/api/api2 Retrieves system settings. ```APIDOC ## GET /api2.0/v1/setting/get ### Description Retrieves system settings. ### Method GET ### Endpoint /api2.0/v1/setting/get ``` -------------------------------- ### Batch Refresh Selected Inventory Response Example Source: https://developers.cjdropshipping.com/en/api/api2/api/shopping.html Example response for batch refreshing inventory, showing updated quantities for specified products. ```json { "code": 200, "result": true, "message": "Success", "data": [ { "privateOrderId": "PO26050001", "stanProductId": "CJVAR001", "uid": "PO26050001-CJVAR001", "availableQuantity": 118 } ] } ``` -------------------------------- ### Get Shop List (GET) Source: https://developers.cjdropshipping.com/en/api/api2/api/shop.html Retrieves a list of shops associated with the current account. Requires authentication via CJ-Access-Token. ```bash curl --location --request GET 'https://developers.cjdropshipping.com/api2.0/v1/shop/getShops' \ --header 'CJ-Access-Token: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx' ``` -------------------------------- ### Get All Products Source: https://developers.cjdropshipping.com/en/api/api2 Retrieves a list of all products. ```APIDOC ## GET /api2.0/v1/product/list ### Description Retrieves a list of all products. ### Method GET ### Endpoint /api2.0/v1/product/list ``` -------------------------------- ### Auto Merge Order Progress Response Example Source: https://developers.cjdropshipping.com/en/api/api2/api/shopping.html Example of a successful response when querying the progress of an auto-merge order task. Indicates task status and progress. ```json { "code": 200, "data": { "noTask": false, "step": 2, "stepCount": [10, 20, 30, 10, 30], "stepPercent": 5000 }, "message": "success", "success": true } ``` -------------------------------- ### Download Product Video Source: https://developers.cjdropshipping.com/en/api/api2/api/product.html Example of how to download a product video. Ensure you include the 'Referer' header with the specified value to avoid request rejection. ```bash curl -H "Referer: https://developers.cjdropshipping.com" -O "https://download-only-api.cjdropshipping.com/xxxxxx/video.mp4" ``` -------------------------------- ### Get Dispute Detail API Request (GET) Source: https://developers.cjdropshipping.com/en/api/api2/api/dispute.html Example of how to retrieve the details of a specific dispute using the GET method. Requires a dispute ID and an access token. ```curl curl --location --request GET 'https://developers.cjdropshipping.com/api2.0/v1/disputes/getDisputeDetail?disputeId=12345' \ --header 'CJ-Access-Token: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx' ``` -------------------------------- ### Get Access Token Error Response Source: https://developers.cjdropshipping.com/en/api/api2/api/auth.html Example of an error response when the user is not found during token retrieval. ```json { "code": 1601000, "result": false, "message": "User not find", "data": null, "requestId": "a18c9793-7c99-42f9-970b-790eecdceba2", "success": false } ``` -------------------------------- ### Get Access Token Success Response Source: https://developers.cjdropshipping.com/en/api/api2/api/auth.html Example of a successful response when obtaining access and refresh tokens. ```json { "code": 200, "result": true, "message": "Success", "data": { "openId": 123456789, "accessToken": "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx", "accessTokenExpiryDate": "2021-08-18T09:16:33+08:00", "refreshToken": "f7edabe65c3b4a198b50ca8f969e36eb", "refreshTokenExpiryDate": "2022-02-07T09:16:33+08:00", "createDate": "2021-08-11T09:16:33+08:00" }, "requestId": "8b3d9ea1-00c3-4d10-9e2b-d18041d98080", "success": true } ``` -------------------------------- ### Clone and Build CJ MCP Server Source: https://developers.cjdropshipping.com/en/api/api2/mcp.html Clone the CJ MCP Server repository, install dependencies, and build the project. This prepares the server for local integration. ```bash git clone https://github.com/CJ-dropshipping/api-mcp.git cd api-mcp npm install npm run build ``` -------------------------------- ### Error Response for Get Tracking Information Source: https://developers.cjdropshipping.com/en/api/api2/api/logistic.html This is an example of an error response for the trackInfo endpoint, typically indicating a parameter error. ```json { "code": 1600100, "result": false, "message": "Param error", "data": null, "requestId": "323fda9d-3c94-41dc-a944-5cc1b8baf5b1" } ``` -------------------------------- ### Create Product Connection (POST) Source: https://developers.cjdropshipping.com/en/api/api2/api/product.html Use this CURL command to bind a CJ product to a platform product. Ensure you include the CJ-Access-Token and specify variant details. ```curl curl --location --request POST 'https://developers.cjdropshipping.com/api2.0/v1/product/conn/connection' \ --header 'CJ-Access-Token: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx' \ --header 'Content-Type: application/json' \ --data-raw '{ "shopId": "xxx", "defaultArea": 1, "logistics": "PacketPlus", "cjProductId": "1424608189734850560", "platformProductId": "yyy", "sourceCountryCode": "CN", "sourceCountry": "China", "targetCountryCode": "US", "targetCountry": "United States", "variantList": [ { "cjVariantId": "1424608152007086080", "platformVariantId": "v_001" } ] }' ``` -------------------------------- ### Get Balance Success Response Source: https://developers.cjdropshipping.com/en/api/api2/api/shopping.html Example of a successful response when retrieving account balance. It includes the total amount, no withdrawal amount, and freeze amount. ```json { "code": 200, "result": true, "message": "Success", "data": { "amount": 87247.32, "noWithdrawalAmount": null, "freezeAmount": null }, "requestId": "36fc030a-a110-4318-bc83-f39f9d3e5484" } ``` -------------------------------- ### Query Product Inventory using CURL Source: https://developers.cjdropshipping.com/en/api/api2/api/product.html This example demonstrates how to query product inventory by Variant ID using a CURL command. Ensure you include your CJ-Access-Token for authentication. ```bash curl --location --request GET 'https://developers.cjdropshipping.com/api2.0/v1/product/stock/queryByVid?vid=7874B45D-E971-4DC8-8F59-40530B0F6B77' \ --header 'CJ-Access-Token: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx' ``` -------------------------------- ### Success Response for Get Tracking Information Source: https://developers.cjdropshipping.com/en/api/api2/api/logistic.html Example of a successful response when fetching tracking information. It provides details such as tracking status, delivery time, and carrier information. ```json { "code": 200, "result": true, "message": "Success", "data": [ { "trackingNumber": "CJPKL7160102171YQ", "logisticName": "CJPacket Sensitive", "trackingFrom": "CN", "trackingTo": "US", "deliveryDay": "13", "deliveryTime": "2021-06-17 07:04:04", "trackingStatus": "In transit", "lastMileCarrier": "CJPacket", "lastTrackNumber": "926112903032124" } ], "requestId": "3426e927-8c50-4687-9ced-623e77d55bd0", "success": true } ``` -------------------------------- ### Success Response for Get Supplier Logistics Template Source: https://developers.cjdropshipping.com/en/api/api2/api/logistic.html This is an example of a successful response when retrieving supplier logistics templates. It includes details about the logistics information for the provided SKUs. ```json { "code": 200, "result": true, "message": "Success", "data": [ { "skuList": [], "logisticsInfoList": [ { "id": "123", "logisticsName": "fdd", "postage": "", "startCountryCode": "", "destCountryCode": "" } ] } ], "requestId": "0242ad78-eea2-481d-876a-7cf64398f07f", "success": true } ``` -------------------------------- ### Example Natural Language Prompts for MCP Server Source: https://developers.cjdropshipping.com/en/api/api2/mcp.html Illustrative prompts that can be used with the integrated CJ MCP Server to perform various actions like searching products, querying orders, and calculating shipping costs. ```text Search for "wireless earbuds" products Show my recent orders Get details for order DP2605200604000336000 Calculate shipping cost to the US for this product ``` -------------------------------- ### Get Product List Source: https://developers.cjdropshipping.com/en/api/api2/api/product.html Use this CURL command to retrieve a list of products. Ensure you include your CJ-Access-Token. ```bash curl --location --request GET 'https://developers.cjdropshipping.com/api2.0/v1/product/list' \ --header 'CJ-Access-Token: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx' ``` -------------------------------- ### Get Makeup List Response Example Source: https://developers.cjdropshipping.com/en/api/api2/api/shopping.html The API returns a JSON object containing the status of the request, total amount, counts of unpaid orders by type, and paginated order data. Each order includes details like order codes, amounts, and creation timestamps. ```json { "code": 200, "result": true, "message": "Success", "data": { "type": 0, "totalAmount": 12.35, "unPaymentCountList": [ { "type": 0, "count": 2 }, { "type": 1, "count": 0 } ], "pageData": { "pageSize": 20, "pageNumber": 1, "totalRecords": 2, "totalPages": 1, "content": [ { "orderCode": "BT2606061320024499900", "cjOrderCode": "SD2606060858539645300", "status": 0, "amount": 12.35, "reason": "Postage difference", "orderType": 1, "diffUseType": 0, "createAt": 1779763200000 } ] } }, "requestId": "2b97f15603384fe4832e85617cf07d9c" } ``` -------------------------------- ### Get Confirmation with Cost Details Source: https://developers.cjdropshipping.com/en/api/api2/api/shopping.html This API returns confirmation data, warehouse options, and cost details in one response. Call it without `storageId` to get warehouse options; pass the selected `storageId` to get cost details; pass the selected `logisticName` to get the final amount. ```APIDOC ## POST /api2.0/v1/shopping/privateInventory/getConfirmationWithCost ### Description Returns confirmation data, warehouse options, and cost details in one response. Call it without `storageId` to get warehouse options; pass the selected `storageId` to get cost details; pass the selected `logisticName` to get the final amount. ### Method POST ### Endpoint https://developers.cjdropshipping.com/api2.0/v1/shopping/privateInventory/getConfirmationWithCost ### Parameters #### Request Body - **storageId** (string) - Optional - The ID of the storage location. Omit to get warehouse options. - **variantInfoList** (list) - Required - A list of product variants and their quantities. - **variantInfoList[].id** (string) - Required - The ID of the product variant. - **variantInfoList[].quantity** (integer) - Required - The quantity of the product variant. - **logisticName** (string) - Optional - The selected logistics name, used to get the final amount. ``` -------------------------------- ### Address List Response Example Source: https://developers.cjdropshipping.com/en/api/api2/api/shopping.html Example response structure for the address list endpoint, containing address details. ```json { "code": 200, "result": true, "message": "Success", "data": [ { "id": "ADDR001", "name": "Gilbert Soria", "countryCode": "US", "province": "OH", "city": "HUBER HEIGHTS", "address": "3419 BROADMOOR BLVD1", "addressNew": "Apt 123", "zip": "222260", "phone": "9322331159", "mail": "test@example.com" } ] } ``` -------------------------------- ### Add Product Success Response Source: https://developers.cjdropshipping.com/en/api/api2/api/product.html Example of a successful response when a product is added to 'My Products'. ```JSON { "code": 200, "result": true, "message": "Success", "data": true, "requestId": "a7d4d01b1eed4db9ac2cc1ab7903c98c", "success": true } ``` -------------------------------- ### Error Response Example Source: https://developers.cjdropshipping.com/en/api/api2/api/shopping.html This is an example of an error response, detailing the error code, message, and request ID for troubleshooting. ```json { "code": 804, "result": false, "message": "This order does not use store platform logistics. Label upload not supported.", "data": null, "requestId": "715937dad5844ec49d51be43541eeb00", "success": false } ``` -------------------------------- ### Successful Product Video Query Response Source: https://developers.cjdropshipping.com/en/api/api2/api/product.html Example of a successful response when querying product videos. Includes video details such as URL, size, duration, and counts for plays, likes, etc. ```json { "success": true, "code": 0, "message": "success", "data": [ { "id": "abc39e6946dc4aa6b53f1813b53cfcb1", "locProductId": "1964955178105954305", "videoName": "123", "videoState": "ON_STATE", "videoUrl": "https://download-only-api.cjdropshipping.com/abc39e6946dc4aa6b53f1813b53cfcb1/xxxx.mp4", "videoNumber": null, "notCopyrightPrice": "", "copyrightPrice": "", "copyright": "1", "isFree": "1", "videoId": "abc39e6946dc4aa6b53f1813b53cfcb1", "videoSize": "4689615", "coverURL": "https://download-only-api.cjdropshipping.com/abc39e6946dc4aa6b53f1813b53cfcb1/snapshots/xxx.jpg", "duration": 39.521, "unit": "MB", "flag": "0", "isBuy": true, "payType": null, "playCount": 6543, "collectCount": 26, "downloadCount": 46, "showCount": 734, "shareNum": 12, "likeNum": 19, "commentCount": 0, "buyCount": 0, "videoType": 1, "copyrightBuyType": 4, "orderNum": 0, "videoByOut": null, "width": 960, "height": 540, "openIn": null } ], "requestId": "6106699663484b45829410eb75b5a4b3" } ``` -------------------------------- ### API Error Response Example Source: https://developers.cjdropshipping.com/en/api/api2/api/webhook.html Example of an API error response, showing an error code and a descriptive message. ```json { "code": 1607001, "result": false, "message": "Please do not use domain names such as localhost, 127.0.0.1", "data": null, "requestId": "a18c9793-7c99-42f9-970b-790eecdceba2", "success": false } ``` -------------------------------- ### My Product List Success Response Source: https://developers.cjdropshipping.com/en/api/api2/api/product.html Example of a successful response when retrieving the product list. It includes pagination details and a content array with product information. ```JSON { "code": 200, "result": true, "message": "Success", "data": { "pageSize": 10, "pageNumber": 1, "totalRecords": 536, "totalPages": 54, "content": [ { "productId": "01118E21-A8B9-45CE-A16C-75232FB8A14A", "packWeight": "530.0", "weight": "480.0", "productType": "0", "propertyKeyList": [ "COMMON" ], "bigImage": "https://cf.cjdropshipping.com/15926688/9714688036284.jpg", "nameEn": "3D wooden three-dimensional puzzle", "sku": "CJWJWJJM00719", "hasPacked": 0, "sellPrice": "2.4", "discountPrice": null, "discountPriceRate": null, "defaultArea": "China Warehouse", "shopMethod": "CAI NIAO", "trialFreight": "0", "totalPrice": "2.40", "listedShopNum": "0", "vid": "7986724D-7214-4B4B-A184-493E7BD78F47", "areaId": "1", "areaCountryCode": "CN", "freightDiscount": "0", "createAt": 1743218214000, "lengthList": [ 335, 335 ], "heightList": [ 200, 200 ], "widthList": [ 225, 225 ], "volumeList": [ 15075000, 15075000 ], "hasVirPacked": 1 } ] }, "requestId": "b0f251412bd0446cb56ba5988706d964", "success": true } ``` -------------------------------- ### Create Product Connection Source: https://developers.cjdropshipping.com/en/api/api2/api/product.html Binds a CJ product (with variants) to a platform product (with corresponding variants). ```APIDOC ## POST /api2.0/v1/product/conn/connection ### Description Binds one CJ product (with one or more variants) to a platform product (with the corresponding variants). ### Method POST ### Endpoint https://developers.cjdropshipping.com/api2.0/v1/product/conn/connection ### Parameters #### Request Body - **shopId** (string) - Optional - Shop Id - **defaultArea** (int) - Required - Default area - **logistics** (string) - Required - Logistics method - **cjProductId** (string) - Required - CJ Product Id - **platformProductId** (string) - Required - Platform Product Id - **sourceCountryCode** (string) - Optional - Source country code - **sourceCountry** (string) - Optional - Source country - **targetCountryCode** (string) - Optional - Target country code - **targetCountry** (string) - Optional - Target country - **variantList** (list) - Required - Variant list (At least one variant) - **cjVariantId** (string) - Required - CJ Variant Id - **platformVariantId** (string) - Required - Platform Variant Id ### Request Example ```json { "shopId": "xxx", "defaultArea": 1, "logistics": "PacketPlus", "cjProductId": "1424608189734850560", "platformProductId": "yyy", "sourceCountryCode": "CN", "sourceCountry": "China", "targetCountryCode": "US", "targetCountry": "United States", "variantList": [ { "cjVariantId": "1424608152007086080", "platformVariantId": "v_001" } ] } ``` ### Response #### Success Response (200) - **code** (int) - **result** (boolean) - **message** (string) - **data** (boolean) - **requestId** (string) #### Response Example ```json { "code": 200, "result": true, "message": "Success", "data": true, "requestId": "ae543fd1-cdd7-4a61-974a-1340fea678c6" } ``` ``` -------------------------------- ### API Request Structure Example Source: https://developers.cjdropshipping.com/en/api/start/development.html This is a general template for API requests, outlining the method, address, package body, parameter descriptions, permission details, and return results. All requests must use HTTPS, JSON, and UTF8 encoding. ```text Request method: POST (HTTPS) Request address: ... Request package body. ... Parameter description. ... Permission Description. ... Return results. ... Description of parameters. ... ``` -------------------------------- ### Test Commands for CJ MCP Setup Source: https://developers.cjdropshipping.com/en/api/api2/mcp.html Use these commands in your AI client to verify that your CJ MCP integration is configured correctly. The AI should respond with results from the MCP tools. ```text Check my CJ login status Search for "phone case" products on CJ Show me my recent orders ``` -------------------------------- ### Get Tracking Information (GET) Source: https://developers.cjdropshipping.com/en/api/api2/api/logistic.html Retrieve shipping and tracking details using one or more tracking numbers. This endpoint is useful for monitoring the status of shipments. ```cURL curl --location --request GET 'https://developers.cjdropshipping.com/api2.0/v1/logistic/trackInfo?trackNumber=CJPKL7160102171YQ &trackNumber=CJPKL7160102171YQ &trackNumber=CJPKL7160102171YQ &trackNumber=CJPKL7160102171YQ ' ``` -------------------------------- ### Auto Merge Order List Response Example Source: https://developers.cjdropshipping.com/en/api/api2/api/shopping.html Example of a successful response when listing auto-mergeable orders. Includes order details and logistics information. ```json { "code": 200, "data": [ { "haveMoreShopOrder": true, "mergeShopOrderVOList": [ { "city": "Shanghai", "country": "China", "countryCode": "CN", "customerName": "John", "logisticsInfoList": [ { "logisticsName": "PostNL", "postage": 18.00, "arrivalTime": "2023-11-20", "isChecked": true } ] } ] } ], "message": "success", "success": true } ``` -------------------------------- ### Save Product (POST) Source: https://developers.cjdropshipping.com/en/api/api2/api/shop.html Saves a store product to the CJ system. Requires authentication and specifies product details in JSON format. ```bash curl --location 'https://developers.cjdropshipping.com/api2.0/v1/store/product/saveProduct' \ --header 'CJ-Access-Token: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx' \ --header 'Content-Type: application/json' \ --data '{ "id": "prod123", "title": "Example Product", "image": "https://example.com/image.jpg", "description": "Product description", "priceMin": 10.00, "priceMax": 20.00, "priceCurrency": "USD" }' ```