From 3320f3d0079df4024edd09d4bcc871a631ca3a5b Mon Sep 17 00:00:00 2001 From: "CTFang@WireLab" Date: Thu, 15 Aug 2024 02:58:12 +0000 Subject: [PATCH] feat: add BSF openapi --- .../api_individual_pcf_binding_document.go | 196 ++++++++ ...pcf_for_an_mbs_session_binding_document.go | 401 ++++++++++++++++ ...l_pcf_for_apdu_session_binding_document.go | 233 ++++++++++ ...individual_pcf_for_aue_binding_document.go | 399 ++++++++++++++++ .../api_individual_subscription_document.go | 401 ++++++++++++++++ bsf/Management/api_pcf_bindings_collection.go | 434 ++++++++++++++++++ ..._for_an_mbs_session_bindings_collection.go | 378 +++++++++++++++ .../api_pcf_for_aue_bindings_collection.go | 383 ++++++++++++++++ .../api_subscriptions_collection.go | 390 ++++++++++++++++ bsf/Management/client.go | 56 +++ bsf/Management/configuration.go | 82 ++++ models/model_binding_level.go | 21 + models/model_bsf_event.go | 25 + models/model_bsf_event_notification.go | 23 + ...odel_bsf_management_ext_problem_details.go | 38 ++ ..._bsf_management_mbs_ext_problem_details.go | 38 ++ models/model_bsf_notification.go | 26 ++ models/model_bsf_subscription.go | 32 ++ models/model_bsf_subscription_resp.go | 39 ++ models/model_parameter_combination.go | 22 + models/model_pcf_binding.go | 62 +++ models/model_pcf_binding_patch.go | 37 ++ models/model_pcf_for_pdu_session_info.go | 36 ++ models/model_pcf_for_ue_binding.go | 32 ++ models/model_pcf_for_ue_binding_patch.go | 23 + models/model_pcf_for_ue_info.go | 26 ++ models/model_pcf_mbs_binding.go | 34 ++ models/model_pcf_mbs_binding_patch.go | 22 + models/model_snssai_dnn_pair.go | 20 + 29 files changed, 3909 insertions(+) create mode 100644 bsf/Management/api_individual_pcf_binding_document.go create mode 100644 bsf/Management/api_individual_pcf_for_an_mbs_session_binding_document.go create mode 100644 bsf/Management/api_individual_pcf_for_apdu_session_binding_document.go create mode 100644 bsf/Management/api_individual_pcf_for_aue_binding_document.go create mode 100644 bsf/Management/api_individual_subscription_document.go create mode 100644 bsf/Management/api_pcf_bindings_collection.go create mode 100644 bsf/Management/api_pcf_for_an_mbs_session_bindings_collection.go create mode 100644 bsf/Management/api_pcf_for_aue_bindings_collection.go create mode 100644 bsf/Management/api_subscriptions_collection.go create mode 100644 bsf/Management/client.go create mode 100644 bsf/Management/configuration.go create mode 100644 models/model_binding_level.go create mode 100644 models/model_bsf_event.go create mode 100644 models/model_bsf_event_notification.go create mode 100644 models/model_bsf_management_ext_problem_details.go create mode 100644 models/model_bsf_management_mbs_ext_problem_details.go create mode 100644 models/model_bsf_notification.go create mode 100644 models/model_bsf_subscription.go create mode 100644 models/model_bsf_subscription_resp.go create mode 100644 models/model_parameter_combination.go create mode 100644 models/model_pcf_binding.go create mode 100644 models/model_pcf_binding_patch.go create mode 100644 models/model_pcf_for_pdu_session_info.go create mode 100644 models/model_pcf_for_ue_binding.go create mode 100644 models/model_pcf_for_ue_binding_patch.go create mode 100644 models/model_pcf_for_ue_info.go create mode 100644 models/model_pcf_mbs_binding.go create mode 100644 models/model_pcf_mbs_binding_patch.go create mode 100644 models/model_snssai_dnn_pair.go diff --git a/bsf/Management/api_individual_pcf_binding_document.go b/bsf/Management/api_individual_pcf_binding_document.go new file mode 100644 index 00000000..56e219fc --- /dev/null +++ b/bsf/Management/api_individual_pcf_binding_document.go @@ -0,0 +1,196 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package Management + +import ( + "github.com/free5gc/openapi" + "github.com/free5gc/openapi/models" + + "context" + "io/ioutil" + "net/url" + "strings" +) + +// Linger please +var ( + _ context.Context +) + +type IndividualPCFBindingDocumentApiService service + +/* +IndividualPCFBindingDocumentApiService Delete an existing Individual PCF for a PDU Session Binding information + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param BindingId - Represents the individual PCF for a PDU Session Binding. + +@return DeleteIndPCFBindingResponse +*/ + +// DeleteIndPCFBindingRequest +type DeleteIndPCFBindingRequest struct { + BindingId *string +} + +func (r *DeleteIndPCFBindingRequest) SetBindingId(BindingId string) { + r.BindingId = &BindingId +} + +type DeleteIndPCFBindingResponse struct { +} + +type DeleteIndPCFBindingError struct { + Location string + Var3gppSbiTargetNfId string + ProblemDetails models.ProblemDetails + RedirectResponse models.RedirectResponse +} + +func (a *IndividualPCFBindingDocumentApiService) DeleteIndPCFBinding(ctx context.Context, request *DeleteIndPCFBindingRequest) (*DeleteIndPCFBindingResponse, error) { + var ( + localVarHTTPMethod = strings.ToUpper("Delete") + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteIndPCFBindingResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath() + "/pcfBindings/{bindingId}" + localVarPath = strings.Replace(localVarPath, "{"+"bindingId"+"}", openapi.StringOfValue(*request.BindingId), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarHTTPContentTypes := []string{"application/json"} + + localVarHeaderParams["Content-Type"] = localVarHTTPContentTypes[0] // use the first content type specified in 'consumes' + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json", "application/problem+json"} + + // set Accept header + localVarHTTPHeaderAccept := strings.Join(localVarHTTPHeaderAccepts, ", ") + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + + r, err := openapi.PrepareRequest(ctx, a.client.cfg, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return nil, err + } + + localVarHTTPResponse, err := openapi.CallAPI(a.client.cfg, r) + if err != nil || localVarHTTPResponse == nil { + return nil, err + } + + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) + if err != nil { + return nil, err + } + err = localVarHTTPResponse.Body.Close() + if err != nil { + return nil, err + } + + apiError := openapi.GenericOpenAPIError{ + RawBody: localVarBody, + ErrorStatus: localVarHTTPResponse.StatusCode, + } + + switch localVarHTTPResponse.StatusCode { + case 204: + return &localVarReturnValue, nil + case 307: + var v DeleteIndPCFBindingError + err = openapi.Deserialize(&v.RedirectResponse, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + v.Location = localVarHTTPResponse.Header.Get("Location") + v.Var3gppSbiTargetNfId = localVarHTTPResponse.Header.Get("3gpp-Sbi-Target-Nf-Id") + apiError.ErrorModel = v + return nil, apiError + case 308: + var v DeleteIndPCFBindingError + err = openapi.Deserialize(&v.RedirectResponse, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + v.Location = localVarHTTPResponse.Header.Get("Location") + v.Var3gppSbiTargetNfId = localVarHTTPResponse.Header.Get("3gpp-Sbi-Target-Nf-Id") + apiError.ErrorModel = v + return nil, apiError + case 400: + var v DeleteIndPCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 401: + var v DeleteIndPCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 403: + var v DeleteIndPCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 404: + var v DeleteIndPCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 429: + var v DeleteIndPCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 500: + var v DeleteIndPCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 503: + var v DeleteIndPCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + default: + return nil, apiError + } +} diff --git a/bsf/Management/api_individual_pcf_for_an_mbs_session_binding_document.go b/bsf/Management/api_individual_pcf_for_an_mbs_session_binding_document.go new file mode 100644 index 00000000..0accae1a --- /dev/null +++ b/bsf/Management/api_individual_pcf_for_an_mbs_session_binding_document.go @@ -0,0 +1,401 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package Management + +import ( + "github.com/free5gc/openapi" + "github.com/free5gc/openapi/models" + + "context" + "io/ioutil" + "net/url" + "strings" +) + +// Linger please +var ( + _ context.Context +) + +type IndividualPCFForAnMBSSessionBindingDocumentApiService service + +/* +IndividualPCFForAnMBSSessionBindingDocumentApiService Request the deletion of an existing Individual PCF for an MBS Session Binding. + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param BindingId - Represents the identifier of the Individual PCF for an MBS Session Binding resource. + +@return DeleteIndPCFMbsBindingResponse +*/ + +// DeleteIndPCFMbsBindingRequest +type DeleteIndPCFMbsBindingRequest struct { + BindingId *string +} + +func (r *DeleteIndPCFMbsBindingRequest) SetBindingId(BindingId string) { + r.BindingId = &BindingId +} + +type DeleteIndPCFMbsBindingResponse struct { +} + +type DeleteIndPCFMbsBindingError struct { + Location string + Var3gppSbiTargetNfId string + ProblemDetails models.ProblemDetails + RedirectResponse models.RedirectResponse +} + +func (a *IndividualPCFForAnMBSSessionBindingDocumentApiService) DeleteIndPCFMbsBinding(ctx context.Context, request *DeleteIndPCFMbsBindingRequest) (*DeleteIndPCFMbsBindingResponse, error) { + var ( + localVarHTTPMethod = strings.ToUpper("Delete") + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteIndPCFMbsBindingResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath() + "/pcf-mbs-bindings/{bindingId}" + localVarPath = strings.Replace(localVarPath, "{"+"bindingId"+"}", openapi.StringOfValue(*request.BindingId), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarHTTPContentTypes := []string{"application/json"} + + localVarHeaderParams["Content-Type"] = localVarHTTPContentTypes[0] // use the first content type specified in 'consumes' + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json", "application/problem+json"} + + // set Accept header + localVarHTTPHeaderAccept := strings.Join(localVarHTTPHeaderAccepts, ", ") + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + + r, err := openapi.PrepareRequest(ctx, a.client.cfg, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return nil, err + } + + localVarHTTPResponse, err := openapi.CallAPI(a.client.cfg, r) + if err != nil || localVarHTTPResponse == nil { + return nil, err + } + + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) + if err != nil { + return nil, err + } + err = localVarHTTPResponse.Body.Close() + if err != nil { + return nil, err + } + + apiError := openapi.GenericOpenAPIError{ + RawBody: localVarBody, + ErrorStatus: localVarHTTPResponse.StatusCode, + } + + switch localVarHTTPResponse.StatusCode { + case 204: + return &localVarReturnValue, nil + case 307: + var v DeleteIndPCFMbsBindingError + err = openapi.Deserialize(&v.RedirectResponse, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + v.Location = localVarHTTPResponse.Header.Get("Location") + v.Var3gppSbiTargetNfId = localVarHTTPResponse.Header.Get("3gpp-Sbi-Target-Nf-Id") + apiError.ErrorModel = v + return nil, apiError + case 308: + var v DeleteIndPCFMbsBindingError + err = openapi.Deserialize(&v.RedirectResponse, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + v.Location = localVarHTTPResponse.Header.Get("Location") + v.Var3gppSbiTargetNfId = localVarHTTPResponse.Header.Get("3gpp-Sbi-Target-Nf-Id") + apiError.ErrorModel = v + return nil, apiError + case 400: + var v DeleteIndPCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 401: + var v DeleteIndPCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 403: + var v DeleteIndPCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 404: + var v DeleteIndPCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 429: + var v DeleteIndPCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 500: + var v DeleteIndPCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 503: + var v DeleteIndPCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + default: + return nil, apiError + } +} + +/* +IndividualPCFForAnMBSSessionBindingDocumentApiService Request the modification of an existing Individual PCF for an MBS Session Binding resource. + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param BindingId - Represents the identifier of the Individual PCF for an MBS Session Binding resource. + * @param PcfMbsBindingPatch - Parameters to request the modification of the PCF for an MBS Session Binding. + +@return ModifyIndPCFMbsBindingResponse +*/ + +// ModifyIndPCFMbsBindingRequest +type ModifyIndPCFMbsBindingRequest struct { + BindingId *string + PcfMbsBindingPatch *models.PcfMbsBindingPatch +} + +func (r *ModifyIndPCFMbsBindingRequest) SetBindingId(BindingId string) { + r.BindingId = &BindingId +} +func (r *ModifyIndPCFMbsBindingRequest) SetPcfMbsBindingPatch(PcfMbsBindingPatch models.PcfMbsBindingPatch) { + r.PcfMbsBindingPatch = &PcfMbsBindingPatch +} + +type ModifyIndPCFMbsBindingResponse struct { + PcfMbsBinding models.PcfMbsBinding +} + +type ModifyIndPCFMbsBindingError struct { + Location string + Var3gppSbiTargetNfId string + ProblemDetails models.ProblemDetails + RedirectResponse models.RedirectResponse +} + +func (a *IndividualPCFForAnMBSSessionBindingDocumentApiService) ModifyIndPCFMbsBinding(ctx context.Context, request *ModifyIndPCFMbsBindingRequest) (*ModifyIndPCFMbsBindingResponse, error) { + var ( + localVarHTTPMethod = strings.ToUpper("Patch") + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ModifyIndPCFMbsBindingResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath() + "/pcf-mbs-bindings/{bindingId}" + localVarPath = strings.Replace(localVarPath, "{"+"bindingId"+"}", openapi.StringOfValue(*request.BindingId), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarHTTPContentTypes := []string{"application/merge-patch+json"} + + localVarHeaderParams["Content-Type"] = localVarHTTPContentTypes[0] // use the first content type specified in 'consumes' + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json", "application/problem+json"} + + // set Accept header + localVarHTTPHeaderAccept := strings.Join(localVarHTTPHeaderAccepts, ", ") + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + + // body params + localVarPostBody = request.PcfMbsBindingPatch + + r, err := openapi.PrepareRequest(ctx, a.client.cfg, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return nil, err + } + + localVarHTTPResponse, err := openapi.CallAPI(a.client.cfg, r) + if err != nil || localVarHTTPResponse == nil { + return nil, err + } + + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) + if err != nil { + return nil, err + } + err = localVarHTTPResponse.Body.Close() + if err != nil { + return nil, err + } + + apiError := openapi.GenericOpenAPIError{ + RawBody: localVarBody, + ErrorStatus: localVarHTTPResponse.StatusCode, + } + + switch localVarHTTPResponse.StatusCode { + case 200: + err = openapi.Deserialize(&localVarReturnValue.PcfMbsBinding, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + return &localVarReturnValue, nil + case 204: + return &localVarReturnValue, nil + case 307: + var v ModifyIndPCFMbsBindingError + err = openapi.Deserialize(&v.RedirectResponse, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + v.Location = localVarHTTPResponse.Header.Get("Location") + v.Var3gppSbiTargetNfId = localVarHTTPResponse.Header.Get("3gpp-Sbi-Target-Nf-Id") + apiError.ErrorModel = v + return nil, apiError + case 308: + var v ModifyIndPCFMbsBindingError + err = openapi.Deserialize(&v.RedirectResponse, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + v.Location = localVarHTTPResponse.Header.Get("Location") + v.Var3gppSbiTargetNfId = localVarHTTPResponse.Header.Get("3gpp-Sbi-Target-Nf-Id") + apiError.ErrorModel = v + return nil, apiError + case 400: + var v ModifyIndPCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 401: + var v ModifyIndPCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 403: + var v ModifyIndPCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 404: + var v ModifyIndPCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 411: + var v ModifyIndPCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 413: + var v ModifyIndPCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 415: + var v ModifyIndPCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 429: + var v ModifyIndPCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 500: + var v ModifyIndPCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 503: + var v ModifyIndPCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + default: + return nil, apiError + } +} diff --git a/bsf/Management/api_individual_pcf_for_apdu_session_binding_document.go b/bsf/Management/api_individual_pcf_for_apdu_session_binding_document.go new file mode 100644 index 00000000..98e67425 --- /dev/null +++ b/bsf/Management/api_individual_pcf_for_apdu_session_binding_document.go @@ -0,0 +1,233 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package Management + +import ( + "github.com/free5gc/openapi" + "github.com/free5gc/openapi/models" + + "context" + "io/ioutil" + "net/url" + "strings" +) + +// Linger please +var ( + _ context.Context +) + +type IndividualPCFForAPDUSessionBindingDocumentApiService service + +/* +IndividualPCFForAPDUSessionBindingDocumentApiService Update an existing Individual PCF for a PDU Session Binding information + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param BindingId - Represents the individual PCF for a PDU Session Binding. + * @param PcfBindingPatch - Parameters to update the existing PCF for a PDU Session binding. + +@return UpdateIndPCFBindingResponse +*/ + +// UpdateIndPCFBindingRequest +type UpdateIndPCFBindingRequest struct { + BindingId *string + PcfBindingPatch *models.PcfBindingPatch +} + +func (r *UpdateIndPCFBindingRequest) SetBindingId(BindingId string) { + r.BindingId = &BindingId +} +func (r *UpdateIndPCFBindingRequest) SetPcfBindingPatch(PcfBindingPatch models.PcfBindingPatch) { + r.PcfBindingPatch = &PcfBindingPatch +} + +type UpdateIndPCFBindingResponse struct { + PcfBinding models.PcfBinding +} + +type UpdateIndPCFBindingError struct { + Location string + Var3gppSbiTargetNfId string + ProblemDetails models.ProblemDetails + RedirectResponse models.RedirectResponse +} + +func (a *IndividualPCFForAPDUSessionBindingDocumentApiService) UpdateIndPCFBinding(ctx context.Context, request *UpdateIndPCFBindingRequest) (*UpdateIndPCFBindingResponse, error) { + var ( + localVarHTTPMethod = strings.ToUpper("Patch") + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue UpdateIndPCFBindingResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath() + "/pcfBindings/{bindingId}" + localVarPath = strings.Replace(localVarPath, "{"+"bindingId"+"}", openapi.StringOfValue(*request.BindingId), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarHTTPContentTypes := []string{"application/merge-patch+json"} + + localVarHeaderParams["Content-Type"] = localVarHTTPContentTypes[0] // use the first content type specified in 'consumes' + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json", "application/problem+json"} + + // set Accept header + localVarHTTPHeaderAccept := strings.Join(localVarHTTPHeaderAccepts, ", ") + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + + // body params + localVarPostBody = request.PcfBindingPatch + + r, err := openapi.PrepareRequest(ctx, a.client.cfg, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return nil, err + } + + localVarHTTPResponse, err := openapi.CallAPI(a.client.cfg, r) + if err != nil || localVarHTTPResponse == nil { + return nil, err + } + + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) + if err != nil { + return nil, err + } + err = localVarHTTPResponse.Body.Close() + if err != nil { + return nil, err + } + + apiError := openapi.GenericOpenAPIError{ + RawBody: localVarBody, + ErrorStatus: localVarHTTPResponse.StatusCode, + } + + switch localVarHTTPResponse.StatusCode { + case 200: + err = openapi.Deserialize(&localVarReturnValue.PcfBinding, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + return &localVarReturnValue, nil + case 307: + var v UpdateIndPCFBindingError + err = openapi.Deserialize(&v.RedirectResponse, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + v.Location = localVarHTTPResponse.Header.Get("Location") + v.Var3gppSbiTargetNfId = localVarHTTPResponse.Header.Get("3gpp-Sbi-Target-Nf-Id") + apiError.ErrorModel = v + return nil, apiError + case 308: + var v UpdateIndPCFBindingError + err = openapi.Deserialize(&v.RedirectResponse, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + v.Location = localVarHTTPResponse.Header.Get("Location") + v.Var3gppSbiTargetNfId = localVarHTTPResponse.Header.Get("3gpp-Sbi-Target-Nf-Id") + apiError.ErrorModel = v + return nil, apiError + case 400: + var v UpdateIndPCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 401: + var v UpdateIndPCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 403: + var v UpdateIndPCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 404: + var v UpdateIndPCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 411: + var v UpdateIndPCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 413: + var v UpdateIndPCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 415: + var v UpdateIndPCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 429: + var v UpdateIndPCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 500: + var v UpdateIndPCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 503: + var v UpdateIndPCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + default: + return nil, apiError + } +} diff --git a/bsf/Management/api_individual_pcf_for_aue_binding_document.go b/bsf/Management/api_individual_pcf_for_aue_binding_document.go new file mode 100644 index 00000000..1c417531 --- /dev/null +++ b/bsf/Management/api_individual_pcf_for_aue_binding_document.go @@ -0,0 +1,399 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package Management + +import ( + "github.com/free5gc/openapi" + "github.com/free5gc/openapi/models" + + "context" + "io/ioutil" + "net/url" + "strings" +) + +// Linger please +var ( + _ context.Context +) + +type IndividualPCFForAUEBindingDocumentApiService service + +/* +IndividualPCFForAUEBindingDocumentApiService Delete an existing Individual PCF for a UE Binding information + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param BindingId - Represents the individual PCF for a UE Binding. + +@return DeleteIndPCFforUEBindingResponse +*/ + +// DeleteIndPCFforUEBindingRequest +type DeleteIndPCFforUEBindingRequest struct { + BindingId *string +} + +func (r *DeleteIndPCFforUEBindingRequest) SetBindingId(BindingId string) { + r.BindingId = &BindingId +} + +type DeleteIndPCFforUEBindingResponse struct { +} + +type DeleteIndPCFforUEBindingError struct { + Location string + Var3gppSbiTargetNfId string + ProblemDetails models.ProblemDetails + RedirectResponse models.RedirectResponse +} + +func (a *IndividualPCFForAUEBindingDocumentApiService) DeleteIndPCFforUEBinding(ctx context.Context, request *DeleteIndPCFforUEBindingRequest) (*DeleteIndPCFforUEBindingResponse, error) { + var ( + localVarHTTPMethod = strings.ToUpper("Delete") + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteIndPCFforUEBindingResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath() + "/pcf-ue-bindings/{bindingId}" + localVarPath = strings.Replace(localVarPath, "{"+"bindingId"+"}", openapi.StringOfValue(*request.BindingId), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarHTTPContentTypes := []string{"application/json"} + + localVarHeaderParams["Content-Type"] = localVarHTTPContentTypes[0] // use the first content type specified in 'consumes' + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json", "application/problem+json"} + + // set Accept header + localVarHTTPHeaderAccept := strings.Join(localVarHTTPHeaderAccepts, ", ") + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + + r, err := openapi.PrepareRequest(ctx, a.client.cfg, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return nil, err + } + + localVarHTTPResponse, err := openapi.CallAPI(a.client.cfg, r) + if err != nil || localVarHTTPResponse == nil { + return nil, err + } + + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) + if err != nil { + return nil, err + } + err = localVarHTTPResponse.Body.Close() + if err != nil { + return nil, err + } + + apiError := openapi.GenericOpenAPIError{ + RawBody: localVarBody, + ErrorStatus: localVarHTTPResponse.StatusCode, + } + + switch localVarHTTPResponse.StatusCode { + case 204: + return &localVarReturnValue, nil + case 307: + var v DeleteIndPCFforUEBindingError + err = openapi.Deserialize(&v.RedirectResponse, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + v.Location = localVarHTTPResponse.Header.Get("Location") + v.Var3gppSbiTargetNfId = localVarHTTPResponse.Header.Get("3gpp-Sbi-Target-Nf-Id") + apiError.ErrorModel = v + return nil, apiError + case 308: + var v DeleteIndPCFforUEBindingError + err = openapi.Deserialize(&v.RedirectResponse, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + v.Location = localVarHTTPResponse.Header.Get("Location") + v.Var3gppSbiTargetNfId = localVarHTTPResponse.Header.Get("3gpp-Sbi-Target-Nf-Id") + apiError.ErrorModel = v + return nil, apiError + case 400: + var v DeleteIndPCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 401: + var v DeleteIndPCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 403: + var v DeleteIndPCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 404: + var v DeleteIndPCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 429: + var v DeleteIndPCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 500: + var v DeleteIndPCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 503: + var v DeleteIndPCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + default: + return nil, apiError + } +} + +/* +IndividualPCFForAUEBindingDocumentApiService Update an existing Individual PCF for a UE Binding information + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param BindingId - Represents the individual PCF for a UE Binding. + * @param PcfForUeBindingPatch - Parameters to update the existing PCF for a UE binding. + +@return UpdateIndPCFforUEBindingResponse +*/ + +// UpdateIndPCFforUEBindingRequest +type UpdateIndPCFforUEBindingRequest struct { + BindingId *string + PcfForUeBindingPatch *models.PcfForUeBindingPatch +} + +func (r *UpdateIndPCFforUEBindingRequest) SetBindingId(BindingId string) { + r.BindingId = &BindingId +} +func (r *UpdateIndPCFforUEBindingRequest) SetPcfForUeBindingPatch(PcfForUeBindingPatch models.PcfForUeBindingPatch) { + r.PcfForUeBindingPatch = &PcfForUeBindingPatch +} + +type UpdateIndPCFforUEBindingResponse struct { + PcfForUeBinding models.PcfForUeBinding +} + +type UpdateIndPCFforUEBindingError struct { + Location string + Var3gppSbiTargetNfId string + ProblemDetails models.ProblemDetails + RedirectResponse models.RedirectResponse +} + +func (a *IndividualPCFForAUEBindingDocumentApiService) UpdateIndPCFforUEBinding(ctx context.Context, request *UpdateIndPCFforUEBindingRequest) (*UpdateIndPCFforUEBindingResponse, error) { + var ( + localVarHTTPMethod = strings.ToUpper("Patch") + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue UpdateIndPCFforUEBindingResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath() + "/pcf-ue-bindings/{bindingId}" + localVarPath = strings.Replace(localVarPath, "{"+"bindingId"+"}", openapi.StringOfValue(*request.BindingId), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarHTTPContentTypes := []string{"application/merge-patch+json"} + + localVarHeaderParams["Content-Type"] = localVarHTTPContentTypes[0] // use the first content type specified in 'consumes' + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json", "application/problem+json"} + + // set Accept header + localVarHTTPHeaderAccept := strings.Join(localVarHTTPHeaderAccepts, ", ") + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + + // body params + localVarPostBody = request.PcfForUeBindingPatch + + r, err := openapi.PrepareRequest(ctx, a.client.cfg, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return nil, err + } + + localVarHTTPResponse, err := openapi.CallAPI(a.client.cfg, r) + if err != nil || localVarHTTPResponse == nil { + return nil, err + } + + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) + if err != nil { + return nil, err + } + err = localVarHTTPResponse.Body.Close() + if err != nil { + return nil, err + } + + apiError := openapi.GenericOpenAPIError{ + RawBody: localVarBody, + ErrorStatus: localVarHTTPResponse.StatusCode, + } + + switch localVarHTTPResponse.StatusCode { + case 200: + err = openapi.Deserialize(&localVarReturnValue.PcfForUeBinding, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + return &localVarReturnValue, nil + case 307: + var v UpdateIndPCFforUEBindingError + err = openapi.Deserialize(&v.RedirectResponse, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + v.Location = localVarHTTPResponse.Header.Get("Location") + v.Var3gppSbiTargetNfId = localVarHTTPResponse.Header.Get("3gpp-Sbi-Target-Nf-Id") + apiError.ErrorModel = v + return nil, apiError + case 308: + var v UpdateIndPCFforUEBindingError + err = openapi.Deserialize(&v.RedirectResponse, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + v.Location = localVarHTTPResponse.Header.Get("Location") + v.Var3gppSbiTargetNfId = localVarHTTPResponse.Header.Get("3gpp-Sbi-Target-Nf-Id") + apiError.ErrorModel = v + return nil, apiError + case 400: + var v UpdateIndPCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 401: + var v UpdateIndPCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 403: + var v UpdateIndPCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 404: + var v UpdateIndPCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 411: + var v UpdateIndPCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 413: + var v UpdateIndPCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 415: + var v UpdateIndPCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 429: + var v UpdateIndPCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 500: + var v UpdateIndPCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 503: + var v UpdateIndPCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + default: + return nil, apiError + } +} diff --git a/bsf/Management/api_individual_subscription_document.go b/bsf/Management/api_individual_subscription_document.go new file mode 100644 index 00000000..fe3237f8 --- /dev/null +++ b/bsf/Management/api_individual_subscription_document.go @@ -0,0 +1,401 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package Management + +import ( + "github.com/free5gc/openapi" + "github.com/free5gc/openapi/models" + + "context" + "io/ioutil" + "net/url" + "strings" +) + +// Linger please +var ( + _ context.Context +) + +type IndividualSubscriptionDocumentApiService service + +/* +IndividualSubscriptionDocumentApiService Delete an individual subscription for event notifications from the BSF + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param SubId - Subscription correlation ID + +@return DeleteIndividualSubcriptionResponse +*/ + +// DeleteIndividualSubcriptionRequest +type DeleteIndividualSubcriptionRequest struct { + SubId *string +} + +func (r *DeleteIndividualSubcriptionRequest) SetSubId(SubId string) { + r.SubId = &SubId +} + +type DeleteIndividualSubcriptionResponse struct { +} + +type DeleteIndividualSubcriptionError struct { + Location string + Var3gppSbiTargetNfId string + ProblemDetails models.ProblemDetails + RedirectResponse models.RedirectResponse +} + +func (a *IndividualSubscriptionDocumentApiService) DeleteIndividualSubcription(ctx context.Context, request *DeleteIndividualSubcriptionRequest) (*DeleteIndividualSubcriptionResponse, error) { + var ( + localVarHTTPMethod = strings.ToUpper("Delete") + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteIndividualSubcriptionResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath() + "/subscriptions/{subId}" + localVarPath = strings.Replace(localVarPath, "{"+"subId"+"}", openapi.StringOfValue(*request.SubId), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarHTTPContentTypes := []string{"application/json"} + + localVarHeaderParams["Content-Type"] = localVarHTTPContentTypes[0] // use the first content type specified in 'consumes' + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json", "application/problem+json"} + + // set Accept header + localVarHTTPHeaderAccept := strings.Join(localVarHTTPHeaderAccepts, ", ") + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + + r, err := openapi.PrepareRequest(ctx, a.client.cfg, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return nil, err + } + + localVarHTTPResponse, err := openapi.CallAPI(a.client.cfg, r) + if err != nil || localVarHTTPResponse == nil { + return nil, err + } + + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) + if err != nil { + return nil, err + } + err = localVarHTTPResponse.Body.Close() + if err != nil { + return nil, err + } + + apiError := openapi.GenericOpenAPIError{ + RawBody: localVarBody, + ErrorStatus: localVarHTTPResponse.StatusCode, + } + + switch localVarHTTPResponse.StatusCode { + case 204: + return &localVarReturnValue, nil + case 307: + var v DeleteIndividualSubcriptionError + err = openapi.Deserialize(&v.RedirectResponse, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + v.Location = localVarHTTPResponse.Header.Get("Location") + v.Var3gppSbiTargetNfId = localVarHTTPResponse.Header.Get("3gpp-Sbi-Target-Nf-Id") + apiError.ErrorModel = v + return nil, apiError + case 308: + var v DeleteIndividualSubcriptionError + err = openapi.Deserialize(&v.RedirectResponse, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + v.Location = localVarHTTPResponse.Header.Get("Location") + v.Var3gppSbiTargetNfId = localVarHTTPResponse.Header.Get("3gpp-Sbi-Target-Nf-Id") + apiError.ErrorModel = v + return nil, apiError + case 400: + var v DeleteIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 401: + var v DeleteIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 403: + var v DeleteIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 404: + var v DeleteIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 429: + var v DeleteIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 500: + var v DeleteIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 503: + var v DeleteIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + default: + return nil, apiError + } +} + +/* +IndividualSubscriptionDocumentApiService Replace an individual subscription for event notifications from the BSF + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param SubId - Subscription correlation ID + * @param BsfSubscription - + +@return ReplaceIndividualSubcriptionResponse +*/ + +// ReplaceIndividualSubcriptionRequest +type ReplaceIndividualSubcriptionRequest struct { + SubId *string + BsfSubscription *models.BsfSubscription +} + +func (r *ReplaceIndividualSubcriptionRequest) SetSubId(SubId string) { + r.SubId = &SubId +} +func (r *ReplaceIndividualSubcriptionRequest) SetBsfSubscription(BsfSubscription models.BsfSubscription) { + r.BsfSubscription = &BsfSubscription +} + +type ReplaceIndividualSubcriptionResponse struct { + BsfSubscriptionResp models.BsfSubscriptionResp +} + +type ReplaceIndividualSubcriptionError struct { + Location string + Var3gppSbiTargetNfId string + ProblemDetails models.ProblemDetails + RedirectResponse models.RedirectResponse +} + +func (a *IndividualSubscriptionDocumentApiService) ReplaceIndividualSubcription(ctx context.Context, request *ReplaceIndividualSubcriptionRequest) (*ReplaceIndividualSubcriptionResponse, error) { + var ( + localVarHTTPMethod = strings.ToUpper("Put") + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReplaceIndividualSubcriptionResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath() + "/subscriptions/{subId}" + localVarPath = strings.Replace(localVarPath, "{"+"subId"+"}", openapi.StringOfValue(*request.SubId), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarHTTPContentTypes := []string{"application/json"} + + localVarHeaderParams["Content-Type"] = localVarHTTPContentTypes[0] // use the first content type specified in 'consumes' + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json", "application/problem+json"} + + // set Accept header + localVarHTTPHeaderAccept := strings.Join(localVarHTTPHeaderAccepts, ", ") + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + + // body params + localVarPostBody = request.BsfSubscription + + r, err := openapi.PrepareRequest(ctx, a.client.cfg, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return nil, err + } + + localVarHTTPResponse, err := openapi.CallAPI(a.client.cfg, r) + if err != nil || localVarHTTPResponse == nil { + return nil, err + } + + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) + if err != nil { + return nil, err + } + err = localVarHTTPResponse.Body.Close() + if err != nil { + return nil, err + } + + apiError := openapi.GenericOpenAPIError{ + RawBody: localVarBody, + ErrorStatus: localVarHTTPResponse.StatusCode, + } + + switch localVarHTTPResponse.StatusCode { + case 200: + err = openapi.Deserialize(&localVarReturnValue.BsfSubscriptionResp, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + return &localVarReturnValue, nil + case 204: + return &localVarReturnValue, nil + case 307: + var v ReplaceIndividualSubcriptionError + err = openapi.Deserialize(&v.RedirectResponse, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + v.Location = localVarHTTPResponse.Header.Get("Location") + v.Var3gppSbiTargetNfId = localVarHTTPResponse.Header.Get("3gpp-Sbi-Target-Nf-Id") + apiError.ErrorModel = v + return nil, apiError + case 308: + var v ReplaceIndividualSubcriptionError + err = openapi.Deserialize(&v.RedirectResponse, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + v.Location = localVarHTTPResponse.Header.Get("Location") + v.Var3gppSbiTargetNfId = localVarHTTPResponse.Header.Get("3gpp-Sbi-Target-Nf-Id") + apiError.ErrorModel = v + return nil, apiError + case 400: + var v ReplaceIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 401: + var v ReplaceIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 403: + var v ReplaceIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 404: + var v ReplaceIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 411: + var v ReplaceIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 413: + var v ReplaceIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 415: + var v ReplaceIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 429: + var v ReplaceIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 500: + var v ReplaceIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 503: + var v ReplaceIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + default: + return nil, apiError + } +} diff --git a/bsf/Management/api_pcf_bindings_collection.go b/bsf/Management/api_pcf_bindings_collection.go new file mode 100644 index 00000000..374822cd --- /dev/null +++ b/bsf/Management/api_pcf_bindings_collection.go @@ -0,0 +1,434 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package Management + +import ( + "github.com/free5gc/openapi" + "github.com/free5gc/openapi/models" + + "context" + "io/ioutil" + "net/url" + "strings" +) + +// Linger please +var ( + _ context.Context +) + +type PCFBindingsCollectionApiService service + +/* +PCFBindingsCollectionApiService Create a new Individual PCF for a PDU Session binding information + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param PcfBinding - + +@return CreatePCFBindingResponse +*/ + +// CreatePCFBindingRequest +type CreatePCFBindingRequest struct { + PcfBinding *models.PcfBinding +} + +func (r *CreatePCFBindingRequest) SetPcfBinding(PcfBinding models.PcfBinding) { + r.PcfBinding = &PcfBinding +} + +type CreatePCFBindingResponse struct { + Location string + PcfBinding models.PcfBinding +} + +type CreatePCFBindingError struct { + BsfManagementExtProblemDetails models.BsfManagementExtProblemDetails + ProblemDetails models.ProblemDetails +} + +func (a *PCFBindingsCollectionApiService) CreatePCFBinding(ctx context.Context, request *CreatePCFBindingRequest) (*CreatePCFBindingResponse, error) { + var ( + localVarHTTPMethod = strings.ToUpper("Post") + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreatePCFBindingResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath() + "/pcfBindings" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarHTTPContentTypes := []string{"application/json"} + + localVarHeaderParams["Content-Type"] = localVarHTTPContentTypes[0] // use the first content type specified in 'consumes' + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json", "application/problem+json"} + + // set Accept header + localVarHTTPHeaderAccept := strings.Join(localVarHTTPHeaderAccepts, ", ") + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + + // body params + localVarPostBody = request.PcfBinding + + r, err := openapi.PrepareRequest(ctx, a.client.cfg, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return nil, err + } + + localVarHTTPResponse, err := openapi.CallAPI(a.client.cfg, r) + if err != nil || localVarHTTPResponse == nil { + return nil, err + } + + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) + if err != nil { + return nil, err + } + err = localVarHTTPResponse.Body.Close() + if err != nil { + return nil, err + } + + apiError := openapi.GenericOpenAPIError{ + RawBody: localVarBody, + ErrorStatus: localVarHTTPResponse.StatusCode, + } + + switch localVarHTTPResponse.StatusCode { + case 201: + err = openapi.Deserialize(&localVarReturnValue.PcfBinding, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + localVarReturnValue.Location = localVarHTTPResponse.Header.Get("Location") + return &localVarReturnValue, nil + case 400: + var v CreatePCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 401: + var v CreatePCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 403: + var v CreatePCFBindingError + err = openapi.Deserialize(&v.BsfManagementExtProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 404: + var v CreatePCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 411: + var v CreatePCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 413: + var v CreatePCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 415: + var v CreatePCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 429: + var v CreatePCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 500: + var v CreatePCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 503: + var v CreatePCFBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + default: + return nil, apiError + } +} + +/* +PCFBindingsCollectionApiService Read PCF for a PDU Session Bindings information + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param Ipv4Addr - The IPv4 Address of the served UE. + * @param Ipv6Prefix - The IPv6 Address of the served UE. The NF service consumer shall append '/128' to the IPv6 address in the attribute value. E.g. '2001:db8:85a3::8a2e:370:7334/128'. + * @param MacAddr48 - The MAC Address of the served UE. + * @param Dnn - DNN. + * @param Supi - Subscription Permanent Identifier. + * @param Gpsi - Generic Public Subscription Identifier + * @param Snssai - The identification of slice. + * @param IpDomain - The IPv4 address domain identifier. + * @param SuppFeat - To filter irrelevant responses related to unsupported features. + +@return GetPCFBindingsResponse +*/ + +// GetPCFBindingsRequest +type GetPCFBindingsRequest struct { + Ipv4Addr *string + Ipv6Prefix *string + MacAddr48 *string + Dnn *string + Supi *string + Gpsi *string + Snssai *models.Snssai + IpDomain *string + SuppFeat *string +} + +func (r *GetPCFBindingsRequest) SetIpv4Addr(Ipv4Addr string) { + r.Ipv4Addr = &Ipv4Addr +} +func (r *GetPCFBindingsRequest) SetIpv6Prefix(Ipv6Prefix string) { + r.Ipv6Prefix = &Ipv6Prefix +} +func (r *GetPCFBindingsRequest) SetMacAddr48(MacAddr48 string) { + r.MacAddr48 = &MacAddr48 +} +func (r *GetPCFBindingsRequest) SetDnn(Dnn string) { + r.Dnn = &Dnn +} +func (r *GetPCFBindingsRequest) SetSupi(Supi string) { + r.Supi = &Supi +} +func (r *GetPCFBindingsRequest) SetGpsi(Gpsi string) { + r.Gpsi = &Gpsi +} +func (r *GetPCFBindingsRequest) SetSnssai(Snssai models.Snssai) { + r.Snssai = &Snssai +} +func (r *GetPCFBindingsRequest) SetIpDomain(IpDomain string) { + r.IpDomain = &IpDomain +} +func (r *GetPCFBindingsRequest) SetSuppFeat(SuppFeat string) { + r.SuppFeat = &SuppFeat +} + +type GetPCFBindingsResponse struct { + PcfBinding models.PcfBinding +} + +type GetPCFBindingsError struct { + ProblemDetails models.ProblemDetails +} + +func (a *PCFBindingsCollectionApiService) GetPCFBindings(ctx context.Context, request *GetPCFBindingsRequest) (*GetPCFBindingsResponse, error) { + var ( + localVarHTTPMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue GetPCFBindingsResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath() + "/pcfBindings" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if request.Ipv4Addr != nil { + localVarQueryParams.Add("ipv4Addr", openapi.ParameterToString(request.Ipv4Addr, "multi")) + } + if request.Ipv6Prefix != nil { + localVarQueryParams.Add("ipv6Prefix", openapi.ParameterToString(request.Ipv6Prefix, "multi")) + } + if request.MacAddr48 != nil { + localVarQueryParams.Add("macAddr48", openapi.ParameterToString(request.MacAddr48, "multi")) + } + if request.Dnn != nil { + localVarQueryParams.Add("dnn", openapi.ParameterToString(request.Dnn, "multi")) + } + if request.Supi != nil { + localVarQueryParams.Add("supi", openapi.ParameterToString(request.Supi, "multi")) + } + if request.Gpsi != nil { + localVarQueryParams.Add("gpsi", openapi.ParameterToString(request.Gpsi, "multi")) + } + if request.Snssai != nil { + localVarQueryParams.Add("snssai", openapi.ParameterToString(request.Snssai, "application/json")) + } + if request.IpDomain != nil { + localVarQueryParams.Add("ipDomain", openapi.ParameterToString(request.IpDomain, "multi")) + } + if request.SuppFeat != nil { + localVarQueryParams.Add("supp-feat", openapi.ParameterToString(request.SuppFeat, "multi")) + } + + localVarHTTPContentTypes := []string{"application/json"} + + localVarHeaderParams["Content-Type"] = localVarHTTPContentTypes[0] // use the first content type specified in 'consumes' + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json", "application/problem+json"} + + // set Accept header + localVarHTTPHeaderAccept := strings.Join(localVarHTTPHeaderAccepts, ", ") + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + + r, err := openapi.PrepareRequest(ctx, a.client.cfg, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return nil, err + } + + localVarHTTPResponse, err := openapi.CallAPI(a.client.cfg, r) + if err != nil || localVarHTTPResponse == nil { + return nil, err + } + + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) + if err != nil { + return nil, err + } + err = localVarHTTPResponse.Body.Close() + if err != nil { + return nil, err + } + + apiError := openapi.GenericOpenAPIError{ + RawBody: localVarBody, + ErrorStatus: localVarHTTPResponse.StatusCode, + } + + switch localVarHTTPResponse.StatusCode { + case 200: + err = openapi.Deserialize(&localVarReturnValue.PcfBinding, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + return &localVarReturnValue, nil + case 204: + return &localVarReturnValue, nil + case 400: + var v GetPCFBindingsError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 401: + var v GetPCFBindingsError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 403: + var v GetPCFBindingsError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 404: + var v GetPCFBindingsError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 406: + return &localVarReturnValue, nil + case 414: + var v GetPCFBindingsError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 429: + var v GetPCFBindingsError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 500: + var v GetPCFBindingsError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 503: + var v GetPCFBindingsError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + default: + return nil, apiError + } +} diff --git a/bsf/Management/api_pcf_for_an_mbs_session_bindings_collection.go b/bsf/Management/api_pcf_for_an_mbs_session_bindings_collection.go new file mode 100644 index 00000000..60a415c4 --- /dev/null +++ b/bsf/Management/api_pcf_for_an_mbs_session_bindings_collection.go @@ -0,0 +1,378 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package Management + +import ( + "github.com/free5gc/openapi" + "github.com/free5gc/openapi/models" + + "context" + "io/ioutil" + "net/url" + "strings" +) + +// Linger please +var ( + _ context.Context +) + +type PCFForAnMBSSessionBindingsCollectionApiService service + +/* +PCFForAnMBSSessionBindingsCollectionApiService Create a new Individual PCF for an MBS Session binding. + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param PcfMbsBinding - + +@return CreatePCFMbsBindingResponse +*/ + +// CreatePCFMbsBindingRequest +type CreatePCFMbsBindingRequest struct { + PcfMbsBinding *models.PcfMbsBinding +} + +func (r *CreatePCFMbsBindingRequest) SetPcfMbsBinding(PcfMbsBinding models.PcfMbsBinding) { + r.PcfMbsBinding = &PcfMbsBinding +} + +type CreatePCFMbsBindingResponse struct { + Location string + PcfMbsBinding models.PcfMbsBinding +} + +type CreatePCFMbsBindingError struct { + BsfManagementMbsExtProblemDetails models.BsfManagementMbsExtProblemDetails + ProblemDetails models.ProblemDetails +} + +func (a *PCFForAnMBSSessionBindingsCollectionApiService) CreatePCFMbsBinding(ctx context.Context, request *CreatePCFMbsBindingRequest) (*CreatePCFMbsBindingResponse, error) { + var ( + localVarHTTPMethod = strings.ToUpper("Post") + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreatePCFMbsBindingResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath() + "/pcf-mbs-bindings" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarHTTPContentTypes := []string{"application/json"} + + localVarHeaderParams["Content-Type"] = localVarHTTPContentTypes[0] // use the first content type specified in 'consumes' + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json", "application/problem+json"} + + // set Accept header + localVarHTTPHeaderAccept := strings.Join(localVarHTTPHeaderAccepts, ", ") + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + + // body params + localVarPostBody = request.PcfMbsBinding + + r, err := openapi.PrepareRequest(ctx, a.client.cfg, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return nil, err + } + + localVarHTTPResponse, err := openapi.CallAPI(a.client.cfg, r) + if err != nil || localVarHTTPResponse == nil { + return nil, err + } + + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) + if err != nil { + return nil, err + } + err = localVarHTTPResponse.Body.Close() + if err != nil { + return nil, err + } + + apiError := openapi.GenericOpenAPIError{ + RawBody: localVarBody, + ErrorStatus: localVarHTTPResponse.StatusCode, + } + + switch localVarHTTPResponse.StatusCode { + case 201: + err = openapi.Deserialize(&localVarReturnValue.PcfMbsBinding, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + localVarReturnValue.Location = localVarHTTPResponse.Header.Get("Location") + return &localVarReturnValue, nil + case 400: + var v CreatePCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 401: + var v CreatePCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 403: + var v CreatePCFMbsBindingError + err = openapi.Deserialize(&v.BsfManagementMbsExtProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 404: + var v CreatePCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 411: + var v CreatePCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 413: + var v CreatePCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 415: + var v CreatePCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 429: + var v CreatePCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 500: + var v CreatePCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 503: + var v CreatePCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + default: + return nil, apiError + } +} + +/* +PCFForAnMBSSessionBindingsCollectionApiService Retrieve an existing PCF for an MBS Session binding. + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param MbsSessionId - Contains the identifier of the MBS Session to which the requested MBS Session binding is related. + * @param SuppFeat - Contains the list of features supported by the NF service consumer and used to filter irrelevant responses related to unsupported features. + +@return GetPCFMbsBindingResponse +*/ + +// GetPCFMbsBindingRequest +type GetPCFMbsBindingRequest struct { + MbsSessionId *models.MbsSessionId + SuppFeat *string +} + +func (r *GetPCFMbsBindingRequest) SetMbsSessionId(MbsSessionId models.MbsSessionId) { + r.MbsSessionId = &MbsSessionId +} +func (r *GetPCFMbsBindingRequest) SetSuppFeat(SuppFeat string) { + r.SuppFeat = &SuppFeat +} + +type GetPCFMbsBindingResponse struct { + PcfMbsBinding []models.PcfMbsBinding +} + +type GetPCFMbsBindingError struct { + ProblemDetails models.ProblemDetails +} + +func (a *PCFForAnMBSSessionBindingsCollectionApiService) GetPCFMbsBinding(ctx context.Context, request *GetPCFMbsBindingRequest) (*GetPCFMbsBindingResponse, error) { + var ( + localVarHTTPMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue GetPCFMbsBindingResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath() + "/pcf-mbs-bindings" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if request.MbsSessionId == nil { + return nil, openapi.ReportError("MbsSessionId must be non nil") + } else { + localVarQueryParams.Add("mbs-session-id", openapi.ParameterToString(request.MbsSessionId, "application/json")) + } + if request.SuppFeat != nil { + localVarQueryParams.Add("supp-feat", openapi.ParameterToString(request.SuppFeat, "application/json")) + } + + localVarHTTPContentTypes := []string{"application/json"} + + localVarHeaderParams["Content-Type"] = localVarHTTPContentTypes[0] // use the first content type specified in 'consumes' + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json", "application/problem+json"} + + // set Accept header + localVarHTTPHeaderAccept := strings.Join(localVarHTTPHeaderAccepts, ", ") + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + + r, err := openapi.PrepareRequest(ctx, a.client.cfg, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return nil, err + } + + localVarHTTPResponse, err := openapi.CallAPI(a.client.cfg, r) + if err != nil || localVarHTTPResponse == nil { + return nil, err + } + + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) + if err != nil { + return nil, err + } + err = localVarHTTPResponse.Body.Close() + if err != nil { + return nil, err + } + + apiError := openapi.GenericOpenAPIError{ + RawBody: localVarBody, + ErrorStatus: localVarHTTPResponse.StatusCode, + } + + switch localVarHTTPResponse.StatusCode { + case 200: + err = openapi.Deserialize(&localVarReturnValue.PcfMbsBinding, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + return &localVarReturnValue, nil + case 400: + var v GetPCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 401: + var v GetPCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 403: + var v GetPCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 404: + var v GetPCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 406: + return &localVarReturnValue, nil + case 414: + var v GetPCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 429: + var v GetPCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 500: + var v GetPCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 503: + var v GetPCFMbsBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + default: + return nil, apiError + } +} diff --git a/bsf/Management/api_pcf_for_aue_bindings_collection.go b/bsf/Management/api_pcf_for_aue_bindings_collection.go new file mode 100644 index 00000000..300db79b --- /dev/null +++ b/bsf/Management/api_pcf_for_aue_bindings_collection.go @@ -0,0 +1,383 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package Management + +import ( + "github.com/free5gc/openapi" + "github.com/free5gc/openapi/models" + + "context" + "io/ioutil" + "net/url" + "strings" +) + +// Linger please +var ( + _ context.Context +) + +type PCFForAUEBindingsCollectionApiService service + +/* +PCFForAUEBindingsCollectionApiService Create a new Individual PCF for a UE binding information + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param PcfForUeBinding - + +@return CreatePCFforUEBindingResponse +*/ + +// CreatePCFforUEBindingRequest +type CreatePCFforUEBindingRequest struct { + PcfForUeBinding *models.PcfForUeBinding +} + +func (r *CreatePCFforUEBindingRequest) SetPcfForUeBinding(PcfForUeBinding models.PcfForUeBinding) { + r.PcfForUeBinding = &PcfForUeBinding +} + +type CreatePCFforUEBindingResponse struct { + Location string + PcfForUeBinding models.PcfForUeBinding +} + +type CreatePCFforUEBindingError struct { + ProblemDetails models.ProblemDetails +} + +func (a *PCFForAUEBindingsCollectionApiService) CreatePCFforUEBinding(ctx context.Context, request *CreatePCFforUEBindingRequest) (*CreatePCFforUEBindingResponse, error) { + var ( + localVarHTTPMethod = strings.ToUpper("Post") + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreatePCFforUEBindingResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath() + "/pcf-ue-bindings" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarHTTPContentTypes := []string{"application/json"} + + localVarHeaderParams["Content-Type"] = localVarHTTPContentTypes[0] // use the first content type specified in 'consumes' + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json", "application/problem+json"} + + // set Accept header + localVarHTTPHeaderAccept := strings.Join(localVarHTTPHeaderAccepts, ", ") + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + + // body params + localVarPostBody = request.PcfForUeBinding + + r, err := openapi.PrepareRequest(ctx, a.client.cfg, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return nil, err + } + + localVarHTTPResponse, err := openapi.CallAPI(a.client.cfg, r) + if err != nil || localVarHTTPResponse == nil { + return nil, err + } + + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) + if err != nil { + return nil, err + } + err = localVarHTTPResponse.Body.Close() + if err != nil { + return nil, err + } + + apiError := openapi.GenericOpenAPIError{ + RawBody: localVarBody, + ErrorStatus: localVarHTTPResponse.StatusCode, + } + + switch localVarHTTPResponse.StatusCode { + case 201: + err = openapi.Deserialize(&localVarReturnValue.PcfForUeBinding, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + localVarReturnValue.Location = localVarHTTPResponse.Header.Get("Location") + return &localVarReturnValue, nil + case 400: + var v CreatePCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 401: + var v CreatePCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 403: + var v CreatePCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 404: + var v CreatePCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 411: + var v CreatePCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 413: + var v CreatePCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 415: + var v CreatePCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 429: + var v CreatePCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 500: + var v CreatePCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 503: + var v CreatePCFforUEBindingError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + default: + return nil, apiError + } +} + +/* +PCFForAUEBindingsCollectionApiService Read PCF for a UE Bindings information + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param Supi - Subscription Permanent Identifier. + * @param Gpsi - Generic Public Subscription Identifier + * @param SuppFeat - To filter irrelevant responses related to unsupported features. + +@return GetPCFForUeBindingsResponse +*/ + +// GetPCFForUeBindingsRequest +type GetPCFForUeBindingsRequest struct { + Supi *string + Gpsi *string + SuppFeat *string +} + +func (r *GetPCFForUeBindingsRequest) SetSupi(Supi string) { + r.Supi = &Supi +} +func (r *GetPCFForUeBindingsRequest) SetGpsi(Gpsi string) { + r.Gpsi = &Gpsi +} +func (r *GetPCFForUeBindingsRequest) SetSuppFeat(SuppFeat string) { + r.SuppFeat = &SuppFeat +} + +type GetPCFForUeBindingsResponse struct { + PcfForUeBinding []models.PcfForUeBinding +} + +type GetPCFForUeBindingsError struct { + ProblemDetails models.ProblemDetails +} + +func (a *PCFForAUEBindingsCollectionApiService) GetPCFForUeBindings(ctx context.Context, request *GetPCFForUeBindingsRequest) (*GetPCFForUeBindingsResponse, error) { + var ( + localVarHTTPMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue GetPCFForUeBindingsResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath() + "/pcf-ue-bindings" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if request.Supi != nil { + localVarQueryParams.Add("supi", openapi.ParameterToString(request.Supi, "multi")) + } + if request.Gpsi != nil { + localVarQueryParams.Add("gpsi", openapi.ParameterToString(request.Gpsi, "multi")) + } + if request.SuppFeat != nil { + localVarQueryParams.Add("supp-feat", openapi.ParameterToString(request.SuppFeat, "multi")) + } + + localVarHTTPContentTypes := []string{"application/json"} + + localVarHeaderParams["Content-Type"] = localVarHTTPContentTypes[0] // use the first content type specified in 'consumes' + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json", "application/problem+json"} + + // set Accept header + localVarHTTPHeaderAccept := strings.Join(localVarHTTPHeaderAccepts, ", ") + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + + r, err := openapi.PrepareRequest(ctx, a.client.cfg, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return nil, err + } + + localVarHTTPResponse, err := openapi.CallAPI(a.client.cfg, r) + if err != nil || localVarHTTPResponse == nil { + return nil, err + } + + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) + if err != nil { + return nil, err + } + err = localVarHTTPResponse.Body.Close() + if err != nil { + return nil, err + } + + apiError := openapi.GenericOpenAPIError{ + RawBody: localVarBody, + ErrorStatus: localVarHTTPResponse.StatusCode, + } + + switch localVarHTTPResponse.StatusCode { + case 200: + err = openapi.Deserialize(&localVarReturnValue.PcfForUeBinding, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + return &localVarReturnValue, nil + case 400: + var v GetPCFForUeBindingsError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 401: + var v GetPCFForUeBindingsError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 403: + var v GetPCFForUeBindingsError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 404: + var v GetPCFForUeBindingsError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 406: + return &localVarReturnValue, nil + case 414: + var v GetPCFForUeBindingsError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 429: + var v GetPCFForUeBindingsError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 500: + var v GetPCFForUeBindingsError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 503: + var v GetPCFForUeBindingsError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + default: + return nil, apiError + } +} diff --git a/bsf/Management/api_subscriptions_collection.go b/bsf/Management/api_subscriptions_collection.go new file mode 100644 index 00000000..f2762671 --- /dev/null +++ b/bsf/Management/api_subscriptions_collection.go @@ -0,0 +1,390 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package Management + +import ( + "github.com/free5gc/openapi" + "github.com/free5gc/openapi/models" + + "context" + "io/ioutil" + "net/url" + "strings" +) + +// Linger please +var ( + _ context.Context +) + +type SubscriptionsCollectionApiService service + +/* +SubscriptionsCollectionApiService Create an individual subscription for event notifications from the BSF + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param BsfSubscription - + +@return CreateIndividualSubcriptionResponse +*/ + +// CreateIndividualSubcriptionRequest +type CreateIndividualSubcriptionRequest struct { + BsfSubscription *models.BsfSubscription +} + +func (r *CreateIndividualSubcriptionRequest) SetBsfSubscription(BsfSubscription models.BsfSubscription) { + r.BsfSubscription = &BsfSubscription +} + +type CreateIndividualSubcriptionResponse struct { + Location string + BsfSubscriptionResp models.BsfSubscriptionResp +} + +type CreateIndividualSubcriptionError struct { + ProblemDetails models.ProblemDetails +} + +func (a *SubscriptionsCollectionApiService) CreateIndividualSubcription(ctx context.Context, request *CreateIndividualSubcriptionRequest) (*CreateIndividualSubcriptionResponse, error) { + var ( + localVarHTTPMethod = strings.ToUpper("Post") + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateIndividualSubcriptionResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath() + "/subscriptions" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarHTTPContentTypes := []string{"application/json"} + + localVarHeaderParams["Content-Type"] = localVarHTTPContentTypes[0] // use the first content type specified in 'consumes' + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json", "application/problem+json"} + + // set Accept header + localVarHTTPHeaderAccept := strings.Join(localVarHTTPHeaderAccepts, ", ") + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + + // body params + localVarPostBody = request.BsfSubscription + + r, err := openapi.PrepareRequest(ctx, a.client.cfg, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return nil, err + } + + localVarHTTPResponse, err := openapi.CallAPI(a.client.cfg, r) + if err != nil || localVarHTTPResponse == nil { + return nil, err + } + + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) + if err != nil { + return nil, err + } + err = localVarHTTPResponse.Body.Close() + if err != nil { + return nil, err + } + + apiError := openapi.GenericOpenAPIError{ + RawBody: localVarBody, + ErrorStatus: localVarHTTPResponse.StatusCode, + } + + switch localVarHTTPResponse.StatusCode { + case 201: + err = openapi.Deserialize(&localVarReturnValue.BsfSubscriptionResp, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + localVarReturnValue.Location = localVarHTTPResponse.Header.Get("Location") + return &localVarReturnValue, nil + case 400: + var v CreateIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 401: + var v CreateIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 403: + var v CreateIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 404: + var v CreateIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 411: + var v CreateIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 413: + var v CreateIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 415: + var v CreateIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 429: + var v CreateIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 500: + var v CreateIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 503: + var v CreateIndividualSubcriptionError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + default: + return nil, apiError + } +} + +// CreateIndividualSubcriptionMyNotificationPostRequest +type CreateIndividualSubcriptionMyNotificationPostRequest struct { + BsfNotification *models.BsfNotification +} + +func (r *CreateIndividualSubcriptionMyNotificationPostRequest) SetBsfNotification(BsfNotification models.BsfNotification) { + r.BsfNotification = &BsfNotification +} + +type CreateIndividualSubcriptionMyNotificationPostResponse struct { +} + +type CreateIndividualSubcriptionMyNotificationPostError struct { + Location string + Var3gppSbiTargetNfId string + ProblemDetails models.ProblemDetails + RedirectResponse models.RedirectResponse +} + +func (a *SubscriptionsCollectionApiService) CreateIndividualSubcriptionMyNotificationPost(ctx context.Context, uri string, request *CreateIndividualSubcriptionMyNotificationPostRequest) (*CreateIndividualSubcriptionMyNotificationPostResponse, error) { + var ( + localVarHTTPMethod = strings.ToUpper("POST") + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateIndividualSubcriptionMyNotificationPostResponse + ) + + // create path and map variables + localVarPath := uri + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarHTTPContentTypes := []string{"application/json"} + + localVarHeaderParams["Content-Type"] = localVarHTTPContentTypes[0] // use the first content type specified in 'consumes' + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json", "application/problem+json"} + + // set Accept header + localVarHTTPHeaderAccept := strings.Join(localVarHTTPHeaderAccepts, ", ") + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + + // body params + localVarPostBody = request.BsfNotification + + r, err := openapi.PrepareRequest(ctx, a.client.cfg, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return nil, err + } + + localVarHTTPResponse, err := openapi.CallAPI(a.client.cfg, r) + if err != nil || localVarHTTPResponse == nil { + return nil, err + } + + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) + if err != nil { + return nil, err + } + err = localVarHTTPResponse.Body.Close() + if err != nil { + return nil, err + } + + apiError := openapi.GenericOpenAPIError{ + RawBody: localVarBody, + ErrorStatus: localVarHTTPResponse.StatusCode, + } + + switch localVarHTTPResponse.StatusCode { + case 204: + return &localVarReturnValue, nil + case 307: + var v CreateIndividualSubcriptionMyNotificationPostError + err = openapi.Deserialize(&v.RedirectResponse, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + v.Location = localVarHTTPResponse.Header.Get("Location") + v.Var3gppSbiTargetNfId = localVarHTTPResponse.Header.Get("3gpp-Sbi-Target-Nf-Id") + apiError.ErrorModel = v + return nil, apiError + case 308: + var v CreateIndividualSubcriptionMyNotificationPostError + err = openapi.Deserialize(&v.RedirectResponse, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + v.Location = localVarHTTPResponse.Header.Get("Location") + v.Var3gppSbiTargetNfId = localVarHTTPResponse.Header.Get("3gpp-Sbi-Target-Nf-Id") + apiError.ErrorModel = v + return nil, apiError + case 400: + var v CreateIndividualSubcriptionMyNotificationPostError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 401: + var v CreateIndividualSubcriptionMyNotificationPostError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 403: + var v CreateIndividualSubcriptionMyNotificationPostError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 404: + var v CreateIndividualSubcriptionMyNotificationPostError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 411: + var v CreateIndividualSubcriptionMyNotificationPostError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 413: + var v CreateIndividualSubcriptionMyNotificationPostError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 415: + var v CreateIndividualSubcriptionMyNotificationPostError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 429: + var v CreateIndividualSubcriptionMyNotificationPostError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 500: + var v CreateIndividualSubcriptionMyNotificationPostError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + case 503: + var v CreateIndividualSubcriptionMyNotificationPostError + err = openapi.Deserialize(&v.ProblemDetails, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + return nil, err + } + apiError.ErrorModel = v + return nil, apiError + default: + return &localVarReturnValue, nil + } +} diff --git a/bsf/Management/client.go b/bsf/Management/client.go new file mode 100644 index 00000000..8e246248 --- /dev/null +++ b/bsf/Management/client.go @@ -0,0 +1,56 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package Management + +// APIClient manages communication with the Nbsf_Management API v1.3.1 +// In most cases there should be only one, shared, APIClient. +type APIClient struct { + cfg *Configuration + common service // Reuse a single struct instead of allocating one for each service on the heap. + + // API Services + IndividualPCFBindingDocumentApi *IndividualPCFBindingDocumentApiService + IndividualPCFForAPDUSessionBindingDocumentApi *IndividualPCFForAPDUSessionBindingDocumentApiService + IndividualPCFForAUEBindingDocumentApi *IndividualPCFForAUEBindingDocumentApiService + IndividualPCFForAnMBSSessionBindingDocumentApi *IndividualPCFForAnMBSSessionBindingDocumentApiService + IndividualSubscriptionDocumentApi *IndividualSubscriptionDocumentApiService + PCFBindingsCollectionApi *PCFBindingsCollectionApiService + PCFForAUEBindingsCollectionApi *PCFForAUEBindingsCollectionApiService + PCFForAnMBSSessionBindingsCollectionApi *PCFForAnMBSSessionBindingsCollectionApiService + SubscriptionsCollectionApi *SubscriptionsCollectionApiService +} + +type service struct { + client *APIClient +} + +// NewAPIClient creates a new API client. Requires a userAgent string describing your application. +// optionally a custom http.Client to allow for advanced features such as caching. +func NewAPIClient(cfg *Configuration) *APIClient { + c := &APIClient{} + c.cfg = cfg + c.common.client = c + + // API Services + c.IndividualPCFBindingDocumentApi = (*IndividualPCFBindingDocumentApiService)(&c.common) + c.IndividualPCFForAPDUSessionBindingDocumentApi = (*IndividualPCFForAPDUSessionBindingDocumentApiService)(&c.common) + c.IndividualPCFForAUEBindingDocumentApi = (*IndividualPCFForAUEBindingDocumentApiService)(&c.common) + c.IndividualPCFForAnMBSSessionBindingDocumentApi = (*IndividualPCFForAnMBSSessionBindingDocumentApiService)(&c.common) + c.IndividualSubscriptionDocumentApi = (*IndividualSubscriptionDocumentApiService)(&c.common) + c.PCFBindingsCollectionApi = (*PCFBindingsCollectionApiService)(&c.common) + c.PCFForAUEBindingsCollectionApi = (*PCFForAUEBindingsCollectionApiService)(&c.common) + c.PCFForAnMBSSessionBindingsCollectionApi = (*PCFForAnMBSSessionBindingsCollectionApiService)(&c.common) + c.SubscriptionsCollectionApi = (*SubscriptionsCollectionApiService)(&c.common) + + return c +} diff --git a/bsf/Management/configuration.go b/bsf/Management/configuration.go new file mode 100644 index 00000000..53d84af4 --- /dev/null +++ b/bsf/Management/configuration.go @@ -0,0 +1,82 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package Management + +import ( + "net/http" + "strings" +) + +type Configuration struct { + url string + basePath string + host string + defaultHeader map[string]string + userAgent string + httpClient *http.Client +} + +func NewConfiguration() *Configuration { + cfg := &Configuration{ + basePath: "https://example.com/nbsf-management/v1", + url: "{apiRoot}/nbsf-management/v1", + defaultHeader: make(map[string]string), + userAgent: "OpenAPI-Generator/1.0.0/go", + } + return cfg +} + +func (c *Configuration) SetBasePath(apiRoot string) { + url := c.url + + // Replace apiRoot + url = strings.Replace(url, "{"+"apiRoot"+"}", apiRoot, -1) + + c.basePath = url +} + +func (c *Configuration) BasePath() string { + return c.basePath +} + +func (c *Configuration) Host() string { + return c.host +} + +func (c *Configuration) SetHost(host string) { + c.host = host +} + +func (c *Configuration) UserAgent() string { + return c.userAgent +} + +func (c *Configuration) SetUserAgent(userAgent string) { + c.userAgent = userAgent +} + +func (c *Configuration) DefaultHeader() map[string]string { + return c.defaultHeader +} + +func (c *Configuration) AddDefaultHeader(key string, value string) { + c.defaultHeader[key] = value +} + +func (c *Configuration) HTTPClient() *http.Client { + return c.httpClient +} + +func (c *Configuration) SetHTTPClient(client *http.Client) { + c.httpClient = client +} diff --git a/models/model_binding_level.go b/models/model_binding_level.go new file mode 100644 index 00000000..04b03600 --- /dev/null +++ b/models/model_binding_level.go @@ -0,0 +1,21 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package models + +type BindingLevel string + +// List of BindingLevel +const ( + BindingLevel_SET BindingLevel = "NF_SET" + BindingLevel_INSTANCE BindingLevel = "NF_INSTANCE" +) diff --git a/models/model_bsf_event.go b/models/model_bsf_event.go new file mode 100644 index 00000000..d48191a8 --- /dev/null +++ b/models/model_bsf_event.go @@ -0,0 +1,25 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package models + +type BsfEvent string + +// List of BsfEvent +const ( + BsfEvent_PCF_PDU_SESSION_BINDING_REGISTRATION BsfEvent = "PCF_PDU_SESSION_BINDING_REGISTRATION" + BsfEvent_PCF_PDU_SESSION_BINDING_DEREGISTRATION BsfEvent = "PCF_PDU_SESSION_BINDING_DEREGISTRATION" + BsfEvent_PCF_UE_BINDING_REGISTRATION BsfEvent = "PCF_UE_BINDING_REGISTRATION" + BsfEvent_PCF_UE_BINDING_DEREGISTRATION BsfEvent = "PCF_UE_BINDING_DEREGISTRATION" + BsfEvent_SNSSAI_DNN_BINDING_REGISTRATION BsfEvent = "SNSSAI_DNN_BINDING_REGISTRATION" + BsfEvent_SNSSAI_DNN_BINDING_DEREGISTRATION BsfEvent = "SNSSAI_DNN_BINDING_DEREGISTRATION" +) diff --git a/models/model_bsf_event_notification.go b/models/model_bsf_event_notification.go new file mode 100644 index 00000000..f0ba90f6 --- /dev/null +++ b/models/model_bsf_event_notification.go @@ -0,0 +1,23 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package models + +// Contains an event notification. +type BsfEventNotification struct { + Event BsfEvent `json:"event" yaml:"event" bson:"event,omitempty"` + PcfForUeInfo *PcfForUeInfo `json:"pcfForUeInfo,omitempty" yaml:"pcfForUeInfo" bson:"pcfForUeInfo,omitempty"` + // The information of the PCF for a PDU session. + PcfForPduSessInfos []PcfForPduSessionInfo `json:"pcfForPduSessInfos,omitempty" yaml:"pcfForPduSessInfos" bson:"pcfForPduSessInfos,omitempty"` + // Matching S-NSSAI and DNN pairs. + MatchSnssaiDnns []SnssaiDnnPair `json:"matchSnssaiDnns,omitempty" yaml:"matchSnssaiDnns" bson:"matchSnssaiDnns,omitempty"` +} diff --git a/models/model_bsf_management_ext_problem_details.go b/models/model_bsf_management_ext_problem_details.go new file mode 100644 index 00000000..57def829 --- /dev/null +++ b/models/model_bsf_management_ext_problem_details.go @@ -0,0 +1,38 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package models + +// Contains the FQDN or IP endpoints of the existing PCF and the cause value if there is an existing PCF binding information for the indicated combination. +type BsfManagementExtProblemDetails struct { + // String providing an URI formatted according to RFC 3986. + Type string `json:"type,omitempty" yaml:"type" bson:"type,omitempty"` + Title string `json:"title,omitempty" yaml:"title" bson:"title,omitempty"` + Status int32 `json:"status,omitempty" yaml:"status" bson:"status,omitempty"` + // A human-readable explanation specific to this occurrence of the problem. + Detail string `json:"detail,omitempty" yaml:"detail" bson:"detail,omitempty"` + // String providing an URI formatted according to RFC 3986. + Instance string `json:"instance,omitempty" yaml:"instance" bson:"instance,omitempty"` + // A machine-readable application error cause specific to this occurrence of the problem. This IE should be present and provide application-related error information, if available. + Cause string `json:"cause,omitempty" yaml:"cause" bson:"cause,omitempty"` + InvalidParams []InvalidParam `json:"invalidParams,omitempty" yaml:"invalidParams" bson:"invalidParams,omitempty"` + // A string used to indicate the features supported by an API that is used as defined in clause 6.6 in 3GPP TS 29.500. The string shall contain a bitmask indicating supported features in hexadecimal representation Each character in the string shall take a value of \"0\" to \"9\", \"a\" to \"f\" or \"A\" to \"F\" and shall represent the support of 4 features as described in table 5.2.2-3. The most significant character representing the highest-numbered features shall appear first in the string, and the character representing features 1 to 4 shall appear last in the string. The list of features and their numbering (starting with 1) are defined separately for each API. If the string contains a lower number of characters than there are defined features for an API, all features that would be represented by characters that are not present in the string are not supported. + SupportedFeatures string `json:"supportedFeatures,omitempty" yaml:"supportedFeatures" bson:"supportedFeatures,omitempty"` + AccessTokenError *AccessTokenErr `json:"accessTokenError,omitempty" yaml:"accessTokenError" bson:"accessTokenError,omitempty"` + AccessTokenRequest *NrfAccessTokenAccessTokenReq `json:"accessTokenRequest,omitempty" yaml:"accessTokenRequest" bson:"accessTokenRequest,omitempty"` + // Fully Qualified Domain Name + NrfId string `json:"nrfId,omitempty" yaml:"nrfId" bson:"nrfId,omitempty"` + // Fully Qualified Domain Name + PcfSmFqdn string `json:"pcfSmFqdn,omitempty" yaml:"pcfSmFqdn" bson:"pcfSmFqdn,omitempty"` + // IP end points of the PCF hosting the Npcf_SMPolicyControl service. + PcfSmIpEndPoints []IpEndPoint `json:"pcfSmIpEndPoints,omitempty" yaml:"pcfSmIpEndPoints" bson:"pcfSmIpEndPoints,omitempty"` +} diff --git a/models/model_bsf_management_mbs_ext_problem_details.go b/models/model_bsf_management_mbs_ext_problem_details.go new file mode 100644 index 00000000..c2c8cb2e --- /dev/null +++ b/models/model_bsf_management_mbs_ext_problem_details.go @@ -0,0 +1,38 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package models + +// Contains the FQDN or IP endpoints of the existing PCF and the cause value if there is an existing PCF binding information for the MBS session. +type BsfManagementMbsExtProblemDetails struct { + // String providing an URI formatted according to RFC 3986. + Type string `json:"type,omitempty" yaml:"type" bson:"type,omitempty"` + Title string `json:"title,omitempty" yaml:"title" bson:"title,omitempty"` + Status int32 `json:"status,omitempty" yaml:"status" bson:"status,omitempty"` + // A human-readable explanation specific to this occurrence of the problem. + Detail string `json:"detail,omitempty" yaml:"detail" bson:"detail,omitempty"` + // String providing an URI formatted according to RFC 3986. + Instance string `json:"instance,omitempty" yaml:"instance" bson:"instance,omitempty"` + // A machine-readable application error cause specific to this occurrence of the problem. This IE should be present and provide application-related error information, if available. + Cause string `json:"cause,omitempty" yaml:"cause" bson:"cause,omitempty"` + InvalidParams []InvalidParam `json:"invalidParams,omitempty" yaml:"invalidParams" bson:"invalidParams,omitempty"` + // A string used to indicate the features supported by an API that is used as defined in clause 6.6 in 3GPP TS 29.500. The string shall contain a bitmask indicating supported features in hexadecimal representation Each character in the string shall take a value of \"0\" to \"9\", \"a\" to \"f\" or \"A\" to \"F\" and shall represent the support of 4 features as described in table 5.2.2-3. The most significant character representing the highest-numbered features shall appear first in the string, and the character representing features 1 to 4 shall appear last in the string. The list of features and their numbering (starting with 1) are defined separately for each API. If the string contains a lower number of characters than there are defined features for an API, all features that would be represented by characters that are not present in the string are not supported. + SupportedFeatures string `json:"supportedFeatures,omitempty" yaml:"supportedFeatures" bson:"supportedFeatures,omitempty"` + AccessTokenError *AccessTokenErr `json:"accessTokenError,omitempty" yaml:"accessTokenError" bson:"accessTokenError,omitempty"` + AccessTokenRequest *NrfAccessTokenAccessTokenReq `json:"accessTokenRequest,omitempty" yaml:"accessTokenRequest" bson:"accessTokenRequest,omitempty"` + // Fully Qualified Domain Name + NrfId string `json:"nrfId,omitempty" yaml:"nrfId" bson:"nrfId,omitempty"` + // Fully Qualified Domain Name + PcfFqdn string `json:"pcfFqdn,omitempty" yaml:"pcfFqdn" bson:"pcfFqdn,omitempty"` + // IP end points of the PCF handling the MBS Session. + PcfIpEndPoints []IpEndPoint `json:"pcfIpEndPoints,omitempty" yaml:"pcfIpEndPoints" bson:"pcfIpEndPoints,omitempty"` +} diff --git a/models/model_bsf_notification.go b/models/model_bsf_notification.go new file mode 100644 index 00000000..3f3e814c --- /dev/null +++ b/models/model_bsf_notification.go @@ -0,0 +1,26 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package models + +// Contains the event notifications. +type BsfNotification struct { + // Notification Correlation ID assigned by the NF service consumer. + NotifCorreId string `json:"notifCorreId" yaml:"notifCorreId" bson:"notifCorreId,omitempty"` + // String uniquely identifying a NF instance. The format of the NF Instance ID shall be a Universally Unique Identifier (UUID) version 4, as described in IETF RFC 4122. + PcfId string `json:"pcfId,omitempty" yaml:"pcfId" bson:"pcfId,omitempty"` + // NF Set Identifier (see clause 28.12 of 3GPP TS 23.003), formatted as the following string \"set.set.5gc.mnc.mcc\", or \"set.set.5gc.nid.mnc.mcc\" with encoded as defined in clause 5.4.2 (\"Mcc\" data type definition) encoding the Mobile Network Code part of the PLMN, comprising 3 digits. If there are only 2 significant digits in the MNC, one \"0\" digit shall be inserted at the left side to fill the 3 digits coding of MNC. Pattern: '^[0-9]{3}$' encoded as a value defined in Table 6.1.6.3.3-1 of 3GPP TS 29.510 but with lower case characters encoded as a string of characters consisting of alphabetic characters (A-Z and a-z), digits (0-9) and/or the hyphen (-) and that shall end with either an alphabetic character or a digit. + PcfSetId string `json:"pcfSetId,omitempty" yaml:"pcfSetId" bson:"pcfSetId,omitempty"` + BindLevel BindingLevel `json:"bindLevel,omitempty" yaml:"bindLevel" bson:"bindLevel,omitempty"` + // Notifications about Individual Events. + EventNotifs []BsfEventNotification `json:"eventNotifs" yaml:"eventNotifs" bson:"eventNotifs,omitempty"` +} diff --git a/models/model_bsf_subscription.go b/models/model_bsf_subscription.go new file mode 100644 index 00000000..a843553d --- /dev/null +++ b/models/model_bsf_subscription.go @@ -0,0 +1,32 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package models + +// Contains the event subscription data. +type BsfSubscription struct { + // Contain te subscribed events. + Events []BsfEvent `json:"events" yaml:"events" bson:"events,omitempty"` + // String providing an URI formatted according to RFC 3986. + NotifUri string `json:"notifUri" yaml:"notifUri" bson:"notifUri,omitempty"` + // Notification Correlation ID assigned by the NF service consumer. + NotifCorreId string `json:"notifCorreId" yaml:"notifCorreId" bson:"notifCorreId,omitempty"` + // String identifying a Supi that shall contain either an IMSI, a network specific identifier, a Global Cable Identifier (GCI) or a Global Line Identifier (GLI) as specified in clause 2.2A of 3GPP TS 23.003. It shall be formatted as follows - for an IMSI \"imsi-\", where shall be formatted according to clause 2.2 of 3GPP TS 23.003 that describes an IMSI. - for a network specific identifier \"nai-, where shall be formatted according to clause 28.7.2 of 3GPP TS 23.003 that describes an NAI. - for a GCI \"gci-\", where shall be formatted according to clause 28.15.2 of 3GPP TS 23.003. - for a GLI \"gli-\", where shall be formatted according to clause 28.16.2 of 3GPP TS 23.003.To enable that the value is used as part of an URI, the string shall only contain characters allowed according to the \"lower-with-hyphen\" naming convention defined in 3GPP TS 29.501. + Supi string `json:"supi" yaml:"supi" bson:"supi,omitempty"` + // String identifying a Gpsi shall contain either an External Id or an MSISDN. It shall be formatted as follows -External Identifier= \"extid-'extid', where 'extid' shall be formatted according to clause 19.7.2 of 3GPP TS 23.003 that describes an External Identifier. + Gpsi string `json:"gpsi,omitempty" yaml:"gpsi" bson:"gpsi,omitempty"` + SnssaiDnnPairs *SnssaiDnnPair `json:"snssaiDnnPairs,omitempty" yaml:"snssaiDnnPairs" bson:"snssaiDnnPairs,omitempty"` + // Represents the additional S-NSSAI and DNN pair(s) for which the binding event report(s) shall apply. + AddSnssaiDnnPairs []SnssaiDnnPair `json:"addSnssaiDnnPairs,omitempty" yaml:"addSnssaiDnnPairs" bson:"addSnssaiDnnPairs,omitempty"` + // A string used to indicate the features supported by an API that is used as defined in clause 6.6 in 3GPP TS 29.500. The string shall contain a bitmask indicating supported features in hexadecimal representation Each character in the string shall take a value of \"0\" to \"9\", \"a\" to \"f\" or \"A\" to \"F\" and shall represent the support of 4 features as described in table 5.2.2-3. The most significant character representing the highest-numbered features shall appear first in the string, and the character representing features 1 to 4 shall appear last in the string. The list of features and their numbering (starting with 1) are defined separately for each API. If the string contains a lower number of characters than there are defined features for an API, all features that would be represented by characters that are not present in the string are not supported. + SuppFeat string `json:"suppFeat,omitempty" yaml:"suppFeat" bson:"suppFeat,omitempty"` +} diff --git a/models/model_bsf_subscription_resp.go b/models/model_bsf_subscription_resp.go new file mode 100644 index 00000000..f5dc5fc6 --- /dev/null +++ b/models/model_bsf_subscription_resp.go @@ -0,0 +1,39 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package models + +// It represents a response to a modification or creation request of an Individual Binding Subscription resource. It may contain the notification of the already met events. +type BsfSubscriptionResp struct { + // Contain te subscribed events. + Events []BsfEvent `json:"events" yaml:"events" bson:"events,omitempty"` + // String providing an URI formatted according to RFC 3986. + NotifUri string `json:"notifUri" yaml:"notifUri" bson:"notifUri,omitempty"` + // Notification Correlation ID assigned by the NF service consumer. + NotifCorreId string `json:"notifCorreId" yaml:"notifCorreId" bson:"notifCorreId,omitempty"` + // String identifying a Supi that shall contain either an IMSI, a network specific identifier, a Global Cable Identifier (GCI) or a Global Line Identifier (GLI) as specified in clause 2.2A of 3GPP TS 23.003. It shall be formatted as follows - for an IMSI \"imsi-\", where shall be formatted according to clause 2.2 of 3GPP TS 23.003 that describes an IMSI. - for a network specific identifier \"nai-, where shall be formatted according to clause 28.7.2 of 3GPP TS 23.003 that describes an NAI. - for a GCI \"gci-\", where shall be formatted according to clause 28.15.2 of 3GPP TS 23.003. - for a GLI \"gli-\", where shall be formatted according to clause 28.16.2 of 3GPP TS 23.003.To enable that the value is used as part of an URI, the string shall only contain characters allowed according to the \"lower-with-hyphen\" naming convention defined in 3GPP TS 29.501. + Supi string `json:"supi" yaml:"supi" bson:"supi,omitempty"` + // String identifying a Gpsi shall contain either an External Id or an MSISDN. It shall be formatted as follows -External Identifier= \"extid-'extid', where 'extid' shall be formatted according to clause 19.7.2 of 3GPP TS 23.003 that describes an External Identifier. + Gpsi string `json:"gpsi,omitempty" yaml:"gpsi" bson:"gpsi,omitempty"` + SnssaiDnnPairs *SnssaiDnnPair `json:"snssaiDnnPairs,omitempty" yaml:"snssaiDnnPairs" bson:"snssaiDnnPairs,omitempty"` + // Represents the additional S-NSSAI and DNN pair(s) for which the binding event report(s) shall apply. + AddSnssaiDnnPairs []SnssaiDnnPair `json:"addSnssaiDnnPairs,omitempty" yaml:"addSnssaiDnnPairs" bson:"addSnssaiDnnPairs,omitempty"` + // A string used to indicate the features supported by an API that is used as defined in clause 6.6 in 3GPP TS 29.500. The string shall contain a bitmask indicating supported features in hexadecimal representation Each character in the string shall take a value of \"0\" to \"9\", \"a\" to \"f\" or \"A\" to \"F\" and shall represent the support of 4 features as described in table 5.2.2-3. The most significant character representing the highest-numbered features shall appear first in the string, and the character representing features 1 to 4 shall appear last in the string. The list of features and their numbering (starting with 1) are defined separately for each API. If the string contains a lower number of characters than there are defined features for an API, all features that would be represented by characters that are not present in the string are not supported. + SuppFeat string `json:"suppFeat,omitempty" yaml:"suppFeat" bson:"suppFeat,omitempty"` + // String uniquely identifying a NF instance. The format of the NF Instance ID shall be a Universally Unique Identifier (UUID) version 4, as described in IETF RFC 4122. + PcfId string `json:"pcfId,omitempty" yaml:"pcfId" bson:"pcfId,omitempty"` + // NF Set Identifier (see clause 28.12 of 3GPP TS 23.003), formatted as the following string \"set.set.5gc.mnc.mcc\", or \"set.set.5gc.nid.mnc.mcc\" with encoded as defined in clause 5.4.2 (\"Mcc\" data type definition) encoding the Mobile Network Code part of the PLMN, comprising 3 digits. If there are only 2 significant digits in the MNC, one \"0\" digit shall be inserted at the left side to fill the 3 digits coding of MNC. Pattern: '^[0-9]{3}$' encoded as a value defined in Table 6.1.6.3.3-1 of 3GPP TS 29.510 but with lower case characters encoded as a string of characters consisting of alphabetic characters (A-Z and a-z), digits (0-9) and/or the hyphen (-) and that shall end with either an alphabetic character or a digit. + PcfSetId string `json:"pcfSetId,omitempty" yaml:"pcfSetId" bson:"pcfSetId,omitempty"` + BindLevel BindingLevel `json:"bindLevel,omitempty" yaml:"bindLevel" bson:"bindLevel,omitempty"` + // Notifications about Individual Events. + EventNotifs []BsfEventNotification `json:"eventNotifs" yaml:"eventNotifs" bson:"eventNotifs,omitempty"` +} diff --git a/models/model_parameter_combination.go b/models/model_parameter_combination.go new file mode 100644 index 00000000..cabcb3c3 --- /dev/null +++ b/models/model_parameter_combination.go @@ -0,0 +1,22 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package models + +// Represents the combination used by the BSF to check whether there is an existing PCF binding information. +type ParameterCombination struct { + // String identifying a Supi that shall contain either an IMSI, a network specific identifier, a Global Cable Identifier (GCI) or a Global Line Identifier (GLI) as specified in clause 2.2A of 3GPP TS 23.003. It shall be formatted as follows - for an IMSI \"imsi-\", where shall be formatted according to clause 2.2 of 3GPP TS 23.003 that describes an IMSI. - for a network specific identifier \"nai-, where shall be formatted according to clause 28.7.2 of 3GPP TS 23.003 that describes an NAI. - for a GCI \"gci-\", where shall be formatted according to clause 28.15.2 of 3GPP TS 23.003. - for a GLI \"gli-\", where shall be formatted according to clause 28.16.2 of 3GPP TS 23.003.To enable that the value is used as part of an URI, the string shall only contain characters allowed according to the \"lower-with-hyphen\" naming convention defined in 3GPP TS 29.501. + Supi string `json:"supi,omitempty" yaml:"supi" bson:"supi,omitempty"` + // String representing a Data Network as defined in clause 9A of 3GPP TS 23.003; it shall contain either a DNN Network Identifier, or a full DNN with both the Network Identifier and Operator Identifier, as specified in 3GPP TS 23.003 clause 9.1.1 and 9.1.2. It shall be coded as string in which the labels are separated by dots (e.g. \"Label1.Label2.Label3\"). + Dnn string `json:"dnn,omitempty" yaml:"dnn" bson:"dnn,omitempty"` + Snssai *Snssai `json:"snssai,omitempty" yaml:"snssai" bson:"snssai,omitempty"` +} diff --git a/models/model_pcf_binding.go b/models/model_pcf_binding.go new file mode 100644 index 00000000..2e873719 --- /dev/null +++ b/models/model_pcf_binding.go @@ -0,0 +1,62 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package models + +import ( + "time" +) + +// Identifies an Individual PCF for a PDU Session binding. +type PcfBinding struct { + // String identifying a Supi that shall contain either an IMSI, a network specific identifier, a Global Cable Identifier (GCI) or a Global Line Identifier (GLI) as specified in clause 2.2A of 3GPP TS 23.003. It shall be formatted as follows - for an IMSI \"imsi-\", where shall be formatted according to clause 2.2 of 3GPP TS 23.003 that describes an IMSI. - for a network specific identifier \"nai-, where shall be formatted according to clause 28.7.2 of 3GPP TS 23.003 that describes an NAI. - for a GCI \"gci-\", where shall be formatted according to clause 28.15.2 of 3GPP TS 23.003. - for a GLI \"gli-\", where shall be formatted according to clause 28.16.2 of 3GPP TS 23.003.To enable that the value is used as part of an URI, the string shall only contain characters allowed according to the \"lower-with-hyphen\" naming convention defined in 3GPP TS 29.501. + Supi string `json:"supi,omitempty" yaml:"supi" bson:"supi,omitempty"` + // String identifying a Gpsi shall contain either an External Id or an MSISDN. It shall be formatted as follows -External Identifier= \"extid-'extid', where 'extid' shall be formatted according to clause 19.7.2 of 3GPP TS 23.003 that describes an External Identifier. + Gpsi string `json:"gpsi,omitempty" yaml:"gpsi" bson:"gpsi,omitempty"` + // String identifying a IPv4 address formatted in the 'dotted decimal' notation as defined in RFC 1166. + Ipv4Addr string `json:"ipv4Addr,omitempty" yaml:"ipv4Addr" bson:"ipv4Addr,omitempty"` + Ipv6Prefix string `json:"ipv6Prefix,omitempty" yaml:"ipv6Prefix" bson:"ipv6Prefix,omitempty"` + // The additional IPv6 Address Prefixes of the served UE. + AddIpv6Prefixes []string `json:"addIpv6Prefixes,omitempty" yaml:"addIpv6Prefixes" bson:"addIpv6Prefixes,omitempty"` + IpDomain string `json:"ipDomain,omitempty" yaml:"ipDomain" bson:"ipDomain,omitempty"` + // String identifying a MAC address formatted in the hexadecimal notation according to clause 1.1 and clause 2.1 of RFC 7042. + MacAddr48 string `json:"macAddr48,omitempty" yaml:"macAddr48" bson:"macAddr48,omitempty"` + // The additional MAC Addresses of the served UE. + AddMacAddrs []string `json:"addMacAddrs,omitempty" yaml:"addMacAddrs" bson:"addMacAddrs,omitempty"` + // String representing a Data Network as defined in clause 9A of 3GPP TS 23.003; it shall contain either a DNN Network Identifier, or a full DNN with both the Network Identifier and Operator Identifier, as specified in 3GPP TS 23.003 clause 9.1.1 and 9.1.2. It shall be coded as string in which the labels are separated by dots (e.g. \"Label1.Label2.Label3\"). + Dnn string `json:"dnn" yaml:"dnn" bson:"dnn,omitempty"` + // Fully Qualified Domain Name + PcfFqdn string `json:"pcfFqdn,omitempty" yaml:"pcfFqdn" bson:"pcfFqdn,omitempty"` + // IP end points of the PCF hosting the Npcf_PolicyAuthorization service + PcfIpEndPoints []IpEndPoint `json:"pcfIpEndPoints,omitempty" yaml:"pcfIpEndPoints" bson:"pcfIpEndPoints,omitempty"` + // Fully Qualified Domain Name + PcfDiamHost string `json:"pcfDiamHost,omitempty" yaml:"pcfDiamHost" bson:"pcfDiamHost,omitempty"` + // Fully Qualified Domain Name + PcfDiamRealm string `json:"pcfDiamRealm,omitempty" yaml:"pcfDiamRealm" bson:"pcfDiamRealm,omitempty"` + // Fully Qualified Domain Name + PcfSmFqdn string `json:"pcfSmFqdn,omitempty" yaml:"pcfSmFqdn" bson:"pcfSmFqdn,omitempty"` + // IP end points of the PCF hosting the Npcf_SMPolicyControl service. + PcfSmIpEndPoints []IpEndPoint `json:"pcfSmIpEndPoints,omitempty" yaml:"pcfSmIpEndPoints" bson:"pcfSmIpEndPoints,omitempty"` + Snssai *Snssai `json:"snssai" yaml:"snssai" bson:"snssai,omitempty"` + // A string used to indicate the features supported by an API that is used as defined in clause 6.6 in 3GPP TS 29.500. The string shall contain a bitmask indicating supported features in hexadecimal representation Each character in the string shall take a value of \"0\" to \"9\", \"a\" to \"f\" or \"A\" to \"F\" and shall represent the support of 4 features as described in table 5.2.2-3. The most significant character representing the highest-numbered features shall appear first in the string, and the character representing features 1 to 4 shall appear last in the string. The list of features and their numbering (starting with 1) are defined separately for each API. If the string contains a lower number of characters than there are defined features for an API, all features that would be represented by characters that are not present in the string are not supported. + SuppFeat string `json:"suppFeat,omitempty" yaml:"suppFeat" bson:"suppFeat,omitempty"` + // String uniquely identifying a NF instance. The format of the NF Instance ID shall be a Universally Unique Identifier (UUID) version 4, as described in IETF RFC 4122. + PcfId string `json:"pcfId,omitempty" yaml:"pcfId" bson:"pcfId,omitempty"` + // NF Set Identifier (see clause 28.12 of 3GPP TS 23.003), formatted as the following string \"set.set.5gc.mnc.mcc\", or \"set.set.5gc.nid.mnc.mcc\" with encoded as defined in clause 5.4.2 (\"Mcc\" data type definition) encoding the Mobile Network Code part of the PLMN, comprising 3 digits. If there are only 2 significant digits in the MNC, one \"0\" digit shall be inserted at the left side to fill the 3 digits coding of MNC. Pattern: '^[0-9]{3}$' encoded as a value defined in Table 6.1.6.3.3-1 of 3GPP TS 29.510 but with lower case characters encoded as a string of characters consisting of alphabetic characters (A-Z and a-z), digits (0-9) and/or the hyphen (-) and that shall end with either an alphabetic character or a digit. + PcfSetId string `json:"pcfSetId,omitempty" yaml:"pcfSetId" bson:"pcfSetId,omitempty"` + // string with format 'date-time' as defined in OpenAPI. + RecoveryTime *time.Time `json:"recoveryTime,omitempty" yaml:"recoveryTime" bson:"recoveryTime,omitempty"` + ParaCom *ParameterCombination `json:"paraCom,omitempty" yaml:"paraCom" bson:"paraCom,omitempty"` + BindLevel BindingLevel `json:"bindLevel,omitempty" yaml:"bindLevel" bson:"bindLevel,omitempty"` + Ipv4FrameRouteList []string `json:"ipv4FrameRouteList,omitempty" yaml:"ipv4FrameRouteList" bson:"ipv4FrameRouteList,omitempty"` + Ipv6FrameRouteList []string `json:"ipv6FrameRouteList,omitempty" yaml:"ipv6FrameRouteList" bson:"ipv6FrameRouteList,omitempty"` +} diff --git a/models/model_pcf_binding_patch.go b/models/model_pcf_binding_patch.go new file mode 100644 index 00000000..50053a7b --- /dev/null +++ b/models/model_pcf_binding_patch.go @@ -0,0 +1,37 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package models + +// Identifies an Individual PCF binding used in an HTTP Patch method. +type PcfBindingPatch struct { + // String identifying a IPv4 address formatted in the 'dotted decimal' notation as defined in RFC 1166 with the OpenAPI defined 'nullable: true' property. + Ipv4Addr string `json:"ipv4Addr,omitempty" yaml:"ipv4Addr" bson:"ipv4Addr,omitempty"` + IpDomain string `json:"ipDomain,omitempty" yaml:"ipDomain" bson:"ipDomain,omitempty"` + Ipv6Prefix string `json:"ipv6Prefix,omitempty" yaml:"ipv6Prefix" bson:"ipv6Prefix,omitempty"` + // The additional IPv6 Address Prefixes of the served UE. + AddIpv6Prefixes []string `json:"addIpv6Prefixes,omitempty" yaml:"addIpv6Prefixes" bson:"addIpv6Prefixes,omitempty"` + // \"String identifying a MAC address formatted in the hexadecimal notation according to clause 1.1 and clause 2.1 of RFC 7042 with the OpenAPI 'nullable: true' property.\" + MacAddr48 string `json:"macAddr48,omitempty" yaml:"macAddr48" bson:"macAddr48,omitempty"` + // The additional MAC Addresses of the served UE. + AddMacAddrs []string `json:"addMacAddrs,omitempty" yaml:"addMacAddrs" bson:"addMacAddrs,omitempty"` + // String uniquely identifying a NF instance. The format of the NF Instance ID shall be a Universally Unique Identifier (UUID) version 4, as described in IETF RFC 4122. + PcfId string `json:"pcfId,omitempty" yaml:"pcfId" bson:"pcfId,omitempty"` + // Fully Qualified Domain Name + PcfFqdn string `json:"pcfFqdn,omitempty" yaml:"pcfFqdn" bson:"pcfFqdn,omitempty"` + // IP end points of the PCF hosting the Npcf_PolicyAuthorization service. + PcfIpEndPoints []IpEndPoint `json:"pcfIpEndPoints,omitempty" yaml:"pcfIpEndPoints" bson:"pcfIpEndPoints,omitempty"` + // Fully Qualified Domain Name + PcfDiamHost string `json:"pcfDiamHost,omitempty" yaml:"pcfDiamHost" bson:"pcfDiamHost,omitempty"` + // Fully Qualified Domain Name + PcfDiamRealm string `json:"pcfDiamRealm,omitempty" yaml:"pcfDiamRealm" bson:"pcfDiamRealm,omitempty"` +} diff --git a/models/model_pcf_for_pdu_session_info.go b/models/model_pcf_for_pdu_session_info.go new file mode 100644 index 00000000..eb388537 --- /dev/null +++ b/models/model_pcf_for_pdu_session_info.go @@ -0,0 +1,36 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package models + +// Contains the informaiton of the PCF for a PDU session. +type PcfForPduSessionInfo struct { + // String representing a Data Network as defined in clause 9A of 3GPP TS 23.003; it shall contain either a DNN Network Identifier, or a full DNN with both the Network Identifier and Operator Identifier, as specified in 3GPP TS 23.003 clause 9.1.1 and 9.1.2. It shall be coded as string in which the labels are separated by dots (e.g. \"Label1.Label2.Label3\"). + Dnn string `json:"dnn" yaml:"dnn" bson:"dnn,omitempty"` + Snssai *Snssai `json:"snssai" yaml:"snssai" bson:"snssai,omitempty"` + // Fully Qualified Domain Name + PcfFqdn string `json:"pcfFqdn,omitempty" yaml:"pcfFqdn" bson:"pcfFqdn,omitempty"` + // IP end points of the PCF hosting the Npcf_AmPolicyAuthorization service. + PcfIpEndPoints []IpEndPoint `json:"pcfIpEndPoints,omitempty" yaml:"pcfIpEndPoints" bson:"pcfIpEndPoints,omitempty"` + // String identifying a IPv4 address formatted in the 'dotted decimal' notation as defined in RFC 1166 with the OpenAPI defined 'nullable: true' property. + Ipv4Addr string `json:"ipv4Addr,omitempty" yaml:"ipv4Addr" bson:"ipv4Addr,omitempty"` + IpDomain string `json:"ipDomain,omitempty" yaml:"ipDomain" bson:"ipDomain,omitempty"` + // The IPv6 Address Prefixes of the served UE. + Ipv6Prefixes []string `json:"ipv6Prefixes,omitempty" yaml:"ipv6Prefixes" bson:"ipv6Prefixes,omitempty"` + // The MAC Addresses of the served UE. + MacAddrs []string `json:"macAddrs,omitempty" yaml:"macAddrs" bson:"macAddrs,omitempty"` + // String uniquely identifying a NF instance. The format of the NF Instance ID shall be a Universally Unique Identifier (UUID) version 4, as described in IETF RFC 4122. + PcfId string `json:"pcfId,omitempty" yaml:"pcfId" bson:"pcfId,omitempty"` + // NF Set Identifier (see clause 28.12 of 3GPP TS 23.003), formatted as the following string \"set.set.5gc.mnc.mcc\", or \"set.set.5gc.nid.mnc.mcc\" with encoded as defined in clause 5.4.2 (\"Mcc\" data type definition) encoding the Mobile Network Code part of the PLMN, comprising 3 digits. If there are only 2 significant digits in the MNC, one \"0\" digit shall be inserted at the left side to fill the 3 digits coding of MNC. Pattern: '^[0-9]{3}$' encoded as a value defined in Table 6.1.6.3.3-1 of 3GPP TS 29.510 but with lower case characters encoded as a string of characters consisting of alphabetic characters (A-Z and a-z), digits (0-9) and/or the hyphen (-) and that shall end with either an alphabetic character or a digit. + PcfSetId string `json:"pcfSetId,omitempty" yaml:"pcfSetId" bson:"pcfSetId,omitempty"` + BindLevel BindingLevel `json:"bindLevel,omitempty" yaml:"bindLevel" bson:"bindLevel,omitempty"` +} diff --git a/models/model_pcf_for_ue_binding.go b/models/model_pcf_for_ue_binding.go new file mode 100644 index 00000000..21649e6d --- /dev/null +++ b/models/model_pcf_for_ue_binding.go @@ -0,0 +1,32 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package models + +// Identifies an Individual PCF for a UE binding. +type PcfForUeBinding struct { + // String identifying a Supi that shall contain either an IMSI, a network specific identifier, a Global Cable Identifier (GCI) or a Global Line Identifier (GLI) as specified in clause 2.2A of 3GPP TS 23.003. It shall be formatted as follows - for an IMSI \"imsi-\", where shall be formatted according to clause 2.2 of 3GPP TS 23.003 that describes an IMSI. - for a network specific identifier \"nai-, where shall be formatted according to clause 28.7.2 of 3GPP TS 23.003 that describes an NAI. - for a GCI \"gci-\", where shall be formatted according to clause 28.15.2 of 3GPP TS 23.003. - for a GLI \"gli-\", where shall be formatted according to clause 28.16.2 of 3GPP TS 23.003.To enable that the value is used as part of an URI, the string shall only contain characters allowed according to the \"lower-with-hyphen\" naming convention defined in 3GPP TS 29.501. + Supi string `json:"supi" yaml:"supi" bson:"supi,omitempty"` + // String identifying a Gpsi shall contain either an External Id or an MSISDN. It shall be formatted as follows -External Identifier= \"extid-'extid', where 'extid' shall be formatted according to clause 19.7.2 of 3GPP TS 23.003 that describes an External Identifier. + Gpsi string `json:"gpsi,omitempty" yaml:"gpsi" bson:"gpsi,omitempty"` + // Fully Qualified Domain Name + PcfForUeFqdn string `json:"pcfForUeFqdn,omitempty" yaml:"pcfForUeFqdn" bson:"pcfForUeFqdn,omitempty"` + // IP end points of the PCF hosting the Npcf_AmPolicyAuthorization service. + PcfForUeIpEndPoints []IpEndPoint `json:"pcfForUeIpEndPoints,omitempty" yaml:"pcfForUeIpEndPoints" bson:"pcfForUeIpEndPoints,omitempty"` + // String uniquely identifying a NF instance. The format of the NF Instance ID shall be a Universally Unique Identifier (UUID) version 4, as described in IETF RFC 4122. + PcfId string `json:"pcfId,omitempty" yaml:"pcfId" bson:"pcfId,omitempty"` + // NF Set Identifier (see clause 28.12 of 3GPP TS 23.003), formatted as the following string \"set.set.5gc.mnc.mcc\", or \"set.set.5gc.nid.mnc.mcc\" with encoded as defined in clause 5.4.2 (\"Mcc\" data type definition) encoding the Mobile Network Code part of the PLMN, comprising 3 digits. If there are only 2 significant digits in the MNC, one \"0\" digit shall be inserted at the left side to fill the 3 digits coding of MNC. Pattern: '^[0-9]{3}$' encoded as a value defined in Table 6.1.6.3.3-1 of 3GPP TS 29.510 but with lower case characters encoded as a string of characters consisting of alphabetic characters (A-Z and a-z), digits (0-9) and/or the hyphen (-) and that shall end with either an alphabetic character or a digit. + PcfSetId string `json:"pcfSetId,omitempty" yaml:"pcfSetId" bson:"pcfSetId,omitempty"` + BindLevel BindingLevel `json:"bindLevel,omitempty" yaml:"bindLevel" bson:"bindLevel,omitempty"` + // A string used to indicate the features supported by an API that is used as defined in clause 6.6 in 3GPP TS 29.500. The string shall contain a bitmask indicating supported features in hexadecimal representation Each character in the string shall take a value of \"0\" to \"9\", \"a\" to \"f\" or \"A\" to \"F\" and shall represent the support of 4 features as described in table 5.2.2-3. The most significant character representing the highest-numbered features shall appear first in the string, and the character representing features 1 to 4 shall appear last in the string. The list of features and their numbering (starting with 1) are defined separately for each API. If the string contains a lower number of characters than there are defined features for an API, all features that would be represented by characters that are not present in the string are not supported. + SuppFeat string `json:"suppFeat,omitempty" yaml:"suppFeat" bson:"suppFeat,omitempty"` +} diff --git a/models/model_pcf_for_ue_binding_patch.go b/models/model_pcf_for_ue_binding_patch.go new file mode 100644 index 00000000..c90ba102 --- /dev/null +++ b/models/model_pcf_for_ue_binding_patch.go @@ -0,0 +1,23 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package models + +// Identifies the updates of an Individual PCF for a UE binding. +type PcfForUeBindingPatch struct { + // Fully Qualified Domain Name + PcfForUeFqdn string `json:"pcfForUeFqdn,omitempty" yaml:"pcfForUeFqdn" bson:"pcfForUeFqdn,omitempty"` + // IP end points of the PCF hosting the Npcf_AmPolicyAuthorization service. + PcfForUeIpEndPoints []IpEndPoint `json:"pcfForUeIpEndPoints,omitempty" yaml:"pcfForUeIpEndPoints" bson:"pcfForUeIpEndPoints,omitempty"` + // String uniquely identifying a NF instance. The format of the NF Instance ID shall be a Universally Unique Identifier (UUID) version 4, as described in IETF RFC 4122. + PcfId string `json:"pcfId,omitempty" yaml:"pcfId" bson:"pcfId,omitempty"` +} diff --git a/models/model_pcf_for_ue_info.go b/models/model_pcf_for_ue_info.go new file mode 100644 index 00000000..a1cbe1f0 --- /dev/null +++ b/models/model_pcf_for_ue_info.go @@ -0,0 +1,26 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package models + +// Contains the information of the PCF for a UE. +type PcfForUeInfo struct { + // Fully Qualified Domain Name + PcfFqdn string `json:"pcfFqdn,omitempty" yaml:"pcfFqdn" bson:"pcfFqdn,omitempty"` + // IP end points of the PCF hosting the Npcf_AmPolicyAuthorization service. + PcfIpEndPoints []IpEndPoint `json:"pcfIpEndPoints,omitempty" yaml:"pcfIpEndPoints" bson:"pcfIpEndPoints,omitempty"` + // String uniquely identifying a NF instance. The format of the NF Instance ID shall be a Universally Unique Identifier (UUID) version 4, as described in IETF RFC 4122. + PcfId string `json:"pcfId,omitempty" yaml:"pcfId" bson:"pcfId,omitempty"` + // NF Set Identifier (see clause 28.12 of 3GPP TS 23.003), formatted as the following string \"set.set.5gc.mnc.mcc\", or \"set.set.5gc.nid.mnc.mcc\" with encoded as defined in clause 5.4.2 (\"Mcc\" data type definition) encoding the Mobile Network Code part of the PLMN, comprising 3 digits. If there are only 2 significant digits in the MNC, one \"0\" digit shall be inserted at the left side to fill the 3 digits coding of MNC. Pattern: '^[0-9]{3}$' encoded as a value defined in Table 6.1.6.3.3-1 of 3GPP TS 29.510 but with lower case characters encoded as a string of characters consisting of alphabetic characters (A-Z and a-z), digits (0-9) and/or the hyphen (-) and that shall end with either an alphabetic character or a digit. + PcfSetId string `json:"pcfSetId,omitempty" yaml:"pcfSetId" bson:"pcfSetId,omitempty"` + BindLevel BindingLevel `json:"bindLevel,omitempty" yaml:"bindLevel" bson:"bindLevel,omitempty"` +} diff --git a/models/model_pcf_mbs_binding.go b/models/model_pcf_mbs_binding.go new file mode 100644 index 00000000..dfc3cfb6 --- /dev/null +++ b/models/model_pcf_mbs_binding.go @@ -0,0 +1,34 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package models + +import ( + "time" +) + +// Represents an Individual PCF for an MBS Session binding. +type PcfMbsBinding struct { + MbsSessionId *MbsSessionId `json:"mbsSessionId" yaml:"mbsSessionId" bson:"mbsSessionId,omitempty"` + // Fully Qualified Domain Name + PcfFqdn string `json:"pcfFqdn,omitempty" yaml:"pcfFqdn" bson:"pcfFqdn,omitempty"` + PcfIpEndPoints []IpEndPoint `json:"pcfIpEndPoints,omitempty" yaml:"pcfIpEndPoints" bson:"pcfIpEndPoints,omitempty"` + // String uniquely identifying a NF instance. The format of the NF Instance ID shall be a Universally Unique Identifier (UUID) version 4, as described in IETF RFC 4122. + PcfId string `json:"pcfId,omitempty" yaml:"pcfId" bson:"pcfId,omitempty"` + // NF Set Identifier (see clause 28.12 of 3GPP TS 23.003), formatted as the following string \"set.set.5gc.mnc.mcc\", or \"set.set.5gc.nid.mnc.mcc\" with encoded as defined in clause 5.4.2 (\"Mcc\" data type definition) encoding the Mobile Network Code part of the PLMN, comprising 3 digits. If there are only 2 significant digits in the MNC, one \"0\" digit shall be inserted at the left side to fill the 3 digits coding of MNC. Pattern: '^[0-9]{3}$' encoded as a value defined in Table 6.1.6.3.3-1 of 3GPP TS 29.510 but with lower case characters encoded as a string of characters consisting of alphabetic characters (A-Z and a-z), digits (0-9) and/or the hyphen (-) and that shall end with either an alphabetic character or a digit. + PcfSetId string `json:"pcfSetId,omitempty" yaml:"pcfSetId" bson:"pcfSetId,omitempty"` + BindLevel BindingLevel `json:"bindLevel,omitempty" yaml:"bindLevel" bson:"bindLevel,omitempty"` + // string with format 'date-time' as defined in OpenAPI. + RecoveryTime *time.Time `json:"recoveryTime,omitempty" yaml:"recoveryTime" bson:"recoveryTime,omitempty"` + // A string used to indicate the features supported by an API that is used as defined in clause 6.6 in 3GPP TS 29.500. The string shall contain a bitmask indicating supported features in hexadecimal representation Each character in the string shall take a value of \"0\" to \"9\", \"a\" to \"f\" or \"A\" to \"F\" and shall represent the support of 4 features as described in table 5.2.2-3. The most significant character representing the highest-numbered features shall appear first in the string, and the character representing features 1 to 4 shall appear last in the string. The list of features and their numbering (starting with 1) are defined separately for each API. If the string contains a lower number of characters than there are defined features for an API, all features that would be represented by characters that are not present in the string are not supported. + SuppFeat string `json:"suppFeat,omitempty" yaml:"suppFeat" bson:"suppFeat,omitempty"` +} diff --git a/models/model_pcf_mbs_binding_patch.go b/models/model_pcf_mbs_binding_patch.go new file mode 100644 index 00000000..b4564cd9 --- /dev/null +++ b/models/model_pcf_mbs_binding_patch.go @@ -0,0 +1,22 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package models + +// Represents the requested modification to an Individual PCF for an MBS Session binding. +type PcfMbsBindingPatch struct { + // Fully Qualified Domain Name + PcfFqdn string `json:"pcfFqdn,omitempty" yaml:"pcfFqdn" bson:"pcfFqdn,omitempty"` + PcfIpEndPoints []IpEndPoint `json:"pcfIpEndPoints,omitempty" yaml:"pcfIpEndPoints" bson:"pcfIpEndPoints,omitempty"` + // String uniquely identifying a NF instance. The format of the NF Instance ID shall be a Universally Unique Identifier (UUID) version 4, as described in IETF RFC 4122. + PcfId string `json:"pcfId,omitempty" yaml:"pcfId" bson:"pcfId,omitempty"` +} diff --git a/models/model_snssai_dnn_pair.go b/models/model_snssai_dnn_pair.go new file mode 100644 index 00000000..f6d2c241 --- /dev/null +++ b/models/model_snssai_dnn_pair.go @@ -0,0 +1,20 @@ +/* + * Nbsf_Management + * + * Binding Support Management Service API. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved. + * + * Source file: 3GPP TS 29.521 V17.7.0; 5G System; Binding Support Management Service. + * Url: https://www.3gpp.org/ftp/Specs/archive/29_series/29.521/ + * + * API version: 1.3.1 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package models + +// Contains a S-NSSAI and DNN combination. +type SnssaiDnnPair struct { + // String representing a Data Network as defined in clause 9A of 3GPP TS 23.003; it shall contain either a DNN Network Identifier, or a full DNN with both the Network Identifier and Operator Identifier, as specified in 3GPP TS 23.003 clause 9.1.1 and 9.1.2. It shall be coded as string in which the labels are separated by dots (e.g. \"Label1.Label2.Label3\"). + Dnn string `json:"dnn" yaml:"dnn" bson:"dnn,omitempty"` + Snssai *Snssai `json:"snssai" yaml:"snssai" bson:"snssai,omitempty"` +}