Commit 95df6472 authored by Steven's avatar Steven

chore: tweak comments

parent f52e0e00
...@@ -4,6 +4,7 @@ package memos.api.v2; ...@@ -4,6 +4,7 @@ package memos.api.v2;
import "google/api/annotations.proto"; import "google/api/annotations.proto";
import "google/api/client.proto"; import "google/api/client.proto";
import "google/api/field_behavior.proto";
import "google/protobuf/timestamp.proto"; import "google/protobuf/timestamp.proto";
option go_package = "gen/api/v2"; option go_package = "gen/api/v2";
...@@ -17,25 +18,30 @@ service ActivityService { ...@@ -17,25 +18,30 @@ service ActivityService {
} }
message Activity { message Activity {
// The system-generated unique identifier for the activity.
int32 id = 1; int32 id = 1;
// The system-generated unique identifier for the user who created the activity.
int32 creator_id = 2; int32 creator_id = 2;
// The type of the activity.
string type = 3; string type = 3;
// The level of the activity.
string level = 4; string level = 4;
// The create time of the activity.
google.protobuf.Timestamp create_time = 5; google.protobuf.Timestamp create_time = 5 [(google.api.field_behavior) = OUTPUT_ONLY];
// The payload of the activity.
ActivityPayload payload = 6; ActivityPayload payload = 6;
} }
// ActivityMemoCommentPayload represents the payload of a memo comment activity.
message ActivityMemoCommentPayload { message ActivityMemoCommentPayload {
// The memo id of comment.
int32 memo_id = 1; int32 memo_id = 1;
// The memo id of related memo.
int32 related_memo_id = 2; int32 related_memo_id = 2;
} }
message ActivityVersionUpdatePayload { message ActivityVersionUpdatePayload {
// The updated version of memos.
string version = 1; string version = 1;
} }
...@@ -45,6 +51,7 @@ message ActivityPayload { ...@@ -45,6 +51,7 @@ message ActivityPayload {
} }
message GetActivityRequest { message GetActivityRequest {
// The system-generated unique identifier for the activity.
int32 id = 1; int32 id = 1;
} }
......
...@@ -37,8 +37,11 @@ message GetAuthStatusResponse { ...@@ -37,8 +37,11 @@ message GetAuthStatusResponse {
} }
message SignInRequest { message SignInRequest {
// The username to sign in with.
string username = 1; string username = 1;
// The password to sign in with.
string password = 2; string password = 2;
// Whether the session should never expire.
bool never_expire = 3; bool never_expire = 3;
} }
...@@ -47,8 +50,11 @@ message SignInResponse { ...@@ -47,8 +50,11 @@ message SignInResponse {
} }
message SignInWithSSORequest { message SignInWithSSORequest {
// The ID of the SSO provider.
int32 idp_id = 1; int32 idp_id = 1;
// The code to sign in with.
string code = 2; string code = 2;
// The redirect URI.
string redirect_uri = 3; string redirect_uri = 3;
} }
...@@ -57,7 +63,9 @@ message SignInWithSSOResponse { ...@@ -57,7 +63,9 @@ message SignInWithSSOResponse {
} }
message SignUpRequest { message SignUpRequest {
// The username to sign up with.
string username = 1; string username = 1;
// The password to sign up with.
string password = 2; string password = 2;
} }
......
...@@ -6,9 +6,7 @@ option go_package = "gen/api/v2"; ...@@ -6,9 +6,7 @@ option go_package = "gen/api/v2";
enum RowStatus { enum RowStatus {
ROW_STATUS_UNSPECIFIED = 0; ROW_STATUS_UNSPECIFIED = 0;
ACTIVE = 1; ACTIVE = 1;
ARCHIVED = 2; ARCHIVED = 2;
} }
......
...@@ -9,15 +9,21 @@ import "google/protobuf/field_mask.proto"; ...@@ -9,15 +9,21 @@ import "google/protobuf/field_mask.proto";
option go_package = "gen/api/v2"; option go_package = "gen/api/v2";
service IdentityProviderService { service IdentityProviderService {
// ListIdentityProviders lists identity providers.
rpc ListIdentityProviders(ListIdentityProvidersRequest) returns (ListIdentityProvidersResponse) { rpc ListIdentityProviders(ListIdentityProvidersRequest) returns (ListIdentityProvidersResponse) {
option (google.api.http) = {get: "/api/v2/identityProviders"}; option (google.api.http) = {get: "/api/v2/identityProviders"};
} }
// GetIdentityProvider gets an identity provider.
rpc GetIdentityProvider(GetIdentityProviderRequest) returns (GetIdentityProviderResponse) { rpc GetIdentityProvider(GetIdentityProviderRequest) returns (GetIdentityProviderResponse) {
option (google.api.http) = {get: "/api/v2/{name=identityProviders/*}"}; option (google.api.http) = {get: "/api/v2/{name=identityProviders/*}"};
option (google.api.method_signature) = "name"; option (google.api.method_signature) = "name";
} }
// CreateIdentityProvider creates an identity provider.
rpc CreateIdentityProvider(CreateIdentityProviderRequest) returns (CreateIdentityProviderResponse) { rpc CreateIdentityProvider(CreateIdentityProviderRequest) returns (CreateIdentityProviderResponse) {
option (google.api.http) = {post: "/api/v2/identityProviders"}; option (google.api.http) = {
post: "/api/v2/identityProviders",
body: "identity_provider"
};
} }
// UpdateIdentityProvider updates an identity provider. // UpdateIdentityProvider updates an identity provider.
rpc UpdateIdentityProvider(UpdateIdentityProviderRequest) returns (UpdateIdentityProviderResponse) { rpc UpdateIdentityProvider(UpdateIdentityProviderRequest) returns (UpdateIdentityProviderResponse) {
......
...@@ -7,8 +7,9 @@ import "google/api/annotations.proto"; ...@@ -7,8 +7,9 @@ import "google/api/annotations.proto";
option go_package = "gen/api/v2"; option go_package = "gen/api/v2";
service LinkService { service LinkService {
// GetLinkMetadata returns metadata for a given link.
rpc GetLinkMetadata(GetLinkMetadataRequest) returns (GetLinkMetadataResponse) { rpc GetLinkMetadata(GetLinkMetadataRequest) returns (GetLinkMetadataResponse) {
option (google.api.http) = {get: "/api/v2/link_metadata"}; option (google.api.http) = {get: "/api/v2/linkMetadata"};
} }
} }
......
...@@ -50,12 +50,15 @@ service MemoService { ...@@ -50,12 +50,15 @@ service MemoService {
} }
// ExportMemos exports memos. // ExportMemos exports memos.
rpc ExportMemos(ExportMemosRequest) returns (ExportMemosResponse) { rpc ExportMemos(ExportMemosRequest) returns (ExportMemosResponse) {
option (google.api.http) = {post: "/api/v2/memos:export"}; option (google.api.http) = {
post: "/api/v2/memos:export",
body: "*"
};
} }
// SetMemoResources sets resources for a memo. // SetMemoResources sets resources for a memo.
rpc SetMemoResources(SetMemoResourcesRequest) returns (SetMemoResourcesResponse) { rpc SetMemoResources(SetMemoResourcesRequest) returns (SetMemoResourcesResponse) {
option (google.api.http) = { option (google.api.http) = {
post: "/api/v2/{name=memos/*}/resources" patch: "/api/v2/{name=memos/*}/resources"
body: "*" body: "*"
}; };
option (google.api.method_signature) = "name"; option (google.api.method_signature) = "name";
...@@ -68,7 +71,7 @@ service MemoService { ...@@ -68,7 +71,7 @@ service MemoService {
// SetMemoRelations sets relations for a memo. // SetMemoRelations sets relations for a memo.
rpc SetMemoRelations(SetMemoRelationsRequest) returns (SetMemoRelationsResponse) { rpc SetMemoRelations(SetMemoRelationsRequest) returns (SetMemoRelationsResponse) {
option (google.api.http) = { option (google.api.http) = {
post: "/api/v2/{name=memos/*}/relations" patch: "/api/v2/{name=memos/*}/relations"
body: "*" body: "*"
}; };
option (google.api.method_signature) = "name"; option (google.api.method_signature) = "name";
...@@ -80,7 +83,10 @@ service MemoService { ...@@ -80,7 +83,10 @@ service MemoService {
} }
// CreateMemoComment creates a comment for a memo. // CreateMemoComment creates a comment for a memo.
rpc CreateMemoComment(CreateMemoCommentRequest) returns (CreateMemoCommentResponse) { rpc CreateMemoComment(CreateMemoCommentRequest) returns (CreateMemoCommentResponse) {
option (google.api.http) = {post: "/api/v2/{name=memos/*}/comments"}; option (google.api.http) = {
post: "/api/v2/{name=memos/*}/comments",
body: "*"
};
option (google.api.method_signature) = "name"; option (google.api.method_signature) = "name";
} }
// ListMemoComments lists comments for a memo. // ListMemoComments lists comments for a memo.
...@@ -100,7 +106,10 @@ service MemoService { ...@@ -100,7 +106,10 @@ service MemoService {
} }
// UpsertMemoReaction upserts a reaction for a memo. // UpsertMemoReaction upserts a reaction for a memo.
rpc UpsertMemoReaction(UpsertMemoReactionRequest) returns (UpsertMemoReactionResponse) { rpc UpsertMemoReaction(UpsertMemoReactionRequest) returns (UpsertMemoReactionResponse) {
option (google.api.http) = {post: "/api/v2/{name=memos/*}/reactions"}; option (google.api.http) = {
post: "/api/v2/{name=memos/*}/reactions",
body: "*"
};
option (google.api.method_signature) = "name"; option (google.api.method_signature) = "name";
} }
// DeleteMemoReaction deletes a reaction for a memo. // DeleteMemoReaction deletes a reaction for a memo.
...@@ -112,11 +121,8 @@ service MemoService { ...@@ -112,11 +121,8 @@ service MemoService {
enum Visibility { enum Visibility {
VISIBILITY_UNSPECIFIED = 0; VISIBILITY_UNSPECIFIED = 0;
PRIVATE = 1; PRIVATE = 1;
PROTECTED = 2; PROTECTED = 2;
PUBLIC = 3; PUBLIC = 3;
} }
......
...@@ -13,7 +13,10 @@ option go_package = "gen/api/v2"; ...@@ -13,7 +13,10 @@ option go_package = "gen/api/v2";
service ResourceService { service ResourceService {
// CreateResource creates a new resource. // CreateResource creates a new resource.
rpc CreateResource(CreateResourceRequest) returns (CreateResourceResponse) { rpc CreateResource(CreateResourceRequest) returns (CreateResourceResponse) {
option (google.api.http) = {post: "/api/v2/resources"}; option (google.api.http) = {
post: "/api/v2/resources",
body: "resource"
};
} }
// ListResources lists all resources. // ListResources lists all resources.
rpc ListResources(ListResourcesRequest) returns (ListResourcesResponse) { rpc ListResources(ListResourcesRequest) returns (ListResourcesResponse) {
......
...@@ -9,11 +9,17 @@ option go_package = "gen/api/v2"; ...@@ -9,11 +9,17 @@ option go_package = "gen/api/v2";
service TagService { service TagService {
// UpsertTag upserts a tag. // UpsertTag upserts a tag.
rpc UpsertTag(UpsertTagRequest) returns (UpsertTagResponse) { rpc UpsertTag(UpsertTagRequest) returns (UpsertTagResponse) {
option (google.api.http) = {post: "/api/v2/tags"}; option (google.api.http) = {
post: "/api/v2/tags",
body: "*"
};
} }
// BatchUpsertTag upserts multiple tags. // BatchUpsertTag upserts multiple tags.
rpc BatchUpsertTag(BatchUpsertTagRequest) returns (BatchUpsertTagResponse) { rpc BatchUpsertTag(BatchUpsertTagRequest) returns (BatchUpsertTagResponse) {
option (google.api.http) = {post: "/api/v2/tags:batchUpsert"}; option (google.api.http) = {
post: "/api/v2/tags:batchUpsert",
body: "*"
};
} }
// ListTags lists tags. // ListTags lists tags.
rpc ListTags(ListTagsRequest) returns (ListTagsResponse) { rpc ListTags(ListTagsRequest) returns (ListTagsResponse) {
...@@ -22,7 +28,10 @@ service TagService { ...@@ -22,7 +28,10 @@ service TagService {
// RenameTag renames a tag. // RenameTag renames a tag.
// All related memos will be updated. // All related memos will be updated.
rpc RenameTag(RenameTagRequest) returns (RenameTagResponse) { rpc RenameTag(RenameTagRequest) returns (RenameTagResponse) {
option (google.api.http) = {patch: "/api/v2/tags:rename"}; option (google.api.http) = {
patch: "/api/v2/tags:rename",
body: "*"
};
} }
// DeleteTag deletes a tag. // DeleteTag deletes a tag.
rpc DeleteTag(DeleteTagRequest) returns (DeleteTagResponse) { rpc DeleteTag(DeleteTagRequest) returns (DeleteTagResponse) {
......
...@@ -16,18 +16,15 @@ service UserService { ...@@ -16,18 +16,15 @@ service UserService {
rpc ListUsers(ListUsersRequest) returns (ListUsersResponse) { rpc ListUsers(ListUsersRequest) returns (ListUsersResponse) {
option (google.api.http) = {get: "/api/v2/users"}; option (google.api.http) = {get: "/api/v2/users"};
} }
// SearchUsers searches users by filter. // SearchUsers searches users by filter.
rpc SearchUsers(SearchUsersRequest) returns (SearchUsersResponse) { rpc SearchUsers(SearchUsersRequest) returns (SearchUsersResponse) {
option (google.api.http) = {get: "/api/v2/users:search"}; option (google.api.http) = {get: "/api/v2/users:search"};
} }
// GetUser gets a user by name. // GetUser gets a user by name.
rpc GetUser(GetUserRequest) returns (GetUserResponse) { rpc GetUser(GetUserRequest) returns (GetUserResponse) {
option (google.api.http) = {get: "/api/v2/{name=users/*}"}; option (google.api.http) = {get: "/api/v2/{name=users/*}"};
option (google.api.method_signature) = "name"; option (google.api.method_signature) = "name";
} }
// CreateUser creates a new user. // CreateUser creates a new user.
rpc CreateUser(CreateUserRequest) returns (CreateUserResponse) { rpc CreateUser(CreateUserRequest) returns (CreateUserResponse) {
option (google.api.http) = { option (google.api.http) = {
...@@ -36,7 +33,6 @@ service UserService { ...@@ -36,7 +33,6 @@ service UserService {
}; };
option (google.api.method_signature) = "user"; option (google.api.method_signature) = "user";
} }
// UpdateUser updates a user. // UpdateUser updates a user.
rpc UpdateUser(UpdateUserRequest) returns (UpdateUserResponse) { rpc UpdateUser(UpdateUserRequest) returns (UpdateUserResponse) {
option (google.api.http) = { option (google.api.http) = {
...@@ -45,19 +41,16 @@ service UserService { ...@@ -45,19 +41,16 @@ service UserService {
}; };
option (google.api.method_signature) = "user,update_mask"; option (google.api.method_signature) = "user,update_mask";
} }
// DeleteUser deletes a user. // DeleteUser deletes a user.
rpc DeleteUser(DeleteUserRequest) returns (DeleteUserResponse) { rpc DeleteUser(DeleteUserRequest) returns (DeleteUserResponse) {
option (google.api.http) = {delete: "/api/v2/{name=users/*}"}; option (google.api.http) = {delete: "/api/v2/{name=users/*}"};
option (google.api.method_signature) = "name"; option (google.api.method_signature) = "name";
} }
// GetUserSetting gets the setting of a user. // GetUserSetting gets the setting of a user.
rpc GetUserSetting(GetUserSettingRequest) returns (GetUserSettingResponse) { rpc GetUserSetting(GetUserSettingRequest) returns (GetUserSettingResponse) {
option (google.api.http) = {get: "/api/v2/{name=users/*}/setting"}; option (google.api.http) = {get: "/api/v2/{name=users/*}/setting"};
option (google.api.method_signature) = "name"; option (google.api.method_signature) = "name";
} }
// UpdateUserSetting updates the setting of a user. // UpdateUserSetting updates the setting of a user.
rpc UpdateUserSetting(UpdateUserSettingRequest) returns (UpdateUserSettingResponse) { rpc UpdateUserSetting(UpdateUserSettingRequest) returns (UpdateUserSettingResponse) {
option (google.api.http) = { option (google.api.http) = {
...@@ -66,13 +59,11 @@ service UserService { ...@@ -66,13 +59,11 @@ service UserService {
}; };
option (google.api.method_signature) = "setting,update_mask"; option (google.api.method_signature) = "setting,update_mask";
} }
// ListUserAccessTokens returns a list of access tokens for a user. // ListUserAccessTokens returns a list of access tokens for a user.
rpc ListUserAccessTokens(ListUserAccessTokensRequest) returns (ListUserAccessTokensResponse) { rpc ListUserAccessTokens(ListUserAccessTokensRequest) returns (ListUserAccessTokensResponse) {
option (google.api.http) = {get: "/api/v2/{name=users/*}/access_tokens"}; option (google.api.http) = {get: "/api/v2/{name=users/*}/access_tokens"};
option (google.api.method_signature) = "name"; option (google.api.method_signature) = "name";
} }
// CreateUserAccessToken creates a new access token for a user. // CreateUserAccessToken creates a new access token for a user.
rpc CreateUserAccessToken(CreateUserAccessTokenRequest) returns (CreateUserAccessTokenResponse) { rpc CreateUserAccessToken(CreateUserAccessTokenRequest) returns (CreateUserAccessTokenResponse) {
option (google.api.http) = { option (google.api.http) = {
...@@ -81,7 +72,6 @@ service UserService { ...@@ -81,7 +72,6 @@ service UserService {
}; };
option (google.api.method_signature) = "name"; option (google.api.method_signature) = "name";
} }
// DeleteUserAccessToken deletes an access token for a user. // DeleteUserAccessToken deletes an access token for a user.
rpc DeleteUserAccessToken(DeleteUserAccessTokenRequest) returns (DeleteUserAccessTokenResponse) { rpc DeleteUserAccessToken(DeleteUserAccessTokenRequest) returns (DeleteUserAccessTokenResponse) {
option (google.api.http) = {delete: "/api/v2/{name=users/*}/access_tokens/{access_token}"}; option (google.api.http) = {delete: "/api/v2/{name=users/*}/access_tokens/{access_token}"};
......
...@@ -19,7 +19,7 @@ plugins: ...@@ -19,7 +19,7 @@ plugins:
opt: opt:
- paths=source_relative - paths=source_relative
- plugin: buf.build/grpc-ecosystem/openapiv2:v2.19.0 - plugin: buf.build/grpc-ecosystem/openapiv2:v2.19.0
out: ../server/route/api/v2/ out: ../docs
opt: output_format=yaml,allow_merge=true opt: output_format=yaml,allow_merge=true
# Build the TypeScript definitions for the web. # Build the TypeScript definitions for the web.
- plugin: buf.build/community/stephenh-ts-proto:v1.152.1 - plugin: buf.build/community/stephenh-ts-proto:v1.152.1
...@@ -33,7 +33,3 @@ plugins: ...@@ -33,7 +33,3 @@ plugins:
- useExactTypes=false - useExactTypes=false
- esModuleInterop=true - esModuleInterop=true
- stringEnums=true - stringEnums=true
- plugin: buf.build/community/pseudomuto-doc:v1.5.1
out: gen
opt:
- markdown,README.md,source_relative
This diff is collapsed.
This diff is collapsed.
...@@ -111,9 +111,12 @@ type SignInRequest struct { ...@@ -111,9 +111,12 @@ type SignInRequest struct {
sizeCache protoimpl.SizeCache sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields unknownFields protoimpl.UnknownFields
Username string `protobuf:"bytes,1,opt,name=username,proto3" json:"username,omitempty"` // The username to sign in with.
Password string `protobuf:"bytes,2,opt,name=password,proto3" json:"password,omitempty"` Username string `protobuf:"bytes,1,opt,name=username,proto3" json:"username,omitempty"`
NeverExpire bool `protobuf:"varint,3,opt,name=never_expire,json=neverExpire,proto3" json:"never_expire,omitempty"` // The password to sign in with.
Password string `protobuf:"bytes,2,opt,name=password,proto3" json:"password,omitempty"`
// Whether the session should never expire.
NeverExpire bool `protobuf:"varint,3,opt,name=never_expire,json=neverExpire,proto3" json:"never_expire,omitempty"`
} }
func (x *SignInRequest) Reset() { func (x *SignInRequest) Reset() {
...@@ -221,8 +224,11 @@ type SignInWithSSORequest struct { ...@@ -221,8 +224,11 @@ type SignInWithSSORequest struct {
sizeCache protoimpl.SizeCache sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields unknownFields protoimpl.UnknownFields
IdpId int32 `protobuf:"varint,1,opt,name=idp_id,json=idpId,proto3" json:"idp_id,omitempty"` // The ID of the SSO provider.
Code string `protobuf:"bytes,2,opt,name=code,proto3" json:"code,omitempty"` IdpId int32 `protobuf:"varint,1,opt,name=idp_id,json=idpId,proto3" json:"idp_id,omitempty"`
// The code to sign in with.
Code string `protobuf:"bytes,2,opt,name=code,proto3" json:"code,omitempty"`
// The redirect URI.
RedirectUri string `protobuf:"bytes,3,opt,name=redirect_uri,json=redirectUri,proto3" json:"redirect_uri,omitempty"` RedirectUri string `protobuf:"bytes,3,opt,name=redirect_uri,json=redirectUri,proto3" json:"redirect_uri,omitempty"`
} }
...@@ -331,7 +337,9 @@ type SignUpRequest struct { ...@@ -331,7 +337,9 @@ type SignUpRequest struct {
sizeCache protoimpl.SizeCache sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields unknownFields protoimpl.UnknownFields
// The username to sign up with.
Username string `protobuf:"bytes,1,opt,name=username,proto3" json:"username,omitempty"` Username string `protobuf:"bytes,1,opt,name=username,proto3" json:"username,omitempty"`
// The password to sign up with.
Password string `protobuf:"bytes,2,opt,name=password,proto3" json:"password,omitempty"` Password string `protobuf:"bytes,2,opt,name=password,proto3" json:"password,omitempty"`
} }
......
...@@ -958,7 +958,7 @@ var file_api_v2_idp_service_proto_rawDesc = []byte{ ...@@ -958,7 +958,7 @@ var file_api_v2_idp_service_proto_rawDesc = []byte{
0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d,
0x65, 0x22, 0x20, 0x0a, 0x1e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x65, 0x22, 0x20, 0x0a, 0x1e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x49, 0x64, 0x65, 0x6e, 0x74,
0x69, 0x74, 0x79, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x69, 0x74, 0x79, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f,
0x6e, 0x73, 0x65, 0x32, 0xf8, 0x06, 0x0a, 0x17, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x6e, 0x73, 0x65, 0x32, 0x8b, 0x07, 0x0a, 0x17, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79,
0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12,
0x93, 0x01, 0x0a, 0x15, 0x4c, 0x69, 0x73, 0x74, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x93, 0x01, 0x0a, 0x15, 0x4c, 0x69, 0x73, 0x74, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79,
0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x73, 0x12, 0x2a, 0x2e, 0x6d, 0x65, 0x6d, 0x6f, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x73, 0x12, 0x2a, 0x2e, 0x6d, 0x65, 0x6d, 0x6f,
...@@ -979,52 +979,54 @@ var file_api_v2_idp_service_proto_rawDesc = []byte{ ...@@ -979,52 +979,54 @@ var file_api_v2_idp_service_proto_rawDesc = []byte{
0x73, 0x65, 0x22, 0x31, 0xda, 0x41, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x73, 0x65, 0x22, 0x31, 0xda, 0x41, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x82, 0xd3, 0xe4, 0x93, 0x02,
0x24, 0x12, 0x22, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x76, 0x32, 0x2f, 0x7b, 0x6e, 0x61, 0x6d, 0x65, 0x24, 0x12, 0x22, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x76, 0x32, 0x2f, 0x7b, 0x6e, 0x61, 0x6d, 0x65,
0x3d, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x3d, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65,
0x72, 0x73, 0x2f, 0x2a, 0x7d, 0x12, 0x96, 0x01, 0x0a, 0x16, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x72, 0x73, 0x2f, 0x2a, 0x7d, 0x12, 0xa9, 0x01, 0x0a, 0x16, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65,
0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72,
0x12, 0x2b, 0x2e, 0x6d, 0x65, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x32, 0x2e, 0x12, 0x2b, 0x2e, 0x6d, 0x65, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x32, 0x2e,
0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x50, 0x72, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x50, 0x72,
0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e,
0x6d, 0x65, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x32, 0x2e, 0x43, 0x72, 0x65, 0x6d, 0x65, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x32, 0x2e, 0x43, 0x72, 0x65,
0x61, 0x74, 0x65, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x61, 0x74, 0x65, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x50, 0x72, 0x6f, 0x76, 0x69,
0x64, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x21, 0x82, 0xd3, 0xe4, 0x64, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x34, 0x82, 0xd3, 0xe4,
0x93, 0x02, 0x1b, 0x22, 0x19, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x76, 0x32, 0x2f, 0x69, 0x64, 0x65, 0x93, 0x02, 0x2e, 0x3a, 0x11, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x5f, 0x70, 0x72,
0x6e, 0x74, 0x69, 0x74, 0x79, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x73, 0x12, 0xe4, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x22, 0x19, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x76, 0x32, 0x2f,
0x01, 0x0a, 0x16, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72,
0x79, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x12, 0x2b, 0x2e, 0x6d, 0x65, 0x6d, 0x6f, 0x73, 0x12, 0xe4, 0x01, 0x0a, 0x16, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x49, 0x64, 0x65, 0x6e,
0x74, 0x69, 0x74, 0x79, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x12, 0x2b, 0x2e, 0x6d,
0x65, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x32, 0x2e, 0x55, 0x70, 0x64, 0x61,
0x74, 0x65, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64,
0x65, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x6d, 0x65, 0x6d, 0x6f,
0x73, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x32, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x49, 0x73, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x32, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x49,
0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x52, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x52,
0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x6d, 0x65, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x6f, 0xda, 0x41, 0x1d, 0x69, 0x64, 0x65, 0x6e,
0x70, 0x69, 0x2e, 0x76, 0x32, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x5f, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x2c, 0x75, 0x70,
0x74, 0x69, 0x74, 0x79, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x64, 0x61, 0x74, 0x65, 0x5f, 0x6d, 0x61, 0x73, 0x6b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x49, 0x3a,
0x6f, 0x6e, 0x73, 0x65, 0x22, 0x6f, 0xda, 0x41, 0x1d, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x11, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x5f, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64,
0x79, 0x5f, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x2c, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x72, 0x32, 0x34, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x76, 0x32, 0x2f, 0x7b, 0x69, 0x64, 0x65,
0x65, 0x5f, 0x6d, 0x61, 0x73, 0x6b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x49, 0x3a, 0x11, 0x69, 0x64, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x5f, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x2e, 0x6e,
0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x5f, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x32, 0x61, 0x6d, 0x65, 0x3d, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x50, 0x72, 0x6f, 0x76,
0x34, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x76, 0x32, 0x2f, 0x7b, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x69, 0x64, 0x65, 0x72, 0x73, 0x2f, 0x2a, 0x7d, 0x12, 0xa6, 0x01, 0x0a, 0x16, 0x44, 0x65, 0x6c,
0x74, 0x79, 0x5f, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x2e, 0x6e, 0x61, 0x6d, 0x65,
0x3d, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65,
0x72, 0x73, 0x2f, 0x2a, 0x7d, 0x12, 0xa6, 0x01, 0x0a, 0x16, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65,
0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72,
0x12, 0x2b, 0x2e, 0x6d, 0x65, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x32, 0x2e,
0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x50, 0x72,
0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e,
0x6d, 0x65, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x32, 0x2e, 0x44, 0x65, 0x6c,
0x65, 0x74, 0x65, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x65, 0x74, 0x65, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x50, 0x72, 0x6f, 0x76, 0x69,
0x64, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x31, 0xda, 0x41, 0x04, 0x64, 0x65, 0x72, 0x12, 0x2b, 0x2e, 0x6d, 0x65, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x70, 0x69, 0x2e,
0x6e, 0x61, 0x6d, 0x65, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x24, 0x2a, 0x22, 0x2f, 0x61, 0x70, 0x69, 0x76, 0x32, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74,
0x2f, 0x76, 0x32, 0x2f, 0x7b, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x79, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74,
0x74, 0x79, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x73, 0x2f, 0x2a, 0x7d, 0x42, 0xa7, 0x1a, 0x2c, 0x2e, 0x6d, 0x65, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x32, 0x2e,
0x01, 0x0a, 0x10, 0x63, 0x6f, 0x6d, 0x2e, 0x6d, 0x65, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x70, 0x69, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x50, 0x72,
0x2e, 0x76, 0x32, 0x42, 0x0f, 0x49, 0x64, 0x70, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x50, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x31,
0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x30, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0xda, 0x41, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x24, 0x2a, 0x22, 0x2f,
0x6f, 0x6d, 0x2f, 0x75, 0x73, 0x65, 0x6d, 0x65, 0x6d, 0x6f, 0x73, 0x2f, 0x6d, 0x65, 0x6d, 0x6f, 0x61, 0x70, 0x69, 0x2f, 0x76, 0x32, 0x2f, 0x7b, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x69, 0x64, 0x65,
0x73, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x65, 0x6e, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x73, 0x2f, 0x2a,
0x76, 0x32, 0x3b, 0x61, 0x70, 0x69, 0x76, 0x32, 0xa2, 0x02, 0x03, 0x4d, 0x41, 0x58, 0xaa, 0x02, 0x7d, 0x42, 0xa7, 0x01, 0x0a, 0x10, 0x63, 0x6f, 0x6d, 0x2e, 0x6d, 0x65, 0x6d, 0x6f, 0x73, 0x2e,
0x0c, 0x4d, 0x65, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x70, 0x69, 0x2e, 0x56, 0x32, 0xca, 0x02, 0x0c, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x32, 0x42, 0x0f, 0x49, 0x64, 0x70, 0x53, 0x65, 0x72, 0x76, 0x69,
0x4d, 0x65, 0x6d, 0x6f, 0x73, 0x5c, 0x41, 0x70, 0x69, 0x5c, 0x56, 0x32, 0xe2, 0x02, 0x18, 0x4d, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x30, 0x67, 0x69, 0x74, 0x68, 0x75,
0x65, 0x6d, 0x6f, 0x73, 0x5c, 0x41, 0x70, 0x69, 0x5c, 0x56, 0x32, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x75, 0x73, 0x65, 0x6d, 0x65, 0x6d, 0x6f, 0x73, 0x2f, 0x6d,
0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x0e, 0x4d, 0x65, 0x6d, 0x6f, 0x73, 0x3a, 0x65, 0x6d, 0x6f, 0x73, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x65, 0x6e, 0x2f, 0x61,
0x3a, 0x41, 0x70, 0x69, 0x3a, 0x3a, 0x56, 0x32, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, 0x70, 0x69, 0x2f, 0x76, 0x32, 0x3b, 0x61, 0x70, 0x69, 0x76, 0x32, 0xa2, 0x02, 0x03, 0x4d, 0x41,
0x58, 0xaa, 0x02, 0x0c, 0x4d, 0x65, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x70, 0x69, 0x2e, 0x56, 0x32,
0xca, 0x02, 0x0c, 0x4d, 0x65, 0x6d, 0x6f, 0x73, 0x5c, 0x41, 0x70, 0x69, 0x5c, 0x56, 0x32, 0xe2,
0x02, 0x18, 0x4d, 0x65, 0x6d, 0x6f, 0x73, 0x5c, 0x41, 0x70, 0x69, 0x5c, 0x56, 0x32, 0x5c, 0x47,
0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x0e, 0x4d, 0x65, 0x6d,
0x6f, 0x73, 0x3a, 0x3a, 0x41, 0x70, 0x69, 0x3a, 0x3a, 0x56, 0x32, 0x62, 0x06, 0x70, 0x72, 0x6f,
0x74, 0x6f, 0x33,
} }
var ( var (
......
...@@ -101,18 +101,15 @@ func local_request_IdentityProviderService_GetIdentityProvider_0(ctx context.Con ...@@ -101,18 +101,15 @@ func local_request_IdentityProviderService_GetIdentityProvider_0(ctx context.Con
} }
var (
filter_IdentityProviderService_CreateIdentityProvider_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)}
)
func request_IdentityProviderService_CreateIdentityProvider_0(ctx context.Context, marshaler runtime.Marshaler, client IdentityProviderServiceClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { func request_IdentityProviderService_CreateIdentityProvider_0(ctx context.Context, marshaler runtime.Marshaler, client IdentityProviderServiceClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
var protoReq CreateIdentityProviderRequest var protoReq CreateIdentityProviderRequest
var metadata runtime.ServerMetadata var metadata runtime.ServerMetadata
if err := req.ParseForm(); err != nil { newReader, berr := utilities.IOReaderFactory(req.Body)
return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) if berr != nil {
return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)
} }
if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_IdentityProviderService_CreateIdentityProvider_0); err != nil { if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.IdentityProvider); err != nil && err != io.EOF {
return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)
} }
...@@ -125,10 +122,11 @@ func local_request_IdentityProviderService_CreateIdentityProvider_0(ctx context. ...@@ -125,10 +122,11 @@ func local_request_IdentityProviderService_CreateIdentityProvider_0(ctx context.
var protoReq CreateIdentityProviderRequest var protoReq CreateIdentityProviderRequest
var metadata runtime.ServerMetadata var metadata runtime.ServerMetadata
if err := req.ParseForm(); err != nil { newReader, berr := utilities.IOReaderFactory(req.Body)
return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) if berr != nil {
return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)
} }
if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_IdentityProviderService_CreateIdentityProvider_0); err != nil { if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.IdentityProvider); err != nil && err != io.EOF {
return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)
} }
......
...@@ -30,8 +30,11 @@ const ( ...@@ -30,8 +30,11 @@ const (
// //
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
type IdentityProviderServiceClient interface { type IdentityProviderServiceClient interface {
// ListIdentityProviders lists identity providers.
ListIdentityProviders(ctx context.Context, in *ListIdentityProvidersRequest, opts ...grpc.CallOption) (*ListIdentityProvidersResponse, error) ListIdentityProviders(ctx context.Context, in *ListIdentityProvidersRequest, opts ...grpc.CallOption) (*ListIdentityProvidersResponse, error)
// GetIdentityProvider gets an identity provider.
GetIdentityProvider(ctx context.Context, in *GetIdentityProviderRequest, opts ...grpc.CallOption) (*GetIdentityProviderResponse, error) GetIdentityProvider(ctx context.Context, in *GetIdentityProviderRequest, opts ...grpc.CallOption) (*GetIdentityProviderResponse, error)
// CreateIdentityProvider creates an identity provider.
CreateIdentityProvider(ctx context.Context, in *CreateIdentityProviderRequest, opts ...grpc.CallOption) (*CreateIdentityProviderResponse, error) CreateIdentityProvider(ctx context.Context, in *CreateIdentityProviderRequest, opts ...grpc.CallOption) (*CreateIdentityProviderResponse, error)
// UpdateIdentityProvider updates an identity provider. // UpdateIdentityProvider updates an identity provider.
UpdateIdentityProvider(ctx context.Context, in *UpdateIdentityProviderRequest, opts ...grpc.CallOption) (*UpdateIdentityProviderResponse, error) UpdateIdentityProvider(ctx context.Context, in *UpdateIdentityProviderRequest, opts ...grpc.CallOption) (*UpdateIdentityProviderResponse, error)
...@@ -96,8 +99,11 @@ func (c *identityProviderServiceClient) DeleteIdentityProvider(ctx context.Conte ...@@ -96,8 +99,11 @@ func (c *identityProviderServiceClient) DeleteIdentityProvider(ctx context.Conte
// All implementations must embed UnimplementedIdentityProviderServiceServer // All implementations must embed UnimplementedIdentityProviderServiceServer
// for forward compatibility // for forward compatibility
type IdentityProviderServiceServer interface { type IdentityProviderServiceServer interface {
// ListIdentityProviders lists identity providers.
ListIdentityProviders(context.Context, *ListIdentityProvidersRequest) (*ListIdentityProvidersResponse, error) ListIdentityProviders(context.Context, *ListIdentityProvidersRequest) (*ListIdentityProvidersResponse, error)
// GetIdentityProvider gets an identity provider.
GetIdentityProvider(context.Context, *GetIdentityProviderRequest) (*GetIdentityProviderResponse, error) GetIdentityProvider(context.Context, *GetIdentityProviderRequest) (*GetIdentityProviderResponse, error)
// CreateIdentityProvider creates an identity provider.
CreateIdentityProvider(context.Context, *CreateIdentityProviderRequest) (*CreateIdentityProviderResponse, error) CreateIdentityProvider(context.Context, *CreateIdentityProviderRequest) (*CreateIdentityProviderResponse, error)
// UpdateIdentityProvider updates an identity provider. // UpdateIdentityProvider updates an identity provider.
UpdateIdentityProvider(context.Context, *UpdateIdentityProviderRequest) (*UpdateIdentityProviderResponse, error) UpdateIdentityProvider(context.Context, *UpdateIdentityProviderRequest) (*UpdateIdentityProviderResponse, error)
......
...@@ -200,27 +200,26 @@ var file_api_v2_link_service_proto_rawDesc = []byte{ ...@@ -200,27 +200,26 @@ var file_api_v2_link_service_proto_rawDesc = []byte{
0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x64, 0x65, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x64, 0x65,
0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x69, 0x6d, 0x61, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x69, 0x6d, 0x61,
0x67, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x32, 0x67, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x32,
0x8c, 0x01, 0x0a, 0x0b, 0x4c, 0x69, 0x6e, 0x6b, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x8b, 0x01, 0x0a, 0x0b, 0x4c, 0x69, 0x6e, 0x6b, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12,
0x7d, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x4c, 0x69, 0x6e, 0x6b, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x7c, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x4c, 0x69, 0x6e, 0x6b, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61,
0x74, 0x61, 0x12, 0x24, 0x2e, 0x6d, 0x65, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x74, 0x61, 0x12, 0x24, 0x2e, 0x6d, 0x65, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76,
0x32, 0x2e, 0x47, 0x65, 0x74, 0x4c, 0x69, 0x6e, 0x6b, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x32, 0x2e, 0x47, 0x65, 0x74, 0x4c, 0x69, 0x6e, 0x6b, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74,
0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x25, 0x2e, 0x6d, 0x65, 0x6d, 0x6f, 0x73, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x25, 0x2e, 0x6d, 0x65, 0x6d, 0x6f, 0x73,
0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x32, 0x2e, 0x47, 0x65, 0x74, 0x4c, 0x69, 0x6e, 0x6b, 0x4d, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x32, 0x2e, 0x47, 0x65, 0x74, 0x4c, 0x69, 0x6e, 0x6b, 0x4d,
0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22,
0x1d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x17, 0x12, 0x15, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x76, 0x32, 0x1c, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x16, 0x12, 0x14, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x76, 0x32,
0x2f, 0x6c, 0x69, 0x6e, 0x6b, 0x5f, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x42, 0xa8, 0x2f, 0x6c, 0x69, 0x6e, 0x6b, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x42, 0xa8, 0x01,
0x01, 0x0a, 0x10, 0x63, 0x6f, 0x6d, 0x2e, 0x6d, 0x65, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x70, 0x69, 0x0a, 0x10, 0x63, 0x6f, 0x6d, 0x2e, 0x6d, 0x65, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x70, 0x69, 0x2e,
0x2e, 0x76, 0x32, 0x42, 0x10, 0x4c, 0x69, 0x6e, 0x6b, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x76, 0x32, 0x42, 0x10, 0x4c, 0x69, 0x6e, 0x6b, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x50,
0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x30, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x30, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63,
0x63, 0x6f, 0x6d, 0x2f, 0x75, 0x73, 0x65, 0x6d, 0x65, 0x6d, 0x6f, 0x73, 0x2f, 0x6d, 0x65, 0x6d, 0x6f, 0x6d, 0x2f, 0x75, 0x73, 0x65, 0x6d, 0x65, 0x6d, 0x6f, 0x73, 0x2f, 0x6d, 0x65, 0x6d, 0x6f,
0x6f, 0x73, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x65, 0x6e, 0x2f, 0x61, 0x70, 0x69, 0x73, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x65, 0x6e, 0x2f, 0x61, 0x70, 0x69, 0x2f,
0x2f, 0x76, 0x32, 0x3b, 0x61, 0x70, 0x69, 0x76, 0x32, 0xa2, 0x02, 0x03, 0x4d, 0x41, 0x58, 0xaa, 0x76, 0x32, 0x3b, 0x61, 0x70, 0x69, 0x76, 0x32, 0xa2, 0x02, 0x03, 0x4d, 0x41, 0x58, 0xaa, 0x02,
0x02, 0x0c, 0x4d, 0x65, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x70, 0x69, 0x2e, 0x56, 0x32, 0xca, 0x02, 0x0c, 0x4d, 0x65, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x70, 0x69, 0x2e, 0x56, 0x32, 0xca, 0x02, 0x0c,
0x0c, 0x4d, 0x65, 0x6d, 0x6f, 0x73, 0x5c, 0x41, 0x70, 0x69, 0x5c, 0x56, 0x32, 0xe2, 0x02, 0x18, 0x4d, 0x65, 0x6d, 0x6f, 0x73, 0x5c, 0x41, 0x70, 0x69, 0x5c, 0x56, 0x32, 0xe2, 0x02, 0x18, 0x4d,
0x4d, 0x65, 0x6d, 0x6f, 0x73, 0x5c, 0x41, 0x70, 0x69, 0x5c, 0x56, 0x32, 0x5c, 0x47, 0x50, 0x42, 0x65, 0x6d, 0x6f, 0x73, 0x5c, 0x41, 0x70, 0x69, 0x5c, 0x56, 0x32, 0x5c, 0x47, 0x50, 0x42, 0x4d,
0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x0e, 0x4d, 0x65, 0x6d, 0x6f, 0x73, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x0e, 0x4d, 0x65, 0x6d, 0x6f, 0x73, 0x3a,
0x3a, 0x3a, 0x41, 0x70, 0x69, 0x3a, 0x3a, 0x56, 0x32, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x3a, 0x41, 0x70, 0x69, 0x3a, 0x3a, 0x56, 0x32, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
0x33,
} }
var ( var (
......
...@@ -81,7 +81,7 @@ func RegisterLinkServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux ...@@ -81,7 +81,7 @@ func RegisterLinkServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
var err error var err error
var annotatedContext context.Context var annotatedContext context.Context
annotatedContext, err = runtime.AnnotateIncomingContext(ctx, mux, req, "/memos.api.v2.LinkService/GetLinkMetadata", runtime.WithHTTPPathPattern("/api/v2/link_metadata")) annotatedContext, err = runtime.AnnotateIncomingContext(ctx, mux, req, "/memos.api.v2.LinkService/GetLinkMetadata", runtime.WithHTTPPathPattern("/api/v2/linkMetadata"))
if err != nil { if err != nil {
runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
return return
...@@ -145,7 +145,7 @@ func RegisterLinkServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux ...@@ -145,7 +145,7 @@ func RegisterLinkServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
var err error var err error
var annotatedContext context.Context var annotatedContext context.Context
annotatedContext, err = runtime.AnnotateContext(ctx, mux, req, "/memos.api.v2.LinkService/GetLinkMetadata", runtime.WithHTTPPathPattern("/api/v2/link_metadata")) annotatedContext, err = runtime.AnnotateContext(ctx, mux, req, "/memos.api.v2.LinkService/GetLinkMetadata", runtime.WithHTTPPathPattern("/api/v2/linkMetadata"))
if err != nil { if err != nil {
runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
return return
...@@ -165,7 +165,7 @@ func RegisterLinkServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux ...@@ -165,7 +165,7 @@ func RegisterLinkServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux
} }
var ( var (
pattern_LinkService_GetLinkMetadata_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"api", "v2", "link_metadata"}, "")) pattern_LinkService_GetLinkMetadata_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"api", "v2", "linkMetadata"}, ""))
) )
var ( var (
......
...@@ -26,6 +26,7 @@ const ( ...@@ -26,6 +26,7 @@ const (
// //
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
type LinkServiceClient interface { type LinkServiceClient interface {
// GetLinkMetadata returns metadata for a given link.
GetLinkMetadata(ctx context.Context, in *GetLinkMetadataRequest, opts ...grpc.CallOption) (*GetLinkMetadataResponse, error) GetLinkMetadata(ctx context.Context, in *GetLinkMetadataRequest, opts ...grpc.CallOption) (*GetLinkMetadataResponse, error)
} }
...@@ -50,6 +51,7 @@ func (c *linkServiceClient) GetLinkMetadata(ctx context.Context, in *GetLinkMeta ...@@ -50,6 +51,7 @@ func (c *linkServiceClient) GetLinkMetadata(ctx context.Context, in *GetLinkMeta
// All implementations must embed UnimplementedLinkServiceServer // All implementations must embed UnimplementedLinkServiceServer
// for forward compatibility // for forward compatibility
type LinkServiceServer interface { type LinkServiceServer interface {
// GetLinkMetadata returns metadata for a given link.
GetLinkMetadata(context.Context, *GetLinkMetadataRequest) (*GetLinkMetadataResponse, error) GetLinkMetadata(context.Context, *GetLinkMetadataRequest) (*GetLinkMetadataResponse, error)
mustEmbedUnimplementedLinkServiceServer() mustEmbedUnimplementedLinkServiceServer()
} }
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
...@@ -31,18 +31,15 @@ var _ = runtime.String ...@@ -31,18 +31,15 @@ var _ = runtime.String
var _ = utilities.NewDoubleArray var _ = utilities.NewDoubleArray
var _ = metadata.Join var _ = metadata.Join
var (
filter_ResourceService_CreateResource_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)}
)
func request_ResourceService_CreateResource_0(ctx context.Context, marshaler runtime.Marshaler, client ResourceServiceClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { func request_ResourceService_CreateResource_0(ctx context.Context, marshaler runtime.Marshaler, client ResourceServiceClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
var protoReq CreateResourceRequest var protoReq CreateResourceRequest
var metadata runtime.ServerMetadata var metadata runtime.ServerMetadata
if err := req.ParseForm(); err != nil { newReader, berr := utilities.IOReaderFactory(req.Body)
return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) if berr != nil {
return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)
} }
if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_ResourceService_CreateResource_0); err != nil { if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Resource); err != nil && err != io.EOF {
return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)
} }
...@@ -55,10 +52,11 @@ func local_request_ResourceService_CreateResource_0(ctx context.Context, marshal ...@@ -55,10 +52,11 @@ func local_request_ResourceService_CreateResource_0(ctx context.Context, marshal
var protoReq CreateResourceRequest var protoReq CreateResourceRequest
var metadata runtime.ServerMetadata var metadata runtime.ServerMetadata
if err := req.ParseForm(); err != nil { newReader, berr := utilities.IOReaderFactory(req.Body)
return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) if berr != nil {
return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)
} }
if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_ResourceService_CreateResource_0); err != nil { if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Resource); err != nil && err != io.EOF {
return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)
} }
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment