{
  "openapi": "3.0.1",
  "info": {
    "title": "eBay Sold Listings API",
    "description": "Extract recent sold eBay listings with prices, shipping costs, sale dates, conditions, sellers, and URLs. Search eight marketplaces with date, condition, and price filters, then export structured data or access it through the Apify API.",
    "version": "0.2",
    "x-build-id": "qtyWewklOh4bIAIy8"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/epicscrapers~ebay-sold-listings-api/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-epicscrapers-ebay-sold-listings-api",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/acts/epicscrapers~ebay-sold-listings-api/runs": {
      "post": {
        "operationId": "runs-sync-epicscrapers-ebay-sold-listings-api",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor and returns information about the initiated run in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/runsResponseSchema"
                }
              }
            }
          }
        }
      }
    },
    "/acts/epicscrapers~ebay-sold-listings-api/run-sync": {
      "post": {
        "operationId": "run-sync-epicscrapers-ebay-sold-listings-api",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "inputSchema": {
        "type": "object",
        "properties": {
          "startUrls": {
            "title": "eBay search URLs",
            "type": "array",
            "description": "Paste eBay search URLs from any of the 17 supported eBay sites (ebay.com, ebay.co.uk, ebay.de and others). The URL sets the marketplace and keeps all its filters. Live-listing URLs work too: the actor always switches to sold listings, newest sales first.",
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "keywords": {
            "title": "Search keywords",
            "type": "array",
            "description": "Products to look up, one search per entry, e.g. iphone 13 128gb. Use the words a buyer would type. eBay matches keywords loosely, so a URL with eBay's Model filter is more precise.",
            "items": {
              "type": "string"
            }
          },
          "site": {
            "title": "eBay marketplace",
            "enum": [
              "ebay.com",
              "ebay.co.uk",
              "ebay.de",
              "ebay.fr",
              "ebay.it",
              "ebay.es",
              "ebay.ca",
              "ebay.com.au",
              "ebay.nl",
              "ebay.at",
              "ebay.ch",
              "ebay.ie",
              "ebay.pl",
              "ebay.com.hk",
              "ebay.com.my",
              "ebay.ph",
              "ebay.com.sg"
            ],
            "type": "string",
            "description": "eBay site for keyword searches. URLs use their own site. Prices come in the site's currency.",
            "default": "ebay.com"
          },
          "maxItems": {
            "title": "Max results per search",
            "minimum": 1,
            "type": "integer",
            "description": "Maximum sold listings saved for each URL or keyword. You pay only for saved listings.",
            "default": 100
          },
          "days": {
            "title": "Sold in the last N days",
            "minimum": 1,
            "type": "integer",
            "description": "Only sales from the last N days (whole days, UTC). eBay keeps about 90 days of sold listings.",
            "default": 30
          },
          "onlyNewSales": {
            "title": "Only new sales",
            "type": "boolean",
            "description": "Skip sales an earlier run of the same search already saved, so a scheduled run returns and charges only new sales. Saved sales are remembered in the key-value store \"ebay-sold-listings-history\" on your account, for 100 days.",
            "default": false
          },
          "excludeKeywords": {
            "title": "Exclude keywords",
            "type": "array",
            "description": "Words or phrases to leave out, e.g. psa, graded, box only. Single words are also sent to eBay as minus terms (-psa).",
            "items": {
              "type": "string"
            }
          },
          "sellerType": {
            "title": "Seller type",
            "enum": [
              "all",
              "private",
              "business"
            ],
            "type": "string",
            "description": "Private or business sellers. eBay supports this on its European sites; elsewhere the result can be empty. A seller type in a URL wins over this setting.",
            "default": "all"
          },
          "skipOtherModels": {
            "title": "Skip other models",
            "type": "boolean",
            "description": "Leave out sales of a different model than your keyword: for \"iphone 14 128gb\" it skips iPhone 12 and iPhone 14 Pro / Plus / Max. It checks each word followed by a number in your keyword. Turn it off to keep everything eBay returns.",
            "default": true
          },
          "condition": {
            "title": "Condition",
            "enum": [
              "all",
              "new",
              "used",
              "refurbished",
              "for_parts"
            ],
            "type": "string",
            "description": "Item condition, as eBay groups it.",
            "default": "all"
          },
          "listingType": {
            "title": "Listing type",
            "enum": [
              "all",
              "auction",
              "buy_it_now"
            ],
            "type": "string",
            "description": "Auction or Buy It Now sales. Buy It Now includes accepted Best Offers (marked with bestOfferAccepted).",
            "default": "all"
          },
          "categoryId": {
            "title": "Category ID",
            "pattern": "^\\s*\\d*\\s*$",
            "type": "string",
            "description": "eBay category ID to search in, e.g. 183454 for single trading cards on ebay.com: the number after _sacat= in an eBay URL. Find IDs in the <a href=\"https://epicscrapers.com/tools/ebay-category-ids/\" target=\"_blank\">eBay category ID lookup</a>."
          },
          "minPrice": {
            "title": "Minimum price",
            "minimum": 0,
            "type": "number",
            "description": "Minimum sold price in the marketplace currency."
          },
          "maxPrice": {
            "title": "Maximum price",
            "minimum": 0,
            "type": "number",
            "description": "Maximum sold price in the marketplace currency."
          },
          "includeSummary": {
            "title": "Add price statistics",
            "type": "boolean",
            "description": "Save the min, max, mean, median and quartile sold price for each search to the PRICE_STATS record in the key-value store. Accepted Best Offers are left out. Not charged.",
            "default": false
          }
        }
      },
      "runsResponseSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "actId": {
                "type": "string"
              },
              "userId": {
                "type": "string"
              },
              "startedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "finishedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "status": {
                "type": "string",
                "example": "READY"
              },
              "meta": {
                "type": "object",
                "properties": {
                  "origin": {
                    "type": "string",
                    "example": "API"
                  },
                  "userAgent": {
                    "type": "string"
                  }
                }
              },
              "stats": {
                "type": "object",
                "properties": {
                  "inputBodyLen": {
                    "type": "integer",
                    "example": 2000
                  },
                  "rebootCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "restartCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "resurrectCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "computeUnits": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "options": {
                "type": "object",
                "properties": {
                  "build": {
                    "type": "string",
                    "example": "latest"
                  },
                  "timeoutSecs": {
                    "type": "integer",
                    "example": 300
                  },
                  "memoryMbytes": {
                    "type": "integer",
                    "example": 1024
                  },
                  "diskMbytes": {
                    "type": "integer",
                    "example": 2048
                  }
                }
              },
              "buildId": {
                "type": "string"
              },
              "defaultKeyValueStoreId": {
                "type": "string"
              },
              "defaultDatasetId": {
                "type": "string"
              },
              "defaultRequestQueueId": {
                "type": "string"
              },
              "buildNumber": {
                "type": "string",
                "example": "1.0.0"
              },
              "containerUrl": {
                "type": "string"
              },
              "usage": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "integer",
                    "example": 1
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "usageTotalUsd": {
                "type": "number",
                "example": 0.00005
              },
              "usageUsd": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "number",
                    "example": 0.00005
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}