Send Requests

Use the following guidelines when sending requests using the REST API for Oracle Communications Session Delivery Manager

URL Structure

The URL parameters for the REST API for Oracle Communications Session Delivery Manager contains either the server IP address or the DNS name of the server, the port number on which the Oracle Communications Session Delivery Manager is running, and its uniform resource identifier (URI).

Access the Oracle Communications Session Delivery Manager REST resources using the following URL structure:
https://<OCSDM ip-address or <domain>.com>:8443/rest/v1.0/admin/login
Where:
  • <OCSDM ip-address or DNS name>:8443 - Host and its designated port number (8443) that was defined during the installation where the REST API for Oracle Communications Session Delivery Manager is running.

  • /rest/v1.0/admin/login - Relative path that defines the resource, which is the uniform resource identifier (URI) portion of the fixed URL starts with /rest, the major and minor version (/ v1.0) of the API, the API category name (/admin), and the resource (/login).

    Note:

    Minor versions expand the interface and do not change the request and response body format. For example, everything in v1.1 is available in v1.2 and all existing request and response message formats are the same. For a complete list of resources, see <Appendix A, REST API Reference, alphabetically by resource path>.

Supported Methods

You can perform basic CRUD operations (create, read, update, and delete) on the REST API for Oracle? Communications Session Delivery Manager using standard HTTP method requests, as summarized in the following table.

HTTP Method Description
GET The specified read-only operation passes query parameters to the resource and retrieves data from the resource without changing it. Unless otherwise specified, this operation returns the configured state of the resource.
POST Submit data to be processed by the specified resource in the request body, and is also able to create a new resource with the details contained in the JSON or XML request body.
PUT Update the specified resource with new information that replaces or modifies the previous data with the following conditions:
  • This operation cannot be used to create a new resource.
  • The request body must contain the complete representation of mandatory attributes of the resource.
DELETE Delete the a resource. If the resource has already been deleted, a "404 Not Found" response is returned.

Content Media Types

The REST API for Oracle? Communications Session Delivery Manager supports both XML and JSON data formats in the request and response message. Request and response data formats are always same.

A request to the API resource always returns a response code through HTTP/HTTPS. Error response codes typically have two types: 4xx series status codes for client side issues and 5xx series status codes for server side issues. An error response also contains an error body in either XML or JSON format containing the http status code, server error code, error label and error message that are defined by Oracle Communications Application Orchestrator server.

For example, the following server error response (in XML format) shows that the server failed to get alarms:

<errorCode>15034</errorCode> <errorLabel>DBS_QUERY_EXCEPTION</errorLabel> <message>Database query encountered an exception.</message>

The following content media types are supported by the Oracle Communications Session Delivery Manager REST API:

  • application/json

  • application/XML

  • multipart/form-data (for uploading a product plugin file)

Supported Headers

The REST API for Oracle Communications Session Delivery Manager supports the following headers that may be passed in the header section of the HTTP request or response. The following table describes the HTTP request and response headers supported in the REST API.

Header Description Example
Content-Type Media type of the body of the request. Required for POST and PUT requests. Content-Type: application/json or application/xml
Accept Media type of the body of the response. Accept: application/json or application/xml

Request or Response Parameter Object

The REST API for Oracle Communications Session Delivery Manager is supported by various element managers (EMs) to manage a variety of network functions. The REST API uses a parameter object in a request and response to accommodate the differences in the system and facilitate a REST client application.

A parameter object can contain the following attributes:
  • name - The parameter name.
  • valueType - Any of the following supported parameter types:
    • String
    • NumberString
    • BooleanString
    • IPV4String
    • IPV6String
    • MACAddressString
    • SubnetGatewayString
    • SubnetMaskString
    • SingleSelection
    • MultiSelection
  • description - Parameter description.
  • minValue - The minimum allowed value for a NumberString parameter type.
  • maxValue - The maximum allowed value for a NumberString parameter type.
  • Value - The current parameter value.
  • ValueList - The current parameter value list if the parameter is multiSelectionList.
  • validValues - The valid value options for the selection type parameter.
  • readOnly - This parameter informs users whether a parameter accepts user input.

The following figure shows a request or response parameter schema example:

Pagination Parameters

The following pagination parameters can be found in the REST API for Oracle Communications Session Delivery Manager resources:
  • limitation - Total number of objects allowed. The default is 50.
  • numberOfElements - Number of elements per page allowed.
  • offset - The page offset within a data structure object that is a number indicating the distance (displacement) from the beginning of the object up until a given element within the same object. The default page offset is one.