add_resource_permissions
async
¶
add_resource_permissions(
resource_id: ResourceIdType,
principals: SharePrincipalList,
*,
config_overrides: Optional[AsyncWorkDocsClientConfig] = None,
authentication_token: Optional[AuthenticationHeaderType] = None,
notification_options: Optional[NotificationOptions] = None,
) -> AddResourcePermissionsResponse
Creates a set of permissions for the specified folder or document. The resource permissions are overwritten if the principals already have different permissions.
Parameters:
-
authentication_token(Optional[AuthenticationHeaderType], default:None) –Amazon WorkDocs authentication token. Not required when using Amazon Web Services administrator credentials to access the API.
-
resource_id(ResourceIdType) –The ID of the resource.
-
principals(SharePrincipalList) –The users, groups, or organization being granted permission.
-
notification_options(Optional[NotificationOptions], default:None) –The notification options.
Raises:
-
FailedDependencyException–The Directory Service cannot reach an on-premises instance. Or a dependency under the control of the organization is failing, such as a connected Active Directory.
-
ProhibitedStateException–The specified document version is not in the INITIALIZED state.
-
ServiceUnavailableException–One or more of the dependencies is unavailable.
-
UnauthorizedOperationException–The operation is not permitted.
-
UnauthorizedResourceAccessException–The caller does not have access to perform the action on the resource.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_workdocs/_services/async_work_docs.py
422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 | |