diff --git a/harness/nextgen/api_agents.go b/harness/nextgen/api_agents.go index 3b692581..4ad24040 100644 --- a/harness/nextgen/api_agents.go +++ b/harness/nextgen/api_agents.go @@ -12,11 +12,12 @@ package nextgen import ( "context" "fmt" - "github.com/antihax/optional" "io/ioutil" "net/http" "net/url" "strings" + + "github.com/antihax/optional" ) // Linger please @@ -341,6 +342,7 @@ Get agents. * @param "PageSize" (optional.Int32) - * @param "PageIndex" (optional.Int32) - * @param "Scope" (optional.String) - + * @param "WithCredentials" (optional.Bool) - Applicable when trying to retrieve an agent. Set to true to include the credentials for the agent in the response. (Private key may not be included in response if agent is already connected to harness). NOTE: Setting this to true requires the user to have edit permissions on Agent. @return V1Agent */ @@ -354,6 +356,7 @@ type AgentsApiAgentServiceForServerGetOpts struct { PageSize optional.Int32 PageIndex optional.Int32 Scope optional.String + WithCredentials optional.Bool } func (a *AgentsApiService) AgentServiceForServerGet(ctx context.Context, identifier string, accountIdentifier string, localVarOptionals *AgentsApiAgentServiceForServerGetOpts) (V1Agent, *http.Response, error) { @@ -402,6 +405,9 @@ func (a *AgentsApiService) AgentServiceForServerGet(ctx context.Context, identif if localVarOptionals != nil && localVarOptionals.Scope.IsSet() { localVarQueryParams.Add("scope", parameterToString(localVarOptionals.Scope.Value(), "")) } + if localVarOptionals != nil && localVarOptionals.WithCredentials.IsSet() { + localVarQueryParams.Add("withCredentials", parameterToString(localVarOptionals.WithCredentials.Value(), "")) + } // to determine the Content-Type header localVarHttpContentTypes := []string{} diff --git a/harness/nextgen/docs/AgentsApi.md b/harness/nextgen/docs/AgentsApi.md index e540bdff..9b098978 100644 --- a/harness/nextgen/docs/AgentsApi.md +++ b/harness/nextgen/docs/AgentsApi.md @@ -116,6 +116,7 @@ Name | Type | Description | Notes **pageSize** | **optional.Int32**| | **pageIndex** | **optional.Int32**| | **scope** | **optional.String**| | [default to AGENT_SCOPE_UNSET] + **withCredentials** | **optional.Bool**| Applicable when trying to retrieve an agent. Set to true to include the credentials for the agent in the response. (Private key may not be included in response if agent is already connected to harness). NOTE: Setting this to true requires the user to have edit permissions on Agent. | ### Return type