3 Common Services REST Specifications

This chapter provides information about the REST specifications for Common Services used in Oracle Communications Cloud Native Core Converged Policy. You can use the following APIs to update configurations related to the Overload Control feature.

3.1 OAuth Validator REST API Configuration

This REST API configuration is required for enabling access token validation using NRF Instance ID and key-ID (K-ID).

Before this configuration, perform the prerequisite steps and helm configuration explained in "Configuring Secrets to Enable Access Token " section in Oracle Communications Cloud Native Core, Converged Policy Installation, Upgrade and Fault Recovery Guide.

After the Helm configuration, send the REST requests to Ingress Gateway to use configured public key certificates. Using REST-based configuration, you can distinguish between the certificates configured on different NRFs and can use these certificates to validate the token received from a specific NRF.

This REST API configuration is required for enabling access token validation using NRF Instance ID and key-ID (K-ID). This URI can be used to update oauth configuration that is used for validating token sent in request to Ingress Gateway. By default, the instanceIdlist and keyIdList are null and validation mode is INSTANCEID_ONLY.

Table 3-1 OAuth Validator Configuration

Description HTTP Method or Custom Operation Resource URI Content Type

Update or Add oauth configuration that will be used for validating token sent in request to Ingress Gateway.

Note: By default, instanceIdList, keyIdList are null and validation mode is INSTANCEID_ONLY. This configuration is only applicable when oauth feature is enabled via Helm chart.

PUT

/{nfType}/nf-common-component/v1/{serviceName}/oauthvalidatorconfiguration

Example:

http://10.75.152.236:8000/pcf/nf-common-component/v1/igw/oAuthValidatorConfiguration
application/json
Sample JSON:

"oAuthValidatorConfiguration": {
   "type": "object",
   "description": "Validator configurations for oAuth",
   "properties": {
      "keyIdList": {
         "type": ["array","null"],
         "uniqueItems": true, 
         "maxItems": 150,
         "description": "Array containing KID based configuration",
         "items": {
            "anyOf": [
               {
                  "type": "object",
                  "properties": {
                     "keyId":{"type": "string",  "minLength": 1, "maxLength": 36,"pattern": "[a-zA-Z0-9]"},
                     "kSecretName": {"type": "string"},
                     "certName": {"type": "string"},
                     "certAlgorithm": {"type": "string"}
                  },
                  "required": [
                     "keyId",
                     "kSecretName",
                     "certName",
                     "certAlgorithm"
		     ]
               }
            ]
         }
      },
      "instanceIdList": {
         "type": ["array","null"],
         "uniqueItems": true,
         "maxItems": 150,
         "description": "Array containing Instance Id based configuration",
         "items": {
            "anyOf": [
               {
                  "type": "object",
                  "properties": {
                     "instanceId": {"type": "string"},
                     "kSecretName": {"type": "string"},
                     "certName": {"type": "string"},
                     "certAlgorithm": {"type": "string"}
                  },
                  "required": [
                     "instanceId",
                     "kSecretName",
                     "certName",
                     "certAlgorithm"
		    ]
               }
            ]
         }
      },
      "oauthValidationMode": {
         "type": "string",
         "enum": [
            "KID_ONLY",
            "INSTANCEID_ONLY",
            "KID_PREFERRED"
	  ],
         "description": "Mode of validation"
        }
    }
}

3.2 CCA Header Validation

Table 3-2 CCA Header Validation APIs

API Description HTTP Method or Custom Operation Resource URI Description Possible Result Code
GET CCA header information. GET

{apiRoot}/{nfType}/nf-common-component/v1/igw/ccaheader

Content Type: application/json

Gets the details stored in DB for property ccaheader. See Table A-1
Update the CCA details using PUT. PUT

{apiRoot}/{nfType}/nf-common-component/v1/igw/ccaheader

Content Type: application/json

Replaces the existing values with the new value sent. See Table A-2
Update the CCA details using PATCH. PATCH

{apiRoot}/{nfType}/nf-common-component/v1/igw/ccaheader

Content Type: application/json

Updates the value of the parameters modified. See Table A-2

Get and Update Operations

Table 3-3 Request/Response Body Parameters

Attribute Name Data Type Mandatory(M)/Optional(O)/Conditional(C) Description
enabled boolean M Indicates if the CCA validation feature flag is enabled or disabled.

Note: This is a read-only parameter.

If you want to enable this feature, use metadata.ccaHeaderValidation.enabled parameter in routesConfig for accesstoken_mapping id in Helm.

Constraints: true, false

Default Value: false

minExpiryTime integer NA Indicates the minimum time of expiry for the CA Root certificate.

Default Value: 0

maxTokenAge integer M Indicates the maximum token age allowed.

Note: It skips the check if the value is 0.

Constraints: 0 - 86400 seconds

Default Value: 0

role string M Indicates the CCA token validator role to match the audience claim in the header.

Note: This is a read-only parameter.

Default Value: NRF

subKey string M Indicates if the certificate extension name to be read in the public key certificate received in CCA request.

Note: This is a read-only parameter.

Default Value: subjectAltName

validationRule string M Indicates the CCA validation rule.
  • strict: NRF validation rules are applied.
  • relaxed: "Issued At" validation is not mandatory. Validation rules are applied to Producer NF.

Constraints: strict, relaxed

Default Value: strict

k8SecretName string M Indicates the name of the Kubernetes secret in which the CA bundle is present.

Note: After fresh installation, these attributes must be configured with appropriate values as per the system requirement using the Rest API as these values are sample ones.

Example k8SecretName: ocnrfaccesstoken-secret

k8NameSpace string M Indicates the Kubernetes namespace in which CA bundle is present.

Note: After fresh installation, these attributes must be configured with appropriate values as per the system requirement using the Rest API as these values are sample ones.

Example k8NameSpace: b2-gate-zeta-13775736-pcf1

fileName string M Indicates the name of the CA bundle file used for CCA. This is the file generated by certificate and key generation steps.

Note: After fresh installation, these attributes must be configured with appropriate values as per the system requirement using the Rest API as these values are sample ones.

Example: fileName: caroot.cer

Sample Body Request:

"role":"NRF",
"subKey":"subjectAltName",
"enabled":true,
"fileName":"caroot.cer",
"k8NameSpace":"b2-gate-zeta-13775736-pcf1",
"maxTokenAge":10,
"k8SecretName":"ocnrfaccesstoken-secret",
"minExpiryTime":1000,
"validationRule":"strict"

3.3 Egress Gateway for SCP Health

Peer Configuration

Table 3-4 Peer Configuration supported REST APIs details:

Description HTTP Method or Custom Operation Resource URI Content Type Possible Result Codes
Get Peer Configuration GET /{nfType}/nf-common-component/v1/{serviceName}/peerconfiguration application/json See Table A-1
Update Peer Configuration PUT /{nfType}/nf-common-component/v1/{serviceName}/peerconfiguration application/json See Table A-2
Get All Peer Configuration GET /{nfType}/nf-common-component/v1/{serviceName}/{instanceId}/peerconfiguration application/json See Table A-1
Update All Peer Configurations PUT /{nfType}/nf-common-component/v1/{serviceName}/{instanceId}/peerconfiguration application/json See Table A-2

Table 3-5 Request/Response Body Parameters

Field Name Data Type Mandatory(M)/ Optional(O)/ Conditional(C) Description
id string O Peer identifier

Note: Unique value in peerconfiguration

host string O Host details of a peer.It can be IPv4, IPv6 and FQDN details.
virtualHost string O Host details of a remote peer. For SLF feature, the virtualHost is SCP peer details. It must be a valid FQDN.This FQDN is sent to Alternate Route Service for DNS SRV resolution.
port string O Port details of a peer.
apiPrefix string O API prefix details of a peer.

Note: Keep the value as '/' only

healthApiPath string O

Path of health API /scp-api-root/v1/status. This attribute is added to maintain the health status of the API.

This attribute is added as part of monitoring the availability of SCP health status.

Peer Monitoring Configuration

Table 3-6 Peer Monitoring Configuration supported REST APIs details:

Description HTTP Method or Custom Operation Resource URI Content Type Possible Result Codes
Get Peer Monitoring Configuration GET /{nfType}/nf-common-component/v1/{serviceName}/peermonitoringconfiguration application/json See Table A-1
Update Peer Monitoring Configuration PUT /{nfType}/nf-common-component/v1/{serviceName}/peermonitoringconfiguration application/json See Table A-2
Get All of Peer Monitoring Configuration GET /{nfType}/nf-common-component/v1/{serviceName}/{instanceId}/peermonitoringconfiguration application/json See Table A-1
Update All of Peer Monitoring Configurations PUT /{nfType}/nf-common-component/v1/{serviceName}/{instanceId}/peermonitoringconfiguration application/json See Table A-2

Table 3-7 Request/Response Body Parameters

Field Name Data Type Mandatory(M)/ Optional(O)/ Conditional(C) Description
enabled Boolean O

Attribute to enable or disable monitoring at a global level.

Default value: false

timeout Long O

Flag to configure the duration after which calls to the SCP health API is timed out. This is provided in milliseconds. The allowed value ranges from 300 milliseconds to 10000 milliseconds.

Default value: 1000

frequency Long O

Indicates the frequency or interval at which Egress Gateway microservice initiates health check calls toward SCP. This is provided in milliseconds. The allowed value ranges from 300 milliseconds to 10000 milliseconds.

Default value: 2000

failureThreshold Integer O

Indicates the number of consecutive failure responses after which a healthy SCP can be marked as unhealthy. The allowed value ranges 1 to 10.

The maximum number of attempts to mark SCP unhealthy is 10.

Default value: 3

successThreshold Integer O

Indicates the number of successful responses after which an unhealthy SCP can be marked as healthy.

Health API call to given SCP shall succeed consecutively to these many attempts before it is marked as Available from UNAVAILABLE. The allowed value ranges 1 to 10.

Default value: 3

Sample body:
{      
    "enabled":true,              
    "timeout":1000,      
    "frequency":2000,      
    "failureThreshold":3,      
    "successThreshold":3   
}

Peer Set Configuration

Table 3-8 Peerset Configuration supported REST APIs details:

Description HTTP Method or Custom Operation Resource URI Content Type Possible Result Codes
Get Peerset Configuration GET {apiRoot}/egw/healthStatus/peerSet/{peerSetId} application/json See Table A-1
List of Peerset Configuration GET {apiRoot}/egw/healthStatus/peerSet application/json See Table A-1
Get the list of peer sets wherein each peer set consists of ID and list of http or https instances. GET /{nfType}/nf-common-component/v1/{serviceName}/peersetconfiguration application/json See Table A-1
Add or update the list of peer sets wherein each peer set consists of ID and list of http or https instances. PUT, PATCH, /{nfType}/nf-common-component/v1/{serviceName}/peersetconfiguration application/json see Table A-2

Table 3-9 Request/Response Body Parameters

Field Name Data Type Mandatory(M)/ Optional(O)/ Conditional(C) Description
id string O Identifier for Peer Set
httpConfiguration array(PeerIdentiferConfiguration) O Configuration for HTTP based Peers. This value will be selected, if 3GPPAPIRootScheme value is http
httpsConfiguration array(PeerIdentifierConfiguration) O Configuration for HTTPs based Peers. This value will be selected, if 3GPPAPIRootScheme value is https

Table 3-10 PeerIdentifierConfiguration

Field Name Data Type Mandatory(M)/ Optional(O)/ Conditional(C) Description
priority integer O Priority of peer to be used in a peer set
peerIdentifier string O Peer identifier is the value of peer configured during PeerConfiguration
Sample body:

 peerSetConfiguration[
    {
        "id":"set0",
        "httpConfiguration":[
        {
        "priority": 1,
                "peerIdentifier": "peer1"
        }],
        "httpsConfiguration":[
        {
        "priority": 1,
                "peerIdentifier": "peer1"
        }]
	

3.4 OC Policy Mapping

This URI can be used to update service names and corresponding policy name for the service which is mapped to "ocDiscardPolicies" based on "policyName" and also to enable/disable the Overload Control feature and the sampling period in overload control. By default, the Overload Control feature is disabled and the sampling period is the 60s. To enable the feature, REST API needs to be invoked and update the enabled flag to true.

Table 3-11 Supported REST APIs

Description HTTP Method or Custom Operation Resource URI
Get OC Policy Mapping GET PCF/nf-common-component/v1/{serviceName}/ocpolicymapping
Update OC Policy Mapping PUT PCF/nf-common-component/v1/{serviceName}/{instanceId}/ocpolicymapping
Partially OC Policy Mapping PATCH PCF/nf-common-component/v1/{serviceName}/{instanceId}/ocpolicymapping

Get, Update, and Patch OCPolicyMapping

Table 3-12 Request/Response Body Parameters

Field Name Data Type Mandatory(M)/Optional(O)/Conditional(C)aints Description
enabled

boolean

M To enable or disable Overload Control feature. Set values to:
  • true: To enable
  • false: To disable
mappings.svcName string M The SVC entry to determine a mapping between service and discard policy name per service.
mappings.policyName string M The discard policy entry to determine a mapping between service and discard policy name per service.
samplingPeriod integer M Time frame for each cycle of Overload Control per service. Its value is in milliseconds.

Sample Request/Response body structure for GET, PUT, and PATCH operations:

{
   "enabled": true,
   "mappings": [
   {
     "svcName": "sm.pcf.com",
     "policyName": "OCDP1"
   },
   {
     "svcName": "cm.pcf.com",
     "policyName": "OCDP2"
   },
   {
     "svcName": "localhost",
     "policyName": "OCDP3"
   }],
   "samplingPeriod": 200
}

3.5 Error Code Profiles

This URI can be used to update the errorCodeProfiles that are used in Overload Control feature for populating details in error responses when a request is discarded.

By default, the errorCodeProfiles remains null.

Table 3-13 Supported REST APIs

Description HTTP Method or Custom Operation Resource URI
Get error code profiles GET PCF/nf-common-component/v1/{serviceName}/errorcodeprofiles
Update error code profiles PUT PCF/nf-common-component/v1/{serviceName}/{instanceId}/errorcodeprofiles
Partially update the error code profiles PATCH PCF/nf-common-component/v1/{serviceName}/{instanceId}/errorcodeprofiles

Get, Update, and Patch errorCodeProfile

Table 3-14 Request/Response Body Parameters

Field Name Data Type Mandatory(M)/Optional(O)/Conditional(C) Description
name

string

M Error name.
errorCode integer M errorCode field in an errorScenario determines the HttpStatusCode that needs to be populated in ProblemDetails (HttpStatus field) response from IGW when the exception occurred at IGW matches the configured errorScenario's exceptionType field.
errorCause string O

errorCause field in an errorScenario determines the error cause that needs to be populated in ProblemDetails (Cause field) response from IGW when the exception occurred at IGW matches the configured errorScenario's exceptionType parameter.

errorTitle string O

errorTitle field in an errorScenario determines the title that needs to be populated in ProblemDetails (Title field) response from IGW when the exception occurred at IGW matches the configured errorScenario's exceptionType parameter.

redirectURL string O

redirectUrl field in an errorScenario determines the redirection URL, this value is populated in LOCATION header while sending response from IGW. The header is populated only when the exception occurred at IGW matches the configured errorScenario's exceptionType parameter, the errorCode configured for the particular errorScenario lies in 3xx error series and the redirectUrl field for the particular errorScenario is configured appropriately.

retry-after string O

retryAfter field in an errorScenario determines the value in seconds/ particular date after which the service should be retried, this value is populated in Retry-After header while sending response from IGW. The header is populated only when the exception occurred at IGW matches the configured errorScenario's exceptionType parameter, the errorCode configured for the particular errorScenario lies in 3xx error series and the retryAfter field for the particular errorScenario is configured appropriately in seconds.

errorDescription string O errorDescription field in an errorScenario determines the description that needs to be populated in ProblemDetails (Detail field) response from IGW when the exception occurred at IGW matches the configured errorScenario's exceptionType field.

Sample Request/Response body structure for GET, PUT, and PATCH operations:

[
 {
   "name": "error300",
   "errorCode": 300,
   "errorCause": "",
   "errorTitle": "",
   "redirectURL": "",
   "retry-after": "",
   "errorDescription": ""
 },
 {
   "name": "error500",
   "errorCode": 500,
   "errorCause": "",
   "errorTitle": "",
   "redirectURL": "",
   "retry-after": "",
   "errorDescription": ""
 },
 {
   "name": "error429",
   "errorCode": 429,
   "errorCause": "",
   "errorTitle": "",
   "redirectURL": "",
   "retry-after": "",
   "errorDescription": ""
 }
]

3.6 OC Discard Policies

This URI can be used to update discard policies that will be used in overload control to select the appropriate policy from the configured list based on the load level of a particular service. By default, ocDicardPolicies will be null.

Table 3-15 Supported REST APIs

Description HTTP Method or Custom Operation Resource URI
Get Discard Policies GET PCF/nf-common-component/v1/{serviceName}/ocdiscardpolicies
Update Discard Policy PUT PCF/nf-common-component/v1/{serviceName}/{instanceId}/ocdiscardpolicies
Partially update the Discard Policy PATCH PCF/nf-common-component/v1/{serviceName}/{instanceId}/ocdiscardpolicies

Get, Update, and Patch OCDiscardData

Table 3-16 Request/Response Body Parameters

Field Name Data Type Mandatory(M)/Optional(O)/Conditional(C) Description
name

string

M Name of the discarded policy.
scheme string
The value can be:
  • PriorityBased
  • PercentageBased
M Discarded policy scheme.
policies.value integer M Value of priority above which requests are considered as potential candidates for drop. Percentage of requests to drop in the current sampling period over the calculated rate in the previous sampling period.
policies.action string

The vaue can be: RejectWithErrorCode

O Defines the action to be taken on selected requests rejection based on error code.
policies.level string O Defines the overload level.
policies.errorCodeProfile string O The error code profiles.

Sample Request/Response body structure for GET, PUT, and PATCH operations:

[
 {
   "name": "OCDP2",
   "scheme": "PercentageBased",
   "policies": [
   {
     "value": 20,
     "action": "RejectWithErrorCode",
     "level": "L1",
     "errorCodeProfile": "error411"
   },
   {
     "value": 40,
     "action": "RejectWithErrorCode",
     "level": "L2",
     "errorCodeProfile": "error412"
   },
   {
      "value": 60,
      "action": "RejectWithErrorCode",
      "level": "L3",
      "errorCodeProfile": "error413"
   },
   {
     "value": 80,
     "action": "RejectWithErrorCode",
     "level": "L4",
     "errorCodeProfile": "error414"
   },
   {
     "value": 95,
     "action": "RejectWithErrorCode",
     "level": "L5",
     "errorCodeProfile": "error415"
   }]
 },
 {
   "name": "OCDP1",
   "scheme": "PriorityBased",
   "policies": [
   {
     "value": 30,
     "action": "RejectWithErrorCode",
     "level": "Minor",
     "errorCodeProfile": "error300"
   },
   {
     "value": 20,
     "action": "RejectWithErrorCode",
     "level": "Critical",
     "errorCodeProfile": "error500"
   }]
 }
]

3.7 Overload Level Threshold

This URI can be used to configure the Overload Threshold Level. The data is saved in a line with service_name perf-info and used by the overload manager.

Table 3-17 Supported REST APIs

Description HTTP Method or Custom Operation Resource URI
Get Overload Threshold Value of the required SVC (Backend service). GET /PCF/nf-common-component/v1/perf-info/overloadLevelThreshold
Update the Overload Threshold Value of the required SVC (Backend service). PUT /PCF/nf-common-component/v1/perf-info/overloadLevelThreshold
Delete the Overload Threshold Value of the required SVC (Backend service). DELETE /PCF/nf-common-component/v1/perf-info/overloadLevelThreshold

Update overloadLevelThreshold

Table 3-18 Request/Response Body Parameters

Field Name Data Type Mandatory(M)/Optional(O)/Conditional(C) Description
svcName

string

M

Name of the backend service (svcName).

You can configure the threshold values for the following services:
  • PCRF Core
  • Diameter Connector
  • PCF Session Management
  • PCF Access and Mobility
  • PCF UE Policy
  • CHF Connector
  • UDR Connector

Note:

For PCRF-CORE deployment mode, configuring overload level threshold for SM Service, AM Service, and UE Policy Service is not required.

For PCF deployment mode, configuring the overload level threshold for PCRF Core is not required.

metricsThresholdList array M List of criteria used to calculate the load level.
metricsThresholdList.metricsName string M
Name of criteria:
  • cpu
  • svc_pending_count
  • svc_failure_count
  • memory
metricsThresholdList.levelThresholdList array M List of threshold values
metricsThresholdList.levelThresholdList.level string M Specifies the name of the level: L1/L2/L3
metricsThresholdList.levelThresholdList.abatementValue integer M If the metric level goes below this value, load level goes to a lower value.
The abatement values for each of the metrics are as follows:
  • cpu (Calucalted in percentage (%)) and ranges between 1-100

  • svc_pending_count (Accepts an integer value) and ranges between 1 to 1000000

  • svc_failure_count (Accepts an integer value) and ranges between 1 to 1000000

  • memory (Calucalted in percentage (%)) and ranges between 1-100

metricsThresholdList.levelThresholdList.onsetValue integer M

If the metric level goes above this value, load level is set.

The onset value of L1 is less than the abatement value of L2 and the onset value of L2 is less than the abatement value of L3.

The onset values for each of the metrics are as follows:
  • cpu (Calucalted in percentage (%)) and ranges between 1-100

  • svc_pending_count (Accepts an integer value) and ranges between 1 to 1000000

  • svc_failure_count (Accepts an integer value) and ranges between 1 to 1000000

  • memory (Calucalted in percentage (%)) and ranges between 1-100

Sample Request/Response body structure for GET/PUT operation:

[
       {
       "svcName": "ztt-overload-occnp-pcf-sm",
       "metricsThresholdList": [
           {
               "metricsName": "svc_pending_count",
               "levelThresholdList": [
                   {
                       "level": "L1",
                       "onsetValue": 50,
                       "abatementValue": 40
                   },
                   {
                       "level": "L2",
                       "onsetValue": 200,
                       "abatementValue": 180
                   },
                   {
                       "level": "L3",
                       "onsetValue": 400,
                       "abatementValue": 360
                   },
                   {
                       "level": "L4",
                       "onsetValue": 600,
                       "abatementValue": 540
                   },
                   {
                       "level": "L5",
                       "onsetValue": 800,
                       "abatementValue": 720
                   }
               ]
           }
       ]
       }
   ]

3.7.1 Overload Level Threshold Profiles

This URI can be used to configure the Overload Threshold Level Profiles. The data is saved in a line with service_name perf-info and used by the overload manager.

Table 3-19 Supported REST APIs

Description HTTP Method or Custom Operation Resource URI

Get the Overload Threshold Profile of the required SVC (Backend service).

GET /oc-cnpolicy-configuration/v1/overloadlevelThreshold/activeProfile

For details on Request/Response Body Parameters for GET activeProfile, see Table 3-20

Activate the Overload Threshold Profile

PUT /oc-cnpolicy-configuration/v1/overloadlevelThreshold/activeProfile

For details on Request/Response Body Parameters for PUT activeProfile, see Table 3-20

Get all the overload threshold profiles names which includes default and custom profiles

GET /oc-cnpolicy-configuration/v1/overloadlevelThreshold/profiles

For details on Request/Response Body Parameters for GET profiles, see Table 3-21

Get Overload Threshold Value for particular profile.

GET /oc-cnpolicy-configuration/v1/overloadlevelThreshold/profiles/{name}

For details on Request/Response Body Parameters for GET profiles/{name}, see Table 3-22

Adds a new Overload Threshold Profile

POST /oc-cnpolicy-configuration/v1/overloadlevelThreshold/profiles/{name}

For details on Request/Response Body Parameters for POST profiles/{name}, see Table 3-22

Update the profile.

PUT

/oc-cnpolicy-configuration/v1/overloadlevelThreshold/profiles/{name}

For details on Request/Response Body Parameters for PUT profiles/{name}, see Table 3-22

Delete the Overload Threshold Profile of the required SVC (Backend service).

DELETE /oc-cnpolicy-configuration/v1/overloadlevelThreshold/profiles/{name}

Migrate the data from standalone to profile i.e if any overloadlevelThreshold data is already configured then it will migrate that data to profile

name - Name of the profile

activate - if after migration , profile should be activated

POST /oc-cnpolicy-configuration/v1/overloadlevelThreshold/migrate

For details on Request/Response Body Parameters for POST migrate, see Table 3-23

Exports the Overload Threshold Profile. GET

/oc-cnpolicy-configuration/v1/overloadlevelThreshold/export

Imports the Overload Threshold Profile. POST

/oc-cnpolicy-configuration/v1/overloadlevelThreshold/import

For details on Request/Response Body Parameters for POST (import), see Table 3-24.

Table 3-20 Request/Response Body Parameters for GET/PUT activeProfile

Field Name Data Type Mandatory(M)/Optional(O)/Conditional(C) Description
name

string

M Name of the active profile.

Sample Request/Response for GET/PUT activeProfile

{
    "name":"custom"
}

Table 3-21 Request/Response Body Parameters for GET profiles

Field Name Data Type Mandatory(M)/Optional(O)/Conditional(C) Description
name

string

M Name of the profile.
isCustomProfile string M To specify the type of profile: default or custom

Sample Request/Response for GET profiles

[
{
    "name":"default",
    "isCustomProfile":false
},{
    "name":"custom",
    "isCustomProfile":true
}
]

Table 3-22 Request/Response Body Parameters for GET/PUT/POST profiles/{name}

Field Name Data Type Mandatory(M)/Optional(O)/Conditional(C) Description
name

string

M Name of the profile.
value.svcName

string

M

Name of the backend service (svcName).

You can configure the threshold values for the following services:
  • PCRF Core
  • Diameter Connector
  • PCF Session Management
  • PCF Access and Mobility
  • PCF UE Policy
  • CHF Connector
  • UDR Connector

Note:

For PCRF-CORE deployment mode, configuring overload level threshold for SM Service, AM Service, and UE Policy Service is not required.

For PCF deployment mode, configuring the overload level threshold for PCRF Core is not required.

value.metricsThresholdList array M List of criteria used to calculate the load level.
value.metricsThresholdList.metricsName string M
Name of criteria:
  • cpu
  • svc_pending_count
  • svc_failure_count
  • memory
value.metricsThresholdList.levelThresholdList array M List of threshold values
value.metricsThresholdList.levelThresholdList.level string M Specifies the name of the level: L1/L2/L3.
value.metricsThresholdList.levelThresholdList.abatementValue integer M If the metric level goes below this value, load level goes to a lower value.
The abatement values for each of the metrics are as follows:
  • cpu (Calucalted in percentage (%)) and ranges between 1-100

  • svc_pending_count (Accepts an integer value) and ranges between 1 to 1000000

  • svc_failure_count (Accepts an integer value) and ranges between 1 to 1000000

  • memory (Calucalted in percentage (%)) and ranges between 1-100

value.metricsThresholdList.levelThresholdList.onsetValue integer M

If the metric level goes above this value, load level is set.

The onset value of L1 is less than the abatement value of L2 and the onset value of L2 is less than the abatement value of L3.

The onset values for each of the metrics are as follows:
  • cpu (Calucalted in percentage (%)) and ranges between 1-100

  • svc_pending_count (Accepts an integer value) and ranges between 1 to 1000000

  • svc_failure_count (Accepts an integer value) and ranges between 1 to 1000000

  • memory (Calucalted in percentage (%)) and ranges between 1-100

Sample Request/Response for GET/PUT/POST profiles/{name}

{
    "name": "custom",
    "value": [
        {
            "svcName": "service-name-pcrf-core",
            "metricsThresholdList": [
                {
                    "metricsName": "cpu",
                    "levelThresholdList": [
                        {
                            "level": "L1",
                            "onsetValue": 49,
                            "abatementValue": 41
                        },
                        {
                            "level": "L2",
                            "onsetValue": 48,
                            "abatementValue": 47
                        },
                        {
                            "level": "L3",
                            "onsetValue": 52,
                            "abatementValue": 50
                        }
                    ]
                }
            ]
        }
    ]
} 

Table 3-23 Request/Response Body Parameters for POST migrate

Field Name Data Type Mandatory(M)/Optional(O)/Conditional(C) Description
name

string

M Name of the profile to migrate.
activate string M

To activate the profile.

Set value to:
  • true: To activate
  • false: Not to activate

Sample request/response for GET profiles list

{ 
     "name":"migrate_profile",
     "activate":true/false
}

Table 3-24 Request/Response Body Parameters for POST (import)

Field Name Data Type Mandatory(M)/Optional(O)/Conditional(C) Description
exportData.name

string

M Name of the profile.
exportData.value.svcName

string

M

Name of the backend service (svcName).

You can configure the threshold values for the following services:
  • PCRF Core
  • Diameter Connector
  • PCF Session Management
  • PCF Access and Mobility
  • PCF UE Policy
  • CHF Connector
  • UDR Connector

Note:

For PCRF-CORE deployment mode, configuring overload level threshold for SM Service, AM Service, and UE Policy Service is not required.

For PCF deployment mode, configuring the overload level threshold for PCRF Core is not required.

exportData.value.metricsThresholdList array M List of criteria used to calculate the load level.
exportData.value.metricsThresholdList.metricsName string M
Name of criteria:
  • cpu
  • svc_pending_count
  • svc_failure_count
  • memory
exportData.value.metricsThresholdList.levelThresholdList array M List of threshold values
exportData.value.metricsThresholdList.levelThresholdList.level string M Specifies the name of the level: L1/L2/L3.
exportData.value.metricsThresholdList.levelThresholdList.abatementValue integer M If the metric level goes below this value, load level goes to a lower value.
The abatement values for each of the metrics are as follows:
  • cpu (Calucalted in percentage (%)) and ranges between 1-100

  • svc_pending_count (Accepts an integer value) and ranges between 1 to 1000000

  • svc_failure_count (Accepts an integer value) and ranges between 1 to 1000000

  • memory (Calucalted in percentage (%)) and ranges between 1-100

exportData.value.metricsThresholdList.levelThresholdList.onsetValue integer M

If the metric level goes above this value, load level is set.

The onset value of L1 is less than the abatement value of L2 and the onset value of L2 is less than the abatement value of L3.

The onset values for each of the metrics are as follows:
  • cpu (Calucalted in percentage (%)) and ranges between 1-100

  • svc_pending_count (Accepts an integer value) and ranges between 1 to 1000000

  • svc_failure_count (Accepts an integer value) and ranges between 1 to 1000000

  • memory (Calucalted in percentage (%)) and ranges between 1-100

Sample Request/Response Body Parameters for POST (import)

"exportData": [
    {
      "name": "TestProfile",
      "value": [
        {
          "svcName": "pcrf-core",
          "metricsThresholdList": [
            {
              "metricsName": "cpu",
              "levelThresholdList": [
                {
                  "level": "L1",
                  "abatementValue": 41,
                  "onsetValue": 44
                },
                {
                  "level": "L2",
                  "abatementValue": 47,
                  "onsetValue": 49
                },
                {
                  "level": "L3",
                  "abatementValue": 50,
                  "onsetValue": 52
                }
              ]
            },
		}

3.8 NF profile registration with NRF

These URIs can be used to update or retrieve PCF NF profile to be registered with Network Repository Function (NRF).

Table 3-25 Supported REST APIs

Description HTTP Method or Custom Operation Resource URI
Get PCF NfProfile GET PCF/nf-common-component/v1/nrf-client-nfmanagement/nfProfileList
Update PCF NfProfile PUT PCF/nf-common-component/v1/nrf-client-nfmanagement/nfProfileList
The sample request body structure for GET and PUT operation is as follows:
[
   {
      "nfInstanceId":"fe7d992b-0541-4c7d-ab84-c6d70b1b0123",
      "nfType":"PCF",
      "nfStatus":"REGISTERED",
      "plmnList":null,
      "nsiList":null,
      "fqdn":"occnp-ocpm-ingress-gateway.ocpcf.svc",
      "interPlmnFqdn":null,
      "ipv4Addresses":null,
      "ipv6Addresses":null,
      "priority":null,
      "capacity":null,
      "load":80,
      "locality":null,
      "pcfInfo":{
         "dnnList":[
            "internet",
            "volte"
         ],
         "supiRanges":[
            {
               "start":"12123444444",
               "end":"232332323323232",
               "pattern":null
            }
         ]
      },
      "customInfo":null,
      "recoveryTime":null,
      "nfServices":[
         {
            "serviceInstanceId":"03063893-cf9e-4f7a-9827-067f6fa9dd01",
            "serviceName":"npcf-am-policy-control",
            "versions":[
               {
                  "apiVersionInUri":"v1",
                  "apiFullVersion":"1.0.0",
                  "expiry":null
               }
            ],
            "scheme":"http",
            "nfServiceStatus":"REGISTERED",
            "fqdn":"occnp-ocpm-ingress-gateway.ocpcf.svc",
            "interPlmnFqdn":null,
            "ipEndPoints":null,
            "apiPrefix":null,
            "defaultNotificationSubscriptions":null,
            "allowedPlmns":null,
            "allowedNfTypes":[
               "AMF",
               "NEF"
            ],
            "allowedNfDomains":null,
            "allowedNssais":null,
            "priority":null,
            "capacity":null,
            "load":null,
            "recoveryTime":null,
            "supportedFeatures":null
         },
         {
            "serviceInstanceId":"03063893-cf9e-4f7a-9827-067f6fa9dd02",
            "serviceName":"npcf-smpolicycontrol",
            "versions":[
               {
                  "apiVersionInUri":"v1",
                  "apiFullVersion":"1.0.0",
                  "expiry":null
               }
            ],
            "scheme":"http",
            "nfServiceStatus":"REGISTERED",
            "fqdn":"occnp-ocpm-ingress-gateway.ocpcf.svc",
            "interPlmnFqdn":null,
            "ipEndPoints":null,
            "apiPrefix":null,
            "defaultNotificationSubscriptions":null,
            "allowedPlmns":null,
            "allowedNfTypes":[
               "SMF",
               "NEF",
               "AF"
            ],
            "allowedNfDomains":null,
            "allowedNssais":null,
            "priority":null,
            "capacity":null,
            "load":null,
            "recoveryTime":null,
            "supportedFeatures":null
         },
         {
            "serviceInstanceId":"03063893-cf9e-4f7a-9827-067f6fa9dd03",
            "serviceName":"npcf-ue-policy-control",
            "versions":[
               {
                  "apiVersionInUri":"v1",
                  "apiFullVersion":"1.0.0",
                  "expiry":null
               }
            ],
            "scheme":"http",
            "nfServiceStatus":"REGISTERED",
            "fqdn":"occnp-ocpm-ingress-gateway.ocpcf.svc",
            "interPlmnFqdn":null,
            "ipEndPoints":null,
            "apiPrefix":null,
            "defaultNotificationSubscriptions":null,
            "allowedPlmns":null,
            "allowedNfTypes":[
               "AMF"
            ],
            "allowedNfDomains":null,
            "allowedNssais":null,
            "priority":null,
            "capacity":null,
            "load":null,
            "recoveryTime":null,
            "supportedFeatures":null
         }
      ]
   }
]

3.9 Server Header at Ingress Gateway

This section describes the Common Config Server URIs that you can use to enable and configure server header at Ingress Gateway. The server header is included in the error responses sent by Ingress Gateway for the errors generated at Ingress Gateway as well as backend microservices.

Note:

You can configure server header at both global and route level. However, if you define server header configuration at both global and route level, the route level configuration (irrespective of being enabled or disabled) takes precendence over the global level configuration.

Error Code Series List

The following table describes the URIs available to define and retrieve error code series list:

Table 3-26 Supported REST APIs for Error Code Series List

Description HTTP Method or Custom Operation Resource URI
Get Error Code Series List GET {apiRoot}/PCF/nf-common-component/v1/igw/errorcodeserieslist
Define Error Code Series List PUT {apiRoot}/PCF/nf-common-component/v1/igw/errorcodeserieslist
Delete Error Code Series List PUT
To delete the configurations, put an empty json in the request.
[]
{apiRoot}/PCF/nf-common-component/v1/igw/errorcodeserieslist
The sample request body structure for PUT operation is as follows:
[  
    {
        "id": "E1",
        "errorCodeSeries":
        [
            {
                "errorSet": "4xx",
                "errorCodes": [400, 408]
            },
            {
                "errorSet": "5xx",
                "errorCodes": [500, 503]
            }
        ]
    },
    {
        "id": "E2",
        "errorCodeSeries":
        [
            {
                "errorSet": "4xx",
                "errorCodes": [-1]
            }
        ]
    }
]

Table 3-27 Request/Response Body Parameters

Field Name Data Type Mandatory(M)/Optional(O)/Conditional(C) Description
id string M Specifies the unique ID that is used in the errorCodeSeriesId while configuring server header at global or route level.
errorCodeSeries.errorSet string M Specifies an errorSet (4XX, 5XX) in errorCodeSeries for matching server response.
errorCodeSeries.errorCodes array M Specifies the error codes in a specific error set against which the server response is validated for populating server header.

Configuring Server header (global level)

The following table describes the URIs available to enable and configure server header at global level:

Table 3-28 Supported REST APIs

Description HTTP Method or Custom Operation Resource URI
Get Server Header GET /PCF/nf-common-component/v1/igw/serverheaderdetails
Define Server Header PUT /PCF/nf-common-component/v1/igw/serverheaderdetails
The sample request body structure for PUT operation is as follows:
{
		"enabled": false,            # Set to false if we want Server Header to be generated at Route Level   
		"errorCodeSeriesId": "E1",   # See "errorcodeserieslist" resource above for more details.
		"configuration": {
		    "nfType": "PCF",
		    "nfInstanceId": "123456" # NF Instance Id of the PCF
		}
	}

Table 3-29 Request/Response Body Parameters

Field Name Data Type Mandatory(M)/Optional(O)/Conditional(C) Description
enabled

boolean

M When the value for this parameter is set to true, server headers are generated at a global level.

To generate server headers at route level, set the value to false.

errorCodeSeriesId string M Specifies the error list IDs. For more information, see Table 3-26.
configuration.nfType string M Specifies the type of network function.

Default value: PCF

configuration.nfInstanceId string M Specifies the NF Instance ID of the PCF.

Configuring Server header (route level)

The following table describes the URIs available to enable and configure server header at route level:

Table 3-30 Supported REST APIs

Description HTTP Method or Custom Operation Resource URI
Get Route Level Configuration GET /PCF/nf-common-component/v1/igw/routesconfiguration
Define Server Header at Route Level PUT /PCF/nf-common-component/v1/igw/routesconfiguration
The sample request body structure for PUT operation is as follows:
[{
		"id": "sm_create_session_route",
		"serverHeaderDetails": {
		"enabled": true,
		"errorCodeSeriesId": "E1"
	    }
	}]
The sample request body structure to clear route using PUT operation is as follows:
[]

Table 3-31 Request/Response Body Parameters

Field Name Data Type Mandatory(M)/Optional(O)/Conditional(C) Description
id string M Specifies the route IDs for which you need to define server header.
You can define the server header at route level for any of the following supported route IDs:
  • sm_create_session_route
  • sm_delete_session_route
  • sm_update_session_route
  • udr_notify_route
  • chf_terminate_route
  • chf_notify_route
  • pa_create_session_route
  • pa_delete_session_route
  • pa_update_session_route
  • pa_events_subscription_route
  • reverse_ue_service
  • reverse_user_udr_notify_service
  • reverse_user_chf_notify_service
  • reverse_nrf_discovery_service
  • reverse_nrf_management_service
  • reverse_nrf_notify_service
  • reverse_soapconnector_service
  • reverse_ue_service_notify
  • am_create_session_route
  • am_delete_session_route
  • am_update_session_route
serverHeaderDetails.enabled boolean M Set the value for this parameter to true if you want to define server header at the route level.
serverHeaderDetails.errorCodeSeriesId string M Specifies the error list IDs. For more information, see Table 3-26.
The sample request body structure for GET operation is as follows:
[{
	"id":"sm_create_session_route"
}]

3.10 Rate Limiting

3.10.1 Rate Limiting at Ingress Gateway

This section describes the URIs that you can use to configure route level rate limiting in persistent configuration at Ingress Gateway.

Error Code Profiles

The following table describes the URIs available to define and retrieve error code profiles in persistent configuration:

Table 3-32 Supported REST APIs for Error Code Profiles

Description HTTP Method or Custom Operation Resource URI
Get Error Code Profiles GET {apiRoot}/PCF/nf-common-component/v1/igw/errorcodeprofiles
Define Error Code Profiles PUT {apiRoot}/PCF/nf-common-component/v1/igw/errorcodeprofiles
The sample request body structure for PUT operation is as follows:
[{
        "name": "error429",
        "errorCode": 429,
        "errorCause": "Too Many Request",
        "errorTitle": "",
        "redirectURL": "",
        "retry-after": "",
        "errorDescription": ""
    }]

Table 3-33 Request/Response Body Parameters

Field Name Data Type Mandatory(M)/Optional(O)/Conditional(C) Description
name string M Specifies the unique name for the error profile.
errorCode string M errorCode field in an errorScenario determines the HttpStatusCode that needs to be populated in ProblemDetails (HttpStatus field) response from IGW when the exception occurred at IGW matches the configured errorScenario's exceptionType field.
errorCause string M

errorCause field in an errorScenario determines the error cause that needs to be populated in ProblemDetails (Cause field) response from IGW when the exception occurred at IGW matches the configured errorScenario's exceptionType parameter.

errorTitle string O

errorTitle field in an errorScenario determines the title that needs to be populated in ProblemDetails (Title field) response from IGW when the exception occurred at IGW matches the configured errorScenario's exceptionType parameter.

redirectURL string O

redirectUrl field in an errorScenario determines the redirection URL, this value is populated in LOCATION header while sending response from IGW. The header is populated only when the exception occurred at IGW matches the configured errorScenario's exceptionType parameter, the errorCode configured for the particular errorScenario lies in 3xx error series and the redirectUrl field for the particular errorScenario is configured appropriately.

retry-after string O

retryAfter field in an errorScenario determines the value in seconds/ particular date after which the service should be retried, this value is populated in Retry-After header while sending response from IGW. The header is populated only when the exception occurred at IGW matches the configured errorScenario's exceptionType parameter, the errorCode configured for the particular errorScenario lies in 3xx error series and the retryAfter field for the particular errorScenario is configured appropriately in seconds.

errorDescription string O errorDescription field in an errorScenario determines the description that needs to be populated in ProblemDetails (Detail field) response from IGW when the exception occurred at IGW matches the configured errorScenario's exceptionType field.

Configuring Rate Limit for Policy

The following table describes the URIs available to enable and configure ratelimit:

Table 3-34 Supported REST APIs

Description HTTP Method or Custom Operation Resource URI
Get Rate Limit GET {apiRoot}/PCF/nf-common-component/v1/igw/routelevelratelimiting
Define Rate Limit PUT {apiRoot}/PCF/nf-common-component/v1/igw/routelevelratelimiting
The sample request body structure for PUT operation is as follows:
{
   "enabled": true,
   "samplingPeriod": 2000, 
   "rateLimitPolicies": [
   {
     "name": "R1",
     "value": 5,
     "action": "RejectWithErrorCode",
     "scheme": "PriorityBased",
     "errorCodeProfile": "error429"
   }
   ]
}

Table 3-35 Request/Response Body Parameters

Field Name Data Type Mandatory(M)/Optional(O)/Conditional(C) Description
enabled boolean M Specifies whether to enable or disable rate limiting feature.
samplingPeriod   M Specifies the duration for each cycle of route rate limit. The value of sampling period is defined in milliseconds.
rateLimitPolicies.name string M Specifies the unique name of the discard policy.
rateLimitPolicies.value integer M Specifies the value of priority above which requests are considered as potential candidates for drop.
rateLimitPolicies.action string M Specifies the action such as silent drop or rejection for the selected requests.
rateLimitPolicies.scheme string M Specifies the scheme on the basis of which requests are selected to be dropped.

The only supported value for this parameter is PriorityBased.

rateLimitPolicies.errorCodeProfile string M Specifies the error code profile. For more information, seeTable 3-32.

Configuring Rate Limit for Policy at route level

For details on configuring rate limit for policy at route level, see Route Level Configuration.

3.11 Failure Count at Ingress Gateway

This section describes the URIs that you can use to configure failure count at Ingress Gateway.

Configuring Failure Count Overload

Error Code Series List

The following table describes the URIs available to define and retrieve error code series list:

Table 3-36 Supported REST APIs for Error Code Series

Description HTTP Method or Custom Operation Resource URI
Get Error Code Series List GET {apiRoot}/PCF/nf-common- component/v1/igw/errorcodeserieslist
Define Error Code Series List PUT {apiRoot}/PCF/nf-common- component/v1/igw/ errorcodeserieslist
Delete Error Code Series List

PUT

To delete the configurations, put an empty json in the request.

[]

{apiRoot}/PCF/nf-common- component/v1/igw/ errorcodeserieslist
The sample request body structure for PUT operation is as follows:
[
    {
        "id": "E1",
        "errorCodeSeries": [
            {
                "errorSet": "4xx",
                "errorCodes": [
                    400,
                    408
                ]
            },
            {
                "errorCodes": [
                    500,
                    503
                ]
            }
        ]
    },
    {
        "id": "E2",
        "errorCodeSeries": [
            {
                "errorSet": "5xx",
                "errorCodes": [
                    -1
                ]
            }
        ]
    }
]

Table 3-37 Request/Response Body Parameters

Field Name Data Type Mandatory(M)/Optional(O)/Conditional(C) Description
id string M Specifies the unique ID that is used in the errorCodeSeriesId while configuring server header at global or route level.
errorCodeSeries.errorSet string M Specifies an errorSet (4XX, 5XX) in errorCodeSeries for matching server response.
errorCodeSeries.errorCodes array M Specifies the error codes in a specific error set against which the server response is validated for populating server header.

Failure Count for Policy at Route Level

The following table describes the URIs available to define and retrieve failure count at route level:

Table 3-38 Supported REST APIs for Failure Count at Route Level

Description HTTP Method or Custom Operation Resource URI
Get failure count at route level Configuration GET {apiRoot}/PCF/nf-common- component/v1/igw/ routesconfiguration
Define failure count at route level Configuration PUT {apiRoot}/PCF/nf-common- component/v1/igw/ routesconfiguration

For details on configuring the failure count for Policy at route level, see Route Level Configuration.

Configuring both Failure Count and Rate Limiting Overload

Error Code Series List for Failure Count

For details on configuring error code series list for failure count, see Error Code Series List under Configuring Failure Count Overload section.

Error Code Profile for Rate Limiting

For details on configuring error code profile for failure count, see Error Code Profiles in Rate Limiting at Ingress Gateway.

Rate Limit for Policy

For details on configuring rate limit for Policy, see Configuring Rate Limit for Policy in Rate Limiting at Ingress Gateway.

Route Level for Failure Count and Rate Limiting

For details on configuring the route level for failure count and rate limiting, see Route Level Configuration.

3.12 Route Level Configuration

The following table describes the URIs available to enable and configure rate-limit at route level:

Table 3-39 Supported REST APIs

Description HTTP Method or Custom Operation Resource URI
Get Rate Limit at route level Configuration GET {apiRoot}/PCF/nf-common-component/v1/igw/routesconfiguration
Define Rate Limit at route level Configuration PUT {apiRoot}/PCF/nf-common-component/v1/igw/routesconfiguration
The sample request body structure for PUT operation is as follows:
[
    {
        "id": "sm_create_session_route",
        "rateLimiting": {	
            "methods": [
                {
                    "name": "POST",
                    "rate": 3,
                    "rateLimitPolicy": "R1"
                }
            ]
        },
        "failureReqCountErrorCodeSeriesId": "E1"
    },
    {
        "id": "sm_update_session_route",
        "rateLimiting": {
            "methods": [
                {
                    "name": "POST",
                    "rate": 6,
                    "rateLimitPolicy": "R1"
                }
            ]
        },
        "failureReqCountErrorCodeSeriesId": "E1"
    },
    {
        "id": "sm_delete_session_route",
        "rateLimiting": {
            "methods": [
                {
                    "name": "POST",
                    "rate": 3,
                    "rateLimitPolicy": "R1"
                }
            ]
        },
        "failureReqCountErrorCodeSeriesId": "E1"
    }
]

Table 3-40 Request/Response Body Parameters

Field Name Data Type Mandatory(M)/Optional(O)/Conditional(C) Description
id string M Specifies the route IDs for which you need to define the rate limit.

You can define the rate limit at route level for any of the following supported route IDs.

For the list of supported route IDs for each service, see Overload Control section in Oracle Communications Cloud Native Core, Converged Policy User Guide.

rateLimiting.methods.name string O Specifies the name of the HTTP method such as GET, DELETE, or POST. The rate limit is calculated by considering the method along with the route ID.
rateLimiting.methods.rate integer O Specifies the rate for route level rate limit. Any requests with sbi-priority header with a value greater than the configured number are discarded.
rateLimiting.methods.rateLimitPolicy string O Specifies the unique rate limit policy name. For more information, see Table 3-34.
failureReqCountErrorCodeSeriesId string O Specifies the mapping between error series and failure count.

3.13 Controlled Shutdown at Ingress and Diameter Gateway

This section describes the URIs that you can use to enable and configure Controlled Shutdown at Ingress and Diameter Gateway.

Operational State

The following table describes the URIs available to define and retrieve operational state:

Table 3-41 Supported REST APIs for Operational State

Description HTTP Method or Custom Operation Resource URI
GET Operational State GET {apiRoot}/controlledShutdown/operationalState
PUT Operational State PUT {apiRoot}/controlledShutdown/operationalState
The sample request body structure for PUT operation is as follows:

{
  "operationalState": "NORMAL"
}

Table 3-42 Request/Response Body Parameters

Field Name Data Type Mandatory(M)/Optional(O)/Conditional(C) Description
Operational State Enum
  • NORMAL
  • PARTIAL_SHUTDOWN
  • COMPLETE_SHUTDOWN
M Specifies the operational state

Operational State History

The following table describes the URIs available to retrieve operational state history:

Table 3-43 Supported REST APIs for Operational State History

Description HTTP Method or Custom Operation Resource URI
GET Operational State History GET {apiRoot}/oc-cnpolicy-configuration/v1/controlledShutdown/operationalStateHistory
The sample request body structure for GET operation is as follows:
[
  {
    "id": "ea01053b-5a3b-4de2-850b-7210bf2a04d5",
    "type": "operationalState",
    "value": "{\"state\":\"NORMAL\"}",
    "timeStamp": "2022-08-30T08:12:45.88519",
    "status": "SUCCESS"
  }
]

Table 3-44 Request/Response Body Parameters

Field Name Data Type Description
id UUID Auto-generated ID
type String Type of historical data
value String Operational state value
timeStamp Date Logs the timestamp when the operational state event took place
status String
  • Success: Successful in switching of operational state
  • Failure: Fail in switching of operational state

Table 3-45 Request Parameters

Field Name Data Type Mandatory(M)/ Optional(O)/ Conditional(C) Description
Offset Integer O Offset is a position in the set of records.
Limit Integer O Limit as an option allows to limit the number of rows returned from a query.
Page Integer O Page shows the number of records.

Note:

If offset and Limit are not provided in the API, then the query fetches all the records from the database.

Controlled Shutdown Error Mapping

The following table describes the URIs available to define and retrieve Controlled Shutdown Error Mapping:

Table 3-46 Supported REST APIs for Controlled Shutdown Error Mapping

Description HTTP Method or Custom Operation Resource URI
GET Controlled Shutdown Error Mapping GET {apiRoot}/oc-cnpolicy-configuration/v1/controlledShutdown/errorMapping
PUT Controlled Shutdown Error Mapping PUT {apiRoot}/oc-cnpolicy-configuration/v1/controlledShutdown/errorMapping
The sample request body structure for PUT operation is as follows:
{
    "routeErrorProfileList": [
        {
            "errorProfileName": "ERR_400",
            "routeIds": [
                "sm_update_session_route"
            ]
        },
        {
            "errorProfileName": "ERR_100",
            "routeIds": [
                "sm_create_session_route"
            ]
        },
        {
            "routeIds": [
                "sm_delete_session_route",
                "udr_notify_route"
            ],
            "errorProfileName": "ERR_1200"
        }
    ]
}

Table 3-47 Request/Response Body Parameters

Field Name Data Type Mandatory(M)/Optional(O)/Conditional(C) Description
routeErrorProfileList Array M Specifies the route error profile list.
routeErrorProfileList.routeIDs Array M

Specifies the route ID.

You can define the server header at route level for any of the following supported route IDs:
  • sm_create_session_route
  • sm_delete_session_route
  • sm_update_session_route
  • udr_notify_route
  • chf_terminate_route
  • chf_notify_route
  • pa_create_session_route
  • pa_delete_session_route
  • pa_update_session_route
  • pa_events_subscription_route
  • pa_events_unsubscription_route
  • am_create_session_route
  • am_delete_session_route
  • am_update_session_route
  • ue_create_session_route
  • ue_update_session_route
  • ue_delete_session_route
  • n1_message_notify
  • reverse_soapconnector_service
  • reverse_nrf_notify_service
  • binding_audit_notify_route
  • udr_um_notify_route
routeErrorProfileList.errorProfileName String M Specifies the error code profile.

Message Type

The following table describes the URIs available to define and retrieve Message Type:

Table 3-48 Supported REST APIs for Message Type

Description HTTP Method or Custom Operation Resource URI
GET Message Type GET {apiRoot}/oc-cnpolicy-configuration/v1/diameter/controlledshutdown/errormappings/{messageType}
PUT Message Type PUT {apiRoot}/oc-cnpolicy-configuration/v1/diameter/controlledshutdown/errormappings/{messageType}
The sample request body structure for PUT operation is as follows:
{
  "messageType": "CER",
  "ansWithResultCode": "CUSTOM_RESULT_CODE",
  "resultCode": "7899",
  "useExperimentalResultCode": true,
  "vendorId": "2"
}

Table 3-49 Request/Response Body Parameters

Field Name Data Type Mandatory(M)/Optional(O)/Conditional(C) Description
messageType String M Type of the request
ansWithResultCode Enum
The supported values are:
  • DIAMETER_TOO_BUSY
  • DIAMETER_UNABLE_TO_COMPLY
  • DIAMETER_UNABLE_TO_DELIVER
  • CUSTOM_RESULT_CODE
M Specifies the result code, returned in the answer response.
resultCode Integer M

Specify a value for this parameter when you choose CUSTOM_RESULT_CODE value for the ansWithResultCode parameter.

Specifies the custom result code, which is returned in the answer response.

.
useExperimentalResultCode Boolean O

Specify a value for this parameter when you choose CUSTOM_RESULT_CODE value for the ansWithResultCode parameter.

Specifies the value of result code by user according to their requirement.

Result code associates with the vendor ID, when the useExperimentalResultCode is true.

vendorId Integer O

Specify a value for this parameter when you choose CUSTOM_RESULT_CODE value for the ansWithResultCode parameter and useExperimentalResultCode is true.

Export/Import

The following table describes the URIs available to define and retrieve Export/Import:

Table 3-50 Supported REST APIs for Export/Import

Description HTTP Method or Custom Operation Resource URI
GET Export GET {apiRoot}/oc-cnpolicy-configuration/v1/diameter/controlledshutdown/errormappings/export
Put Import PUT {apiRoot}/oc-cnpolicy-configuration/v1/diameter/controlledshutdown/errormappings/import
The sample response body structure for PUT operation is as follows:
"exportData": [
    {
      "messageType": "Rx_AAR_I",
      "ansWithResultCode": "CUSTOM_RESULT_CODE",
      "useExperimentalResultCode": false,
      "resultCode": "1300"
    },
    {
      "messageType": "Rx_AAR_U",
      "ansWithResultCode": "DIAMETER_TOO_BUSY",
      "useExperimentalResultCode": false
    },
    {
      "messageType": "STR",
      "ansWithResultCode": "CUSTOM_RESULT_CODE",
      "useExperimentalResultCode": true,
      "resultCode": "2109",
      "vendorId": "1"
    }

Table 3-51 Request/Response Body Parameters

Field Name Data Type Mandatory(M)/Optional(O)/Conditional(C) Description
messageType String M Type of the request
ansWithResultCode Enum
The supported values are:
  • DIAMETER_TOO_BUSY
  • DIAMETER_UNABLE_TO_COMPLY
  • DIAMETER_UNABLE_TO_DELIVER
  • CUSTOM_RESULT_CODE
M Specifies the result code, returned in the answer response.
resultCode Integer M

Specify a value for this parameter when you choose CUSTOM_RESULT_CODE value for the ansWithResultCode parameter.

Specifies the custom result code, which is returned in the answer response.

.
useExperimentalResultCode Boolean O

Specify a value for this parameter when you choose CUSTOM_RESULT_CODE value for the ansWithResultCode parameter.

Specifies the value of result code by user according to their requirement.

Result code associates with the vendor ID, when the useExperimentalResultCode is true.

vendorId Integer O

Specify a value for this parameter when you choose CUSTOM_RESULT_CODE value for the ansWithResultCode parameter and useExperimentalResultCode is true.

3.14 NF Scoring for a Site

The following table describes the URI available to define NF Scoring:

Table 3-52 REST API for NF Scoring

Description HTTP Method or Custom Operation Resource API
GET for NF Score GET /oc-cnpolicy-configuration/v1/nfscore

Table 3-53 Fields

Field Name Mandatory (M)/Optional(O)/Conditional(C) Datatype Description
NF Score M Float The score of a site based on NF-specific factors (metrics, alerts, and so on).
detailedReport M NA Detailed report of NFScore calculation.
scoringFactors M NA Comprises the factors that contributed to the NFScore
criteria C NA

Factors involved in NFScore calculation

Criteria are present for a specific factor If it is enabled for NF-Scoring.

maxScore C Integer

Max score of that factor

maxScore is present for a specific factor If it is enabled for NF-Scoring.

calculatedScore C Float

calculated score of that factor

calculatedScore are present for a specific factor If it is enabled for NF-Scoring.

additionalInfo O NA additional info related to factor's score calculation.
configuredValue C Integer

An expected value configured for a factor

configuredValue is present for a specific factor If it is enabled for NF-Scoring.

actualValue C Float

An actual value for a particular factor after doing factor-specific configuration.

actualValue is present for a specific factor If it is enabled for NF-Scoring.

totalSvcs C Integer

Total configured services.

totalSvcs is present when the factor SVC-Health is enabled

upSvcs C Integer

Total running services.

upSvcs is present when the factor SVC-Health is enabled

totalSites C Integer

Total configured sites

totalSites is present when the factor replicationHealth is enabled.

availableLinks C Integer

Total healthy sites

availableLinks is present when the factor replicationHealth is enabled.

critical C Integer

Critical alert's contribution to alert's calculated score

This attribute is present when ActiveAlerts are enabled as NF-Scoring factor

major C Float

Major alert's contribution to alert's calculated score

This attribute is present when ActiveAlerts are enabled as NF-Scoring factor

minor C Float

Minor alert's contribution to alert's calculated score

This attribute is present when ActiveAlerts are enabled as NF-Scoring factor

failedFactors C Float

Enabled factors that failed to contribute to NFScore

This attribute is present when an application fails to calculate the score for 1 or more factors.

detail C NA

Factor's failure reason

This attribute is present when there are 1 or more failed factors.

Note: When the Enable flag is true for any criteria, then its related fields will be shown.
Sample Response Body for GET NF Score:
{
  "NFScore": 129,
  "detailedReport": {
    "scoringFactors": [
      {
        "criteria": "tps",
        "maxScore": 100,
        "calculatedScore": 75,
        "additionalInfo": {
          "configuredValue": 4000,
          "actualValue": 3000
        }
      },
      {
        "criteria": "serviceHealth",
        "maxScore": 100,
        "calculatedScore": 70,
        "additionalInfo": {
          "totalSvcs": 10,
          "upSvcs": 7
        }
      },
      {
        "criteria": "signallingConnections",
        "maxScore": 100,
        "calculatedScore": 50,
        "additionalInfo": {
          "configuredValue": 50,
          "actualValue": 25
        }
      },
      {
        "criteria": "replicationHealth",
        "maxScore": 100,
        "calculatedScore": 50,
        "additionalInfo": {
          "totalSites": 3,
          "availableLinks": 1
        }
      },
      {
        "criteria": "localityPreference",
        "maxScore": 100, #remove
        "calculatedScore": 100
      },
      {
        "criteria": "activeAlert",
        "score": -30,#rename to "calculatedScore"
        "additionalInfo": {
          "critical": -10,
          "major": -20,
          "minor": 0
        }
      }
    ]
  },
  "failedFactors": [
    {
      "criteria": "replicationHealth",
      "detail": "failed to calculate replicationHealth score"
    }
  ]
}

3.15 Configuration for User-Agent Header Generation at Egress Gateway

Configuring User-Agent Header in Egress Gateway

This section describes the URIs that you can configure for user-agent header generation at Egress Gateway.

The configuration to enable and disable the generation of the user-agent header can be done using REST API exposed by the config-service when sending the following JSON body.

Table 3-54 Supported REST APIs for User-Agent Generation

Description HTTP Method or Custom Operation Resource URI
PUT User-Agent Generation PUT http://<config-service IP>:<config-service PORT>/pcf/nf-common-component/v1/egw/useragentheader

CURL command for PUT Operation: curl -X PUT http://10.75.232.35:8000/pcf/nf-common-component/v1/egw/useragentheader -H "Content-Type: application/json" -d

The sample request body structure for PUT operation is as follows:

{
     "enabled": true,
     "nfType": "PCF",
     "nfInstanceId": "fe7d992b-0541-4c7d-ab84-c6d70b1b0555",
     "nfFqdn": "pcf.oracle.org",
     "addFqdnToHeader": true,
     "overwriteHeader": true
}

Table 3-55 Request Body Parameters

Field Name Data Type Mandatory(M)/Optional(O)/Conditional(C) Description
egress-gateway.userAgentHeader.enabled Boolean M Specifies whether the feature is enabled or disabled.

By default, the value is set to false.

egress-gateway.userAgentHeader.nfType String M This parameter holds the nfType that will be used to generate the user agent header.
egress-gateway.userAgentHeader.nfInstanceId String O This parameter represents the UUID of the CNPCF deployment that will be used to generate the user agent header.
egress-gateway.userAgentHeader.addFqdnToHeader Boolean M This parameter specifies if the user agent will use the FQDN information under the module to append it when generating the user agent header.The default value is set to 'false' meaning that the FQDN information will not be encoded into the user agent header during its generation.

By default, the value is set to false.

egress-gateway.userAgentHeader.nfFqdn String O This is an optional parameter and can be present or not, if operators want to include the FQDN string configured under this section then the parameter userAgentHeader.addFqdnToHeader needs to be enabled.
egress-gateway.userAgentHeader.overwriteHeader Boolean M This parameter is used to govern if we want to include the User-Agent header generated at CNPCF Egress Gateway or forward the User-Agent received from service request. By default it will be set to true as CNPCF always generates its own service requests.