Using Datasets can bring a whole new layer to your Smart Triggers and it can make writing your ParsiQL code less bulky. Instead of using the web interface to modify it, our API gives you a way to dynamically modify Dataset entries, e.g. for adding new monitoring addresses programmatically.
Obtaining necessary information
Obtaining an API key
Navigate to PARSIQ Portal and press copy to clipboard button in project's dashboard on the right.
Copying project's ID from project's dashboard
Alternatively, you can go to View All Projects in the sidebar, then press " ⋮ " button next to the project of interest.
Copying project's ID from the projects list
DATASET_TABLE_ID can be found in the interface by pressing " ⋮ " button near the desired dataset.
Supported commands and examples
Our API supports the following commands
to read Datasets
to insert Datasets
to update (and insert) Datasets
to delete Datasets
to completely replace Datasets
How to use them
For example, we have a Dataset table with this info
To retrive your Dataset, use this command
curl --location --request GET 'https://api.parsiq.net/v1/data/DATASET_TABLE_ID'
--header 'Authorization: Bearer YOUR_API_KEY'
To add new rows to your Dataset table, use this command. In this example, two new rows will be added to our Dataset.
curl --location --request POST 'https://api.parsiq.net/v1/data/DATASET_TABLE_ID'
Use this to entirely replace rows of your Dataset Table. Technically you can update, delete and post new rows with this command if you would put an entire updated list of your desired addresses. But in this example, we will put 2 new addresses instead of 4 old ones.
curl --location --request PUT 'https://api.parsiq.net/v1/data/DATASET_TABLE_ID/'