RapidIdentity Product Guides - 2019 Rolling Release

Network Actions

createRESTPointResponse

Create a new RESTPoint Response.

Property

Value

Description

statusCode

text, expression, variable

the HTTP status code (default: OK)

data

text, expression, variable

the content data of the HTTP response (default: empty content)

contentType

choice (application/json, application/xml, text/xml, text/plain, application/octet-stream), text, expression, variable

the MIME type of the data (default: whatever is defined by the RESTPoint)

headers

expression, variable

Record or Object containing HTTP header fields

cookies

expression, variable

Record or Object containing HTTP cookies

returnVariable

expression, variable

name of the variable to be assigned to the return value

Example

if(record == null) {
    recordJSON = toJSON(recordJSON)
    response = createRESTPointResponse(200, recordJSON, 
        "application/json")
} else {
    response = createRESTPointResponse(404, '{"status": 
        "Not Found"}', "application/json")
}
return(response)
getHostName

Gets the hostname of the server hosting the current process.

Property

Value

Description

returnVariable

expression, variable

name of the variable to be assigned to the return value

Example

hostname = getHostName() 
getIPAddress

Gets the IP address of the server hosting the current process.

Property

Value

Description

returnVariable

expression, variable

name of the variable to be assigned to the return value

Example

ipAddress = getIPAddress()
readURL

Read the contents of a URL.

Property

Value

Description

url*

text, expression, variable

the URL

returnVariable

expression, variable

name of the variable to be assigned to the return value

Example

dssWADL = readURL("http://127.0.0.1:8080/dss/ws/dss?_wadl");