syntax = "proto3";
package cosmostest.cosmostest;

import "gogoproto/gogo.proto";
import "google/api/annotations.proto";
import "cosmos/base/query/v1beta1/pagination.proto";
import "cosmostest/params.proto";
import "cosmostest/next_auction.proto";
import "cosmostest/auction.proto";
// this line is used by starport scaffolding # 1

option go_package = "cosmos-test/x/cosmostest/types";

// Query defines the gRPC querier service.
service Query {
  // Parameters queries the parameters of the module.
  rpc Params(QueryParamsRequest) returns (QueryParamsResponse) {
    option (google.api.http).get = "/cosmos-test/cosmostest/params";
  }
  // Queries a NextAuction by index.
	rpc NextAuction(QueryGetNextAuctionRequest) returns (QueryGetNextAuctionResponse) {
		option (google.api.http).get = "/cosmos-test/cosmostest/next_auction";
	}
// Queries a Auction by index.
	rpc Auction(QueryGetAuctionRequest) returns (QueryGetAuctionResponse) {
		option (google.api.http).get = "/cosmos-test/cosmostest/auction/{index}";
	}

	// Queries a list of Auction items.
	rpc AuctionAll(QueryAllAuctionRequest) returns (QueryAllAuctionResponse) {
		option (google.api.http).get = "/cosmos-test/cosmostest/auction";
	}

// this line is used by starport scaffolding # 2
}

// QueryParamsRequest is request type for the Query/Params RPC method.
message QueryParamsRequest {}

// QueryParamsResponse is response type for the Query/Params RPC method.
message QueryParamsResponse {
  // params holds all the parameters of this module.
  Params params = 1 [(gogoproto.nullable) = false];
}

message QueryGetNextAuctionRequest {}

message QueryGetNextAuctionResponse {
	NextAuction NextAuction = 1 [(gogoproto.nullable) = false];
}
message QueryGetAuctionRequest {
	  string index = 1;

}

message QueryGetAuctionResponse {
	Auction auction = 1 [(gogoproto.nullable) = false];
}

message QueryAllAuctionRequest {
	cosmos.base.query.v1beta1.PageRequest pagination = 1;
}

message QueryAllAuctionResponse {
	repeated Auction auction = 1 [(gogoproto.nullable) = false];
	cosmos.base.query.v1beta1.PageResponse pagination = 2;
}

// this line is used by starport scaffolding # 3
