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

Support for arbitrary message types #29

Open
samepant opened this issue Feb 1, 2022 · 1 comment
Open

Support for arbitrary message types #29

samepant opened this issue Feb 1, 2022 · 1 comment

Comments

@samepant
Copy link
Contributor

samepant commented Feb 1, 2022

Right now the app only supports signing messages for sending tokens. It would be great if multisigs could create and sign any message type (even uploading or pasting in JSON).

I'm a little unclear as to whether this would mean adding support for protobuf message types, or if the Amino signer can handle any message type.

@webmaster128 Any ideas?

@webmaster128
Copy link
Member

webmaster128 commented Feb 1, 2022

I think this is a great and very valid feature request. However, unfortunatly CosmJS does not yet have the tools to support it well.

In CosmJS, everything starts with a protobuf message. This proto message is the one that is broadcasted to chain at the end of the day. In some cases, the messages are signed in a different representation than that (Amino JSON). But this only affects the signature generation, not how the message is actually encoded in the transaction.

Now those proto messages have a JavaScript representation: EncodeObject. This is good enough for caller-CosmJS app internal communication. But it does not a format that can easily be generated elsewhere. Ideally we support the protobuf JSON representation that is dumped by the Go tooling and convert it to EncodeObjects. This is something that would best be implemented in CosmJS as it is general purpose tooling.

@webmaster128 webmaster128 changed the title Support for other message types Support for arbitrary message types Jun 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants