curl --request PATCH \ --url https://api.dune.com/api/v1/query/{queryId} \ --header 'Content-Type: application/json' \ --header 'X-DUNE-API-KEY: <x-dune-api-key>' \ --data '{ "query_id": 1252207, "query_sql": "SELECT * FROM {{blockchain}}.transactions WHERE to = {{address}} AND block_number > {{blocknumber}}",}'
Query Management
Update Query
This API allows for anyone to update the sql text,
parameters, name, tags, and state of a query. Only the API key
generated under the context of the owner of that query will work.
To access Query endpoints, an Analyst plan or higher is required.
Copy
Ask AI
curl --request PATCH \ --url https://api.dune.com/api/v1/query/{queryId} \ --header 'Content-Type: application/json' \ --header 'X-DUNE-API-KEY: <x-dune-api-key>' \ --data '{ "query_id": 1252207, "query_sql": "SELECT * FROM {{blockchain}}.transactions WHERE to = {{address}} AND block_number > {{blocknumber}}",}'