Security News
Introducing the Socket Python SDK
The initial version of the Socket Python SDK is now on PyPI, enabling developers to more easily interact with the Socket REST API in Python projects.
@cowprotocol/ts-dune-client
Advanced tools
Node Client for Dune Analytics' officially supported API.
This NPM package implements all the basic routes defined in the Dune API Docs. It also introduces a convenience method refresh
which combines execute
, getStatus
and getResults
in a way that makes it nearly trivial to fetch query execution results.
Install the package
yarn add @cowprotocol/ts-dune-client
import { QueryParameter, DuneClient } from "@cowprotocol/ts-dune-client";
const { DUNE_API_KEY } = process.env;
const client = new DuneClient(DUNE_API_KEY ?? "");
const queryID = 1215383;
const parameters = [
QueryParameter.text("TextField", "Plain Text"),
QueryParameter.number("NumberField", 3.1415926535),
QueryParameter.date("DateField", "2022-05-04 00:00:00"),
QueryParameter.enum("ListField", "Option 1"),
];
client
.refresh(queryID, parameters)
.then((executionResult) => console.log(executionResult.result?.rows));
// should look like
// [
// {
// date_field: "2022-05-04 00:00:00",
// list_field: "Option 1",
// number_field: "3.1415926535",
// text_field: "Plain Text",
// },
// ]
Note also that the client has methods execute
, getStatus
, getResult
and cancelExecution
Check out this Demo Project!
FAQs
Node Client for Dune Analytics' officially supported API.
The npm package @cowprotocol/ts-dune-client receives a total of 143 weekly downloads. As such, @cowprotocol/ts-dune-client popularity was classified as not popular.
We found that @cowprotocol/ts-dune-client demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 8 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
The initial version of the Socket Python SDK is now on PyPI, enabling developers to more easily interact with the Socket REST API in Python projects.
Security News
Floating dependency ranges in npm can introduce instability and security risks into your project by allowing unverified or incompatible versions to be installed automatically, leading to unpredictable behavior and potential conflicts.
Security News
A new Rust RFC proposes "Trusted Publishing" for Crates.io, introducing short-lived access tokens via OIDC to improve security and reduce risks associated with long-lived API tokens.