diff --git a/CHANGELOG.md b/CHANGELOG.md index 50770025..b56ba6ee 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # CHANGELOG +## v1.0.6 + +CHANGE: The `/overview` endpoint has been adjusted to include a new `remoteAgent` `boolean` on the `environment` instances, indicating whether or not the environment has an enrolled remote agent (https://github.com/openziti/zrok/issues/977) + ## v1.0.5 FEATURE: Initial support for zrok Agent remoting; new `zrok agent enroll` and `zrok agent unenroll` commands that establish opt-in remote Agent management facilities on a per-environment basis. The central API has been augmented to allow for remote control (creating shares and private access instances) of these agents; see the [remoting guide](https://docs.zrok.io/docs/guides/agent/remoting) for details (https://github.com/openziti/zrok/issues/967) diff --git a/controller/overview.go b/controller/overview.go index 00de1de4..f23b95d1 100644 --- a/controller/overview.go +++ b/controller/overview.go @@ -36,12 +36,19 @@ func (h *overviewHandler) Handle(_ metadata.OverviewParams, principal *rest_mode ovr := &rest_model_zrok.Overview{AccountLimited: accountLimited} for _, env := range envs { + remoteAgent, err := str.IsAgentEnrolledForEnvironment(env.Id, trx) + if err != nil { + logrus.Errorf("error checking agent enrollment for environment '%v' (%v): %v", env.ZId, principal.Email, err) + return metadata.NewOverviewInternalServerError() + } + ear := &rest_model_zrok.EnvironmentAndResources{ Environment: &rest_model_zrok.Environment{ Address: env.Address, Description: env.Description, Host: env.Host, ZID: env.ZId, + RemoteAgent: remoteAgent, Limited: accountLimited, CreatedAt: env.CreatedAt.UnixMilli(), UpdatedAt: env.UpdatedAt.UnixMilli(), diff --git a/rest_client_zrok/account/account_client.go b/rest_client_zrok/account/account_client.go index 5fda16b6..2f602875 100644 --- a/rest_client_zrok/account/account_client.go +++ b/rest_client_zrok/account/account_client.go @@ -9,7 +9,6 @@ import ( "fmt" "github.com/go-openapi/runtime" - httptransport "github.com/go-openapi/runtime/client" "github.com/go-openapi/strfmt" ) @@ -18,31 +17,6 @@ func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientServi return &Client{transport: transport, formats: formats} } -// New creates a new account API client with basic auth credentials. -// It takes the following parameters: -// - host: http host (github.com). -// - basePath: any base path for the API client ("/v1", "/v3"). -// - scheme: http scheme ("http", "https"). -// - user: user for basic authentication header. -// - password: password for basic authentication header. -func NewClientWithBasicAuth(host, basePath, scheme, user, password string) ClientService { - transport := httptransport.New(host, basePath, []string{scheme}) - transport.DefaultAuthentication = httptransport.BasicAuth(user, password) - return &Client{transport: transport, formats: strfmt.Default} -} - -// New creates a new account API client with a bearer token for authentication. -// It takes the following parameters: -// - host: http host (github.com). -// - basePath: any base path for the API client ("/v1", "/v3"). -// - scheme: http scheme ("http", "https"). -// - bearerToken: bearer token for Bearer authentication header. -func NewClientWithBearerToken(host, basePath, scheme, bearerToken string) ClientService { - transport := httptransport.New(host, basePath, []string{scheme}) - transport.DefaultAuthentication = httptransport.BearerToken(bearerToken) - return &Client{transport: transport, formats: strfmt.Default} -} - /* Client for account API */ @@ -51,53 +25,9 @@ type Client struct { formats strfmt.Registry } -// ClientOption may be used to customize the behavior of Client methods. +// ClientOption is the option for Client methods type ClientOption func(*runtime.ClientOperation) -// This client is generated with a few options you might find useful for your swagger spec. -// -// Feel free to add you own set of options. - -// WithContentType allows the client to force the Content-Type header -// to negotiate a specific Consumer from the server. -// -// You may use this option to set arbitrary extensions to your MIME media type. -func WithContentType(mime string) ClientOption { - return func(r *runtime.ClientOperation) { - r.ConsumesMediaTypes = []string{mime} - } -} - -// WithContentTypeApplicationJSON sets the Content-Type header to "application/json". -func WithContentTypeApplicationJSON(r *runtime.ClientOperation) { - r.ConsumesMediaTypes = []string{"application/json"} -} - -// WithContentTypeApplicationZrokV1JSON sets the Content-Type header to "application/zrok.v1+json". -func WithContentTypeApplicationZrokV1JSON(r *runtime.ClientOperation) { - r.ConsumesMediaTypes = []string{"application/zrok.v1+json"} -} - -// WithAccept allows the client to force the Accept header -// to negotiate a specific Producer from the server. -// -// You may use this option to set arbitrary extensions to your MIME media type. -func WithAccept(mime string) ClientOption { - return func(r *runtime.ClientOperation) { - r.ProducesMediaTypes = []string{mime} - } -} - -// WithAcceptApplicationJSON sets the Accept header to "application/json". -func WithAcceptApplicationJSON(r *runtime.ClientOperation) { - r.ProducesMediaTypes = []string{"application/json"} -} - -// WithAcceptApplicationZrokV1JSON sets the Accept header to "application/zrok.v1+json". -func WithAcceptApplicationZrokV1JSON(r *runtime.ClientOperation) { - r.ProducesMediaTypes = []string{"application/zrok.v1+json"} -} - // ClientService is the interface for Client methods type ClientService interface { ChangePassword(params *ChangePasswordParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*ChangePasswordOK, error) diff --git a/rest_client_zrok/account/change_password_responses.go b/rest_client_zrok/account/change_password_responses.go index 3d08dbc7..4d3f9fc7 100644 --- a/rest_client_zrok/account/change_password_responses.go +++ b/rest_client_zrok/account/change_password_responses.go @@ -7,7 +7,6 @@ package account import ( "context" - "encoding/json" "fmt" "io" @@ -105,11 +104,11 @@ func (o *ChangePasswordOK) Code() int { } func (o *ChangePasswordOK) Error() string { - return fmt.Sprintf("[POST /changePassword][%d] changePasswordOK", 200) + return fmt.Sprintf("[POST /changePassword][%d] changePasswordOK ", 200) } func (o *ChangePasswordOK) String() string { - return fmt.Sprintf("[POST /changePassword][%d] changePasswordOK", 200) + return fmt.Sprintf("[POST /changePassword][%d] changePasswordOK ", 200) } func (o *ChangePasswordOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -161,11 +160,11 @@ func (o *ChangePasswordBadRequest) Code() int { } func (o *ChangePasswordBadRequest) Error() string { - return fmt.Sprintf("[POST /changePassword][%d] changePasswordBadRequest", 400) + return fmt.Sprintf("[POST /changePassword][%d] changePasswordBadRequest ", 400) } func (o *ChangePasswordBadRequest) String() string { - return fmt.Sprintf("[POST /changePassword][%d] changePasswordBadRequest", 400) + return fmt.Sprintf("[POST /changePassword][%d] changePasswordBadRequest ", 400) } func (o *ChangePasswordBadRequest) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -217,11 +216,11 @@ func (o *ChangePasswordUnauthorized) Code() int { } func (o *ChangePasswordUnauthorized) Error() string { - return fmt.Sprintf("[POST /changePassword][%d] changePasswordUnauthorized", 401) + return fmt.Sprintf("[POST /changePassword][%d] changePasswordUnauthorized ", 401) } func (o *ChangePasswordUnauthorized) String() string { - return fmt.Sprintf("[POST /changePassword][%d] changePasswordUnauthorized", 401) + return fmt.Sprintf("[POST /changePassword][%d] changePasswordUnauthorized ", 401) } func (o *ChangePasswordUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -274,13 +273,11 @@ func (o *ChangePasswordUnprocessableEntity) Code() int { } func (o *ChangePasswordUnprocessableEntity) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /changePassword][%d] changePasswordUnprocessableEntity %s", 422, payload) + return fmt.Sprintf("[POST /changePassword][%d] changePasswordUnprocessableEntity %+v", 422, o.Payload) } func (o *ChangePasswordUnprocessableEntity) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /changePassword][%d] changePasswordUnprocessableEntity %s", 422, payload) + return fmt.Sprintf("[POST /changePassword][%d] changePasswordUnprocessableEntity %+v", 422, o.Payload) } func (o *ChangePasswordUnprocessableEntity) GetPayload() rest_model_zrok.ErrorMessage { @@ -341,11 +338,11 @@ func (o *ChangePasswordInternalServerError) Code() int { } func (o *ChangePasswordInternalServerError) Error() string { - return fmt.Sprintf("[POST /changePassword][%d] changePasswordInternalServerError", 500) + return fmt.Sprintf("[POST /changePassword][%d] changePasswordInternalServerError ", 500) } func (o *ChangePasswordInternalServerError) String() string { - return fmt.Sprintf("[POST /changePassword][%d] changePasswordInternalServerError", 500) + return fmt.Sprintf("[POST /changePassword][%d] changePasswordInternalServerError ", 500) } func (o *ChangePasswordInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/account/invite_responses.go b/rest_client_zrok/account/invite_responses.go index 10056ce2..c009cc6d 100644 --- a/rest_client_zrok/account/invite_responses.go +++ b/rest_client_zrok/account/invite_responses.go @@ -7,7 +7,6 @@ package account import ( "context" - "encoding/json" "fmt" "io" @@ -99,11 +98,11 @@ func (o *InviteCreated) Code() int { } func (o *InviteCreated) Error() string { - return fmt.Sprintf("[POST /invite][%d] inviteCreated", 201) + return fmt.Sprintf("[POST /invite][%d] inviteCreated ", 201) } func (o *InviteCreated) String() string { - return fmt.Sprintf("[POST /invite][%d] inviteCreated", 201) + return fmt.Sprintf("[POST /invite][%d] inviteCreated ", 201) } func (o *InviteCreated) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -156,13 +155,11 @@ func (o *InviteBadRequest) Code() int { } func (o *InviteBadRequest) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /invite][%d] inviteBadRequest %s", 400, payload) + return fmt.Sprintf("[POST /invite][%d] inviteBadRequest %+v", 400, o.Payload) } func (o *InviteBadRequest) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /invite][%d] inviteBadRequest %s", 400, payload) + return fmt.Sprintf("[POST /invite][%d] inviteBadRequest %+v", 400, o.Payload) } func (o *InviteBadRequest) GetPayload() rest_model_zrok.ErrorMessage { @@ -223,11 +220,11 @@ func (o *InviteUnauthorized) Code() int { } func (o *InviteUnauthorized) Error() string { - return fmt.Sprintf("[POST /invite][%d] inviteUnauthorized", 401) + return fmt.Sprintf("[POST /invite][%d] inviteUnauthorized ", 401) } func (o *InviteUnauthorized) String() string { - return fmt.Sprintf("[POST /invite][%d] inviteUnauthorized", 401) + return fmt.Sprintf("[POST /invite][%d] inviteUnauthorized ", 401) } func (o *InviteUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -279,11 +276,11 @@ func (o *InviteInternalServerError) Code() int { } func (o *InviteInternalServerError) Error() string { - return fmt.Sprintf("[POST /invite][%d] inviteInternalServerError", 500) + return fmt.Sprintf("[POST /invite][%d] inviteInternalServerError ", 500) } func (o *InviteInternalServerError) String() string { - return fmt.Sprintf("[POST /invite][%d] inviteInternalServerError", 500) + return fmt.Sprintf("[POST /invite][%d] inviteInternalServerError ", 500) } func (o *InviteInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/account/login_responses.go b/rest_client_zrok/account/login_responses.go index d9987a43..7a348ebc 100644 --- a/rest_client_zrok/account/login_responses.go +++ b/rest_client_zrok/account/login_responses.go @@ -7,7 +7,6 @@ package account import ( "context" - "encoding/json" "fmt" "io" @@ -86,13 +85,11 @@ func (o *LoginOK) Code() int { } func (o *LoginOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /login][%d] loginOK %s", 200, payload) + return fmt.Sprintf("[POST /login][%d] loginOK %+v", 200, o.Payload) } func (o *LoginOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /login][%d] loginOK %s", 200, payload) + return fmt.Sprintf("[POST /login][%d] loginOK %+v", 200, o.Payload) } func (o *LoginOK) GetPayload() string { @@ -153,11 +150,11 @@ func (o *LoginUnauthorized) Code() int { } func (o *LoginUnauthorized) Error() string { - return fmt.Sprintf("[POST /login][%d] loginUnauthorized", 401) + return fmt.Sprintf("[POST /login][%d] loginUnauthorized ", 401) } func (o *LoginUnauthorized) String() string { - return fmt.Sprintf("[POST /login][%d] loginUnauthorized", 401) + return fmt.Sprintf("[POST /login][%d] loginUnauthorized ", 401) } func (o *LoginUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/account/regenerate_account_token_responses.go b/rest_client_zrok/account/regenerate_account_token_responses.go index 46f77056..a2d57bec 100644 --- a/rest_client_zrok/account/regenerate_account_token_responses.go +++ b/rest_client_zrok/account/regenerate_account_token_responses.go @@ -7,7 +7,6 @@ package account import ( "context" - "encoding/json" "fmt" "io" @@ -92,13 +91,11 @@ func (o *RegenerateAccountTokenOK) Code() int { } func (o *RegenerateAccountTokenOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /regenerateAccountToken][%d] regenerateAccountTokenOK %s", 200, payload) + return fmt.Sprintf("[POST /regenerateAccountToken][%d] regenerateAccountTokenOK %+v", 200, o.Payload) } func (o *RegenerateAccountTokenOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /regenerateAccountToken][%d] regenerateAccountTokenOK %s", 200, payload) + return fmt.Sprintf("[POST /regenerateAccountToken][%d] regenerateAccountTokenOK %+v", 200, o.Payload) } func (o *RegenerateAccountTokenOK) GetPayload() *RegenerateAccountTokenOKBody { @@ -161,11 +158,11 @@ func (o *RegenerateAccountTokenNotFound) Code() int { } func (o *RegenerateAccountTokenNotFound) Error() string { - return fmt.Sprintf("[POST /regenerateAccountToken][%d] regenerateAccountTokenNotFound", 404) + return fmt.Sprintf("[POST /regenerateAccountToken][%d] regenerateAccountTokenNotFound ", 404) } func (o *RegenerateAccountTokenNotFound) String() string { - return fmt.Sprintf("[POST /regenerateAccountToken][%d] regenerateAccountTokenNotFound", 404) + return fmt.Sprintf("[POST /regenerateAccountToken][%d] regenerateAccountTokenNotFound ", 404) } func (o *RegenerateAccountTokenNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -217,11 +214,11 @@ func (o *RegenerateAccountTokenInternalServerError) Code() int { } func (o *RegenerateAccountTokenInternalServerError) Error() string { - return fmt.Sprintf("[POST /regenerateAccountToken][%d] regenerateAccountTokenInternalServerError", 500) + return fmt.Sprintf("[POST /regenerateAccountToken][%d] regenerateAccountTokenInternalServerError ", 500) } func (o *RegenerateAccountTokenInternalServerError) String() string { - return fmt.Sprintf("[POST /regenerateAccountToken][%d] regenerateAccountTokenInternalServerError", 500) + return fmt.Sprintf("[POST /regenerateAccountToken][%d] regenerateAccountTokenInternalServerError ", 500) } func (o *RegenerateAccountTokenInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/account/register_responses.go b/rest_client_zrok/account/register_responses.go index 031a0206..e283669f 100644 --- a/rest_client_zrok/account/register_responses.go +++ b/rest_client_zrok/account/register_responses.go @@ -7,7 +7,6 @@ package account import ( "context" - "encoding/json" "fmt" "io" @@ -100,13 +99,11 @@ func (o *RegisterOK) Code() int { } func (o *RegisterOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /register][%d] registerOK %s", 200, payload) + return fmt.Sprintf("[POST /register][%d] registerOK %+v", 200, o.Payload) } func (o *RegisterOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /register][%d] registerOK %s", 200, payload) + return fmt.Sprintf("[POST /register][%d] registerOK %+v", 200, o.Payload) } func (o *RegisterOK) GetPayload() *RegisterOKBody { @@ -169,11 +166,11 @@ func (o *RegisterNotFound) Code() int { } func (o *RegisterNotFound) Error() string { - return fmt.Sprintf("[POST /register][%d] registerNotFound", 404) + return fmt.Sprintf("[POST /register][%d] registerNotFound ", 404) } func (o *RegisterNotFound) String() string { - return fmt.Sprintf("[POST /register][%d] registerNotFound", 404) + return fmt.Sprintf("[POST /register][%d] registerNotFound ", 404) } func (o *RegisterNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -226,13 +223,11 @@ func (o *RegisterUnprocessableEntity) Code() int { } func (o *RegisterUnprocessableEntity) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /register][%d] registerUnprocessableEntity %s", 422, payload) + return fmt.Sprintf("[POST /register][%d] registerUnprocessableEntity %+v", 422, o.Payload) } func (o *RegisterUnprocessableEntity) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /register][%d] registerUnprocessableEntity %s", 422, payload) + return fmt.Sprintf("[POST /register][%d] registerUnprocessableEntity %+v", 422, o.Payload) } func (o *RegisterUnprocessableEntity) GetPayload() rest_model_zrok.ErrorMessage { @@ -293,11 +288,11 @@ func (o *RegisterInternalServerError) Code() int { } func (o *RegisterInternalServerError) Error() string { - return fmt.Sprintf("[POST /register][%d] registerInternalServerError", 500) + return fmt.Sprintf("[POST /register][%d] registerInternalServerError ", 500) } func (o *RegisterInternalServerError) String() string { - return fmt.Sprintf("[POST /register][%d] registerInternalServerError", 500) + return fmt.Sprintf("[POST /register][%d] registerInternalServerError ", 500) } func (o *RegisterInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/account/reset_password_request_responses.go b/rest_client_zrok/account/reset_password_request_responses.go index d799e89e..ac021614 100644 --- a/rest_client_zrok/account/reset_password_request_responses.go +++ b/rest_client_zrok/account/reset_password_request_responses.go @@ -89,11 +89,11 @@ func (o *ResetPasswordRequestCreated) Code() int { } func (o *ResetPasswordRequestCreated) Error() string { - return fmt.Sprintf("[POST /resetPasswordRequest][%d] resetPasswordRequestCreated", 201) + return fmt.Sprintf("[POST /resetPasswordRequest][%d] resetPasswordRequestCreated ", 201) } func (o *ResetPasswordRequestCreated) String() string { - return fmt.Sprintf("[POST /resetPasswordRequest][%d] resetPasswordRequestCreated", 201) + return fmt.Sprintf("[POST /resetPasswordRequest][%d] resetPasswordRequestCreated ", 201) } func (o *ResetPasswordRequestCreated) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -145,11 +145,11 @@ func (o *ResetPasswordRequestBadRequest) Code() int { } func (o *ResetPasswordRequestBadRequest) Error() string { - return fmt.Sprintf("[POST /resetPasswordRequest][%d] resetPasswordRequestBadRequest", 400) + return fmt.Sprintf("[POST /resetPasswordRequest][%d] resetPasswordRequestBadRequest ", 400) } func (o *ResetPasswordRequestBadRequest) String() string { - return fmt.Sprintf("[POST /resetPasswordRequest][%d] resetPasswordRequestBadRequest", 400) + return fmt.Sprintf("[POST /resetPasswordRequest][%d] resetPasswordRequestBadRequest ", 400) } func (o *ResetPasswordRequestBadRequest) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -201,11 +201,11 @@ func (o *ResetPasswordRequestInternalServerError) Code() int { } func (o *ResetPasswordRequestInternalServerError) Error() string { - return fmt.Sprintf("[POST /resetPasswordRequest][%d] resetPasswordRequestInternalServerError", 500) + return fmt.Sprintf("[POST /resetPasswordRequest][%d] resetPasswordRequestInternalServerError ", 500) } func (o *ResetPasswordRequestInternalServerError) String() string { - return fmt.Sprintf("[POST /resetPasswordRequest][%d] resetPasswordRequestInternalServerError", 500) + return fmt.Sprintf("[POST /resetPasswordRequest][%d] resetPasswordRequestInternalServerError ", 500) } func (o *ResetPasswordRequestInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/account/reset_password_responses.go b/rest_client_zrok/account/reset_password_responses.go index 5c63b039..7b095fdf 100644 --- a/rest_client_zrok/account/reset_password_responses.go +++ b/rest_client_zrok/account/reset_password_responses.go @@ -7,7 +7,6 @@ package account import ( "context" - "encoding/json" "fmt" "io" @@ -99,11 +98,11 @@ func (o *ResetPasswordOK) Code() int { } func (o *ResetPasswordOK) Error() string { - return fmt.Sprintf("[POST /resetPassword][%d] resetPasswordOK", 200) + return fmt.Sprintf("[POST /resetPassword][%d] resetPasswordOK ", 200) } func (o *ResetPasswordOK) String() string { - return fmt.Sprintf("[POST /resetPassword][%d] resetPasswordOK", 200) + return fmt.Sprintf("[POST /resetPassword][%d] resetPasswordOK ", 200) } func (o *ResetPasswordOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -155,11 +154,11 @@ func (o *ResetPasswordNotFound) Code() int { } func (o *ResetPasswordNotFound) Error() string { - return fmt.Sprintf("[POST /resetPassword][%d] resetPasswordNotFound", 404) + return fmt.Sprintf("[POST /resetPassword][%d] resetPasswordNotFound ", 404) } func (o *ResetPasswordNotFound) String() string { - return fmt.Sprintf("[POST /resetPassword][%d] resetPasswordNotFound", 404) + return fmt.Sprintf("[POST /resetPassword][%d] resetPasswordNotFound ", 404) } func (o *ResetPasswordNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -212,13 +211,11 @@ func (o *ResetPasswordUnprocessableEntity) Code() int { } func (o *ResetPasswordUnprocessableEntity) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /resetPassword][%d] resetPasswordUnprocessableEntity %s", 422, payload) + return fmt.Sprintf("[POST /resetPassword][%d] resetPasswordUnprocessableEntity %+v", 422, o.Payload) } func (o *ResetPasswordUnprocessableEntity) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /resetPassword][%d] resetPasswordUnprocessableEntity %s", 422, payload) + return fmt.Sprintf("[POST /resetPassword][%d] resetPasswordUnprocessableEntity %+v", 422, o.Payload) } func (o *ResetPasswordUnprocessableEntity) GetPayload() rest_model_zrok.ErrorMessage { @@ -279,11 +276,11 @@ func (o *ResetPasswordInternalServerError) Code() int { } func (o *ResetPasswordInternalServerError) Error() string { - return fmt.Sprintf("[POST /resetPassword][%d] resetPasswordInternalServerError", 500) + return fmt.Sprintf("[POST /resetPassword][%d] resetPasswordInternalServerError ", 500) } func (o *ResetPasswordInternalServerError) String() string { - return fmt.Sprintf("[POST /resetPassword][%d] resetPasswordInternalServerError", 500) + return fmt.Sprintf("[POST /resetPassword][%d] resetPasswordInternalServerError ", 500) } func (o *ResetPasswordInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/account/verify_responses.go b/rest_client_zrok/account/verify_responses.go index c79e0088..13051959 100644 --- a/rest_client_zrok/account/verify_responses.go +++ b/rest_client_zrok/account/verify_responses.go @@ -7,7 +7,6 @@ package account import ( "context" - "encoding/json" "fmt" "io" @@ -92,13 +91,11 @@ func (o *VerifyOK) Code() int { } func (o *VerifyOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /verify][%d] verifyOK %s", 200, payload) + return fmt.Sprintf("[POST /verify][%d] verifyOK %+v", 200, o.Payload) } func (o *VerifyOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /verify][%d] verifyOK %s", 200, payload) + return fmt.Sprintf("[POST /verify][%d] verifyOK %+v", 200, o.Payload) } func (o *VerifyOK) GetPayload() *VerifyOKBody { @@ -161,11 +158,11 @@ func (o *VerifyNotFound) Code() int { } func (o *VerifyNotFound) Error() string { - return fmt.Sprintf("[POST /verify][%d] verifyNotFound", 404) + return fmt.Sprintf("[POST /verify][%d] verifyNotFound ", 404) } func (o *VerifyNotFound) String() string { - return fmt.Sprintf("[POST /verify][%d] verifyNotFound", 404) + return fmt.Sprintf("[POST /verify][%d] verifyNotFound ", 404) } func (o *VerifyNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -217,11 +214,11 @@ func (o *VerifyInternalServerError) Code() int { } func (o *VerifyInternalServerError) Error() string { - return fmt.Sprintf("[POST /verify][%d] verifyInternalServerError", 500) + return fmt.Sprintf("[POST /verify][%d] verifyInternalServerError ", 500) } func (o *VerifyInternalServerError) String() string { - return fmt.Sprintf("[POST /verify][%d] verifyInternalServerError", 500) + return fmt.Sprintf("[POST /verify][%d] verifyInternalServerError ", 500) } func (o *VerifyInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/admin/add_organization_member_responses.go b/rest_client_zrok/admin/add_organization_member_responses.go index a290cf70..da8500fa 100644 --- a/rest_client_zrok/admin/add_organization_member_responses.go +++ b/rest_client_zrok/admin/add_organization_member_responses.go @@ -95,11 +95,11 @@ func (o *AddOrganizationMemberCreated) Code() int { } func (o *AddOrganizationMemberCreated) Error() string { - return fmt.Sprintf("[POST /organization/add][%d] addOrganizationMemberCreated", 201) + return fmt.Sprintf("[POST /organization/add][%d] addOrganizationMemberCreated ", 201) } func (o *AddOrganizationMemberCreated) String() string { - return fmt.Sprintf("[POST /organization/add][%d] addOrganizationMemberCreated", 201) + return fmt.Sprintf("[POST /organization/add][%d] addOrganizationMemberCreated ", 201) } func (o *AddOrganizationMemberCreated) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -151,11 +151,11 @@ func (o *AddOrganizationMemberUnauthorized) Code() int { } func (o *AddOrganizationMemberUnauthorized) Error() string { - return fmt.Sprintf("[POST /organization/add][%d] addOrganizationMemberUnauthorized", 401) + return fmt.Sprintf("[POST /organization/add][%d] addOrganizationMemberUnauthorized ", 401) } func (o *AddOrganizationMemberUnauthorized) String() string { - return fmt.Sprintf("[POST /organization/add][%d] addOrganizationMemberUnauthorized", 401) + return fmt.Sprintf("[POST /organization/add][%d] addOrganizationMemberUnauthorized ", 401) } func (o *AddOrganizationMemberUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -207,11 +207,11 @@ func (o *AddOrganizationMemberNotFound) Code() int { } func (o *AddOrganizationMemberNotFound) Error() string { - return fmt.Sprintf("[POST /organization/add][%d] addOrganizationMemberNotFound", 404) + return fmt.Sprintf("[POST /organization/add][%d] addOrganizationMemberNotFound ", 404) } func (o *AddOrganizationMemberNotFound) String() string { - return fmt.Sprintf("[POST /organization/add][%d] addOrganizationMemberNotFound", 404) + return fmt.Sprintf("[POST /organization/add][%d] addOrganizationMemberNotFound ", 404) } func (o *AddOrganizationMemberNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -263,11 +263,11 @@ func (o *AddOrganizationMemberInternalServerError) Code() int { } func (o *AddOrganizationMemberInternalServerError) Error() string { - return fmt.Sprintf("[POST /organization/add][%d] addOrganizationMemberInternalServerError", 500) + return fmt.Sprintf("[POST /organization/add][%d] addOrganizationMemberInternalServerError ", 500) } func (o *AddOrganizationMemberInternalServerError) String() string { - return fmt.Sprintf("[POST /organization/add][%d] addOrganizationMemberInternalServerError", 500) + return fmt.Sprintf("[POST /organization/add][%d] addOrganizationMemberInternalServerError ", 500) } func (o *AddOrganizationMemberInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/admin/admin_client.go b/rest_client_zrok/admin/admin_client.go index 0bfa7ebe..e8597a63 100644 --- a/rest_client_zrok/admin/admin_client.go +++ b/rest_client_zrok/admin/admin_client.go @@ -9,7 +9,6 @@ import ( "fmt" "github.com/go-openapi/runtime" - httptransport "github.com/go-openapi/runtime/client" "github.com/go-openapi/strfmt" ) @@ -18,31 +17,6 @@ func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientServi return &Client{transport: transport, formats: formats} } -// New creates a new admin API client with basic auth credentials. -// It takes the following parameters: -// - host: http host (github.com). -// - basePath: any base path for the API client ("/v1", "/v3"). -// - scheme: http scheme ("http", "https"). -// - user: user for basic authentication header. -// - password: password for basic authentication header. -func NewClientWithBasicAuth(host, basePath, scheme, user, password string) ClientService { - transport := httptransport.New(host, basePath, []string{scheme}) - transport.DefaultAuthentication = httptransport.BasicAuth(user, password) - return &Client{transport: transport, formats: strfmt.Default} -} - -// New creates a new admin API client with a bearer token for authentication. -// It takes the following parameters: -// - host: http host (github.com). -// - basePath: any base path for the API client ("/v1", "/v3"). -// - scheme: http scheme ("http", "https"). -// - bearerToken: bearer token for Bearer authentication header. -func NewClientWithBearerToken(host, basePath, scheme, bearerToken string) ClientService { - transport := httptransport.New(host, basePath, []string{scheme}) - transport.DefaultAuthentication = httptransport.BearerToken(bearerToken) - return &Client{transport: transport, formats: strfmt.Default} -} - /* Client for admin API */ @@ -51,53 +25,9 @@ type Client struct { formats strfmt.Registry } -// ClientOption may be used to customize the behavior of Client methods. +// ClientOption is the option for Client methods type ClientOption func(*runtime.ClientOperation) -// This client is generated with a few options you might find useful for your swagger spec. -// -// Feel free to add you own set of options. - -// WithContentType allows the client to force the Content-Type header -// to negotiate a specific Consumer from the server. -// -// You may use this option to set arbitrary extensions to your MIME media type. -func WithContentType(mime string) ClientOption { - return func(r *runtime.ClientOperation) { - r.ConsumesMediaTypes = []string{mime} - } -} - -// WithContentTypeApplicationJSON sets the Content-Type header to "application/json". -func WithContentTypeApplicationJSON(r *runtime.ClientOperation) { - r.ConsumesMediaTypes = []string{"application/json"} -} - -// WithContentTypeApplicationZrokV1JSON sets the Content-Type header to "application/zrok.v1+json". -func WithContentTypeApplicationZrokV1JSON(r *runtime.ClientOperation) { - r.ConsumesMediaTypes = []string{"application/zrok.v1+json"} -} - -// WithAccept allows the client to force the Accept header -// to negotiate a specific Producer from the server. -// -// You may use this option to set arbitrary extensions to your MIME media type. -func WithAccept(mime string) ClientOption { - return func(r *runtime.ClientOperation) { - r.ProducesMediaTypes = []string{mime} - } -} - -// WithAcceptApplicationJSON sets the Accept header to "application/json". -func WithAcceptApplicationJSON(r *runtime.ClientOperation) { - r.ProducesMediaTypes = []string{"application/json"} -} - -// WithAcceptApplicationZrokV1JSON sets the Accept header to "application/zrok.v1+json". -func WithAcceptApplicationZrokV1JSON(r *runtime.ClientOperation) { - r.ProducesMediaTypes = []string{"application/zrok.v1+json"} -} - // ClientService is the interface for Client methods type ClientService interface { AddOrganizationMember(params *AddOrganizationMemberParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*AddOrganizationMemberCreated, error) diff --git a/rest_client_zrok/admin/create_account_responses.go b/rest_client_zrok/admin/create_account_responses.go index f64322f6..9f0f4f39 100644 --- a/rest_client_zrok/admin/create_account_responses.go +++ b/rest_client_zrok/admin/create_account_responses.go @@ -7,7 +7,6 @@ package admin import ( "context" - "encoding/json" "fmt" "io" @@ -92,13 +91,11 @@ func (o *CreateAccountCreated) Code() int { } func (o *CreateAccountCreated) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /account][%d] createAccountCreated %s", 201, payload) + return fmt.Sprintf("[POST /account][%d] createAccountCreated %+v", 201, o.Payload) } func (o *CreateAccountCreated) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /account][%d] createAccountCreated %s", 201, payload) + return fmt.Sprintf("[POST /account][%d] createAccountCreated %+v", 201, o.Payload) } func (o *CreateAccountCreated) GetPayload() *CreateAccountCreatedBody { @@ -161,11 +158,11 @@ func (o *CreateAccountUnauthorized) Code() int { } func (o *CreateAccountUnauthorized) Error() string { - return fmt.Sprintf("[POST /account][%d] createAccountUnauthorized", 401) + return fmt.Sprintf("[POST /account][%d] createAccountUnauthorized ", 401) } func (o *CreateAccountUnauthorized) String() string { - return fmt.Sprintf("[POST /account][%d] createAccountUnauthorized", 401) + return fmt.Sprintf("[POST /account][%d] createAccountUnauthorized ", 401) } func (o *CreateAccountUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -217,11 +214,11 @@ func (o *CreateAccountInternalServerError) Code() int { } func (o *CreateAccountInternalServerError) Error() string { - return fmt.Sprintf("[POST /account][%d] createAccountInternalServerError", 500) + return fmt.Sprintf("[POST /account][%d] createAccountInternalServerError ", 500) } func (o *CreateAccountInternalServerError) String() string { - return fmt.Sprintf("[POST /account][%d] createAccountInternalServerError", 500) + return fmt.Sprintf("[POST /account][%d] createAccountInternalServerError ", 500) } func (o *CreateAccountInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/admin/create_frontend_responses.go b/rest_client_zrok/admin/create_frontend_responses.go index af456402..367d6b5c 100644 --- a/rest_client_zrok/admin/create_frontend_responses.go +++ b/rest_client_zrok/admin/create_frontend_responses.go @@ -106,13 +106,11 @@ func (o *CreateFrontendCreated) Code() int { } func (o *CreateFrontendCreated) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /frontend][%d] createFrontendCreated %s", 201, payload) + return fmt.Sprintf("[POST /frontend][%d] createFrontendCreated %+v", 201, o.Payload) } func (o *CreateFrontendCreated) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /frontend][%d] createFrontendCreated %s", 201, payload) + return fmt.Sprintf("[POST /frontend][%d] createFrontendCreated %+v", 201, o.Payload) } func (o *CreateFrontendCreated) GetPayload() *CreateFrontendCreatedBody { @@ -175,11 +173,11 @@ func (o *CreateFrontendBadRequest) Code() int { } func (o *CreateFrontendBadRequest) Error() string { - return fmt.Sprintf("[POST /frontend][%d] createFrontendBadRequest", 400) + return fmt.Sprintf("[POST /frontend][%d] createFrontendBadRequest ", 400) } func (o *CreateFrontendBadRequest) String() string { - return fmt.Sprintf("[POST /frontend][%d] createFrontendBadRequest", 400) + return fmt.Sprintf("[POST /frontend][%d] createFrontendBadRequest ", 400) } func (o *CreateFrontendBadRequest) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -231,11 +229,11 @@ func (o *CreateFrontendUnauthorized) Code() int { } func (o *CreateFrontendUnauthorized) Error() string { - return fmt.Sprintf("[POST /frontend][%d] createFrontendUnauthorized", 401) + return fmt.Sprintf("[POST /frontend][%d] createFrontendUnauthorized ", 401) } func (o *CreateFrontendUnauthorized) String() string { - return fmt.Sprintf("[POST /frontend][%d] createFrontendUnauthorized", 401) + return fmt.Sprintf("[POST /frontend][%d] createFrontendUnauthorized ", 401) } func (o *CreateFrontendUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -287,11 +285,11 @@ func (o *CreateFrontendNotFound) Code() int { } func (o *CreateFrontendNotFound) Error() string { - return fmt.Sprintf("[POST /frontend][%d] createFrontendNotFound", 404) + return fmt.Sprintf("[POST /frontend][%d] createFrontendNotFound ", 404) } func (o *CreateFrontendNotFound) String() string { - return fmt.Sprintf("[POST /frontend][%d] createFrontendNotFound", 404) + return fmt.Sprintf("[POST /frontend][%d] createFrontendNotFound ", 404) } func (o *CreateFrontendNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -343,11 +341,11 @@ func (o *CreateFrontendInternalServerError) Code() int { } func (o *CreateFrontendInternalServerError) Error() string { - return fmt.Sprintf("[POST /frontend][%d] createFrontendInternalServerError", 500) + return fmt.Sprintf("[POST /frontend][%d] createFrontendInternalServerError ", 500) } func (o *CreateFrontendInternalServerError) String() string { - return fmt.Sprintf("[POST /frontend][%d] createFrontendInternalServerError", 500) + return fmt.Sprintf("[POST /frontend][%d] createFrontendInternalServerError ", 500) } func (o *CreateFrontendInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -362,7 +360,7 @@ swagger:model CreateFrontendBody type CreateFrontendBody struct { // permission mode - // Enum: ["open","closed"] + // Enum: [open closed] PermissionMode string `json:"permissionMode,omitempty"` // public name diff --git a/rest_client_zrok/admin/create_identity_responses.go b/rest_client_zrok/admin/create_identity_responses.go index c1f0670f..17c7457b 100644 --- a/rest_client_zrok/admin/create_identity_responses.go +++ b/rest_client_zrok/admin/create_identity_responses.go @@ -7,7 +7,6 @@ package admin import ( "context" - "encoding/json" "fmt" "io" @@ -92,13 +91,11 @@ func (o *CreateIdentityCreated) Code() int { } func (o *CreateIdentityCreated) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /identity][%d] createIdentityCreated %s", 201, payload) + return fmt.Sprintf("[POST /identity][%d] createIdentityCreated %+v", 201, o.Payload) } func (o *CreateIdentityCreated) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /identity][%d] createIdentityCreated %s", 201, payload) + return fmt.Sprintf("[POST /identity][%d] createIdentityCreated %+v", 201, o.Payload) } func (o *CreateIdentityCreated) GetPayload() *CreateIdentityCreatedBody { @@ -161,11 +158,11 @@ func (o *CreateIdentityUnauthorized) Code() int { } func (o *CreateIdentityUnauthorized) Error() string { - return fmt.Sprintf("[POST /identity][%d] createIdentityUnauthorized", 401) + return fmt.Sprintf("[POST /identity][%d] createIdentityUnauthorized ", 401) } func (o *CreateIdentityUnauthorized) String() string { - return fmt.Sprintf("[POST /identity][%d] createIdentityUnauthorized", 401) + return fmt.Sprintf("[POST /identity][%d] createIdentityUnauthorized ", 401) } func (o *CreateIdentityUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -217,11 +214,11 @@ func (o *CreateIdentityInternalServerError) Code() int { } func (o *CreateIdentityInternalServerError) Error() string { - return fmt.Sprintf("[POST /identity][%d] createIdentityInternalServerError", 500) + return fmt.Sprintf("[POST /identity][%d] createIdentityInternalServerError ", 500) } func (o *CreateIdentityInternalServerError) String() string { - return fmt.Sprintf("[POST /identity][%d] createIdentityInternalServerError", 500) + return fmt.Sprintf("[POST /identity][%d] createIdentityInternalServerError ", 500) } func (o *CreateIdentityInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/admin/create_organization_responses.go b/rest_client_zrok/admin/create_organization_responses.go index fdca102b..b31dffa6 100644 --- a/rest_client_zrok/admin/create_organization_responses.go +++ b/rest_client_zrok/admin/create_organization_responses.go @@ -7,7 +7,6 @@ package admin import ( "context" - "encoding/json" "fmt" "io" @@ -92,13 +91,11 @@ func (o *CreateOrganizationCreated) Code() int { } func (o *CreateOrganizationCreated) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /organization][%d] createOrganizationCreated %s", 201, payload) + return fmt.Sprintf("[POST /organization][%d] createOrganizationCreated %+v", 201, o.Payload) } func (o *CreateOrganizationCreated) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /organization][%d] createOrganizationCreated %s", 201, payload) + return fmt.Sprintf("[POST /organization][%d] createOrganizationCreated %+v", 201, o.Payload) } func (o *CreateOrganizationCreated) GetPayload() *CreateOrganizationCreatedBody { @@ -161,11 +158,11 @@ func (o *CreateOrganizationUnauthorized) Code() int { } func (o *CreateOrganizationUnauthorized) Error() string { - return fmt.Sprintf("[POST /organization][%d] createOrganizationUnauthorized", 401) + return fmt.Sprintf("[POST /organization][%d] createOrganizationUnauthorized ", 401) } func (o *CreateOrganizationUnauthorized) String() string { - return fmt.Sprintf("[POST /organization][%d] createOrganizationUnauthorized", 401) + return fmt.Sprintf("[POST /organization][%d] createOrganizationUnauthorized ", 401) } func (o *CreateOrganizationUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -217,11 +214,11 @@ func (o *CreateOrganizationInternalServerError) Code() int { } func (o *CreateOrganizationInternalServerError) Error() string { - return fmt.Sprintf("[POST /organization][%d] createOrganizationInternalServerError", 500) + return fmt.Sprintf("[POST /organization][%d] createOrganizationInternalServerError ", 500) } func (o *CreateOrganizationInternalServerError) String() string { - return fmt.Sprintf("[POST /organization][%d] createOrganizationInternalServerError", 500) + return fmt.Sprintf("[POST /organization][%d] createOrganizationInternalServerError ", 500) } func (o *CreateOrganizationInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/admin/delete_frontend_responses.go b/rest_client_zrok/admin/delete_frontend_responses.go index b5bef8ba..235c2c19 100644 --- a/rest_client_zrok/admin/delete_frontend_responses.go +++ b/rest_client_zrok/admin/delete_frontend_responses.go @@ -95,11 +95,11 @@ func (o *DeleteFrontendOK) Code() int { } func (o *DeleteFrontendOK) Error() string { - return fmt.Sprintf("[DELETE /frontend][%d] deleteFrontendOK", 200) + return fmt.Sprintf("[DELETE /frontend][%d] deleteFrontendOK ", 200) } func (o *DeleteFrontendOK) String() string { - return fmt.Sprintf("[DELETE /frontend][%d] deleteFrontendOK", 200) + return fmt.Sprintf("[DELETE /frontend][%d] deleteFrontendOK ", 200) } func (o *DeleteFrontendOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -151,11 +151,11 @@ func (o *DeleteFrontendUnauthorized) Code() int { } func (o *DeleteFrontendUnauthorized) Error() string { - return fmt.Sprintf("[DELETE /frontend][%d] deleteFrontendUnauthorized", 401) + return fmt.Sprintf("[DELETE /frontend][%d] deleteFrontendUnauthorized ", 401) } func (o *DeleteFrontendUnauthorized) String() string { - return fmt.Sprintf("[DELETE /frontend][%d] deleteFrontendUnauthorized", 401) + return fmt.Sprintf("[DELETE /frontend][%d] deleteFrontendUnauthorized ", 401) } func (o *DeleteFrontendUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -207,11 +207,11 @@ func (o *DeleteFrontendNotFound) Code() int { } func (o *DeleteFrontendNotFound) Error() string { - return fmt.Sprintf("[DELETE /frontend][%d] deleteFrontendNotFound", 404) + return fmt.Sprintf("[DELETE /frontend][%d] deleteFrontendNotFound ", 404) } func (o *DeleteFrontendNotFound) String() string { - return fmt.Sprintf("[DELETE /frontend][%d] deleteFrontendNotFound", 404) + return fmt.Sprintf("[DELETE /frontend][%d] deleteFrontendNotFound ", 404) } func (o *DeleteFrontendNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -263,11 +263,11 @@ func (o *DeleteFrontendInternalServerError) Code() int { } func (o *DeleteFrontendInternalServerError) Error() string { - return fmt.Sprintf("[DELETE /frontend][%d] deleteFrontendInternalServerError", 500) + return fmt.Sprintf("[DELETE /frontend][%d] deleteFrontendInternalServerError ", 500) } func (o *DeleteFrontendInternalServerError) String() string { - return fmt.Sprintf("[DELETE /frontend][%d] deleteFrontendInternalServerError", 500) + return fmt.Sprintf("[DELETE /frontend][%d] deleteFrontendInternalServerError ", 500) } func (o *DeleteFrontendInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/admin/delete_organization_responses.go b/rest_client_zrok/admin/delete_organization_responses.go index 430b89f3..7dbf9987 100644 --- a/rest_client_zrok/admin/delete_organization_responses.go +++ b/rest_client_zrok/admin/delete_organization_responses.go @@ -95,11 +95,11 @@ func (o *DeleteOrganizationOK) Code() int { } func (o *DeleteOrganizationOK) Error() string { - return fmt.Sprintf("[DELETE /organization][%d] deleteOrganizationOK", 200) + return fmt.Sprintf("[DELETE /organization][%d] deleteOrganizationOK ", 200) } func (o *DeleteOrganizationOK) String() string { - return fmt.Sprintf("[DELETE /organization][%d] deleteOrganizationOK", 200) + return fmt.Sprintf("[DELETE /organization][%d] deleteOrganizationOK ", 200) } func (o *DeleteOrganizationOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -151,11 +151,11 @@ func (o *DeleteOrganizationUnauthorized) Code() int { } func (o *DeleteOrganizationUnauthorized) Error() string { - return fmt.Sprintf("[DELETE /organization][%d] deleteOrganizationUnauthorized", 401) + return fmt.Sprintf("[DELETE /organization][%d] deleteOrganizationUnauthorized ", 401) } func (o *DeleteOrganizationUnauthorized) String() string { - return fmt.Sprintf("[DELETE /organization][%d] deleteOrganizationUnauthorized", 401) + return fmt.Sprintf("[DELETE /organization][%d] deleteOrganizationUnauthorized ", 401) } func (o *DeleteOrganizationUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -207,11 +207,11 @@ func (o *DeleteOrganizationNotFound) Code() int { } func (o *DeleteOrganizationNotFound) Error() string { - return fmt.Sprintf("[DELETE /organization][%d] deleteOrganizationNotFound", 404) + return fmt.Sprintf("[DELETE /organization][%d] deleteOrganizationNotFound ", 404) } func (o *DeleteOrganizationNotFound) String() string { - return fmt.Sprintf("[DELETE /organization][%d] deleteOrganizationNotFound", 404) + return fmt.Sprintf("[DELETE /organization][%d] deleteOrganizationNotFound ", 404) } func (o *DeleteOrganizationNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -263,11 +263,11 @@ func (o *DeleteOrganizationInternalServerError) Code() int { } func (o *DeleteOrganizationInternalServerError) Error() string { - return fmt.Sprintf("[DELETE /organization][%d] deleteOrganizationInternalServerError", 500) + return fmt.Sprintf("[DELETE /organization][%d] deleteOrganizationInternalServerError ", 500) } func (o *DeleteOrganizationInternalServerError) String() string { - return fmt.Sprintf("[DELETE /organization][%d] deleteOrganizationInternalServerError", 500) + return fmt.Sprintf("[DELETE /organization][%d] deleteOrganizationInternalServerError ", 500) } func (o *DeleteOrganizationInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/admin/grants_responses.go b/rest_client_zrok/admin/grants_responses.go index 8f72c2de..a8b1ddb1 100644 --- a/rest_client_zrok/admin/grants_responses.go +++ b/rest_client_zrok/admin/grants_responses.go @@ -95,11 +95,11 @@ func (o *GrantsOK) Code() int { } func (o *GrantsOK) Error() string { - return fmt.Sprintf("[POST /grants][%d] grantsOK", 200) + return fmt.Sprintf("[POST /grants][%d] grantsOK ", 200) } func (o *GrantsOK) String() string { - return fmt.Sprintf("[POST /grants][%d] grantsOK", 200) + return fmt.Sprintf("[POST /grants][%d] grantsOK ", 200) } func (o *GrantsOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -151,11 +151,11 @@ func (o *GrantsUnauthorized) Code() int { } func (o *GrantsUnauthorized) Error() string { - return fmt.Sprintf("[POST /grants][%d] grantsUnauthorized", 401) + return fmt.Sprintf("[POST /grants][%d] grantsUnauthorized ", 401) } func (o *GrantsUnauthorized) String() string { - return fmt.Sprintf("[POST /grants][%d] grantsUnauthorized", 401) + return fmt.Sprintf("[POST /grants][%d] grantsUnauthorized ", 401) } func (o *GrantsUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -207,11 +207,11 @@ func (o *GrantsNotFound) Code() int { } func (o *GrantsNotFound) Error() string { - return fmt.Sprintf("[POST /grants][%d] grantsNotFound", 404) + return fmt.Sprintf("[POST /grants][%d] grantsNotFound ", 404) } func (o *GrantsNotFound) String() string { - return fmt.Sprintf("[POST /grants][%d] grantsNotFound", 404) + return fmt.Sprintf("[POST /grants][%d] grantsNotFound ", 404) } func (o *GrantsNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -263,11 +263,11 @@ func (o *GrantsInternalServerError) Code() int { } func (o *GrantsInternalServerError) Error() string { - return fmt.Sprintf("[POST /grants][%d] grantsInternalServerError", 500) + return fmt.Sprintf("[POST /grants][%d] grantsInternalServerError ", 500) } func (o *GrantsInternalServerError) String() string { - return fmt.Sprintf("[POST /grants][%d] grantsInternalServerError", 500) + return fmt.Sprintf("[POST /grants][%d] grantsInternalServerError ", 500) } func (o *GrantsInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/admin/invite_token_generate_responses.go b/rest_client_zrok/admin/invite_token_generate_responses.go index 312043c2..1279f0a4 100644 --- a/rest_client_zrok/admin/invite_token_generate_responses.go +++ b/rest_client_zrok/admin/invite_token_generate_responses.go @@ -95,11 +95,11 @@ func (o *InviteTokenGenerateCreated) Code() int { } func (o *InviteTokenGenerateCreated) Error() string { - return fmt.Sprintf("[POST /invite/token/generate][%d] inviteTokenGenerateCreated", 201) + return fmt.Sprintf("[POST /invite/token/generate][%d] inviteTokenGenerateCreated ", 201) } func (o *InviteTokenGenerateCreated) String() string { - return fmt.Sprintf("[POST /invite/token/generate][%d] inviteTokenGenerateCreated", 201) + return fmt.Sprintf("[POST /invite/token/generate][%d] inviteTokenGenerateCreated ", 201) } func (o *InviteTokenGenerateCreated) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -151,11 +151,11 @@ func (o *InviteTokenGenerateBadRequest) Code() int { } func (o *InviteTokenGenerateBadRequest) Error() string { - return fmt.Sprintf("[POST /invite/token/generate][%d] inviteTokenGenerateBadRequest", 400) + return fmt.Sprintf("[POST /invite/token/generate][%d] inviteTokenGenerateBadRequest ", 400) } func (o *InviteTokenGenerateBadRequest) String() string { - return fmt.Sprintf("[POST /invite/token/generate][%d] inviteTokenGenerateBadRequest", 400) + return fmt.Sprintf("[POST /invite/token/generate][%d] inviteTokenGenerateBadRequest ", 400) } func (o *InviteTokenGenerateBadRequest) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -207,11 +207,11 @@ func (o *InviteTokenGenerateUnauthorized) Code() int { } func (o *InviteTokenGenerateUnauthorized) Error() string { - return fmt.Sprintf("[POST /invite/token/generate][%d] inviteTokenGenerateUnauthorized", 401) + return fmt.Sprintf("[POST /invite/token/generate][%d] inviteTokenGenerateUnauthorized ", 401) } func (o *InviteTokenGenerateUnauthorized) String() string { - return fmt.Sprintf("[POST /invite/token/generate][%d] inviteTokenGenerateUnauthorized", 401) + return fmt.Sprintf("[POST /invite/token/generate][%d] inviteTokenGenerateUnauthorized ", 401) } func (o *InviteTokenGenerateUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -263,11 +263,11 @@ func (o *InviteTokenGenerateInternalServerError) Code() int { } func (o *InviteTokenGenerateInternalServerError) Error() string { - return fmt.Sprintf("[POST /invite/token/generate][%d] inviteTokenGenerateInternalServerError", 500) + return fmt.Sprintf("[POST /invite/token/generate][%d] inviteTokenGenerateInternalServerError ", 500) } func (o *InviteTokenGenerateInternalServerError) String() string { - return fmt.Sprintf("[POST /invite/token/generate][%d] inviteTokenGenerateInternalServerError", 500) + return fmt.Sprintf("[POST /invite/token/generate][%d] inviteTokenGenerateInternalServerError ", 500) } func (o *InviteTokenGenerateInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/admin/list_frontends_responses.go b/rest_client_zrok/admin/list_frontends_responses.go index 5ff04e11..d351c898 100644 --- a/rest_client_zrok/admin/list_frontends_responses.go +++ b/rest_client_zrok/admin/list_frontends_responses.go @@ -7,7 +7,6 @@ package admin import ( "context" - "encoding/json" "fmt" "io" @@ -92,13 +91,11 @@ func (o *ListFrontendsOK) Code() int { } func (o *ListFrontendsOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /frontends][%d] listFrontendsOK %s", 200, payload) + return fmt.Sprintf("[GET /frontends][%d] listFrontendsOK %+v", 200, o.Payload) } func (o *ListFrontendsOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /frontends][%d] listFrontendsOK %s", 200, payload) + return fmt.Sprintf("[GET /frontends][%d] listFrontendsOK %+v", 200, o.Payload) } func (o *ListFrontendsOK) GetPayload() []*ListFrontendsOKBodyItems0 { @@ -159,11 +156,11 @@ func (o *ListFrontendsUnauthorized) Code() int { } func (o *ListFrontendsUnauthorized) Error() string { - return fmt.Sprintf("[GET /frontends][%d] listFrontendsUnauthorized", 401) + return fmt.Sprintf("[GET /frontends][%d] listFrontendsUnauthorized ", 401) } func (o *ListFrontendsUnauthorized) String() string { - return fmt.Sprintf("[GET /frontends][%d] listFrontendsUnauthorized", 401) + return fmt.Sprintf("[GET /frontends][%d] listFrontendsUnauthorized ", 401) } func (o *ListFrontendsUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -215,11 +212,11 @@ func (o *ListFrontendsInternalServerError) Code() int { } func (o *ListFrontendsInternalServerError) Error() string { - return fmt.Sprintf("[GET /frontends][%d] listFrontendsInternalServerError", 500) + return fmt.Sprintf("[GET /frontends][%d] listFrontendsInternalServerError ", 500) } func (o *ListFrontendsInternalServerError) String() string { - return fmt.Sprintf("[GET /frontends][%d] listFrontendsInternalServerError", 500) + return fmt.Sprintf("[GET /frontends][%d] listFrontendsInternalServerError ", 500) } func (o *ListFrontendsInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/admin/list_organization_members_responses.go b/rest_client_zrok/admin/list_organization_members_responses.go index f6bb8887..dfc0a42c 100644 --- a/rest_client_zrok/admin/list_organization_members_responses.go +++ b/rest_client_zrok/admin/list_organization_members_responses.go @@ -7,7 +7,6 @@ package admin import ( "context" - "encoding/json" "fmt" "io" "strconv" @@ -100,13 +99,11 @@ func (o *ListOrganizationMembersOK) Code() int { } func (o *ListOrganizationMembersOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /organization/list][%d] listOrganizationMembersOK %s", 200, payload) + return fmt.Sprintf("[POST /organization/list][%d] listOrganizationMembersOK %+v", 200, o.Payload) } func (o *ListOrganizationMembersOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /organization/list][%d] listOrganizationMembersOK %s", 200, payload) + return fmt.Sprintf("[POST /organization/list][%d] listOrganizationMembersOK %+v", 200, o.Payload) } func (o *ListOrganizationMembersOK) GetPayload() *ListOrganizationMembersOKBody { @@ -169,11 +166,11 @@ func (o *ListOrganizationMembersUnauthorized) Code() int { } func (o *ListOrganizationMembersUnauthorized) Error() string { - return fmt.Sprintf("[POST /organization/list][%d] listOrganizationMembersUnauthorized", 401) + return fmt.Sprintf("[POST /organization/list][%d] listOrganizationMembersUnauthorized ", 401) } func (o *ListOrganizationMembersUnauthorized) String() string { - return fmt.Sprintf("[POST /organization/list][%d] listOrganizationMembersUnauthorized", 401) + return fmt.Sprintf("[POST /organization/list][%d] listOrganizationMembersUnauthorized ", 401) } func (o *ListOrganizationMembersUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -225,11 +222,11 @@ func (o *ListOrganizationMembersNotFound) Code() int { } func (o *ListOrganizationMembersNotFound) Error() string { - return fmt.Sprintf("[POST /organization/list][%d] listOrganizationMembersNotFound", 404) + return fmt.Sprintf("[POST /organization/list][%d] listOrganizationMembersNotFound ", 404) } func (o *ListOrganizationMembersNotFound) String() string { - return fmt.Sprintf("[POST /organization/list][%d] listOrganizationMembersNotFound", 404) + return fmt.Sprintf("[POST /organization/list][%d] listOrganizationMembersNotFound ", 404) } func (o *ListOrganizationMembersNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -281,11 +278,11 @@ func (o *ListOrganizationMembersInternalServerError) Code() int { } func (o *ListOrganizationMembersInternalServerError) Error() string { - return fmt.Sprintf("[POST /organization/list][%d] listOrganizationMembersInternalServerError", 500) + return fmt.Sprintf("[POST /organization/list][%d] listOrganizationMembersInternalServerError ", 500) } func (o *ListOrganizationMembersInternalServerError) String() string { - return fmt.Sprintf("[POST /organization/list][%d] listOrganizationMembersInternalServerError", 500) + return fmt.Sprintf("[POST /organization/list][%d] listOrganizationMembersInternalServerError ", 500) } func (o *ListOrganizationMembersInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/admin/list_organizations_responses.go b/rest_client_zrok/admin/list_organizations_responses.go index 34cb742f..01055621 100644 --- a/rest_client_zrok/admin/list_organizations_responses.go +++ b/rest_client_zrok/admin/list_organizations_responses.go @@ -7,7 +7,6 @@ package admin import ( "context" - "encoding/json" "fmt" "io" "strconv" @@ -94,13 +93,11 @@ func (o *ListOrganizationsOK) Code() int { } func (o *ListOrganizationsOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /organizations][%d] listOrganizationsOK %s", 200, payload) + return fmt.Sprintf("[GET /organizations][%d] listOrganizationsOK %+v", 200, o.Payload) } func (o *ListOrganizationsOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /organizations][%d] listOrganizationsOK %s", 200, payload) + return fmt.Sprintf("[GET /organizations][%d] listOrganizationsOK %+v", 200, o.Payload) } func (o *ListOrganizationsOK) GetPayload() *ListOrganizationsOKBody { @@ -163,11 +160,11 @@ func (o *ListOrganizationsUnauthorized) Code() int { } func (o *ListOrganizationsUnauthorized) Error() string { - return fmt.Sprintf("[GET /organizations][%d] listOrganizationsUnauthorized", 401) + return fmt.Sprintf("[GET /organizations][%d] listOrganizationsUnauthorized ", 401) } func (o *ListOrganizationsUnauthorized) String() string { - return fmt.Sprintf("[GET /organizations][%d] listOrganizationsUnauthorized", 401) + return fmt.Sprintf("[GET /organizations][%d] listOrganizationsUnauthorized ", 401) } func (o *ListOrganizationsUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -219,11 +216,11 @@ func (o *ListOrganizationsInternalServerError) Code() int { } func (o *ListOrganizationsInternalServerError) Error() string { - return fmt.Sprintf("[GET /organizations][%d] listOrganizationsInternalServerError", 500) + return fmt.Sprintf("[GET /organizations][%d] listOrganizationsInternalServerError ", 500) } func (o *ListOrganizationsInternalServerError) String() string { - return fmt.Sprintf("[GET /organizations][%d] listOrganizationsInternalServerError", 500) + return fmt.Sprintf("[GET /organizations][%d] listOrganizationsInternalServerError ", 500) } func (o *ListOrganizationsInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/admin/remove_organization_member_responses.go b/rest_client_zrok/admin/remove_organization_member_responses.go index 46c269fd..115b20b8 100644 --- a/rest_client_zrok/admin/remove_organization_member_responses.go +++ b/rest_client_zrok/admin/remove_organization_member_responses.go @@ -95,11 +95,11 @@ func (o *RemoveOrganizationMemberOK) Code() int { } func (o *RemoveOrganizationMemberOK) Error() string { - return fmt.Sprintf("[POST /organization/remove][%d] removeOrganizationMemberOK", 200) + return fmt.Sprintf("[POST /organization/remove][%d] removeOrganizationMemberOK ", 200) } func (o *RemoveOrganizationMemberOK) String() string { - return fmt.Sprintf("[POST /organization/remove][%d] removeOrganizationMemberOK", 200) + return fmt.Sprintf("[POST /organization/remove][%d] removeOrganizationMemberOK ", 200) } func (o *RemoveOrganizationMemberOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -151,11 +151,11 @@ func (o *RemoveOrganizationMemberUnauthorized) Code() int { } func (o *RemoveOrganizationMemberUnauthorized) Error() string { - return fmt.Sprintf("[POST /organization/remove][%d] removeOrganizationMemberUnauthorized", 401) + return fmt.Sprintf("[POST /organization/remove][%d] removeOrganizationMemberUnauthorized ", 401) } func (o *RemoveOrganizationMemberUnauthorized) String() string { - return fmt.Sprintf("[POST /organization/remove][%d] removeOrganizationMemberUnauthorized", 401) + return fmt.Sprintf("[POST /organization/remove][%d] removeOrganizationMemberUnauthorized ", 401) } func (o *RemoveOrganizationMemberUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -207,11 +207,11 @@ func (o *RemoveOrganizationMemberNotFound) Code() int { } func (o *RemoveOrganizationMemberNotFound) Error() string { - return fmt.Sprintf("[POST /organization/remove][%d] removeOrganizationMemberNotFound", 404) + return fmt.Sprintf("[POST /organization/remove][%d] removeOrganizationMemberNotFound ", 404) } func (o *RemoveOrganizationMemberNotFound) String() string { - return fmt.Sprintf("[POST /organization/remove][%d] removeOrganizationMemberNotFound", 404) + return fmt.Sprintf("[POST /organization/remove][%d] removeOrganizationMemberNotFound ", 404) } func (o *RemoveOrganizationMemberNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -263,11 +263,11 @@ func (o *RemoveOrganizationMemberInternalServerError) Code() int { } func (o *RemoveOrganizationMemberInternalServerError) Error() string { - return fmt.Sprintf("[POST /organization/remove][%d] removeOrganizationMemberInternalServerError", 500) + return fmt.Sprintf("[POST /organization/remove][%d] removeOrganizationMemberInternalServerError ", 500) } func (o *RemoveOrganizationMemberInternalServerError) String() string { - return fmt.Sprintf("[POST /organization/remove][%d] removeOrganizationMemberInternalServerError", 500) + return fmt.Sprintf("[POST /organization/remove][%d] removeOrganizationMemberInternalServerError ", 500) } func (o *RemoveOrganizationMemberInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/admin/update_frontend_responses.go b/rest_client_zrok/admin/update_frontend_responses.go index 466ba857..943e37b8 100644 --- a/rest_client_zrok/admin/update_frontend_responses.go +++ b/rest_client_zrok/admin/update_frontend_responses.go @@ -95,11 +95,11 @@ func (o *UpdateFrontendOK) Code() int { } func (o *UpdateFrontendOK) Error() string { - return fmt.Sprintf("[PATCH /frontend][%d] updateFrontendOK", 200) + return fmt.Sprintf("[PATCH /frontend][%d] updateFrontendOK ", 200) } func (o *UpdateFrontendOK) String() string { - return fmt.Sprintf("[PATCH /frontend][%d] updateFrontendOK", 200) + return fmt.Sprintf("[PATCH /frontend][%d] updateFrontendOK ", 200) } func (o *UpdateFrontendOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -151,11 +151,11 @@ func (o *UpdateFrontendUnauthorized) Code() int { } func (o *UpdateFrontendUnauthorized) Error() string { - return fmt.Sprintf("[PATCH /frontend][%d] updateFrontendUnauthorized", 401) + return fmt.Sprintf("[PATCH /frontend][%d] updateFrontendUnauthorized ", 401) } func (o *UpdateFrontendUnauthorized) String() string { - return fmt.Sprintf("[PATCH /frontend][%d] updateFrontendUnauthorized", 401) + return fmt.Sprintf("[PATCH /frontend][%d] updateFrontendUnauthorized ", 401) } func (o *UpdateFrontendUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -207,11 +207,11 @@ func (o *UpdateFrontendNotFound) Code() int { } func (o *UpdateFrontendNotFound) Error() string { - return fmt.Sprintf("[PATCH /frontend][%d] updateFrontendNotFound", 404) + return fmt.Sprintf("[PATCH /frontend][%d] updateFrontendNotFound ", 404) } func (o *UpdateFrontendNotFound) String() string { - return fmt.Sprintf("[PATCH /frontend][%d] updateFrontendNotFound", 404) + return fmt.Sprintf("[PATCH /frontend][%d] updateFrontendNotFound ", 404) } func (o *UpdateFrontendNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -263,11 +263,11 @@ func (o *UpdateFrontendInternalServerError) Code() int { } func (o *UpdateFrontendInternalServerError) Error() string { - return fmt.Sprintf("[PATCH /frontend][%d] updateFrontendInternalServerError", 500) + return fmt.Sprintf("[PATCH /frontend][%d] updateFrontendInternalServerError ", 500) } func (o *UpdateFrontendInternalServerError) String() string { - return fmt.Sprintf("[PATCH /frontend][%d] updateFrontendInternalServerError", 500) + return fmt.Sprintf("[PATCH /frontend][%d] updateFrontendInternalServerError ", 500) } func (o *UpdateFrontendInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/agent/agent_client.go b/rest_client_zrok/agent/agent_client.go index 16be5eb7..b3b96ea5 100644 --- a/rest_client_zrok/agent/agent_client.go +++ b/rest_client_zrok/agent/agent_client.go @@ -9,7 +9,6 @@ import ( "fmt" "github.com/go-openapi/runtime" - httptransport "github.com/go-openapi/runtime/client" "github.com/go-openapi/strfmt" ) @@ -18,31 +17,6 @@ func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientServi return &Client{transport: transport, formats: formats} } -// New creates a new agent API client with basic auth credentials. -// It takes the following parameters: -// - host: http host (github.com). -// - basePath: any base path for the API client ("/v1", "/v3"). -// - scheme: http scheme ("http", "https"). -// - user: user for basic authentication header. -// - password: password for basic authentication header. -func NewClientWithBasicAuth(host, basePath, scheme, user, password string) ClientService { - transport := httptransport.New(host, basePath, []string{scheme}) - transport.DefaultAuthentication = httptransport.BasicAuth(user, password) - return &Client{transport: transport, formats: strfmt.Default} -} - -// New creates a new agent API client with a bearer token for authentication. -// It takes the following parameters: -// - host: http host (github.com). -// - basePath: any base path for the API client ("/v1", "/v3"). -// - scheme: http scheme ("http", "https"). -// - bearerToken: bearer token for Bearer authentication header. -func NewClientWithBearerToken(host, basePath, scheme, bearerToken string) ClientService { - transport := httptransport.New(host, basePath, []string{scheme}) - transport.DefaultAuthentication = httptransport.BearerToken(bearerToken) - return &Client{transport: transport, formats: strfmt.Default} -} - /* Client for agent API */ @@ -51,53 +25,9 @@ type Client struct { formats strfmt.Registry } -// ClientOption may be used to customize the behavior of Client methods. +// ClientOption is the option for Client methods type ClientOption func(*runtime.ClientOperation) -// This client is generated with a few options you might find useful for your swagger spec. -// -// Feel free to add you own set of options. - -// WithContentType allows the client to force the Content-Type header -// to negotiate a specific Consumer from the server. -// -// You may use this option to set arbitrary extensions to your MIME media type. -func WithContentType(mime string) ClientOption { - return func(r *runtime.ClientOperation) { - r.ConsumesMediaTypes = []string{mime} - } -} - -// WithContentTypeApplicationJSON sets the Content-Type header to "application/json". -func WithContentTypeApplicationJSON(r *runtime.ClientOperation) { - r.ConsumesMediaTypes = []string{"application/json"} -} - -// WithContentTypeApplicationZrokV1JSON sets the Content-Type header to "application/zrok.v1+json". -func WithContentTypeApplicationZrokV1JSON(r *runtime.ClientOperation) { - r.ConsumesMediaTypes = []string{"application/zrok.v1+json"} -} - -// WithAccept allows the client to force the Accept header -// to negotiate a specific Producer from the server. -// -// You may use this option to set arbitrary extensions to your MIME media type. -func WithAccept(mime string) ClientOption { - return func(r *runtime.ClientOperation) { - r.ProducesMediaTypes = []string{mime} - } -} - -// WithAcceptApplicationJSON sets the Accept header to "application/json". -func WithAcceptApplicationJSON(r *runtime.ClientOperation) { - r.ProducesMediaTypes = []string{"application/json"} -} - -// WithAcceptApplicationZrokV1JSON sets the Accept header to "application/zrok.v1+json". -func WithAcceptApplicationZrokV1JSON(r *runtime.ClientOperation) { - r.ProducesMediaTypes = []string{"application/zrok.v1+json"} -} - // ClientService is the interface for Client methods type ClientService interface { Enroll(params *EnrollParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*EnrollOK, error) diff --git a/rest_client_zrok/agent/enroll_responses.go b/rest_client_zrok/agent/enroll_responses.go index 5bb45786..834f85a4 100644 --- a/rest_client_zrok/agent/enroll_responses.go +++ b/rest_client_zrok/agent/enroll_responses.go @@ -7,7 +7,6 @@ package agent import ( "context" - "encoding/json" "fmt" "io" @@ -98,13 +97,11 @@ func (o *EnrollOK) Code() int { } func (o *EnrollOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /agent/enroll][%d] enrollOK %s", 200, payload) + return fmt.Sprintf("[POST /agent/enroll][%d] enrollOK %+v", 200, o.Payload) } func (o *EnrollOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /agent/enroll][%d] enrollOK %s", 200, payload) + return fmt.Sprintf("[POST /agent/enroll][%d] enrollOK %+v", 200, o.Payload) } func (o *EnrollOK) GetPayload() *EnrollOKBody { @@ -167,11 +164,11 @@ func (o *EnrollBadRequest) Code() int { } func (o *EnrollBadRequest) Error() string { - return fmt.Sprintf("[POST /agent/enroll][%d] enrollBadRequest", 400) + return fmt.Sprintf("[POST /agent/enroll][%d] enrollBadRequest ", 400) } func (o *EnrollBadRequest) String() string { - return fmt.Sprintf("[POST /agent/enroll][%d] enrollBadRequest", 400) + return fmt.Sprintf("[POST /agent/enroll][%d] enrollBadRequest ", 400) } func (o *EnrollBadRequest) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -223,11 +220,11 @@ func (o *EnrollUnauthorized) Code() int { } func (o *EnrollUnauthorized) Error() string { - return fmt.Sprintf("[POST /agent/enroll][%d] enrollUnauthorized", 401) + return fmt.Sprintf("[POST /agent/enroll][%d] enrollUnauthorized ", 401) } func (o *EnrollUnauthorized) String() string { - return fmt.Sprintf("[POST /agent/enroll][%d] enrollUnauthorized", 401) + return fmt.Sprintf("[POST /agent/enroll][%d] enrollUnauthorized ", 401) } func (o *EnrollUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -279,11 +276,11 @@ func (o *EnrollInternalServerError) Code() int { } func (o *EnrollInternalServerError) Error() string { - return fmt.Sprintf("[POST /agent/enroll][%d] enrollInternalServerError", 500) + return fmt.Sprintf("[POST /agent/enroll][%d] enrollInternalServerError ", 500) } func (o *EnrollInternalServerError) String() string { - return fmt.Sprintf("[POST /agent/enroll][%d] enrollInternalServerError", 500) + return fmt.Sprintf("[POST /agent/enroll][%d] enrollInternalServerError ", 500) } func (o *EnrollInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/agent/ping_responses.go b/rest_client_zrok/agent/ping_responses.go index 8797465b..0a75237f 100644 --- a/rest_client_zrok/agent/ping_responses.go +++ b/rest_client_zrok/agent/ping_responses.go @@ -7,7 +7,6 @@ package agent import ( "context" - "encoding/json" "fmt" "io" @@ -98,13 +97,11 @@ func (o *PingOK) Code() int { } func (o *PingOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /agent/ping][%d] pingOK %s", 200, payload) + return fmt.Sprintf("[POST /agent/ping][%d] pingOK %+v", 200, o.Payload) } func (o *PingOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /agent/ping][%d] pingOK %s", 200, payload) + return fmt.Sprintf("[POST /agent/ping][%d] pingOK %+v", 200, o.Payload) } func (o *PingOK) GetPayload() *PingOKBody { @@ -167,11 +164,11 @@ func (o *PingUnauthorized) Code() int { } func (o *PingUnauthorized) Error() string { - return fmt.Sprintf("[POST /agent/ping][%d] pingUnauthorized", 401) + return fmt.Sprintf("[POST /agent/ping][%d] pingUnauthorized ", 401) } func (o *PingUnauthorized) String() string { - return fmt.Sprintf("[POST /agent/ping][%d] pingUnauthorized", 401) + return fmt.Sprintf("[POST /agent/ping][%d] pingUnauthorized ", 401) } func (o *PingUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -223,11 +220,11 @@ func (o *PingInternalServerError) Code() int { } func (o *PingInternalServerError) Error() string { - return fmt.Sprintf("[POST /agent/ping][%d] pingInternalServerError", 500) + return fmt.Sprintf("[POST /agent/ping][%d] pingInternalServerError ", 500) } func (o *PingInternalServerError) String() string { - return fmt.Sprintf("[POST /agent/ping][%d] pingInternalServerError", 500) + return fmt.Sprintf("[POST /agent/ping][%d] pingInternalServerError ", 500) } func (o *PingInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -279,11 +276,11 @@ func (o *PingBadGateway) Code() int { } func (o *PingBadGateway) Error() string { - return fmt.Sprintf("[POST /agent/ping][%d] pingBadGateway", 502) + return fmt.Sprintf("[POST /agent/ping][%d] pingBadGateway ", 502) } func (o *PingBadGateway) String() string { - return fmt.Sprintf("[POST /agent/ping][%d] pingBadGateway", 502) + return fmt.Sprintf("[POST /agent/ping][%d] pingBadGateway ", 502) } func (o *PingBadGateway) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/agent/remote_access_responses.go b/rest_client_zrok/agent/remote_access_responses.go index 9f055e30..2cb34377 100644 --- a/rest_client_zrok/agent/remote_access_responses.go +++ b/rest_client_zrok/agent/remote_access_responses.go @@ -7,7 +7,6 @@ package agent import ( "context" - "encoding/json" "fmt" "io" @@ -100,13 +99,11 @@ func (o *RemoteAccessOK) Code() int { } func (o *RemoteAccessOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /agent/access][%d] remoteAccessOK %s", 200, payload) + return fmt.Sprintf("[POST /agent/access][%d] remoteAccessOK %+v", 200, o.Payload) } func (o *RemoteAccessOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /agent/access][%d] remoteAccessOK %s", 200, payload) + return fmt.Sprintf("[POST /agent/access][%d] remoteAccessOK %+v", 200, o.Payload) } func (o *RemoteAccessOK) GetPayload() *RemoteAccessOKBody { @@ -169,11 +166,11 @@ func (o *RemoteAccessUnauthorized) Code() int { } func (o *RemoteAccessUnauthorized) Error() string { - return fmt.Sprintf("[POST /agent/access][%d] remoteAccessUnauthorized", 401) + return fmt.Sprintf("[POST /agent/access][%d] remoteAccessUnauthorized ", 401) } func (o *RemoteAccessUnauthorized) String() string { - return fmt.Sprintf("[POST /agent/access][%d] remoteAccessUnauthorized", 401) + return fmt.Sprintf("[POST /agent/access][%d] remoteAccessUnauthorized ", 401) } func (o *RemoteAccessUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -225,11 +222,11 @@ func (o *RemoteAccessInternalServerError) Code() int { } func (o *RemoteAccessInternalServerError) Error() string { - return fmt.Sprintf("[POST /agent/access][%d] remoteAccessInternalServerError", 500) + return fmt.Sprintf("[POST /agent/access][%d] remoteAccessInternalServerError ", 500) } func (o *RemoteAccessInternalServerError) String() string { - return fmt.Sprintf("[POST /agent/access][%d] remoteAccessInternalServerError", 500) + return fmt.Sprintf("[POST /agent/access][%d] remoteAccessInternalServerError ", 500) } func (o *RemoteAccessInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -281,11 +278,11 @@ func (o *RemoteAccessBadGateway) Code() int { } func (o *RemoteAccessBadGateway) Error() string { - return fmt.Sprintf("[POST /agent/access][%d] remoteAccessBadGateway", 502) + return fmt.Sprintf("[POST /agent/access][%d] remoteAccessBadGateway ", 502) } func (o *RemoteAccessBadGateway) String() string { - return fmt.Sprintf("[POST /agent/access][%d] remoteAccessBadGateway", 502) + return fmt.Sprintf("[POST /agent/access][%d] remoteAccessBadGateway ", 502) } func (o *RemoteAccessBadGateway) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/agent/remote_share_responses.go b/rest_client_zrok/agent/remote_share_responses.go index d1c0bc4a..248b55d1 100644 --- a/rest_client_zrok/agent/remote_share_responses.go +++ b/rest_client_zrok/agent/remote_share_responses.go @@ -100,13 +100,11 @@ func (o *RemoteShareOK) Code() int { } func (o *RemoteShareOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /agent/share][%d] remoteShareOK %s", 200, payload) + return fmt.Sprintf("[POST /agent/share][%d] remoteShareOK %+v", 200, o.Payload) } func (o *RemoteShareOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /agent/share][%d] remoteShareOK %s", 200, payload) + return fmt.Sprintf("[POST /agent/share][%d] remoteShareOK %+v", 200, o.Payload) } func (o *RemoteShareOK) GetPayload() *RemoteShareOKBody { @@ -169,11 +167,11 @@ func (o *RemoteShareUnauthorized) Code() int { } func (o *RemoteShareUnauthorized) Error() string { - return fmt.Sprintf("[POST /agent/share][%d] remoteShareUnauthorized", 401) + return fmt.Sprintf("[POST /agent/share][%d] remoteShareUnauthorized ", 401) } func (o *RemoteShareUnauthorized) String() string { - return fmt.Sprintf("[POST /agent/share][%d] remoteShareUnauthorized", 401) + return fmt.Sprintf("[POST /agent/share][%d] remoteShareUnauthorized ", 401) } func (o *RemoteShareUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -225,11 +223,11 @@ func (o *RemoteShareInternalServerError) Code() int { } func (o *RemoteShareInternalServerError) Error() string { - return fmt.Sprintf("[POST /agent/share][%d] remoteShareInternalServerError", 500) + return fmt.Sprintf("[POST /agent/share][%d] remoteShareInternalServerError ", 500) } func (o *RemoteShareInternalServerError) String() string { - return fmt.Sprintf("[POST /agent/share][%d] remoteShareInternalServerError", 500) + return fmt.Sprintf("[POST /agent/share][%d] remoteShareInternalServerError ", 500) } func (o *RemoteShareInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -281,11 +279,11 @@ func (o *RemoteShareBadGateway) Code() int { } func (o *RemoteShareBadGateway) Error() string { - return fmt.Sprintf("[POST /agent/share][%d] remoteShareBadGateway", 502) + return fmt.Sprintf("[POST /agent/share][%d] remoteShareBadGateway ", 502) } func (o *RemoteShareBadGateway) String() string { - return fmt.Sprintf("[POST /agent/share][%d] remoteShareBadGateway", 502) + return fmt.Sprintf("[POST /agent/share][%d] remoteShareBadGateway ", 502) } func (o *RemoteShareBadGateway) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -303,7 +301,7 @@ type RemoteShareBody struct { AccessGrants []string `json:"accessGrants"` // backend mode - // Enum: ["proxy","web","tcpTunnel","udpTunnel","caddy","drive","socks","vpn"] + // Enum: [proxy web tcpTunnel udpTunnel caddy drive socks vpn] BackendMode string `json:"backendMode,omitempty"` // basic auth @@ -331,7 +329,7 @@ type RemoteShareBody struct { Open bool `json:"open,omitempty"` // share mode - // Enum: ["public","private","reserved"] + // Enum: [public private reserved] ShareMode string `json:"shareMode,omitempty"` // target diff --git a/rest_client_zrok/agent/remote_status_responses.go b/rest_client_zrok/agent/remote_status_responses.go index bcbe0f61..40e83418 100644 --- a/rest_client_zrok/agent/remote_status_responses.go +++ b/rest_client_zrok/agent/remote_status_responses.go @@ -7,7 +7,6 @@ package agent import ( "context" - "encoding/json" "fmt" "io" "strconv" @@ -100,13 +99,11 @@ func (o *RemoteStatusOK) Code() int { } func (o *RemoteStatusOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /agent/status][%d] remoteStatusOK %s", 200, payload) + return fmt.Sprintf("[POST /agent/status][%d] remoteStatusOK %+v", 200, o.Payload) } func (o *RemoteStatusOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /agent/status][%d] remoteStatusOK %s", 200, payload) + return fmt.Sprintf("[POST /agent/status][%d] remoteStatusOK %+v", 200, o.Payload) } func (o *RemoteStatusOK) GetPayload() *RemoteStatusOKBody { @@ -169,11 +166,11 @@ func (o *RemoteStatusUnauthorized) Code() int { } func (o *RemoteStatusUnauthorized) Error() string { - return fmt.Sprintf("[POST /agent/status][%d] remoteStatusUnauthorized", 401) + return fmt.Sprintf("[POST /agent/status][%d] remoteStatusUnauthorized ", 401) } func (o *RemoteStatusUnauthorized) String() string { - return fmt.Sprintf("[POST /agent/status][%d] remoteStatusUnauthorized", 401) + return fmt.Sprintf("[POST /agent/status][%d] remoteStatusUnauthorized ", 401) } func (o *RemoteStatusUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -225,11 +222,11 @@ func (o *RemoteStatusInternalServerError) Code() int { } func (o *RemoteStatusInternalServerError) Error() string { - return fmt.Sprintf("[POST /agent/status][%d] remoteStatusInternalServerError", 500) + return fmt.Sprintf("[POST /agent/status][%d] remoteStatusInternalServerError ", 500) } func (o *RemoteStatusInternalServerError) String() string { - return fmt.Sprintf("[POST /agent/status][%d] remoteStatusInternalServerError", 500) + return fmt.Sprintf("[POST /agent/status][%d] remoteStatusInternalServerError ", 500) } func (o *RemoteStatusInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -281,11 +278,11 @@ func (o *RemoteStatusBadGateway) Code() int { } func (o *RemoteStatusBadGateway) Error() string { - return fmt.Sprintf("[POST /agent/status][%d] remoteStatusBadGateway", 502) + return fmt.Sprintf("[POST /agent/status][%d] remoteStatusBadGateway ", 502) } func (o *RemoteStatusBadGateway) String() string { - return fmt.Sprintf("[POST /agent/status][%d] remoteStatusBadGateway", 502) + return fmt.Sprintf("[POST /agent/status][%d] remoteStatusBadGateway ", 502) } func (o *RemoteStatusBadGateway) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/agent/remote_unaccess_responses.go b/rest_client_zrok/agent/remote_unaccess_responses.go index 2a73b5a2..2a4c6aab 100644 --- a/rest_client_zrok/agent/remote_unaccess_responses.go +++ b/rest_client_zrok/agent/remote_unaccess_responses.go @@ -95,11 +95,11 @@ func (o *RemoteUnaccessOK) Code() int { } func (o *RemoteUnaccessOK) Error() string { - return fmt.Sprintf("[POST /agent/unaccess][%d] remoteUnaccessOK", 200) + return fmt.Sprintf("[POST /agent/unaccess][%d] remoteUnaccessOK ", 200) } func (o *RemoteUnaccessOK) String() string { - return fmt.Sprintf("[POST /agent/unaccess][%d] remoteUnaccessOK", 200) + return fmt.Sprintf("[POST /agent/unaccess][%d] remoteUnaccessOK ", 200) } func (o *RemoteUnaccessOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -151,11 +151,11 @@ func (o *RemoteUnaccessUnauthorized) Code() int { } func (o *RemoteUnaccessUnauthorized) Error() string { - return fmt.Sprintf("[POST /agent/unaccess][%d] remoteUnaccessUnauthorized", 401) + return fmt.Sprintf("[POST /agent/unaccess][%d] remoteUnaccessUnauthorized ", 401) } func (o *RemoteUnaccessUnauthorized) String() string { - return fmt.Sprintf("[POST /agent/unaccess][%d] remoteUnaccessUnauthorized", 401) + return fmt.Sprintf("[POST /agent/unaccess][%d] remoteUnaccessUnauthorized ", 401) } func (o *RemoteUnaccessUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -207,11 +207,11 @@ func (o *RemoteUnaccessInternalServerError) Code() int { } func (o *RemoteUnaccessInternalServerError) Error() string { - return fmt.Sprintf("[POST /agent/unaccess][%d] remoteUnaccessInternalServerError", 500) + return fmt.Sprintf("[POST /agent/unaccess][%d] remoteUnaccessInternalServerError ", 500) } func (o *RemoteUnaccessInternalServerError) String() string { - return fmt.Sprintf("[POST /agent/unaccess][%d] remoteUnaccessInternalServerError", 500) + return fmt.Sprintf("[POST /agent/unaccess][%d] remoteUnaccessInternalServerError ", 500) } func (o *RemoteUnaccessInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -263,11 +263,11 @@ func (o *RemoteUnaccessBadGateway) Code() int { } func (o *RemoteUnaccessBadGateway) Error() string { - return fmt.Sprintf("[POST /agent/unaccess][%d] remoteUnaccessBadGateway", 502) + return fmt.Sprintf("[POST /agent/unaccess][%d] remoteUnaccessBadGateway ", 502) } func (o *RemoteUnaccessBadGateway) String() string { - return fmt.Sprintf("[POST /agent/unaccess][%d] remoteUnaccessBadGateway", 502) + return fmt.Sprintf("[POST /agent/unaccess][%d] remoteUnaccessBadGateway ", 502) } func (o *RemoteUnaccessBadGateway) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/agent/remote_unshare_responses.go b/rest_client_zrok/agent/remote_unshare_responses.go index 419f922e..4d04f27f 100644 --- a/rest_client_zrok/agent/remote_unshare_responses.go +++ b/rest_client_zrok/agent/remote_unshare_responses.go @@ -95,11 +95,11 @@ func (o *RemoteUnshareOK) Code() int { } func (o *RemoteUnshareOK) Error() string { - return fmt.Sprintf("[POST /agent/unshare][%d] remoteUnshareOK", 200) + return fmt.Sprintf("[POST /agent/unshare][%d] remoteUnshareOK ", 200) } func (o *RemoteUnshareOK) String() string { - return fmt.Sprintf("[POST /agent/unshare][%d] remoteUnshareOK", 200) + return fmt.Sprintf("[POST /agent/unshare][%d] remoteUnshareOK ", 200) } func (o *RemoteUnshareOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -151,11 +151,11 @@ func (o *RemoteUnshareUnauthorized) Code() int { } func (o *RemoteUnshareUnauthorized) Error() string { - return fmt.Sprintf("[POST /agent/unshare][%d] remoteUnshareUnauthorized", 401) + return fmt.Sprintf("[POST /agent/unshare][%d] remoteUnshareUnauthorized ", 401) } func (o *RemoteUnshareUnauthorized) String() string { - return fmt.Sprintf("[POST /agent/unshare][%d] remoteUnshareUnauthorized", 401) + return fmt.Sprintf("[POST /agent/unshare][%d] remoteUnshareUnauthorized ", 401) } func (o *RemoteUnshareUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -207,11 +207,11 @@ func (o *RemoteUnshareInternalServerError) Code() int { } func (o *RemoteUnshareInternalServerError) Error() string { - return fmt.Sprintf("[POST /agent/unshare][%d] remoteUnshareInternalServerError", 500) + return fmt.Sprintf("[POST /agent/unshare][%d] remoteUnshareInternalServerError ", 500) } func (o *RemoteUnshareInternalServerError) String() string { - return fmt.Sprintf("[POST /agent/unshare][%d] remoteUnshareInternalServerError", 500) + return fmt.Sprintf("[POST /agent/unshare][%d] remoteUnshareInternalServerError ", 500) } func (o *RemoteUnshareInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -263,11 +263,11 @@ func (o *RemoteUnshareBadGateway) Code() int { } func (o *RemoteUnshareBadGateway) Error() string { - return fmt.Sprintf("[POST /agent/unshare][%d] remoteUnshareBadGateway", 502) + return fmt.Sprintf("[POST /agent/unshare][%d] remoteUnshareBadGateway ", 502) } func (o *RemoteUnshareBadGateway) String() string { - return fmt.Sprintf("[POST /agent/unshare][%d] remoteUnshareBadGateway", 502) + return fmt.Sprintf("[POST /agent/unshare][%d] remoteUnshareBadGateway ", 502) } func (o *RemoteUnshareBadGateway) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/agent/unenroll_responses.go b/rest_client_zrok/agent/unenroll_responses.go index 03b85c46..3614e8fd 100644 --- a/rest_client_zrok/agent/unenroll_responses.go +++ b/rest_client_zrok/agent/unenroll_responses.go @@ -95,11 +95,11 @@ func (o *UnenrollOK) Code() int { } func (o *UnenrollOK) Error() string { - return fmt.Sprintf("[POST /agent/unenroll][%d] unenrollOK", 200) + return fmt.Sprintf("[POST /agent/unenroll][%d] unenrollOK ", 200) } func (o *UnenrollOK) String() string { - return fmt.Sprintf("[POST /agent/unenroll][%d] unenrollOK", 200) + return fmt.Sprintf("[POST /agent/unenroll][%d] unenrollOK ", 200) } func (o *UnenrollOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -151,11 +151,11 @@ func (o *UnenrollBadRequest) Code() int { } func (o *UnenrollBadRequest) Error() string { - return fmt.Sprintf("[POST /agent/unenroll][%d] unenrollBadRequest", 400) + return fmt.Sprintf("[POST /agent/unenroll][%d] unenrollBadRequest ", 400) } func (o *UnenrollBadRequest) String() string { - return fmt.Sprintf("[POST /agent/unenroll][%d] unenrollBadRequest", 400) + return fmt.Sprintf("[POST /agent/unenroll][%d] unenrollBadRequest ", 400) } func (o *UnenrollBadRequest) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -207,11 +207,11 @@ func (o *UnenrollUnauthorized) Code() int { } func (o *UnenrollUnauthorized) Error() string { - return fmt.Sprintf("[POST /agent/unenroll][%d] unenrollUnauthorized", 401) + return fmt.Sprintf("[POST /agent/unenroll][%d] unenrollUnauthorized ", 401) } func (o *UnenrollUnauthorized) String() string { - return fmt.Sprintf("[POST /agent/unenroll][%d] unenrollUnauthorized", 401) + return fmt.Sprintf("[POST /agent/unenroll][%d] unenrollUnauthorized ", 401) } func (o *UnenrollUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -263,11 +263,11 @@ func (o *UnenrollInternalServerError) Code() int { } func (o *UnenrollInternalServerError) Error() string { - return fmt.Sprintf("[POST /agent/unenroll][%d] unenrollInternalServerError", 500) + return fmt.Sprintf("[POST /agent/unenroll][%d] unenrollInternalServerError ", 500) } func (o *UnenrollInternalServerError) String() string { - return fmt.Sprintf("[POST /agent/unenroll][%d] unenrollInternalServerError", 500) + return fmt.Sprintf("[POST /agent/unenroll][%d] unenrollInternalServerError ", 500) } func (o *UnenrollInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/environment/disable_responses.go b/rest_client_zrok/environment/disable_responses.go index e7c251e2..e31ae99c 100644 --- a/rest_client_zrok/environment/disable_responses.go +++ b/rest_client_zrok/environment/disable_responses.go @@ -89,11 +89,11 @@ func (o *DisableOK) Code() int { } func (o *DisableOK) Error() string { - return fmt.Sprintf("[POST /disable][%d] disableOK", 200) + return fmt.Sprintf("[POST /disable][%d] disableOK ", 200) } func (o *DisableOK) String() string { - return fmt.Sprintf("[POST /disable][%d] disableOK", 200) + return fmt.Sprintf("[POST /disable][%d] disableOK ", 200) } func (o *DisableOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -145,11 +145,11 @@ func (o *DisableUnauthorized) Code() int { } func (o *DisableUnauthorized) Error() string { - return fmt.Sprintf("[POST /disable][%d] disableUnauthorized", 401) + return fmt.Sprintf("[POST /disable][%d] disableUnauthorized ", 401) } func (o *DisableUnauthorized) String() string { - return fmt.Sprintf("[POST /disable][%d] disableUnauthorized", 401) + return fmt.Sprintf("[POST /disable][%d] disableUnauthorized ", 401) } func (o *DisableUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -201,11 +201,11 @@ func (o *DisableInternalServerError) Code() int { } func (o *DisableInternalServerError) Error() string { - return fmt.Sprintf("[POST /disable][%d] disableInternalServerError", 500) + return fmt.Sprintf("[POST /disable][%d] disableInternalServerError ", 500) } func (o *DisableInternalServerError) String() string { - return fmt.Sprintf("[POST /disable][%d] disableInternalServerError", 500) + return fmt.Sprintf("[POST /disable][%d] disableInternalServerError ", 500) } func (o *DisableInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/environment/enable_responses.go b/rest_client_zrok/environment/enable_responses.go index 08cf9569..e846e122 100644 --- a/rest_client_zrok/environment/enable_responses.go +++ b/rest_client_zrok/environment/enable_responses.go @@ -7,7 +7,6 @@ package environment import ( "context" - "encoding/json" "fmt" "io" @@ -98,13 +97,11 @@ func (o *EnableCreated) Code() int { } func (o *EnableCreated) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /enable][%d] enableCreated %s", 201, payload) + return fmt.Sprintf("[POST /enable][%d] enableCreated %+v", 201, o.Payload) } func (o *EnableCreated) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /enable][%d] enableCreated %s", 201, payload) + return fmt.Sprintf("[POST /enable][%d] enableCreated %+v", 201, o.Payload) } func (o *EnableCreated) GetPayload() *EnableCreatedBody { @@ -167,11 +164,11 @@ func (o *EnableUnauthorized) Code() int { } func (o *EnableUnauthorized) Error() string { - return fmt.Sprintf("[POST /enable][%d] enableUnauthorized", 401) + return fmt.Sprintf("[POST /enable][%d] enableUnauthorized ", 401) } func (o *EnableUnauthorized) String() string { - return fmt.Sprintf("[POST /enable][%d] enableUnauthorized", 401) + return fmt.Sprintf("[POST /enable][%d] enableUnauthorized ", 401) } func (o *EnableUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -223,11 +220,11 @@ func (o *EnableNotFound) Code() int { } func (o *EnableNotFound) Error() string { - return fmt.Sprintf("[POST /enable][%d] enableNotFound", 404) + return fmt.Sprintf("[POST /enable][%d] enableNotFound ", 404) } func (o *EnableNotFound) String() string { - return fmt.Sprintf("[POST /enable][%d] enableNotFound", 404) + return fmt.Sprintf("[POST /enable][%d] enableNotFound ", 404) } func (o *EnableNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -279,11 +276,11 @@ func (o *EnableInternalServerError) Code() int { } func (o *EnableInternalServerError) Error() string { - return fmt.Sprintf("[POST /enable][%d] enableInternalServerError", 500) + return fmt.Sprintf("[POST /enable][%d] enableInternalServerError ", 500) } func (o *EnableInternalServerError) String() string { - return fmt.Sprintf("[POST /enable][%d] enableInternalServerError", 500) + return fmt.Sprintf("[POST /enable][%d] enableInternalServerError ", 500) } func (o *EnableInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/environment/environment_client.go b/rest_client_zrok/environment/environment_client.go index 20db54be..f8463b6e 100644 --- a/rest_client_zrok/environment/environment_client.go +++ b/rest_client_zrok/environment/environment_client.go @@ -9,7 +9,6 @@ import ( "fmt" "github.com/go-openapi/runtime" - httptransport "github.com/go-openapi/runtime/client" "github.com/go-openapi/strfmt" ) @@ -18,31 +17,6 @@ func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientServi return &Client{transport: transport, formats: formats} } -// New creates a new environment API client with basic auth credentials. -// It takes the following parameters: -// - host: http host (github.com). -// - basePath: any base path for the API client ("/v1", "/v3"). -// - scheme: http scheme ("http", "https"). -// - user: user for basic authentication header. -// - password: password for basic authentication header. -func NewClientWithBasicAuth(host, basePath, scheme, user, password string) ClientService { - transport := httptransport.New(host, basePath, []string{scheme}) - transport.DefaultAuthentication = httptransport.BasicAuth(user, password) - return &Client{transport: transport, formats: strfmt.Default} -} - -// New creates a new environment API client with a bearer token for authentication. -// It takes the following parameters: -// - host: http host (github.com). -// - basePath: any base path for the API client ("/v1", "/v3"). -// - scheme: http scheme ("http", "https"). -// - bearerToken: bearer token for Bearer authentication header. -func NewClientWithBearerToken(host, basePath, scheme, bearerToken string) ClientService { - transport := httptransport.New(host, basePath, []string{scheme}) - transport.DefaultAuthentication = httptransport.BearerToken(bearerToken) - return &Client{transport: transport, formats: strfmt.Default} -} - /* Client for environment API */ @@ -51,53 +25,9 @@ type Client struct { formats strfmt.Registry } -// ClientOption may be used to customize the behavior of Client methods. +// ClientOption is the option for Client methods type ClientOption func(*runtime.ClientOperation) -// This client is generated with a few options you might find useful for your swagger spec. -// -// Feel free to add you own set of options. - -// WithContentType allows the client to force the Content-Type header -// to negotiate a specific Consumer from the server. -// -// You may use this option to set arbitrary extensions to your MIME media type. -func WithContentType(mime string) ClientOption { - return func(r *runtime.ClientOperation) { - r.ConsumesMediaTypes = []string{mime} - } -} - -// WithContentTypeApplicationJSON sets the Content-Type header to "application/json". -func WithContentTypeApplicationJSON(r *runtime.ClientOperation) { - r.ConsumesMediaTypes = []string{"application/json"} -} - -// WithContentTypeApplicationZrokV1JSON sets the Content-Type header to "application/zrok.v1+json". -func WithContentTypeApplicationZrokV1JSON(r *runtime.ClientOperation) { - r.ConsumesMediaTypes = []string{"application/zrok.v1+json"} -} - -// WithAccept allows the client to force the Accept header -// to negotiate a specific Producer from the server. -// -// You may use this option to set arbitrary extensions to your MIME media type. -func WithAccept(mime string) ClientOption { - return func(r *runtime.ClientOperation) { - r.ProducesMediaTypes = []string{mime} - } -} - -// WithAcceptApplicationJSON sets the Accept header to "application/json". -func WithAcceptApplicationJSON(r *runtime.ClientOperation) { - r.ProducesMediaTypes = []string{"application/json"} -} - -// WithAcceptApplicationZrokV1JSON sets the Accept header to "application/zrok.v1+json". -func WithAcceptApplicationZrokV1JSON(r *runtime.ClientOperation) { - r.ProducesMediaTypes = []string{"application/zrok.v1+json"} -} - // ClientService is the interface for Client methods type ClientService interface { Disable(params *DisableParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*DisableOK, error) diff --git a/rest_client_zrok/metadata/client_version_check_responses.go b/rest_client_zrok/metadata/client_version_check_responses.go index 94d4e41c..d179f9e5 100644 --- a/rest_client_zrok/metadata/client_version_check_responses.go +++ b/rest_client_zrok/metadata/client_version_check_responses.go @@ -7,7 +7,6 @@ package metadata import ( "context" - "encoding/json" "fmt" "io" @@ -85,11 +84,11 @@ func (o *ClientVersionCheckOK) Code() int { } func (o *ClientVersionCheckOK) Error() string { - return fmt.Sprintf("[POST /clientVersionCheck][%d] clientVersionCheckOK", 200) + return fmt.Sprintf("[POST /clientVersionCheck][%d] clientVersionCheckOK ", 200) } func (o *ClientVersionCheckOK) String() string { - return fmt.Sprintf("[POST /clientVersionCheck][%d] clientVersionCheckOK", 200) + return fmt.Sprintf("[POST /clientVersionCheck][%d] clientVersionCheckOK ", 200) } func (o *ClientVersionCheckOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -142,13 +141,11 @@ func (o *ClientVersionCheckBadRequest) Code() int { } func (o *ClientVersionCheckBadRequest) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /clientVersionCheck][%d] clientVersionCheckBadRequest %s", 400, payload) + return fmt.Sprintf("[POST /clientVersionCheck][%d] clientVersionCheckBadRequest %+v", 400, o.Payload) } func (o *ClientVersionCheckBadRequest) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /clientVersionCheck][%d] clientVersionCheckBadRequest %s", 400, payload) + return fmt.Sprintf("[POST /clientVersionCheck][%d] clientVersionCheckBadRequest %+v", 400, o.Payload) } func (o *ClientVersionCheckBadRequest) GetPayload() string { diff --git a/rest_client_zrok/metadata/configuration_responses.go b/rest_client_zrok/metadata/configuration_responses.go index aad3cff1..792cd003 100644 --- a/rest_client_zrok/metadata/configuration_responses.go +++ b/rest_client_zrok/metadata/configuration_responses.go @@ -6,7 +6,6 @@ package metadata // Editing this file might prove futile when you re-run the swagger generate command import ( - "encoding/json" "fmt" "io" @@ -80,13 +79,11 @@ func (o *ConfigurationOK) Code() int { } func (o *ConfigurationOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /configuration][%d] configurationOK %s", 200, payload) + return fmt.Sprintf("[GET /configuration][%d] configurationOK %+v", 200, o.Payload) } func (o *ConfigurationOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /configuration][%d] configurationOK %s", 200, payload) + return fmt.Sprintf("[GET /configuration][%d] configurationOK %+v", 200, o.Payload) } func (o *ConfigurationOK) GetPayload() *rest_model_zrok.Configuration { diff --git a/rest_client_zrok/metadata/get_account_detail_responses.go b/rest_client_zrok/metadata/get_account_detail_responses.go index ac9253f7..119c3335 100644 --- a/rest_client_zrok/metadata/get_account_detail_responses.go +++ b/rest_client_zrok/metadata/get_account_detail_responses.go @@ -6,7 +6,6 @@ package metadata // Editing this file might prove futile when you re-run the swagger generate command import ( - "encoding/json" "fmt" "io" @@ -86,13 +85,11 @@ func (o *GetAccountDetailOK) Code() int { } func (o *GetAccountDetailOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /detail/account][%d] getAccountDetailOK %s", 200, payload) + return fmt.Sprintf("[GET /detail/account][%d] getAccountDetailOK %+v", 200, o.Payload) } func (o *GetAccountDetailOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /detail/account][%d] getAccountDetailOK %s", 200, payload) + return fmt.Sprintf("[GET /detail/account][%d] getAccountDetailOK %+v", 200, o.Payload) } func (o *GetAccountDetailOK) GetPayload() rest_model_zrok.Environments { @@ -153,11 +150,11 @@ func (o *GetAccountDetailInternalServerError) Code() int { } func (o *GetAccountDetailInternalServerError) Error() string { - return fmt.Sprintf("[GET /detail/account][%d] getAccountDetailInternalServerError", 500) + return fmt.Sprintf("[GET /detail/account][%d] getAccountDetailInternalServerError ", 500) } func (o *GetAccountDetailInternalServerError) String() string { - return fmt.Sprintf("[GET /detail/account][%d] getAccountDetailInternalServerError", 500) + return fmt.Sprintf("[GET /detail/account][%d] getAccountDetailInternalServerError ", 500) } func (o *GetAccountDetailInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/metadata/get_account_metrics_responses.go b/rest_client_zrok/metadata/get_account_metrics_responses.go index fee26dc0..6cc34746 100644 --- a/rest_client_zrok/metadata/get_account_metrics_responses.go +++ b/rest_client_zrok/metadata/get_account_metrics_responses.go @@ -6,7 +6,6 @@ package metadata // Editing this file might prove futile when you re-run the swagger generate command import ( - "encoding/json" "fmt" "io" @@ -92,13 +91,11 @@ func (o *GetAccountMetricsOK) Code() int { } func (o *GetAccountMetricsOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /metrics/account][%d] getAccountMetricsOK %s", 200, payload) + return fmt.Sprintf("[GET /metrics/account][%d] getAccountMetricsOK %+v", 200, o.Payload) } func (o *GetAccountMetricsOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /metrics/account][%d] getAccountMetricsOK %s", 200, payload) + return fmt.Sprintf("[GET /metrics/account][%d] getAccountMetricsOK %+v", 200, o.Payload) } func (o *GetAccountMetricsOK) GetPayload() *rest_model_zrok.Metrics { @@ -161,11 +158,11 @@ func (o *GetAccountMetricsBadRequest) Code() int { } func (o *GetAccountMetricsBadRequest) Error() string { - return fmt.Sprintf("[GET /metrics/account][%d] getAccountMetricsBadRequest", 400) + return fmt.Sprintf("[GET /metrics/account][%d] getAccountMetricsBadRequest ", 400) } func (o *GetAccountMetricsBadRequest) String() string { - return fmt.Sprintf("[GET /metrics/account][%d] getAccountMetricsBadRequest", 400) + return fmt.Sprintf("[GET /metrics/account][%d] getAccountMetricsBadRequest ", 400) } func (o *GetAccountMetricsBadRequest) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -217,11 +214,11 @@ func (o *GetAccountMetricsInternalServerError) Code() int { } func (o *GetAccountMetricsInternalServerError) Error() string { - return fmt.Sprintf("[GET /metrics/account][%d] getAccountMetricsInternalServerError", 500) + return fmt.Sprintf("[GET /metrics/account][%d] getAccountMetricsInternalServerError ", 500) } func (o *GetAccountMetricsInternalServerError) String() string { - return fmt.Sprintf("[GET /metrics/account][%d] getAccountMetricsInternalServerError", 500) + return fmt.Sprintf("[GET /metrics/account][%d] getAccountMetricsInternalServerError ", 500) } func (o *GetAccountMetricsInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/metadata/get_environment_detail_responses.go b/rest_client_zrok/metadata/get_environment_detail_responses.go index 536f30bc..7247746c 100644 --- a/rest_client_zrok/metadata/get_environment_detail_responses.go +++ b/rest_client_zrok/metadata/get_environment_detail_responses.go @@ -6,7 +6,6 @@ package metadata // Editing this file might prove futile when you re-run the swagger generate command import ( - "encoding/json" "fmt" "io" @@ -98,13 +97,11 @@ func (o *GetEnvironmentDetailOK) Code() int { } func (o *GetEnvironmentDetailOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /detail/environment/{envZId}][%d] getEnvironmentDetailOK %s", 200, payload) + return fmt.Sprintf("[GET /detail/environment/{envZId}][%d] getEnvironmentDetailOK %+v", 200, o.Payload) } func (o *GetEnvironmentDetailOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /detail/environment/{envZId}][%d] getEnvironmentDetailOK %s", 200, payload) + return fmt.Sprintf("[GET /detail/environment/{envZId}][%d] getEnvironmentDetailOK %+v", 200, o.Payload) } func (o *GetEnvironmentDetailOK) GetPayload() *rest_model_zrok.EnvironmentAndResources { @@ -167,11 +164,11 @@ func (o *GetEnvironmentDetailUnauthorized) Code() int { } func (o *GetEnvironmentDetailUnauthorized) Error() string { - return fmt.Sprintf("[GET /detail/environment/{envZId}][%d] getEnvironmentDetailUnauthorized", 401) + return fmt.Sprintf("[GET /detail/environment/{envZId}][%d] getEnvironmentDetailUnauthorized ", 401) } func (o *GetEnvironmentDetailUnauthorized) String() string { - return fmt.Sprintf("[GET /detail/environment/{envZId}][%d] getEnvironmentDetailUnauthorized", 401) + return fmt.Sprintf("[GET /detail/environment/{envZId}][%d] getEnvironmentDetailUnauthorized ", 401) } func (o *GetEnvironmentDetailUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -223,11 +220,11 @@ func (o *GetEnvironmentDetailNotFound) Code() int { } func (o *GetEnvironmentDetailNotFound) Error() string { - return fmt.Sprintf("[GET /detail/environment/{envZId}][%d] getEnvironmentDetailNotFound", 404) + return fmt.Sprintf("[GET /detail/environment/{envZId}][%d] getEnvironmentDetailNotFound ", 404) } func (o *GetEnvironmentDetailNotFound) String() string { - return fmt.Sprintf("[GET /detail/environment/{envZId}][%d] getEnvironmentDetailNotFound", 404) + return fmt.Sprintf("[GET /detail/environment/{envZId}][%d] getEnvironmentDetailNotFound ", 404) } func (o *GetEnvironmentDetailNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -279,11 +276,11 @@ func (o *GetEnvironmentDetailInternalServerError) Code() int { } func (o *GetEnvironmentDetailInternalServerError) Error() string { - return fmt.Sprintf("[GET /detail/environment/{envZId}][%d] getEnvironmentDetailInternalServerError", 500) + return fmt.Sprintf("[GET /detail/environment/{envZId}][%d] getEnvironmentDetailInternalServerError ", 500) } func (o *GetEnvironmentDetailInternalServerError) String() string { - return fmt.Sprintf("[GET /detail/environment/{envZId}][%d] getEnvironmentDetailInternalServerError", 500) + return fmt.Sprintf("[GET /detail/environment/{envZId}][%d] getEnvironmentDetailInternalServerError ", 500) } func (o *GetEnvironmentDetailInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/metadata/get_environment_metrics_responses.go b/rest_client_zrok/metadata/get_environment_metrics_responses.go index 6e9e5a9f..0e331725 100644 --- a/rest_client_zrok/metadata/get_environment_metrics_responses.go +++ b/rest_client_zrok/metadata/get_environment_metrics_responses.go @@ -6,7 +6,6 @@ package metadata // Editing this file might prove futile when you re-run the swagger generate command import ( - "encoding/json" "fmt" "io" @@ -98,13 +97,11 @@ func (o *GetEnvironmentMetricsOK) Code() int { } func (o *GetEnvironmentMetricsOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /metrics/environment/{envId}][%d] getEnvironmentMetricsOK %s", 200, payload) + return fmt.Sprintf("[GET /metrics/environment/{envId}][%d] getEnvironmentMetricsOK %+v", 200, o.Payload) } func (o *GetEnvironmentMetricsOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /metrics/environment/{envId}][%d] getEnvironmentMetricsOK %s", 200, payload) + return fmt.Sprintf("[GET /metrics/environment/{envId}][%d] getEnvironmentMetricsOK %+v", 200, o.Payload) } func (o *GetEnvironmentMetricsOK) GetPayload() *rest_model_zrok.Metrics { @@ -167,11 +164,11 @@ func (o *GetEnvironmentMetricsBadRequest) Code() int { } func (o *GetEnvironmentMetricsBadRequest) Error() string { - return fmt.Sprintf("[GET /metrics/environment/{envId}][%d] getEnvironmentMetricsBadRequest", 400) + return fmt.Sprintf("[GET /metrics/environment/{envId}][%d] getEnvironmentMetricsBadRequest ", 400) } func (o *GetEnvironmentMetricsBadRequest) String() string { - return fmt.Sprintf("[GET /metrics/environment/{envId}][%d] getEnvironmentMetricsBadRequest", 400) + return fmt.Sprintf("[GET /metrics/environment/{envId}][%d] getEnvironmentMetricsBadRequest ", 400) } func (o *GetEnvironmentMetricsBadRequest) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -223,11 +220,11 @@ func (o *GetEnvironmentMetricsUnauthorized) Code() int { } func (o *GetEnvironmentMetricsUnauthorized) Error() string { - return fmt.Sprintf("[GET /metrics/environment/{envId}][%d] getEnvironmentMetricsUnauthorized", 401) + return fmt.Sprintf("[GET /metrics/environment/{envId}][%d] getEnvironmentMetricsUnauthorized ", 401) } func (o *GetEnvironmentMetricsUnauthorized) String() string { - return fmt.Sprintf("[GET /metrics/environment/{envId}][%d] getEnvironmentMetricsUnauthorized", 401) + return fmt.Sprintf("[GET /metrics/environment/{envId}][%d] getEnvironmentMetricsUnauthorized ", 401) } func (o *GetEnvironmentMetricsUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -279,11 +276,11 @@ func (o *GetEnvironmentMetricsInternalServerError) Code() int { } func (o *GetEnvironmentMetricsInternalServerError) Error() string { - return fmt.Sprintf("[GET /metrics/environment/{envId}][%d] getEnvironmentMetricsInternalServerError", 500) + return fmt.Sprintf("[GET /metrics/environment/{envId}][%d] getEnvironmentMetricsInternalServerError ", 500) } func (o *GetEnvironmentMetricsInternalServerError) String() string { - return fmt.Sprintf("[GET /metrics/environment/{envId}][%d] getEnvironmentMetricsInternalServerError", 500) + return fmt.Sprintf("[GET /metrics/environment/{envId}][%d] getEnvironmentMetricsInternalServerError ", 500) } func (o *GetEnvironmentMetricsInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/metadata/get_frontend_detail_responses.go b/rest_client_zrok/metadata/get_frontend_detail_responses.go index d4a8df4a..70d44977 100644 --- a/rest_client_zrok/metadata/get_frontend_detail_responses.go +++ b/rest_client_zrok/metadata/get_frontend_detail_responses.go @@ -6,7 +6,6 @@ package metadata // Editing this file might prove futile when you re-run the swagger generate command import ( - "encoding/json" "fmt" "io" @@ -98,13 +97,11 @@ func (o *GetFrontendDetailOK) Code() int { } func (o *GetFrontendDetailOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /detail/frontend/{frontendId}][%d] getFrontendDetailOK %s", 200, payload) + return fmt.Sprintf("[GET /detail/frontend/{frontendId}][%d] getFrontendDetailOK %+v", 200, o.Payload) } func (o *GetFrontendDetailOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /detail/frontend/{frontendId}][%d] getFrontendDetailOK %s", 200, payload) + return fmt.Sprintf("[GET /detail/frontend/{frontendId}][%d] getFrontendDetailOK %+v", 200, o.Payload) } func (o *GetFrontendDetailOK) GetPayload() *rest_model_zrok.Frontend { @@ -167,11 +164,11 @@ func (o *GetFrontendDetailUnauthorized) Code() int { } func (o *GetFrontendDetailUnauthorized) Error() string { - return fmt.Sprintf("[GET /detail/frontend/{frontendId}][%d] getFrontendDetailUnauthorized", 401) + return fmt.Sprintf("[GET /detail/frontend/{frontendId}][%d] getFrontendDetailUnauthorized ", 401) } func (o *GetFrontendDetailUnauthorized) String() string { - return fmt.Sprintf("[GET /detail/frontend/{frontendId}][%d] getFrontendDetailUnauthorized", 401) + return fmt.Sprintf("[GET /detail/frontend/{frontendId}][%d] getFrontendDetailUnauthorized ", 401) } func (o *GetFrontendDetailUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -223,11 +220,11 @@ func (o *GetFrontendDetailNotFound) Code() int { } func (o *GetFrontendDetailNotFound) Error() string { - return fmt.Sprintf("[GET /detail/frontend/{frontendId}][%d] getFrontendDetailNotFound", 404) + return fmt.Sprintf("[GET /detail/frontend/{frontendId}][%d] getFrontendDetailNotFound ", 404) } func (o *GetFrontendDetailNotFound) String() string { - return fmt.Sprintf("[GET /detail/frontend/{frontendId}][%d] getFrontendDetailNotFound", 404) + return fmt.Sprintf("[GET /detail/frontend/{frontendId}][%d] getFrontendDetailNotFound ", 404) } func (o *GetFrontendDetailNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -279,11 +276,11 @@ func (o *GetFrontendDetailInternalServerError) Code() int { } func (o *GetFrontendDetailInternalServerError) Error() string { - return fmt.Sprintf("[GET /detail/frontend/{frontendId}][%d] getFrontendDetailInternalServerError", 500) + return fmt.Sprintf("[GET /detail/frontend/{frontendId}][%d] getFrontendDetailInternalServerError ", 500) } func (o *GetFrontendDetailInternalServerError) String() string { - return fmt.Sprintf("[GET /detail/frontend/{frontendId}][%d] getFrontendDetailInternalServerError", 500) + return fmt.Sprintf("[GET /detail/frontend/{frontendId}][%d] getFrontendDetailInternalServerError ", 500) } func (o *GetFrontendDetailInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/metadata/get_share_detail_responses.go b/rest_client_zrok/metadata/get_share_detail_responses.go index 04aab98f..f319df42 100644 --- a/rest_client_zrok/metadata/get_share_detail_responses.go +++ b/rest_client_zrok/metadata/get_share_detail_responses.go @@ -6,7 +6,6 @@ package metadata // Editing this file might prove futile when you re-run the swagger generate command import ( - "encoding/json" "fmt" "io" @@ -98,13 +97,11 @@ func (o *GetShareDetailOK) Code() int { } func (o *GetShareDetailOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /detail/share/{shareToken}][%d] getShareDetailOK %s", 200, payload) + return fmt.Sprintf("[GET /detail/share/{shareToken}][%d] getShareDetailOK %+v", 200, o.Payload) } func (o *GetShareDetailOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /detail/share/{shareToken}][%d] getShareDetailOK %s", 200, payload) + return fmt.Sprintf("[GET /detail/share/{shareToken}][%d] getShareDetailOK %+v", 200, o.Payload) } func (o *GetShareDetailOK) GetPayload() *rest_model_zrok.Share { @@ -167,11 +164,11 @@ func (o *GetShareDetailUnauthorized) Code() int { } func (o *GetShareDetailUnauthorized) Error() string { - return fmt.Sprintf("[GET /detail/share/{shareToken}][%d] getShareDetailUnauthorized", 401) + return fmt.Sprintf("[GET /detail/share/{shareToken}][%d] getShareDetailUnauthorized ", 401) } func (o *GetShareDetailUnauthorized) String() string { - return fmt.Sprintf("[GET /detail/share/{shareToken}][%d] getShareDetailUnauthorized", 401) + return fmt.Sprintf("[GET /detail/share/{shareToken}][%d] getShareDetailUnauthorized ", 401) } func (o *GetShareDetailUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -223,11 +220,11 @@ func (o *GetShareDetailNotFound) Code() int { } func (o *GetShareDetailNotFound) Error() string { - return fmt.Sprintf("[GET /detail/share/{shareToken}][%d] getShareDetailNotFound", 404) + return fmt.Sprintf("[GET /detail/share/{shareToken}][%d] getShareDetailNotFound ", 404) } func (o *GetShareDetailNotFound) String() string { - return fmt.Sprintf("[GET /detail/share/{shareToken}][%d] getShareDetailNotFound", 404) + return fmt.Sprintf("[GET /detail/share/{shareToken}][%d] getShareDetailNotFound ", 404) } func (o *GetShareDetailNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -279,11 +276,11 @@ func (o *GetShareDetailInternalServerError) Code() int { } func (o *GetShareDetailInternalServerError) Error() string { - return fmt.Sprintf("[GET /detail/share/{shareToken}][%d] getShareDetailInternalServerError", 500) + return fmt.Sprintf("[GET /detail/share/{shareToken}][%d] getShareDetailInternalServerError ", 500) } func (o *GetShareDetailInternalServerError) String() string { - return fmt.Sprintf("[GET /detail/share/{shareToken}][%d] getShareDetailInternalServerError", 500) + return fmt.Sprintf("[GET /detail/share/{shareToken}][%d] getShareDetailInternalServerError ", 500) } func (o *GetShareDetailInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/metadata/get_share_metrics_responses.go b/rest_client_zrok/metadata/get_share_metrics_responses.go index 9b14fbe0..242760ef 100644 --- a/rest_client_zrok/metadata/get_share_metrics_responses.go +++ b/rest_client_zrok/metadata/get_share_metrics_responses.go @@ -6,7 +6,6 @@ package metadata // Editing this file might prove futile when you re-run the swagger generate command import ( - "encoding/json" "fmt" "io" @@ -98,13 +97,11 @@ func (o *GetShareMetricsOK) Code() int { } func (o *GetShareMetricsOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /metrics/share/{shareToken}][%d] getShareMetricsOK %s", 200, payload) + return fmt.Sprintf("[GET /metrics/share/{shareToken}][%d] getShareMetricsOK %+v", 200, o.Payload) } func (o *GetShareMetricsOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /metrics/share/{shareToken}][%d] getShareMetricsOK %s", 200, payload) + return fmt.Sprintf("[GET /metrics/share/{shareToken}][%d] getShareMetricsOK %+v", 200, o.Payload) } func (o *GetShareMetricsOK) GetPayload() *rest_model_zrok.Metrics { @@ -167,11 +164,11 @@ func (o *GetShareMetricsBadRequest) Code() int { } func (o *GetShareMetricsBadRequest) Error() string { - return fmt.Sprintf("[GET /metrics/share/{shareToken}][%d] getShareMetricsBadRequest", 400) + return fmt.Sprintf("[GET /metrics/share/{shareToken}][%d] getShareMetricsBadRequest ", 400) } func (o *GetShareMetricsBadRequest) String() string { - return fmt.Sprintf("[GET /metrics/share/{shareToken}][%d] getShareMetricsBadRequest", 400) + return fmt.Sprintf("[GET /metrics/share/{shareToken}][%d] getShareMetricsBadRequest ", 400) } func (o *GetShareMetricsBadRequest) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -223,11 +220,11 @@ func (o *GetShareMetricsUnauthorized) Code() int { } func (o *GetShareMetricsUnauthorized) Error() string { - return fmt.Sprintf("[GET /metrics/share/{shareToken}][%d] getShareMetricsUnauthorized", 401) + return fmt.Sprintf("[GET /metrics/share/{shareToken}][%d] getShareMetricsUnauthorized ", 401) } func (o *GetShareMetricsUnauthorized) String() string { - return fmt.Sprintf("[GET /metrics/share/{shareToken}][%d] getShareMetricsUnauthorized", 401) + return fmt.Sprintf("[GET /metrics/share/{shareToken}][%d] getShareMetricsUnauthorized ", 401) } func (o *GetShareMetricsUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -279,11 +276,11 @@ func (o *GetShareMetricsInternalServerError) Code() int { } func (o *GetShareMetricsInternalServerError) Error() string { - return fmt.Sprintf("[GET /metrics/share/{shareToken}][%d] getShareMetricsInternalServerError", 500) + return fmt.Sprintf("[GET /metrics/share/{shareToken}][%d] getShareMetricsInternalServerError ", 500) } func (o *GetShareMetricsInternalServerError) String() string { - return fmt.Sprintf("[GET /metrics/share/{shareToken}][%d] getShareMetricsInternalServerError", 500) + return fmt.Sprintf("[GET /metrics/share/{shareToken}][%d] getShareMetricsInternalServerError ", 500) } func (o *GetShareMetricsInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/metadata/get_sparklines_responses.go b/rest_client_zrok/metadata/get_sparklines_responses.go index 00baa63e..65747107 100644 --- a/rest_client_zrok/metadata/get_sparklines_responses.go +++ b/rest_client_zrok/metadata/get_sparklines_responses.go @@ -7,7 +7,6 @@ package metadata import ( "context" - "encoding/json" "fmt" "io" "strconv" @@ -96,13 +95,11 @@ func (o *GetSparklinesOK) Code() int { } func (o *GetSparklinesOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /sparklines][%d] getSparklinesOK %s", 200, payload) + return fmt.Sprintf("[POST /sparklines][%d] getSparklinesOK %+v", 200, o.Payload) } func (o *GetSparklinesOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /sparklines][%d] getSparklinesOK %s", 200, payload) + return fmt.Sprintf("[POST /sparklines][%d] getSparklinesOK %+v", 200, o.Payload) } func (o *GetSparklinesOK) GetPayload() *GetSparklinesOKBody { @@ -165,11 +162,11 @@ func (o *GetSparklinesUnauthorized) Code() int { } func (o *GetSparklinesUnauthorized) Error() string { - return fmt.Sprintf("[POST /sparklines][%d] getSparklinesUnauthorized", 401) + return fmt.Sprintf("[POST /sparklines][%d] getSparklinesUnauthorized ", 401) } func (o *GetSparklinesUnauthorized) String() string { - return fmt.Sprintf("[POST /sparklines][%d] getSparklinesUnauthorized", 401) + return fmt.Sprintf("[POST /sparklines][%d] getSparklinesUnauthorized ", 401) } func (o *GetSparklinesUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -221,11 +218,11 @@ func (o *GetSparklinesInternalServerError) Code() int { } func (o *GetSparklinesInternalServerError) Error() string { - return fmt.Sprintf("[POST /sparklines][%d] getSparklinesInternalServerError", 500) + return fmt.Sprintf("[POST /sparklines][%d] getSparklinesInternalServerError ", 500) } func (o *GetSparklinesInternalServerError) String() string { - return fmt.Sprintf("[POST /sparklines][%d] getSparklinesInternalServerError", 500) + return fmt.Sprintf("[POST /sparklines][%d] getSparklinesInternalServerError ", 500) } func (o *GetSparklinesInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/metadata/list_memberships_responses.go b/rest_client_zrok/metadata/list_memberships_responses.go index 1dbf9624..2ea41233 100644 --- a/rest_client_zrok/metadata/list_memberships_responses.go +++ b/rest_client_zrok/metadata/list_memberships_responses.go @@ -7,7 +7,6 @@ package metadata import ( "context" - "encoding/json" "fmt" "io" "strconv" @@ -88,13 +87,11 @@ func (o *ListMembershipsOK) Code() int { } func (o *ListMembershipsOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /memberships][%d] listMembershipsOK %s", 200, payload) + return fmt.Sprintf("[GET /memberships][%d] listMembershipsOK %+v", 200, o.Payload) } func (o *ListMembershipsOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /memberships][%d] listMembershipsOK %s", 200, payload) + return fmt.Sprintf("[GET /memberships][%d] listMembershipsOK %+v", 200, o.Payload) } func (o *ListMembershipsOK) GetPayload() *ListMembershipsOKBody { @@ -157,11 +154,11 @@ func (o *ListMembershipsInternalServerError) Code() int { } func (o *ListMembershipsInternalServerError) Error() string { - return fmt.Sprintf("[GET /memberships][%d] listMembershipsInternalServerError", 500) + return fmt.Sprintf("[GET /memberships][%d] listMembershipsInternalServerError ", 500) } func (o *ListMembershipsInternalServerError) String() string { - return fmt.Sprintf("[GET /memberships][%d] listMembershipsInternalServerError", 500) + return fmt.Sprintf("[GET /memberships][%d] listMembershipsInternalServerError ", 500) } func (o *ListMembershipsInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/metadata/list_org_members_responses.go b/rest_client_zrok/metadata/list_org_members_responses.go index 7a28a4d8..138ef025 100644 --- a/rest_client_zrok/metadata/list_org_members_responses.go +++ b/rest_client_zrok/metadata/list_org_members_responses.go @@ -7,7 +7,6 @@ package metadata import ( "context" - "encoding/json" "fmt" "io" "strconv" @@ -94,13 +93,11 @@ func (o *ListOrgMembersOK) Code() int { } func (o *ListOrgMembersOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /members/{organizationToken}][%d] listOrgMembersOK %s", 200, payload) + return fmt.Sprintf("[GET /members/{organizationToken}][%d] listOrgMembersOK %+v", 200, o.Payload) } func (o *ListOrgMembersOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /members/{organizationToken}][%d] listOrgMembersOK %s", 200, payload) + return fmt.Sprintf("[GET /members/{organizationToken}][%d] listOrgMembersOK %+v", 200, o.Payload) } func (o *ListOrgMembersOK) GetPayload() *ListOrgMembersOKBody { @@ -163,11 +160,11 @@ func (o *ListOrgMembersNotFound) Code() int { } func (o *ListOrgMembersNotFound) Error() string { - return fmt.Sprintf("[GET /members/{organizationToken}][%d] listOrgMembersNotFound", 404) + return fmt.Sprintf("[GET /members/{organizationToken}][%d] listOrgMembersNotFound ", 404) } func (o *ListOrgMembersNotFound) String() string { - return fmt.Sprintf("[GET /members/{organizationToken}][%d] listOrgMembersNotFound", 404) + return fmt.Sprintf("[GET /members/{organizationToken}][%d] listOrgMembersNotFound ", 404) } func (o *ListOrgMembersNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -219,11 +216,11 @@ func (o *ListOrgMembersInternalServerError) Code() int { } func (o *ListOrgMembersInternalServerError) Error() string { - return fmt.Sprintf("[GET /members/{organizationToken}][%d] listOrgMembersInternalServerError", 500) + return fmt.Sprintf("[GET /members/{organizationToken}][%d] listOrgMembersInternalServerError ", 500) } func (o *ListOrgMembersInternalServerError) String() string { - return fmt.Sprintf("[GET /members/{organizationToken}][%d] listOrgMembersInternalServerError", 500) + return fmt.Sprintf("[GET /members/{organizationToken}][%d] listOrgMembersInternalServerError ", 500) } func (o *ListOrgMembersInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/metadata/metadata_client.go b/rest_client_zrok/metadata/metadata_client.go index 2871fe05..4682edbb 100644 --- a/rest_client_zrok/metadata/metadata_client.go +++ b/rest_client_zrok/metadata/metadata_client.go @@ -9,7 +9,6 @@ import ( "fmt" "github.com/go-openapi/runtime" - httptransport "github.com/go-openapi/runtime/client" "github.com/go-openapi/strfmt" ) @@ -18,31 +17,6 @@ func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientServi return &Client{transport: transport, formats: formats} } -// New creates a new metadata API client with basic auth credentials. -// It takes the following parameters: -// - host: http host (github.com). -// - basePath: any base path for the API client ("/v1", "/v3"). -// - scheme: http scheme ("http", "https"). -// - user: user for basic authentication header. -// - password: password for basic authentication header. -func NewClientWithBasicAuth(host, basePath, scheme, user, password string) ClientService { - transport := httptransport.New(host, basePath, []string{scheme}) - transport.DefaultAuthentication = httptransport.BasicAuth(user, password) - return &Client{transport: transport, formats: strfmt.Default} -} - -// New creates a new metadata API client with a bearer token for authentication. -// It takes the following parameters: -// - host: http host (github.com). -// - basePath: any base path for the API client ("/v1", "/v3"). -// - scheme: http scheme ("http", "https"). -// - bearerToken: bearer token for Bearer authentication header. -func NewClientWithBearerToken(host, basePath, scheme, bearerToken string) ClientService { - transport := httptransport.New(host, basePath, []string{scheme}) - transport.DefaultAuthentication = httptransport.BearerToken(bearerToken) - return &Client{transport: transport, formats: strfmt.Default} -} - /* Client for metadata API */ @@ -51,53 +25,9 @@ type Client struct { formats strfmt.Registry } -// ClientOption may be used to customize the behavior of Client methods. +// ClientOption is the option for Client methods type ClientOption func(*runtime.ClientOperation) -// This client is generated with a few options you might find useful for your swagger spec. -// -// Feel free to add you own set of options. - -// WithContentType allows the client to force the Content-Type header -// to negotiate a specific Consumer from the server. -// -// You may use this option to set arbitrary extensions to your MIME media type. -func WithContentType(mime string) ClientOption { - return func(r *runtime.ClientOperation) { - r.ConsumesMediaTypes = []string{mime} - } -} - -// WithContentTypeApplicationJSON sets the Content-Type header to "application/json". -func WithContentTypeApplicationJSON(r *runtime.ClientOperation) { - r.ConsumesMediaTypes = []string{"application/json"} -} - -// WithContentTypeApplicationZrokV1JSON sets the Content-Type header to "application/zrok.v1+json". -func WithContentTypeApplicationZrokV1JSON(r *runtime.ClientOperation) { - r.ConsumesMediaTypes = []string{"application/zrok.v1+json"} -} - -// WithAccept allows the client to force the Accept header -// to negotiate a specific Producer from the server. -// -// You may use this option to set arbitrary extensions to your MIME media type. -func WithAccept(mime string) ClientOption { - return func(r *runtime.ClientOperation) { - r.ProducesMediaTypes = []string{mime} - } -} - -// WithAcceptApplicationJSON sets the Accept header to "application/json". -func WithAcceptApplicationJSON(r *runtime.ClientOperation) { - r.ProducesMediaTypes = []string{"application/json"} -} - -// WithAcceptApplicationZrokV1JSON sets the Accept header to "application/zrok.v1+json". -func WithAcceptApplicationZrokV1JSON(r *runtime.ClientOperation) { - r.ProducesMediaTypes = []string{"application/zrok.v1+json"} -} - // ClientService is the interface for Client methods type ClientService interface { ClientVersionCheck(params *ClientVersionCheckParams, opts ...ClientOption) (*ClientVersionCheckOK, error) diff --git a/rest_client_zrok/metadata/org_account_overview_responses.go b/rest_client_zrok/metadata/org_account_overview_responses.go index 6fa4ba93..11f69a0e 100644 --- a/rest_client_zrok/metadata/org_account_overview_responses.go +++ b/rest_client_zrok/metadata/org_account_overview_responses.go @@ -6,7 +6,6 @@ package metadata // Editing this file might prove futile when you re-run the swagger generate command import ( - "encoding/json" "fmt" "io" @@ -92,13 +91,11 @@ func (o *OrgAccountOverviewOK) Code() int { } func (o *OrgAccountOverviewOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /overview/{organizationToken}/{accountEmail}][%d] orgAccountOverviewOK %s", 200, payload) + return fmt.Sprintf("[GET /overview/{organizationToken}/{accountEmail}][%d] orgAccountOverviewOK %+v", 200, o.Payload) } func (o *OrgAccountOverviewOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /overview/{organizationToken}/{accountEmail}][%d] orgAccountOverviewOK %s", 200, payload) + return fmt.Sprintf("[GET /overview/{organizationToken}/{accountEmail}][%d] orgAccountOverviewOK %+v", 200, o.Payload) } func (o *OrgAccountOverviewOK) GetPayload() *rest_model_zrok.Overview { @@ -161,11 +158,11 @@ func (o *OrgAccountOverviewNotFound) Code() int { } func (o *OrgAccountOverviewNotFound) Error() string { - return fmt.Sprintf("[GET /overview/{organizationToken}/{accountEmail}][%d] orgAccountOverviewNotFound", 404) + return fmt.Sprintf("[GET /overview/{organizationToken}/{accountEmail}][%d] orgAccountOverviewNotFound ", 404) } func (o *OrgAccountOverviewNotFound) String() string { - return fmt.Sprintf("[GET /overview/{organizationToken}/{accountEmail}][%d] orgAccountOverviewNotFound", 404) + return fmt.Sprintf("[GET /overview/{organizationToken}/{accountEmail}][%d] orgAccountOverviewNotFound ", 404) } func (o *OrgAccountOverviewNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -217,11 +214,11 @@ func (o *OrgAccountOverviewInternalServerError) Code() int { } func (o *OrgAccountOverviewInternalServerError) Error() string { - return fmt.Sprintf("[GET /overview/{organizationToken}/{accountEmail}][%d] orgAccountOverviewInternalServerError", 500) + return fmt.Sprintf("[GET /overview/{organizationToken}/{accountEmail}][%d] orgAccountOverviewInternalServerError ", 500) } func (o *OrgAccountOverviewInternalServerError) String() string { - return fmt.Sprintf("[GET /overview/{organizationToken}/{accountEmail}][%d] orgAccountOverviewInternalServerError", 500) + return fmt.Sprintf("[GET /overview/{organizationToken}/{accountEmail}][%d] orgAccountOverviewInternalServerError ", 500) } func (o *OrgAccountOverviewInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/metadata/overview_responses.go b/rest_client_zrok/metadata/overview_responses.go index f6ff75c3..9b3b6be4 100644 --- a/rest_client_zrok/metadata/overview_responses.go +++ b/rest_client_zrok/metadata/overview_responses.go @@ -6,7 +6,6 @@ package metadata // Editing this file might prove futile when you re-run the swagger generate command import ( - "encoding/json" "fmt" "io" @@ -86,13 +85,11 @@ func (o *OverviewOK) Code() int { } func (o *OverviewOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /overview][%d] overviewOK %s", 200, payload) + return fmt.Sprintf("[GET /overview][%d] overviewOK %+v", 200, o.Payload) } func (o *OverviewOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /overview][%d] overviewOK %s", 200, payload) + return fmt.Sprintf("[GET /overview][%d] overviewOK %+v", 200, o.Payload) } func (o *OverviewOK) GetPayload() *rest_model_zrok.Overview { @@ -156,13 +153,11 @@ func (o *OverviewInternalServerError) Code() int { } func (o *OverviewInternalServerError) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /overview][%d] overviewInternalServerError %s", 500, payload) + return fmt.Sprintf("[GET /overview][%d] overviewInternalServerError %+v", 500, o.Payload) } func (o *OverviewInternalServerError) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /overview][%d] overviewInternalServerError %s", 500, payload) + return fmt.Sprintf("[GET /overview][%d] overviewInternalServerError %+v", 500, o.Payload) } func (o *OverviewInternalServerError) GetPayload() rest_model_zrok.ErrorMessage { diff --git a/rest_client_zrok/metadata/version_inventory_responses.go b/rest_client_zrok/metadata/version_inventory_responses.go index 9080d4d5..258dfebc 100644 --- a/rest_client_zrok/metadata/version_inventory_responses.go +++ b/rest_client_zrok/metadata/version_inventory_responses.go @@ -7,7 +7,6 @@ package metadata import ( "context" - "encoding/json" "fmt" "io" @@ -80,13 +79,11 @@ func (o *VersionInventoryOK) Code() int { } func (o *VersionInventoryOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /versions][%d] versionInventoryOK %s", 200, payload) + return fmt.Sprintf("[GET /versions][%d] versionInventoryOK %+v", 200, o.Payload) } func (o *VersionInventoryOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /versions][%d] versionInventoryOK %s", 200, payload) + return fmt.Sprintf("[GET /versions][%d] versionInventoryOK %+v", 200, o.Payload) } func (o *VersionInventoryOK) GetPayload() *VersionInventoryOKBody { diff --git a/rest_client_zrok/metadata/version_responses.go b/rest_client_zrok/metadata/version_responses.go index 0a917227..de978ab5 100644 --- a/rest_client_zrok/metadata/version_responses.go +++ b/rest_client_zrok/metadata/version_responses.go @@ -6,7 +6,6 @@ package metadata // Editing this file might prove futile when you re-run the swagger generate command import ( - "encoding/json" "fmt" "io" @@ -80,13 +79,11 @@ func (o *VersionOK) Code() int { } func (o *VersionOK) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /version][%d] versionOK %s", 200, payload) + return fmt.Sprintf("[GET /version][%d] versionOK %+v", 200, o.Payload) } func (o *VersionOK) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[GET /version][%d] versionOK %s", 200, payload) + return fmt.Sprintf("[GET /version][%d] versionOK %+v", 200, o.Payload) } func (o *VersionOK) GetPayload() rest_model_zrok.Version { diff --git a/rest_client_zrok/share/access_responses.go b/rest_client_zrok/share/access_responses.go index 30f275d8..6e476af5 100644 --- a/rest_client_zrok/share/access_responses.go +++ b/rest_client_zrok/share/access_responses.go @@ -7,7 +7,6 @@ package share import ( "context" - "encoding/json" "fmt" "io" @@ -98,13 +97,11 @@ func (o *AccessCreated) Code() int { } func (o *AccessCreated) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /access][%d] accessCreated %s", 201, payload) + return fmt.Sprintf("[POST /access][%d] accessCreated %+v", 201, o.Payload) } func (o *AccessCreated) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /access][%d] accessCreated %s", 201, payload) + return fmt.Sprintf("[POST /access][%d] accessCreated %+v", 201, o.Payload) } func (o *AccessCreated) GetPayload() *AccessCreatedBody { @@ -167,11 +164,11 @@ func (o *AccessUnauthorized) Code() int { } func (o *AccessUnauthorized) Error() string { - return fmt.Sprintf("[POST /access][%d] accessUnauthorized", 401) + return fmt.Sprintf("[POST /access][%d] accessUnauthorized ", 401) } func (o *AccessUnauthorized) String() string { - return fmt.Sprintf("[POST /access][%d] accessUnauthorized", 401) + return fmt.Sprintf("[POST /access][%d] accessUnauthorized ", 401) } func (o *AccessUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -223,11 +220,11 @@ func (o *AccessNotFound) Code() int { } func (o *AccessNotFound) Error() string { - return fmt.Sprintf("[POST /access][%d] accessNotFound", 404) + return fmt.Sprintf("[POST /access][%d] accessNotFound ", 404) } func (o *AccessNotFound) String() string { - return fmt.Sprintf("[POST /access][%d] accessNotFound", 404) + return fmt.Sprintf("[POST /access][%d] accessNotFound ", 404) } func (o *AccessNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -279,11 +276,11 @@ func (o *AccessInternalServerError) Code() int { } func (o *AccessInternalServerError) Error() string { - return fmt.Sprintf("[POST /access][%d] accessInternalServerError", 500) + return fmt.Sprintf("[POST /access][%d] accessInternalServerError ", 500) } func (o *AccessInternalServerError) String() string { - return fmt.Sprintf("[POST /access][%d] accessInternalServerError", 500) + return fmt.Sprintf("[POST /access][%d] accessInternalServerError ", 500) } func (o *AccessInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/share/share_client.go b/rest_client_zrok/share/share_client.go index 7476a930..48acfa17 100644 --- a/rest_client_zrok/share/share_client.go +++ b/rest_client_zrok/share/share_client.go @@ -9,7 +9,6 @@ import ( "fmt" "github.com/go-openapi/runtime" - httptransport "github.com/go-openapi/runtime/client" "github.com/go-openapi/strfmt" ) @@ -18,31 +17,6 @@ func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientServi return &Client{transport: transport, formats: formats} } -// New creates a new share API client with basic auth credentials. -// It takes the following parameters: -// - host: http host (github.com). -// - basePath: any base path for the API client ("/v1", "/v3"). -// - scheme: http scheme ("http", "https"). -// - user: user for basic authentication header. -// - password: password for basic authentication header. -func NewClientWithBasicAuth(host, basePath, scheme, user, password string) ClientService { - transport := httptransport.New(host, basePath, []string{scheme}) - transport.DefaultAuthentication = httptransport.BasicAuth(user, password) - return &Client{transport: transport, formats: strfmt.Default} -} - -// New creates a new share API client with a bearer token for authentication. -// It takes the following parameters: -// - host: http host (github.com). -// - basePath: any base path for the API client ("/v1", "/v3"). -// - scheme: http scheme ("http", "https"). -// - bearerToken: bearer token for Bearer authentication header. -func NewClientWithBearerToken(host, basePath, scheme, bearerToken string) ClientService { - transport := httptransport.New(host, basePath, []string{scheme}) - transport.DefaultAuthentication = httptransport.BearerToken(bearerToken) - return &Client{transport: transport, formats: strfmt.Default} -} - /* Client for share API */ @@ -51,53 +25,9 @@ type Client struct { formats strfmt.Registry } -// ClientOption may be used to customize the behavior of Client methods. +// ClientOption is the option for Client methods type ClientOption func(*runtime.ClientOperation) -// This client is generated with a few options you might find useful for your swagger spec. -// -// Feel free to add you own set of options. - -// WithContentType allows the client to force the Content-Type header -// to negotiate a specific Consumer from the server. -// -// You may use this option to set arbitrary extensions to your MIME media type. -func WithContentType(mime string) ClientOption { - return func(r *runtime.ClientOperation) { - r.ConsumesMediaTypes = []string{mime} - } -} - -// WithContentTypeApplicationJSON sets the Content-Type header to "application/json". -func WithContentTypeApplicationJSON(r *runtime.ClientOperation) { - r.ConsumesMediaTypes = []string{"application/json"} -} - -// WithContentTypeApplicationZrokV1JSON sets the Content-Type header to "application/zrok.v1+json". -func WithContentTypeApplicationZrokV1JSON(r *runtime.ClientOperation) { - r.ConsumesMediaTypes = []string{"application/zrok.v1+json"} -} - -// WithAccept allows the client to force the Accept header -// to negotiate a specific Producer from the server. -// -// You may use this option to set arbitrary extensions to your MIME media type. -func WithAccept(mime string) ClientOption { - return func(r *runtime.ClientOperation) { - r.ProducesMediaTypes = []string{mime} - } -} - -// WithAcceptApplicationJSON sets the Accept header to "application/json". -func WithAcceptApplicationJSON(r *runtime.ClientOperation) { - r.ProducesMediaTypes = []string{"application/json"} -} - -// WithAcceptApplicationZrokV1JSON sets the Accept header to "application/zrok.v1+json". -func WithAcceptApplicationZrokV1JSON(r *runtime.ClientOperation) { - r.ProducesMediaTypes = []string{"application/zrok.v1+json"} -} - // ClientService is the interface for Client methods type ClientService interface { Access(params *AccessParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*AccessCreated, error) diff --git a/rest_client_zrok/share/share_responses.go b/rest_client_zrok/share/share_responses.go index f7dfe691..8af0e374 100644 --- a/rest_client_zrok/share/share_responses.go +++ b/rest_client_zrok/share/share_responses.go @@ -6,7 +6,6 @@ package share // Editing this file might prove futile when you re-run the swagger generate command import ( - "encoding/json" "fmt" "io" @@ -110,13 +109,11 @@ func (o *ShareCreated) Code() int { } func (o *ShareCreated) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /share][%d] shareCreated %s", 201, payload) + return fmt.Sprintf("[POST /share][%d] shareCreated %+v", 201, o.Payload) } func (o *ShareCreated) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /share][%d] shareCreated %s", 201, payload) + return fmt.Sprintf("[POST /share][%d] shareCreated %+v", 201, o.Payload) } func (o *ShareCreated) GetPayload() *rest_model_zrok.ShareResponse { @@ -179,11 +176,11 @@ func (o *ShareUnauthorized) Code() int { } func (o *ShareUnauthorized) Error() string { - return fmt.Sprintf("[POST /share][%d] shareUnauthorized", 401) + return fmt.Sprintf("[POST /share][%d] shareUnauthorized ", 401) } func (o *ShareUnauthorized) String() string { - return fmt.Sprintf("[POST /share][%d] shareUnauthorized", 401) + return fmt.Sprintf("[POST /share][%d] shareUnauthorized ", 401) } func (o *ShareUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -235,11 +232,11 @@ func (o *ShareNotFound) Code() int { } func (o *ShareNotFound) Error() string { - return fmt.Sprintf("[POST /share][%d] shareNotFound", 404) + return fmt.Sprintf("[POST /share][%d] shareNotFound ", 404) } func (o *ShareNotFound) String() string { - return fmt.Sprintf("[POST /share][%d] shareNotFound", 404) + return fmt.Sprintf("[POST /share][%d] shareNotFound ", 404) } func (o *ShareNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -291,11 +288,11 @@ func (o *ShareConflict) Code() int { } func (o *ShareConflict) Error() string { - return fmt.Sprintf("[POST /share][%d] shareConflict", 409) + return fmt.Sprintf("[POST /share][%d] shareConflict ", 409) } func (o *ShareConflict) String() string { - return fmt.Sprintf("[POST /share][%d] shareConflict", 409) + return fmt.Sprintf("[POST /share][%d] shareConflict ", 409) } func (o *ShareConflict) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -347,11 +344,11 @@ func (o *ShareUnprocessableEntity) Code() int { } func (o *ShareUnprocessableEntity) Error() string { - return fmt.Sprintf("[POST /share][%d] shareUnprocessableEntity", 422) + return fmt.Sprintf("[POST /share][%d] shareUnprocessableEntity ", 422) } func (o *ShareUnprocessableEntity) String() string { - return fmt.Sprintf("[POST /share][%d] shareUnprocessableEntity", 422) + return fmt.Sprintf("[POST /share][%d] shareUnprocessableEntity ", 422) } func (o *ShareUnprocessableEntity) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -404,13 +401,11 @@ func (o *ShareInternalServerError) Code() int { } func (o *ShareInternalServerError) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /share][%d] shareInternalServerError %s", 500, payload) + return fmt.Sprintf("[POST /share][%d] shareInternalServerError %+v", 500, o.Payload) } func (o *ShareInternalServerError) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[POST /share][%d] shareInternalServerError %s", 500, payload) + return fmt.Sprintf("[POST /share][%d] shareInternalServerError %+v", 500, o.Payload) } func (o *ShareInternalServerError) GetPayload() rest_model_zrok.ErrorMessage { diff --git a/rest_client_zrok/share/unaccess_responses.go b/rest_client_zrok/share/unaccess_responses.go index 66a174b3..2f5579bf 100644 --- a/rest_client_zrok/share/unaccess_responses.go +++ b/rest_client_zrok/share/unaccess_responses.go @@ -95,11 +95,11 @@ func (o *UnaccessOK) Code() int { } func (o *UnaccessOK) Error() string { - return fmt.Sprintf("[DELETE /unaccess][%d] unaccessOK", 200) + return fmt.Sprintf("[DELETE /unaccess][%d] unaccessOK ", 200) } func (o *UnaccessOK) String() string { - return fmt.Sprintf("[DELETE /unaccess][%d] unaccessOK", 200) + return fmt.Sprintf("[DELETE /unaccess][%d] unaccessOK ", 200) } func (o *UnaccessOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -151,11 +151,11 @@ func (o *UnaccessUnauthorized) Code() int { } func (o *UnaccessUnauthorized) Error() string { - return fmt.Sprintf("[DELETE /unaccess][%d] unaccessUnauthorized", 401) + return fmt.Sprintf("[DELETE /unaccess][%d] unaccessUnauthorized ", 401) } func (o *UnaccessUnauthorized) String() string { - return fmt.Sprintf("[DELETE /unaccess][%d] unaccessUnauthorized", 401) + return fmt.Sprintf("[DELETE /unaccess][%d] unaccessUnauthorized ", 401) } func (o *UnaccessUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -207,11 +207,11 @@ func (o *UnaccessNotFound) Code() int { } func (o *UnaccessNotFound) Error() string { - return fmt.Sprintf("[DELETE /unaccess][%d] unaccessNotFound", 404) + return fmt.Sprintf("[DELETE /unaccess][%d] unaccessNotFound ", 404) } func (o *UnaccessNotFound) String() string { - return fmt.Sprintf("[DELETE /unaccess][%d] unaccessNotFound", 404) + return fmt.Sprintf("[DELETE /unaccess][%d] unaccessNotFound ", 404) } func (o *UnaccessNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -263,11 +263,11 @@ func (o *UnaccessInternalServerError) Code() int { } func (o *UnaccessInternalServerError) Error() string { - return fmt.Sprintf("[DELETE /unaccess][%d] unaccessInternalServerError", 500) + return fmt.Sprintf("[DELETE /unaccess][%d] unaccessInternalServerError ", 500) } func (o *UnaccessInternalServerError) String() string { - return fmt.Sprintf("[DELETE /unaccess][%d] unaccessInternalServerError", 500) + return fmt.Sprintf("[DELETE /unaccess][%d] unaccessInternalServerError ", 500) } func (o *UnaccessInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/share/unshare_responses.go b/rest_client_zrok/share/unshare_responses.go index 40a2e1c2..7e1d1d62 100644 --- a/rest_client_zrok/share/unshare_responses.go +++ b/rest_client_zrok/share/unshare_responses.go @@ -7,7 +7,6 @@ package share import ( "context" - "encoding/json" "fmt" "io" @@ -99,11 +98,11 @@ func (o *UnshareOK) Code() int { } func (o *UnshareOK) Error() string { - return fmt.Sprintf("[DELETE /unshare][%d] unshareOK", 200) + return fmt.Sprintf("[DELETE /unshare][%d] unshareOK ", 200) } func (o *UnshareOK) String() string { - return fmt.Sprintf("[DELETE /unshare][%d] unshareOK", 200) + return fmt.Sprintf("[DELETE /unshare][%d] unshareOK ", 200) } func (o *UnshareOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -155,11 +154,11 @@ func (o *UnshareUnauthorized) Code() int { } func (o *UnshareUnauthorized) Error() string { - return fmt.Sprintf("[DELETE /unshare][%d] unshareUnauthorized", 401) + return fmt.Sprintf("[DELETE /unshare][%d] unshareUnauthorized ", 401) } func (o *UnshareUnauthorized) String() string { - return fmt.Sprintf("[DELETE /unshare][%d] unshareUnauthorized", 401) + return fmt.Sprintf("[DELETE /unshare][%d] unshareUnauthorized ", 401) } func (o *UnshareUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -211,11 +210,11 @@ func (o *UnshareNotFound) Code() int { } func (o *UnshareNotFound) Error() string { - return fmt.Sprintf("[DELETE /unshare][%d] unshareNotFound", 404) + return fmt.Sprintf("[DELETE /unshare][%d] unshareNotFound ", 404) } func (o *UnshareNotFound) String() string { - return fmt.Sprintf("[DELETE /unshare][%d] unshareNotFound", 404) + return fmt.Sprintf("[DELETE /unshare][%d] unshareNotFound ", 404) } func (o *UnshareNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -268,13 +267,11 @@ func (o *UnshareInternalServerError) Code() int { } func (o *UnshareInternalServerError) Error() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[DELETE /unshare][%d] unshareInternalServerError %s", 500, payload) + return fmt.Sprintf("[DELETE /unshare][%d] unshareInternalServerError %+v", 500, o.Payload) } func (o *UnshareInternalServerError) String() string { - payload, _ := json.Marshal(o.Payload) - return fmt.Sprintf("[DELETE /unshare][%d] unshareInternalServerError %s", 500, payload) + return fmt.Sprintf("[DELETE /unshare][%d] unshareInternalServerError %+v", 500, o.Payload) } func (o *UnshareInternalServerError) GetPayload() rest_model_zrok.ErrorMessage { diff --git a/rest_client_zrok/share/update_access_responses.go b/rest_client_zrok/share/update_access_responses.go index 082a94d5..08ccbb97 100644 --- a/rest_client_zrok/share/update_access_responses.go +++ b/rest_client_zrok/share/update_access_responses.go @@ -95,11 +95,11 @@ func (o *UpdateAccessOK) Code() int { } func (o *UpdateAccessOK) Error() string { - return fmt.Sprintf("[PATCH /access][%d] updateAccessOK", 200) + return fmt.Sprintf("[PATCH /access][%d] updateAccessOK ", 200) } func (o *UpdateAccessOK) String() string { - return fmt.Sprintf("[PATCH /access][%d] updateAccessOK", 200) + return fmt.Sprintf("[PATCH /access][%d] updateAccessOK ", 200) } func (o *UpdateAccessOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -151,11 +151,11 @@ func (o *UpdateAccessUnauthorized) Code() int { } func (o *UpdateAccessUnauthorized) Error() string { - return fmt.Sprintf("[PATCH /access][%d] updateAccessUnauthorized", 401) + return fmt.Sprintf("[PATCH /access][%d] updateAccessUnauthorized ", 401) } func (o *UpdateAccessUnauthorized) String() string { - return fmt.Sprintf("[PATCH /access][%d] updateAccessUnauthorized", 401) + return fmt.Sprintf("[PATCH /access][%d] updateAccessUnauthorized ", 401) } func (o *UpdateAccessUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -207,11 +207,11 @@ func (o *UpdateAccessNotFound) Code() int { } func (o *UpdateAccessNotFound) Error() string { - return fmt.Sprintf("[PATCH /access][%d] updateAccessNotFound", 404) + return fmt.Sprintf("[PATCH /access][%d] updateAccessNotFound ", 404) } func (o *UpdateAccessNotFound) String() string { - return fmt.Sprintf("[PATCH /access][%d] updateAccessNotFound", 404) + return fmt.Sprintf("[PATCH /access][%d] updateAccessNotFound ", 404) } func (o *UpdateAccessNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -263,11 +263,11 @@ func (o *UpdateAccessInternalServerError) Code() int { } func (o *UpdateAccessInternalServerError) Error() string { - return fmt.Sprintf("[PATCH /access][%d] updateAccessInternalServerError", 500) + return fmt.Sprintf("[PATCH /access][%d] updateAccessInternalServerError ", 500) } func (o *UpdateAccessInternalServerError) String() string { - return fmt.Sprintf("[PATCH /access][%d] updateAccessInternalServerError", 500) + return fmt.Sprintf("[PATCH /access][%d] updateAccessInternalServerError ", 500) } func (o *UpdateAccessInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_client_zrok/share/update_share_responses.go b/rest_client_zrok/share/update_share_responses.go index 4654914c..0478efa8 100644 --- a/rest_client_zrok/share/update_share_responses.go +++ b/rest_client_zrok/share/update_share_responses.go @@ -101,11 +101,11 @@ func (o *UpdateShareOK) Code() int { } func (o *UpdateShareOK) Error() string { - return fmt.Sprintf("[PATCH /share][%d] updateShareOK", 200) + return fmt.Sprintf("[PATCH /share][%d] updateShareOK ", 200) } func (o *UpdateShareOK) String() string { - return fmt.Sprintf("[PATCH /share][%d] updateShareOK", 200) + return fmt.Sprintf("[PATCH /share][%d] updateShareOK ", 200) } func (o *UpdateShareOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -157,11 +157,11 @@ func (o *UpdateShareBadRequest) Code() int { } func (o *UpdateShareBadRequest) Error() string { - return fmt.Sprintf("[PATCH /share][%d] updateShareBadRequest", 400) + return fmt.Sprintf("[PATCH /share][%d] updateShareBadRequest ", 400) } func (o *UpdateShareBadRequest) String() string { - return fmt.Sprintf("[PATCH /share][%d] updateShareBadRequest", 400) + return fmt.Sprintf("[PATCH /share][%d] updateShareBadRequest ", 400) } func (o *UpdateShareBadRequest) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -213,11 +213,11 @@ func (o *UpdateShareUnauthorized) Code() int { } func (o *UpdateShareUnauthorized) Error() string { - return fmt.Sprintf("[PATCH /share][%d] updateShareUnauthorized", 401) + return fmt.Sprintf("[PATCH /share][%d] updateShareUnauthorized ", 401) } func (o *UpdateShareUnauthorized) String() string { - return fmt.Sprintf("[PATCH /share][%d] updateShareUnauthorized", 401) + return fmt.Sprintf("[PATCH /share][%d] updateShareUnauthorized ", 401) } func (o *UpdateShareUnauthorized) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -269,11 +269,11 @@ func (o *UpdateShareNotFound) Code() int { } func (o *UpdateShareNotFound) Error() string { - return fmt.Sprintf("[PATCH /share][%d] updateShareNotFound", 404) + return fmt.Sprintf("[PATCH /share][%d] updateShareNotFound ", 404) } func (o *UpdateShareNotFound) String() string { - return fmt.Sprintf("[PATCH /share][%d] updateShareNotFound", 404) + return fmt.Sprintf("[PATCH /share][%d] updateShareNotFound ", 404) } func (o *UpdateShareNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { @@ -325,11 +325,11 @@ func (o *UpdateShareInternalServerError) Code() int { } func (o *UpdateShareInternalServerError) Error() string { - return fmt.Sprintf("[PATCH /share][%d] updateShareInternalServerError", 500) + return fmt.Sprintf("[PATCH /share][%d] updateShareInternalServerError ", 500) } func (o *UpdateShareInternalServerError) String() string { - return fmt.Sprintf("[PATCH /share][%d] updateShareInternalServerError", 500) + return fmt.Sprintf("[PATCH /share][%d] updateShareInternalServerError ", 500) } func (o *UpdateShareInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { diff --git a/rest_model_zrok/environment.go b/rest_model_zrok/environment.go index 17376949..2d77152f 100644 --- a/rest_model_zrok/environment.go +++ b/rest_model_zrok/environment.go @@ -36,6 +36,9 @@ type Environment struct { // limited Limited bool `json:"limited,omitempty"` + // remote agent + RemoteAgent bool `json:"remoteAgent,omitempty"` + // updated at UpdatedAt int64 `json:"updatedAt,omitempty"` diff --git a/rest_model_zrok/share_request.go b/rest_model_zrok/share_request.go index b4e5c309..c440d6bc 100644 --- a/rest_model_zrok/share_request.go +++ b/rest_model_zrok/share_request.go @@ -31,7 +31,7 @@ type ShareRequest struct { AuthUsers []*AuthUser `json:"authUsers"` // backend mode - // Enum: ["proxy","web","tcpTunnel","udpTunnel","caddy","drive","socks","vpn"] + // Enum: [proxy web tcpTunnel udpTunnel caddy drive socks vpn] BackendMode string `json:"backendMode,omitempty"` // backend proxy endpoint @@ -50,18 +50,18 @@ type ShareRequest struct { OauthEmailDomains []string `json:"oauthEmailDomains"` // oauth provider - // Enum: ["github","google"] + // Enum: [github google] OauthProvider string `json:"oauthProvider,omitempty"` // permission mode - // Enum: ["open","closed"] + // Enum: [open closed] PermissionMode string `json:"permissionMode,omitempty"` // reserved Reserved bool `json:"reserved,omitempty"` // share mode - // Enum: ["public","private"] + // Enum: [public private] ShareMode string `json:"shareMode,omitempty"` // unique name diff --git a/rest_server_zrok/embedded_spec.go b/rest_server_zrok/embedded_spec.go index feab35be..07e0fd84 100644 --- a/rest_server_zrok/embedded_spec.go +++ b/rest_server_zrok/embedded_spec.go @@ -2533,6 +2533,9 @@ func init() { "limited": { "type": "boolean" }, + "remoteAgent": { + "type": "boolean" + }, "updatedAt": { "type": "integer" }, @@ -5368,6 +5371,9 @@ func init() { "limited": { "type": "boolean" }, + "remoteAgent": { + "type": "boolean" + }, "updatedAt": { "type": "integer" }, diff --git a/rest_server_zrok/operations/admin/create_frontend.go b/rest_server_zrok/operations/admin/create_frontend.go index 3c9ac02e..dd2a15aa 100644 --- a/rest_server_zrok/operations/admin/create_frontend.go +++ b/rest_server_zrok/operations/admin/create_frontend.go @@ -82,7 +82,7 @@ func (o *CreateFrontend) ServeHTTP(rw http.ResponseWriter, r *http.Request) { type CreateFrontendBody struct { // permission mode - // Enum: ["open","closed"] + // Enum: [open closed] PermissionMode string `json:"permissionMode,omitempty"` // public name diff --git a/rest_server_zrok/operations/agent/remote_share.go b/rest_server_zrok/operations/agent/remote_share.go index f0022de5..dd7b2292 100644 --- a/rest_server_zrok/operations/agent/remote_share.go +++ b/rest_server_zrok/operations/agent/remote_share.go @@ -85,7 +85,7 @@ type RemoteShareBody struct { AccessGrants []string `json:"accessGrants"` // backend mode - // Enum: ["proxy","web","tcpTunnel","udpTunnel","caddy","drive","socks","vpn"] + // Enum: [proxy web tcpTunnel udpTunnel caddy drive socks vpn] BackendMode string `json:"backendMode,omitempty"` // basic auth @@ -113,7 +113,7 @@ type RemoteShareBody struct { Open bool `json:"open,omitempty"` // share mode - // Enum: ["public","private","reserved"] + // Enum: [public private reserved] ShareMode string `json:"shareMode,omitempty"` // target diff --git a/rest_server_zrok/server.go b/rest_server_zrok/server.go index 56c64b79..d07438f0 100644 --- a/rest_server_zrok/server.go +++ b/rest_server_zrok/server.go @@ -80,7 +80,7 @@ type Server struct { ListenLimit int `long:"listen-limit" description:"limit the number of outstanding requests"` KeepAlive time.Duration `long:"keep-alive" description:"sets the TCP keep-alive timeouts on accepted connections. It prunes dead TCP connections ( e.g. closing laptop mid-download)" default:"3m"` ReadTimeout time.Duration `long:"read-timeout" description:"maximum duration before timing out read of the request" default:"30s"` - WriteTimeout time.Duration `long:"write-timeout" description:"maximum duration before timing out write of the response" default:"30s"` + WriteTimeout time.Duration `long:"write-timeout" description:"maximum duration before timing out write of the response" default:"60s"` httpServerL net.Listener TLSHost string `long:"tls-host" description:"the IP to listen on for tls, when not specified it's the same as --host" env:"TLS_HOST"` diff --git a/sdk/nodejs/sdk/src/api/models/Environment.ts b/sdk/nodejs/sdk/src/api/models/Environment.ts index dee66aac..7794c7a6 100644 --- a/sdk/nodejs/sdk/src/api/models/Environment.ts +++ b/sdk/nodejs/sdk/src/api/models/Environment.ts @@ -51,6 +51,12 @@ export interface Environment { * @memberof Environment */ zId?: string; + /** + * + * @type {boolean} + * @memberof Environment + */ + remoteAgent?: boolean; /** * * @type {Array} @@ -98,6 +104,7 @@ export function EnvironmentFromJSONTyped(json: any, ignoreDiscriminator: boolean 'host': json['host'] == null ? undefined : json['host'], 'address': json['address'] == null ? undefined : json['address'], 'zId': json['zId'] == null ? undefined : json['zId'], + 'remoteAgent': json['remoteAgent'] == null ? undefined : json['remoteAgent'], 'activity': json['activity'] == null ? undefined : ((json['activity'] as Array).map(SparkDataSampleFromJSON)), 'limited': json['limited'] == null ? undefined : json['limited'], 'createdAt': json['createdAt'] == null ? undefined : json['createdAt'], @@ -120,6 +127,7 @@ export function EnvironmentToJSONTyped(value?: Environment | null, ignoreDiscrim 'host': value['host'], 'address': value['address'], 'zId': value['zId'], + 'remoteAgent': value['remoteAgent'], 'activity': value['activity'] == null ? undefined : ((value['activity'] as Array).map(SparkDataSampleToJSON)), 'limited': value['limited'], 'createdAt': value['createdAt'], diff --git a/sdk/python/src/docs/Environment.md b/sdk/python/src/docs/Environment.md index 44a9356b..7614c379 100644 --- a/sdk/python/src/docs/Environment.md +++ b/sdk/python/src/docs/Environment.md @@ -9,6 +9,7 @@ Name | Type | Description | Notes **host** | **str** | | [optional] **address** | **str** | | [optional] **z_id** | **str** | | [optional] +**remote_agent** | **bool** | | [optional] **activity** | [**List[SparkDataSample]**](SparkDataSample.md) | | [optional] **limited** | **bool** | | [optional] **created_at** | **int** | | [optional] diff --git a/sdk/python/src/test/test_environment.py b/sdk/python/src/test/test_environment.py index d2e28280..ae1e6d41 100644 --- a/sdk/python/src/test/test_environment.py +++ b/sdk/python/src/test/test_environment.py @@ -39,6 +39,7 @@ class TestEnvironment(unittest.TestCase): host = '', address = '', z_id = '', + remote_agent = True, activity = [ zrok_api.models.spark_data_sample.sparkDataSample( rx = 1.337, diff --git a/sdk/python/src/test/test_environment_and_resources.py b/sdk/python/src/test/test_environment_and_resources.py index 56cafdac..36e6cc56 100644 --- a/sdk/python/src/test/test_environment_and_resources.py +++ b/sdk/python/src/test/test_environment_and_resources.py @@ -40,6 +40,7 @@ class TestEnvironmentAndResources(unittest.TestCase): host = '', address = '', z_id = '', + remote_agent = True, activity = [ zrok_api.models.spark_data_sample.sparkDataSample( rx = 1.337, diff --git a/sdk/python/src/test/test_overview.py b/sdk/python/src/test/test_overview.py index 804007cd..ffb64a15 100644 --- a/sdk/python/src/test/test_overview.py +++ b/sdk/python/src/test/test_overview.py @@ -43,6 +43,7 @@ class TestOverview(unittest.TestCase): host = '', address = '', z_id = '', + remote_agent = True, activity = [ zrok_api.models.spark_data_sample.sparkDataSample( rx = 1.337, diff --git a/sdk/python/src/zrok_api/models/environment.py b/sdk/python/src/zrok_api/models/environment.py index 063ff59e..0e08ad39 100644 --- a/sdk/python/src/zrok_api/models/environment.py +++ b/sdk/python/src/zrok_api/models/environment.py @@ -31,11 +31,12 @@ class Environment(BaseModel): host: Optional[StrictStr] = None address: Optional[StrictStr] = None z_id: Optional[StrictStr] = Field(default=None, alias="zId") + remote_agent: Optional[StrictBool] = Field(default=None, alias="remoteAgent") activity: Optional[List[SparkDataSample]] = None limited: Optional[StrictBool] = None created_at: Optional[StrictInt] = Field(default=None, alias="createdAt") updated_at: Optional[StrictInt] = Field(default=None, alias="updatedAt") - __properties: ClassVar[List[str]] = ["description", "host", "address", "zId", "activity", "limited", "createdAt", "updatedAt"] + __properties: ClassVar[List[str]] = ["description", "host", "address", "zId", "remoteAgent", "activity", "limited", "createdAt", "updatedAt"] model_config = ConfigDict( populate_by_name=True, @@ -99,6 +100,7 @@ class Environment(BaseModel): "host": obj.get("host"), "address": obj.get("address"), "zId": obj.get("zId"), + "remoteAgent": obj.get("remoteAgent"), "activity": [SparkDataSample.from_dict(_item) for _item in obj["activity"]] if obj.get("activity") is not None else None, "limited": obj.get("limited"), "createdAt": obj.get("createdAt"), diff --git a/specs/zrok.yml b/specs/zrok.yml index 6a552985..009cad59 100644 --- a/specs/zrok.yml +++ b/specs/zrok.yml @@ -1562,6 +1562,8 @@ definitions: type: string zId: type: string + remoteAgent: + type: boolean activity: $ref: "#/definitions/sparkData" limited: diff --git a/ui/src/api/models/Environment.ts b/ui/src/api/models/Environment.ts index dee66aac..7794c7a6 100644 --- a/ui/src/api/models/Environment.ts +++ b/ui/src/api/models/Environment.ts @@ -51,6 +51,12 @@ export interface Environment { * @memberof Environment */ zId?: string; + /** + * + * @type {boolean} + * @memberof Environment + */ + remoteAgent?: boolean; /** * * @type {Array} @@ -98,6 +104,7 @@ export function EnvironmentFromJSONTyped(json: any, ignoreDiscriminator: boolean 'host': json['host'] == null ? undefined : json['host'], 'address': json['address'] == null ? undefined : json['address'], 'zId': json['zId'] == null ? undefined : json['zId'], + 'remoteAgent': json['remoteAgent'] == null ? undefined : json['remoteAgent'], 'activity': json['activity'] == null ? undefined : ((json['activity'] as Array).map(SparkDataSampleFromJSON)), 'limited': json['limited'] == null ? undefined : json['limited'], 'createdAt': json['createdAt'] == null ? undefined : json['createdAt'], @@ -120,6 +127,7 @@ export function EnvironmentToJSONTyped(value?: Environment | null, ignoreDiscrim 'host': value['host'], 'address': value['address'], 'zId': value['zId'], + 'remoteAgent': value['remoteAgent'], 'activity': value['activity'] == null ? undefined : ((value['activity'] as Array).map(SparkDataSampleToJSON)), 'limited': value['limited'], 'createdAt': value['createdAt'],