{
  "openapi": "3.0.1",
  "info": {
    "title": "USAspending Mid-Size Federal Awards Data",
    "description": "New mid-size US federal contract actions from the public USAspending API. Obligated amounts, set-aside, and sole-proprietor flag. No DUNS, UEI, or street addresses. No API key.",
    "version": "0.1",
    "x-build-id": "XCk159lVv6r5J0STA"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/zecro-apps~federal-contract-awards/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-zecro-apps-federal-contract-awards",
        "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/zecro-apps~federal-contract-awards/runs": {
      "post": {
        "operationId": "runs-sync-zecro-apps-federal-contract-awards",
        "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/zecro-apps~federal-contract-awards/run-sync": {
      "post": {
        "operationId": "run-sync-zecro-apps-federal-contract-awards",
        "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": {
          "startDate": {
            "title": "Start action date",
            "type": "string",
            "description": "First action date to include, YYYY-MM-DD. Leave blank to start lookbackDays before End date (or before the default end date)."
          },
          "endDate": {
            "title": "End action date",
            "type": "string",
            "description": "Last action date to include, YYYY-MM-DD. Leave blank to use the previous weekday in America/Los_Angeles (or today if the run starts at/after 6 PM PT)."
          },
          "lookbackDays": {
            "title": "Lookback days",
            "minimum": 1,
            "maximum": 31,
            "type": "integer",
            "description": "If Start date is blank, cover this many calendar days ending on End date. Ignored when Start date is set. Cap is 31. The default of 21 covers weekends, U.S. holidays, and the roughly one-week lag on civilian USAspending publications. DoD and Army Corps actions lag about 90 days.",
            "default": 21
          },
          "maxResults": {
            "title": "Max results",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "Maximum number of output rows after filters, largest obligated amount first. Defaults to 10 so a first run stays small and cheap. You can raise this up to 1,000 on any plan.",
            "default": 10
          },
          "minObligatedAmount": {
            "title": "Minimum obligated amount (USD)",
            "minimum": 0,
            "type": "number",
            "description": "Keep a row only if the obligated amount on that first action is at least this amount. This is not total or potential contract value.",
            "default": 100000
          },
          "maxObligatedAmount": {
            "title": "Maximum obligated amount (USD)",
            "minimum": 0,
            "type": "number",
            "description": "Keep a row only if the obligated amount on that first action is at most this amount.",
            "default": 10000000
          },
          "newAwardsOnly": {
            "title": "New awards and orders only (Mod 0)",
            "type": "boolean",
            "description": "When on, only modification number 0 is kept (a new award or order, not a later modification).",
            "default": true
          },
          "awardTypeCodes": {
            "title": "Award type codes",
            "type": "array",
            "description": "USAspending type codes: A definitive contract, B purchase order, C delivery order, D BPA call.",
            "items": {
              "type": "string",
              "enum": [
                "A",
                "B",
                "C",
                "D"
              ]
            },
            "default": [
              "A",
              "B",
              "C",
              "D"
            ]
          },
          "includeSetAside": {
            "title": "Include set-aside and sole-proprietor flag",
            "type": "boolean",
            "description": "When on, one awards-API request is made per output row to fill set_aside and sole_proprietor. This adds about one second per row. Leave on for the default 10-row run.",
            "default": true
          },
          "awardingAgency": {
            "title": "Awarding agency contains",
            "type": "string",
            "description": "Optional case-insensitive substring match on awarding agency or sub-agency. Leave blank for all agencies."
          },
          "naicsPrefix": {
            "title": "NAICS prefix",
            "type": "string",
            "description": "Optional NAICS code prefix, for example 54 or 541512. Leave blank for all industries."
          },
          "recipientState": {
            "title": "Recipient state",
            "type": "string",
            "description": "Optional two-letter recipient state code, for example CA. Street addresses are never included."
          },
          "popState": {
            "title": "Place-of-performance state",
            "type": "string",
            "description": "Optional two-letter place-of-performance state code."
          },
          "userAgent": {
            "title": "User-Agent",
            "type": "string",
            "description": "Declared User-Agent sent to the public USAspending API. The default identifies this Actor.",
            "default": "ZecroLLC zecroapp@gmail.com"
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}