{
  "openapi": "3.0.1",
  "info": {
    "title": "SECOP II Scraper: Colombia Tenders, Licitaciones & Contracts",
    "description": "Colombia's public procurement from SECOP II: tenders (licitaciones, selección abreviada, mínima cuantía, concurso de méritos, subasta) with entity, base price, bids deadline and link, and signed contracts with supplier, NIT and value. Official open data. Export to JSON, CSV or Excel, or via API.",
    "version": "1.0",
    "x-build-id": "ZajUz76HoFr45c0X5"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/steadyscrape~secop-colombia-tenders-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-steadyscrape-secop-colombia-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/steadyscrape~secop-colombia-tenders-scraper/runs": {
      "post": {
        "operationId": "runs-sync-steadyscrape-secop-colombia-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/steadyscrape~secop-colombia-tenders-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-steadyscrape-secop-colombia-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": {
          "datasets": {
            "title": "What to get",
            "minItems": 1,
            "type": "array",
            "description": "Procurement processes (tenders a supplier can bid on: entity, modality, base price, bids deadline, status, link) and/or signed contracts (supplier, value, dates). Each process is one \"process\" event, each contract one \"contract\" event.",
            "items": {
              "type": "string",
              "enum": [
                "processes",
                "contracts"
              ],
              "enumTitles": [
                "Procurement processes (procesos de contratación)",
                "Signed contracts (contratos electrónicos)"
              ]
            },
            "default": [
              "processes"
            ]
          },
          "withinDays": {
            "title": "Published in the last N days",
            "minimum": 1,
            "maximum": 3650,
            "type": "integer",
            "description": "Processes first published, or contracts signed, from this many days ago up to today (Colombia's date). SECOP II's open data runs 2–3 days behind the portal, so the last days come in later. Ignored when the dates below are set.",
            "default": 7
          },
          "dateFrom": {
            "title": "From (optional)",
            "type": "string",
            "description": "The first day, YYYY-MM-DD (publication for processes, signature for contracts). Replaces the days above."
          },
          "dateTo": {
            "title": "To (optional)",
            "type": "string",
            "description": "The last day, YYYY-MM-DD, included. Without it, today."
          },
          "modalities": {
            "title": "Modalities (modalidades de contratación)",
            "type": "array",
            "description": "The selection modalities to read. By default the ones a supplier can bid on. Direct awards and the special regime are mostly service orders naming one person. Leave empty for every modality.",
            "items": {
              "type": "string",
              "enum": [
                "public-tender",
                "abbreviated-selection",
                "reverse-auction",
                "merit-contest",
                "minimum-amount",
                "direct-with-offers",
                "special-regime-with-offers",
                "direct",
                "special-regime",
                "asset-sale",
                "information-request",
                "other"
              ],
              "enumTitles": [
                "Licitación pública (public tender)",
                "Selección abreviada de menor cuantía (abbreviated selection)",
                "Selección abreviada subasta inversa (reverse auction)",
                "Concurso de méritos (merit-based contest)",
                "Mínima cuantía (minimum amount)",
                "Contratación directa con ofertas (direct award asking for offers)",
                "Régimen especial con ofertas (special regime asking for offers)",
                "Contratación directa (direct award)",
                "Contratación régimen especial (special regime)",
                "Enajenación de bienes (sale of state assets)",
                "Solicitud de información (request for information)",
                "Any other modality"
              ]
            },
            "default": [
              "public-tender",
              "abbreviated-selection",
              "reverse-auction",
              "merit-contest",
              "minimum-amount",
              "direct-with-offers",
              "special-regime-with-offers"
            ]
          },
          "keywords": {
            "title": "Keywords",
            "type": "array",
            "description": "Any one of these words or phrases in the title or description (a contract's object). Accents and case do not matter: \"construccion\" finds \"CONSTRUCCIÓN\". Write them in Spanish, as entities do: \"obra\", \"software\", \"vigilancia\", \"alimentación escolar\". At most 25.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "departments": {
            "title": "Departments",
            "type": "array",
            "description": "The buying entity's department. Leave empty for the whole country. About 2 % of processes name no department and are left out by this filter.",
            "items": {
              "type": "string",
              "enum": [
                "amazonas",
                "antioquia",
                "arauca",
                "atlantico",
                "bogota",
                "bolivar",
                "boyaca",
                "caldas",
                "caqueta",
                "casanare",
                "cauca",
                "cesar",
                "choco",
                "cordoba",
                "cundinamarca",
                "guainia",
                "guaviare",
                "huila",
                "la-guajira",
                "magdalena",
                "meta",
                "narino",
                "norte-de-santander",
                "putumayo",
                "quindio",
                "risaralda",
                "san-andres",
                "santander",
                "sucre",
                "tolima",
                "valle-del-cauca",
                "vaupes",
                "vichada"
              ],
              "enumTitles": [
                "Amazonas",
                "Antioquia",
                "Arauca",
                "Atlántico",
                "Distrito Capital de Bogotá",
                "Bolívar",
                "Boyacá",
                "Caldas",
                "Caquetá",
                "Casanare",
                "Cauca",
                "Cesar",
                "Chocó",
                "Córdoba",
                "Cundinamarca",
                "Guainía",
                "Guaviare",
                "Huila",
                "La Guajira",
                "Magdalena",
                "Meta",
                "Nariño",
                "Norte de Santander",
                "Putumayo",
                "Quindío",
                "Risaralda",
                "San Andrés, Providencia y Santa Catalina",
                "Santander",
                "Sucre",
                "Tolima",
                "Valle del Cauca",
                "Vaupés",
                "Vichada"
              ]
            },
            "default": []
          },
          "entityName": {
            "title": "Entity name contains",
            "type": "string",
            "description": "Part of the buying entity's name, e.g. \"INVIAS\", \"ALCALDIA MUNICIPAL DE MEDELLIN\", \"ICBF\". Accents and case do not matter."
          },
          "entityNit": {
            "title": "Entity NIT",
            "type": "string",
            "description": "The buying entity's NIT, digits only or as written (\"899.999.239-2\" or \"899999239\")."
          },
          "contractTypes": {
            "title": "Contract types",
            "type": "array",
            "description": "Works, supplies, services, consulting… Leave empty for every type.",
            "items": {
              "type": "string",
              "enum": [
                "services",
                "supplies",
                "purchase",
                "works",
                "supervision",
                "consulting",
                "insurance",
                "property-lease",
                "equipment-lease",
                "concession",
                "public-private-partnership",
                "financial-services",
                "trust",
                "public-credit",
                "loan-for-use",
                "non-profit-agreement",
                "sale",
                "other"
              ],
              "enumTitles": [
                "Prestación de servicios (services)",
                "Suministros (supplies)",
                "Compraventa (purchase of goods)",
                "Obra (public works)",
                "Interventoría (works supervision)",
                "Consultoría (consulting)",
                "Seguros (insurance)",
                "Arrendamiento de inmuebles (property lease)",
                "Arrendamiento de muebles (equipment lease)",
                "Concesión (concession)",
                "Asociación público privada (PPP)",
                "Servicios financieros (financial services)",
                "Negocio fiduciario (trust)",
                "Operaciones de crédito público (public credit)",
                "Comodato (loan for use)",
                "Decreto 092 de 2017 (agreements with non-profits)",
                "Venta de muebles o inmuebles (sale of assets)",
                "Any other type (Otro, No especificado…)"
              ]
            },
            "default": []
          },
          "minValue": {
            "title": "Minimum value (COP)",
            "minimum": 0,
            "type": "integer",
            "description": "A process's base price (precio base) or a contract's value, in Colombian pesos. 0 for no minimum.",
            "default": 0
          },
          "maxValue": {
            "title": "Maximum value (COP)",
            "minimum": 0,
            "type": "integer",
            "description": "Likewise, the most. 0 for no maximum.",
            "default": 0
          },
          "onlyOpenForBids": {
            "title": "Only processes still open for bids",
            "type": "boolean",
            "description": "Processes whose bids deadline (fecha de recepción de respuestas) is still ahead and that are not cancelled. Contracts are not affected.",
            "default": false
          },
          "supplierNit": {
            "title": "Supplier NIT",
            "type": "string",
            "description": "A supplier's NIT: the contracts signed with it, and the processes awarded to it. Digits only or as written."
          },
          "unspscCodes": {
            "title": "UNSPSC codes (contracts only)",
            "type": "array",
            "description": "Contracts whose main UNSPSC code starts with one of these: segment (2 digits, \"72\" building and construction), family (4), class (6) or commodity (8). The processes dataset leaves the code unspecified, so with codes set processes are not read.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "maxResults": {
            "title": "Max results per dataset",
            "minimum": 0,
            "type": "integer",
            "description": "The most processes, and the most contracts, one run delivers, newest first. 0 for no limit.",
            "default": 100
          },
          "includeRawRecord": {
            "title": "Include the raw record",
            "type": "boolean",
            "description": "Adds every column the dataset publishes as `raw` (60 for a process, 95 for a contract), without people's ID numbers and bank accounts. Off keeps CSV and Excel exports to the normalized columns.",
            "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}