Saviynt unveils its cutting-edge Intelligence Suite products to revolutionize Identity Security!
Click HERE to see how Saviynt Intelligence is transforming the industry.
Saviynt Copilot Icon

Azure Active Directory REST ImportAccountEntitlement JSON with SignInActivity

SJ_544
New Contributor III
New Contributor III

Hi Team,

Can anyone share the ImportAccountEntitlement (Account, Entitlement and AcctEntitlement Params) JSON for Azure AD Rest connector. We are looking to include the SignInActivity information. As OOTB Azure connector Is not supporting this attribute today.

Regards,

SJ_544

1 REPLY 1

sudeshjaiswal
Saviynt Employee
Saviynt Employee

Hello @SJ_544,

You may refer the below two sample,
Please make sure before useing any API, try to test in POSTMAN, before using the below sample.

Sample 1

 

{
	"accountParams": {
		"connection": "userAuth",
		"processingType": "SequentialAndIterative",
		"statusAndThresholdConfig": {
			"statusColumn": "customproperty10",
			"activeStatus": [
				"true"
			],
			"deleteLinks": true,
			"accountThresholdValue": 50,
			"correlateInactiveAccounts": true,
			"deleteAccEntForActiveAccounts": true
		},
		"call": {
			"call1": {
				"http": {
					"url": "https://graph.microsoft.com/beta/users?$filter=userType%20eq%20'Guest'&$select=givenName,surname,displayName,mail,userType,userPrincipalName,Id,accountEnabled,createdDateTime,jobTitle,companyname,signInActivity,department",
					"httpHeaders": {
						"Authorization": "${access_token}",
						"Accept": "application/json"
					},
					"httpContentType": "application/json",
					"httpMethod": "GET"
				},
				"listField": "value",
				"keyField": "accountID",
				"statusConfig": {
					"active": "true",
					"inactive": "false"
				},
				"colsToPropsMap": {
					"CUSTOMPROPERTY1": "givenName~#~char",
					"CUSTOMPROPERTY2": "surname~#~char",
					"DISPLAYNAME": "displayName~#~char",
					"Name": "mail~#~char",
					"CUSTOMPROPERTY3": "mail~#~char",
					"CUSTOMPROPERTY5": "userType~#~char",
					"customproperty6": "userPrincipalName~#~char",
					"accountID": "id~#~char",
					"status": "accountEnabled~#~char",
					"customproperty10": "accountEnabled~#~char",
					"customproperty9": "createdDateTime~#~char",
					"customproperty7": "signInActivity.lastSignInDateTime~#~char",
					"customproperty8": "jobTitle~#~char",
					"CUSTOMPROPERTY4": "companyName~#~char",
					"ACCOUNTTYPE": "userType~#~char",
					"customproperty11": "department~#~char"
				},
				"pagination": {
					"nextUrl": {
						"nextUrlPath": "${(response?.completeResponseMap?.get('@odata.nextLink')==null)? null : response?.completeResponseMap?.get('@odata.nextLink')}"
					}
				}
			}
		}
	},
	"entitlementParams": {
		"connection": "userAuth",
		"processingType": "SequentialAndIterative",
		"entTypes": {
			"Enterprise Apps": {
				"entTypeOrder": 0,
				"call": {
					"call101": {
						"callOrder": 0,
						"stageNumber": 0,
						"http": {
							"url": "https://graph.microsoft.com/beta/groups?$count=true&$filter=onPremisesSyncEnabled%20ne%20true%20and%20startswith(displayName,'B2B')&$select=displayName,id,description,createdDateTime,securityEnabled",
							"httpHeaders": {
								"Authorization": "${access_token}",
								"Accept": "application/json",
								"ConsistencyLevel": "eventual"
							},
							"httpContentType": "application/json",
							"httpMethod": "GET"
						},
						"listField": "value",
						"keyField": "entitlementID",
						"colsToPropsMap": {
							"entitlementID": "id~#~char",
							"entitlement_value": "displayName~#~char",
							"DISPLAYNAME": "displayName~#~char",
							"DESCRIPTION": "description~#~char",
							"customproperty10": "securityEnabled~#~char",
							"customproperty2": "createdDateTime~#~char"
						},
						"pagination": {
							"nextUrl": {
								"nextUrlPath": "${(response?.completeResponseMap?.get('@odata.nextLink')==null)? null : response?.completeResponseMap?.get('@odata.nextLink')}"
							}
						},
						"disableDeletedEntitlements": true
					}
				}
			}
		}
	},
	"acctEntParams": {
		"connection": "userAuth",
		"entTypes": {
			"Enterprise Apps": {
				"call": {
					"call201": {
						"callOrder": 0,
						"stageNumber": 0,
						"processingType": "httpEntToAcct",
						"http": {
							"url": "https://graph.microsoft.com/beta/groups/${id}/members",
							"httpHeaders": {
								"Authorization": "${access_token}",
								"Accept": "application/json",
								"ConsistencyLevel": "eventual"
							},
							"httpContentType": "application/json",
							"httpMethod": "GET"
						},
						"listField": "value",
						"entKeyField": "entitlementID",
						"acctIdPath": "id",
						"acctKeyField": "accountID",
						"pagination": {
							"nextUrl": {
								"nextUrlPath": "${(response?.completeResponseMap?.get('@odata.nextLink')==null)? null : response?.completeResponseMap?.get('@odata.nextLink')}"
							}
						}
					}
				}
			}
		}
	}
}

 

Sample 2

 

{
    "accountParams": {
        "connection": "userAuth",
        "createUsers": true,
        "adminName": "admin",
        "processingType": "SequentialAndIterative",
        "statusAndThresholdConfig": {
            "deleteLinks": false,
            "accountThresholdValue": 30,
            "correlateInactiveAccounts": false,
            "inactivateAccountsNotInFile": true,
            "statusColumn": "customproperty42"
        },
        "call": {
            "call1": {
                "callOrder": 0,
                "stageNumber": 0,
                "http": {
                    "url": "https://graph.microsoft.com/v1.0/users/8cd741eb-6319-49bd-9848-cc82b9c35eb8/?$select=id,userPrincipalName,signInActivity,lastSignInDateTime",
                    "httpHeaders": {
                        "Authorization": "${access_token}"
                    },
                    "httpContentType": "application/x-www-form-urlencoded",
                    "httpMethod": "GET"
                },
                "listField": "",
                "keyField": "accountID",
                "colsToPropsMap": {
                    "accountID": "id~#~char",
                    "name": "userPrincipalName~#~char",
                    "customproperty4": "signInActivity.lastSignInDateTime~#~char"
                },
                "disableDeletedAccounts": true
            }
        }
    },
    "entitlementParams": {},
    "acctEntParams": {}
}

 

Thanks.

 

If you find the above response useful, Kindly Mark it as "Accept As Solution".