laconicd-deprecated/proto/vulcanize/registry/v1beta1/tx.proto
Nabarun 776799ea02
Some checks failed
Pull Request Labeler / triage (push) Successful in 58s
Run Gosec / Gosec (push) Failing after 2m29s
Tests / cleanup-runs (push) Has been skipped
Lint / Run flake8 on python integration tests (push) Failing after 4m48s
Tests / test-unit-cover (push) Failing after 8m52s
Tests / sdk_tests (push) Failing after 22s
Tests / test-rpc (push) Failing after 1m18s
Lint / Run golangci-lint (push) Successful in 15m15s
Tests / test-importer (push) Successful in 11m6s
CodeQL / Analyze (go) (push) Failing after 3m14s
Semgrep / Scan (push) Failing after 47s
Remove hard-coded record types (#132)
- Resolves #107 and is initial work on #108
  - Refactors the `Record.Attributes` from Any into a byte string and removes the hard-coded Protobuf record types.
  - Fixes EIP-712 bytes decoding.
- Resolves #109
  - Rewords the graphql schema to be able to represent generic IPLD objects encoded as DAG-JSON.

Co-authored-by: Roy Crihfield <roy@manteia.ltd>
Co-authored-by: neeraj <neeraj.rtly@gmail.com>
Co-authored-by: Prathamesh Musale <prathamesh.musale0@gmail.com>
Reviewed-on: cerc-io/laconicd#132
Reviewed-by: Thomas E Lackey <telackey@noreply.git.vdb.to>
Co-authored-by: Nabarun <nabarun@deepstacksoft.com>
Co-committed-by: Nabarun <nabarun@deepstacksoft.com>
2024-01-15 04:20:38 +00:00

161 lines
4.8 KiB
Protocol Buffer

syntax = "proto3";
package vulcanize.registry.v1beta1;
import "gogoproto/gogo.proto";
import "google/api/annotations.proto";
import "vulcanize/registry/v1beta1/registry.proto";
option go_package = "github.com/cerc-io/laconicd/x/registry/types";
// Msg is a service which exposes the registry functionality
service Msg {
// SetRecord records a new record with given payload and bond id
rpc SetRecord(MsgSetRecord) returns (MsgSetRecordResponse) {
option (google.api.http).post = "/vulcanize/registry/v1beta1/set_record";
}
// Renew Record renews an expired record
rpc RenewRecord(MsgRenewRecord) returns (MsgRenewRecordResponse) {
option (google.api.http).post = "/vulcanize/registry/v1beta1/renew_record";
}
// AssociateBond
rpc AssociateBond(MsgAssociateBond) returns (MsgAssociateBondResponse) {
option (google.api.http).post = "/vulcanize/registry/v1beta1/associate_bond";
}
// DissociateBond
rpc DissociateBond(MsgDissociateBond) returns (MsgDissociateBondResponse) {
option (google.api.http).post = "/vulcanize/registry/v1beta1/dissociate_bond";
}
// DissociateRecords
rpc DissociateRecords(MsgDissociateRecords) returns (MsgDissociateRecordsResponse) {
option (google.api.http).post = "/vulcanize/registry/v1beta1/dissociate_records";
}
// ReAssociateRecords
rpc ReAssociateRecords(MsgReAssociateRecords) returns (MsgReAssociateRecordsResponse) {
option (google.api.http).post = "/vulcanize/registry/v1beta1/reassociate_records";
}
// SetName will store the name with given crn and name
rpc SetName(MsgSetName) returns (MsgSetNameResponse) {
option (google.api.http).post = "/vulcanize/registry/v1beta1/set_name";
}
// Reserve name
rpc ReserveName(MsgReserveAuthority) returns (MsgReserveAuthorityResponse) {
option (google.api.http).post = "/vulcanize/registry/v1beta1/reserve_name";
}
// Delete Name method will remove authority name
rpc DeleteName(MsgDeleteNameAuthority) returns (MsgDeleteNameAuthorityResponse) {
option (google.api.http).post = "/vulcanize/registry/v1beta1/delete_name";
}
// SetAuthorityBond
rpc SetAuthorityBond(MsgSetAuthorityBond) returns (MsgSetAuthorityBondResponse) {
option (google.api.http).post = "/vulcanize/registry/v1beta1/set_authority_bond";
}
}
// MsgSetRecord
message MsgSetRecord {
string bond_id = 1 [(gogoproto.moretags) = "json:\"bondId\" yaml:\"bondId\""];
string signer = 2;
Payload payload = 3 [(gogoproto.nullable) = false];
}
// MsgSetRecordResponse
message MsgSetRecordResponse {
string id = 1;
}
// Payload
message Payload {
Record record = 1;
repeated Signature signatures = 2 [
(gogoproto.nullable) = false,
(gogoproto.moretags) = "json:\"signatures\" yaml:\"signatures\""
];
}
// MsgSetName
message MsgSetName {
string crn = 1;
string cid = 2;
string signer = 3;
}
// MsgSetNameResponse
message MsgSetNameResponse {}
// MsgReserveName
message MsgReserveAuthority {
string name = 1;
string signer = 2;
// if creating a sub-authority.
string owner = 3;
}
// MsgReserveNameResponse
message MsgReserveAuthorityResponse {}
// MsgSetAuthorityBond
message MsgSetAuthorityBond {
string name = 1;
string bond_id = 2 [(gogoproto.moretags) = "json:\"bondId\" yaml:\"bondId\""];
string signer = 3;
}
// MsgSetAuthorityBondResponse
message MsgSetAuthorityBondResponse {}
// MsgDeleteNameAuthority
message MsgDeleteNameAuthority {
string crn = 1;
string signer = 2;
}
// MsgDeleteNameAuthorityResponse
message MsgDeleteNameAuthorityResponse {}
// MsgRenewRecord
message MsgRenewRecord {
string record_id = 1 [(gogoproto.moretags) = "json:\"recordId\" yaml:\"recordId\""];
string signer = 2;
}
// MsgRenewRecordResponse
message MsgRenewRecordResponse {}
// MsgAssociateBond
message MsgAssociateBond {
string record_id = 1 [(gogoproto.moretags) = "json:\"recordId\" yaml:\"recordId\""];
string bond_id = 2 [(gogoproto.moretags) = "json:\"bondId\" yaml:\"bondId\""];
string signer = 3;
}
// MsgAssociateBondResponse
message MsgAssociateBondResponse {}
// MsgDissociateBond
message MsgDissociateBond {
string record_id = 1 [(gogoproto.moretags) = "json:\"recordId\" yaml:\"recordId\""];
string signer = 2;
}
// MsgDissociateBondResponse
message MsgDissociateBondResponse {}
// MsgDissociateRecords
message MsgDissociateRecords {
string bond_id = 1 [(gogoproto.moretags) = "json:\"bondId\" yaml:\"bondId\""];
string signer = 2;
}
// MsgDissociateRecordsResponse
message MsgDissociateRecordsResponse {}
// MsgReAssociateRecords
message MsgReAssociateRecords {
string new_bond_id = 1 [(gogoproto.moretags) = "json:\"newBondId\" yaml:\"newBondId\""];
string old_bond_id = 2 [(gogoproto.moretags) = "json:\"oldBondId\" yaml:\"oldBondId\""];
string signer = 3;
}
// MsgReAssociateRecordsResponse
message MsgReAssociateRecordsResponse {}