Skip to main content

getSecurityRealm

A Graze API GET request that returns a JSON object containing the names and configuration details of active SAML security realms.

Back to Graze API EndPoint Reference.

Request arguments

Endpoint getSecurityRealm takes the following request argument:

Endpoint getSecurityRealm takes no other arguments because this endpoint returns data on all active security realms.

Response

Endpoint getSecurityRealm returns the following response:

Successful requests return a JSON object containing the following:

Name

Type

Description

JSON Object

JSON

The name of the created Security Realms followed by its configured variables.

Examples

The following examples demonstrate typical use of endpoint getSecurityRealm:

Request example

Example cURL request to return the configuration of any active security realm in Moogsoft Enterprise:

curl -G -u graze:graze -k -v "https://localhost/graze/v1/getSecurityRealms"

Response example

Successful requests return a JSON object representing the active realms. The following example shows a test SAML realm:

{
    "Test Saml Realm":
    {
        "configuration":
        {
            "defaultGroup":"EndUser",
            "realmType":"SAML2",
            "existingUserMappingField":"username",
            "spMetadataFile":"/usr/share/moogsoft/config/keycloak.my_sp_metadata.xml",
            "defaultRoles":["Operator"],
            "defaultTeams":["Cloud DevOps"],
            "fullname":"$FirstName $LastName",
            "email":"$Email",
            "idpMetadataFile":"/usr/share/moogsoft/config/keycloak.my_idp_metadata.xml",
            "username":"$Email",
            "maximumAuthenticationLifetime":60
        },
        "name":"Test Saml Realm",
        "active":true,
        "type":"SAML2"
    }
}