# requestOrganizationsForUser Source: https://www.nianticspatial.com/docs/api/swift/NSDK.NSDKSitesSession.method-requestOrganizationsForUser/ requestOrganizationsForUser --- ## Declaration func requestOrganizationsForUser(userId: String, pollingInterval: TimeInterval = 0.5, timeout: TimeInterval = 60.0) async throws -> OrganizationResult #### Summary Requests organizations for a user and waits for the result. This is an async wrapper that combines request initiation and polling. It automatically handles polling until the request completes or times out. #### Returns An OrganizationResult containing the organizations. #### Throws - CancellationError if the Task running this function was cancelled. - TimeoutError if the function timed out before it could complete execution. - SitesResult.Error if there was an error specific to the network query. > **Info:** > > **Notice** > > Note: Consider using `requestSelfOrganizationInfo(pollingInterval:timeout:)` instead. ### Parameters | Name | Type | Summary | | --- | --- | --- | | userId | String | The user ID to fetch organizations for. | | pollingInterval | TimeInterval | The interval between status checks (default: 0.5 seconds). | | timeout | TimeInterval | Maximum time to wait for completion (default: 60 seconds). | ---