{
  "openapi": "3.0.1",
  "info": {
    "title": "COMPRASAL Scraper: El Salvador Public Tenders",
    "description": "Scrape Central America public tenders, starting with El Salvador's official COMPRASAL portal (licitaciones and adjudicaciones). Type El Salvador and get deadlines, ending-soon flags, award amounts, supplier stats, a TENDER_REPORT, and monitor mode. Export JSON, CSV or Excel.",
    "version": "0.1",
    "x-build-id": "iJf4ERfsfEGBunjqs"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/kareninatech~central-america-tenders-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-kareninatech-central-america-tenders-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/kareninatech~central-america-tenders-scraper/runs": {
      "post": {
        "operationId": "runs-sync-kareninatech-central-america-tenders-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/kareninatech~central-america-tenders-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-kareninatech-central-america-tenders-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": {
          "country": {
            "title": "Country",
            "type": "string",
            "description": "Type El Salvador (or SV). Type Central America or all for every supported country — in this version that is still El Salvador only. Do not leave this empty if you want a wider search: an omitted value is filled with the default, El Salvador, because the input schema default is merged when the field is left out. Panama, Honduras, Guatemala, Costa Rica and Nicaragua are not available yet.",
            "default": "El Salvador"
          },
          "status": {
            "title": "Status",
            "enum": [
              "open",
              "awarded",
              "all"
            ],
            "type": "string",
            "description": "Open tenders currently receiving bids, already awarded processes, or both.",
            "default": "open"
          },
          "keyword": {
            "title": "Keyword",
            "type": "string",
            "description": "Optional words to match in the title, institution, category or code. Separate several terms with a comma. With expand_keywords on, a word such as software also finds sistemas, tecnología and informático."
          },
          "expand_keywords": {
            "title": "Expand Spanish keywords",
            "type": "boolean",
            "description": "When a keyword is set, also match common Spanish synonyms (for example software → sistemas, tecnología, informático).",
            "default": true
          },
          "institution": {
            "title": "Institution",
            "type": "string",
            "description": "Optional. Keep tenders whose buying institution name or code contains this text, for example Ministerio de Salud or 2307."
          },
          "category": {
            "title": "Category",
            "type": "string",
            "description": "Optional. Keep tenders whose activity / category name or code contains this text, for example software, construcción or 96092."
          },
          "procedure_type": {
            "title": "Procedure type",
            "type": "string",
            "description": "Optional. Keep one contracting method, for example Licitación competitiva, Comparación de precios, Subasta Inversa or CD."
          },
          "min_amount": {
            "title": "Min amount",
            "minimum": 0,
            "type": "number",
            "description": "Minimum awarded or listed amount. Open COMPRASAL tenders usually have no amount until they are awarded, so this filter mainly applies to awards."
          },
          "max_amount": {
            "title": "Max amount",
            "minimum": 0,
            "type": "number",
            "description": "Maximum awarded or listed amount. Same note as min amount: open tenders often have no figure."
          },
          "published_from": {
            "title": "Published from (YYYY-MM-DD)",
            "type": "string",
            "description": "Keep open tenders published on or after this date, for example 2026-01-15."
          },
          "published_to": {
            "title": "Published to (YYYY-MM-DD)",
            "type": "string",
            "description": "Keep open tenders published on or before this date, for example 2026-11-30."
          },
          "deadline_from": {
            "title": "Deadline from (YYYY-MM-DD)",
            "type": "string",
            "description": "Keep open tenders whose bid deadline is on or after this date, for example 2026-11-21."
          },
          "deadline_to": {
            "title": "Deadline to (YYYY-MM-DD)",
            "type": "string",
            "description": "Keep open tenders whose bid deadline is on or before this date, for example 2026-12-31."
          },
          "awarded_from": {
            "title": "Awarded from (YYYY-MM-DD)",
            "type": "string",
            "description": "Keep awards decided on or after this date, for example 2026-01-01."
          },
          "awarded_to": {
            "title": "Awarded to (YYYY-MM-DD)",
            "type": "string",
            "description": "Keep awards decided on or before this date, for example 2026-11-30."
          },
          "max_items": {
            "title": "Max results",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "Maximum number of dataset rows to save (default 40). Use a higher number to collect every open tender (there are typically a few hundred) or several hundred awards.",
            "default": 40
          },
          "max_pages": {
            "title": "Max award pages",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "Safety cap on award list pages. Each page has up to 100 awards. Leave empty to use the default (200)."
          },
          "ending_soon_days": {
            "title": "Ending-soon window (days)",
            "minimum": 1,
            "maximum": 90,
            "type": "integer",
            "description": "Flag open tenders whose bid deadline falls within this many days (default 3).",
            "default": 3
          },
          "fetch_details": {
            "title": "Fetch official process details",
            "type": "boolean",
            "description": "Call the official detail endpoint for each process to fill the internal code and the exact publication timestamp. Off by default because the public lists already include the deadline, institution and award data. Open tenders still have no budget on the detail page.",
            "default": false
          },
          "monitor_mode": {
            "title": "Monitor mode",
            "type": "boolean",
            "description": "Remember this search and, on later runs, only emit tenders that are new, whose deadline, status, amendment version, winner or awarded amount changed, or (if emit_removed is on) that disappeared. Ideal for a daily alert schedule.",
            "default": false
          },
          "monitor_key": {
            "title": "Monitor key",
            "type": "string",
            "description": "Optional name for the memory used by monitor mode, for example sv-open-software. Use a different key for each search you want to track separately."
          },
          "emit_removed": {
            "title": "Emit removed tenders",
            "type": "boolean",
            "description": "In monitor mode, also emit a row when a previously seen tender is no longer in this search.",
            "default": false
          },
          "proxyConfiguration": {
            "title": "Proxy",
            "type": "object",
            "description": "Optional. Not needed for COMPRASAL: the official public JSON API is open and does not require a browser or a proxy."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}