sonr/proto/svc/v1/query.proto
Prad Nukala 0ec2f7d86a
feature/1214 session fetch refactor (#1215)
* chore(docs): remove token economy guide

* refactor(context): update GatewayContext to use Querier interface

* chore(database): update schema path

* docs: Update READMEs for x/did, x/dwn, and x/svc with UCAN integration

* chore(pkg): update database scope name

* refactor(did): optimize GenesisState proto methods

* refactor(svc): update Service proto to use repeated fields

* refactor(api): rename MsgSpawn to MsgInitialize
2024-12-24 15:38:17 +00:00

59 lines
1.9 KiB
Protocol Buffer

syntax = "proto3";
package svc.v1;
import "google/api/annotations.proto";
import "svc/v1/genesis.proto";
option go_package = "github.com/onsonr/sonr/x/svc/types";
// Query provides defines the gRPC querier service.
service Query {
// Params queries all parameters of the module.
rpc Params(QueryParamsRequest) returns (QueryParamsResponse) {
option (google.api.http).get = "/svc/v1/params";
}
// OriginExists queries if a given origin exists.
rpc OriginExists(QueryOriginExistsRequest) returns (QueryOriginExistsResponse) {
option (google.api.http).get = "/svc/v1/origins/{origin}";
}
// ResolveOrigin queries the domain of a given service and returns its record with capabilities.
rpc ResolveOrigin(QueryResolveOriginRequest) returns (QueryResolveOriginResponse) {
option (google.api.http).get = "/svc/v1/origins/{origin}/record";
}
}
// QueryParamsRequest is the request type for the Query/Params RPC method.
message QueryParamsRequest {}
// QueryParamsResponse is the response type for the Query/Params RPC method.
message QueryParamsResponse {
// params defines the parameters of the module.
Params params = 1;
}
// QueryOriginExistsRequest is the request type for the Query/OriginExists RPC method.
message QueryOriginExistsRequest {
// origin is the origin to query.
string origin = 1;
}
// QueryOriginExistsResponse is the response type for the Query/OriginExists RPC method.
message QueryOriginExistsResponse {
// exists is the boolean value representing whether the origin exists.
bool exists = 1;
}
// QueryResolveOriginRequest is the request type for the Query/ResolveOrigin RPC method.
message QueryResolveOriginRequest {
// origin is the origin to query.
string origin = 1;
}
// QueryResolveOriginResponse is the response type for the Query/ResolveOrigin RPC method.
message QueryResolveOriginResponse {
// record is the record of the origin.
Service record = 1;
}