Add an NF

post

/rest/{versionId}/inventory/nfMgmt/nfs

Use this (POST) method to add a Network Function (NF) with devices to a group that you created. Once the NF is added successfully, the Oracle Communications Session Element Manager plug-in is able to communicate with the devices in the NF.

Request

Supported Media Types
Path Parameters
Body ()
Root Schema : nfConfig
Type: object
Show Source
Nested Schema : nfCategory
Type: object
Show Source
Nested Schema : nfcConfig
Type: array
Show Source
Nested Schema : nfType
Type: object
Show Source
Nested Schema : parameter
Type: array
Show Source
Nested Schema : nfType
Type: array
Show Source
Nested Schema : nfcConfig
Type: object
Show Source
Nested Schema : deviceConfig
Type: array
Show Source
Nested Schema : parameter
Type: array
Show Source
Nested Schema : deviceConfig
Type: object
Show Source
Nested Schema : parameter
Type: array
Show Source
Nested Schema : parameter
Type: object
Show Source
Nested Schema : validValue
Type: array
Show Source
Nested Schema : validLists
Type: array
Show Source
Back to Top

Response

Supported Media Types

200 Response

successful operation
Body ()
Root Schema : nf
Type: object
Show Source
Nested Schema : group
Type: array
Show Source
Nested Schema : nfCategory
Type: object
Show Source
Nested Schema : nfType
Type: object
Show Source
Nested Schema : nfType
Type: array
Show Source

400 Response

The user input is invalid.

401 Response

The session ID is invalid.

404 Response

The object (resource URI, device, and so on) of your input request cannot be found.
Back to Top

Examples

The following example shows how to add an NF by submitting a POST request on the REST resource using cURL. For more information about cURL, see Use cURL

Example of cURL Data

The following shows an example of cURL data sent with the request.

curl -v -b sessionid.txt -X POST -d@nf/addDevice79_78.xml -H"Content-Type: application/xml" -H"Accept: application/xml" http://localhost:8080/rest/v1.1/inventory/nfMgmt/nfs

Example of Request Body

The following shows an example of the user request body input in XML format.

<?xml version="1.0" encoding="UTF-8"?>
<nfConfig>
    <name>NF2</name>
    <parentGroupFullName>HG1</parentGroupFullName>
    <nfCategory>
        <name>SD</name>
        <product>Session Delivery</product>
        <vendor>Oracle</vendor>
    </nfCategory>
    <nfType>
        <name>Device</name>
    </nfType>
    <parameters>
        <parameter>
            <name>primary.ip</name>
            <value>10.196.120.79</value>
        </parameter>
	<parameter>
            <name>secondary.ip</name>
            <value>10.196.120.78</value>
        </parameter>
        <parameter>
            <name>snmp.community.name</name>
            <value>public</value>
        </parameter>
        <parameter>
            <name>snmp.port</name>
            <value>161</value>
        </parameter>
        <parameter>
            <name>username</name>
            <value>admin</value>
        </parameter>
        <parameter>
            <name>password</name>
            <value>packet</value>
        </parameter>
    </parameters>
</nfConfig>

Example of Response Header

The following shows an example of the response header.

HTTP/1.1 200 OK
Date: Wed, 06 Sep 2017 19:21:13 GMT
Server: Apache
X-Frame-Options: SAMEORIGIN
Content-Length: 717
Vary: Accept-Encoding
Content-Type: application/xml

Example of Response Body

The following example shows the contents of the response body in XML format.

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<nf>
  <groups>
    <group>
      <id>ID5</id>
      <ipAddress>10.196.120.79</ipAddress>
      <name>sd79</name>
      <parentGroupFullName>HG1/NF2</parentGroupFullName>
      <parentGroupId>ID16</parentGroupId>
    </group>
    <group>
      <id>ID6</id>
      <ipAddress>10.196.120.78</ipAddress>
      <name>sd78</name>
      <parentGroupFullName>HG1/NF2</parentGroupFullName>
      <parentGroupId>ID16</parentGroupId>
    </group>
  </groups>
  <groupType>DEVICE</groupType>
  <hidden>false</hidden>
  <id>ID16</id>
  <name>NF2</name>
  <nfCategory>
    <id>ID2</id>
    <name>SD</name>
    <product>Session Delivery</product>
    <vendor>Oracle</vendor>
  </nfCategory>
  <nfType>
    <name>Device</name>
  </nfType>
  <parentGroupFullName>HG1</parentGroupFullName>
  <parentGroupId>ID3</parentGroupId>
</nf>
Back to Top