apiTest. set recipient type in body

This commit is contained in:
Viktor Scharf
2023-12-19 23:28:52 +01:00
parent bce38f965f
commit 4e6bdc1688
2 changed files with 6 additions and 1 deletions

View File

@@ -1579,7 +1579,8 @@ class GraphHelper {
* @param string $spaceId
* @param string $itemId
* @param string $shareeId
* @param string|null $role
* @param string $shareType
* @param string|null $role
*
* @return ResponseInterface
* @throws \JsonException
@@ -1592,12 +1593,15 @@ class GraphHelper {
string $spaceId,
string $itemId,
string $shareeId,
string $shareType,
?string $role
): ResponseInterface {
$url = self::getBetaFullUrl($baseUrl, "drives/$spaceId/items/$itemId/invite");
$body = [];
$recipients['objectId'] = $shareeId;
$recipients['@libre.graph.recipient.type'] = $shareType;
$body['recipients'] = [$recipients];
if ($role !== null) {

View File

@@ -112,6 +112,7 @@ class SharingNgContext implements Context {
$spaceId,
$itemId,
$shareeId,
$rows['shareType'],
$rows['role']
)
);