Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade for the Get Contract Events API endpoint #2071

Open
Ghislo749 opened this issue Sep 5, 2024 · 0 comments
Open

Upgrade for the Get Contract Events API endpoint #2071

Ghislo749 opened this issue Sep 5, 2024 · 0 comments

Comments

@Ghislo749
Copy link

Using this endpoint: https://docs.hiro.so/stacks/api/smart-contracts/events
Trying to retrieve events with a specific function_name from a contract that has thousands of contract calls but only few ones with the function_name being targeted might be difficult and heavy on the api, having to parse every 50 events with the offset.

Was wondering if it could be easier to add function_name(s) query parameter to filter out only events that match the name(s).
And maybe add a function_name property in the events properties.

I considered parsing through all of them and filtering them out by checking if the function_name is present in the contract_log.value.repr property, but requires a ping to the api every 50 events in the contract, i feel like that's not very efficient.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: 🆕 New
Development

No branches or pull requests

1 participant