View a Login Policy

Endpoint URL: {identityDomain}/{customerId}/config/loginPolicies/{loginPolicyId}


Returns information about the specified login policy. All OpenID Connect clients used for logins and registrations must be associated with a login policy.

Login policies help manage the user login experience by doing such things as: specifying the exact path to the Capture domain and the user profile entity type, and defining the login URL for the associated directory. All OpenID Connect clients (public and confidential) must be associated with one (but only one) login policy.

Login policies can also be used to specify custom claims: custom claims provide a way to return user profile attributes that are not returned by any of your predefined scopes. For example, suppose you have a custom attribute – newsletterSubscriber– that is not returned by any of your Hosted Login scopes. You cannot add this attribute to any of your existing scopes, nor can you create a new scope. However, in your login policy you can define a custom claim that will return the newsletterSubscriber attribute:

"customClaims": {
           {"subscriber": "newsletterSubscriber"}

In the preceding example, a unique claim name (subscriber) is mapped to the newsletterSubscriber attribute. In addition, the value id_token indicates that the custom claim should be returned as part of the identity token. For example:

  "iss": "",
  "sub": "8855454e-8146-11e8-adc0-fa7ae01bbebc",
  "aud": "c2a5b7bc-e329-b4e4-dd6b-eb1ae01c22aa",
  "iat": 1530897246,
  "exp": 1530900246,
  "jti": "ID.rWH0iZkhFNxAoDxR5LhLAOqNj2bQvmMaeQiqhH5BcAU",
  "subscriber": true

Alternatively, you can replace id_token with userinfo. When you do that, the custom claim is not returned as part of the identity token; instead, it’s returned when you make a call to the userinfo endpoint.

For more information, see the article OpenID Connect Scopes and Claims.

Respects the API Client Allow List: No


This endpoint requires token-based authentication. To obtain an access token, you must use a configuration client (using the client ID as the username and the client secret as the password) to access the /{customerId}}/login/token endpoint. The access token returned from the token endpoint is then used in the Authorization header of your API call. For example, if you get back the access token Ki712dpGq5GPQcsxMHY6ShHY7wU_iTs0o9dPx4TEzf5yLIvddjnDVBJxjPDucf5YVB then your Authorization header would look like this when using Curl:

-H 'Authorization: Bearer Ki712dpGq5GPQcsxMHY6ShHY7wU_iTs0o9dPx4TEzf5yLIvddjnDVBJxjPDucf5YVB'

In Postman, set the Authorization Type to Bearer and use the access token as the value of the Token field.

Path Parameters

The path parameters that must be included in the request are listed in the following table:





Unique identifier of the customer associated with the login policy.




Unique identifier of the login policy to be returned.

Sample Request (Curl)

The following command returns information about the login policy with the policy ID d4308c4d-f5d5-403f-bbb4-403dbdb3efe6:

curl -X GET \ \ 
-H 'Authorization: Bearer Ki712dpGq5GPQcsxMHY6ShHY7wU_iTs0o9dPx4TEzf5yLIvddjnDVBJxjPDucf5YVB'


200 OK

If your call to this endpoint succeeds, you'll get back information about the specified login policy:

    "id": "d4308c4d-f5d5-403f-bbb4-403dbdb3efe6",
    "identityStoreDetails": {
        "type": "janrainCapture",
        "connectionDetails": {
            "domain": "",
            "applicationId": "kfcmdfudasmx9wkay7463vpdsy",
            "entityType": "user",
            "clientId": "96by2t9dav337mvzbybqdfcjmrsd7bn4",
            "clientSecret": "jiu62gun9wkkmi7fgnqx4ppe1476amh99"
    "loginURL": "http://localhost/login",
    "title": "Documentation Login Policy",
    "_links": {
        "self": {
            "href": "/01000000-0000-3000-9000-000000000000/config/loginPolicies/d4308c4d-f5d5-403f-bbb4-403dbdb3efe6"