Test New Application Connection
/applications/{applicationName}/connections/actions/test
Tests a new or updated application connection, using specified inputs, without saving it.
Request
-
applicationName(required):
Application name.
-
validateName:
Validate if connection name already exists.
Response
200 Response
OK
The connection tested successfully.
400 Response
Bad Request
Error occurred while testing connection.
Examples
The following example shows how to test a new application connection before creating it.
This example uses cURL to access the REST API from a Windows shell script. The calling user's ID and password are variables whose values are set in properties.bat.
Script with cURL Command
call properties.bat
curl -X POST -i "https://myserver.example.com:9001/essbase/rest/v1/applications/Sample/connections/actions/test" -H Accept:application/json -H Content-Type:application/json --data "@./app_conn_details.json" -u %User%:%Password%The cURL example above delivers a JSON payload in app_conn_details.json. The details you include in the payload determine what kind of connection would be created. The example below is for testing a DB2 connection.
Sample JSON Payload - IBM DB2
The following sample JSON payload, passed to REST API in app_conn_details.json, is an example for testing a connection to DB2. The required parameters are name, type, subtype, dbDriver, host + port+ service (OR dbURL), user, and password.
{
"name" : "DB2Conn",
"type" : "DB",
"subtype" : "DB2",
"dbDriver" : "com.oracle.bi.jdbc.db2.DB2Driver",
"host" : db2host.example.com",
"port" : 50000,
"user" : "user1",
"password" : "cGE1NXdvcmQx",
"service" : "dbname"
}
For more examples of JSON payloads you can use to test, update, and create connections to sources supported by Essbase, see the Create Connection endpoint.
Example of Response Body
Returns header information (if -i was used), beginning with the status code 200 (if the test was successful). The header information is truncated to show only the status code.
HTTP/1.1 200 OK