{
  "openapi": "3.0.1",
  "info": {
    "title": "Goofish (Xianyu 闲鱼) Scraper & Monitor - Search, Items, Prices",
    "description": "Search Goofish (Xianyu 闲鱼) by keyword or read item IDs or URLs: price, condition, wants, views, favorites, photos, full description, location and seller ratings. Monitor mode returns only new listings, price drops and sold items since the last run. No login, API key or start fee.",
    "version": "0.1",
    "x-build-id": "mzsjqnfgNC4yawgeT"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/neverempty~goofish-xianyu-listings-monitor/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-neverempty-goofish-xianyu-listings-monitor",
        "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/neverempty~goofish-xianyu-listings-monitor/runs": {
      "post": {
        "operationId": "runs-sync-neverempty-goofish-xianyu-listings-monitor",
        "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/neverempty~goofish-xianyu-listings-monitor/run-sync": {
      "post": {
        "operationId": "run-sync-neverempty-goofish-xianyu-listings-monitor",
        "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": {
          "keywords": {
            "title": "Search keywords",
            "type": "array",
            "description": "Words to search on Goofish (Xianyu 闲鱼), one per line (up to 100 per run), in Chinese or English, like 徕卡M6 or iPhone 15. Every listing found comes back as one row with price, condition, wants, location and seller. If both lists are empty, an example keyword is searched.",
            "items": {
              "type": "string"
            }
          },
          "itemIds": {
            "title": "Item IDs or URLs",
            "type": "array",
            "description": "Goofish item IDs or item links, one per line (up to 2,000 per run), like 1042804563826 or https://www.goofish.com/item?id=1042804563826. Each one comes back with all photos, the full description, views, wants, favorites, shipping and the seller's ratings.",
            "items": {
              "type": "string"
            }
          },
          "maxItemsPerKeyword": {
            "title": "Max listings per keyword",
            "minimum": 1,
            "maximum": 1500,
            "type": "integer",
            "description": "How many listings to return for each keyword, in the chosen order (1 to 1,500; Goofish shows up to 50 pages of 30). Empty means 100."
          },
          "sort": {
            "title": "Order",
            "enum": [
              "relevance",
              "newest",
              "priceAsc",
              "priceDesc",
              "priceDrop"
            ],
            "type": "string",
            "description": "The order Goofish shows the search results in. Empty means best match."
          },
          "minPrice": {
            "title": "Minimum price (CNY)",
            "minimum": 0,
            "maximum": 10000000,
            "type": "integer",
            "description": "Only listings at or above this price in yuan. Empty means no minimum."
          },
          "maxPrice": {
            "title": "Maximum price (CNY)",
            "minimum": 0,
            "maximum": 10000000,
            "type": "integer",
            "description": "Only listings at or below this price in yuan. Empty means no maximum."
          },
          "personalSellersOnly": {
            "title": "Personal sellers only",
            "type": "boolean",
            "description": "Only listings from individual sellers (Goofish's own personal-seller filter), leaving out shops and dealers.",
            "default": false
          },
          "publishedWithinHours": {
            "title": "Listed within the last hours",
            "minimum": 1,
            "maximum": 8760,
            "type": "integer",
            "description": "Only listings published in the last N hours, like 24. Works best with the order Newest first, where reading stops as soon as older listings start. Empty means any time."
          },
          "includeDetails": {
            "title": "Add full item details to keyword results",
            "type": "boolean",
            "description": "Also opens every listing found by a keyword and adds all photos, the full description, views, favorites, brand, model, shipping and the seller's ratings, reply rate and items sold. These rows are charged as item rows instead of listing rows. In monitor mode only the changed listings are opened.",
            "default": false
          },
          "onlyChanges": {
            "title": "Monitor mode: return only new listings and changes",
            "type": "boolean",
            "description": "Remembers every listing seen. The first run records the starting point (free, no listing rows). Later runs with the same input return only listings published since the watch started, price drops and status changes such as sold or removed, each with the previous price. Listings with no change are not returned and not charged.",
            "default": false
          },
          "includePriceIncreases": {
            "title": "Monitor mode: also return price increases",
            "type": "boolean",
            "description": "Monitor mode only: also return listings whose price went up. Off means price increases are remembered quietly and not returned.",
            "default": false
          },
          "watchName": {
            "title": "Watch name (optional)",
            "type": "string",
            "description": "Keeps a separate memory per name, so two schedules with different lists do not mix. Letters, digits, dot, dash and underscore, up to 40 characters. Empty means the watch called default."
          },
          "resetMonitoringState": {
            "title": "Forget what this watch remembers",
            "type": "boolean",
            "description": "Monitor mode only: forget the remembered listings of this watch name first, so this run records a new starting point.",
            "default": false
          },
          "concurrency": {
            "title": "Pages read at the same time",
            "minimum": 1,
            "maximum": 8,
            "type": "integer",
            "description": "How many Goofish pages are read at the same time (1 to 8). Empty means 4."
          },
          "requestTimeoutSecs": {
            "title": "Seconds to wait for one page",
            "minimum": 5,
            "maximum": 60,
            "type": "integer",
            "description": "How long to wait for one page before asking again (5 to 60). Empty means 30."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}