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

How to access nested data from JSON response

IAM-Vaibhav
New Contributor III
New Contributor III

Hi Team , We are integating one REST base application , Its get all users , Roles and Groups api returns response in following format , Is it possible to import accounts and other supporting data with below response and could you help me JSON snippet with the syntax to access Role Name , Role Description, ROle ID. { "pageNumber": 1, "pageSize": 22, "totalPages": 1, "totalRecords": 22, "items": [ { "appId": 1, "recordId": 1, "fieldData": [ { "type": "String", "fieldId": 27, "value": "Role Name" }, { "type": "String", "fieldId": 28, "value": "Role Description" }, { "type": "Guid", "fieldId": 29, "value": "Role ID" }, ] }, { "appId": 1, "recordId": 2, "fieldData": [ { "type": "String", "fieldId": 27, "value": "Role Name" }, { "type": "String", "fieldId": 28, "value": "Role Description" }, { "type": "Guid", "fieldId": 29, "value": "4dc60eed-f6d8-4050-acd8-c0b156a800e9" }, ] } }.

I have gone through the Saviynt developer handbook, but didn't find any similar example.

 

 

Regards,
Vaibhav Patil
If this helps you, click 'Kudos'. If it solved your query, select 'Accept As Solution'.
3 REPLIES 3

nimitdave
Saviynt Employee
Saviynt Employee

@IAM-Vaibhav , pls check the json response shared as its not valid. Share the valid response. You can use https://jsonlint.com/ to validate a json.

IAM-Vaibhav
New Contributor III
New Contributor III

@nimitdave 

 

this is the valid json :

{
"pageNumber": 1,
"pageSize": 22,
"totalPages": 1,
"totalRecords": 22,
"items": [{
"appId": 1,
"recordId": 1,
"fieldData": [{
"type": "String",
"fieldId": 27,
"value": "Role Name"
}, {
"type": "String",
"fieldId": 28,
"value": "Role Description"
}, {
"type": "Guid",
"fieldId": 29,
"value": "Role ID"
}]
}, {
"appId": 1,
"recordId": 2,
"fieldData": [{
"type": "String",
"fieldId": 27,
"value": "Role Name"
}, {
"type": "String",
"fieldId": 28,
"value": "Role Description"
}, {
"type": "Guid",
"fieldId": 29,
"value": "4dc60eed-f6d8-4050-acd8-c0b156a800e9"
}]
}]
}

Regards,
Vaibhav Patil
If this helps you, click 'Kudos'. If it solved your query, select 'Accept As Solution'.

IAM-Vaibhav
New Contributor III
New Contributor III

@nimitdave , @Saviynt Team,

Any update on this, application team is following with us continuously due urgent requirement of onboarding.

Regards,
Vaibhav Patil
If this helps you, click 'Kudos'. If it solved your query, select 'Accept As Solution'.