One gRPC service per domain in state.v1 (tasks, executions, accounts, identities, packages, captures, bindings, access, orgs, alerts and so on), each with its own server type in staterpc. RPC and message names and numbers are unchanged.
71 lines
2.8 KiB
Protocol Buffer
71 lines
2.8 KiB
Protocol Buffer
syntax = "proto3";
|
|
|
|
package state.v1;
|
|
|
|
import "state/v1/types.proto";
|
|
|
|
// Task-scoped grants cannot call these administrative RPCs.
|
|
service IdentityService {
|
|
rpc ListIdentities(ListIdentitiesRequest) returns (ListIdentitiesResponse);
|
|
rpc GetIdentity(GetIdentityRequest) returns (GetIdentityResponse);
|
|
rpc CreateIdentity(CreateIdentityRequest) returns (CreateIdentityResponse);
|
|
rpc RenameIdentity(RenameIdentityRequest) returns (RenameIdentityResponse);
|
|
rpc SuspendIdentity(SuspendIdentityRequest) returns (SuspendIdentityResponse);
|
|
rpc ReactivateIdentity(ReactivateIdentityRequest) returns (ReactivateIdentityResponse);
|
|
rpc RetireIdentity(RetireIdentityRequest) returns (RetireIdentityResponse);
|
|
// Subject bindings. A verified provider subject is resolved to the identity it
|
|
// is bound to; the authenticating process calls these rather than owning the
|
|
// identity store.
|
|
rpc ResolveIdentitySubject(ResolveIdentitySubjectRequest) returns (ResolveIdentitySubjectResponse);
|
|
rpc BindIdentitySubject(BindIdentitySubjectRequest) returns (BindIdentitySubjectResponse);
|
|
rpc ClaimIdentitySubject(ClaimIdentitySubjectRequest) returns (ClaimIdentitySubjectResponse);
|
|
}
|
|
|
|
message IdentityAudit {
|
|
string actor_id = 1;
|
|
string source = 2;
|
|
string request_id = 3;
|
|
}
|
|
message ListIdentitiesRequest {}
|
|
message ListIdentitiesResponse { repeated Identity identities = 1; }
|
|
message GetIdentityRequest { string id = 1; }
|
|
message GetIdentityResponse { Identity identity = 1; }
|
|
message CreateIdentityRequest {
|
|
string id = 1;
|
|
string kind = 2;
|
|
string display_name = 3;
|
|
IdentityAudit audit = 4;
|
|
}
|
|
message RenameIdentityRequest {
|
|
string id = 1;
|
|
int64 expected_version = 2;
|
|
string display_name = 3;
|
|
IdentityAudit audit = 4;
|
|
}
|
|
message SuspendIdentityRequest { string id = 1; int64 expected_version = 2; IdentityAudit audit = 3; }
|
|
message ReactivateIdentityRequest { string id = 1; int64 expected_version = 2; IdentityAudit audit = 3; }
|
|
message RetireIdentityRequest { string id = 1; int64 expected_version = 2; IdentityAudit audit = 3; }
|
|
message CreateIdentityResponse { Identity identity = 1; }
|
|
message RenameIdentityResponse { Identity identity = 1; }
|
|
message SuspendIdentityResponse { Identity identity = 1; }
|
|
message ReactivateIdentityResponse { Identity identity = 1; }
|
|
message RetireIdentityResponse { Identity identity = 1; }
|
|
message ResolveIdentitySubjectRequest {
|
|
string issuer = 1;
|
|
string subject = 2;
|
|
}
|
|
message ResolveIdentitySubjectResponse { Identity identity = 1; }
|
|
message BindIdentitySubjectRequest {
|
|
string id = 1;
|
|
string issuer = 2;
|
|
string subject = 3;
|
|
IdentityAudit audit = 4;
|
|
}
|
|
message BindIdentitySubjectResponse { Identity identity = 1; }
|
|
message ClaimIdentitySubjectRequest {
|
|
string issuer = 1;
|
|
string placeholder = 2;
|
|
string subject = 3;
|
|
}
|
|
message ClaimIdentitySubjectResponse { Identity identity = 1; }
|