Responses to SDC HTTP calls

6.2 and later Applies to 6.2 and later.

SDC captures the security definitions required by applications during development. You can interact with security definition capture (SDC) through an HTTP REST interface. The response schema and example responses are documented.

For more information about the structure of HTTP responses, see HTTP responses.

Status codes and reason phrases

Responses to the SDC HTTP calls contain the following status codes, by request type.

The following table shows responses of the SDC HTTP calls:
Table 1. Status codes of SDC calls' responses
Status code Reason phrases Applicable request type Description
200 OK GET, DELETE The request completed.
201 CREATED POST SDC started.
202 ACCEPTED DELETE The job to stop SDC and generate required definitions was submitted.
400 BAD REQUEST DELETE The parameters or the syntax in the request were invalid.
401 UNAUTHORIZED DELETE The requester did not have required authority.
404 NOT FOUND GET, DELETE Couldn't stop SDC because the path was wrong or it was already off.
409 CONFLICT POST SDC was already on.
500 INTERNAL SERVER ERROR POST, DELETE An error occurred. Details can be found in the reason message.

Response scheme

In each response, the following parameters are present:
srr_id
Displays the ID generated by SDC. If SDC is not active, null is returned.
message
Displays a reason message that explains the result of the client HTTP request.

Example responses to GET requests

GET requests query the status of SDC.

Table 2. Responses to GET request
Example response Description
HTTP/1.1 404 NOT FOUND 
{
  "srr_id": null,
  "message": "SDC IS NOT SWITCHED ON"
}

SDC is off.

HTTP/1.1 200 OK 
{
  "srr_id": "_1047462",
  "message": "SDC IS ALREADY SWITCHED ON"
}
SDC is on.

Example responses to POST requests

POST requests start SDC.

Table 3. Responses to POST requests
Example response Description
HTTP/1.1 201 Created
{
  "srr_id": "_1053208",
  "message": "SDC HAS BEEN SWITCHED ON"
}
SDC started successfully.
HTTP/1.1 409 Conflict
{
  "srr_id": "_1053208",
  "message": "SDC IS ALREADY SWITCHED ON"
}
SDC was already on.
HTTP/1.1 500 Internal Server Error
{
  "srr_id": "null",
  "message": "(This message can be a number of reasons as to why the request has failed)"
}
An error occurred. Troubleshoot the error as instructed in the message section of the response.

Example responses to DELETE requests

DELETE requests stop SDC.

Table 4. Responses to DELETE requests
Example response Description
HTTP/1.1 202 Accepted
{
  "srr_id": "_1053208",
  "message": "SDC JOB SUBMITTED"
}
SDC was stopped and a job was submitted to output the required security definitions.
HTTP/1.1 200 OK
{
"srr_id": "_1058733",
"message": "SDC TURNED OFF, NO RECORDS CAPTURED"
}
SDC was stopped but no records were captured while SDC was on. Try extending the period when SDC is on.
HTTP/1.1 200 OK
{
  "srr_id": "_1058700",
  "message": "SDC HAS BEEN TURNED OFF"
}
SDC was stopped without submitting a job because "submit": false was specified in the DELETE request. See Capturing security definitions during development using security definition capture.

HTTP/1.1 404 Not Found
{
  "srr_id": null,
  "message": "SDC IS NOT SWITCHED ON"
}
SDC was already off. If you want to capture security definitions, start it before testing. See Capturing security definitions during development using security definition capture.

HTTP/1.1 500 Internal Server Error
{
  "srr_id": "null",
  "message": "(This message can be a number of reasons as to why the request has failed)"
}
An error occurred. Troubleshoot the error as instructed in the message section of the response.