2024-09-26 18:01:49 -04:00
|
|
|
syntax = "proto3";
|
|
|
|
package macaroon.v1;
|
|
|
|
|
|
|
|
import "cosmos/orm/v1/orm.proto";
|
|
|
|
|
|
|
|
option go_package = "github.com/onsonr/sonr/x/macaroon/types";
|
|
|
|
|
|
|
|
// https://github.com/cosmos/cosmos-sdk/blob/main/orm/README.md
|
|
|
|
|
2024-10-28 10:12:05 -04:00
|
|
|
// Grant is a Grant message type.
|
2024-09-27 20:58:05 -04:00
|
|
|
message Grant {
|
|
|
|
option (cosmos.orm.v1.table) = {
|
2024-10-08 16:43:59 -04:00
|
|
|
id : 1
|
|
|
|
primary_key : {fields : "id" auto_increment : true}
|
|
|
|
index : {id : 1 fields : "subject,origin" unique : true}
|
2024-09-27 20:58:05 -04:00
|
|
|
};
|
2024-09-26 18:01:49 -04:00
|
|
|
|
2024-09-27 20:58:05 -04:00
|
|
|
uint64 id = 1;
|
|
|
|
string controller = 2;
|
|
|
|
string subject = 3;
|
|
|
|
string origin = 4;
|
|
|
|
int64 expiry_height = 5;
|
|
|
|
}
|
2024-10-02 01:40:49 -04:00
|
|
|
|
2024-10-28 10:12:05 -04:00
|
|
|
// Macaroon is a Macaroon message type.
|
2024-10-02 01:40:49 -04:00
|
|
|
message Macaroon {
|
|
|
|
option (cosmos.orm.v1.table) = {
|
2024-10-08 16:43:59 -04:00
|
|
|
id : 2
|
|
|
|
primary_key : {fields : "id" auto_increment : true}
|
|
|
|
index : {id : 1 fields : "subject,origin" unique : true}
|
2024-10-02 01:40:49 -04:00
|
|
|
};
|
|
|
|
|
|
|
|
uint64 id = 1;
|
|
|
|
string controller = 2;
|
|
|
|
string subject = 3;
|
|
|
|
string origin = 4;
|
|
|
|
int64 expiry_height = 5;
|
|
|
|
string macaroon = 6;
|
|
|
|
}
|