Quick Start

The REST API for Oracle? Communications Session Delivery Manager allows a northbound client application, such as a network service orchestrator (NSO), to interact with Oracle? Communications Session Delivery Manager. The following prerequisites, sample client code, and tasks are used to help you prepare and set up your environment for the REST API.

REST Client Prerequisites

Any application that needs to interact with REST API needs to send HTTP/HTTPS requests and receive HTTP/HTTPS responses. The application must have a software development toolkit that can generate the HTTP requests and receive HTTP responses. The request and response body are available in either XML or JSON formats. A XML and JSON parser toolkit is needed in the application to be able to parse the XML or JSON data.

Note:

The REST API resource examples provided in this guide are represented in XML format only.

Note:

If you are using JSON for your REST implementation, the root element should be excluded in the request payload. The JSON response example below contains the root element, which is highlighted in bold.
{ "session": {
"userName": "admin",
"password": "NextGen"
} } 

The JSON response example below has the root element removed:

{
"userName": "admin",
"password": "NextGen"
}

Using Jersey or Java JDK Net Clients with the REST API

You can use the REST API with various client-side libraries and cURL to utilize different programming languages. Your development environment determines how you access the REST API.

If you want to use a Jersey client, you must download a Jersey release package a Jersey release and put the JARs in your class path to use the Jersey package. If using the JSON message format, you must also retrieve any additional JARs described in the Jersey User Guide. The following JARs are required to support MOXy as your JSON provider:

jersey-entity-filtering-2.9.jar
jersey-media-moxy-2.9.jar
org.eclipse.persistence.moxy-2.5.0.jar
org.eclipse.persistence.core-2.5.0.jar
org.eclipse.persistence.antlr-2.5.0.jar
org.eclipse.persistence.asm-2.5.0.jar

For the Java JDK Net Package, no additional 3rd party JARs are required to make REST API calls using the JDK net package.

Step 1: Obtain NNC User Information

Obtain the user name and password credentials from your account administrator to enable you to initiate a client/server session with the REST API through the login URI.

Step 2: Install and Configure the REST Sample Client

The following task shows how to install and configure the REST sample client on which you can view the structure and composition of the REST API in order to help you construct your own REST client.

The following procedure demonstrates how to install cURL on a Windows 64?bit system.
  1. Download the NNC<Version>RESTClient.zip file from the Oracle Delivery Software Cloud to your server by doing the following:

    • Type Oracle Communications Session Delivery Manager in the Product drop-down list.
    • Click the Select Platform drop-down list.
    • In the Select Platform drop-down dialog box, select Acme Packet OS.
    • Continue through the next screens and accept the Oracle license agreements and download the product installation zip file.
  2. Within the product installation zip file, unzip <NNC_VERSION>RESTClient.zip file and open the README.txt file.

  3. Download the Jersey client software to the /lib directory, and unzip the file. Use the README.txt file to verify the Jersey client directory structure on the server.

  4. Run chmod +x * within the bin folder to make bash scripts executable.

  5. Run the ./build.sh to compile source code.
  6. Open and modify the <rest-client> class file to configure REST API calls under the src folder by editing the RESTClientExample, which is a container of all calls to the Oracle Communications Application Orchestrator REST API and uncomment parameters in the main () method to execute different call flows.
  7. Modify XML files in the xml folder.
  8. Configure the individual REST API methods, which are called from the main method.
  9. Run the ./run.sh <rest-client> <server-name>:<port> script to execute the desired REST client within the src folder.