Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Generated models and request builders #1325

Merged
merged 1 commit into from
Aug 22, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public function __construct($pathParametersOrRawUrl, RequestAdapter $requestAdap
}

/**
* Return all the group IDs for the groups that the specified user, group, service principal, organizational contact, device, or directory object is a member of. This function is transitive.
* Return all the group IDs for the groups that the specified user, group, service principal, organizational contact, device, or directory object is a member of. This function is transitive. This API returns up to 11,000 group IDs. If more than 11,000 results are available, it returns a 400 Bad Request error with the Directory_ResultSizeLimitExceeded error code. As a workaround, use the List group transitive memberOf API.
* @param GetMemberGroupsPostRequestBody $body The request body
* @param GetMemberGroupsRequestBuilderPostRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
* @return Promise
Expand All @@ -51,7 +51,7 @@ public function post(GetMemberGroupsPostRequestBody $body, ?GetMemberGroupsReque
}

/**
* Return all the group IDs for the groups that the specified user, group, service principal, organizational contact, device, or directory object is a member of. This function is transitive.
* Return all the group IDs for the groups that the specified user, group, service principal, organizational contact, device, or directory object is a member of. This function is transitive. This API returns up to 11,000 group IDs. If more than 11,000 results are available, it returns a 400 Bad Request error with the Directory_ResultSizeLimitExceeded error code. As a workaround, use the List group transitive memberOf API.
* @param GetMemberGroupsPostRequestBody $body The request body
* @param GetMemberGroupsRequestBuilderPostRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
* @return RequestInformation
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,10 @@ public function delete(?ConversationMemberItemRequestBuilderDeleteRequestConfigu
}

/**
* Retrieve a conversationMember from a chat.
* Retrieve a conversationMember from a chat or channel.
* @param ConversationMemberItemRequestBuilderGetRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
* @return Promise
* @link https://learn.microsoft.com/graph/api/chat-get-members?view=graph-rest-1.0 Find more info here
* @link https://learn.microsoft.com/graph/api/conversationmember-get?view=graph-rest-1.0 Find more info here
*/
public function get(?ConversationMemberItemRequestBuilderGetRequestConfiguration $requestConfiguration = null): Promise {
$requestInfo = $this->toGetRequestInformation($requestConfiguration);
Expand Down Expand Up @@ -106,7 +106,7 @@ public function toDeleteRequestInformation(?ConversationMemberItemRequestBuilder
}

/**
* Retrieve a conversationMember from a chat.
* Retrieve a conversationMember from a chat or channel.
* @param ConversationMemberItemRequestBuilderGetRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
* @return RequestInformation
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
use Microsoft\Kiota\Abstractions\QueryParameter;

/**
* Retrieve a conversationMember from a chat.
* Retrieve a conversationMember from a chat or channel.
*/
class ConversationMemberItemRequestBuilderGetQueryParameters
{
Expand Down
6 changes: 3 additions & 3 deletions src/Generated/Chats/Item/Messages/MessagesRequestBuilder.php
Original file line number Diff line number Diff line change
Expand Up @@ -80,11 +80,11 @@ public function get(?MessagesRequestBuilderGetRequestConfiguration $requestConfi
}

/**
* Send a new chatMessage in the specified chat. This API can't create a new chat; you must use the list chats method to retrieve the ID of an existing chat before you can create a chat message.
* Send a new chatMessage in the specified channel or a chat.
* @param ChatMessage $body The request body
* @param MessagesRequestBuilderPostRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
* @return Promise
* @link https://learn.microsoft.com/graph/api/chat-post-messages?view=graph-rest-1.0 Find more info here
* @link https://learn.microsoft.com/graph/api/chatmessage-post?view=graph-rest-1.0 Find more info here
*/
public function post(ChatMessage $body, ?MessagesRequestBuilderPostRequestConfiguration $requestConfiguration = null): Promise {
$requestInfo = $this->toPostRequestInformation($body, $requestConfiguration);
Expand Down Expand Up @@ -121,7 +121,7 @@ public function toGetRequestInformation(?MessagesRequestBuilderGetRequestConfigu
}

/**
* Send a new chatMessage in the specified chat. This API can't create a new chat; you must use the list chats method to retrieve the ID of an existing chat before you can create a chat message.
* Send a new chatMessage in the specified channel or a chat.
* @param ChatMessage $body The request body
* @param MessagesRequestBuilderPostRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
* @return RequestInformation
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public function __construct($pathParametersOrRawUrl, RequestAdapter $requestAdap
}

/**
* Return all the group IDs for the groups that the specified user, group, service principal, organizational contact, device, or directory object is a member of. This function is transitive.
* Return all the group IDs for the groups that the specified user, group, service principal, organizational contact, device, or directory object is a member of. This function is transitive. This API returns up to 11,000 group IDs. If more than 11,000 results are available, it returns a 400 Bad Request error with the Directory_ResultSizeLimitExceeded error code. As a workaround, use the List group transitive memberOf API.
* @param GetMemberGroupsPostRequestBody $body The request body
* @param GetMemberGroupsRequestBuilderPostRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
* @return Promise
Expand All @@ -51,7 +51,7 @@ public function post(GetMemberGroupsPostRequestBody $body, ?GetMemberGroupsReque
}

/**
* Return all the group IDs for the groups that the specified user, group, service principal, organizational contact, device, or directory object is a member of. This function is transitive.
* Return all the group IDs for the groups that the specified user, group, service principal, organizational contact, device, or directory object is a member of. This function is transitive. This API returns up to 11,000 group IDs. If more than 11,000 results are available, it returns a 400 Bad Request error with the Directory_ResultSizeLimitExceeded error code. As a workaround, use the List group transitive memberOf API.
* @param GetMemberGroupsPostRequestBody $body The request body
* @param GetMemberGroupsRequestBuilderPostRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
* @return RequestInformation
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,11 +32,11 @@ public function __construct($pathParametersOrRawUrl, RequestAdapter $requestAdap
}

/**
* Invite participants to the active call. For more information about how to handle operations, see commsOperation.
* Delete a specific participant in a call. In some situations, it is appropriate for an application to remove a participant from an active call. This action can be done before or after the participant answers the call. When an active caller is removed, they are immediately dropped from the call with no pre- or post-removal notification. When an invited participant is removed, any outstanding add participant request is canceled.
* @param InvitePostRequestBody $body The request body
* @param InviteRequestBuilderPostRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
* @return Promise
* @link https://learn.microsoft.com/graph/api/participant-invite?view=graph-rest-1.0 Find more info here
* @link https://learn.microsoft.com/graph/api/participant-delete?view=graph-rest-1.0 Find more info here
*/
public function post(InvitePostRequestBody $body, ?InviteRequestBuilderPostRequestConfiguration $requestConfiguration = null): Promise {
$requestInfo = $this->toPostRequestInformation($body, $requestConfiguration);
Expand All @@ -52,7 +52,7 @@ public function post(InvitePostRequestBody $body, ?InviteRequestBuilderPostReque
}

/**
* Invite participants to the active call. For more information about how to handle operations, see commsOperation.
* Delete a specific participant in a call. In some situations, it is appropriate for an application to remove a participant from an active call. This action can be done before or after the participant answers the call. When an active caller is removed, they are immediately dropped from the call with no pre- or post-removal notification. When an invited participant is removed, any outstanding add participant request is canceled.
* @param InvitePostRequestBody $body The request body
* @param InviteRequestBuilderPostRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
* @return RequestInformation
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public function __construct($pathParametersOrRawUrl, RequestAdapter $requestAdap
}

/**
* Return all the group IDs for the groups that the specified user, group, service principal, organizational contact, device, or directory object is a member of. This function is transitive.
* Return all the group IDs for the groups that the specified user, group, service principal, organizational contact, device, or directory object is a member of. This function is transitive. This API returns up to 11,000 group IDs. If more than 11,000 results are available, it returns a 400 Bad Request error with the Directory_ResultSizeLimitExceeded error code. As a workaround, use the List group transitive memberOf API.
* @param GetMemberGroupsPostRequestBody $body The request body
* @param GetMemberGroupsRequestBuilderPostRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
* @return Promise
Expand All @@ -51,7 +51,7 @@ public function post(GetMemberGroupsPostRequestBody $body, ?GetMemberGroupsReque
}

/**
* Return all the group IDs for the groups that the specified user, group, service principal, organizational contact, device, or directory object is a member of. This function is transitive.
* Return all the group IDs for the groups that the specified user, group, service principal, organizational contact, device, or directory object is a member of. This function is transitive. This API returns up to 11,000 group IDs. If more than 11,000 results are available, it returns a 400 Bad Request error with the Directory_ResultSizeLimitExceeded error code. As a workaround, use the List group transitive memberOf API.
* @param GetMemberGroupsPostRequestBody $body The request body
* @param GetMemberGroupsRequestBuilderPostRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
* @return RequestInformation
Expand Down
8 changes: 8 additions & 0 deletions src/Generated/Contacts/Item/OrgContactItemRequestBuilder.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
use Microsoft\Graph\Generated\Contacts\Item\Manager\ManagerRequestBuilder;
use Microsoft\Graph\Generated\Contacts\Item\MemberOf\MemberOfRequestBuilder;
use Microsoft\Graph\Generated\Contacts\Item\Restore\RestoreRequestBuilder;
use Microsoft\Graph\Generated\Contacts\Item\RetryServiceProvisioning\RetryServiceProvisioningRequestBuilder;
use Microsoft\Graph\Generated\Contacts\Item\TransitiveMemberOf\TransitiveMemberOfRequestBuilder;
use Microsoft\Graph\Generated\Models\ODataErrors\ODataError;
use Microsoft\Graph\Generated\Models\OrgContact;
Expand Down Expand Up @@ -82,6 +83,13 @@ public function restore(): RestoreRequestBuilder {
return new RestoreRequestBuilder($this->pathParameters, $this->requestAdapter);
}

/**
* Provides operations to call the retryServiceProvisioning method.
*/
public function retryServiceProvisioning(): RetryServiceProvisioningRequestBuilder {
return new RetryServiceProvisioningRequestBuilder($this->pathParameters, $this->requestAdapter);
}

/**
* Provides operations to manage the transitiveMemberOf property of the microsoft.graph.orgContact entity.
*/
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
<?php

namespace Microsoft\Graph\Generated\Contacts\Item\RetryServiceProvisioning;

use Exception;
use Http\Promise\Promise;
use Http\Promise\RejectedPromise;
use Microsoft\Graph\Generated\Models\ODataErrors\ODataError;
use Microsoft\Kiota\Abstractions\BaseRequestBuilder;
use Microsoft\Kiota\Abstractions\HttpMethod;
use Microsoft\Kiota\Abstractions\RequestAdapter;
use Microsoft\Kiota\Abstractions\RequestInformation;

/**
* Provides operations to call the retryServiceProvisioning method.
*/
class RetryServiceProvisioningRequestBuilder extends BaseRequestBuilder
{
/**
* Instantiates a new RetryServiceProvisioningRequestBuilder and sets the default values.
* @param array<string, mixed>|string $pathParametersOrRawUrl Path parameters for the request or a String representing the raw URL.
* @param RequestAdapter $requestAdapter The request adapter to use to execute the requests.
*/
public function __construct($pathParametersOrRawUrl, RequestAdapter $requestAdapter) {
parent::__construct($requestAdapter, [], '{+baseurl}/contacts/{orgContact%2Did}/retryServiceProvisioning');
if (is_array($pathParametersOrRawUrl)) {
$this->pathParameters = $pathParametersOrRawUrl;
} else {
$this->pathParameters = ['request-raw-url' => $pathParametersOrRawUrl];
}
}

/**
* Invoke action retryServiceProvisioning
* @param RetryServiceProvisioningRequestBuilderPostRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
* @return Promise
*/
public function post(?RetryServiceProvisioningRequestBuilderPostRequestConfiguration $requestConfiguration = null): Promise {
$requestInfo = $this->toPostRequestInformation($requestConfiguration);
try {
$errorMappings = [
'4XX' => [ODataError::class, 'createFromDiscriminatorValue'],
'5XX' => [ODataError::class, 'createFromDiscriminatorValue'],
];
return $this->requestAdapter->sendNoContentAsync($requestInfo, $errorMappings);
} catch(Exception $ex) {
return new RejectedPromise($ex);
}
}

/**
* Invoke action retryServiceProvisioning
* @param RetryServiceProvisioningRequestBuilderPostRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
* @return RequestInformation
*/
public function toPostRequestInformation(?RetryServiceProvisioningRequestBuilderPostRequestConfiguration $requestConfiguration = null): RequestInformation {
$requestInfo = new RequestInformation();
$requestInfo->urlTemplate = $this->urlTemplate;
$requestInfo->pathParameters = $this->pathParameters;
$requestInfo->httpMethod = HttpMethod::POST;
if ($requestConfiguration !== null) {
$requestInfo->addHeaders($requestConfiguration->headers);
$requestInfo->addRequestOptions(...$requestConfiguration->options);
}
return $requestInfo;
}

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
<?php

namespace Microsoft\Graph\Generated\Contacts\Item\RetryServiceProvisioning;

use Microsoft\Kiota\Abstractions\BaseRequestConfiguration;
use Microsoft\Kiota\Abstractions\RequestOption;

/**
* Configuration for the request such as headers, query parameters, and middleware options.
*/
class RetryServiceProvisioningRequestBuilderPostRequestConfiguration extends BaseRequestConfiguration
{
/**
* Instantiates a new retryServiceProvisioningRequestBuilderPostRequestConfiguration and sets the default values.
* @param array<string, array<string>|string>|null $headers Request headers
* @param array<RequestOption>|null $options Request options
*/
public function __construct(?array $headers = null, ?array $options = null) {
parent::__construct($headers ?? [], $options ?? []);
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public function __construct($pathParametersOrRawUrl, RequestAdapter $requestAdap
}

/**
* Return all the group IDs for the groups that the specified user, group, service principal, organizational contact, device, or directory object is a member of. This function is transitive.
* Return all the group IDs for the groups that the specified user, group, service principal, organizational contact, device, or directory object is a member of. This function is transitive. This API returns up to 11,000 group IDs. If more than 11,000 results are available, it returns a 400 Bad Request error with the Directory_ResultSizeLimitExceeded error code. As a workaround, use the List group transitive memberOf API.
* @param GetMemberGroupsPostRequestBody $body The request body
* @param GetMemberGroupsRequestBuilderPostRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
* @return Promise
Expand All @@ -51,7 +51,7 @@ public function post(GetMemberGroupsPostRequestBody $body, ?GetMemberGroupsReque
}

/**
* Return all the group IDs for the groups that the specified user, group, service principal, organizational contact, device, or directory object is a member of. This function is transitive.
* Return all the group IDs for the groups that the specified user, group, service principal, organizational contact, device, or directory object is a member of. This function is transitive. This API returns up to 11,000 group IDs. If more than 11,000 results are available, it returns a 400 Bad Request error with the Directory_ResultSizeLimitExceeded error code. As a workaround, use the List group transitive memberOf API.
* @param GetMemberGroupsPostRequestBody $body The request body
* @param GetMemberGroupsRequestBuilderPostRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
* @return RequestInformation
Expand Down
Loading