Skip to content

Commit

Permalink
Merge branch 'main' into CNS-394-delete-safely-the-consumer-stake-parts
Browse files Browse the repository at this point in the history
  • Loading branch information
Yarom Swisa authored and Yarom Swisa committed May 31, 2023
2 parents 0a0cdd1 + 71a1bd0 commit 62e9825
Show file tree
Hide file tree
Showing 5 changed files with 1,272 additions and 956 deletions.
63 changes: 63 additions & 0 deletions docs/static/openapi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54962,6 +54962,69 @@ definitions:
type: array
items:
type: string
lavanet.lava.pairing.GenerateBadgeResponse:
type: object
properties:
badge:
type: object
properties:
cu_allocation:
type: string
format: uint64
epoch:
type: string
format: uint64
address:
type: string
lava_chain_id:
type: string
project_sig:
type: string
format: byte
pairing_list:
type: array
items:
type: object
properties:
stake:
type: object
properties:
denom:
type: string
amount:
type: string
description: >-
Coin defines a token with a denomination and an amount.


NOTE: The amount field is an Int which implements the custom
method

signatures required by gogoproto.
address:
type: string
stake_applied_block:
type: string
format: uint64
endpoints:
type: array
items:
type: object
properties:
iPPORT:
type: string
useType:
type: string
geolocation:
type: string
format: uint64
geolocation:
type: string
format: uint64
chain:
type: string
moniker:
type: string
lavanet.lava.pairing.Metadata:
type: object
properties:
Expand Down
30 changes: 30 additions & 0 deletions proto/pairing/badges.proto
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
syntax = "proto3";
package lavanet.lava.pairing;
import "gogoproto/gogo.proto";
import "google/protobuf/wrappers.proto";
import "epochstorage/stake_entry.proto";

option go_package = "github.com/lavanet/lava/x/pairing/types";

message Badge {
uint64 cu_allocation =1;
uint64 epoch = 2;
string address = 3;
string lava_chain_id = 4;
bytes project_sig = 5;
}

message GenerateBadgeRequest {
string badge_address = 1;
string project_id = 2;
string spec_id = 3 [(gogoproto.nullable) = true];
}

message GenerateBadgeResponse {
Badge badge = 1;
repeated lavanet.lava.epochstorage.StakeEntry pairing_list = 2 [(gogoproto.nullable) = true];
}

service BadgeGenerator {
rpc GenerateBadge(GenerateBadgeRequest) returns (GenerateBadgeResponse) {}
}
18 changes: 1 addition & 17 deletions proto/pairing/relay.proto
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ syntax = "proto3";
package lavanet.lava.pairing;
import "gogoproto/gogo.proto";
import "google/protobuf/wrappers.proto";
import "epochstorage/stake_entry.proto";
import "pairing/badges.proto";

option go_package = "github.com/lavanet/lava/x/pairing/types";

Expand Down Expand Up @@ -48,24 +48,8 @@ message RelayRequest {
RelayPrivateData relay_data= 2;
}

message Badge {
uint64 cu_allocation =1;
uint64 epoch = 2;
string address = 3;
string lava_chain_id = 4;
bytes project_sig = 5;
}

message GenerateBadgeRequest {
string badge_address = 1;
string project_id = 2;
string spec_id = 3 [(gogoproto.nullable) = true];
}

message GenerateBadgeResponse {
Badge badge = 1;
repeated lavanet.lava.epochstorage.StakeEntry pairing_list = 2 [(gogoproto.nullable) = true];
}

message RelayReply {
bytes data = 1;
Expand Down
Loading

0 comments on commit 62e9825

Please sign in to comment.