jillesvangurp / stellar-kotlin-client

Kotlin wrapper for the Stellar java sdk with some added kotlin convenience
MIT License
14 stars 1 forks source link

CAP-38 AMM Changes #21

Open paulbellamy opened 3 years ago

paulbellamy commented 3 years ago

We've just released v6.0.1, of the SDF Javascript base library.

It includes changes to implement CAP-38, supporting automated market makers.

These changes will be released with the protocol v18 upgrade.

There are some further notes on the changes API endpoints, with mock responses, on this APIary. Further notes on the API changes are available in this document.

Because the order of the assets must be sorted in the pool ID, as well as in the depositing and withdrawing operations, SDKs should either:

Asset ordering is determined by: Native < AlphaNum4 < AlphaNum12, then by Code, then by Issuer, using lexicographic ordering.

If your SDK has implemented and released these changes, reference the release in a closing comment.

paulbellamy commented 3 years ago

There were a couple of missed points in the initial version of the linked docs sent out.\n\nFirst, there is also a /liquidity_pools/:pool_id/trades api endpoint for retrieving the trades which have taken place in a pool.\n\nSecond, the numerator and denominator in the price field of trades, will be serialized as strings. This is because they can now be 64-bit integers.\n\nBoth changes are now reflected in the updated apiary docs at https://ammmock.docs.apiary.io/