--- title: "Get Assignment Role For Folder By Name Or Id" slug: "get-assignment-role-for-folder-by-name-or-id" tags: ["Assignment Roles", "Folder", "name"] updated: 2025-07-07T16:38:21Z published: 2025-07-07T16:38:21Z canonical: "documentation.decisions.com/get-assignment-role-for-folder-by-name-or-id" --- > ## Documentation Index > Fetch the complete documentation index at: https://documentation.decisions.com/llms.txt > Use this file to discover all available pages before exploring further. # Get Assignment Role For Folder By Name Or Id | ## Step Details | | --- | | **Introduced in Version** | 4.0.0 | | **Last Modified in Version** | 5.12.0 | | **Location** | System > Assignment | The Get Assignment Role For Folder By Name Or Id step returns the Assignment Role data for the specified Folder. --- ## Properties #### Inputs | Property | Description | Data Type | | --- | --- | --- | | Folder Id | The Id of the desired Folder | String | | Role Name Or Id | Allows the user to specify the Assignment Role name or Id of the Assignment Role to retrieve Assignment Data for | String | #### Outputs | Property | Description | Data Type | | --- | --- | --- | | Output | List of the specified Assignment Role data | AssignmentRole | --- ## Example Inputs and Outputs | Folder Id | Role Name Or Id | Output | | --- | --- | --- | | 08da6f2e-eafc-755c-1f24-2223a4075e8 | Executive | List of Assignment Role data | | 08da6f2e-eafc-755c-1f24-2223a4075e8 | Null | EXCEPTION MESSAGE | | Null | Executive | EXCEPTION MESSAGE | #### ![](https://cdn.document360.io/6ef8bcc1-6489-4486-9ad1-83acff7e5df0/Images/Documentation/image-1673885165170.png) --- ## Common Errors ### Object reference not set to an instance of an object If the Role Name is empty or null, the step will throw an error. To correct this, ensure that the Role Name is entered correctly. #### Exception Message: ```csharp Exception Stack Trace: DecisionsFramework.Design.Flow.ErrorRunningFlowStep: Error running step Get Assignment Role For Folder By Name Or Id 1[GetAssignmentRoleForFolderByNameOrId] in flow [Flow 1]: Exception invoking method GetAssignmentRoleForFolderByNameOrId on class AssignmentRoleSteps ---> DecisionsFramework.LoggedException: Exception invoking method GetAssignmentRoleForFolderByNameOrId on class AssignmentRoleSteps ---> System.NullReferenceException: Object reference not set to an instance of an object. at DecisionsFramework.Design.Flow.CoreSteps.AssignmentRoleSteps.GetRoleByNameOrIdAndFolderId(String folderId, String roleNameOrId at DecisionsFramework.Design.Flow.CoreSteps.AssignmentRoleSteps.GetAssignmentRoleForFolderByNameOrId(String folderId, String roleNameOrId) --- End of inner exception stack trace --- at DecisionsFramework.Design.Flow.StepImplementations.InvokeMethodStep.Run(StepStartData data at DecisionsFramework.Design.Flow.FlowStep.RunStepInternal(String flowTrackingID, String stepTrackingID, KeyValuePairDataStructure[] stepRunDataValues, AbstractFlowTrackingData trackingData at DecisionsFramework.Design.Flow.FlowStep.Start(String flowTrackingID, String stepTrackingID, FlowStateData data, AbstractFlowTrackingData trackingData, RunningStepData currentStepData) --- End of inner exception stack trace --- ``` --- ### Value cannot be null If the Folder Id value is null or empty, an error will occur. To correct this, ensure that the value is mapped or entered correctly. #### Exception Message: ```csharp Exception Stack Trace: DecisionsFramework.Design.Flow.ErrorRunningFlowStep: Error running step Get Assignment Role For Folder By Name Or Id 1[GetAssignmentRoleForFolderByNameOrId] in flow [Flow 1]: Exception invoking method GetAssignmentRoleForFolderByNameOrId on class AssignmentRoleSteps ---> DecisionsFramework.LoggedException: Exception invoking method GetAssignmentRoleForFolderByNameOrId on class AssignmentRoleSteps ---> System.ArgumentNullException: Value cannot be null. (Parameter 'folderId' at DecisionsFramework.ServiceLayer.Services.Assignments.AssignmentService.GetAssignmentRoleInFolder(String folderId, String roleTypeId at DecisionsFramework.Design.Flow.CoreSteps.AssignmentRoleSteps.GetRoleByNameOrIdAndFolderId(String folderId, String roleNameOrId at DecisionsFramework.Design.Flow.CoreSteps.AssignmentRoleSteps.GetAssignmentRoleForFolderByNameOrId(String folderId, String roleNameOrId) --- End of inner exception stack trace --- at DecisionsFramework.Design.Flow.StepImplementations.InvokeMethodStep.Run(StepStartData data at DecisionsFramework.Design.Flow.FlowStep.RunStepInternal(String flowTrackingID, String stepTrackingID, KeyValuePairDataStructure[] stepRunDataValues, AbstractFlowTrackingData trackingData at DecisionsFramework.Design.Flow.FlowStep.Start(String flowTrackingID, String stepTrackingID, FlowStateData data, AbstractFlowTrackingData trackingData, RunningStepData currentStepData) --- End of inner exception stack trace --- ``` ## Related - [Get Accounts For Assignment Role](/get-accounts-for-assignment-role.md) - [Get Groups On Assignment Role](/get-groups-on-assignment-role.md) - [Add Users On Assignment Role](/add-users-on-assignment-role.md) - [Set Groups On Assignment Role](/set-groups-on-assignment-role.md)