archway-network / archway

Archway Network
https://archway.io
Other
74 stars 99 forks source link

Feature Request: Enable Stargate queries for custom modules #587

Open pyncz opened 3 months ago

pyncz commented 3 months ago

Among the custom modules, only the archway.cwerrors.v1.Query/Errors Stargate query is enabled to be used from smart contracts. Having them available is important to allow building more sophisticated contracts.

From my experience, that issue limited the use of the callback module, since currently there's no way to query the estimated fee to be attached to the registration msg (QueryEstimateCallbackFeesRequest query). It still can be queried from outside the contract (e.g. from a frontend), but it's not the case if you have recurring automated registrations.

Exposing the Params query would be useful as well, at least to validate the automation intervals against the max_future_reservation_limit module param.

But it's not just about callback module ofc, I'm sure it will be a useful to whitelist queries for all the custom modules, if they are safe to use from cosmwasm.