{
  "openapi": "3.0.1",
  "info": {
    "title": "Snapshot DAO Governance Scraper",
    "description": "Scrape Snapshot.org DAO governance data - proposals (by space, state, or ID), spaces (DAO profiles), and votes (by proposal or voter address). Public GraphQL API, no login required.",
    "version": "1.0",
    "x-build-id": "AY9NN7cOCFIP1LsYa"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/crawlerbros~snapshot-dao-governance-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-crawlerbros-snapshot-dao-governance-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/crawlerbros~snapshot-dao-governance-scraper/runs": {
      "post": {
        "operationId": "runs-sync-crawlerbros-snapshot-dao-governance-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/crawlerbros~snapshot-dao-governance-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-crawlerbros-snapshot-dao-governance-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",
        "required": [
          "mode"
        ],
        "properties": {
          "mode": {
            "title": "Mode",
            "enum": [
              "proposals",
              "proposalByIds",
              "spaces",
              "spaceByIds",
              "votes",
              "votesByVoter"
            ],
            "type": "string",
            "description": "What to fetch.",
            "default": "proposals"
          },
          "space": {
            "title": "Space / DAO (ENS name)",
            "type": "string",
            "description": "Filter proposals to a single space, e.g. `ens.eth`, `aavedao.eth`, `uniswapgovernance.eth`. Also narrows mode=votesByVoter."
          },
          "state": {
            "title": "Proposal state (mode=proposals)",
            "enum": [
              "",
              "pending",
              "active",
              "closed"
            ],
            "type": "string",
            "description": "Filter by voting state.",
            "default": ""
          },
          "titleContains": {
            "title": "Title contains (mode=proposals)",
            "type": "string",
            "description": "Case-insensitive substring match on the proposal title."
          },
          "network": {
            "title": "Network / chain ID",
            "type": "string",
            "description": "Filter by blockchain network ID, e.g. `1` (Ethereum), `137` (Polygon), `42161` (Arbitrum), `8453` (Base), `10` (Optimism), `56` (BNB Chain), `100` (Gnosis)."
          },
          "authorAddress": {
            "title": "Author address (mode=proposals)",
            "type": "string",
            "description": "Only return proposals created by this 0x wallet address. Confirmed honored server-side by Snapshot's own API."
          },
          "proposalType": {
            "title": "Proposal voting type (mode=proposals)",
            "enum": [
              "",
              "single-choice",
              "approval",
              "quadratic",
              "ranked-choice",
              "weighted",
              "basic"
            ],
            "type": "string",
            "description": "Filter by the proposal's voting system. Confirmed honored server-side by Snapshot's own API.",
            "default": ""
          },
          "minVotes": {
            "title": "Min vote count (mode=proposals)",
            "minimum": 0,
            "maximum": 10000000,
            "type": "integer",
            "description": "Only include proposals with at least this many votes cast."
          },
          "proposalOrderBy": {
            "title": "Order proposals by",
            "enum": [
              "created",
              "votes",
              "scores_total_value",
              "start",
              "end"
            ],
            "type": "string",
            "description": "Sort field for proposal results (mode=proposals). Note: `scores_total_value` is not reliably honored by Snapshot's own API (confirmed via direct testing -- it silently falls back to created-date order); `created`, `votes`, `start`, and `end` all sort correctly.",
            "default": "created"
          },
          "proposalIds": {
            "title": "Proposal IDs (mode=proposalByIds)",
            "type": "array",
            "description": "Snapshot proposal IDs (0x-prefixed hashes).",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "searchText": {
            "title": "Search text (mode=spaces)",
            "type": "string",
            "description": "Full-text search against space name/ENS domain."
          },
          "verifiedOnly": {
            "title": "Verified spaces only (mode=spaces)",
            "type": "boolean",
            "description": "Only emit spaces Snapshot has marked as verified.",
            "default": false
          },
          "spaceOrderBy": {
            "title": "Order spaces by",
            "enum": [
              "followersCount",
              "proposalsCount",
              "votesCount",
              "created"
            ],
            "type": "string",
            "description": "Sort field for space results (mode=spaces). Note: `followersCount`/`proposalsCount`/`votesCount` are NOT reliably honored by Snapshot's own API (confirmed via direct testing -- it silently falls back to created-date order for these three); only `created` reliably sorts server-side. Results are still complete/correct either way, just not necessarily in the requested order for the three unreliable fields.",
            "default": "created"
          },
          "spaceIds": {
            "title": "Space IDs (mode=spaceByIds)",
            "type": "array",
            "description": "Snapshot space IDs (ENS names), e.g. `ens.eth`.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "voteProposalId": {
            "title": "Proposal ID (mode=votes)",
            "type": "string",
            "description": "Fetch every vote cast on this proposal."
          },
          "voterAddress": {
            "title": "Voter address (mode=votesByVoter)",
            "type": "string",
            "description": "0x wallet address. Returns this voter's cast votes, optionally narrowed with `space`."
          },
          "minVotingPower": {
            "title": "Min voting power (modes=votes/votesByVoter)",
            "minimum": 0,
            "maximum": 1000000000000,
            "type": "number",
            "description": "Only include votes with at least this much voting power."
          },
          "voteOrderBy": {
            "title": "Order votes by",
            "enum": [
              "created",
              "vp"
            ],
            "type": "string",
            "description": "Sort field for vote results (modes=votes/votesByVoter).",
            "default": "created"
          },
          "orderDirection": {
            "title": "Order direction",
            "enum": [
              "desc",
              "asc"
            ],
            "type": "string",
            "description": "Sort direction applied to the chosen order-by field.",
            "default": "desc"
          },
          "maxItems": {
            "title": "Max items",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "Hard cap on emitted records.",
            "default": 25
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Optional. Snapshot's public GraphQL API is not blocked from Apify's datacenter IPs; this is only used as an automatic fallback if it starts returning 403/429 responses.",
            "default": {
              "useApifyProxy": true
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}