From 3d9ca0b1c4546473dde7d53815411a3416f4c5df Mon Sep 17 00:00:00 2001 From: SDK Generator Bot Date: Wed, 11 Mar 2026 16:13:12 +0000 Subject: [PATCH 1/2] Generate vpn --- services/vpn/oas_commit | 2 +- services/vpn/v1alpha1api/api_default.go | 467 +++++++++--------- services/vpn/v1alpha1api/api_default_mock.go | 148 +++--- services/vpn/v1alpha1api/client.go | 2 +- services/vpn/v1alpha1api/configuration.go | 2 +- services/vpn/v1alpha1api/model_api_error.go | 38 +- .../vpn/v1alpha1api/model_api_error_detail.go | 2 +- .../v1alpha1api/model_api_error_response.go | 2 +- .../v1alpha1api/model_bgp_gateway_config.go | 6 +- services/vpn/v1alpha1api/model_bgp_status.go | 2 +- .../vpn/v1alpha1api/model_bgp_status_peers.go | 57 ++- .../v1alpha1api/model_bgp_status_routes.go | 25 +- .../v1alpha1api/model_bgp_tunnel_config.go | 4 +- .../vpn/v1alpha1api/model_connection_list.go | 14 +- ...ection.go => model_connection_response.go} | 214 ++++---- .../model_connection_status_response.go | 75 ++- ...model_create_gateway_connection_payload.go | 108 ++-- .../model_create_vpn_gateway_payload.go | 66 +-- ..._vpn_gateway_payload_availability_zones.go | 2 +- services/vpn/v1alpha1api/model_gateway.go | 66 +-- .../model_gateway_availability_zones.go | 2 +- .../vpn/v1alpha1api/model_gateway_list.go | 2 +- .../vpn/v1alpha1api/model_gateway_response.go | 113 +++-- .../vpn/v1alpha1api/model_gateway_status.go | 4 +- .../model_gateway_status_response.go | 111 ++++- .../vpn/v1alpha1api/model_peering_config.go | 2 +- services/vpn/v1alpha1api/model_phase.go | 2 +- .../vpn/v1alpha1api/model_phase1_status.go | 8 +- .../vpn/v1alpha1api/model_phase2_status.go | 24 +- services/vpn/v1alpha1api/model_plan.go | 86 +--- services/vpn/v1alpha1api/model_plan_list.go | 44 +- services/vpn/v1alpha1api/model_quota.go | 2 +- services/vpn/v1alpha1api/model_quota_list.go | 4 +- .../v1alpha1api/model_quota_list_response.go | 2 +- services/vpn/v1alpha1api/model_region.go | 2 +- .../vpn/v1alpha1api/model_routing_type.go | 2 +- .../v1alpha1api/model_tunnel_configuration.go | 2 +- .../model_tunnel_configuration_phase1.go | 2 +- .../model_tunnel_configuration_phase2.go | 6 +- .../vpn/v1alpha1api/model_tunnel_status.go | 2 +- ...model_update_gateway_connection_payload.go | 108 ++-- .../model_update_vpn_gateway_payload.go | 66 +-- ..._vpn_gateway_payload_availability_zones.go | 2 +- .../vpn/v1alpha1api/model_vpn_tunnel_plan.go | 199 -------- services/vpn/v1alpha1api/model_vpn_tunnels.go | 7 +- services/vpn/v1alpha1api/response.go | 2 +- services/vpn/v1alpha1api/utils.go | 2 +- 47 files changed, 947 insertions(+), 1163 deletions(-) rename services/vpn/v1alpha1api/{model_connection.go => model_connection_response.go} (56%) delete mode 100644 services/vpn/v1alpha1api/model_vpn_tunnel_plan.go diff --git a/services/vpn/oas_commit b/services/vpn/oas_commit index bf3189995..e6996ba65 100644 --- a/services/vpn/oas_commit +++ b/services/vpn/oas_commit @@ -1 +1 @@ -3e9c109388be83b40c16d8cb5ab146aa314eb6e8 +5cc62daf6e2109097bee8436b7085328e452c937 diff --git a/services/vpn/v1alpha1api/api_default.go b/services/vpn/v1alpha1api/api_default.go index 3965a6651..773de4f0f 100644 --- a/services/vpn/v1alpha1api/api_default.go +++ b/services/vpn/v1alpha1api/api_default.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ @@ -24,26 +24,26 @@ import ( type DefaultAPI interface { /* - CreateGatewayConnection Create a connection for an existing VPN gateway. + CreateGatewayConnection Create a new connection on an existing VPN gateway. - Create a connection for an existing VPN gateway. + Create a new connection on an existing VPN gateway. @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param projectId @param region - @param gatewayName + @param gatewayId @return ApiCreateGatewayConnectionRequest */ - CreateGatewayConnection(ctx context.Context, projectId string, region Region, gatewayName string) ApiCreateGatewayConnectionRequest + CreateGatewayConnection(ctx context.Context, projectId string, region Region, gatewayId string) ApiCreateGatewayConnectionRequest // CreateGatewayConnectionExecute executes the request - // @return Connection - CreateGatewayConnectionExecute(r ApiCreateGatewayConnectionRequest) (*Connection, error) + // @return ConnectionResponse + CreateGatewayConnectionExecute(r ApiCreateGatewayConnectionRequest) (*ConnectionResponse, error) /* CreateVPNGateway Create a VPN gateway in a project. - Create a VPN gateway in a project. + Provision a new VPN gateway. @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param projectId @@ -64,27 +64,29 @@ type DefaultAPI interface { @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param projectId @param region - @param gatewayName - @param connectionName + @param gatewayId + @param connectionId @return ApiDeleteGatewayConnectionRequest */ - DeleteGatewayConnection(ctx context.Context, projectId string, region Region, gatewayName string, connectionName string) ApiDeleteGatewayConnectionRequest + DeleteGatewayConnection(ctx context.Context, projectId string, region Region, gatewayId string, connectionId string) ApiDeleteGatewayConnectionRequest // DeleteGatewayConnectionExecute executes the request DeleteGatewayConnectionExecute(r ApiDeleteGatewayConnectionRequest) error /* - DeleteVPNGateway Delete a existing VPN gateway in a project. + DeleteVPNGateway Delete a existing VPN gateway in a project. - Delete a existing VPN gateway and all it's connections in a project. + Permanently remove a VPN gateway and all its associated connections. + This operation is irreversible. - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - @param projectId - @param region - @param gatewayName - @return ApiDeleteVPNGatewayRequest + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param projectId + @param region + @param gatewayId + @return ApiDeleteVPNGatewayRequest */ - DeleteVPNGateway(ctx context.Context, projectId string, region Region, gatewayName string) ApiDeleteVPNGatewayRequest + DeleteVPNGateway(ctx context.Context, projectId string, region Region, gatewayId string) ApiDeleteVPNGatewayRequest // DeleteVPNGatewayExecute executes the request DeleteVPNGatewayExecute(r ApiDeleteVPNGatewayRequest) error @@ -97,29 +99,29 @@ type DefaultAPI interface { @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param projectId @param region - @param gatewayName - @param connectionName + @param gatewayId + @param connectionId @return ApiGetGatewayConnectionRequest */ - GetGatewayConnection(ctx context.Context, projectId string, region Region, gatewayName string, connectionName string) ApiGetGatewayConnectionRequest + GetGatewayConnection(ctx context.Context, projectId string, region Region, gatewayId string, connectionId string) ApiGetGatewayConnectionRequest // GetGatewayConnectionExecute executes the request - // @return Connection - GetGatewayConnectionExecute(r ApiGetGatewayConnectionRequest) (*Connection, error) + // @return ConnectionResponse + GetGatewayConnectionExecute(r ApiGetGatewayConnectionRequest) (*ConnectionResponse, error) /* - GetGatewayConnectionStatus Gets the status for a specific connection in an existing VPN gateway. + GetGatewayConnectionStatus Gets the status for a specific connection. - Gets the status for a specific connection in an existing VPN gateway. + Get the status for a specific connection. @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param projectId @param region - @param gatewayName - @param connectionName + @param gatewayId + @param connectionId @return ApiGetGatewayConnectionStatusRequest */ - GetGatewayConnectionStatus(ctx context.Context, projectId string, region Region, gatewayName string, connectionName string) ApiGetGatewayConnectionStatusRequest + GetGatewayConnectionStatus(ctx context.Context, projectId string, region Region, gatewayId string, connectionId string) ApiGetGatewayConnectionStatusRequest // GetGatewayConnectionStatusExecute executes the request // @return ConnectionStatusResponse @@ -133,10 +135,10 @@ type DefaultAPI interface { @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param projectId @param region - @param gatewayName + @param gatewayId @return ApiGetVPNGatewayRequest */ - GetVPNGateway(ctx context.Context, projectId string, region Region, gatewayName string) ApiGetVPNGatewayRequest + GetVPNGateway(ctx context.Context, projectId string, region Region, gatewayId string) ApiGetVPNGatewayRequest // GetVPNGatewayExecute executes the request // @return GatewayResponse @@ -150,10 +152,10 @@ type DefaultAPI interface { @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param projectId @param region - @param gatewayName + @param gatewayId @return ApiGetVPNGatewayStatusRequest */ - GetVPNGatewayStatus(ctx context.Context, projectId string, region Region, gatewayName string) ApiGetVPNGatewayStatusRequest + GetVPNGatewayStatus(ctx context.Context, projectId string, region Region, gatewayId string) ApiGetVPNGatewayStatusRequest // GetVPNGatewayStatusExecute executes the request // @return GatewayStatusResponse @@ -167,23 +169,25 @@ type DefaultAPI interface { @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param projectId @param region - @param gatewayName + @param gatewayId @return ApiListGatewayConnectionsRequest */ - ListGatewayConnections(ctx context.Context, projectId string, region Region, gatewayName string) ApiListGatewayConnectionsRequest + ListGatewayConnections(ctx context.Context, projectId string, region Region, gatewayId string) ApiListGatewayConnectionsRequest // ListGatewayConnectionsExecute executes the request // @return ConnectionList ListGatewayConnectionsExecute(r ApiListGatewayConnectionsRequest) (*ConnectionList, error) /* - ListPlans List available service plans for a project. + ListPlans List available service plans for a project. - List available service plans for a project. + Retrieve a list of available service plans available for provisioning a VPN in a specific `region`. + Use this to identify the `planId` required for gateway creation. - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - @param region - @return ApiListPlansRequest + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param region + @return ApiListPlansRequest */ ListPlans(ctx context.Context, region Region) ApiListPlansRequest @@ -194,7 +198,8 @@ type DefaultAPI interface { /* ListQuotas List project quotas. - List project quotas. + Retrieve the resource quotas and current usage for STACKIT VPN within a specific project and region. + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param projectId @@ -208,14 +213,16 @@ type DefaultAPI interface { ListQuotasExecute(r ApiListQuotasRequest) (*QuotaListResponse, error) /* - ListVPNGateways List VPN gateways in a project with label filtering + ListVPNGateways List VPN gateways in a project with label filtering - Retrieve VPN gateways in a project filtered by a custom label selector format. + Retrieve a list of all VPN gateways in a project. + Filter the results using the `label_selector` query parameter. - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - @param projectId - @param region - @return ApiListVPNGatewaysRequest + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param projectId + @param region + @return ApiListVPNGatewaysRequest */ ListVPNGateways(ctx context.Context, projectId string, region Region) ApiListVPNGatewaysRequest @@ -224,35 +231,37 @@ type DefaultAPI interface { ListVPNGatewaysExecute(r ApiListVPNGatewaysRequest) (*GatewayList, error) /* - UpdateGatewayConnection Update a connection for an existing VPN gateway. + UpdateGatewayConnection Update a connection on an existing VPN gateway. - Update a connection for an existing VPN gateway. + Updating the configuration of an existing connection. @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param projectId @param region - @param gatewayName - @param connectionName + @param gatewayId + @param connectionId @return ApiUpdateGatewayConnectionRequest */ - UpdateGatewayConnection(ctx context.Context, projectId string, region Region, gatewayName string, connectionName string) ApiUpdateGatewayConnectionRequest + UpdateGatewayConnection(ctx context.Context, projectId string, region Region, gatewayId string, connectionId string) ApiUpdateGatewayConnectionRequest // UpdateGatewayConnectionExecute executes the request - // @return Connection - UpdateGatewayConnectionExecute(r ApiUpdateGatewayConnectionRequest) (*Connection, error) + // @return ConnectionResponse + UpdateGatewayConnectionExecute(r ApiUpdateGatewayConnectionRequest) (*ConnectionResponse, error) /* - UpdateVPNGateway Update a VPN gateway in a project. + UpdateVPNGateway Update a VPN gateway in a project. - Update a VPN gateway in a project. + Modify the configuration of an existing VPN gateway. + Certain changes may trigger infrastructure updates or temporary connection re-negotiations. - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - @param projectId - @param region - @param gatewayName - @return ApiUpdateVPNGatewayRequest + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param projectId + @param region + @param gatewayId + @return ApiUpdateVPNGatewayRequest */ - UpdateVPNGateway(ctx context.Context, projectId string, region Region, gatewayName string) ApiUpdateVPNGatewayRequest + UpdateVPNGateway(ctx context.Context, projectId string, region Region, gatewayId string) ApiUpdateVPNGatewayRequest // UpdateVPNGatewayExecute executes the request // @return GatewayResponse @@ -267,7 +276,7 @@ type ApiCreateGatewayConnectionRequest struct { ApiService DefaultAPI projectId string region Region - gatewayName string + gatewayId string createGatewayConnectionPayload *CreateGatewayConnectionPayload } @@ -276,40 +285,40 @@ func (r ApiCreateGatewayConnectionRequest) CreateGatewayConnectionPayload(create return r } -func (r ApiCreateGatewayConnectionRequest) Execute() (*Connection, error) { +func (r ApiCreateGatewayConnectionRequest) Execute() (*ConnectionResponse, error) { return r.ApiService.CreateGatewayConnectionExecute(r) } /* -CreateGatewayConnection Create a connection for an existing VPN gateway. +CreateGatewayConnection Create a new connection on an existing VPN gateway. -Create a connection for an existing VPN gateway. +Create a new connection on an existing VPN gateway. @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param projectId @param region - @param gatewayName + @param gatewayId @return ApiCreateGatewayConnectionRequest */ -func (a *DefaultAPIService) CreateGatewayConnection(ctx context.Context, projectId string, region Region, gatewayName string) ApiCreateGatewayConnectionRequest { +func (a *DefaultAPIService) CreateGatewayConnection(ctx context.Context, projectId string, region Region, gatewayId string) ApiCreateGatewayConnectionRequest { return ApiCreateGatewayConnectionRequest{ - ApiService: a, - ctx: ctx, - projectId: projectId, - region: region, - gatewayName: gatewayName, + ApiService: a, + ctx: ctx, + projectId: projectId, + region: region, + gatewayId: gatewayId, } } // Execute executes the request // -// @return Connection -func (a *DefaultAPIService) CreateGatewayConnectionExecute(r ApiCreateGatewayConnectionRequest) (*Connection, error) { +// @return ConnectionResponse +func (a *DefaultAPIService) CreateGatewayConnectionExecute(r ApiCreateGatewayConnectionRequest) (*ConnectionResponse, error) { var ( localVarHTTPMethod = http.MethodPost localVarPostBody interface{} formFiles []formFile - localVarReturnValue *Connection + localVarReturnValue *ConnectionResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "DefaultAPIService.CreateGatewayConnection") @@ -317,10 +326,10 @@ func (a *DefaultAPIService) CreateGatewayConnectionExecute(r ApiCreateGatewayCon return localVarReturnValue, &oapierror.GenericOpenAPIError{ErrorMessage: err.Error()} } - localVarPath := localBasePath + "/v1alpha1/projects/{projectId}/regions/{region}/gateways/{gatewayName}/connections" + localVarPath := localBasePath + "/v1alpha1/projects/{projectId}/regions/{region}/gateways/{gatewayId}/connections" localVarPath = strings.Replace(localVarPath, "{"+"projectId"+"}", url.PathEscape(parameterValueToString(r.projectId, "projectId")), -1) localVarPath = strings.Replace(localVarPath, "{"+"region"+"}", url.PathEscape(parameterValueToString(r.region, "region")), -1) - localVarPath = strings.Replace(localVarPath, "{"+"gatewayName"+"}", url.PathEscape(parameterValueToString(r.gatewayName, "gatewayName")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"gatewayId"+"}", url.PathEscape(parameterValueToString(r.gatewayId, "gatewayId")), -1) localVarHeaderParams := make(map[string]string) localVarQueryParams := url.Values{} @@ -472,7 +481,7 @@ func (r ApiCreateVPNGatewayRequest) Execute() (*GatewayResponse, error) { /* CreateVPNGateway Create a VPN gateway in a project. -Create a VPN gateway in a project. +Provision a new VPN gateway. @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param projectId @@ -642,12 +651,12 @@ func (a *DefaultAPIService) CreateVPNGatewayExecute(r ApiCreateVPNGatewayRequest } type ApiDeleteGatewayConnectionRequest struct { - ctx context.Context - ApiService DefaultAPI - projectId string - region Region - gatewayName string - connectionName string + ctx context.Context + ApiService DefaultAPI + projectId string + region Region + gatewayId string + connectionId string } func (r ApiDeleteGatewayConnectionRequest) Execute() error { @@ -662,18 +671,18 @@ Delete a certain connection from an existing VPN gateway. @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param projectId @param region - @param gatewayName - @param connectionName + @param gatewayId + @param connectionId @return ApiDeleteGatewayConnectionRequest */ -func (a *DefaultAPIService) DeleteGatewayConnection(ctx context.Context, projectId string, region Region, gatewayName string, connectionName string) ApiDeleteGatewayConnectionRequest { +func (a *DefaultAPIService) DeleteGatewayConnection(ctx context.Context, projectId string, region Region, gatewayId string, connectionId string) ApiDeleteGatewayConnectionRequest { return ApiDeleteGatewayConnectionRequest{ - ApiService: a, - ctx: ctx, - projectId: projectId, - region: region, - gatewayName: gatewayName, - connectionName: connectionName, + ApiService: a, + ctx: ctx, + projectId: projectId, + region: region, + gatewayId: gatewayId, + connectionId: connectionId, } } @@ -690,11 +699,11 @@ func (a *DefaultAPIService) DeleteGatewayConnectionExecute(r ApiDeleteGatewayCon return &oapierror.GenericOpenAPIError{ErrorMessage: err.Error()} } - localVarPath := localBasePath + "/v1alpha1/projects/{projectId}/regions/{region}/gateways/{gatewayName}/connections/{connectionName}" + localVarPath := localBasePath + "/v1alpha1/projects/{projectId}/regions/{region}/gateways/{gatewayId}/connections/{connectionId}" localVarPath = strings.Replace(localVarPath, "{"+"projectId"+"}", url.PathEscape(parameterValueToString(r.projectId, "projectId")), -1) localVarPath = strings.Replace(localVarPath, "{"+"region"+"}", url.PathEscape(parameterValueToString(r.region, "region")), -1) - localVarPath = strings.Replace(localVarPath, "{"+"gatewayName"+"}", url.PathEscape(parameterValueToString(r.gatewayName, "gatewayName")), -1) - localVarPath = strings.Replace(localVarPath, "{"+"connectionName"+"}", url.PathEscape(parameterValueToString(r.connectionName, "connectionName")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"gatewayId"+"}", url.PathEscape(parameterValueToString(r.gatewayId, "gatewayId")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"connectionId"+"}", url.PathEscape(parameterValueToString(r.connectionId, "connectionId")), -1) localVarHeaderParams := make(map[string]string) localVarQueryParams := url.Values{} @@ -815,11 +824,11 @@ func (a *DefaultAPIService) DeleteGatewayConnectionExecute(r ApiDeleteGatewayCon } type ApiDeleteVPNGatewayRequest struct { - ctx context.Context - ApiService DefaultAPI - projectId string - region Region - gatewayName string + ctx context.Context + ApiService DefaultAPI + projectId string + region Region + gatewayId string } func (r ApiDeleteVPNGatewayRequest) Execute() error { @@ -829,21 +838,22 @@ func (r ApiDeleteVPNGatewayRequest) Execute() error { /* DeleteVPNGateway Delete a existing VPN gateway in a project. -Delete a existing VPN gateway and all it's connections in a project. +Permanently remove a VPN gateway and all its associated connections. +This operation is irreversible. @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param projectId @param region - @param gatewayName + @param gatewayId @return ApiDeleteVPNGatewayRequest */ -func (a *DefaultAPIService) DeleteVPNGateway(ctx context.Context, projectId string, region Region, gatewayName string) ApiDeleteVPNGatewayRequest { +func (a *DefaultAPIService) DeleteVPNGateway(ctx context.Context, projectId string, region Region, gatewayId string) ApiDeleteVPNGatewayRequest { return ApiDeleteVPNGatewayRequest{ - ApiService: a, - ctx: ctx, - projectId: projectId, - region: region, - gatewayName: gatewayName, + ApiService: a, + ctx: ctx, + projectId: projectId, + region: region, + gatewayId: gatewayId, } } @@ -860,10 +870,10 @@ func (a *DefaultAPIService) DeleteVPNGatewayExecute(r ApiDeleteVPNGatewayRequest return &oapierror.GenericOpenAPIError{ErrorMessage: err.Error()} } - localVarPath := localBasePath + "/v1alpha1/projects/{projectId}/regions/{region}/gateways/{gatewayName}" + localVarPath := localBasePath + "/v1alpha1/projects/{projectId}/regions/{region}/gateways/{gatewayId}" localVarPath = strings.Replace(localVarPath, "{"+"projectId"+"}", url.PathEscape(parameterValueToString(r.projectId, "projectId")), -1) localVarPath = strings.Replace(localVarPath, "{"+"region"+"}", url.PathEscape(parameterValueToString(r.region, "region")), -1) - localVarPath = strings.Replace(localVarPath, "{"+"gatewayName"+"}", url.PathEscape(parameterValueToString(r.gatewayName, "gatewayName")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"gatewayId"+"}", url.PathEscape(parameterValueToString(r.gatewayId, "gatewayId")), -1) localVarHeaderParams := make(map[string]string) localVarQueryParams := url.Values{} @@ -972,15 +982,15 @@ func (a *DefaultAPIService) DeleteVPNGatewayExecute(r ApiDeleteVPNGatewayRequest } type ApiGetGatewayConnectionRequest struct { - ctx context.Context - ApiService DefaultAPI - projectId string - region Region - gatewayName string - connectionName string + ctx context.Context + ApiService DefaultAPI + projectId string + region Region + gatewayId string + connectionId string } -func (r ApiGetGatewayConnectionRequest) Execute() (*Connection, error) { +func (r ApiGetGatewayConnectionRequest) Execute() (*ConnectionResponse, error) { return r.ApiService.GetGatewayConnectionExecute(r) } @@ -992,30 +1002,30 @@ Get a certain connection for an existing VPN gateway. @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param projectId @param region - @param gatewayName - @param connectionName + @param gatewayId + @param connectionId @return ApiGetGatewayConnectionRequest */ -func (a *DefaultAPIService) GetGatewayConnection(ctx context.Context, projectId string, region Region, gatewayName string, connectionName string) ApiGetGatewayConnectionRequest { +func (a *DefaultAPIService) GetGatewayConnection(ctx context.Context, projectId string, region Region, gatewayId string, connectionId string) ApiGetGatewayConnectionRequest { return ApiGetGatewayConnectionRequest{ - ApiService: a, - ctx: ctx, - projectId: projectId, - region: region, - gatewayName: gatewayName, - connectionName: connectionName, + ApiService: a, + ctx: ctx, + projectId: projectId, + region: region, + gatewayId: gatewayId, + connectionId: connectionId, } } // Execute executes the request // -// @return Connection -func (a *DefaultAPIService) GetGatewayConnectionExecute(r ApiGetGatewayConnectionRequest) (*Connection, error) { +// @return ConnectionResponse +func (a *DefaultAPIService) GetGatewayConnectionExecute(r ApiGetGatewayConnectionRequest) (*ConnectionResponse, error) { var ( localVarHTTPMethod = http.MethodGet localVarPostBody interface{} formFiles []formFile - localVarReturnValue *Connection + localVarReturnValue *ConnectionResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "DefaultAPIService.GetGatewayConnection") @@ -1023,11 +1033,11 @@ func (a *DefaultAPIService) GetGatewayConnectionExecute(r ApiGetGatewayConnectio return localVarReturnValue, &oapierror.GenericOpenAPIError{ErrorMessage: err.Error()} } - localVarPath := localBasePath + "/v1alpha1/projects/{projectId}/regions/{region}/gateways/{gatewayName}/connections/{connectionName}" + localVarPath := localBasePath + "/v1alpha1/projects/{projectId}/regions/{region}/gateways/{gatewayId}/connections/{connectionId}" localVarPath = strings.Replace(localVarPath, "{"+"projectId"+"}", url.PathEscape(parameterValueToString(r.projectId, "projectId")), -1) localVarPath = strings.Replace(localVarPath, "{"+"region"+"}", url.PathEscape(parameterValueToString(r.region, "region")), -1) - localVarPath = strings.Replace(localVarPath, "{"+"gatewayName"+"}", url.PathEscape(parameterValueToString(r.gatewayName, "gatewayName")), -1) - localVarPath = strings.Replace(localVarPath, "{"+"connectionName"+"}", url.PathEscape(parameterValueToString(r.connectionName, "connectionName")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"gatewayId"+"}", url.PathEscape(parameterValueToString(r.gatewayId, "gatewayId")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"connectionId"+"}", url.PathEscape(parameterValueToString(r.connectionId, "connectionId")), -1) localVarHeaderParams := make(map[string]string) localVarQueryParams := url.Values{} @@ -1158,12 +1168,12 @@ func (a *DefaultAPIService) GetGatewayConnectionExecute(r ApiGetGatewayConnectio } type ApiGetGatewayConnectionStatusRequest struct { - ctx context.Context - ApiService DefaultAPI - projectId string - region Region - gatewayName string - connectionName string + ctx context.Context + ApiService DefaultAPI + projectId string + region Region + gatewayId string + connectionId string } func (r ApiGetGatewayConnectionStatusRequest) Execute() (*ConnectionStatusResponse, error) { @@ -1171,25 +1181,25 @@ func (r ApiGetGatewayConnectionStatusRequest) Execute() (*ConnectionStatusRespon } /* -GetGatewayConnectionStatus Gets the status for a specific connection in an existing VPN gateway. +GetGatewayConnectionStatus Gets the status for a specific connection. -Gets the status for a specific connection in an existing VPN gateway. +Get the status for a specific connection. @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param projectId @param region - @param gatewayName - @param connectionName + @param gatewayId + @param connectionId @return ApiGetGatewayConnectionStatusRequest */ -func (a *DefaultAPIService) GetGatewayConnectionStatus(ctx context.Context, projectId string, region Region, gatewayName string, connectionName string) ApiGetGatewayConnectionStatusRequest { +func (a *DefaultAPIService) GetGatewayConnectionStatus(ctx context.Context, projectId string, region Region, gatewayId string, connectionId string) ApiGetGatewayConnectionStatusRequest { return ApiGetGatewayConnectionStatusRequest{ - ApiService: a, - ctx: ctx, - projectId: projectId, - region: region, - gatewayName: gatewayName, - connectionName: connectionName, + ApiService: a, + ctx: ctx, + projectId: projectId, + region: region, + gatewayId: gatewayId, + connectionId: connectionId, } } @@ -1209,11 +1219,11 @@ func (a *DefaultAPIService) GetGatewayConnectionStatusExecute(r ApiGetGatewayCon return localVarReturnValue, &oapierror.GenericOpenAPIError{ErrorMessage: err.Error()} } - localVarPath := localBasePath + "/v1alpha1/projects/{projectId}/regions/{region}/gateways/{gatewayName}/connections/{connectionName}/status" + localVarPath := localBasePath + "/v1alpha1/projects/{projectId}/regions/{region}/gateways/{gatewayId}/connections/{connectionId}/status" localVarPath = strings.Replace(localVarPath, "{"+"projectId"+"}", url.PathEscape(parameterValueToString(r.projectId, "projectId")), -1) localVarPath = strings.Replace(localVarPath, "{"+"region"+"}", url.PathEscape(parameterValueToString(r.region, "region")), -1) - localVarPath = strings.Replace(localVarPath, "{"+"gatewayName"+"}", url.PathEscape(parameterValueToString(r.gatewayName, "gatewayName")), -1) - localVarPath = strings.Replace(localVarPath, "{"+"connectionName"+"}", url.PathEscape(parameterValueToString(r.connectionName, "connectionName")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"gatewayId"+"}", url.PathEscape(parameterValueToString(r.gatewayId, "gatewayId")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"connectionId"+"}", url.PathEscape(parameterValueToString(r.connectionId, "connectionId")), -1) localVarHeaderParams := make(map[string]string) localVarQueryParams := url.Values{} @@ -1344,11 +1354,11 @@ func (a *DefaultAPIService) GetGatewayConnectionStatusExecute(r ApiGetGatewayCon } type ApiGetVPNGatewayRequest struct { - ctx context.Context - ApiService DefaultAPI - projectId string - region Region - gatewayName string + ctx context.Context + ApiService DefaultAPI + projectId string + region Region + gatewayId string } func (r ApiGetVPNGatewayRequest) Execute() (*GatewayResponse, error) { @@ -1363,16 +1373,16 @@ Get details of a VPN Gateway in a project. @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param projectId @param region - @param gatewayName + @param gatewayId @return ApiGetVPNGatewayRequest */ -func (a *DefaultAPIService) GetVPNGateway(ctx context.Context, projectId string, region Region, gatewayName string) ApiGetVPNGatewayRequest { +func (a *DefaultAPIService) GetVPNGateway(ctx context.Context, projectId string, region Region, gatewayId string) ApiGetVPNGatewayRequest { return ApiGetVPNGatewayRequest{ - ApiService: a, - ctx: ctx, - projectId: projectId, - region: region, - gatewayName: gatewayName, + ApiService: a, + ctx: ctx, + projectId: projectId, + region: region, + gatewayId: gatewayId, } } @@ -1392,10 +1402,10 @@ func (a *DefaultAPIService) GetVPNGatewayExecute(r ApiGetVPNGatewayRequest) (*Ga return localVarReturnValue, &oapierror.GenericOpenAPIError{ErrorMessage: err.Error()} } - localVarPath := localBasePath + "/v1alpha1/projects/{projectId}/regions/{region}/gateways/{gatewayName}" + localVarPath := localBasePath + "/v1alpha1/projects/{projectId}/regions/{region}/gateways/{gatewayId}" localVarPath = strings.Replace(localVarPath, "{"+"projectId"+"}", url.PathEscape(parameterValueToString(r.projectId, "projectId")), -1) localVarPath = strings.Replace(localVarPath, "{"+"region"+"}", url.PathEscape(parameterValueToString(r.region, "region")), -1) - localVarPath = strings.Replace(localVarPath, "{"+"gatewayName"+"}", url.PathEscape(parameterValueToString(r.gatewayName, "gatewayName")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"gatewayId"+"}", url.PathEscape(parameterValueToString(r.gatewayId, "gatewayId")), -1) localVarHeaderParams := make(map[string]string) localVarQueryParams := url.Values{} @@ -1526,11 +1536,11 @@ func (a *DefaultAPIService) GetVPNGatewayExecute(r ApiGetVPNGatewayRequest) (*Ga } type ApiGetVPNGatewayStatusRequest struct { - ctx context.Context - ApiService DefaultAPI - projectId string - region Region - gatewayName string + ctx context.Context + ApiService DefaultAPI + projectId string + region Region + gatewayId string } func (r ApiGetVPNGatewayStatusRequest) Execute() (*GatewayStatusResponse, error) { @@ -1545,16 +1555,16 @@ Get the status of a VPN gateway in a project. @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param projectId @param region - @param gatewayName + @param gatewayId @return ApiGetVPNGatewayStatusRequest */ -func (a *DefaultAPIService) GetVPNGatewayStatus(ctx context.Context, projectId string, region Region, gatewayName string) ApiGetVPNGatewayStatusRequest { +func (a *DefaultAPIService) GetVPNGatewayStatus(ctx context.Context, projectId string, region Region, gatewayId string) ApiGetVPNGatewayStatusRequest { return ApiGetVPNGatewayStatusRequest{ - ApiService: a, - ctx: ctx, - projectId: projectId, - region: region, - gatewayName: gatewayName, + ApiService: a, + ctx: ctx, + projectId: projectId, + region: region, + gatewayId: gatewayId, } } @@ -1574,10 +1584,10 @@ func (a *DefaultAPIService) GetVPNGatewayStatusExecute(r ApiGetVPNGatewayStatusR return localVarReturnValue, &oapierror.GenericOpenAPIError{ErrorMessage: err.Error()} } - localVarPath := localBasePath + "/v1alpha1/projects/{projectId}/regions/{region}/gateways/{gatewayName}/status" + localVarPath := localBasePath + "/v1alpha1/projects/{projectId}/regions/{region}/gateways/{gatewayId}/status" localVarPath = strings.Replace(localVarPath, "{"+"projectId"+"}", url.PathEscape(parameterValueToString(r.projectId, "projectId")), -1) localVarPath = strings.Replace(localVarPath, "{"+"region"+"}", url.PathEscape(parameterValueToString(r.region, "region")), -1) - localVarPath = strings.Replace(localVarPath, "{"+"gatewayName"+"}", url.PathEscape(parameterValueToString(r.gatewayName, "gatewayName")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"gatewayId"+"}", url.PathEscape(parameterValueToString(r.gatewayId, "gatewayId")), -1) localVarHeaderParams := make(map[string]string) localVarQueryParams := url.Values{} @@ -1712,10 +1722,11 @@ type ApiListGatewayConnectionsRequest struct { ApiService DefaultAPI projectId string region Region - gatewayName string + gatewayId string labelSelector *map[string]string } +// Filter resources by labels. func (r ApiListGatewayConnectionsRequest) LabelSelector(labelSelector map[string]string) ApiListGatewayConnectionsRequest { r.labelSelector = &labelSelector return r @@ -1733,16 +1744,16 @@ List connections for an existing VPN gateway. @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param projectId @param region - @param gatewayName + @param gatewayId @return ApiListGatewayConnectionsRequest */ -func (a *DefaultAPIService) ListGatewayConnections(ctx context.Context, projectId string, region Region, gatewayName string) ApiListGatewayConnectionsRequest { +func (a *DefaultAPIService) ListGatewayConnections(ctx context.Context, projectId string, region Region, gatewayId string) ApiListGatewayConnectionsRequest { return ApiListGatewayConnectionsRequest{ - ApiService: a, - ctx: ctx, - projectId: projectId, - region: region, - gatewayName: gatewayName, + ApiService: a, + ctx: ctx, + projectId: projectId, + region: region, + gatewayId: gatewayId, } } @@ -1762,10 +1773,10 @@ func (a *DefaultAPIService) ListGatewayConnectionsExecute(r ApiListGatewayConnec return localVarReturnValue, &oapierror.GenericOpenAPIError{ErrorMessage: err.Error()} } - localVarPath := localBasePath + "/v1alpha1/projects/{projectId}/regions/{region}/gateways/{gatewayName}/connections" + localVarPath := localBasePath + "/v1alpha1/projects/{projectId}/regions/{region}/gateways/{gatewayId}/connections" localVarPath = strings.Replace(localVarPath, "{"+"projectId"+"}", url.PathEscape(parameterValueToString(r.projectId, "projectId")), -1) localVarPath = strings.Replace(localVarPath, "{"+"region"+"}", url.PathEscape(parameterValueToString(r.region, "region")), -1) - localVarPath = strings.Replace(localVarPath, "{"+"gatewayName"+"}", url.PathEscape(parameterValueToString(r.gatewayName, "gatewayName")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"gatewayId"+"}", url.PathEscape(parameterValueToString(r.gatewayId, "gatewayId")), -1) localVarHeaderParams := make(map[string]string) localVarQueryParams := url.Values{} @@ -1911,7 +1922,8 @@ func (r ApiListPlansRequest) Execute() (*PlanList, error) { /* ListPlans List available service plans for a project. -List available service plans for a project. +Retrieve a list of available service plans available for provisioning a VPN in a specific `region`. +Use this to identify the `planId` required for gateway creation. @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param region @@ -2050,7 +2062,7 @@ func (r ApiListQuotasRequest) Execute() (*QuotaListResponse, error) { /* ListQuotas List project quotas. -List project quotas. +Retrieve the resource quotas and current usage for STACKIT VPN within a specific project and region. @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param projectId @@ -2186,6 +2198,7 @@ type ApiListVPNGatewaysRequest struct { labelSelector *map[string]string } +// Filter resources by labels. func (r ApiListVPNGatewaysRequest) LabelSelector(labelSelector map[string]string) ApiListVPNGatewaysRequest { r.labelSelector = &labelSelector return r @@ -2198,7 +2211,8 @@ func (r ApiListVPNGatewaysRequest) Execute() (*GatewayList, error) { /* ListVPNGateways List VPN gateways in a project with label filtering -Retrieve VPN gateways in a project filtered by a custom label selector format. +Retrieve a list of all VPN gateways in a project. +Filter the results using the `label_selector` query parameter. @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param projectId @@ -2358,8 +2372,8 @@ type ApiUpdateGatewayConnectionRequest struct { ApiService DefaultAPI projectId string region Region - gatewayName string - connectionName string + gatewayId string + connectionId string updateGatewayConnectionPayload *UpdateGatewayConnectionPayload } @@ -2368,42 +2382,42 @@ func (r ApiUpdateGatewayConnectionRequest) UpdateGatewayConnectionPayload(update return r } -func (r ApiUpdateGatewayConnectionRequest) Execute() (*Connection, error) { +func (r ApiUpdateGatewayConnectionRequest) Execute() (*ConnectionResponse, error) { return r.ApiService.UpdateGatewayConnectionExecute(r) } /* -UpdateGatewayConnection Update a connection for an existing VPN gateway. +UpdateGatewayConnection Update a connection on an existing VPN gateway. -Update a connection for an existing VPN gateway. +Updating the configuration of an existing connection. @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param projectId @param region - @param gatewayName - @param connectionName + @param gatewayId + @param connectionId @return ApiUpdateGatewayConnectionRequest */ -func (a *DefaultAPIService) UpdateGatewayConnection(ctx context.Context, projectId string, region Region, gatewayName string, connectionName string) ApiUpdateGatewayConnectionRequest { +func (a *DefaultAPIService) UpdateGatewayConnection(ctx context.Context, projectId string, region Region, gatewayId string, connectionId string) ApiUpdateGatewayConnectionRequest { return ApiUpdateGatewayConnectionRequest{ - ApiService: a, - ctx: ctx, - projectId: projectId, - region: region, - gatewayName: gatewayName, - connectionName: connectionName, + ApiService: a, + ctx: ctx, + projectId: projectId, + region: region, + gatewayId: gatewayId, + connectionId: connectionId, } } // Execute executes the request // -// @return Connection -func (a *DefaultAPIService) UpdateGatewayConnectionExecute(r ApiUpdateGatewayConnectionRequest) (*Connection, error) { +// @return ConnectionResponse +func (a *DefaultAPIService) UpdateGatewayConnectionExecute(r ApiUpdateGatewayConnectionRequest) (*ConnectionResponse, error) { var ( localVarHTTPMethod = http.MethodPut localVarPostBody interface{} formFiles []formFile - localVarReturnValue *Connection + localVarReturnValue *ConnectionResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "DefaultAPIService.UpdateGatewayConnection") @@ -2411,11 +2425,11 @@ func (a *DefaultAPIService) UpdateGatewayConnectionExecute(r ApiUpdateGatewayCon return localVarReturnValue, &oapierror.GenericOpenAPIError{ErrorMessage: err.Error()} } - localVarPath := localBasePath + "/v1alpha1/projects/{projectId}/regions/{region}/gateways/{gatewayName}/connections/{connectionName}" + localVarPath := localBasePath + "/v1alpha1/projects/{projectId}/regions/{region}/gateways/{gatewayId}/connections/{connectionId}" localVarPath = strings.Replace(localVarPath, "{"+"projectId"+"}", url.PathEscape(parameterValueToString(r.projectId, "projectId")), -1) localVarPath = strings.Replace(localVarPath, "{"+"region"+"}", url.PathEscape(parameterValueToString(r.region, "region")), -1) - localVarPath = strings.Replace(localVarPath, "{"+"gatewayName"+"}", url.PathEscape(parameterValueToString(r.gatewayName, "gatewayName")), -1) - localVarPath = strings.Replace(localVarPath, "{"+"connectionName"+"}", url.PathEscape(parameterValueToString(r.connectionName, "connectionName")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"gatewayId"+"}", url.PathEscape(parameterValueToString(r.gatewayId, "gatewayId")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"connectionId"+"}", url.PathEscape(parameterValueToString(r.connectionId, "connectionId")), -1) localVarHeaderParams := make(map[string]string) localVarQueryParams := url.Values{} @@ -2552,7 +2566,7 @@ type ApiUpdateVPNGatewayRequest struct { ApiService DefaultAPI projectId string region Region - gatewayName string + gatewayId string updateVPNGatewayPayload *UpdateVPNGatewayPayload } @@ -2568,21 +2582,22 @@ func (r ApiUpdateVPNGatewayRequest) Execute() (*GatewayResponse, error) { /* UpdateVPNGateway Update a VPN gateway in a project. -Update a VPN gateway in a project. +Modify the configuration of an existing VPN gateway. +Certain changes may trigger infrastructure updates or temporary connection re-negotiations. @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @param projectId @param region - @param gatewayName + @param gatewayId @return ApiUpdateVPNGatewayRequest */ -func (a *DefaultAPIService) UpdateVPNGateway(ctx context.Context, projectId string, region Region, gatewayName string) ApiUpdateVPNGatewayRequest { +func (a *DefaultAPIService) UpdateVPNGateway(ctx context.Context, projectId string, region Region, gatewayId string) ApiUpdateVPNGatewayRequest { return ApiUpdateVPNGatewayRequest{ - ApiService: a, - ctx: ctx, - projectId: projectId, - region: region, - gatewayName: gatewayName, + ApiService: a, + ctx: ctx, + projectId: projectId, + region: region, + gatewayId: gatewayId, } } @@ -2602,10 +2617,10 @@ func (a *DefaultAPIService) UpdateVPNGatewayExecute(r ApiUpdateVPNGatewayRequest return localVarReturnValue, &oapierror.GenericOpenAPIError{ErrorMessage: err.Error()} } - localVarPath := localBasePath + "/v1alpha1/projects/{projectId}/regions/{region}/gateways/{gatewayName}" + localVarPath := localBasePath + "/v1alpha1/projects/{projectId}/regions/{region}/gateways/{gatewayId}" localVarPath = strings.Replace(localVarPath, "{"+"projectId"+"}", url.PathEscape(parameterValueToString(r.projectId, "projectId")), -1) localVarPath = strings.Replace(localVarPath, "{"+"region"+"}", url.PathEscape(parameterValueToString(r.region, "region")), -1) - localVarPath = strings.Replace(localVarPath, "{"+"gatewayName"+"}", url.PathEscape(parameterValueToString(r.gatewayName, "gatewayName")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"gatewayId"+"}", url.PathEscape(parameterValueToString(r.gatewayId, "gatewayId")), -1) localVarHeaderParams := make(map[string]string) localVarQueryParams := url.Values{} diff --git a/services/vpn/v1alpha1api/api_default_mock.go b/services/vpn/v1alpha1api/api_default_mock.go index f4d9d8a3c..f707b8ed9 100644 --- a/services/vpn/v1alpha1api/api_default_mock.go +++ b/services/vpn/v1alpha1api/api_default_mock.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ @@ -21,7 +21,7 @@ var _ DefaultAPI = &DefaultAPIServiceMock{} // By default all FooExecute() implementations are a no-op. Behavior of the mock can be customized by populating the callbacks in this struct. type DefaultAPIServiceMock struct { // CreateGatewayConnectionExecuteMock can be populated to implement the behavior of the CreateGatewayConnectionExecute function of this mock - CreateGatewayConnectionExecuteMock *func(r ApiCreateGatewayConnectionRequest) (*Connection, error) + CreateGatewayConnectionExecuteMock *func(r ApiCreateGatewayConnectionRequest) (*ConnectionResponse, error) // CreateVPNGatewayExecuteMock can be populated to implement the behavior of the CreateVPNGatewayExecute function of this mock CreateVPNGatewayExecuteMock *func(r ApiCreateVPNGatewayRequest) (*GatewayResponse, error) // DeleteGatewayConnectionExecuteMock can be populated to implement the behavior of the DeleteGatewayConnectionExecute function of this mock @@ -29,7 +29,7 @@ type DefaultAPIServiceMock struct { // DeleteVPNGatewayExecuteMock can be populated to implement the behavior of the DeleteVPNGatewayExecute function of this mock DeleteVPNGatewayExecuteMock *func(r ApiDeleteVPNGatewayRequest) error // GetGatewayConnectionExecuteMock can be populated to implement the behavior of the GetGatewayConnectionExecute function of this mock - GetGatewayConnectionExecuteMock *func(r ApiGetGatewayConnectionRequest) (*Connection, error) + GetGatewayConnectionExecuteMock *func(r ApiGetGatewayConnectionRequest) (*ConnectionResponse, error) // GetGatewayConnectionStatusExecuteMock can be populated to implement the behavior of the GetGatewayConnectionStatusExecute function of this mock GetGatewayConnectionStatusExecuteMock *func(r ApiGetGatewayConnectionStatusRequest) (*ConnectionStatusResponse, error) // GetVPNGatewayExecuteMock can be populated to implement the behavior of the GetVPNGatewayExecute function of this mock @@ -45,25 +45,25 @@ type DefaultAPIServiceMock struct { // ListVPNGatewaysExecuteMock can be populated to implement the behavior of the ListVPNGatewaysExecute function of this mock ListVPNGatewaysExecuteMock *func(r ApiListVPNGatewaysRequest) (*GatewayList, error) // UpdateGatewayConnectionExecuteMock can be populated to implement the behavior of the UpdateGatewayConnectionExecute function of this mock - UpdateGatewayConnectionExecuteMock *func(r ApiUpdateGatewayConnectionRequest) (*Connection, error) + UpdateGatewayConnectionExecuteMock *func(r ApiUpdateGatewayConnectionRequest) (*ConnectionResponse, error) // UpdateVPNGatewayExecuteMock can be populated to implement the behavior of the UpdateVPNGatewayExecute function of this mock UpdateVPNGatewayExecuteMock *func(r ApiUpdateVPNGatewayRequest) (*GatewayResponse, error) } -func (a DefaultAPIServiceMock) CreateGatewayConnection(ctx context.Context, projectId string, region Region, gatewayName string) ApiCreateGatewayConnectionRequest { +func (a DefaultAPIServiceMock) CreateGatewayConnection(ctx context.Context, projectId string, region Region, gatewayId string) ApiCreateGatewayConnectionRequest { return ApiCreateGatewayConnectionRequest{ - ApiService: a, - ctx: ctx, - projectId: projectId, - region: region, - gatewayName: gatewayName, + ApiService: a, + ctx: ctx, + projectId: projectId, + region: region, + gatewayId: gatewayId, } } // CreateGatewayConnectionExecute is a no-op by default and will return only return nil values. Behavior can be controlled by populating the CreateGatewayConnectionExecuteMock field in the DefaultAPIServiceMock struct. -func (a DefaultAPIServiceMock) CreateGatewayConnectionExecute(r ApiCreateGatewayConnectionRequest) (*Connection, error) { +func (a DefaultAPIServiceMock) CreateGatewayConnectionExecute(r ApiCreateGatewayConnectionRequest) (*ConnectionResponse, error) { if a.CreateGatewayConnectionExecuteMock == nil { - var localVarReturnValue *Connection + var localVarReturnValue *ConnectionResponse return localVarReturnValue, nil } @@ -89,14 +89,14 @@ func (a DefaultAPIServiceMock) CreateVPNGatewayExecute(r ApiCreateVPNGatewayRequ return (*a.CreateVPNGatewayExecuteMock)(r) } -func (a DefaultAPIServiceMock) DeleteGatewayConnection(ctx context.Context, projectId string, region Region, gatewayName string, connectionName string) ApiDeleteGatewayConnectionRequest { +func (a DefaultAPIServiceMock) DeleteGatewayConnection(ctx context.Context, projectId string, region Region, gatewayId string, connectionId string) ApiDeleteGatewayConnectionRequest { return ApiDeleteGatewayConnectionRequest{ - ApiService: a, - ctx: ctx, - projectId: projectId, - region: region, - gatewayName: gatewayName, - connectionName: connectionName, + ApiService: a, + ctx: ctx, + projectId: projectId, + region: region, + gatewayId: gatewayId, + connectionId: connectionId, } } @@ -109,13 +109,13 @@ func (a DefaultAPIServiceMock) DeleteGatewayConnectionExecute(r ApiDeleteGateway return (*a.DeleteGatewayConnectionExecuteMock)(r) } -func (a DefaultAPIServiceMock) DeleteVPNGateway(ctx context.Context, projectId string, region Region, gatewayName string) ApiDeleteVPNGatewayRequest { +func (a DefaultAPIServiceMock) DeleteVPNGateway(ctx context.Context, projectId string, region Region, gatewayId string) ApiDeleteVPNGatewayRequest { return ApiDeleteVPNGatewayRequest{ - ApiService: a, - ctx: ctx, - projectId: projectId, - region: region, - gatewayName: gatewayName, + ApiService: a, + ctx: ctx, + projectId: projectId, + region: region, + gatewayId: gatewayId, } } @@ -128,35 +128,35 @@ func (a DefaultAPIServiceMock) DeleteVPNGatewayExecute(r ApiDeleteVPNGatewayRequ return (*a.DeleteVPNGatewayExecuteMock)(r) } -func (a DefaultAPIServiceMock) GetGatewayConnection(ctx context.Context, projectId string, region Region, gatewayName string, connectionName string) ApiGetGatewayConnectionRequest { +func (a DefaultAPIServiceMock) GetGatewayConnection(ctx context.Context, projectId string, region Region, gatewayId string, connectionId string) ApiGetGatewayConnectionRequest { return ApiGetGatewayConnectionRequest{ - ApiService: a, - ctx: ctx, - projectId: projectId, - region: region, - gatewayName: gatewayName, - connectionName: connectionName, + ApiService: a, + ctx: ctx, + projectId: projectId, + region: region, + gatewayId: gatewayId, + connectionId: connectionId, } } // GetGatewayConnectionExecute is a no-op by default and will return only return nil values. Behavior can be controlled by populating the GetGatewayConnectionExecuteMock field in the DefaultAPIServiceMock struct. -func (a DefaultAPIServiceMock) GetGatewayConnectionExecute(r ApiGetGatewayConnectionRequest) (*Connection, error) { +func (a DefaultAPIServiceMock) GetGatewayConnectionExecute(r ApiGetGatewayConnectionRequest) (*ConnectionResponse, error) { if a.GetGatewayConnectionExecuteMock == nil { - var localVarReturnValue *Connection + var localVarReturnValue *ConnectionResponse return localVarReturnValue, nil } return (*a.GetGatewayConnectionExecuteMock)(r) } -func (a DefaultAPIServiceMock) GetGatewayConnectionStatus(ctx context.Context, projectId string, region Region, gatewayName string, connectionName string) ApiGetGatewayConnectionStatusRequest { +func (a DefaultAPIServiceMock) GetGatewayConnectionStatus(ctx context.Context, projectId string, region Region, gatewayId string, connectionId string) ApiGetGatewayConnectionStatusRequest { return ApiGetGatewayConnectionStatusRequest{ - ApiService: a, - ctx: ctx, - projectId: projectId, - region: region, - gatewayName: gatewayName, - connectionName: connectionName, + ApiService: a, + ctx: ctx, + projectId: projectId, + region: region, + gatewayId: gatewayId, + connectionId: connectionId, } } @@ -170,13 +170,13 @@ func (a DefaultAPIServiceMock) GetGatewayConnectionStatusExecute(r ApiGetGateway return (*a.GetGatewayConnectionStatusExecuteMock)(r) } -func (a DefaultAPIServiceMock) GetVPNGateway(ctx context.Context, projectId string, region Region, gatewayName string) ApiGetVPNGatewayRequest { +func (a DefaultAPIServiceMock) GetVPNGateway(ctx context.Context, projectId string, region Region, gatewayId string) ApiGetVPNGatewayRequest { return ApiGetVPNGatewayRequest{ - ApiService: a, - ctx: ctx, - projectId: projectId, - region: region, - gatewayName: gatewayName, + ApiService: a, + ctx: ctx, + projectId: projectId, + region: region, + gatewayId: gatewayId, } } @@ -190,13 +190,13 @@ func (a DefaultAPIServiceMock) GetVPNGatewayExecute(r ApiGetVPNGatewayRequest) ( return (*a.GetVPNGatewayExecuteMock)(r) } -func (a DefaultAPIServiceMock) GetVPNGatewayStatus(ctx context.Context, projectId string, region Region, gatewayName string) ApiGetVPNGatewayStatusRequest { +func (a DefaultAPIServiceMock) GetVPNGatewayStatus(ctx context.Context, projectId string, region Region, gatewayId string) ApiGetVPNGatewayStatusRequest { return ApiGetVPNGatewayStatusRequest{ - ApiService: a, - ctx: ctx, - projectId: projectId, - region: region, - gatewayName: gatewayName, + ApiService: a, + ctx: ctx, + projectId: projectId, + region: region, + gatewayId: gatewayId, } } @@ -210,13 +210,13 @@ func (a DefaultAPIServiceMock) GetVPNGatewayStatusExecute(r ApiGetVPNGatewayStat return (*a.GetVPNGatewayStatusExecuteMock)(r) } -func (a DefaultAPIServiceMock) ListGatewayConnections(ctx context.Context, projectId string, region Region, gatewayName string) ApiListGatewayConnectionsRequest { +func (a DefaultAPIServiceMock) ListGatewayConnections(ctx context.Context, projectId string, region Region, gatewayId string) ApiListGatewayConnectionsRequest { return ApiListGatewayConnectionsRequest{ - ApiService: a, - ctx: ctx, - projectId: projectId, - region: region, - gatewayName: gatewayName, + ApiService: a, + ctx: ctx, + projectId: projectId, + region: region, + gatewayId: gatewayId, } } @@ -286,34 +286,34 @@ func (a DefaultAPIServiceMock) ListVPNGatewaysExecute(r ApiListVPNGatewaysReques return (*a.ListVPNGatewaysExecuteMock)(r) } -func (a DefaultAPIServiceMock) UpdateGatewayConnection(ctx context.Context, projectId string, region Region, gatewayName string, connectionName string) ApiUpdateGatewayConnectionRequest { +func (a DefaultAPIServiceMock) UpdateGatewayConnection(ctx context.Context, projectId string, region Region, gatewayId string, connectionId string) ApiUpdateGatewayConnectionRequest { return ApiUpdateGatewayConnectionRequest{ - ApiService: a, - ctx: ctx, - projectId: projectId, - region: region, - gatewayName: gatewayName, - connectionName: connectionName, + ApiService: a, + ctx: ctx, + projectId: projectId, + region: region, + gatewayId: gatewayId, + connectionId: connectionId, } } // UpdateGatewayConnectionExecute is a no-op by default and will return only return nil values. Behavior can be controlled by populating the UpdateGatewayConnectionExecuteMock field in the DefaultAPIServiceMock struct. -func (a DefaultAPIServiceMock) UpdateGatewayConnectionExecute(r ApiUpdateGatewayConnectionRequest) (*Connection, error) { +func (a DefaultAPIServiceMock) UpdateGatewayConnectionExecute(r ApiUpdateGatewayConnectionRequest) (*ConnectionResponse, error) { if a.UpdateGatewayConnectionExecuteMock == nil { - var localVarReturnValue *Connection + var localVarReturnValue *ConnectionResponse return localVarReturnValue, nil } return (*a.UpdateGatewayConnectionExecuteMock)(r) } -func (a DefaultAPIServiceMock) UpdateVPNGateway(ctx context.Context, projectId string, region Region, gatewayName string) ApiUpdateVPNGatewayRequest { +func (a DefaultAPIServiceMock) UpdateVPNGateway(ctx context.Context, projectId string, region Region, gatewayId string) ApiUpdateVPNGatewayRequest { return ApiUpdateVPNGatewayRequest{ - ApiService: a, - ctx: ctx, - projectId: projectId, - region: region, - gatewayName: gatewayName, + ApiService: a, + ctx: ctx, + projectId: projectId, + region: region, + gatewayId: gatewayId, } } diff --git a/services/vpn/v1alpha1api/client.go b/services/vpn/v1alpha1api/client.go index 992fe708f..74da2a0a1 100644 --- a/services/vpn/v1alpha1api/client.go +++ b/services/vpn/v1alpha1api/client.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ diff --git a/services/vpn/v1alpha1api/configuration.go b/services/vpn/v1alpha1api/configuration.go index 0ab01ac82..d633ca395 100644 --- a/services/vpn/v1alpha1api/configuration.go +++ b/services/vpn/v1alpha1api/configuration.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ diff --git a/services/vpn/v1alpha1api/model_api_error.go b/services/vpn/v1alpha1api/model_api_error.go index 2062b97f4..7ed60eda6 100644 --- a/services/vpn/v1alpha1api/model_api_error.go +++ b/services/vpn/v1alpha1api/model_api_error.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ @@ -28,7 +28,7 @@ type APIError struct { // A message describing the error. Message string `json:"message"` // The HTTP status code text. - Status *string `json:"status,omitempty"` + Status string `json:"status"` } type _APIError APIError @@ -37,10 +37,11 @@ type _APIError APIError // This constructor will assign default values to properties that have it defined, // and makes sure properties required by API are set, but the set of arguments // will change when the set of required properties is changed -func NewAPIError(code int32, message string) *APIError { +func NewAPIError(code int32, message string, status string) *APIError { this := APIError{} this.Code = code this.Message = message + this.Status = status return &this } @@ -132,36 +133,28 @@ func (o *APIError) SetMessage(v string) { o.Message = v } -// GetStatus returns the Status field value if set, zero value otherwise. +// GetStatus returns the Status field value func (o *APIError) GetStatus() string { - if o == nil || IsNil(o.Status) { + if o == nil { var ret string return ret } - return *o.Status + + return o.Status } -// GetStatusOk returns a tuple with the Status field value if set, nil otherwise +// GetStatusOk returns a tuple with the Status field value // and a boolean to check if the value has been set. func (o *APIError) GetStatusOk() (*string, bool) { - if o == nil || IsNil(o.Status) { + if o == nil { return nil, false } - return o.Status, true -} - -// HasStatus returns a boolean if a field has been set. -func (o *APIError) HasStatus() bool { - if o != nil && !IsNil(o.Status) { - return true - } - - return false + return &o.Status, true } -// SetStatus gets a reference to the given string and assigns it to the Status field. +// SetStatus sets field value func (o *APIError) SetStatus(v string) { - o.Status = &v + o.Status = v } func (o APIError) MarshalJSON() ([]byte, error) { @@ -179,9 +172,7 @@ func (o APIError) ToMap() (map[string]interface{}, error) { toSerialize["details"] = o.Details } toSerialize["message"] = o.Message - if !IsNil(o.Status) { - toSerialize["status"] = o.Status - } + toSerialize["status"] = o.Status return toSerialize, nil } @@ -192,6 +183,7 @@ func (o *APIError) UnmarshalJSON(data []byte) (err error) { requiredProperties := []string{ "code", "message", + "status", } allProperties := make(map[string]interface{}) diff --git a/services/vpn/v1alpha1api/model_api_error_detail.go b/services/vpn/v1alpha1api/model_api_error_detail.go index 884816ace..2c694fcc1 100644 --- a/services/vpn/v1alpha1api/model_api_error_detail.go +++ b/services/vpn/v1alpha1api/model_api_error_detail.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ diff --git a/services/vpn/v1alpha1api/model_api_error_response.go b/services/vpn/v1alpha1api/model_api_error_response.go index efa6b5ce4..e73ba6d1a 100644 --- a/services/vpn/v1alpha1api/model_api_error_response.go +++ b/services/vpn/v1alpha1api/model_api_error_response.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ diff --git a/services/vpn/v1alpha1api/model_bgp_gateway_config.go b/services/vpn/v1alpha1api/model_bgp_gateway_config.go index 3ac5bf8b1..481b27cd6 100644 --- a/services/vpn/v1alpha1api/model_bgp_gateway_config.go +++ b/services/vpn/v1alpha1api/model_bgp_gateway_config.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ @@ -19,9 +19,9 @@ var _ MappedNullable = &BGPGatewayConfig{} // BGPGatewayConfig BGP configuration effects all connections. (only for routingMode=BGP_ROUTE_BASED) type BGPGatewayConfig struct { - // ASN for private use (reserved by IANA). Allowed values are 64512-65534 (16-bit range) and 4200000000-4294967294 (32-bit range). + // ASN for private use (reserved by IANA), both 16Bit and 32Bit ranges are valid (RFC 6996). LocalAsn *int32 `json:"localAsn,omitempty"` - // List of routes (IPv4 CIDR). + // A list of IPv4 Prefixes to advertise via BGP. If omitted, the SNA network ranges will be advertised. OverrideAdvertisedRoutes []string `json:"overrideAdvertisedRoutes,omitempty"` } diff --git a/services/vpn/v1alpha1api/model_bgp_status.go b/services/vpn/v1alpha1api/model_bgp_status.go index c16407ec6..3dc4ba71d 100644 --- a/services/vpn/v1alpha1api/model_bgp_status.go +++ b/services/vpn/v1alpha1api/model_bgp_status.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ diff --git a/services/vpn/v1alpha1api/model_bgp_status_peers.go b/services/vpn/v1alpha1api/model_bgp_status_peers.go index cd4909a2e..a614b18c9 100644 --- a/services/vpn/v1alpha1api/model_bgp_status_peers.go +++ b/services/vpn/v1alpha1api/model_bgp_status_peers.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ @@ -21,13 +21,20 @@ var _ MappedNullable = &BGPStatusPeers{} // BGPStatusPeers struct for BGPStatusPeers type BGPStatusPeers struct { - LocalAs float32 `json:"localAs"` - PeerUptime string `json:"peerUptime"` - PfxRcd float32 `json:"pfxRcd"` - PfxSnt float32 `json:"pfxSnt"` - RemoteAs float32 `json:"remoteAs"` - RemoteIP string `json:"remoteIP"` - State string `json:"state"` + // The ASN of the local STACKIT gateway. + LocalAs int32 `json:"localAs"` + // Duration the session has been established + PeerUptime string `json:"peerUptime"` + // Count of prefixes received from the neighbor. + PfxRcd int32 `json:"pfxRcd"` + // Count of prefixes advertised to the neighbor. + PfxSnt int32 `json:"pfxSnt"` + // The ASN of the remote neighbor. + RemoteAs int32 `json:"remoteAs"` + // The IP address of the remote BGP neighbor. + RemoteIP string `json:"remoteIP"` + // The current BGP session state. + State string `json:"state"` } type _BGPStatusPeers BGPStatusPeers @@ -36,7 +43,7 @@ type _BGPStatusPeers BGPStatusPeers // This constructor will assign default values to properties that have it defined, // and makes sure properties required by API are set, but the set of arguments // will change when the set of required properties is changed -func NewBGPStatusPeers(localAs float32, peerUptime string, pfxRcd float32, pfxSnt float32, remoteAs float32, remoteIP string, state string) *BGPStatusPeers { +func NewBGPStatusPeers(localAs int32, peerUptime string, pfxRcd int32, pfxSnt int32, remoteAs int32, remoteIP string, state string) *BGPStatusPeers { this := BGPStatusPeers{} this.LocalAs = localAs this.PeerUptime = peerUptime @@ -57,9 +64,9 @@ func NewBGPStatusPeersWithDefaults() *BGPStatusPeers { } // GetLocalAs returns the LocalAs field value -func (o *BGPStatusPeers) GetLocalAs() float32 { +func (o *BGPStatusPeers) GetLocalAs() int32 { if o == nil { - var ret float32 + var ret int32 return ret } @@ -68,7 +75,7 @@ func (o *BGPStatusPeers) GetLocalAs() float32 { // GetLocalAsOk returns a tuple with the LocalAs field value // and a boolean to check if the value has been set. -func (o *BGPStatusPeers) GetLocalAsOk() (*float32, bool) { +func (o *BGPStatusPeers) GetLocalAsOk() (*int32, bool) { if o == nil { return nil, false } @@ -76,7 +83,7 @@ func (o *BGPStatusPeers) GetLocalAsOk() (*float32, bool) { } // SetLocalAs sets field value -func (o *BGPStatusPeers) SetLocalAs(v float32) { +func (o *BGPStatusPeers) SetLocalAs(v int32) { o.LocalAs = v } @@ -105,9 +112,9 @@ func (o *BGPStatusPeers) SetPeerUptime(v string) { } // GetPfxRcd returns the PfxRcd field value -func (o *BGPStatusPeers) GetPfxRcd() float32 { +func (o *BGPStatusPeers) GetPfxRcd() int32 { if o == nil { - var ret float32 + var ret int32 return ret } @@ -116,7 +123,7 @@ func (o *BGPStatusPeers) GetPfxRcd() float32 { // GetPfxRcdOk returns a tuple with the PfxRcd field value // and a boolean to check if the value has been set. -func (o *BGPStatusPeers) GetPfxRcdOk() (*float32, bool) { +func (o *BGPStatusPeers) GetPfxRcdOk() (*int32, bool) { if o == nil { return nil, false } @@ -124,14 +131,14 @@ func (o *BGPStatusPeers) GetPfxRcdOk() (*float32, bool) { } // SetPfxRcd sets field value -func (o *BGPStatusPeers) SetPfxRcd(v float32) { +func (o *BGPStatusPeers) SetPfxRcd(v int32) { o.PfxRcd = v } // GetPfxSnt returns the PfxSnt field value -func (o *BGPStatusPeers) GetPfxSnt() float32 { +func (o *BGPStatusPeers) GetPfxSnt() int32 { if o == nil { - var ret float32 + var ret int32 return ret } @@ -140,7 +147,7 @@ func (o *BGPStatusPeers) GetPfxSnt() float32 { // GetPfxSntOk returns a tuple with the PfxSnt field value // and a boolean to check if the value has been set. -func (o *BGPStatusPeers) GetPfxSntOk() (*float32, bool) { +func (o *BGPStatusPeers) GetPfxSntOk() (*int32, bool) { if o == nil { return nil, false } @@ -148,14 +155,14 @@ func (o *BGPStatusPeers) GetPfxSntOk() (*float32, bool) { } // SetPfxSnt sets field value -func (o *BGPStatusPeers) SetPfxSnt(v float32) { +func (o *BGPStatusPeers) SetPfxSnt(v int32) { o.PfxSnt = v } // GetRemoteAs returns the RemoteAs field value -func (o *BGPStatusPeers) GetRemoteAs() float32 { +func (o *BGPStatusPeers) GetRemoteAs() int32 { if o == nil { - var ret float32 + var ret int32 return ret } @@ -164,7 +171,7 @@ func (o *BGPStatusPeers) GetRemoteAs() float32 { // GetRemoteAsOk returns a tuple with the RemoteAs field value // and a boolean to check if the value has been set. -func (o *BGPStatusPeers) GetRemoteAsOk() (*float32, bool) { +func (o *BGPStatusPeers) GetRemoteAsOk() (*int32, bool) { if o == nil { return nil, false } @@ -172,7 +179,7 @@ func (o *BGPStatusPeers) GetRemoteAsOk() (*float32, bool) { } // SetRemoteAs sets field value -func (o *BGPStatusPeers) SetRemoteAs(v float32) { +func (o *BGPStatusPeers) SetRemoteAs(v int32) { o.RemoteAs = v } diff --git a/services/vpn/v1alpha1api/model_bgp_status_routes.go b/services/vpn/v1alpha1api/model_bgp_status_routes.go index a4a0ff8a1..4fea094e4 100644 --- a/services/vpn/v1alpha1api/model_bgp_status_routes.go +++ b/services/vpn/v1alpha1api/model_bgp_status_routes.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ @@ -21,11 +21,14 @@ var _ MappedNullable = &BGPStatusRoutes{} // BGPStatusRoutes struct for BGPStatusRoutes type BGPStatusRoutes struct { - Network string `json:"network"` - Origin string `json:"origin"` - Path string `json:"path"` - PeerId string `json:"peerId"` - Weight float32 `json:"weight"` + // The destination network + Network string `json:"network"` + Origin string `json:"origin"` + // The AS-PATH + Path string `json:"path"` + // BGP Router ID of the neighbor that advertised this route + PeerId string `json:"peerId"` + Weight int32 `json:"weight"` } type _BGPStatusRoutes BGPStatusRoutes @@ -34,7 +37,7 @@ type _BGPStatusRoutes BGPStatusRoutes // This constructor will assign default values to properties that have it defined, // and makes sure properties required by API are set, but the set of arguments // will change when the set of required properties is changed -func NewBGPStatusRoutes(network string, origin string, path string, peerId string, weight float32) *BGPStatusRoutes { +func NewBGPStatusRoutes(network string, origin string, path string, peerId string, weight int32) *BGPStatusRoutes { this := BGPStatusRoutes{} this.Network = network this.Origin = origin @@ -149,9 +152,9 @@ func (o *BGPStatusRoutes) SetPeerId(v string) { } // GetWeight returns the Weight field value -func (o *BGPStatusRoutes) GetWeight() float32 { +func (o *BGPStatusRoutes) GetWeight() int32 { if o == nil { - var ret float32 + var ret int32 return ret } @@ -160,7 +163,7 @@ func (o *BGPStatusRoutes) GetWeight() float32 { // GetWeightOk returns a tuple with the Weight field value // and a boolean to check if the value has been set. -func (o *BGPStatusRoutes) GetWeightOk() (*float32, bool) { +func (o *BGPStatusRoutes) GetWeightOk() (*int32, bool) { if o == nil { return nil, false } @@ -168,7 +171,7 @@ func (o *BGPStatusRoutes) GetWeightOk() (*float32, bool) { } // SetWeight sets field value -func (o *BGPStatusRoutes) SetWeight(v float32) { +func (o *BGPStatusRoutes) SetWeight(v int32) { o.Weight = v } diff --git a/services/vpn/v1alpha1api/model_bgp_tunnel_config.go b/services/vpn/v1alpha1api/model_bgp_tunnel_config.go index 40b8cda2d..1f23c3e14 100644 --- a/services/vpn/v1alpha1api/model_bgp_tunnel_config.go +++ b/services/vpn/v1alpha1api/model_bgp_tunnel_config.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ @@ -21,7 +21,7 @@ var _ MappedNullable = &BGPTunnelConfig{} // BGPTunnelConfig struct for BGPTunnelConfig type BGPTunnelConfig struct { - // ASN for private use (reserved by IANA). Allowed values are 64512-65534 (16-bit range) and 4200000000-4294967294 (32-bit range). + // ASN for private use (reserved by IANA), both 16Bit and 32Bit ranges are valid (RFC 6996). RemoteAsn int32 `json:"remoteAsn"` } diff --git a/services/vpn/v1alpha1api/model_connection_list.go b/services/vpn/v1alpha1api/model_connection_list.go index 4547ad37a..a7fcfd6ed 100644 --- a/services/vpn/v1alpha1api/model_connection_list.go +++ b/services/vpn/v1alpha1api/model_connection_list.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ @@ -21,7 +21,7 @@ var _ MappedNullable = &ConnectionList{} // ConnectionList struct for ConnectionList type ConnectionList struct { - Connections []Connection `json:"connections"` + Connections []ConnectionResponse `json:"connections"` } type _ConnectionList ConnectionList @@ -30,7 +30,7 @@ type _ConnectionList ConnectionList // This constructor will assign default values to properties that have it defined, // and makes sure properties required by API are set, but the set of arguments // will change when the set of required properties is changed -func NewConnectionList(connections []Connection) *ConnectionList { +func NewConnectionList(connections []ConnectionResponse) *ConnectionList { this := ConnectionList{} this.Connections = connections return &this @@ -45,9 +45,9 @@ func NewConnectionListWithDefaults() *ConnectionList { } // GetConnections returns the Connections field value -func (o *ConnectionList) GetConnections() []Connection { +func (o *ConnectionList) GetConnections() []ConnectionResponse { if o == nil { - var ret []Connection + var ret []ConnectionResponse return ret } @@ -56,7 +56,7 @@ func (o *ConnectionList) GetConnections() []Connection { // GetConnectionsOk returns a tuple with the Connections field value // and a boolean to check if the value has been set. -func (o *ConnectionList) GetConnectionsOk() ([]Connection, bool) { +func (o *ConnectionList) GetConnectionsOk() ([]ConnectionResponse, bool) { if o == nil { return nil, false } @@ -64,7 +64,7 @@ func (o *ConnectionList) GetConnectionsOk() ([]Connection, bool) { } // SetConnections sets field value -func (o *ConnectionList) SetConnections(v []Connection) { +func (o *ConnectionList) SetConnections(v []ConnectionResponse) { o.Connections = v } diff --git a/services/vpn/v1alpha1api/model_connection.go b/services/vpn/v1alpha1api/model_connection_response.go similarity index 56% rename from services/vpn/v1alpha1api/model_connection.go rename to services/vpn/v1alpha1api/model_connection_response.go index 83143f3b3..41159ac4b 100644 --- a/services/vpn/v1alpha1api/model_connection.go +++ b/services/vpn/v1alpha1api/model_connection_response.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ @@ -16,50 +16,77 @@ import ( "fmt" ) -// checks if the Connection type satisfies the MappedNullable interface at compile time -var _ MappedNullable = &Connection{} +// checks if the ConnectionResponse type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ConnectionResponse{} -// Connection struct for Connection -type Connection struct { +// ConnectionResponse struct for ConnectionResponse +type ConnectionResponse struct { + // A user-friendly name for the connection. + DisplayName string `json:"displayName" validate:"regexp=^[a-zA-Z0-9]([a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?$"` // This flag decides whether this connection should be enabled or disabled Enabled *bool `json:"enabled,omitempty"` - // Map of custom labels. Key and values must be a string with max 63 chars, start/end with alphanumeric. The key of a label follows the same rules as the LabelValue except that it cannot be empty. + // UUID of the Gateway instance. + Id *string `json:"id,omitempty"` + // Map of custom labels. Key and values must be a string with max 63 chars, start/end with alphanumeric. The key of a label follows the same rules as the `LabelValue` except that it cannot be empty. Labels *map[string]string `json:"labels,omitempty"` // Optional. Defaults to 0.0.0.0/0 for Route-based VPN configurations. Mandatory for Policy-based. LocalSubnets []string `json:"localSubnets,omitempty"` - // The name of the connection. Maximum 20 characters (only alphanumeric and hyphens allowed). The name bust be unique within the parent Gateway. Currently renaming is not possible therefore deleting and re-creating the connection is necessary. - Name string `json:"name" validate:"regexp=^[a-z0-9]([a-z0-9-]{0,18}[a-z0-9])?$"` // Optional. Defaults to 0.0.0.0/0 for Route-based VPN configurations. Mandatory for Policy-based. - RemoteSubnets []string `json:"remoteSubnets,omitempty"` - StaticRoutes []string `json:"staticRoutes,omitempty"` - Tunnel1 TunnelConfiguration `json:"tunnel1"` - Tunnel2 TunnelConfiguration `json:"tunnel2"` + RemoteSubnets []string `json:"remoteSubnets,omitempty"` + // Optional. Use this for route-based VPN. + StaticRoutes []string `json:"staticRoutes,omitempty"` + Tunnel1 TunnelConfiguration `json:"tunnel1"` + Tunnel2 TunnelConfiguration `json:"tunnel2"` } -type _Connection Connection +type _ConnectionResponse ConnectionResponse -// NewConnection instantiates a new Connection object +// NewConnectionResponse instantiates a new ConnectionResponse object // This constructor will assign default values to properties that have it defined, // and makes sure properties required by API are set, but the set of arguments // will change when the set of required properties is changed -func NewConnection(name string, tunnel1 TunnelConfiguration, tunnel2 TunnelConfiguration) *Connection { - this := Connection{} - this.Name = name +func NewConnectionResponse(displayName string, tunnel1 TunnelConfiguration, tunnel2 TunnelConfiguration) *ConnectionResponse { + this := ConnectionResponse{} + this.DisplayName = displayName this.Tunnel1 = tunnel1 this.Tunnel2 = tunnel2 return &this } -// NewConnectionWithDefaults instantiates a new Connection object +// NewConnectionResponseWithDefaults instantiates a new ConnectionResponse object // This constructor will only assign default values to properties that have it defined, // but it doesn't guarantee that properties required by API are set -func NewConnectionWithDefaults() *Connection { - this := Connection{} +func NewConnectionResponseWithDefaults() *ConnectionResponse { + this := ConnectionResponse{} return &this } +// GetDisplayName returns the DisplayName field value +func (o *ConnectionResponse) GetDisplayName() string { + if o == nil { + var ret string + return ret + } + + return o.DisplayName +} + +// GetDisplayNameOk returns a tuple with the DisplayName field value +// and a boolean to check if the value has been set. +func (o *ConnectionResponse) GetDisplayNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.DisplayName, true +} + +// SetDisplayName sets field value +func (o *ConnectionResponse) SetDisplayName(v string) { + o.DisplayName = v +} + // GetEnabled returns the Enabled field value if set, zero value otherwise. -func (o *Connection) GetEnabled() bool { +func (o *ConnectionResponse) GetEnabled() bool { if o == nil || IsNil(o.Enabled) { var ret bool return ret @@ -69,7 +96,7 @@ func (o *Connection) GetEnabled() bool { // GetEnabledOk returns a tuple with the Enabled field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Connection) GetEnabledOk() (*bool, bool) { +func (o *ConnectionResponse) GetEnabledOk() (*bool, bool) { if o == nil || IsNil(o.Enabled) { return nil, false } @@ -77,7 +104,7 @@ func (o *Connection) GetEnabledOk() (*bool, bool) { } // HasEnabled returns a boolean if a field has been set. -func (o *Connection) HasEnabled() bool { +func (o *ConnectionResponse) HasEnabled() bool { if o != nil && !IsNil(o.Enabled) { return true } @@ -86,12 +113,44 @@ func (o *Connection) HasEnabled() bool { } // SetEnabled gets a reference to the given bool and assigns it to the Enabled field. -func (o *Connection) SetEnabled(v bool) { +func (o *ConnectionResponse) SetEnabled(v bool) { o.Enabled = &v } +// GetId returns the Id field value if set, zero value otherwise. +func (o *ConnectionResponse) GetId() string { + if o == nil || IsNil(o.Id) { + var ret string + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ConnectionResponse) GetIdOk() (*string, bool) { + if o == nil || IsNil(o.Id) { + return nil, false + } + return o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *ConnectionResponse) HasId() bool { + if o != nil && !IsNil(o.Id) { + return true + } + + return false +} + +// SetId gets a reference to the given string and assigns it to the Id field. +func (o *ConnectionResponse) SetId(v string) { + o.Id = &v +} + // GetLabels returns the Labels field value if set, zero value otherwise. -func (o *Connection) GetLabels() map[string]string { +func (o *ConnectionResponse) GetLabels() map[string]string { if o == nil || IsNil(o.Labels) { var ret map[string]string return ret @@ -101,7 +160,7 @@ func (o *Connection) GetLabels() map[string]string { // GetLabelsOk returns a tuple with the Labels field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Connection) GetLabelsOk() (*map[string]string, bool) { +func (o *ConnectionResponse) GetLabelsOk() (*map[string]string, bool) { if o == nil || IsNil(o.Labels) { return nil, false } @@ -109,7 +168,7 @@ func (o *Connection) GetLabelsOk() (*map[string]string, bool) { } // HasLabels returns a boolean if a field has been set. -func (o *Connection) HasLabels() bool { +func (o *ConnectionResponse) HasLabels() bool { if o != nil && !IsNil(o.Labels) { return true } @@ -118,12 +177,12 @@ func (o *Connection) HasLabels() bool { } // SetLabels gets a reference to the given map[string]string and assigns it to the Labels field. -func (o *Connection) SetLabels(v map[string]string) { +func (o *ConnectionResponse) SetLabels(v map[string]string) { o.Labels = &v } // GetLocalSubnets returns the LocalSubnets field value if set, zero value otherwise. -func (o *Connection) GetLocalSubnets() []string { +func (o *ConnectionResponse) GetLocalSubnets() []string { if o == nil || IsNil(o.LocalSubnets) { var ret []string return ret @@ -133,7 +192,7 @@ func (o *Connection) GetLocalSubnets() []string { // GetLocalSubnetsOk returns a tuple with the LocalSubnets field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Connection) GetLocalSubnetsOk() ([]string, bool) { +func (o *ConnectionResponse) GetLocalSubnetsOk() ([]string, bool) { if o == nil || IsNil(o.LocalSubnets) { return nil, false } @@ -141,7 +200,7 @@ func (o *Connection) GetLocalSubnetsOk() ([]string, bool) { } // HasLocalSubnets returns a boolean if a field has been set. -func (o *Connection) HasLocalSubnets() bool { +func (o *ConnectionResponse) HasLocalSubnets() bool { if o != nil && !IsNil(o.LocalSubnets) { return true } @@ -150,36 +209,12 @@ func (o *Connection) HasLocalSubnets() bool { } // SetLocalSubnets gets a reference to the given []string and assigns it to the LocalSubnets field. -func (o *Connection) SetLocalSubnets(v []string) { +func (o *ConnectionResponse) SetLocalSubnets(v []string) { o.LocalSubnets = v } -// GetName returns the Name field value -func (o *Connection) GetName() string { - if o == nil { - var ret string - return ret - } - - return o.Name -} - -// GetNameOk returns a tuple with the Name field value -// and a boolean to check if the value has been set. -func (o *Connection) GetNameOk() (*string, bool) { - if o == nil { - return nil, false - } - return &o.Name, true -} - -// SetName sets field value -func (o *Connection) SetName(v string) { - o.Name = v -} - // GetRemoteSubnets returns the RemoteSubnets field value if set, zero value otherwise. -func (o *Connection) GetRemoteSubnets() []string { +func (o *ConnectionResponse) GetRemoteSubnets() []string { if o == nil || IsNil(o.RemoteSubnets) { var ret []string return ret @@ -189,7 +224,7 @@ func (o *Connection) GetRemoteSubnets() []string { // GetRemoteSubnetsOk returns a tuple with the RemoteSubnets field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Connection) GetRemoteSubnetsOk() ([]string, bool) { +func (o *ConnectionResponse) GetRemoteSubnetsOk() ([]string, bool) { if o == nil || IsNil(o.RemoteSubnets) { return nil, false } @@ -197,7 +232,7 @@ func (o *Connection) GetRemoteSubnetsOk() ([]string, bool) { } // HasRemoteSubnets returns a boolean if a field has been set. -func (o *Connection) HasRemoteSubnets() bool { +func (o *ConnectionResponse) HasRemoteSubnets() bool { if o != nil && !IsNil(o.RemoteSubnets) { return true } @@ -206,12 +241,12 @@ func (o *Connection) HasRemoteSubnets() bool { } // SetRemoteSubnets gets a reference to the given []string and assigns it to the RemoteSubnets field. -func (o *Connection) SetRemoteSubnets(v []string) { +func (o *ConnectionResponse) SetRemoteSubnets(v []string) { o.RemoteSubnets = v } // GetStaticRoutes returns the StaticRoutes field value if set, zero value otherwise. -func (o *Connection) GetStaticRoutes() []string { +func (o *ConnectionResponse) GetStaticRoutes() []string { if o == nil || IsNil(o.StaticRoutes) { var ret []string return ret @@ -221,7 +256,7 @@ func (o *Connection) GetStaticRoutes() []string { // GetStaticRoutesOk returns a tuple with the StaticRoutes field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Connection) GetStaticRoutesOk() ([]string, bool) { +func (o *ConnectionResponse) GetStaticRoutesOk() ([]string, bool) { if o == nil || IsNil(o.StaticRoutes) { return nil, false } @@ -229,7 +264,7 @@ func (o *Connection) GetStaticRoutesOk() ([]string, bool) { } // HasStaticRoutes returns a boolean if a field has been set. -func (o *Connection) HasStaticRoutes() bool { +func (o *ConnectionResponse) HasStaticRoutes() bool { if o != nil && !IsNil(o.StaticRoutes) { return true } @@ -238,12 +273,12 @@ func (o *Connection) HasStaticRoutes() bool { } // SetStaticRoutes gets a reference to the given []string and assigns it to the StaticRoutes field. -func (o *Connection) SetStaticRoutes(v []string) { +func (o *ConnectionResponse) SetStaticRoutes(v []string) { o.StaticRoutes = v } // GetTunnel1 returns the Tunnel1 field value -func (o *Connection) GetTunnel1() TunnelConfiguration { +func (o *ConnectionResponse) GetTunnel1() TunnelConfiguration { if o == nil { var ret TunnelConfiguration return ret @@ -254,7 +289,7 @@ func (o *Connection) GetTunnel1() TunnelConfiguration { // GetTunnel1Ok returns a tuple with the Tunnel1 field value // and a boolean to check if the value has been set. -func (o *Connection) GetTunnel1Ok() (*TunnelConfiguration, bool) { +func (o *ConnectionResponse) GetTunnel1Ok() (*TunnelConfiguration, bool) { if o == nil { return nil, false } @@ -262,12 +297,12 @@ func (o *Connection) GetTunnel1Ok() (*TunnelConfiguration, bool) { } // SetTunnel1 sets field value -func (o *Connection) SetTunnel1(v TunnelConfiguration) { +func (o *ConnectionResponse) SetTunnel1(v TunnelConfiguration) { o.Tunnel1 = v } // GetTunnel2 returns the Tunnel2 field value -func (o *Connection) GetTunnel2() TunnelConfiguration { +func (o *ConnectionResponse) GetTunnel2() TunnelConfiguration { if o == nil { var ret TunnelConfiguration return ret @@ -278,7 +313,7 @@ func (o *Connection) GetTunnel2() TunnelConfiguration { // GetTunnel2Ok returns a tuple with the Tunnel2 field value // and a boolean to check if the value has been set. -func (o *Connection) GetTunnel2Ok() (*TunnelConfiguration, bool) { +func (o *ConnectionResponse) GetTunnel2Ok() (*TunnelConfiguration, bool) { if o == nil { return nil, false } @@ -286,11 +321,11 @@ func (o *Connection) GetTunnel2Ok() (*TunnelConfiguration, bool) { } // SetTunnel2 sets field value -func (o *Connection) SetTunnel2(v TunnelConfiguration) { +func (o *ConnectionResponse) SetTunnel2(v TunnelConfiguration) { o.Tunnel2 = v } -func (o Connection) MarshalJSON() ([]byte, error) { +func (o ConnectionResponse) MarshalJSON() ([]byte, error) { toSerialize, err := o.ToMap() if err != nil { return []byte{}, err @@ -298,18 +333,21 @@ func (o Connection) MarshalJSON() ([]byte, error) { return json.Marshal(toSerialize) } -func (o Connection) ToMap() (map[string]interface{}, error) { +func (o ConnectionResponse) ToMap() (map[string]interface{}, error) { toSerialize := map[string]interface{}{} + toSerialize["displayName"] = o.DisplayName if !IsNil(o.Enabled) { toSerialize["enabled"] = o.Enabled } + if !IsNil(o.Id) { + toSerialize["id"] = o.Id + } if !IsNil(o.Labels) { toSerialize["labels"] = o.Labels } if !IsNil(o.LocalSubnets) { toSerialize["localSubnets"] = o.LocalSubnets } - toSerialize["name"] = o.Name if !IsNil(o.RemoteSubnets) { toSerialize["remoteSubnets"] = o.RemoteSubnets } @@ -321,12 +359,12 @@ func (o Connection) ToMap() (map[string]interface{}, error) { return toSerialize, nil } -func (o *Connection) UnmarshalJSON(data []byte) (err error) { +func (o *ConnectionResponse) UnmarshalJSON(data []byte) (err error) { // This validates that all required properties are included in the JSON object // by unmarshalling the object into a generic map with string keys and checking // that every required field exists as a key in the generic map. requiredProperties := []string{ - "name", + "displayName", "tunnel1", "tunnel2", } @@ -345,53 +383,53 @@ func (o *Connection) UnmarshalJSON(data []byte) (err error) { } } - varConnection := _Connection{} + varConnectionResponse := _ConnectionResponse{} decoder := json.NewDecoder(bytes.NewReader(data)) decoder.DisallowUnknownFields() - err = decoder.Decode(&varConnection) + err = decoder.Decode(&varConnectionResponse) if err != nil { return err } - *o = Connection(varConnection) + *o = ConnectionResponse(varConnectionResponse) return err } -type NullableConnection struct { - value *Connection +type NullableConnectionResponse struct { + value *ConnectionResponse isSet bool } -func (v NullableConnection) Get() *Connection { +func (v NullableConnectionResponse) Get() *ConnectionResponse { return v.value } -func (v *NullableConnection) Set(val *Connection) { +func (v *NullableConnectionResponse) Set(val *ConnectionResponse) { v.value = val v.isSet = true } -func (v NullableConnection) IsSet() bool { +func (v NullableConnectionResponse) IsSet() bool { return v.isSet } -func (v *NullableConnection) Unset() { +func (v *NullableConnectionResponse) Unset() { v.value = nil v.isSet = false } -func NewNullableConnection(val *Connection) *NullableConnection { - return &NullableConnection{value: val, isSet: true} +func NewNullableConnectionResponse(val *ConnectionResponse) *NullableConnectionResponse { + return &NullableConnectionResponse{value: val, isSet: true} } -func (v NullableConnection) MarshalJSON() ([]byte, error) { +func (v NullableConnectionResponse) MarshalJSON() ([]byte, error) { return json.Marshal(v.value) } -func (v *NullableConnection) UnmarshalJSON(src []byte) error { +func (v *NullableConnectionResponse) UnmarshalJSON(src []byte) error { v.isSet = true return json.Unmarshal(src, &v.value) } diff --git a/services/vpn/v1alpha1api/model_connection_status_response.go b/services/vpn/v1alpha1api/model_connection_status_response.go index e3df68ee9..5fe836561 100644 --- a/services/vpn/v1alpha1api/model_connection_status_response.go +++ b/services/vpn/v1alpha1api/model_connection_status_response.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ @@ -19,9 +19,11 @@ var _ MappedNullable = &ConnectionStatusResponse{} // ConnectionStatusResponse struct for ConnectionStatusResponse type ConnectionStatusResponse struct { - Enabled *bool `json:"enabled,omitempty"` // The name of the connection. - Name *string `json:"name,omitempty"` + DisplayName *string `json:"displayName,omitempty"` + Enabled *bool `json:"enabled,omitempty"` + // UUID of the connection. + Id *string `json:"id,omitempty"` Tunnels []TunnelStatus `json:"tunnels,omitempty"` } @@ -42,6 +44,38 @@ func NewConnectionStatusResponseWithDefaults() *ConnectionStatusResponse { return &this } +// GetDisplayName returns the DisplayName field value if set, zero value otherwise. +func (o *ConnectionStatusResponse) GetDisplayName() string { + if o == nil || IsNil(o.DisplayName) { + var ret string + return ret + } + return *o.DisplayName +} + +// GetDisplayNameOk returns a tuple with the DisplayName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ConnectionStatusResponse) GetDisplayNameOk() (*string, bool) { + if o == nil || IsNil(o.DisplayName) { + return nil, false + } + return o.DisplayName, true +} + +// HasDisplayName returns a boolean if a field has been set. +func (o *ConnectionStatusResponse) HasDisplayName() bool { + if o != nil && !IsNil(o.DisplayName) { + return true + } + + return false +} + +// SetDisplayName gets a reference to the given string and assigns it to the DisplayName field. +func (o *ConnectionStatusResponse) SetDisplayName(v string) { + o.DisplayName = &v +} + // GetEnabled returns the Enabled field value if set, zero value otherwise. func (o *ConnectionStatusResponse) GetEnabled() bool { if o == nil || IsNil(o.Enabled) { @@ -74,36 +108,36 @@ func (o *ConnectionStatusResponse) SetEnabled(v bool) { o.Enabled = &v } -// GetName returns the Name field value if set, zero value otherwise. -func (o *ConnectionStatusResponse) GetName() string { - if o == nil || IsNil(o.Name) { +// GetId returns the Id field value if set, zero value otherwise. +func (o *ConnectionStatusResponse) GetId() string { + if o == nil || IsNil(o.Id) { var ret string return ret } - return *o.Name + return *o.Id } -// GetNameOk returns a tuple with the Name field value if set, nil otherwise +// GetIdOk returns a tuple with the Id field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *ConnectionStatusResponse) GetNameOk() (*string, bool) { - if o == nil || IsNil(o.Name) { +func (o *ConnectionStatusResponse) GetIdOk() (*string, bool) { + if o == nil || IsNil(o.Id) { return nil, false } - return o.Name, true + return o.Id, true } -// HasName returns a boolean if a field has been set. -func (o *ConnectionStatusResponse) HasName() bool { - if o != nil && !IsNil(o.Name) { +// HasId returns a boolean if a field has been set. +func (o *ConnectionStatusResponse) HasId() bool { + if o != nil && !IsNil(o.Id) { return true } return false } -// SetName gets a reference to the given string and assigns it to the Name field. -func (o *ConnectionStatusResponse) SetName(v string) { - o.Name = &v +// SetId gets a reference to the given string and assigns it to the Id field. +func (o *ConnectionStatusResponse) SetId(v string) { + o.Id = &v } // GetTunnels returns the Tunnels field value if set, zero value otherwise. @@ -148,11 +182,14 @@ func (o ConnectionStatusResponse) MarshalJSON() ([]byte, error) { func (o ConnectionStatusResponse) ToMap() (map[string]interface{}, error) { toSerialize := map[string]interface{}{} + if !IsNil(o.DisplayName) { + toSerialize["displayName"] = o.DisplayName + } if !IsNil(o.Enabled) { toSerialize["enabled"] = o.Enabled } - if !IsNil(o.Name) { - toSerialize["name"] = o.Name + if !IsNil(o.Id) { + toSerialize["id"] = o.Id } if !IsNil(o.Tunnels) { toSerialize["tunnels"] = o.Tunnels diff --git a/services/vpn/v1alpha1api/model_create_gateway_connection_payload.go b/services/vpn/v1alpha1api/model_create_gateway_connection_payload.go index 12a9a8eae..078849b60 100644 --- a/services/vpn/v1alpha1api/model_create_gateway_connection_payload.go +++ b/services/vpn/v1alpha1api/model_create_gateway_connection_payload.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ @@ -21,19 +21,18 @@ var _ MappedNullable = &CreateGatewayConnectionPayload{} // CreateGatewayConnectionPayload struct for CreateGatewayConnectionPayload type CreateGatewayConnectionPayload struct { + // A user-friendly name for the connection. + DisplayName string `json:"displayName" validate:"regexp=^[a-zA-Z0-9]([a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?$"` // This flag decides whether this connection should be enabled or disabled Enabled *bool `json:"enabled,omitempty"` - // Map of custom labels. Key and values must be a string with max 63 chars, start/end with alphanumeric. The key of a label follows the same rules as the LabelValue except that it cannot be empty. - Labels *map[string]string `json:"labels,omitempty"` // Optional. Defaults to 0.0.0.0/0 for Route-based VPN configurations. Mandatory for Policy-based. LocalSubnets []string `json:"localSubnets,omitempty"` - // The name of the connection. Maximum 20 characters (only alphanumeric and hyphens allowed). The name bust be unique within the parent Gateway. Currently renaming is not possible therefore deleting and re-creating the connection is necessary. - Name string `json:"name" validate:"regexp=^[a-z0-9]([a-z0-9-]{0,18}[a-z0-9])?$"` // Optional. Defaults to 0.0.0.0/0 for Route-based VPN configurations. Mandatory for Policy-based. - RemoteSubnets []string `json:"remoteSubnets,omitempty"` - StaticRoutes []string `json:"staticRoutes,omitempty"` - Tunnel1 TunnelConfiguration `json:"tunnel1"` - Tunnel2 TunnelConfiguration `json:"tunnel2"` + RemoteSubnets []string `json:"remoteSubnets,omitempty"` + // Optional. Use this for route-based VPN. + StaticRoutes []string `json:"staticRoutes,omitempty"` + Tunnel1 TunnelConfiguration `json:"tunnel1"` + Tunnel2 TunnelConfiguration `json:"tunnel2"` } type _CreateGatewayConnectionPayload CreateGatewayConnectionPayload @@ -42,9 +41,9 @@ type _CreateGatewayConnectionPayload CreateGatewayConnectionPayload // This constructor will assign default values to properties that have it defined, // and makes sure properties required by API are set, but the set of arguments // will change when the set of required properties is changed -func NewCreateGatewayConnectionPayload(name string, tunnel1 TunnelConfiguration, tunnel2 TunnelConfiguration) *CreateGatewayConnectionPayload { +func NewCreateGatewayConnectionPayload(displayName string, tunnel1 TunnelConfiguration, tunnel2 TunnelConfiguration) *CreateGatewayConnectionPayload { this := CreateGatewayConnectionPayload{} - this.Name = name + this.DisplayName = displayName this.Tunnel1 = tunnel1 this.Tunnel2 = tunnel2 return &this @@ -58,6 +57,30 @@ func NewCreateGatewayConnectionPayloadWithDefaults() *CreateGatewayConnectionPay return &this } +// GetDisplayName returns the DisplayName field value +func (o *CreateGatewayConnectionPayload) GetDisplayName() string { + if o == nil { + var ret string + return ret + } + + return o.DisplayName +} + +// GetDisplayNameOk returns a tuple with the DisplayName field value +// and a boolean to check if the value has been set. +func (o *CreateGatewayConnectionPayload) GetDisplayNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.DisplayName, true +} + +// SetDisplayName sets field value +func (o *CreateGatewayConnectionPayload) SetDisplayName(v string) { + o.DisplayName = v +} + // GetEnabled returns the Enabled field value if set, zero value otherwise. func (o *CreateGatewayConnectionPayload) GetEnabled() bool { if o == nil || IsNil(o.Enabled) { @@ -90,38 +113,6 @@ func (o *CreateGatewayConnectionPayload) SetEnabled(v bool) { o.Enabled = &v } -// GetLabels returns the Labels field value if set, zero value otherwise. -func (o *CreateGatewayConnectionPayload) GetLabels() map[string]string { - if o == nil || IsNil(o.Labels) { - var ret map[string]string - return ret - } - return *o.Labels -} - -// GetLabelsOk returns a tuple with the Labels field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *CreateGatewayConnectionPayload) GetLabelsOk() (*map[string]string, bool) { - if o == nil || IsNil(o.Labels) { - return nil, false - } - return o.Labels, true -} - -// HasLabels returns a boolean if a field has been set. -func (o *CreateGatewayConnectionPayload) HasLabels() bool { - if o != nil && !IsNil(o.Labels) { - return true - } - - return false -} - -// SetLabels gets a reference to the given map[string]string and assigns it to the Labels field. -func (o *CreateGatewayConnectionPayload) SetLabels(v map[string]string) { - o.Labels = &v -} - // GetLocalSubnets returns the LocalSubnets field value if set, zero value otherwise. func (o *CreateGatewayConnectionPayload) GetLocalSubnets() []string { if o == nil || IsNil(o.LocalSubnets) { @@ -154,30 +145,6 @@ func (o *CreateGatewayConnectionPayload) SetLocalSubnets(v []string) { o.LocalSubnets = v } -// GetName returns the Name field value -func (o *CreateGatewayConnectionPayload) GetName() string { - if o == nil { - var ret string - return ret - } - - return o.Name -} - -// GetNameOk returns a tuple with the Name field value -// and a boolean to check if the value has been set. -func (o *CreateGatewayConnectionPayload) GetNameOk() (*string, bool) { - if o == nil { - return nil, false - } - return &o.Name, true -} - -// SetName sets field value -func (o *CreateGatewayConnectionPayload) SetName(v string) { - o.Name = v -} - // GetRemoteSubnets returns the RemoteSubnets field value if set, zero value otherwise. func (o *CreateGatewayConnectionPayload) GetRemoteSubnets() []string { if o == nil || IsNil(o.RemoteSubnets) { @@ -300,16 +267,13 @@ func (o CreateGatewayConnectionPayload) MarshalJSON() ([]byte, error) { func (o CreateGatewayConnectionPayload) ToMap() (map[string]interface{}, error) { toSerialize := map[string]interface{}{} + toSerialize["displayName"] = o.DisplayName if !IsNil(o.Enabled) { toSerialize["enabled"] = o.Enabled } - if !IsNil(o.Labels) { - toSerialize["labels"] = o.Labels - } if !IsNil(o.LocalSubnets) { toSerialize["localSubnets"] = o.LocalSubnets } - toSerialize["name"] = o.Name if !IsNil(o.RemoteSubnets) { toSerialize["remoteSubnets"] = o.RemoteSubnets } @@ -326,7 +290,7 @@ func (o *CreateGatewayConnectionPayload) UnmarshalJSON(data []byte) (err error) // by unmarshalling the object into a generic map with string keys and checking // that every required field exists as a key in the generic map. requiredProperties := []string{ - "name", + "displayName", "tunnel1", "tunnel2", } diff --git a/services/vpn/v1alpha1api/model_create_vpn_gateway_payload.go b/services/vpn/v1alpha1api/model_create_vpn_gateway_payload.go index e7aa22d1e..d0a28c6b0 100644 --- a/services/vpn/v1alpha1api/model_create_vpn_gateway_payload.go +++ b/services/vpn/v1alpha1api/model_create_vpn_gateway_payload.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ @@ -23,11 +23,11 @@ var _ MappedNullable = &CreateVPNGatewayPayload{} type CreateVPNGatewayPayload struct { AvailabilityZones CreateVPNGatewayPayloadAvailabilityZones `json:"availabilityZones"` Bgp *BGPGatewayConfig `json:"bgp,omitempty"` - // Map of custom labels. Key and values must be a string with max 63 chars, start/end with alphanumeric. The key of a label follows the same rules as the LabelValue except that it cannot be empty. + // A user-friendly name for the VPN gateway. + DisplayName string `json:"displayName" validate:"regexp=^[a-zA-Z0-9]([a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?$"` + // Map of custom labels. Key and values must be a string with max 63 chars, start/end with alphanumeric. The key of a label follows the same rules as the `LabelValue` except that it cannot be empty. Labels *map[string]string `json:"labels,omitempty"` - // The name of the VPN gateway. Maximum 20 characters (only alphanumeric and hyphens allowed). Not changeable after creation. - Name string `json:"name" validate:"regexp=^[a-z0-9]([a-z0-9-]{0,18}[a-z0-9])?$"` - // Service Plan to configure the limits of the VPN. Currently supported plans are p50, p100, p200. This list can change in the future where plan ids will be removed and new plans by added. That is the reason this is not an enum. + // The service plan identifier. PlanId string `json:"planId"` RoutingType RoutingType `json:"routingType"` } @@ -38,10 +38,10 @@ type _CreateVPNGatewayPayload CreateVPNGatewayPayload // This constructor will assign default values to properties that have it defined, // and makes sure properties required by API are set, but the set of arguments // will change when the set of required properties is changed -func NewCreateVPNGatewayPayload(availabilityZones CreateVPNGatewayPayloadAvailabilityZones, name string, planId string, routingType RoutingType) *CreateVPNGatewayPayload { +func NewCreateVPNGatewayPayload(availabilityZones CreateVPNGatewayPayloadAvailabilityZones, displayName string, planId string, routingType RoutingType) *CreateVPNGatewayPayload { this := CreateVPNGatewayPayload{} this.AvailabilityZones = availabilityZones - this.Name = name + this.DisplayName = displayName this.PlanId = planId this.RoutingType = routingType return &this @@ -111,6 +111,30 @@ func (o *CreateVPNGatewayPayload) SetBgp(v BGPGatewayConfig) { o.Bgp = &v } +// GetDisplayName returns the DisplayName field value +func (o *CreateVPNGatewayPayload) GetDisplayName() string { + if o == nil { + var ret string + return ret + } + + return o.DisplayName +} + +// GetDisplayNameOk returns a tuple with the DisplayName field value +// and a boolean to check if the value has been set. +func (o *CreateVPNGatewayPayload) GetDisplayNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.DisplayName, true +} + +// SetDisplayName sets field value +func (o *CreateVPNGatewayPayload) SetDisplayName(v string) { + o.DisplayName = v +} + // GetLabels returns the Labels field value if set, zero value otherwise. func (o *CreateVPNGatewayPayload) GetLabels() map[string]string { if o == nil || IsNil(o.Labels) { @@ -143,30 +167,6 @@ func (o *CreateVPNGatewayPayload) SetLabels(v map[string]string) { o.Labels = &v } -// GetName returns the Name field value -func (o *CreateVPNGatewayPayload) GetName() string { - if o == nil { - var ret string - return ret - } - - return o.Name -} - -// GetNameOk returns a tuple with the Name field value -// and a boolean to check if the value has been set. -func (o *CreateVPNGatewayPayload) GetNameOk() (*string, bool) { - if o == nil { - return nil, false - } - return &o.Name, true -} - -// SetName sets field value -func (o *CreateVPNGatewayPayload) SetName(v string) { - o.Name = v -} - // GetPlanId returns the PlanId field value func (o *CreateVPNGatewayPayload) GetPlanId() string { if o == nil { @@ -229,10 +229,10 @@ func (o CreateVPNGatewayPayload) ToMap() (map[string]interface{}, error) { if !IsNil(o.Bgp) { toSerialize["bgp"] = o.Bgp } + toSerialize["displayName"] = o.DisplayName if !IsNil(o.Labels) { toSerialize["labels"] = o.Labels } - toSerialize["name"] = o.Name toSerialize["planId"] = o.PlanId toSerialize["routingType"] = o.RoutingType return toSerialize, nil @@ -244,7 +244,7 @@ func (o *CreateVPNGatewayPayload) UnmarshalJSON(data []byte) (err error) { // that every required field exists as a key in the generic map. requiredProperties := []string{ "availabilityZones", - "name", + "displayName", "planId", "routingType", } diff --git a/services/vpn/v1alpha1api/model_create_vpn_gateway_payload_availability_zones.go b/services/vpn/v1alpha1api/model_create_vpn_gateway_payload_availability_zones.go index a32757662..6adef7f39 100644 --- a/services/vpn/v1alpha1api/model_create_vpn_gateway_payload_availability_zones.go +++ b/services/vpn/v1alpha1api/model_create_vpn_gateway_payload_availability_zones.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ diff --git a/services/vpn/v1alpha1api/model_gateway.go b/services/vpn/v1alpha1api/model_gateway.go index 0dbe50c83..bec29ff2a 100644 --- a/services/vpn/v1alpha1api/model_gateway.go +++ b/services/vpn/v1alpha1api/model_gateway.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ @@ -23,11 +23,11 @@ var _ MappedNullable = &Gateway{} type Gateway struct { AvailabilityZones GatewayAvailabilityZones `json:"availabilityZones"` Bgp *BGPGatewayConfig `json:"bgp,omitempty"` - // Map of custom labels. Key and values must be a string with max 63 chars, start/end with alphanumeric. The key of a label follows the same rules as the LabelValue except that it cannot be empty. + // A user-friendly name for the VPN gateway. + DisplayName string `json:"displayName" validate:"regexp=^[a-zA-Z0-9]([a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?$"` + // Map of custom labels. Key and values must be a string with max 63 chars, start/end with alphanumeric. The key of a label follows the same rules as the `LabelValue` except that it cannot be empty. Labels *map[string]string `json:"labels,omitempty"` - // The name of the VPN gateway. Maximum 20 characters (only alphanumeric and hyphens allowed). Not changeable after creation. - Name string `json:"name" validate:"regexp=^[a-z0-9]([a-z0-9-]{0,18}[a-z0-9])?$"` - // Service Plan to configure the limits of the VPN. Currently supported plans are p50, p100, p200. This list can change in the future where plan ids will be removed and new plans by added. That is the reason this is not an enum. + // The service plan identifier. PlanId string `json:"planId"` RoutingType RoutingType `json:"routingType"` } @@ -38,10 +38,10 @@ type _Gateway Gateway // This constructor will assign default values to properties that have it defined, // and makes sure properties required by API are set, but the set of arguments // will change when the set of required properties is changed -func NewGateway(availabilityZones GatewayAvailabilityZones, name string, planId string, routingType RoutingType) *Gateway { +func NewGateway(availabilityZones GatewayAvailabilityZones, displayName string, planId string, routingType RoutingType) *Gateway { this := Gateway{} this.AvailabilityZones = availabilityZones - this.Name = name + this.DisplayName = displayName this.PlanId = planId this.RoutingType = routingType return &this @@ -111,6 +111,30 @@ func (o *Gateway) SetBgp(v BGPGatewayConfig) { o.Bgp = &v } +// GetDisplayName returns the DisplayName field value +func (o *Gateway) GetDisplayName() string { + if o == nil { + var ret string + return ret + } + + return o.DisplayName +} + +// GetDisplayNameOk returns a tuple with the DisplayName field value +// and a boolean to check if the value has been set. +func (o *Gateway) GetDisplayNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.DisplayName, true +} + +// SetDisplayName sets field value +func (o *Gateway) SetDisplayName(v string) { + o.DisplayName = v +} + // GetLabels returns the Labels field value if set, zero value otherwise. func (o *Gateway) GetLabels() map[string]string { if o == nil || IsNil(o.Labels) { @@ -143,30 +167,6 @@ func (o *Gateway) SetLabels(v map[string]string) { o.Labels = &v } -// GetName returns the Name field value -func (o *Gateway) GetName() string { - if o == nil { - var ret string - return ret - } - - return o.Name -} - -// GetNameOk returns a tuple with the Name field value -// and a boolean to check if the value has been set. -func (o *Gateway) GetNameOk() (*string, bool) { - if o == nil { - return nil, false - } - return &o.Name, true -} - -// SetName sets field value -func (o *Gateway) SetName(v string) { - o.Name = v -} - // GetPlanId returns the PlanId field value func (o *Gateway) GetPlanId() string { if o == nil { @@ -229,10 +229,10 @@ func (o Gateway) ToMap() (map[string]interface{}, error) { if !IsNil(o.Bgp) { toSerialize["bgp"] = o.Bgp } + toSerialize["displayName"] = o.DisplayName if !IsNil(o.Labels) { toSerialize["labels"] = o.Labels } - toSerialize["name"] = o.Name toSerialize["planId"] = o.PlanId toSerialize["routingType"] = o.RoutingType return toSerialize, nil @@ -244,7 +244,7 @@ func (o *Gateway) UnmarshalJSON(data []byte) (err error) { // that every required field exists as a key in the generic map. requiredProperties := []string{ "availabilityZones", - "name", + "displayName", "planId", "routingType", } diff --git a/services/vpn/v1alpha1api/model_gateway_availability_zones.go b/services/vpn/v1alpha1api/model_gateway_availability_zones.go index b97a753d6..1fde228c7 100644 --- a/services/vpn/v1alpha1api/model_gateway_availability_zones.go +++ b/services/vpn/v1alpha1api/model_gateway_availability_zones.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ diff --git a/services/vpn/v1alpha1api/model_gateway_list.go b/services/vpn/v1alpha1api/model_gateway_list.go index 6eb37180a..d7875a5cd 100644 --- a/services/vpn/v1alpha1api/model_gateway_list.go +++ b/services/vpn/v1alpha1api/model_gateway_list.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ diff --git a/services/vpn/v1alpha1api/model_gateway_response.go b/services/vpn/v1alpha1api/model_gateway_response.go index d683b51b2..d2b89ae73 100644 --- a/services/vpn/v1alpha1api/model_gateway_response.go +++ b/services/vpn/v1alpha1api/model_gateway_response.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ @@ -23,15 +23,16 @@ var _ MappedNullable = &GatewayResponse{} type GatewayResponse struct { AvailabilityZones GatewayAvailabilityZones `json:"availabilityZones"` Bgp *BGPGatewayConfig `json:"bgp,omitempty"` - // Map of custom labels. Key and values must be a string with max 63 chars, start/end with alphanumeric. The key of a label follows the same rules as the LabelValue except that it cannot be empty. + // A user-friendly name for the VPN gateway. + DisplayName string `json:"displayName" validate:"regexp=^[a-zA-Z0-9]([a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?$"` + // Map of custom labels. Key and values must be a string with max 63 chars, start/end with alphanumeric. The key of a label follows the same rules as the `LabelValue` except that it cannot be empty. Labels *map[string]string `json:"labels,omitempty"` - // The name of the VPN gateway. Maximum 20 characters (only alphanumeric and hyphens allowed). Not changeable after creation. - Name string `json:"name" validate:"regexp=^[a-z0-9]([a-z0-9-]{0,18}[a-z0-9])?$"` - // Service Plan to configure the limits of the VPN. Currently supported plans are p50, p100, p200. This list can change in the future where plan ids will be removed and new plans by added. That is the reason this is not an enum. - PlanId string `json:"planId"` - RoutingType RoutingType `json:"routingType"` - Region *Region `json:"region,omitempty"` - State *GatewayStatus `json:"state,omitempty"` + // The service plan identifier. + PlanId string `json:"planId"` + RoutingType RoutingType `json:"routingType"` + // The server-generated UUID of the VPN gateway. + Id *string `json:"id,omitempty"` + State *GatewayStatus `json:"state,omitempty"` } type _GatewayResponse GatewayResponse @@ -40,14 +41,12 @@ type _GatewayResponse GatewayResponse // This constructor will assign default values to properties that have it defined, // and makes sure properties required by API are set, but the set of arguments // will change when the set of required properties is changed -func NewGatewayResponse(availabilityZones GatewayAvailabilityZones, name string, planId string, routingType RoutingType) *GatewayResponse { +func NewGatewayResponse(availabilityZones GatewayAvailabilityZones, displayName string, planId string, routingType RoutingType) *GatewayResponse { this := GatewayResponse{} this.AvailabilityZones = availabilityZones - this.Name = name + this.DisplayName = displayName this.PlanId = planId this.RoutingType = routingType - var region Region = REGION_EU01 - this.Region = ®ion return &this } @@ -56,8 +55,6 @@ func NewGatewayResponse(availabilityZones GatewayAvailabilityZones, name string, // but it doesn't guarantee that properties required by API are set func NewGatewayResponseWithDefaults() *GatewayResponse { this := GatewayResponse{} - var region Region = REGION_EU01 - this.Region = ®ion return &this } @@ -117,6 +114,30 @@ func (o *GatewayResponse) SetBgp(v BGPGatewayConfig) { o.Bgp = &v } +// GetDisplayName returns the DisplayName field value +func (o *GatewayResponse) GetDisplayName() string { + if o == nil { + var ret string + return ret + } + + return o.DisplayName +} + +// GetDisplayNameOk returns a tuple with the DisplayName field value +// and a boolean to check if the value has been set. +func (o *GatewayResponse) GetDisplayNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.DisplayName, true +} + +// SetDisplayName sets field value +func (o *GatewayResponse) SetDisplayName(v string) { + o.DisplayName = v +} + // GetLabels returns the Labels field value if set, zero value otherwise. func (o *GatewayResponse) GetLabels() map[string]string { if o == nil || IsNil(o.Labels) { @@ -149,30 +170,6 @@ func (o *GatewayResponse) SetLabels(v map[string]string) { o.Labels = &v } -// GetName returns the Name field value -func (o *GatewayResponse) GetName() string { - if o == nil { - var ret string - return ret - } - - return o.Name -} - -// GetNameOk returns a tuple with the Name field value -// and a boolean to check if the value has been set. -func (o *GatewayResponse) GetNameOk() (*string, bool) { - if o == nil { - return nil, false - } - return &o.Name, true -} - -// SetName sets field value -func (o *GatewayResponse) SetName(v string) { - o.Name = v -} - // GetPlanId returns the PlanId field value func (o *GatewayResponse) GetPlanId() string { if o == nil { @@ -221,36 +218,36 @@ func (o *GatewayResponse) SetRoutingType(v RoutingType) { o.RoutingType = v } -// GetRegion returns the Region field value if set, zero value otherwise. -func (o *GatewayResponse) GetRegion() Region { - if o == nil || IsNil(o.Region) { - var ret Region +// GetId returns the Id field value if set, zero value otherwise. +func (o *GatewayResponse) GetId() string { + if o == nil || IsNil(o.Id) { + var ret string return ret } - return *o.Region + return *o.Id } -// GetRegionOk returns a tuple with the Region field value if set, nil otherwise +// GetIdOk returns a tuple with the Id field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *GatewayResponse) GetRegionOk() (*Region, bool) { - if o == nil || IsNil(o.Region) { +func (o *GatewayResponse) GetIdOk() (*string, bool) { + if o == nil || IsNil(o.Id) { return nil, false } - return o.Region, true + return o.Id, true } -// HasRegion returns a boolean if a field has been set. -func (o *GatewayResponse) HasRegion() bool { - if o != nil && !IsNil(o.Region) { +// HasId returns a boolean if a field has been set. +func (o *GatewayResponse) HasId() bool { + if o != nil && !IsNil(o.Id) { return true } return false } -// SetRegion gets a reference to the given Region and assigns it to the Region field. -func (o *GatewayResponse) SetRegion(v Region) { - o.Region = &v +// SetId gets a reference to the given string and assigns it to the Id field. +func (o *GatewayResponse) SetId(v string) { + o.Id = &v } // GetState returns the State field value if set, zero value otherwise. @@ -299,14 +296,14 @@ func (o GatewayResponse) ToMap() (map[string]interface{}, error) { if !IsNil(o.Bgp) { toSerialize["bgp"] = o.Bgp } + toSerialize["displayName"] = o.DisplayName if !IsNil(o.Labels) { toSerialize["labels"] = o.Labels } - toSerialize["name"] = o.Name toSerialize["planId"] = o.PlanId toSerialize["routingType"] = o.RoutingType - if !IsNil(o.Region) { - toSerialize["region"] = o.Region + if !IsNil(o.Id) { + toSerialize["id"] = o.Id } if !IsNil(o.State) { toSerialize["state"] = o.State @@ -320,7 +317,7 @@ func (o *GatewayResponse) UnmarshalJSON(data []byte) (err error) { // that every required field exists as a key in the generic map. requiredProperties := []string{ "availabilityZones", - "name", + "displayName", "planId", "routingType", } diff --git a/services/vpn/v1alpha1api/model_gateway_status.go b/services/vpn/v1alpha1api/model_gateway_status.go index 8362696d4..40c51f3b8 100644 --- a/services/vpn/v1alpha1api/model_gateway_status.go +++ b/services/vpn/v1alpha1api/model_gateway_status.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ @@ -15,7 +15,7 @@ import ( "fmt" ) -// GatewayStatus Describes the status of the surrounding infrastructure. +// GatewayStatus The current lifecycle state of the gateway infrastructure. - `PENDING`: Provisioning or update is in progress. - `READY`: The gateway is fully operational. - `ERROR`: A failure occurred. - `DELETING`: The resource is being removed. type GatewayStatus string // List of GatewayStatus diff --git a/services/vpn/v1alpha1api/model_gateway_status_response.go b/services/vpn/v1alpha1api/model_gateway_status_response.go index a0c490fc6..484582e81 100644 --- a/services/vpn/v1alpha1api/model_gateway_status_response.go +++ b/services/vpn/v1alpha1api/model_gateway_status_response.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ @@ -19,10 +19,13 @@ var _ MappedNullable = &GatewayStatusResponse{} // GatewayStatusResponse struct for GatewayStatusResponse type GatewayStatusResponse struct { + Connections []ConnectionStatusResponse `json:"connections,omitempty"` // Name of the Gateway instance. - GatewayName *string `json:"gatewayName,omitempty"` + DisplayName *string `json:"displayName,omitempty"` GatewayStatus *GatewayStatus `json:"gatewayStatus,omitempty"` - Tunnels []VPNTunnels `json:"tunnels,omitempty"` + // UUID of the Gateway instance. + Id *string `json:"id,omitempty"` + Tunnels []VPNTunnels `json:"tunnels,omitempty"` } // NewGatewayStatusResponse instantiates a new GatewayStatusResponse object @@ -42,36 +45,68 @@ func NewGatewayStatusResponseWithDefaults() *GatewayStatusResponse { return &this } -// GetGatewayName returns the GatewayName field value if set, zero value otherwise. -func (o *GatewayStatusResponse) GetGatewayName() string { - if o == nil || IsNil(o.GatewayName) { +// GetConnections returns the Connections field value if set, zero value otherwise. +func (o *GatewayStatusResponse) GetConnections() []ConnectionStatusResponse { + if o == nil || IsNil(o.Connections) { + var ret []ConnectionStatusResponse + return ret + } + return o.Connections +} + +// GetConnectionsOk returns a tuple with the Connections field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GatewayStatusResponse) GetConnectionsOk() ([]ConnectionStatusResponse, bool) { + if o == nil || IsNil(o.Connections) { + return nil, false + } + return o.Connections, true +} + +// HasConnections returns a boolean if a field has been set. +func (o *GatewayStatusResponse) HasConnections() bool { + if o != nil && !IsNil(o.Connections) { + return true + } + + return false +} + +// SetConnections gets a reference to the given []ConnectionStatusResponse and assigns it to the Connections field. +func (o *GatewayStatusResponse) SetConnections(v []ConnectionStatusResponse) { + o.Connections = v +} + +// GetDisplayName returns the DisplayName field value if set, zero value otherwise. +func (o *GatewayStatusResponse) GetDisplayName() string { + if o == nil || IsNil(o.DisplayName) { var ret string return ret } - return *o.GatewayName + return *o.DisplayName } -// GetGatewayNameOk returns a tuple with the GatewayName field value if set, nil otherwise +// GetDisplayNameOk returns a tuple with the DisplayName field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *GatewayStatusResponse) GetGatewayNameOk() (*string, bool) { - if o == nil || IsNil(o.GatewayName) { +func (o *GatewayStatusResponse) GetDisplayNameOk() (*string, bool) { + if o == nil || IsNil(o.DisplayName) { return nil, false } - return o.GatewayName, true + return o.DisplayName, true } -// HasGatewayName returns a boolean if a field has been set. -func (o *GatewayStatusResponse) HasGatewayName() bool { - if o != nil && !IsNil(o.GatewayName) { +// HasDisplayName returns a boolean if a field has been set. +func (o *GatewayStatusResponse) HasDisplayName() bool { + if o != nil && !IsNil(o.DisplayName) { return true } return false } -// SetGatewayName gets a reference to the given string and assigns it to the GatewayName field. -func (o *GatewayStatusResponse) SetGatewayName(v string) { - o.GatewayName = &v +// SetDisplayName gets a reference to the given string and assigns it to the DisplayName field. +func (o *GatewayStatusResponse) SetDisplayName(v string) { + o.DisplayName = &v } // GetGatewayStatus returns the GatewayStatus field value if set, zero value otherwise. @@ -106,6 +141,38 @@ func (o *GatewayStatusResponse) SetGatewayStatus(v GatewayStatus) { o.GatewayStatus = &v } +// GetId returns the Id field value if set, zero value otherwise. +func (o *GatewayStatusResponse) GetId() string { + if o == nil || IsNil(o.Id) { + var ret string + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GatewayStatusResponse) GetIdOk() (*string, bool) { + if o == nil || IsNil(o.Id) { + return nil, false + } + return o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *GatewayStatusResponse) HasId() bool { + if o != nil && !IsNil(o.Id) { + return true + } + + return false +} + +// SetId gets a reference to the given string and assigns it to the Id field. +func (o *GatewayStatusResponse) SetId(v string) { + o.Id = &v +} + // GetTunnels returns the Tunnels field value if set, zero value otherwise. func (o *GatewayStatusResponse) GetTunnels() []VPNTunnels { if o == nil || IsNil(o.Tunnels) { @@ -148,12 +215,18 @@ func (o GatewayStatusResponse) MarshalJSON() ([]byte, error) { func (o GatewayStatusResponse) ToMap() (map[string]interface{}, error) { toSerialize := map[string]interface{}{} - if !IsNil(o.GatewayName) { - toSerialize["gatewayName"] = o.GatewayName + if !IsNil(o.Connections) { + toSerialize["connections"] = o.Connections + } + if !IsNil(o.DisplayName) { + toSerialize["displayName"] = o.DisplayName } if !IsNil(o.GatewayStatus) { toSerialize["gatewayStatus"] = o.GatewayStatus } + if !IsNil(o.Id) { + toSerialize["id"] = o.Id + } if !IsNil(o.Tunnels) { toSerialize["tunnels"] = o.Tunnels } diff --git a/services/vpn/v1alpha1api/model_peering_config.go b/services/vpn/v1alpha1api/model_peering_config.go index a6c0b11ad..e4d5890c2 100644 --- a/services/vpn/v1alpha1api/model_peering_config.go +++ b/services/vpn/v1alpha1api/model_peering_config.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ diff --git a/services/vpn/v1alpha1api/model_phase.go b/services/vpn/v1alpha1api/model_phase.go index a5d2a9762..c79781087 100644 --- a/services/vpn/v1alpha1api/model_phase.go +++ b/services/vpn/v1alpha1api/model_phase.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ diff --git a/services/vpn/v1alpha1api/model_phase1_status.go b/services/vpn/v1alpha1api/model_phase1_status.go index 83a829b22..bbe640600 100644 --- a/services/vpn/v1alpha1api/model_phase1_status.go +++ b/services/vpn/v1alpha1api/model_phase1_status.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ @@ -19,11 +19,11 @@ var _ MappedNullable = &Phase1Status{} // Phase1Status struct for Phase1Status type Phase1Status struct { - // Negotiated Diffie-Hellman Group + // The negotiated Diffie-Hellman Group DhGroup *string `json:"dhGroup,omitempty"` - // Negotiated encryption algorithm. + // The negotiated encryption algorithm. EncryptionAlgorithm *string `json:"encryptionAlgorithm,omitempty"` - // Negotiated integrity algorithm or pseudo-random-function. + // The negotiated integrity algorithm or pseudo-random-function. IntegrityAlgorithm *string `json:"integrityAlgorithm,omitempty"` State *string `json:"state,omitempty"` } diff --git a/services/vpn/v1alpha1api/model_phase2_status.go b/services/vpn/v1alpha1api/model_phase2_status.go index 44fdfccf8..28c980d60 100644 --- a/services/vpn/v1alpha1api/model_phase2_status.go +++ b/services/vpn/v1alpha1api/model_phase2_status.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ @@ -19,23 +19,25 @@ var _ MappedNullable = &Phase2Status{} // Phase2Status struct for Phase2Status type Phase2Status struct { - // Bytes received. + // The total data volume received through this Security Association, measured in bytes. BytesIn *string `json:"bytesIn,omitempty"` - // Bytes sent. + // The total data volume sent through this Security Association, measured in bytes. BytesOut *string `json:"bytesOut,omitempty"` - // Negotiated Diffie-Hellman Group + // The negotiated Diffie-Hellman Group DhGroup *string `json:"dhGroup,omitempty"` - Encap *string `json:"encap,omitempty"` - // Negotiated encryption algorithm. + // Indicates whether NAT traversal encapsulation is active for the connection. + Encap *string `json:"encap,omitempty"` + // The negotiated encryption algorithm. EncryptionAlgorithm *string `json:"encryptionAlgorithm,omitempty"` - // Negotiated integrity algorithm or pseudo-random-function. + // The negotiated integrity algorithm or pseudo-random-function. IntegrityAlgorithm *string `json:"integrityAlgorithm,omitempty"` - // Packets received. + // The total number of packets received through this IPsec Security Association. PacketsIn *string `json:"packetsIn,omitempty"` - // Packets sent. + // The total number of packets sent through this IPsec Security Association PacketsOut *string `json:"packetsOut,omitempty"` - Protocol *string `json:"protocol,omitempty"` - State *string `json:"state,omitempty"` + // The security protocol used for the tunnel, typically `ESP` (Encapsulating Security Payload). + Protocol *string `json:"protocol,omitempty"` + State *string `json:"state,omitempty"` } // NewPhase2Status instantiates a new Phase2Status object diff --git a/services/vpn/v1alpha1api/model_plan.go b/services/vpn/v1alpha1api/model_plan.go index 2f8e31839..744f37bf0 100644 --- a/services/vpn/v1alpha1api/model_plan.go +++ b/services/vpn/v1alpha1api/model_plan.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ @@ -19,20 +19,16 @@ var _ MappedNullable = &Plan{} // Plan struct for Plan type Plan struct { - // Maximum bandwidth of a VPN instance. + // The maximum throughput supported by the gateway in each direction, measured in MBit/s MaxBandwidth *int32 `json:"maxBandwidth,omitempty"` - // Maximum concurrent connections of a VPN Gateway. + // The maximum number of connections supported by the VPN Gateway. MaxConnections *int32 `json:"maxConnections,omitempty"` - // Service plan name + // The name of the service plan. Name *string `json:"name,omitempty"` - // Service plan identifier + // The service plan identifier. PlanId *string `json:"planId,omitempty"` - // Region (read-only) - Region *string `json:"region,omitempty"` - // Plan SKU + // The SKU identifier used for billing. Sku *string `json:"sku,omitempty"` - // Service plan type - Type *string `json:"type,omitempty"` } // NewPlan instantiates a new Plan object @@ -180,38 +176,6 @@ func (o *Plan) SetPlanId(v string) { o.PlanId = &v } -// GetRegion returns the Region field value if set, zero value otherwise. -func (o *Plan) GetRegion() string { - if o == nil || IsNil(o.Region) { - var ret string - return ret - } - return *o.Region -} - -// GetRegionOk returns a tuple with the Region field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *Plan) GetRegionOk() (*string, bool) { - if o == nil || IsNil(o.Region) { - return nil, false - } - return o.Region, true -} - -// HasRegion returns a boolean if a field has been set. -func (o *Plan) HasRegion() bool { - if o != nil && !IsNil(o.Region) { - return true - } - - return false -} - -// SetRegion gets a reference to the given string and assigns it to the Region field. -func (o *Plan) SetRegion(v string) { - o.Region = &v -} - // GetSku returns the Sku field value if set, zero value otherwise. func (o *Plan) GetSku() string { if o == nil || IsNil(o.Sku) { @@ -244,38 +208,6 @@ func (o *Plan) SetSku(v string) { o.Sku = &v } -// GetType returns the Type field value if set, zero value otherwise. -func (o *Plan) GetType() string { - if o == nil || IsNil(o.Type) { - var ret string - return ret - } - return *o.Type -} - -// GetTypeOk returns a tuple with the Type field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *Plan) GetTypeOk() (*string, bool) { - if o == nil || IsNil(o.Type) { - return nil, false - } - return o.Type, true -} - -// HasType returns a boolean if a field has been set. -func (o *Plan) HasType() bool { - if o != nil && !IsNil(o.Type) { - return true - } - - return false -} - -// SetType gets a reference to the given string and assigns it to the Type field. -func (o *Plan) SetType(v string) { - o.Type = &v -} - func (o Plan) MarshalJSON() ([]byte, error) { toSerialize, err := o.ToMap() if err != nil { @@ -298,15 +230,9 @@ func (o Plan) ToMap() (map[string]interface{}, error) { if !IsNil(o.PlanId) { toSerialize["planId"] = o.PlanId } - if !IsNil(o.Region) { - toSerialize["region"] = o.Region - } if !IsNil(o.Sku) { toSerialize["sku"] = o.Sku } - if !IsNil(o.Type) { - toSerialize["type"] = o.Type - } return toSerialize, nil } diff --git a/services/vpn/v1alpha1api/model_plan_list.go b/services/vpn/v1alpha1api/model_plan_list.go index 1c14e721a..f71dc1df9 100644 --- a/services/vpn/v1alpha1api/model_plan_list.go +++ b/services/vpn/v1alpha1api/model_plan_list.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ @@ -19,10 +19,9 @@ var _ MappedNullable = &PlanList{} // PlanList struct for PlanList type PlanList struct { - // Default Plan ID for the current region - DefaultPlanId *string `json:"defaultPlanId,omitempty"` - Plans []Plan `json:"plans,omitempty"` - Tunnel *VPNTunnelPlan `json:"tunnel,omitempty"` + // The service plan identifier. + DefaultPlanId *string `json:"defaultPlanId,omitempty"` + Plans []Plan `json:"plans,omitempty"` } // NewPlanList instantiates a new PlanList object @@ -106,38 +105,6 @@ func (o *PlanList) SetPlans(v []Plan) { o.Plans = v } -// GetTunnel returns the Tunnel field value if set, zero value otherwise. -func (o *PlanList) GetTunnel() VPNTunnelPlan { - if o == nil || IsNil(o.Tunnel) { - var ret VPNTunnelPlan - return ret - } - return *o.Tunnel -} - -// GetTunnelOk returns a tuple with the Tunnel field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *PlanList) GetTunnelOk() (*VPNTunnelPlan, bool) { - if o == nil || IsNil(o.Tunnel) { - return nil, false - } - return o.Tunnel, true -} - -// HasTunnel returns a boolean if a field has been set. -func (o *PlanList) HasTunnel() bool { - if o != nil && !IsNil(o.Tunnel) { - return true - } - - return false -} - -// SetTunnel gets a reference to the given VPNTunnelPlan and assigns it to the Tunnel field. -func (o *PlanList) SetTunnel(v VPNTunnelPlan) { - o.Tunnel = &v -} - func (o PlanList) MarshalJSON() ([]byte, error) { toSerialize, err := o.ToMap() if err != nil { @@ -154,9 +121,6 @@ func (o PlanList) ToMap() (map[string]interface{}, error) { if !IsNil(o.Plans) { toSerialize["plans"] = o.Plans } - if !IsNil(o.Tunnel) { - toSerialize["tunnel"] = o.Tunnel - } return toSerialize, nil } diff --git a/services/vpn/v1alpha1api/model_quota.go b/services/vpn/v1alpha1api/model_quota.go index f41262b99..c474d3bf9 100644 --- a/services/vpn/v1alpha1api/model_quota.go +++ b/services/vpn/v1alpha1api/model_quota.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ diff --git a/services/vpn/v1alpha1api/model_quota_list.go b/services/vpn/v1alpha1api/model_quota_list.go index ffbb1c75d..f29635e3f 100644 --- a/services/vpn/v1alpha1api/model_quota_list.go +++ b/services/vpn/v1alpha1api/model_quota_list.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ @@ -21,7 +21,7 @@ var _ MappedNullable = &QuotaList{} // QuotaList struct for QuotaList type QuotaList struct { - // The number of gateways. + // Current limit and usage for VPN gateways. Gateways Quota `json:"gateways"` } diff --git a/services/vpn/v1alpha1api/model_quota_list_response.go b/services/vpn/v1alpha1api/model_quota_list_response.go index 3867ec307..a118fb9cc 100644 --- a/services/vpn/v1alpha1api/model_quota_list_response.go +++ b/services/vpn/v1alpha1api/model_quota_list_response.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ diff --git a/services/vpn/v1alpha1api/model_region.go b/services/vpn/v1alpha1api/model_region.go index ca0eaed45..8bbca0bcb 100644 --- a/services/vpn/v1alpha1api/model_region.go +++ b/services/vpn/v1alpha1api/model_region.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ diff --git a/services/vpn/v1alpha1api/model_routing_type.go b/services/vpn/v1alpha1api/model_routing_type.go index 7eb5d4ff2..07ecc1988 100644 --- a/services/vpn/v1alpha1api/model_routing_type.go +++ b/services/vpn/v1alpha1api/model_routing_type.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ diff --git a/services/vpn/v1alpha1api/model_tunnel_configuration.go b/services/vpn/v1alpha1api/model_tunnel_configuration.go index a0c670de8..d77a0c409 100644 --- a/services/vpn/v1alpha1api/model_tunnel_configuration.go +++ b/services/vpn/v1alpha1api/model_tunnel_configuration.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ diff --git a/services/vpn/v1alpha1api/model_tunnel_configuration_phase1.go b/services/vpn/v1alpha1api/model_tunnel_configuration_phase1.go index 79bcd1df7..efcdff952 100644 --- a/services/vpn/v1alpha1api/model_tunnel_configuration_phase1.go +++ b/services/vpn/v1alpha1api/model_tunnel_configuration_phase1.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ diff --git a/services/vpn/v1alpha1api/model_tunnel_configuration_phase2.go b/services/vpn/v1alpha1api/model_tunnel_configuration_phase2.go index 9a0ef940d..d0e0e420b 100644 --- a/services/vpn/v1alpha1api/model_tunnel_configuration_phase2.go +++ b/services/vpn/v1alpha1api/model_tunnel_configuration_phase2.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ @@ -25,11 +25,11 @@ type TunnelConfigurationPhase2 struct { DhGroups []string `json:"dhGroups,omitempty"` EncryptionAlgorithms []string `json:"encryptionAlgorithms"` IntegrityAlgorithms []string `json:"integrityAlgorithms"` - // Action to perform for this CHILD_SA on DPD timeout. \"clear\": Closes the CHILD_SA and does not take further action. \"trap\": installs a trap policy which will catch matching traffic and tries to re-negotiate the tunnel on-demand). \"restart\": immediately tries to re-negotiate the CILD_SA under a fresh IKE_SA. + // Action to perform for this CHILD_SA on DPD timeout. \"clear\": Closes the CHILD_SA and does not take further action. \"restart\": immediately tries to re-negotiate the CILD_SA under a fresh IKE_SA. DpdAction *string `json:"dpdAction,omitempty"` // Time to schedule a Child SA re-keying (in seconds). RekeyTime *int32 `json:"rekeyTime,omitempty"` - // Action to perform after loading the connection configuration. \"none\": The connection will be loaded but needs to be manually initiated. \"trap\": installs a trap policy which triggers the tunnel as soon as matching traffic has been detected. \"start\": initiates the connection actively. \"start|stop\": Immediately initiate a connection for which trap policies have been installed. + // Action to perform after loading the connection configuration. \"none\": The connection will be loaded but needs to be manually initiated. \"start\": initiates the connection actively. StartAction *string `json:"startAction,omitempty"` } diff --git a/services/vpn/v1alpha1api/model_tunnel_status.go b/services/vpn/v1alpha1api/model_tunnel_status.go index dddd77808..2459125ed 100644 --- a/services/vpn/v1alpha1api/model_tunnel_status.go +++ b/services/vpn/v1alpha1api/model_tunnel_status.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ diff --git a/services/vpn/v1alpha1api/model_update_gateway_connection_payload.go b/services/vpn/v1alpha1api/model_update_gateway_connection_payload.go index f9d3ec49b..f4923a06f 100644 --- a/services/vpn/v1alpha1api/model_update_gateway_connection_payload.go +++ b/services/vpn/v1alpha1api/model_update_gateway_connection_payload.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ @@ -21,19 +21,18 @@ var _ MappedNullable = &UpdateGatewayConnectionPayload{} // UpdateGatewayConnectionPayload struct for UpdateGatewayConnectionPayload type UpdateGatewayConnectionPayload struct { + // A user-friendly name for the connection. + DisplayName string `json:"displayName" validate:"regexp=^[a-zA-Z0-9]([a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?$"` // This flag decides whether this connection should be enabled or disabled Enabled *bool `json:"enabled,omitempty"` - // Map of custom labels. Key and values must be a string with max 63 chars, start/end with alphanumeric. The key of a label follows the same rules as the LabelValue except that it cannot be empty. - Labels *map[string]string `json:"labels,omitempty"` // Optional. Defaults to 0.0.0.0/0 for Route-based VPN configurations. Mandatory for Policy-based. LocalSubnets []string `json:"localSubnets,omitempty"` - // The name of the connection. Maximum 20 characters (only alphanumeric and hyphens allowed). The name bust be unique within the parent Gateway. Currently renaming is not possible therefore deleting and re-creating the connection is necessary. - Name string `json:"name" validate:"regexp=^[a-z0-9]([a-z0-9-]{0,18}[a-z0-9])?$"` // Optional. Defaults to 0.0.0.0/0 for Route-based VPN configurations. Mandatory for Policy-based. - RemoteSubnets []string `json:"remoteSubnets,omitempty"` - StaticRoutes []string `json:"staticRoutes,omitempty"` - Tunnel1 TunnelConfiguration `json:"tunnel1"` - Tunnel2 TunnelConfiguration `json:"tunnel2"` + RemoteSubnets []string `json:"remoteSubnets,omitempty"` + // Optional. Use this for route-based VPN. + StaticRoutes []string `json:"staticRoutes,omitempty"` + Tunnel1 TunnelConfiguration `json:"tunnel1"` + Tunnel2 TunnelConfiguration `json:"tunnel2"` } type _UpdateGatewayConnectionPayload UpdateGatewayConnectionPayload @@ -42,9 +41,9 @@ type _UpdateGatewayConnectionPayload UpdateGatewayConnectionPayload // This constructor will assign default values to properties that have it defined, // and makes sure properties required by API are set, but the set of arguments // will change when the set of required properties is changed -func NewUpdateGatewayConnectionPayload(name string, tunnel1 TunnelConfiguration, tunnel2 TunnelConfiguration) *UpdateGatewayConnectionPayload { +func NewUpdateGatewayConnectionPayload(displayName string, tunnel1 TunnelConfiguration, tunnel2 TunnelConfiguration) *UpdateGatewayConnectionPayload { this := UpdateGatewayConnectionPayload{} - this.Name = name + this.DisplayName = displayName this.Tunnel1 = tunnel1 this.Tunnel2 = tunnel2 return &this @@ -58,6 +57,30 @@ func NewUpdateGatewayConnectionPayloadWithDefaults() *UpdateGatewayConnectionPay return &this } +// GetDisplayName returns the DisplayName field value +func (o *UpdateGatewayConnectionPayload) GetDisplayName() string { + if o == nil { + var ret string + return ret + } + + return o.DisplayName +} + +// GetDisplayNameOk returns a tuple with the DisplayName field value +// and a boolean to check if the value has been set. +func (o *UpdateGatewayConnectionPayload) GetDisplayNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.DisplayName, true +} + +// SetDisplayName sets field value +func (o *UpdateGatewayConnectionPayload) SetDisplayName(v string) { + o.DisplayName = v +} + // GetEnabled returns the Enabled field value if set, zero value otherwise. func (o *UpdateGatewayConnectionPayload) GetEnabled() bool { if o == nil || IsNil(o.Enabled) { @@ -90,38 +113,6 @@ func (o *UpdateGatewayConnectionPayload) SetEnabled(v bool) { o.Enabled = &v } -// GetLabels returns the Labels field value if set, zero value otherwise. -func (o *UpdateGatewayConnectionPayload) GetLabels() map[string]string { - if o == nil || IsNil(o.Labels) { - var ret map[string]string - return ret - } - return *o.Labels -} - -// GetLabelsOk returns a tuple with the Labels field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *UpdateGatewayConnectionPayload) GetLabelsOk() (*map[string]string, bool) { - if o == nil || IsNil(o.Labels) { - return nil, false - } - return o.Labels, true -} - -// HasLabels returns a boolean if a field has been set. -func (o *UpdateGatewayConnectionPayload) HasLabels() bool { - if o != nil && !IsNil(o.Labels) { - return true - } - - return false -} - -// SetLabels gets a reference to the given map[string]string and assigns it to the Labels field. -func (o *UpdateGatewayConnectionPayload) SetLabels(v map[string]string) { - o.Labels = &v -} - // GetLocalSubnets returns the LocalSubnets field value if set, zero value otherwise. func (o *UpdateGatewayConnectionPayload) GetLocalSubnets() []string { if o == nil || IsNil(o.LocalSubnets) { @@ -154,30 +145,6 @@ func (o *UpdateGatewayConnectionPayload) SetLocalSubnets(v []string) { o.LocalSubnets = v } -// GetName returns the Name field value -func (o *UpdateGatewayConnectionPayload) GetName() string { - if o == nil { - var ret string - return ret - } - - return o.Name -} - -// GetNameOk returns a tuple with the Name field value -// and a boolean to check if the value has been set. -func (o *UpdateGatewayConnectionPayload) GetNameOk() (*string, bool) { - if o == nil { - return nil, false - } - return &o.Name, true -} - -// SetName sets field value -func (o *UpdateGatewayConnectionPayload) SetName(v string) { - o.Name = v -} - // GetRemoteSubnets returns the RemoteSubnets field value if set, zero value otherwise. func (o *UpdateGatewayConnectionPayload) GetRemoteSubnets() []string { if o == nil || IsNil(o.RemoteSubnets) { @@ -300,16 +267,13 @@ func (o UpdateGatewayConnectionPayload) MarshalJSON() ([]byte, error) { func (o UpdateGatewayConnectionPayload) ToMap() (map[string]interface{}, error) { toSerialize := map[string]interface{}{} + toSerialize["displayName"] = o.DisplayName if !IsNil(o.Enabled) { toSerialize["enabled"] = o.Enabled } - if !IsNil(o.Labels) { - toSerialize["labels"] = o.Labels - } if !IsNil(o.LocalSubnets) { toSerialize["localSubnets"] = o.LocalSubnets } - toSerialize["name"] = o.Name if !IsNil(o.RemoteSubnets) { toSerialize["remoteSubnets"] = o.RemoteSubnets } @@ -326,7 +290,7 @@ func (o *UpdateGatewayConnectionPayload) UnmarshalJSON(data []byte) (err error) // by unmarshalling the object into a generic map with string keys and checking // that every required field exists as a key in the generic map. requiredProperties := []string{ - "name", + "displayName", "tunnel1", "tunnel2", } diff --git a/services/vpn/v1alpha1api/model_update_vpn_gateway_payload.go b/services/vpn/v1alpha1api/model_update_vpn_gateway_payload.go index 597f5d103..364dbb897 100644 --- a/services/vpn/v1alpha1api/model_update_vpn_gateway_payload.go +++ b/services/vpn/v1alpha1api/model_update_vpn_gateway_payload.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ @@ -23,11 +23,11 @@ var _ MappedNullable = &UpdateVPNGatewayPayload{} type UpdateVPNGatewayPayload struct { AvailabilityZones UpdateVPNGatewayPayloadAvailabilityZones `json:"availabilityZones"` Bgp *BGPGatewayConfig `json:"bgp,omitempty"` - // Map of custom labels. Key and values must be a string with max 63 chars, start/end with alphanumeric. The key of a label follows the same rules as the LabelValue except that it cannot be empty. + // A user-friendly name for the VPN gateway. + DisplayName string `json:"displayName" validate:"regexp=^[a-zA-Z0-9]([a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?$"` + // Map of custom labels. Key and values must be a string with max 63 chars, start/end with alphanumeric. The key of a label follows the same rules as the `LabelValue` except that it cannot be empty. Labels *map[string]string `json:"labels,omitempty"` - // The name of the VPN gateway. Maximum 20 characters (only alphanumeric and hyphens allowed). Not changeable after creation. - Name string `json:"name" validate:"regexp=^[a-z0-9]([a-z0-9-]{0,18}[a-z0-9])?$"` - // Service Plan to configure the limits of the VPN. Currently supported plans are p50, p100, p200. This list can change in the future where plan ids will be removed and new plans by added. That is the reason this is not an enum. + // The service plan identifier. PlanId string `json:"planId"` RoutingType RoutingType `json:"routingType"` } @@ -38,10 +38,10 @@ type _UpdateVPNGatewayPayload UpdateVPNGatewayPayload // This constructor will assign default values to properties that have it defined, // and makes sure properties required by API are set, but the set of arguments // will change when the set of required properties is changed -func NewUpdateVPNGatewayPayload(availabilityZones UpdateVPNGatewayPayloadAvailabilityZones, name string, planId string, routingType RoutingType) *UpdateVPNGatewayPayload { +func NewUpdateVPNGatewayPayload(availabilityZones UpdateVPNGatewayPayloadAvailabilityZones, displayName string, planId string, routingType RoutingType) *UpdateVPNGatewayPayload { this := UpdateVPNGatewayPayload{} this.AvailabilityZones = availabilityZones - this.Name = name + this.DisplayName = displayName this.PlanId = planId this.RoutingType = routingType return &this @@ -111,6 +111,30 @@ func (o *UpdateVPNGatewayPayload) SetBgp(v BGPGatewayConfig) { o.Bgp = &v } +// GetDisplayName returns the DisplayName field value +func (o *UpdateVPNGatewayPayload) GetDisplayName() string { + if o == nil { + var ret string + return ret + } + + return o.DisplayName +} + +// GetDisplayNameOk returns a tuple with the DisplayName field value +// and a boolean to check if the value has been set. +func (o *UpdateVPNGatewayPayload) GetDisplayNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.DisplayName, true +} + +// SetDisplayName sets field value +func (o *UpdateVPNGatewayPayload) SetDisplayName(v string) { + o.DisplayName = v +} + // GetLabels returns the Labels field value if set, zero value otherwise. func (o *UpdateVPNGatewayPayload) GetLabels() map[string]string { if o == nil || IsNil(o.Labels) { @@ -143,30 +167,6 @@ func (o *UpdateVPNGatewayPayload) SetLabels(v map[string]string) { o.Labels = &v } -// GetName returns the Name field value -func (o *UpdateVPNGatewayPayload) GetName() string { - if o == nil { - var ret string - return ret - } - - return o.Name -} - -// GetNameOk returns a tuple with the Name field value -// and a boolean to check if the value has been set. -func (o *UpdateVPNGatewayPayload) GetNameOk() (*string, bool) { - if o == nil { - return nil, false - } - return &o.Name, true -} - -// SetName sets field value -func (o *UpdateVPNGatewayPayload) SetName(v string) { - o.Name = v -} - // GetPlanId returns the PlanId field value func (o *UpdateVPNGatewayPayload) GetPlanId() string { if o == nil { @@ -229,10 +229,10 @@ func (o UpdateVPNGatewayPayload) ToMap() (map[string]interface{}, error) { if !IsNil(o.Bgp) { toSerialize["bgp"] = o.Bgp } + toSerialize["displayName"] = o.DisplayName if !IsNil(o.Labels) { toSerialize["labels"] = o.Labels } - toSerialize["name"] = o.Name toSerialize["planId"] = o.PlanId toSerialize["routingType"] = o.RoutingType return toSerialize, nil @@ -244,7 +244,7 @@ func (o *UpdateVPNGatewayPayload) UnmarshalJSON(data []byte) (err error) { // that every required field exists as a key in the generic map. requiredProperties := []string{ "availabilityZones", - "name", + "displayName", "planId", "routingType", } diff --git a/services/vpn/v1alpha1api/model_update_vpn_gateway_payload_availability_zones.go b/services/vpn/v1alpha1api/model_update_vpn_gateway_payload_availability_zones.go index cc9c713d2..08810264c 100644 --- a/services/vpn/v1alpha1api/model_update_vpn_gateway_payload_availability_zones.go +++ b/services/vpn/v1alpha1api/model_update_vpn_gateway_payload_availability_zones.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ diff --git a/services/vpn/v1alpha1api/model_vpn_tunnel_plan.go b/services/vpn/v1alpha1api/model_vpn_tunnel_plan.go deleted file mode 100644 index bfe8a352f..000000000 --- a/services/vpn/v1alpha1api/model_vpn_tunnel_plan.go +++ /dev/null @@ -1,199 +0,0 @@ -/* -STACKIT VPN API - -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. - -API version: 1alpha1 -*/ - -// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. - -package v1alpha1api - -import ( - "encoding/json" -) - -// checks if the VPNTunnelPlan type satisfies the MappedNullable interface at compile time -var _ MappedNullable = &VPNTunnelPlan{} - -// VPNTunnelPlan struct for VPNTunnelPlan -type VPNTunnelPlan struct { - // Tunnel model name - Name *string `json:"name,omitempty"` - // Tunnel model region - Region *string `json:"region,omitempty"` - // Tunnel model SKU - Sku *string `json:"sku,omitempty"` -} - -// NewVPNTunnelPlan instantiates a new VPNTunnelPlan object -// This constructor will assign default values to properties that have it defined, -// and makes sure properties required by API are set, but the set of arguments -// will change when the set of required properties is changed -func NewVPNTunnelPlan() *VPNTunnelPlan { - this := VPNTunnelPlan{} - return &this -} - -// NewVPNTunnelPlanWithDefaults instantiates a new VPNTunnelPlan object -// This constructor will only assign default values to properties that have it defined, -// but it doesn't guarantee that properties required by API are set -func NewVPNTunnelPlanWithDefaults() *VPNTunnelPlan { - this := VPNTunnelPlan{} - return &this -} - -// GetName returns the Name field value if set, zero value otherwise. -func (o *VPNTunnelPlan) GetName() string { - if o == nil || IsNil(o.Name) { - var ret string - return ret - } - return *o.Name -} - -// GetNameOk returns a tuple with the Name field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VPNTunnelPlan) GetNameOk() (*string, bool) { - if o == nil || IsNil(o.Name) { - return nil, false - } - return o.Name, true -} - -// HasName returns a boolean if a field has been set. -func (o *VPNTunnelPlan) HasName() bool { - if o != nil && !IsNil(o.Name) { - return true - } - - return false -} - -// SetName gets a reference to the given string and assigns it to the Name field. -func (o *VPNTunnelPlan) SetName(v string) { - o.Name = &v -} - -// GetRegion returns the Region field value if set, zero value otherwise. -func (o *VPNTunnelPlan) GetRegion() string { - if o == nil || IsNil(o.Region) { - var ret string - return ret - } - return *o.Region -} - -// GetRegionOk returns a tuple with the Region field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VPNTunnelPlan) GetRegionOk() (*string, bool) { - if o == nil || IsNil(o.Region) { - return nil, false - } - return o.Region, true -} - -// HasRegion returns a boolean if a field has been set. -func (o *VPNTunnelPlan) HasRegion() bool { - if o != nil && !IsNil(o.Region) { - return true - } - - return false -} - -// SetRegion gets a reference to the given string and assigns it to the Region field. -func (o *VPNTunnelPlan) SetRegion(v string) { - o.Region = &v -} - -// GetSku returns the Sku field value if set, zero value otherwise. -func (o *VPNTunnelPlan) GetSku() string { - if o == nil || IsNil(o.Sku) { - var ret string - return ret - } - return *o.Sku -} - -// GetSkuOk returns a tuple with the Sku field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VPNTunnelPlan) GetSkuOk() (*string, bool) { - if o == nil || IsNil(o.Sku) { - return nil, false - } - return o.Sku, true -} - -// HasSku returns a boolean if a field has been set. -func (o *VPNTunnelPlan) HasSku() bool { - if o != nil && !IsNil(o.Sku) { - return true - } - - return false -} - -// SetSku gets a reference to the given string and assigns it to the Sku field. -func (o *VPNTunnelPlan) SetSku(v string) { - o.Sku = &v -} - -func (o VPNTunnelPlan) MarshalJSON() ([]byte, error) { - toSerialize, err := o.ToMap() - if err != nil { - return []byte{}, err - } - return json.Marshal(toSerialize) -} - -func (o VPNTunnelPlan) ToMap() (map[string]interface{}, error) { - toSerialize := map[string]interface{}{} - if !IsNil(o.Name) { - toSerialize["name"] = o.Name - } - if !IsNil(o.Region) { - toSerialize["region"] = o.Region - } - if !IsNil(o.Sku) { - toSerialize["sku"] = o.Sku - } - return toSerialize, nil -} - -type NullableVPNTunnelPlan struct { - value *VPNTunnelPlan - isSet bool -} - -func (v NullableVPNTunnelPlan) Get() *VPNTunnelPlan { - return v.value -} - -func (v *NullableVPNTunnelPlan) Set(val *VPNTunnelPlan) { - v.value = val - v.isSet = true -} - -func (v NullableVPNTunnelPlan) IsSet() bool { - return v.isSet -} - -func (v *NullableVPNTunnelPlan) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableVPNTunnelPlan(val *VPNTunnelPlan) *NullableVPNTunnelPlan { - return &NullableVPNTunnelPlan{value: val, isSet: true} -} - -func (v NullableVPNTunnelPlan) MarshalJSON() ([]byte, error) { - return json.Marshal(v.value) -} - -func (v *NullableVPNTunnelPlan) UnmarshalJSON(src []byte) error { - v.isSet = true - return json.Unmarshal(src, &v.value) -} diff --git a/services/vpn/v1alpha1api/model_vpn_tunnels.go b/services/vpn/v1alpha1api/model_vpn_tunnels.go index b3af302bf..61bac70d5 100644 --- a/services/vpn/v1alpha1api/model_vpn_tunnels.go +++ b/services/vpn/v1alpha1api/model_vpn_tunnels.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ @@ -17,12 +17,13 @@ import ( // checks if the VPNTunnels type satisfies the MappedNullable interface at compile time var _ MappedNullable = &VPNTunnels{} -// VPNTunnels List all available tunnels with public IP and status +// VPNTunnels Status of the underlying tunnel instances. type VPNTunnels struct { BgpStatus NullableBGPStatus `json:"bgpStatus,omitempty"` InstanceState *GatewayStatus `json:"instanceState,omitempty"` Name *string `json:"name,omitempty"` - PublicIP *string `json:"publicIP,omitempty"` + // The public IPv4 address of this endpoint. + PublicIP *string `json:"publicIP,omitempty"` } // NewVPNTunnels instantiates a new VPNTunnels object diff --git a/services/vpn/v1alpha1api/response.go b/services/vpn/v1alpha1api/response.go index e04a386ff..7d6060cd5 100644 --- a/services/vpn/v1alpha1api/response.go +++ b/services/vpn/v1alpha1api/response.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ diff --git a/services/vpn/v1alpha1api/utils.go b/services/vpn/v1alpha1api/utils.go index c715674be..4ed1fc3c6 100644 --- a/services/vpn/v1alpha1api/utils.go +++ b/services/vpn/v1alpha1api/utils.go @@ -1,7 +1,7 @@ /* STACKIT VPN API -The STACKIT VPN API provides endpoints to provision and manage VPN instances in your STACKIT project. +Provision and manage STACKIT VPN gateways. Use this API to establish secure, encrypted IPsec tunnels between your STACKIT Network Area (SNA) and external networks. The service supports the following routing architectures: - Policy-based IPsec - Static route-based IPsec - Dynamic BGP IPsec API version: 1alpha1 */ From 350ba08d74410f797d4b609fa6e9d00ddbeba027 Mon Sep 17 00:00:00 2001 From: Ruben Hoenle Date: Thu, 12 Mar 2026 09:19:01 +0100 Subject: [PATCH 2/2] changelogs --- CHANGELOG.md | 9 ++++++--- services/vpn/CHANGELOG.md | 3 +++ services/vpn/VERSION | 2 +- 3 files changed, 10 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 535e25d85..782d87eee 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -43,9 +43,12 @@ - `v3beta1api`: New package which can be used for communication with the sqlserverflex v3 beta1 API - **Deprecation:** The contents in the root of this SDK module including the `wait` package are marked as deprecated and will be removed after 2026-09-30. Switch to the new packages for the available API versions instead. - **Dependencies:** Bump STACKIT SDK core module from `v0.21.1` to `v0.22.0` -- `vpn`: [v0.1.0](services/vpn/CHANGELOG.md#v010) - - **New:** SDK module for vpn service - - `v1alpha1api`: New package which can be used for communication with the vpn v1 alpha1 API +- `vpn`: + - [v0.1.0](services/vpn/CHANGELOG.md#v010) + - **New:** SDK module for vpn service + - `v1alpha1api`: New package which can be used for communication with the vpn v1 alpha1 API + - [v0.2.0](services/vpn/CHANGELOG.md#v020) + - `v1alpha1api`: Align package to latest API specification - `postgresflex`: - [v1.4.0](services/postgresflex/CHANGELOG.md#v140) - **Feature:** Introduction of multi API version support for the postgresflex SDK module. For more details please see the announcement on GitHub: https://github.com/stackitcloud/stackit-sdk-go/discussions/5062 diff --git a/services/vpn/CHANGELOG.md b/services/vpn/CHANGELOG.md index ed30f175f..f1bc468df 100644 --- a/services/vpn/CHANGELOG.md +++ b/services/vpn/CHANGELOG.md @@ -1,3 +1,6 @@ +## v0.2.0 +- `v1alpha1api`: Align package to latest API specification + ## v0.1.0 - **New:** SDK module for vpn service - `v1alpha1api`: New package which can be used for communication with the vpn v1 alpha1 API diff --git a/services/vpn/VERSION b/services/vpn/VERSION index b82608c0b..1474d00f0 100644 --- a/services/vpn/VERSION +++ b/services/vpn/VERSION @@ -1 +1 @@ -v0.1.0 +v0.2.0