{
  "openapi": "3.0.1",
  "info": {
    "title": "Autocosmos Scraper",
    "description": "Scrape used cars from autocosmos.com.mx. Use the same listing filters as the site or paste a URL — the URL wins when set.",
    "version": "0.4",
    "x-build-id": "CAsHM3VyGE8val3KT"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/dadhalfdev~autocosmos-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-dadhalfdev-autocosmos-scraper",
        "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/dadhalfdev~autocosmos-scraper/runs": {
      "post": {
        "operationId": "runs-sync-dadhalfdev-autocosmos-scraper",
        "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/dadhalfdev~autocosmos-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-dadhalfdev-autocosmos-scraper",
        "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": {
          "input_url": {
            "title": "Input URL",
            "type": "string",
            "description": "Paste an Autocosmos search or listing URL from any supported country. Overrides every filter when set."
          },
          "country": {
            "title": "Country",
            "enum": [
              "mx",
              "ar",
              "cl",
              "pe",
              "co",
              "ec"
            ],
            "type": "string",
            "description": "Which Autocosmos country site to scrape. Ignored when input_url is set.",
            "default": "mx"
          },
          "make": {
            "title": "Make",
            "enum": [
              "",
              "chevrolet",
              "nissan",
              "volkswagen",
              "toyota",
              "ford",
              "honda",
              "hyundai",
              "kia",
              "mazda",
              "jeep",
              "bmw",
              "mercedes",
              "audi",
              "suzuki",
              "mg",
              "seat",
              "renault",
              "dodge",
              "gmc",
              "byd",
              "chery",
              "changan",
              "peugeot",
              "citroen",
              "subaru",
              "volvo",
              "mitsubishi",
              "fiat",
              "jac"
            ],
            "type": "string",
            "description": "Car brand, same list as the Autocosmos make filter.",
            "default": ""
          },
          "location": {
            "title": "Location",
            "enum": [
              "",
              "mx-253",
              "mx-250",
              "mx-238",
              "mx-373",
              "mx-246",
              "mx-236",
              "mx-244",
              "mx-241",
              "mx-230",
              "mx-231",
              "mx-233",
              "mx-258",
              "mx-260",
              "mx-235",
              "mx-256",
              "mx-248",
              "mx-255",
              "mx-251",
              "mx-240",
              "mx-257",
              "mx-252",
              "mx-247",
              "mx-261",
              "mx-242",
              "mx-234",
              "mx-232",
              "mx-259",
              "mx-243",
              "mx-254",
              "mx-249",
              "mx-262",
              "mx-239",
              "ar-301",
              "ar-374",
              "ar-324",
              "ar-305",
              "ar-320",
              "ar-312",
              "ar-323",
              "ar-314",
              "ar-316",
              "ar-306",
              "ar-307",
              "ar-302",
              "ar-303",
              "ar-304",
              "ar-308",
              "ar-309",
              "ar-310",
              "ar-311",
              "ar-313",
              "ar-315",
              "ar-317",
              "ar-318",
              "ar-319",
              "ar-321",
              "ar-322",
              "cl-360",
              "cl-365",
              "cl-368",
              "cl-367",
              "cl-369",
              "cl-370",
              "cl-364",
              "cl-362",
              "cl-363",
              "cl-366",
              "cl-361",
              "cl-401",
              "cl-402",
              "cl-407",
              "cl-371",
              "cl-372",
              "pe-155",
              "pe-157",
              "pe-153",
              "pe-151",
              "pe-152",
              "pe-174",
              "pe-167",
              "pe-154",
              "pe-160",
              "pe-156",
              "pe-163",
              "pe-166",
              "pe-165",
              "pe-169",
              "pe-170",
              "pe-159",
              "co-375",
              "co-377",
              "co-408",
              "co-400",
              "co-387",
              "co-397",
              "co-379",
              "co-380",
              "co-399",
              "co-381",
              "co-382",
              "co-395",
              "co-393",
              "co-389",
              "co-392",
              "co-384",
              "co-391",
              "co-386",
              "co-405",
              "co-404",
              "co-390",
              "co-383",
              "co-398",
              "co-401",
              "co-394",
              "ec-217",
              "ec-208",
              "ec-200",
              "ec-212",
              "ec-209",
              "ec-218",
              "ec-210",
              "ec-205",
              "ec-202",
              "ec-223",
              "ec-221"
            ],
            "type": "string",
            "description": "State or region on that country's Autocosmos site. Pick a location in the same country.",
            "default": ""
          },
          "price_min": {
            "title": "Minimum price",
            "minimum": 0,
            "type": "integer",
            "description": "Lowest price in that country's currency."
          },
          "price_max": {
            "title": "Maximum price",
            "minimum": 0,
            "type": "integer",
            "description": "Highest price in that country's currency."
          },
          "year_min": {
            "title": "Minimum year",
            "minimum": 1980,
            "maximum": 2035,
            "type": "integer",
            "description": "Oldest model year."
          },
          "year_max": {
            "title": "Maximum year",
            "minimum": 1980,
            "maximum": 2035,
            "type": "integer",
            "description": "Newest model year."
          },
          "max_results": {
            "title": "Maximum results",
            "minimum": 1,
            "maximum": 2000,
            "type": "integer",
            "description": "Maximum rows to return (1–2000).",
            "default": 50
          }
        }
      },
      "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
                  }
                }
              },
              "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}