From a55804bb4d60ac50e64aeaa74c4faa79abe18b03 Mon Sep 17 00:00:00 2001 From: Artem Gavrilov Date: Wed, 22 Jul 2020 19:12:53 +0200 Subject: [PATCH] SAAS-174 Add Percona Platform user password reset method --- .../platform_reset_password_parameters.go | 131 ++++++++ .../platform_reset_password_responses.go | 223 +++++++++++++ .../json/client/server/server_client.go | 35 ++ api/serverpb/json/serverpb.json | 76 +++++ api/serverpb/server.pb.go | 298 ++++++++++++------ api/serverpb/server.pb.gw.go | 78 +++++ api/serverpb/server.proto | 18 ++ api/serverpb/server.validator.pb.go | 9 + api/swagger/swagger.json | 76 +++++ 9 files changed, 852 insertions(+), 92 deletions(-) create mode 100644 api/serverpb/json/client/server/platform_reset_password_parameters.go create mode 100644 api/serverpb/json/client/server/platform_reset_password_responses.go diff --git a/api/serverpb/json/client/server/platform_reset_password_parameters.go b/api/serverpb/json/client/server/platform_reset_password_parameters.go new file mode 100644 index 00000000000..79515a918ac --- /dev/null +++ b/api/serverpb/json/client/server/platform_reset_password_parameters.go @@ -0,0 +1,131 @@ +// Code generated by go-swagger; DO NOT EDIT. + +package server + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" +) + +// NewPlatformResetPasswordParams creates a new PlatformResetPasswordParams object +// with the default values initialized. +func NewPlatformResetPasswordParams() *PlatformResetPasswordParams { + var () + return &PlatformResetPasswordParams{ + + timeout: cr.DefaultTimeout, + } +} + +// NewPlatformResetPasswordParamsWithTimeout creates a new PlatformResetPasswordParams object +// with the default values initialized, and the ability to set a timeout on a request +func NewPlatformResetPasswordParamsWithTimeout(timeout time.Duration) *PlatformResetPasswordParams { + var () + return &PlatformResetPasswordParams{ + + timeout: timeout, + } +} + +// NewPlatformResetPasswordParamsWithContext creates a new PlatformResetPasswordParams object +// with the default values initialized, and the ability to set a context for a request +func NewPlatformResetPasswordParamsWithContext(ctx context.Context) *PlatformResetPasswordParams { + var () + return &PlatformResetPasswordParams{ + + Context: ctx, + } +} + +// NewPlatformResetPasswordParamsWithHTTPClient creates a new PlatformResetPasswordParams object +// with the default values initialized, and the ability to set a custom HTTPClient for a request +func NewPlatformResetPasswordParamsWithHTTPClient(client *http.Client) *PlatformResetPasswordParams { + var () + return &PlatformResetPasswordParams{ + HTTPClient: client, + } +} + +/*PlatformResetPasswordParams contains all the parameters to send to the API endpoint +for the platform reset password operation typically these are written to a http.Request +*/ +type PlatformResetPasswordParams struct { + + /*Body*/ + Body PlatformResetPasswordBody + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithTimeout adds the timeout to the platform reset password params +func (o *PlatformResetPasswordParams) WithTimeout(timeout time.Duration) *PlatformResetPasswordParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the platform reset password params +func (o *PlatformResetPasswordParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the platform reset password params +func (o *PlatformResetPasswordParams) WithContext(ctx context.Context) *PlatformResetPasswordParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the platform reset password params +func (o *PlatformResetPasswordParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the platform reset password params +func (o *PlatformResetPasswordParams) WithHTTPClient(client *http.Client) *PlatformResetPasswordParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the platform reset password params +func (o *PlatformResetPasswordParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithBody adds the body to the platform reset password params +func (o *PlatformResetPasswordParams) WithBody(body PlatformResetPasswordBody) *PlatformResetPasswordParams { + o.SetBody(body) + return o +} + +// SetBody adds the body to the platform reset password params +func (o *PlatformResetPasswordParams) SetBody(body PlatformResetPasswordBody) { + o.Body = body +} + +// WriteToRequest writes these params to a swagger request +func (o *PlatformResetPasswordParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if err := r.SetBodyParam(o.Body); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/api/serverpb/json/client/server/platform_reset_password_responses.go b/api/serverpb/json/client/server/platform_reset_password_responses.go new file mode 100644 index 00000000000..424c0162545 --- /dev/null +++ b/api/serverpb/json/client/server/platform_reset_password_responses.go @@ -0,0 +1,223 @@ +// Code generated by go-swagger; DO NOT EDIT. + +package server + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// PlatformResetPasswordReader is a Reader for the PlatformResetPassword structure. +type PlatformResetPasswordReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *PlatformResetPasswordReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewPlatformResetPasswordOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + result := NewPlatformResetPasswordDefault(response.Code()) + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + if response.Code()/100 == 2 { + return result, nil + } + return nil, result + } +} + +// NewPlatformResetPasswordOK creates a PlatformResetPasswordOK with default headers values +func NewPlatformResetPasswordOK() *PlatformResetPasswordOK { + return &PlatformResetPasswordOK{} +} + +/*PlatformResetPasswordOK handles this case with default header values. + +A successful response. +*/ +type PlatformResetPasswordOK struct { + Payload interface{} +} + +func (o *PlatformResetPasswordOK) Error() string { + return fmt.Sprintf("[POST /v1/Platform/ResetPassword][%d] platformResetPasswordOk %+v", 200, o.Payload) +} + +func (o *PlatformResetPasswordOK) GetPayload() interface{} { + return o.Payload +} + +func (o *PlatformResetPasswordOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + // response payload + if err := consumer.Consume(response.Body(), &o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +// NewPlatformResetPasswordDefault creates a PlatformResetPasswordDefault with default headers values +func NewPlatformResetPasswordDefault(code int) *PlatformResetPasswordDefault { + return &PlatformResetPasswordDefault{ + _statusCode: code, + } +} + +/*PlatformResetPasswordDefault handles this case with default header values. + +An unexpected error response +*/ +type PlatformResetPasswordDefault struct { + _statusCode int + + Payload *PlatformResetPasswordDefaultBody +} + +// Code gets the status code for the platform reset password default response +func (o *PlatformResetPasswordDefault) Code() int { + return o._statusCode +} + +func (o *PlatformResetPasswordDefault) Error() string { + return fmt.Sprintf("[POST /v1/Platform/ResetPassword][%d] PlatformResetPassword default %+v", o._statusCode, o.Payload) +} + +func (o *PlatformResetPasswordDefault) GetPayload() *PlatformResetPasswordDefaultBody { + return o.Payload +} + +func (o *PlatformResetPasswordDefault) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(PlatformResetPasswordDefaultBody) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +/*PlatformResetPasswordBody platform reset password body +swagger:model PlatformResetPasswordBody +*/ +type PlatformResetPasswordBody struct { + + // Existing Percona Platform user's email. + Email string `json:"email,omitempty"` +} + +// Validate validates this platform reset password body +func (o *PlatformResetPasswordBody) Validate(formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (o *PlatformResetPasswordBody) MarshalBinary() ([]byte, error) { + if o == nil { + return nil, nil + } + return swag.WriteJSON(o) +} + +// UnmarshalBinary interface implementation +func (o *PlatformResetPasswordBody) UnmarshalBinary(b []byte) error { + var res PlatformResetPasswordBody + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *o = res + return nil +} + +/*PlatformResetPasswordDefaultBody platform reset password default body +swagger:model PlatformResetPasswordDefaultBody +*/ +type PlatformResetPasswordDefaultBody struct { + + // error + Error string `json:"error,omitempty"` + + // code + Code int32 `json:"code,omitempty"` + + // message + Message string `json:"message,omitempty"` + + // details + Details []*DetailsItems0 `json:"details"` +} + +// Validate validates this platform reset password default body +func (o *PlatformResetPasswordDefaultBody) Validate(formats strfmt.Registry) error { + var res []error + + if err := o.validateDetails(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (o *PlatformResetPasswordDefaultBody) validateDetails(formats strfmt.Registry) error { + + if swag.IsZero(o.Details) { // not required + return nil + } + + for i := 0; i < len(o.Details); i++ { + if swag.IsZero(o.Details[i]) { // not required + continue + } + + if o.Details[i] != nil { + if err := o.Details[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("PlatformResetPassword default" + "." + "details" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// MarshalBinary interface implementation +func (o *PlatformResetPasswordDefaultBody) MarshalBinary() ([]byte, error) { + if o == nil { + return nil, nil + } + return swag.WriteJSON(o) +} + +// UnmarshalBinary interface implementation +func (o *PlatformResetPasswordDefaultBody) UnmarshalBinary(b []byte) error { + var res PlatformResetPasswordDefaultBody + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *o = res + return nil +} diff --git a/api/serverpb/json/client/server/server_client.go b/api/serverpb/json/client/server/server_client.go index ac5e54e3774..e57a780b886 100644 --- a/api/serverpb/json/client/server/server_client.go +++ b/api/serverpb/json/client/server/server_client.go @@ -37,6 +37,8 @@ type ClientService interface { Logs(params *LogsParams, writer io.Writer) (*LogsOK, error) + PlatformResetPassword(params *PlatformResetPasswordParams) (*PlatformResetPasswordOK, error) + PlatformSignIn(params *PlatformSignInParams) (*PlatformSignInOK, error) PlatformSignUp(params *PlatformSignUpParams) (*PlatformSignUpOK, error) @@ -217,6 +219,39 @@ func (a *Client) Logs(params *LogsParams, writer io.Writer) (*LogsOK, error) { return nil, runtime.NewAPIError("unexpected success response: content available as default response in error", unexpectedSuccess, unexpectedSuccess.Code()) } +/* + PlatformResetPassword platforms reset password initiates password restore procedure +*/ +func (a *Client) PlatformResetPassword(params *PlatformResetPasswordParams) (*PlatformResetPasswordOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewPlatformResetPasswordParams() + } + + result, err := a.transport.Submit(&runtime.ClientOperation{ + ID: "PlatformResetPassword", + Method: "POST", + PathPattern: "/v1/Platform/ResetPassword", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http", "https"}, + Params: params, + Reader: &PlatformResetPasswordReader{formats: a.formats}, + Context: params.Context, + Client: params.HTTPClient, + }) + if err != nil { + return nil, err + } + success, ok := result.(*PlatformResetPasswordOK) + if ok { + return success, nil + } + // unexpected success response + unexpectedSuccess := result.(*PlatformResetPasswordDefault) + return nil, runtime.NewAPIError("unexpected success response: content available as default response in error", unexpectedSuccess, unexpectedSuccess.Code()) +} + /* PlatformSignIn platforms sign in links that PMM instance to percona platform user */ diff --git a/api/serverpb/json/serverpb.json b/api/serverpb/json/serverpb.json index 52226a75f9a..167d1800b8f 100644 --- a/api/serverpb/json/serverpb.json +++ b/api/serverpb/json/serverpb.json @@ -130,6 +130,82 @@ } } }, + "/v1/Platform/ResetPassword": { + "post": { + "tags": [ + "Server" + ], + "summary": "PlatformResetPassword initiates password restore procedure.", + "operationId": "PlatformResetPassword", + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "type": "object", + "properties": { + "email": { + "description": "Existing Percona Platform user's email.", + "type": "string", + "x-order": 0 + } + } + } + } + ], + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "type": "object" + } + }, + "default": { + "description": "An unexpected error response", + "schema": { + "type": "object", + "properties": { + "code": { + "type": "integer", + "format": "int32", + "x-order": 1 + }, + "details": { + "type": "array", + "items": { + "description": "`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n Foo foo = ...;\n Any any;\n any.PackFrom(foo);\n ...\n if (any.UnpackTo(\u0026foo)) {\n ...\n }\n\nExample 2: Pack and unpack a message in Java.\n\n Foo foo = ...;\n Any any = Any.pack(foo);\n ...\n if (any.is(Foo.class)) {\n foo = any.unpack(Foo.class);\n }\n\n Example 3: Pack and unpack a message in Python.\n\n foo = Foo(...)\n any = Any()\n any.Pack(foo)\n ...\n if any.Is(Foo.DESCRIPTOR):\n any.Unpack(foo)\n ...\n\n Example 4: Pack and unpack a message in Go\n\n foo := \u0026pb.Foo{...}\n any, err := ptypes.MarshalAny(foo)\n ...\n foo := \u0026pb.Foo{}\n if err := ptypes.UnmarshalAny(any, foo); err != nil {\n ...\n }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\n\nJSON\n====\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n package google.profile;\n message Person {\n string first_name = 1;\n string last_name = 2;\n }\n\n {\n \"@type\": \"type.googleapis.com/google.profile.Person\",\n \"firstName\": \u003cstring\u003e,\n \"lastName\": \u003cstring\u003e\n }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n {\n \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n \"value\": \"1.212s\"\n }", + "type": "object", + "properties": { + "type_url": { + "description": "A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n URL, or have them precompiled into a binary to avoid any\n lookup. Therefore, binary compatibility needs to be preserved\n on changes to types. (Use versioned type names to manage\n breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics.", + "type": "string", + "x-order": 0 + }, + "value": { + "description": "Must be a valid serialized protocol buffer of the above specified type.", + "type": "string", + "format": "byte", + "x-order": 1 + } + } + }, + "x-order": 3 + }, + "error": { + "type": "string", + "x-order": 0 + }, + "message": { + "type": "string", + "x-order": 2 + } + } + } + } + } + } + }, "/v1/Platform/SignIn": { "post": { "tags": [ diff --git a/api/serverpb/server.pb.go b/api/serverpb/server.pb.go index 02b9a18a36c..df428c9cc12 100644 --- a/api/serverpb/server.pb.go +++ b/api/serverpb/server.pb.go @@ -1237,6 +1237,77 @@ func (m *PlatformSignInResponse) XXX_DiscardUnknown() { var xxx_messageInfo_PlatformSignInResponse proto.InternalMessageInfo +type PlatformResetPasswordRequest struct { + // Existing Percona Platform user's email. + Email string `protobuf:"bytes,1,opt,name=email,proto3" json:"email,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *PlatformResetPasswordRequest) Reset() { *m = PlatformResetPasswordRequest{} } +func (m *PlatformResetPasswordRequest) String() string { return proto.CompactTextString(m) } +func (*PlatformResetPasswordRequest) ProtoMessage() {} +func (*PlatformResetPasswordRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_9202d8f598083902, []int{23} +} + +func (m *PlatformResetPasswordRequest) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_PlatformResetPasswordRequest.Unmarshal(m, b) +} +func (m *PlatformResetPasswordRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_PlatformResetPasswordRequest.Marshal(b, m, deterministic) +} +func (m *PlatformResetPasswordRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_PlatformResetPasswordRequest.Merge(m, src) +} +func (m *PlatformResetPasswordRequest) XXX_Size() int { + return xxx_messageInfo_PlatformResetPasswordRequest.Size(m) +} +func (m *PlatformResetPasswordRequest) XXX_DiscardUnknown() { + xxx_messageInfo_PlatformResetPasswordRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_PlatformResetPasswordRequest proto.InternalMessageInfo + +func (m *PlatformResetPasswordRequest) GetEmail() string { + if m != nil { + return m.Email + } + return "" +} + +type PlatformResetPasswordResponse struct { + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *PlatformResetPasswordResponse) Reset() { *m = PlatformResetPasswordResponse{} } +func (m *PlatformResetPasswordResponse) String() string { return proto.CompactTextString(m) } +func (*PlatformResetPasswordResponse) ProtoMessage() {} +func (*PlatformResetPasswordResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_9202d8f598083902, []int{24} +} + +func (m *PlatformResetPasswordResponse) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_PlatformResetPasswordResponse.Unmarshal(m, b) +} +func (m *PlatformResetPasswordResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_PlatformResetPasswordResponse.Marshal(b, m, deterministic) +} +func (m *PlatformResetPasswordResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_PlatformResetPasswordResponse.Merge(m, src) +} +func (m *PlatformResetPasswordResponse) XXX_Size() int { + return xxx_messageInfo_PlatformResetPasswordResponse.Size(m) +} +func (m *PlatformResetPasswordResponse) XXX_DiscardUnknown() { + xxx_messageInfo_PlatformResetPasswordResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_PlatformResetPasswordResponse proto.InternalMessageInfo + func init() { proto.RegisterEnum("server.DistributionMethod", DistributionMethod_name, DistributionMethod_value) proto.RegisterType((*VersionInfo)(nil), "server.VersionInfo") @@ -1262,103 +1333,108 @@ func init() { proto.RegisterType((*PlatformSignUpResponse)(nil), "server.PlatformSignUpResponse") proto.RegisterType((*PlatformSignInRequest)(nil), "server.PlatformSignInRequest") proto.RegisterType((*PlatformSignInResponse)(nil), "server.PlatformSignInResponse") + proto.RegisterType((*PlatformResetPasswordRequest)(nil), "server.PlatformResetPasswordRequest") + proto.RegisterType((*PlatformResetPasswordResponse)(nil), "server.PlatformResetPasswordResponse") } func init() { proto.RegisterFile("serverpb/server.proto", fileDescriptor_9202d8f598083902) } var fileDescriptor_9202d8f598083902 = []byte{ - // 1441 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe4, 0x58, 0x49, 0x6f, 0x1b, 0xc7, - 0x12, 0x7e, 0xa4, 0x6c, 0x89, 0x2c, 0x6a, 0xa1, 0x9a, 0x5a, 0xc6, 0x94, 0x64, 0xe9, 0x0d, 0x60, - 0x3f, 0x59, 0xb6, 0x44, 0x58, 0x0f, 0xc8, 0xe2, 0x5c, 0xa2, 0xcd, 0x0e, 0x61, 0xcb, 0x72, 0x86, - 0x92, 0x13, 0xe4, 0x32, 0x68, 0x71, 0x9a, 0xc3, 0x81, 0x66, 0x61, 0xba, 0x9b, 0x22, 0x94, 0x63, - 0xe0, 0x7f, 0x10, 0x04, 0xc8, 0xcf, 0x0a, 0x90, 0xe4, 0x1c, 0x20, 0xc8, 0x0f, 0x09, 0x7a, 0x1b, - 0x6e, 0x23, 0x3a, 0x48, 0x72, 0xcb, 0x49, 0xec, 0xaa, 0xaf, 0xeb, 0xeb, 0xaa, 0xfe, 0xba, 0xa6, - 0x20, 0x58, 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 0x2d, 0x38, 0x0b, 0xca, 0x7e, 0x60, 0xcc, 0xe8, 0x21, 0x2c, 0xa8, 0x4d, 0x6e, 0x4c, 0x7a, 0xcc, - 0xed, 0xd2, 0x50, 0x96, 0xb0, 0xe8, 0xcc, 0x29, 0xf3, 0x6b, 0xd2, 0x63, 0x17, 0x34, 0x44, 0x1f, - 0x03, 0x84, 0x98, 0x71, 0xb7, 0x29, 0xf2, 0xb1, 0xee, 0xbe, 0x5f, 0x5b, 0x02, 0x2d, 0x93, 0xb7, - 0x97, 0x00, 0x35, 0x38, 0xa6, 0x5c, 0x55, 0xc1, 0x94, 0xb7, 0x01, 0x95, 0x21, 0xab, 0x2e, 0xcd, - 0x06, 0x00, 0xee, 0xf2, 0xb6, 0xcb, 0x93, 0x2b, 0x62, 0xf4, 0x54, 0x14, 0x96, 0x73, 0x61, 0x10, - 0xee, 0x30, 0xf1, 0xdd, 0xa4, 0xd5, 0x62, 0x44, 0x95, 0x62, 0xce, 0x29, 0x86, 0x89, 0x7f, 0x26, - 0x0d, 0x22, 0xa8, 0x8a, 0xd7, 0xe0, 0x98, 0x77, 0xd3, 0xeb, 0xf9, 0x7b, 0x41, 0x5b, 0xb0, 0x34, - 0x1c, 0x54, 0x1f, 0x75, 0x0d, 0x04, 0xc8, 0x0d, 0x85, 0x42, 0xac, 0xdc, 0xd6, 0xd4, 0x76, 0xd1, - 0x29, 0x84, 0x89, 0xff, 0x4a, 0xac, 0xdf, 0x13, 0x13, 0x21, 0xb8, 0xe3, 0x25, 0xb1, 0xb9, 0x15, - 0xf9, 0xdb, 0xfe, 0x3e, 0x07, 0xe8, 0x94, 0x70, 0x1a, 0x34, 0x05, 0x47, 0x12, 0x4a, 0x81, 0x32, - 0xf4, 0x08, 0xf2, 0x6d, 0xaa, 0x55, 0x72, 0x6f, 0xac, 0xe2, 0xc7, 0xba, 0x3b, 0x39, 0xf9, 0x36, - 0x15, 0xd0, 0xc8, 0xbc, 0xb5, 0x49, 0xd0, 0x48, 0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0x4d, 0xa1, 0x9f, 0x68, 0x66, 0xff, 0xe9, 0x27, 0x7a, 0x4b, 0x2f, 0x19, 0x4a, 0xd4, - 0x60, 0x6a, 0x0a, 0x94, 0x41, 0x58, 0x8f, 0xb3, 0x09, 0xd3, 0x1e, 0x94, 0x4d, 0xd8, 0xef, 0x27, - 0x13, 0x08, 0xeb, 0xf1, 0xb3, 0xdc, 0xce, 0x21, 0x7c, 0x55, 0x30, 0xff, 0x00, 0xb8, 0x9c, 0x96, - 0x5f, 0xdc, 0xff, 0xff, 0x11, 0x00, 0x00, 0xff, 0xff, 0x5e, 0xb5, 0x3c, 0x04, 0x13, 0x10, 0x00, - 0x00, + // 1494 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe4, 0x58, 0x5b, 0x6f, 0x1b, 0x45, + 0x14, 0xc6, 0x4e, 0x9b, 0xd8, 0xc7, 0xb9, 0x38, 0xe3, 0x5c, 0xdc, 0x4d, 0x52, 0x87, 0x15, 0x29, + 0x69, 0xda, 0xc4, 0x6a, 0x90, 0xb8, 0x14, 0x1e, 0xc8, 0xad, 0xc5, 0x6a, 0xd3, 0x94, 0x75, 0x52, + 0x10, 0x2f, 0xab, 0x89, 0x77, 0xbc, 0x5e, 0x65, 0x2f, 0x66, 0x67, 0x6c, 0x2b, 0x3c, 0xa2, 0xbe, + 0xf1, 0x88, 0xf8, 0x0b, 0xfc, 0x1e, 0x24, 0xe0, 0x19, 0x09, 0xf1, 0x43, 0xd0, 0xdc, 0xd6, 0xb7, + 0x75, 0x5a, 0x01, 0x6f, 0x3c, 0xc5, 0x73, 0xce, 0x37, 0xe7, 0x9b, 0x73, 0xe6, 0x9b, 0xb3, 0x47, + 0x81, 0x65, 0x4a, 0xe2, 0x2e, 0x89, 0xdb, 0x97, 0x55, 0xf9, 0x63, 0xaf, 0x1d, 0x47, 0x2c, 0x42, + 0xd3, 0x72, 0x65, 0x7c, 0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x19, 0x58, 0x48, 0x80, + 0xb4, 0x1d, 0x85, 0x94, 0xdc, 0x70, 0xe4, 0x07, 0xa0, 0xee, 0x4a, 0x1c, 0xb6, 0xb0, 0x5f, 0xda, + 0x53, 0x17, 0x39, 0x90, 0xb1, 0xa5, 0x20, 0x68, 0x17, 0x66, 0x02, 0x1c, 0x62, 0x97, 0x38, 0xea, + 0xe8, 0xa9, 0x68, 0x8d, 0x41, 0xcf, 0xa0, 0xe4, 0x78, 0x94, 0xc5, 0xde, 0x65, 0x87, 0xd7, 0xd3, + 0x0e, 0x08, 0x6b, 0x45, 0x4e, 0xf9, 0xd6, 0x66, 0x66, 0x7b, 0x7e, 0xdf, 0xd0, 0x5b, 0x8f, 0x07, + 0x20, 0xa7, 0x02, 0x61, 0x21, 0x67, 0xcc, 0x66, 0x22, 0x28, 0x5a, 0x04, 0x3b, 0x5e, 0x48, 0x28, + 0x55, 0x05, 0x30, 0x4b, 0xb0, 0x38, 0x60, 0x93, 0xb9, 0x9a, 0x0f, 0xa0, 0x74, 0xd4, 0x22, 0x8d, + 0xab, 0x8b, 0xb6, 0x83, 0x19, 0xa1, 0x03, 0xc5, 0x6a, 0x46, 0x71, 0x83, 0x88, 0x02, 0xe4, 0x2c, + 0xb9, 0x30, 0x5f, 0x67, 0x61, 0x69, 0x18, 0xad, 0x2a, 0xf6, 0x08, 0xf2, 0x5e, 0x48, 0x19, 0xf6, + 0x7d, 0xe2, 0x88, 0x2d, 0x13, 0x92, 0xed, 0xa3, 0x78, 0x29, 0x7d, 0x1e, 0x83, 0xdd, 0x58, 0x4a, + 0x09, 0x41, 0xf7, 0xa1, 0xd8, 0x11, 0x94, 0x36, 0xee, 0x62, 0xcf, 0xc7, 0x97, 0x3e, 0x11, 0x35, + 0xcd, 0x59, 0x0b, 0xd2, 0x7e, 0xa0, 0xcd, 0xe8, 0x1e, 0x2c, 0xc8, 0x4d, 0x76, 0x48, 0x7a, 0xd4, + 0xee, 0xc4, 0xbe, 0x28, 0x61,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0xc9, 0x80, 0x88, 0xca, + 0x7a, 0xeb, 0xe8, 0x1c, 0x69, 0xdc, 0x49, 0xf1, 0xa8, 0xb0, 0x48, 0x84, 0x9d, 0x45, 0xc0, 0xc3, + 0xc6, 0x04, 0x3b, 0xd7, 0xdf, 0x21, 0x17, 0x66, 0x07, 0x67, 0x46, 0xb4, 0xa6, 0xb7, 0xa7, 0xcc, + 0x9d, 0xc6, 0x7a, 0xba, 0x53, 0x85, 0x5f, 0x17, 0xe1, 0x57, 0xcc, 0x45, 0x1e, 0x5e, 0x39, 0xab, + 0x02, 0xf9, 0x38, 0xb3, 0x83, 0x1c, 0x28, 0x0c, 0x0c, 0x60, 0x28, 0xe9, 0x91, 0xe3, 0xb3, 0x9a, + 0xb1, 0x96, 0xea, 0xbb, 0x89, 0x45, 0x00, 0x39, 0x4b, 0x0b, 0x66, 0x07, 0x87, 0xa7, 0x7e, 0x3a, + 0x29, 0x73, 0x5a, 0x3f, 0x9d, 0xb4, 0x79, 0xcb, 0xdc, 0x10, 0x44, 0xab, 0x26, 0x1a, 0x21, 0x62, + 0x1d, 0xca, 0x99, 0x1a, 0x50, 0x18, 0xf8, 0x70, 0xf5, 0xf3, 0x19, 0xff, 0xc6, 0xf5, 0xf3, 0x49, + 0xf9, 0xd2, 0x99, 0x6b, 0x82, 0x66, 0xd9, 0x2c, 0x72, 0x1a, 0xed, 0xad, 0x3e, 0x25, 0x22, 0x9d, + 0x08, 0xe6, 0x87, 0xbb, 0x10, 0xda, 0xe8, 0x5f, 0x41, 0xca, 0xf7, 0xce, 0xb8, 0x3b, 0xc9, 0xad, + 0xd8, 0xee, 0x0a, 0xb6, 0xb2, 0x59, 0x1a, 0x62, 0x93, 0x60, 0x4e, 0xd8, 0x85, 0xe2, 0x68, 0xab, + 0x41, 0x15, 0x1d, 0x73, 0x42, 0x23, 0x33, 0x36, 0x27, 0x03, 0x14, 0x6d, 0x45, 0xd0, 0xde, 0x31, + 0x97, 0x38, 0xed, 0x28, 0x4a, 0x25, 0x3a, 0xdc, 0x73, 0xfa, 0x89, 0xa6, 0xb6, 0xb7, 0x7e, 0xa2, + 0x13, 0x5a, 0xd5, 0x50, 0xa2, 0x1a, 0x53, 0x95, 0xa0, 0x14, 0xc2, 0x5a, 0x98, 0x4e, 0x98, 0xb4, + 0xb8, 0x74, 0xc2, 0x81, 0x76, 0x35, 0x99, 0xb0, 0x16, 0x72, 0xc2, 0x1f, 0x32, 0xfd, 0xe6, 0x39, + 0xd4, 0x91, 0xd0, 0x7b, 0xa3, 0x91, 0xd3, 0xda, 0x9d, 0xb1, 0xf5, 0x06, 0x94, 0x3a, 0xc6, 0x96, + 0x38, 0x46, 0xc5, 0x34, 0x86, 0x8e, 0x31, 0x84, 0x7d, 0x9c, 0xd9, 0x39, 0x84, 0x6f, 0x72, 0xfa, + 0xbf, 0x1d, 0x97, 0xd3, 0x62, 0xbc, 0xf8, 0xe0, 0xef, 0x00, 0x00, 0x00, 0xff, 0xff, 0x23, 0xff, + 0x52, 0x30, 0x00, 0x11, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -1394,6 +1470,8 @@ type ServerClient interface { PlatformSignUp(ctx context.Context, in *PlatformSignUpRequest, opts ...grpc.CallOption) (*PlatformSignUpResponse, error) // PlatformSignIn links that PMM instance to Percona Platform user. PlatformSignIn(ctx context.Context, in *PlatformSignInRequest, opts ...grpc.CallOption) (*PlatformSignInResponse, error) + // PlatformResetPassword initiates password restore procedure. + PlatformResetPassword(ctx context.Context, in *PlatformResetPasswordRequest, opts ...grpc.CallOption) (*PlatformResetPasswordResponse, error) } type serverClient struct { @@ -1494,6 +1572,15 @@ func (c *serverClient) PlatformSignIn(ctx context.Context, in *PlatformSignInReq return out, nil } +func (c *serverClient) PlatformResetPassword(ctx context.Context, in *PlatformResetPasswordRequest, opts ...grpc.CallOption) (*PlatformResetPasswordResponse, error) { + out := new(PlatformResetPasswordResponse) + err := c.cc.Invoke(ctx, "/server.Server/PlatformResetPassword", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + // ServerServer is the server API for Server service. type ServerServer interface { // Version returns PMM Server versions. @@ -1517,6 +1604,8 @@ type ServerServer interface { PlatformSignUp(context.Context, *PlatformSignUpRequest) (*PlatformSignUpResponse, error) // PlatformSignIn links that PMM instance to Percona Platform user. PlatformSignIn(context.Context, *PlatformSignInRequest) (*PlatformSignInResponse, error) + // PlatformResetPassword initiates password restore procedure. + PlatformResetPassword(context.Context, *PlatformResetPasswordRequest) (*PlatformResetPasswordResponse, error) } // UnimplementedServerServer can be embedded to have forward compatible implementations. @@ -1553,6 +1642,9 @@ func (*UnimplementedServerServer) PlatformSignUp(ctx context.Context, req *Platf func (*UnimplementedServerServer) PlatformSignIn(ctx context.Context, req *PlatformSignInRequest) (*PlatformSignInResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method PlatformSignIn not implemented") } +func (*UnimplementedServerServer) PlatformResetPassword(ctx context.Context, req *PlatformResetPasswordRequest) (*PlatformResetPasswordResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method PlatformResetPassword not implemented") +} func RegisterServerServer(s *grpc.Server, srv ServerServer) { s.RegisterService(&_Server_serviceDesc, srv) @@ -1738,6 +1830,24 @@ func _Server_PlatformSignIn_Handler(srv interface{}, ctx context.Context, dec fu return interceptor(ctx, in, info, handler) } +func _Server_PlatformResetPassword_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(PlatformResetPasswordRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(ServerServer).PlatformResetPassword(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/server.Server/PlatformResetPassword", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(ServerServer).PlatformResetPassword(ctx, req.(*PlatformResetPasswordRequest)) + } + return interceptor(ctx, in, info, handler) +} + var _Server_serviceDesc = grpc.ServiceDesc{ ServiceName: "server.Server", HandlerType: (*ServerServer)(nil), @@ -1782,6 +1892,10 @@ var _Server_serviceDesc = grpc.ServiceDesc{ MethodName: "PlatformSignIn", Handler: _Server_PlatformSignIn_Handler, }, + { + MethodName: "PlatformResetPassword", + Handler: _Server_PlatformResetPassword_Handler, + }, }, Streams: []grpc.StreamDesc{}, Metadata: "serverpb/server.proto", diff --git a/api/serverpb/server.pb.gw.go b/api/serverpb/server.pb.gw.go index 05ca175443e..ff88a7d2fd5 100644 --- a/api/serverpb/server.pb.gw.go +++ b/api/serverpb/server.pb.gw.go @@ -354,6 +354,40 @@ func local_request_Server_PlatformSignIn_0(ctx context.Context, marshaler runtim } +func request_Server_PlatformResetPassword_0(ctx context.Context, marshaler runtime.Marshaler, client ServerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq PlatformResetPasswordRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.PlatformResetPassword(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_Server_PlatformResetPassword_0(ctx context.Context, marshaler runtime.Marshaler, server ServerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq PlatformResetPasswordRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.PlatformResetPassword(ctx, &protoReq) + return msg, metadata, err + +} + // RegisterServerHandlerServer registers the http handlers for service Server to "mux". // UnaryRPC :call ServerServer directly. // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. @@ -559,6 +593,26 @@ func RegisterServerHandlerServer(ctx context.Context, mux *runtime.ServeMux, ser }) + mux.Handle("POST", pattern_Server_PlatformResetPassword_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_Server_PlatformResetPassword_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Server_PlatformResetPassword_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + return nil } @@ -800,6 +854,26 @@ func RegisterServerHandlerClient(ctx context.Context, mux *runtime.ServeMux, cli }) + mux.Handle("POST", pattern_Server_PlatformResetPassword_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_Server_PlatformResetPassword_0(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Server_PlatformResetPassword_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + return nil } @@ -823,6 +897,8 @@ var ( pattern_Server_PlatformSignUp_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "Platform", "SignUp"}, "", runtime.AssumeColonVerbOpt(true))) pattern_Server_PlatformSignIn_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "Platform", "SignIn"}, "", runtime.AssumeColonVerbOpt(true))) + + pattern_Server_PlatformResetPassword_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "Platform", "ResetPassword"}, "", runtime.AssumeColonVerbOpt(true))) ) var ( @@ -845,4 +921,6 @@ var ( forward_Server_PlatformSignUp_0 = runtime.ForwardResponseMessage forward_Server_PlatformSignIn_0 = runtime.ForwardResponseMessage + + forward_Server_PlatformResetPassword_0 = runtime.ForwardResponseMessage ) diff --git a/api/serverpb/server.proto b/api/serverpb/server.proto index 50d14596b8c..74ca112403c 100644 --- a/api/serverpb/server.proto +++ b/api/serverpb/server.proto @@ -189,6 +189,17 @@ message PlatformSignInRequest { message PlatformSignInResponse {} +message PlatformResetPasswordRequest { + // Existing Percona Platform user's email. + string email = 1 [ + (validator.field) = { + string_not_empty: true + } + ]; +} + +message PlatformResetPasswordResponse {} + // Server service provides generic PMM Server public APIs. service Server { // Version returns PMM Server versions. @@ -260,4 +271,11 @@ service Server { body: "*" }; } + // PlatformResetPassword initiates password restore procedure. + rpc PlatformResetPassword(PlatformResetPasswordRequest) returns (PlatformResetPasswordResponse) { + option (google.api.http) = { + post: "/v1/Platform/ResetPassword" + body: "*" + }; + } } diff --git a/api/serverpb/server.validator.pb.go b/api/serverpb/server.validator.pb.go index c3c58f9880e..f943b88f4e3 100644 --- a/api/serverpb/server.validator.pb.go +++ b/api/serverpb/server.validator.pb.go @@ -173,3 +173,12 @@ func (this *PlatformSignInRequest) Validate() error { func (this *PlatformSignInResponse) Validate() error { return nil } +func (this *PlatformResetPasswordRequest) Validate() error { + if this.Email == "" { + return github_com_mwitkow_go_proto_validators.FieldError("Email", fmt.Errorf(`value '%v' must not be an empty string`, this.Email)) + } + return nil +} +func (this *PlatformResetPasswordResponse) Validate() error { + return nil +} diff --git a/api/swagger/swagger.json b/api/swagger/swagger.json index 1d9525e41b8..4e9c686cb93 100644 --- a/api/swagger/swagger.json +++ b/api/swagger/swagger.json @@ -130,6 +130,82 @@ } } }, + "/v1/Platform/ResetPassword": { + "post": { + "tags": [ + "Server" + ], + "summary": "PlatformResetPassword initiates password restore procedure.", + "operationId": "PlatformResetPassword", + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "type": "object", + "properties": { + "email": { + "description": "Existing Percona Platform user's email.", + "type": "string", + "x-order": 0 + } + } + } + } + ], + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "type": "object" + } + }, + "default": { + "description": "An unexpected error response", + "schema": { + "type": "object", + "properties": { + "error": { + "type": "string", + "x-order": 0 + }, + "code": { + "type": "integer", + "format": "int32", + "x-order": 1 + }, + "message": { + "type": "string", + "x-order": 2 + }, + "details": { + "type": "array", + "items": { + "description": "`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n Foo foo = ...;\n Any any;\n any.PackFrom(foo);\n ...\n if (any.UnpackTo(\u0026foo)) {\n ...\n }\n\nExample 2: Pack and unpack a message in Java.\n\n Foo foo = ...;\n Any any = Any.pack(foo);\n ...\n if (any.is(Foo.class)) {\n foo = any.unpack(Foo.class);\n }\n\n Example 3: Pack and unpack a message in Python.\n\n foo = Foo(...)\n any = Any()\n any.Pack(foo)\n ...\n if any.Is(Foo.DESCRIPTOR):\n any.Unpack(foo)\n ...\n\n Example 4: Pack and unpack a message in Go\n\n foo := \u0026pb.Foo{...}\n any, err := ptypes.MarshalAny(foo)\n ...\n foo := \u0026pb.Foo{}\n if err := ptypes.UnmarshalAny(any, foo); err != nil {\n ...\n }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\n\nJSON\n====\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n package google.profile;\n message Person {\n string first_name = 1;\n string last_name = 2;\n }\n\n {\n \"@type\": \"type.googleapis.com/google.profile.Person\",\n \"firstName\": \u003cstring\u003e,\n \"lastName\": \u003cstring\u003e\n }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n {\n \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n \"value\": \"1.212s\"\n }", + "type": "object", + "properties": { + "type_url": { + "description": "A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n URL, or have them precompiled into a binary to avoid any\n lookup. Therefore, binary compatibility needs to be preserved\n on changes to types. (Use versioned type names to manage\n breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics.", + "type": "string", + "x-order": 0 + }, + "value": { + "description": "Must be a valid serialized protocol buffer of the above specified type.", + "type": "string", + "format": "byte", + "x-order": 1 + } + } + }, + "x-order": 3 + } + } + } + } + } + } + }, "/v1/Platform/SignIn": { "post": { "tags": [