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

Creating a Balancer API provider to fetch pool state for join txs; #97

Merged
merged 20 commits into from
Oct 25, 2023

Conversation

lgahdl
Copy link
Contributor

@lgahdl lgahdl commented Sep 21, 2023

This Balancer API Provider is a utility module designed to provide data for b-sdk functions, initially it will provide pool state input for both join's and exit's, it's divided in "client" and the "modules",

Balancer API Client:
A Http Client that fetches the data from a specified url using a GraphQL query, the url is expected to be from a Beethoven X API or Balancer API, in this link there are some valid urls.

Balancer API Modules:
As a first use case, the module "pool-state" was implemented to provide data for exit's and join's functions of the b-sdk, other modules will implement different data fetchings with different data structures that will be important for other b-sdk functionalities.

@johngrantuk
Copy link
Member

Would be nice to add examples showing how this can be used, could add one for join and one for exit.

Luiz Gustavo Abou Hatem De Liz added 7 commits September 25, 2023 10:22
Changing variable names;
Changing class names;
…e-api

# Conflicts:
#	src/entities/exit/parser.ts
#	src/entities/join/parser.ts
#	test/weightedExit.integration.test.ts
README.md Outdated Show resolved Hide resolved
README.md Outdated Show resolved Hide resolved
src/entities/exit/parser.ts Outdated Show resolved Hide resolved
src/entities/join/parser.ts Outdated Show resolved Hide resolved
Replacing Type PoolState for PoolStateInput;
Updating README.md examples section;
@lgahdl lgahdl requested a review from brunoguerios September 27, 2023 23:15
Copy link
Member

@brunoguerios brunoguerios left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure about why lint and test checks are failing, but otherwise LGTM 👍

@brunoguerios brunoguerios self-requested a review October 9, 2023 20:48
@brunoguerios brunoguerios dismissed their stale review October 9, 2023 20:48

Requested changes were applied

@johngrantuk
Copy link
Member

@lgahdl once the latest updates are pushed can you generate a changelog for the PR please.

Luiz Gustavo Abou Hatem De Liz added 2 commits October 22, 2023 20:05
clarifying query and variables parameters type on fetch function;
…e-api

# Conflicts:
#	.gitignore
#	README.md
#	package.json
@lgahdl lgahdl requested a review from johngrantuk October 22, 2023 23:20
package.json Outdated Show resolved Hide resolved
Luiz Gustavo Abou Hatem De Liz added 3 commits October 23, 2023 19:00
Changing chainId types to ChainId instead of number;
Adding a resolution to install get-port in the version 5.1.2, to accept non ESM imports, since @viem/anvil import this package using require;
package.json Outdated Show resolved Hide resolved
replacing ts-node by tsx;
removing tsconfig-paths;
removing resolutions;
updating pnpm-lock.yaml;
@lgahdl lgahdl requested a review from johngrantuk October 24, 2023 21:57
@johngrantuk johngrantuk merged commit 9de8240 into join Oct 25, 2023
4 checks passed
@johngrantuk johngrantuk deleted the integrate-api branch October 25, 2023 12:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants