{
  "openapi": "3.0.1",
  "info": {
    "title": "Prime-Win Subcontract Radar: Federal Award Alerts by NAICS",
    "description": "Watch the NAICS codes, states and agency you name and get freshly-awarded federal prime contracts as deduped alert rows, each with the prime's business size and a size-gated FAR 19.702 subcontracting-plan indicator, from USAspending's keyless public feed on your schedule.",
    "version": "0.0",
    "x-build-id": "pTSfQzMABdaxCHD2G"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/yungstentech~prime-win-subcontract-radar/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-yungstentech-prime-win-subcontract-radar",
        "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/yungstentech~prime-win-subcontract-radar/runs": {
      "post": {
        "operationId": "runs-sync-yungstentech-prime-win-subcontract-radar",
        "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/yungstentech~prime-win-subcontract-radar/run-sync": {
      "post": {
        "operationId": "run-sync-yungstentech-prime-win-subcontract-radar",
        "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": {
          "naicsCodes": {
            "title": "NAICS codes to watch",
            "type": "array",
            "description": "NAICS codes to watch, one per line (for example 236220 for commercial and institutional building construction). 2 to 6 digits each; a shorter code matches its whole sector. Up to 25. At least one of NAICS codes, Place of performance, or Awarding agency is required.",
            "items": {
              "type": "string"
            }
          },
          "placeOfPerformance": {
            "title": "Place of performance (states)",
            "type": "array",
            "description": "Two-letter state codes for where the work is performed, one per line (for example TX, IN, IL). Up to 15. At least one of NAICS codes, Place of performance, or Awarding agency is required.",
            "items": {
              "type": "string"
            }
          },
          "awardingAgency": {
            "title": "Awarding agency (optional)",
            "type": "string",
            "description": "Optional toptier awarding-agency name to restrict the watch (for example \"General Services Administration\"). At least one of NAICS codes, Place of performance, or Awarding agency is required."
          },
          "minAwardAmount": {
            "title": "Minimum award amount (USD)",
            "minimum": 0,
            "type": "integer",
            "description": "Only awards whose current obligation is at least this many US dollars are returned. Default 750000 keeps awards teaming-relevant while still surfacing just-below-threshold awards; the FAR 19.702 flag is evaluated independently at $900,000 (general) or $2,000,000 (construction).",
            "default": 750000
          },
          "awardTypeCodes": {
            "title": "Award type codes",
            "type": "array",
            "description": "USAspending contract award-type codes. Defaults to the definitive contracts A, B, C, D. You may add IDV codes (IDV_A, IDV_B, IDV_C, IDV_D, IDV_E and the IDV_B_* variants).",
            "default": [
              "A",
              "B",
              "C",
              "D"
            ],
            "items": {
              "type": "string"
            }
          },
          "lookbackDays": {
            "title": "Lookback window (days)",
            "minimum": 1,
            "maximum": 30,
            "type": "integer",
            "description": "How many days back from today (America/New_York) to query on the award date. The default of 7 covers the multi-day FPDS publish lag plus weekends on a daily schedule. Overlap between runs is free because already delivered awards are deduplicated per filter. The maximum of 30 is a catch-up ceiling.",
            "default": 7
          },
          "maxAlertsPerRun": {
            "title": "Max alerts per run",
            "minimum": 1,
            "maximum": 500,
            "type": "integer",
            "description": "Hard cap on the number of alerts delivered and charged in a single run. Overflow is not marked as seen and is redelivered on the next run, so a broad first-run catch-up cannot hit you with a surprise bill. Default 50.",
            "default": 50
          },
          "webhookUrl": {
            "title": "Webhook URL (optional)",
            "type": "string",
            "description": "Optional https URL that receives a POST with the new alerts after each run. Best-effort alerting only: the dataset is the durable record. If you need to verify the caller, put a secret token in the URL yourself."
          },
          "filterName": {
            "title": "Filter name",
            "type": "string",
            "description": "Names this filter within your account so its deduplication memory persists across scheduled runs. Lowercased and restricted to letters, digits and hyphens (1 to 40 characters). Use different names for different filters; each named filter is billed separately.",
            "default": "default"
          },
          "dryRun": {
            "title": "Dry run (preview, no PPE charge)",
            "type": "boolean",
            "description": "When true, fetch and match but return at most 5 preview rows tagged dry-run. It charges no PPE event and saves no filter or billing values, but this filter's named watch and billing key-value stores are still opened and read (and may be created empty), the preview rows are still written to your dataset and OUTPUT, and ordinary Apify platform compute, storage and egress usage still applies. Use it to sanity check your filter before scheduling.",
            "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
                  }
                }
              },
              "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}