diff --git a/harness/nextgen/api_environments.go b/harness/nextgen/api_environments.go index c5e9ee0d..c3bf321e 100644 --- a/harness/nextgen/api_environments.go +++ b/harness/nextgen/api_environments.go @@ -1,7 +1,7 @@ /* * Harness NextGen Software Delivery Platform API Reference * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub # Authentication + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub * * API version: 3.0 * Contact: contact@harness.io @@ -298,6 +298,143 @@ func (a *EnvironmentsApiService) DeleteEnvironmentV2(ctx context.Context, enviro return localVarReturnValue, localVarHttpResponse, nil } +/* +EnvironmentsApiService Delete a ServiceOverride entity + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param accountIdentifier Account Identifier for the Entity. + * @param orgIdentifier Organization Identifier for the Entity. + * @param projectIdentifier Project Identifier for the Entity. + * @param optional nil or *EnvironmentsApiDeleteServiceOverrideOpts - Optional Parameters: + * @param "EnvironmentIdentifier" (optional.String) - Environment Identifier for the Entity. + * @param "ServiceIdentifier" (optional.String) - Service Identifier for the Entity. +@return ResponseDtoBoolean +*/ + +type EnvironmentsApiDeleteServiceOverrideOpts struct { + EnvironmentIdentifier optional.String + ServiceIdentifier optional.String +} + +func (a *EnvironmentsApiService) DeleteServiceOverride(ctx context.Context, accountIdentifier string, orgIdentifier string, projectIdentifier string, localVarOptionals *EnvironmentsApiDeleteServiceOverrideOpts) (ResponseDtoBoolean, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Delete") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoBoolean + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/ng/api/environmentsV2/serviceOverrides" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) + localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) + if localVarOptionals != nil && localVarOptionals.EnvironmentIdentifier.IsSet() { + localVarQueryParams.Add("environmentIdentifier", parameterToString(localVarOptionals.EnvironmentIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ServiceIdentifier.IsSet() { + localVarQueryParams.Add("serviceIdentifier", parameterToString(localVarOptionals.ServiceIdentifier.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + if ctx != nil { + // API Key Authentication + if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok { + var key string + if auth.Prefix != "" { + key = auth.Prefix + " " + auth.Key + } else { + key = auth.Key + } + localVarHeaderParams["x-api-key"] = key + + } + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v Failure + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoBoolean + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + /* EnvironmentsApiService Gets Environment Access list * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @@ -461,8 +598,8 @@ EnvironmentsApiService Gets Environment list for a project * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). * @param accountIdentifier Account Identifier for the Entity. * @param optional nil or *EnvironmentsApiGetEnvironmentListOpts - Optional Parameters: - * @param "Page" (optional.Int32) - Number of pages. - * @param "Size" (optional.Int32) - Number of Elements to fetch. + * @param "Page" (optional.Int32) - Page Index of the results to fetch.Default Value: 0 + * @param "Size" (optional.Int32) - Results per page * @param "OrgIdentifier" (optional.String) - Organization Identifier for the Entity. * @param "ProjectIdentifier" (optional.String) - Project Identifier for the Entity. * @param "SearchTerm" (optional.String) - The word to be searched and included in the list response @@ -754,6 +891,155 @@ func (a *EnvironmentsApiService) GetEnvironmentV2(ctx context.Context, environme return localVarReturnValue, localVarHttpResponse, nil } +/* +EnvironmentsApiService Gets Service Overrides list + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param accountIdentifier Account Identifier for the Entity. + * @param orgIdentifier Organization Identifier for the Entity. + * @param projectIdentifier Project Identifier for the Entity. + * @param environmentIdentifier Environment Identifier for the Entity. + * @param optional nil or *EnvironmentsApiGetServiceOverridesListOpts - Optional Parameters: + * @param "Page" (optional.Int32) - Page Index of the results to fetch.Default Value: 0 + * @param "Size" (optional.Int32) - Results per page + * @param "ServiceIdentifier" (optional.String) - Service Identifier for the Entity. + * @param "Sort" (optional.Interface of []string) - Specifies the sorting criteria of the list. Like sorting based on the last updated entity, alphabetical sorting in an ascending or descending order +@return ResponseDtoPageResponseServiceOverrideResponse +*/ + +type EnvironmentsApiGetServiceOverridesListOpts struct { + Page optional.Int32 + Size optional.Int32 + ServiceIdentifier optional.String + Sort optional.Interface +} + +func (a *EnvironmentsApiService) GetServiceOverridesList(ctx context.Context, accountIdentifier string, orgIdentifier string, projectIdentifier string, environmentIdentifier string, localVarOptionals *EnvironmentsApiGetServiceOverridesListOpts) (ResponseDtoPageResponseServiceOverrideResponse, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoPageResponseServiceOverrideResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/ng/api/environmentsV2/serviceOverrides" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.Page.IsSet() { + localVarQueryParams.Add("page", parameterToString(localVarOptionals.Page.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.Size.IsSet() { + localVarQueryParams.Add("size", parameterToString(localVarOptionals.Size.Value(), "")) + } + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) + localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) + localVarQueryParams.Add("environmentIdentifier", parameterToString(environmentIdentifier, "")) + if localVarOptionals != nil && localVarOptionals.ServiceIdentifier.IsSet() { + localVarQueryParams.Add("serviceIdentifier", parameterToString(localVarOptionals.ServiceIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.Sort.IsSet() { + localVarQueryParams.Add("sort", parameterToString(localVarOptionals.Sort.Value(), "multi")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + if ctx != nil { + // API Key Authentication + if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok { + var key string + if auth.Prefix != "" { + key = auth.Prefix + " " + auth.Key + } else { + key = auth.Key + } + localVarHeaderParams["x-api-key"] = key + + } + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v Failure + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoPageResponseServiceOverrideResponse + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + /* EnvironmentsApiService Update an Environment by identifier * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @@ -1025,3 +1311,134 @@ func (a *EnvironmentsApiService) UpsertEnvironmentV2(ctx context.Context, accoun return localVarReturnValue, localVarHttpResponse, nil } + +/* +EnvironmentsApiService Upsert + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param accountIdentifier Account Identifier for the Entity. + * @param optional nil or *EnvironmentsApiUpsertServiceOverrideOpts - Optional Parameters: + * @param "Body" (optional.Interface of ServiceOverrideRequest) - Details of the Service Override to be upserted +@return ResponseDtoServiceOverrideResponse +*/ + +type EnvironmentsApiUpsertServiceOverrideOpts struct { + Body optional.Interface +} + +func (a *EnvironmentsApiService) UpsertServiceOverride(ctx context.Context, accountIdentifier string, localVarOptionals *EnvironmentsApiUpsertServiceOverrideOpts) (ResponseDtoServiceOverrideResponse, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Post") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoServiceOverrideResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/ng/api/environmentsV2/serviceOverrides" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + // to determine the Content-Type header + localVarHttpContentTypes := []string{"application/json", "application/yaml"} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + // body params + if localVarOptionals != nil && localVarOptionals.Body.IsSet() { + + localVarOptionalBody := localVarOptionals.Body.Value() + localVarPostBody = &localVarOptionalBody + } + if ctx != nil { + // API Key Authentication + if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok { + var key string + if auth.Prefix != "" { + key = auth.Prefix + " " + auth.Key + } else { + key = auth.Key + } + localVarHeaderParams["x-api-key"] = key + + } + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v Failure + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoServiceOverrideResponse + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} diff --git a/harness/nextgen/docs/EnvironmentsApi.md b/harness/nextgen/docs/EnvironmentsApi.md index 4a0e3bcf..86428dc8 100644 --- a/harness/nextgen/docs/EnvironmentsApi.md +++ b/harness/nextgen/docs/EnvironmentsApi.md @@ -1,4 +1,4 @@ -# {{classname}} +# nextgen{{classname}} All URIs are relative to *https://app.harness.io/gateway* @@ -6,11 +6,14 @@ Method | HTTP request | Description ------------- | ------------- | ------------- [**CreateEnvironmentV2**](EnvironmentsApi.md#CreateEnvironmentV2) | **Post** /ng/api/environmentsV2 | Create an Environment [**DeleteEnvironmentV2**](EnvironmentsApi.md#DeleteEnvironmentV2) | **Delete** /ng/api/environmentsV2/{environmentIdentifier} | Delete an Environment by identifier +[**DeleteServiceOverride**](EnvironmentsApi.md#DeleteServiceOverride) | **Delete** /ng/api/environmentsV2/serviceOverrides | Delete a ServiceOverride entity [**GetEnvironmentAccessList**](EnvironmentsApi.md#GetEnvironmentAccessList) | **Get** /ng/api/environmentsV2/list/access | Gets Environment Access list [**GetEnvironmentList**](EnvironmentsApi.md#GetEnvironmentList) | **Get** /ng/api/environmentsV2 | Gets Environment list for a project [**GetEnvironmentV2**](EnvironmentsApi.md#GetEnvironmentV2) | **Get** /ng/api/environmentsV2/{environmentIdentifier} | Gets an Environment by identifier +[**GetServiceOverridesList**](EnvironmentsApi.md#GetServiceOverridesList) | **Get** /ng/api/environmentsV2/serviceOverrides | Gets Service Overrides list [**UpdateEnvironmentV2**](EnvironmentsApi.md#UpdateEnvironmentV2) | **Put** /ng/api/environmentsV2 | Update an Environment by identifier [**UpsertEnvironmentV2**](EnvironmentsApi.md#UpsertEnvironmentV2) | **Put** /ng/api/environmentsV2/upsert | Upsert an Environment by identifier +[**UpsertServiceOverride**](EnvironmentsApi.md#UpsertServiceOverride) | **Post** /ng/api/environmentsV2/serviceOverrides | Upsert # **CreateEnvironmentV2** > ResponseDtoEnvironmentResponse CreateEnvironmentV2(ctx, accountIdentifier, optional) @@ -21,7 +24,7 @@ Create an Environment Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc. - **accountIdentifier** | **string**| Account Identifier for the Entity | + **accountIdentifier** | **string**| Account Identifier for the Entity. | **optional** | ***EnvironmentsApiCreateEnvironmentV2Opts** | optional parameters | nil if no parameters ### Optional Parameters @@ -56,7 +59,7 @@ Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc. **environmentIdentifier** | **string**| Environment Identifier for the entity | - **accountIdentifier** | **string**| Account Identifier for the Entity | + **accountIdentifier** | **string**| Account Identifier for the Entity. | **optional** | ***EnvironmentsApiDeleteEnvironmentV2Opts** | optional parameters | nil if no parameters ### Optional Parameters @@ -66,8 +69,47 @@ Name | Type | Description | Notes **ifMatch** | **optional.String**| | - **orgIdentifier** | **optional.String**| Organization Identifier for the Entity | - **projectIdentifier** | **optional.String**| Project Identifier for the Entity | + **orgIdentifier** | **optional.String**| Organization Identifier for the Entity. | + **projectIdentifier** | **optional.String**| Project Identifier for the Entity. | + +### Return type + +[**ResponseDtoBoolean**](ResponseDTOBoolean.md) + +### Authorization + +[ApiKey](../README.md#ApiKey) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json, application/yaml + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **DeleteServiceOverride** +> ResponseDtoBoolean DeleteServiceOverride(ctx, accountIdentifier, orgIdentifier, projectIdentifier, optional) +Delete a ServiceOverride entity + +### Required Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc. + **accountIdentifier** | **string**| Account Identifier for the Entity. | + **orgIdentifier** | **string**| Organization Identifier for the Entity. | + **projectIdentifier** | **string**| Project Identifier for the Entity. | + **optional** | ***EnvironmentsApiDeleteServiceOverrideOpts** | optional parameters | nil if no parameters + +### Optional Parameters +Optional parameters are passed through a pointer to a EnvironmentsApiDeleteServiceOverrideOpts struct +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + + + + **environmentIdentifier** | **optional.String**| Environment Identifier for the Entity. | + **serviceIdentifier** | **optional.String**| Service Identifier for the Entity. | ### Return type @@ -93,7 +135,7 @@ Gets Environment Access list Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc. - **accountIdentifier** | **string**| Account Identifier for the Entity | + **accountIdentifier** | **string**| Account Identifier for the Entity. | **optional** | ***EnvironmentsApiGetEnvironmentAccessListOpts** | optional parameters | nil if no parameters ### Optional Parameters @@ -103,8 +145,8 @@ Name | Type | Description | Notes **page** | **optional.Int32**| page | [default to 0] **size** | **optional.Int32**| size | [default to 100] - **orgIdentifier** | **optional.String**| Organization Identifier for the Entity | - **projectIdentifier** | **optional.String**| Project Identifier for the Entity | + **orgIdentifier** | **optional.String**| Organization Identifier for the Entity. | + **projectIdentifier** | **optional.String**| Project Identifier for the Entity. | **searchTerm** | **optional.String**| The word to be searched and included in the list response | **envIdentifiers** | [**optional.Interface of []string**](string.md)| List of EnvironmentIds | **sort** | [**optional.Interface of []string**](string.md)| Specifies sorting criteria of the list. Like sorting based on the last updated entity, alphabetical sorting in an ascending or descending order | @@ -133,7 +175,7 @@ Gets Environment list for a project Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc. - **accountIdentifier** | **string**| Account Identifier for the Entity | + **accountIdentifier** | **string**| Account Identifier for the Entity. | **optional** | ***EnvironmentsApiGetEnvironmentListOpts** | optional parameters | nil if no parameters ### Optional Parameters @@ -141,10 +183,10 @@ Optional parameters are passed through a pointer to a EnvironmentsApiGetEnvironm Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **page** | **optional.Int32**| Indicates the number of pages. Results for these pages will be retrieved. | [default to 0] - **size** | **optional.Int32**| The number of the elements to fetch | [default to 100] - **orgIdentifier** | **optional.String**| Organization Identifier for the Entity | - **projectIdentifier** | **optional.String**| Project Identifier for the Entity | + **page** | **optional.Int32**| Page Index of the results to fetch.Default Value: 0 | [default to 0] + **size** | **optional.Int32**| Results per page | [default to 100] + **orgIdentifier** | **optional.String**| Organization Identifier for the Entity. | + **projectIdentifier** | **optional.String**| Project Identifier for the Entity. | **searchTerm** | **optional.String**| The word to be searched and included in the list response | **envIdentifiers** | [**optional.Interface of []string**](string.md)| List of EnvironmentIds | **sort** | [**optional.Interface of []string**](string.md)| Specifies sorting criteria of the list. Like sorting based on the last updated entity, alphabetical sorting in an ascending or descending order | @@ -174,7 +216,7 @@ Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc. **environmentIdentifier** | **string**| Environment Identifier for the entity | - **accountIdentifier** | **string**| Account Identifier for the Entity | + **accountIdentifier** | **string**| Account Identifier for the Entity. | **optional** | ***EnvironmentsApiGetEnvironmentV2Opts** | optional parameters | nil if no parameters ### Optional Parameters @@ -183,8 +225,8 @@ Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **orgIdentifier** | **optional.String**| Organization Identifier for the Entity | - **projectIdentifier** | **optional.String**| Project Identifier for the Entity | + **orgIdentifier** | **optional.String**| Organization Identifier for the Entity. | + **projectIdentifier** | **optional.String**| Project Identifier for the Entity. | **deleted** | **optional.Bool**| Specify whether Environment is deleted or not | [default to false] ### Return type @@ -202,6 +244,49 @@ Name | Type | Description | Notes [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +# **GetServiceOverridesList** +> ResponseDtoPageResponseServiceOverrideResponse GetServiceOverridesList(ctx, accountIdentifier, orgIdentifier, projectIdentifier, environmentIdentifier, optional) +Gets Service Overrides list + +### Required Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc. + **accountIdentifier** | **string**| Account Identifier for the Entity. | + **orgIdentifier** | **string**| Organization Identifier for the Entity. | + **projectIdentifier** | **string**| Project Identifier for the Entity. | + **environmentIdentifier** | **string**| Environment Identifier for the Entity. | + **optional** | ***EnvironmentsApiGetServiceOverridesListOpts** | optional parameters | nil if no parameters + +### Optional Parameters +Optional parameters are passed through a pointer to a EnvironmentsApiGetServiceOverridesListOpts struct +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + + + + + **page** | **optional.Int32**| Page Index of the results to fetch.Default Value: 0 | [default to 0] + **size** | **optional.Int32**| Results per page | [default to 100] + **serviceIdentifier** | **optional.String**| Service Identifier for the Entity. | + **sort** | [**optional.Interface of []string**](string.md)| Specifies the sorting criteria of the list. Like sorting based on the last updated entity, alphabetical sorting in an ascending or descending order | + +### Return type + +[**ResponseDtoPageResponseServiceOverrideResponse**](ResponseDTOPageResponseServiceOverrideResponse.md) + +### Authorization + +[ApiKey](../README.md#ApiKey) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json, application/yaml + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + # **UpdateEnvironmentV2** > ResponseDtoEnvironmentResponse UpdateEnvironmentV2(ctx, accountIdentifier, optional) Update an Environment by identifier @@ -211,7 +296,7 @@ Update an Environment by identifier Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc. - **accountIdentifier** | **string**| Account Identifier for the Entity | + **accountIdentifier** | **string**| Account Identifier for the Entity. | **optional** | ***EnvironmentsApiUpdateEnvironmentV2Opts** | optional parameters | nil if no parameters ### Optional Parameters @@ -246,7 +331,7 @@ Upsert an Environment by identifier Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc. - **accountIdentifier** | **string**| Account Identifier for the Entity | + **accountIdentifier** | **string**| Account Identifier for the Entity. | **optional** | ***EnvironmentsApiUpsertEnvironmentV2Opts** | optional parameters | nil if no parameters ### Optional Parameters @@ -272,3 +357,37 @@ Name | Type | Description | Notes [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +# **UpsertServiceOverride** +> ResponseDtoServiceOverrideResponse UpsertServiceOverride(ctx, accountIdentifier, optional) +Upsert + +### Required Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc. + **accountIdentifier** | **string**| Account Identifier for the Entity. | + **optional** | ***EnvironmentsApiUpsertServiceOverrideOpts** | optional parameters | nil if no parameters + +### Optional Parameters +Optional parameters are passed through a pointer to a EnvironmentsApiUpsertServiceOverrideOpts struct +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + + **body** | [**optional.Interface of ServiceOverrideRequest**](ServiceOverrideRequest.md)| Details of the Service Override to be upserted | + +### Return type + +[**ResponseDtoServiceOverrideResponse**](ResponseDTOServiceOverrideResponse.md) + +### Authorization + +[ApiKey](../README.md#ApiKey) + +### HTTP request headers + + - **Content-Type**: application/json, application/yaml + - **Accept**: application/json, application/yaml + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/harness/nextgen/docs/PageResponseServiceOverrideResponse.md b/harness/nextgen/docs/PageResponseServiceOverrideResponse.md new file mode 100644 index 00000000..231d2cc1 --- /dev/null +++ b/harness/nextgen/docs/PageResponseServiceOverrideResponse.md @@ -0,0 +1,15 @@ +# PageResponseServiceOverrideResponse + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**TotalPages** | **int64** | | [optional] [default to null] +**TotalItems** | **int64** | | [optional] [default to null] +**PageItemCount** | **int64** | | [optional] [default to null] +**PageSize** | **int64** | | [optional] [default to null] +**Content** | [**[]ServiceOverrideResponse**](ServiceOverrideResponse.md) | | [optional] [default to null] +**PageIndex** | **int64** | | [optional] [default to null] +**Empty** | **bool** | | [optional] [default to null] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/harness/nextgen/docs/ResponseDtoPageResponseServiceOverrideResponse.md b/harness/nextgen/docs/ResponseDtoPageResponseServiceOverrideResponse.md new file mode 100644 index 00000000..bdcac6bc --- /dev/null +++ b/harness/nextgen/docs/ResponseDtoPageResponseServiceOverrideResponse.md @@ -0,0 +1,12 @@ +# ResponseDtoPageResponseServiceOverrideResponse + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Status** | **string** | | [optional] [default to null] +**Data** | [***PageResponseServiceOverrideResponse**](PageResponseServiceOverrideResponse.md) | | [optional] [default to null] +**MetaData** | [***interface{}**](interface{}.md) | | [optional] [default to null] +**CorrelationId** | **string** | | [optional] [default to null] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/harness/nextgen/docs/ResponseDtoServiceOverrideResponse.md b/harness/nextgen/docs/ResponseDtoServiceOverrideResponse.md new file mode 100644 index 00000000..2da7e857 --- /dev/null +++ b/harness/nextgen/docs/ResponseDtoServiceOverrideResponse.md @@ -0,0 +1,12 @@ +# ResponseDtoServiceOverrideResponse + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Status** | **string** | | [optional] [default to null] +**Data** | [***ServiceOverrideResponse**](ServiceOverrideResponse.md) | | [optional] [default to null] +**MetaData** | [***interface{}**](interface{}.md) | | [optional] [default to null] +**CorrelationId** | **string** | | [optional] [default to null] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/harness/nextgen/docs/ServiceOverrideRequest.md b/harness/nextgen/docs/ServiceOverrideRequest.md new file mode 100644 index 00000000..2c021105 --- /dev/null +++ b/harness/nextgen/docs/ServiceOverrideRequest.md @@ -0,0 +1,13 @@ +# ServiceOverrideRequest + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**OrgIdentifier** | **string** | Organization Identifier for the Entity. | [optional] [default to null] +**ProjectIdentifier** | **string** | Project Identifier for the Entity. | [optional] [default to null] +**EnvironmentIdentifier** | **string** | Environment Identifier for the Entity. | [optional] [default to null] +**ServiceIdentifier** | **string** | Service Identifier for the Entity. | [optional] [default to null] +**Yaml** | **string** | Yaml for the Service Override entity | [optional] [default to null] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/harness/nextgen/docs/ServiceOverrideResponse.md b/harness/nextgen/docs/ServiceOverrideResponse.md new file mode 100644 index 00000000..e0169ce2 --- /dev/null +++ b/harness/nextgen/docs/ServiceOverrideResponse.md @@ -0,0 +1,14 @@ +# ServiceOverrideResponse + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**AccountId** | **string** | | [optional] [default to null] +**OrgIdentifier** | **string** | | [optional] [default to null] +**ProjectIdentifier** | **string** | | [optional] [default to null] +**EnvironmentRef** | **string** | | [optional] [default to null] +**ServiceRef** | **string** | | [optional] [default to null] +**Yaml** | **string** | | [optional] [default to null] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/harness/nextgen/model_page_response_service_override_response.go b/harness/nextgen/model_page_response_service_override_response.go new file mode 100644 index 00000000..365d6edf --- /dev/null +++ b/harness/nextgen/model_page_response_service_override_response.go @@ -0,0 +1,20 @@ +/* + * Harness NextGen Software Delivery Platform API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +type PageResponseServiceOverrideResponse struct { + TotalPages int64 `json:"totalPages,omitempty"` + TotalItems int64 `json:"totalItems,omitempty"` + PageItemCount int64 `json:"pageItemCount,omitempty"` + PageSize int64 `json:"pageSize,omitempty"` + Content []ServiceOverrideResponse `json:"content,omitempty"` + PageIndex int64 `json:"pageIndex,omitempty"` + Empty bool `json:"empty,omitempty"` +} diff --git a/harness/nextgen/model_response_dto_page_response_service_override_response.go b/harness/nextgen/model_response_dto_page_response_service_override_response.go new file mode 100644 index 00000000..5a9133a9 --- /dev/null +++ b/harness/nextgen/model_response_dto_page_response_service_override_response.go @@ -0,0 +1,17 @@ +/* + * Harness NextGen Software Delivery Platform API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +type ResponseDtoPageResponseServiceOverrideResponse struct { + Status string `json:"status,omitempty"` + Data *PageResponseServiceOverrideResponse `json:"data,omitempty"` + MetaData *interface{} `json:"metaData,omitempty"` + CorrelationId string `json:"correlationId,omitempty"` +} diff --git a/harness/nextgen/model_response_dto_service_override_response.go b/harness/nextgen/model_response_dto_service_override_response.go new file mode 100644 index 00000000..737d79c6 --- /dev/null +++ b/harness/nextgen/model_response_dto_service_override_response.go @@ -0,0 +1,17 @@ +/* + * Harness NextGen Software Delivery Platform API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +type ResponseDtoServiceOverrideResponse struct { + Status string `json:"status,omitempty"` + Data *ServiceOverrideResponse `json:"data,omitempty"` + MetaData *interface{} `json:"metaData,omitempty"` + CorrelationId string `json:"correlationId,omitempty"` +} diff --git a/harness/nextgen/model_service_override_request.go b/harness/nextgen/model_service_override_request.go new file mode 100644 index 00000000..66813a7d --- /dev/null +++ b/harness/nextgen/model_service_override_request.go @@ -0,0 +1,24 @@ +/* + * Harness NextGen Software Delivery Platform API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This is the Service Override Request entity defined in Harness +type ServiceOverrideRequest struct { + // Organization Identifier for the Entity. + OrgIdentifier string `json:"orgIdentifier,omitempty"` + // Project Identifier for the Entity. + ProjectIdentifier string `json:"projectIdentifier,omitempty"` + // Environment Identifier for the Entity. + EnvironmentIdentifier string `json:"environmentIdentifier,omitempty"` + // Service Identifier for the Entity. + ServiceIdentifier string `json:"serviceIdentifier,omitempty"` + // Yaml for the Service Override entity + Yaml string `json:"yaml,omitempty"` +} diff --git a/harness/nextgen/model_service_override_response.go b/harness/nextgen/model_service_override_response.go new file mode 100644 index 00000000..d0256946 --- /dev/null +++ b/harness/nextgen/model_service_override_response.go @@ -0,0 +1,20 @@ +/* + * Harness NextGen Software Delivery Platform API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This is the Service Override Response entity defined in Harness +type ServiceOverrideResponse struct { + AccountId string `json:"accountId,omitempty"` + OrgIdentifier string `json:"orgIdentifier,omitempty"` + ProjectIdentifier string `json:"projectIdentifier,omitempty"` + EnvironmentRef string `json:"environmentRef,omitempty"` + ServiceRef string `json:"serviceRef,omitempty"` + Yaml string `json:"yaml,omitempty"` +}