herissondev / archethic-python-sdk

Python SDK to interact with archethic blockchain
9 stars 0 forks source link

Old definition of token graphql API #19

Closed Neylix closed 2 years ago

Neylix commented 2 years ago

Hello !

It seems that the token API use en old graphql definition : https://github.com/aime-risson/archethic-python-sdk/blob/0ae18ec2516352fc75eb01d723a440483cd16c10/src/archethic/api.py#L112

A new definition of token has been released in version 0.24 of the node according to the new version of AEIP2.

The good graphql definition to get all field would be query {token(address: "%s") {genesis name symbol supply type properties collection id decimals}}

herissondev commented 2 years ago

Hi ! noted,I'll update that. However i think the libjs API call misses the properties {name value} which causes an error in my case. I think they should be added in the graphql definition like so: query {token(address: "%s") {genesis name symbol supply type properties {name value} collection id decimals}}

herissondev commented 2 years ago

Oups I was wrong I tested it on and old node version...

herissondev commented 2 years ago

Closed by 5185908