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

Docebo REST connection: Import entitlements with their hierarchical structure

Lukas1
New Contributor
New Contributor

Hello,

We are able to import all the branches from our Docebo endpoint, however we are not getting their hierarchical structure, all the entitlements are coming in as independant objects.

This is our ImportAccountEntJson config:

 

{
    "accountParams": {
        "connection": "acctAuth",
        "processingType": "SequentialAndIterative",
        "call": {
            "call1": {
                "callOrder": 0,
                "stageNumber": 0,
                "http": {
                    "url": "https://xxxxxxxxx.docebosaas.com/manage/v1/user?page=1&page_size=100",
                    "httpHeaders": {
                        "Authorization": "${access_token}",
                        "Accept": "application/json"
                    },
                    "httpContentType": "application/json",
                    "httpMethod": "GET"
                },
                "listField": "data.items",
                "keyField": "accountID",
                "colsToPropsMap": {
                    "accountID": "user_id~#~char",
                    "name": "email~#~char",
                    "displayName": "fullname~#~char",
                    "customproperty2": "first_name~#~char",
                    "customproperty3": "last_name~#~char",
                    "customproperty4": "uuid~#~char",
                    "customproperty5": "is_manager~#~char",
                    "customproperty6": "username~#~char",
                    "customproperty7": "last_access_date~#~char",
                    "customproperty8": "last_update~#~char",
                    "customproperty9": "creation_date~#~char",
                    "customproperty10": "language~#~char",
                    "customproperty11": "lang_code~#~char",
                    "customproperty12": "expiration_date~#~char",
                    "customproperty13": "level~#~char",
                    "customproperty14": "email_validation_status~#~char",
                    "customproperty15": "send_notification~#~char",
                    "customproperty16": "encoded_username~#~char",
                    "customproperty17": "timezone~#~char",
                    "customproperty18": "date_format~#~char",
                    "customproperty19": "multidomains~#~char",
                    "customproperty20": "status~#~bool",
                    "customproperty21": "actions~#~char",
                    "customproperty22": "expired~#~char",
                    "customproperty31": "STORE#ACC#ENT#MAPPINGINFO~#~char"
                },
                "pagination": {
                    "page": {
                        "pageSizeParam": "page_size",
                        "pageSize": 100,
                        "pageRecordCount": "completeResponseMap.data.current_page_size",
                        "pageNumberParam": "page",
                        "totalCountPath": "completeResponseMap.data.total_count",
                        "FirstPageNumber": 1
                    }
                }
            }
        }
    },
    "entitlementParams": {
        "connection": "acctAuth",
        "processingType": "SequentialAndIterative",
        "entTypes": {
            "Group": {
                "entTypeOrder": 1,
                "entTypeLabels": {
                },
                "call": {
                    "call1": {
                        "connection": "acctAuth",
                        "callOrder": 0,
                        "stageNumber": 0,
                        "http": {
                            "url": "https://xxxxxxxxxxxx.docebosaas.com/manage/v1/group?page=1&page_size=100",
                            "httpHeaders": {
                                "Authorization": "${access_token}",
                                "Accept": "application/json"
                            },
                            "httpContentType": "application/json",
                            "httpMethod": "GET"
                        },
                        "listField": "data.items",
                        "keyField": "entitlementID",
                        "colsToPropsMap": {
                            "entitlementID": "id~#~char",
                            "entitlement_value": "name~#~char",
                            "description": "description~#~char",
                            "customproperty1": "members_count~#~char",
                            "acctEntMappingInfoColumnFromEnt": "STORE#ACC#ENT#MAPPINGINFO~#~char"
                        },
                        "pagination": {
                            "page": {
                                "pageSizeParam": "page_size",
                                "pageSize": 100,
                                "pageRecordCount": "completeResponseMap.data.current_page_size",
                                "pageNumberParam": "page",
                                "totalCountPath": "completeResponseMap.data.total_count",
                                "FirstPageNumber": 1
                            }
                        },
                        "disableDeletedEntitlements": true
                    }
                }
            },
            "Branch": {
                "entTypeOrder": 2,
                "entTypeLabels": {
                },
                "call": {
                    "call1": {
                        "connection": "acctAuth",
                        "callOrder": 0,
                        "stageNumber": 0,
                        "http": {
                            "url": "https://xxxxxxxxxx.docebosaas.com/manage/v1/orgchart?flattened=true&search_type=2&page=1&page_size=5",
                            "httpHeaders": {
                                "Authorization": "${access_token}",
                                "Accept": "application/json"
                            },
                            "httpContentType": "application/json",
                            "httpMethod": "GET"
                        },
                        "listField": "data.items",
                        "keyField": "entitlementID",
                        "colsToPropsMap": {
                            "entitlementID": "id~#~char",
                            "entitlement_value": "code~#~char",
                            "description": "title~#~char",
                            "customproperty1": "parent_code~#~char",
"customproperty2": "id~#~char",
                            "acctEntMappingInfoColumnFromEnt": "STORE#ACC#ENT#MAPPINGINFO~#~char"
                        },
                        "pagination": {
                            "page": {
                                "pageSizeParam": "page_size",
                                "pageSize": 100,
                                "pageRecordCount": "completeResponseMap.data.current_page_size",
                                "pageNumberParam": "page",
                                "totalCountPath": "completeResponseMap.data.total_count",
                                "FirstPageNumber": 1
                            }
                        },
                        "disableDeletedEntitlements": true
                    }
                }
            }
        }
    },
    "acctEntParams": {
        "connection": "acctAuth",
        "entTypes": {
            "Group": {
                "call": {
                    "call1": {
                        "callOrder": 0,
                        "stageNumber": 0,
                        "processingType": "httpEntToAcct",
                        "http": {
                            "httpHeaders": {
                                "Authorization": "${access_token}"
                            },
                            "url": "https://xxxxxxxxxxxx.docebosaas.com/manage/v1/group/${id}/members?page=1&page_size=5",
                            "httpContentType": "application/json",
                            "httpMethod": "GET"
                        },
                        "listField": "data.items",
                        "entKeyField": "entitlementID",
                        "acctIdPath": "id",
                        "acctKeyField": "accountID",
                        "pagination": {
                            "page": {
                                "pageSizeParam": "page_size",
                                "pageSize": 100,
                                "pageRecordCount": "completeResponseMap.data.current_page_size",
                                "pageNumberParam": "page",
                                "totalCountPath": "completeResponseMap.data.total_count",
                                "FirstPageNumber": 1
                            }
                        }
                    }
                }
            },
            "Branch": {
                "call": {
                    "call1": {
                        "callOrder": 0,
                        "stageNumber": 0,
                        "processingType": "httpEntToAcct",
                        "http": {
                            "httpHeaders": {
                                "Authorization": "${access_token}"
                            },
                            "url": "https://xxxxxxxxxxxxxxxx.docebosaas.com/manage/v1/orgchart/${id}/users?page=1&page_size=5",
                            "httpContentType": "application/json",
                            "httpMethod": "GET"
                        },
                        "listField": "data.items",
                        "entKeyField": "entitlementID",
                        "acctIdPath": "user_id",
                        "acctKeyField": "accountID",
                        "pagination": {
                            "page": {
                                "pageSizeParam": "page_size",
                                "pageSize": 100,
                                "pageRecordCount": "completeResponseMap.data.current_page_size",
                                "pageNumberParam": "page",
                                "totalCountPath": "completeResponseMap.data.total_count",
                                "FirstPageNumber": 1
                            }
                        }
                    }
                }
            }
        }
    }
}

 

The branch call in entitlementParams returns the complete list of all enititlements thanks the addition of  the query params flattened=true&search_type=2, otherwise we only got the root elements. 
This is a postman sample response of the call:

 

 

{
    "data": {
        "items": [
            {
                "id": "<id_num>",
                "code": "<string_code>",
                "title": "xxxxxxx",
                "lev": "4",
                "iLeft": "<left_id>",
                "iRight": "<right_id>",
                "parent_code": "<sparent_tring_code>",
                "parent_id": "<parent_id_num>",
                "selection_status": 0,
                "actions": [],
                "has_children": false,
                "selectable": 1,
                "can_manage": <bool>,
                "icon": "folder-outline",
                "color": "",
                "tooltip": ""
            },
            { <other json elements of the response....>

 

The entitlements return both the code and the id of their parent entitlement, we just need a way to make Saviynt apply that to the hierarchy. Note that a root node will have parent_code "root" and parent_id 0

Thank you,

Lukas

1 REPLY 1

rushikeshvartak
All-Star
All-Star

Refer https://forums.saviynt.com/t5/saviynt-knowledge-base/how-to-import-hierarchical-entitlement-using-re...


Regards,
Rushikesh Vartak
If this helped you move forward, click 'Kudos'. If it solved your query, select 'Accept As Solution'.