pendulum-chain / pendulum-squids

The subsquid squids we use for Pendulum/Amplitude/Foucoco.
GNU General Public License v3.0
0 stars 0 forks source link

Update the indexer to provide metadata/tags added with setRemark() #30

Closed annatekl closed 10 months ago

annatekl commented 10 months ago

Context

When subscribing to the indexer to monitor events like off ramp transaction, the stablecoin issuer has a need to track a reference number associated with transactions during the off-ramp process.

Requirement

Update the indexer to also provide metadata/tags added with setRemark() for executed transfers.

Technical considerations

Unlike on Stellar, it's not possible to add a 'memo' to transfers by default. Nevertheless, we can achieve something similar by grouping calls to tokens/balances::transfer() and system::remark() extrinsic into the same transaction. Thus, we assume that users who want to attach reference numbers to their transfers group the calls to transfer and set a remark in a utility::batch() or utility::batchAll() extrinsic.

Thus, we need to change the indexer such that for every transfer that is handled, we also check if the same transaction contains a call to system::remark() and if so, include the contained data into the Transfer entity stored by the indexer.

annatekl commented 10 months ago

@ebma can you please add the technical requirements for this ticket?

ebma commented 10 months ago

This ticket should be moved to the pendulum-squids repository.

annatekl commented 10 months ago

Please add your planning poker estimate with Zenhub @b-yap

annatekl commented 10 months ago

Hey team! Please add your planning poker estimate with Zenhub @b-yap @bogdanS98 @ebma @gianfra-t @TorstenStueber

ebma commented 10 months ago

@pendulum-chain/product this ticket should get high prio once estimated.