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

feat: add interfaces for each abstract contract used by the Starknet core contract #4

Open
tdelabro opened this issue Dec 22, 2023 · 2 comments
Assignees

Comments

@tdelabro
Copy link
Contributor

tdelabro commented Dec 22, 2023

Starknet core contract is a contract deployed on Ethereum.
It is made of multiple abstract contracts, the list is defined here:

contract Starknet is

Those abstract contract types, define interfaces with a list of methods callable on the contract. Some are internal, but others are external, view, pure, and payable, meaning that they can be triggered by transactions coming from the outer world.
We want our client to expose all of those.

I added some of them in #3. There is more to be added, just follow the way I did it: one abstract contract -> one file -> one abigen macro -> one trait -> one impl for AsRef<MyInterfaceType> -> one field in the client -> one imp of AsRef<MyInterfaceType> for MyClientType.

So go into each abstract contract, find the public method by hitting crtl+F, copy paste their signature in the abigen and then go with the flow

@Tidus91
Copy link
Contributor

Tidus91 commented Dec 22, 2023

i would like to do this one :)

@tdelabro
Copy link
Contributor Author

@Tidus91 all yours!

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

No branches or pull requests

2 participants