{
  "openapi": "3.0.1",
  "info": {
    "title": "FEC Campaign Finance API - Candidates, Donors & PAC Scraper",
    "description": "Search FEC campaign finance data: federal candidates, committees and PACs, and individual contributions by state, employer, occupation or amount, including Schedule A donor lookups. An FEC data scraper over the official API with no FEC key needed.",
    "version": "0.1",
    "x-build-id": "6Ca65IKGl3fyDPJw0"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/captainhandsome~fec-campaign-finance-search/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-captainhandsome-fec-campaign-finance-search",
        "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/captainhandsome~fec-campaign-finance-search/runs": {
      "post": {
        "operationId": "runs-sync-captainhandsome-fec-campaign-finance-search",
        "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/captainhandsome~fec-campaign-finance-search/run-sync": {
      "post": {
        "operationId": "run-sync-captainhandsome-fec-campaign-finance-search",
        "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": {
          "data_type": {
            "title": "What to search",
            "enum": [
              "candidates",
              "committees",
              "contributions"
            ],
            "type": "string",
            "description": "Candidates, committees and PACs, or individual contributions.",
            "default": "candidates"
          },
          "name": {
            "title": "Name",
            "type": "string",
            "description": "Candidate, committee or contributor name depending on what you are searching."
          },
          "state": {
            "title": "State",
            "type": "string",
            "description": "Two-letter state code. For contributions this is the CONTRIBUTOR's state."
          },
          "party": {
            "title": "Party",
            "type": "string",
            "description": "Three-letter party code, e.g. DEM, REP, LIB. Candidates only."
          },
          "office": {
            "title": "Office",
            "enum": [
              "H",
              "S",
              "P"
            ],
            "type": "string",
            "description": "Office sought. Candidates only."
          },
          "election_year": {
            "title": "Election year",
            "type": "integer",
            "description": "Candidates only."
          },
          "committee_type": {
            "title": "Committee type",
            "type": "string",
            "description": "FEC committee type code, e.g. N for PAC. Committees only."
          },
          "committee_id": {
            "title": "Committee ID",
            "type": "string",
            "description": "Limit contributions to one recipient committee, e.g. C00887760."
          },
          "employer": {
            "title": "Contributor employer",
            "type": "string",
            "description": "Contributions only."
          },
          "occupation": {
            "title": "Contributor occupation",
            "type": "string",
            "description": "Contributions only."
          },
          "min_amount": {
            "title": "Minimum amount (USD)",
            "type": "integer",
            "description": "Contributions only."
          },
          "two_year_period": {
            "title": "Two-year period",
            "type": "integer",
            "description": "FEC election cycle for contributions, e.g. 2024 covers 2023-2024.",
            "default": 2024
          },
          "include_details": {
            "title": "Include financial totals and contact details",
            "type": "boolean",
            "description": "Adds money and contact columns from the FEC's detail endpoints. Candidates gain receipts, disbursements, cash on hand, debts and the Form 2 mailing address at a cost of one extra request per 100 rows. Committees gain the same financial summary plus street address, email, website, fax and treasurer contact, at a cost of two extra requests per row - a 100-row committee run therefore makes about 200 extra calls and takes noticeably longer. No effect on contributions, whose recipient committee is already included in every row.",
            "default": false
          },
          "max_items": {
            "title": "Max items",
            "minimum": 1,
            "maximum": 20000,
            "type": "integer",
            "description": "Hard cap on rows returned. Also caps your spend.",
            "default": 100
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}