update_q_app_permissions
async
¶
update_q_app_permissions(
instance_id: InstanceId,
app_id: UUID,
*,
config_overrides: Optional[AsyncQAppsClientConfig] = None,
grant_permissions: Optional[PermissionsInputList] = None,
revoke_permissions: Optional[PermissionsInputList] = None,
) -> UpdateQAppPermissionsOutput
Updates read permissions for a Amazon Q App in Amazon Q Business application environment instance.
Parameters:
-
instance_id(InstanceId) –The unique identifier of the Amazon Q Business application environment instance.
-
app_id(UUID) –The unique identifier of the Amazon Q App for which permissions are being updated.
-
grant_permissions(Optional[PermissionsInputList], default:None) –The list of permissions to grant for the Amazon Q App.
-
revoke_permissions(Optional[PermissionsInputList], default:None) –The list of permissions to revoke for the Amazon Q App.
Raises:
-
AccessDeniedException–The client is not authorized to perform the requested operation.
-
InternalServerException–An internal service error occurred while processing the request.
-
ResourceNotFoundException–The requested resource could not be found.
-
ThrottlingException–The requested operation could not be completed because too many requests were sent at once. Wait a bit and try again later.
-
UnauthorizedException–The client is not authenticated or authorized to perform the requested operation.
-
ValidationException–The input failed to satisfy the constraints specified by the service.
-
UnknownServiceError–The service returned an error code this client does not model.
Examples:
Grant permissions for the app
>>> await client.update_q_app_permissions(instance_id='01793661-ad73-4c7d-8eaa-1c95a10151c2', app_id='fe0acf86-49e5-4def-a0c2-40ce0cafee14', grant_permissions=[{'action': 'read', 'principal': '[email protected]'}])
Revoke permissions for the app
>>> await client.update_q_app_permissions(instance_id='01793661-ad73-4c7d-8eaa-1c95a10151c2', app_id='fe0acf86-49e5-4def-a0c2-40ce0cafee14', revoke_permissions=[{'action': 'read', 'principal': '[email protected]'}])
Source code in docs_src/capo_qapps/_services/async_q_apps.py
2276 2277 2278 2279 2280 2281 2282 2283 2284 2285 2286 2287 2288 2289 2290 2291 2292 2293 2294 2295 2296 2297 2298 2299 2300 2301 2302 2303 2304 2305 2306 2307 2308 2309 2310 2311 2312 2313 2314 2315 2316 2317 2318 2319 2320 2321 2322 2323 2324 2325 2326 2327 2328 2329 2330 2331 2332 2333 2334 2335 2336 2337 2338 2339 2340 2341 2342 2343 2344 2345 2346 2347 2348 | |