archway-network / archway

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

feat(x/callback): Implement QueryServer #488

Closed spoo-bar closed 9 months ago

spoo-bar commented 10 months ago

Implement Query Server based on AIP

service Query {
    // Params returns module parameters
    rpc Params(QueryParamsRequest) returns (QueryParamsResponse) {
      option (google.api.http).get = "/archway/callback/v1/params";
    }
    // EstimateCallbackFees returns the total amount of callback fees a contract needs to pay to register the callback
    rpc EstimateCallbackFees(QueryEstimateCallbackFeesRequest) returns (QueryEstimateCallbackFeesResponse) { 
      option (google.api.http).get = "/archway/callback/v1/estimate_callback_fees";
    }
    // Callbacks returns all the callbacks registered at a given height
    rpc Callbacks(QueryCallbacksRequest) returns (QueryCallbacksResponse) { 
      option (google.api.http).get = "/archway/callback/v1/callbacks";
    }
}
spoo-bar commented 9 months ago

Implemented with https://github.com/archway-network/archway/pull/509