Skip to content

Commit e801749

Browse files
Merge pull request #453 from microsoftgraph/kiota/beta/pipelinebuild/214955
Generated beta models and request builders
2 parents e3a5fb6 + 5a36b47 commit e801749

File tree

1,541 files changed

+98285
-1340
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,541 files changed

+98285
-1340
lines changed

src/Generated/Admin/ConfigurationManagement/ConfigurationSnapshots/ConfigurationSnapshotsRequestBuilder.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,10 +52,11 @@ public function __construct($pathParametersOrRawUrl, RequestAdapter $requestAdap
5252
}
5353

5454
/**
55-
* A container for configuration snapshot baselines.
55+
* Get a list of configurationBaseline objects that represent configuration snapshots and their properties.
5656
* @param ConfigurationSnapshotsRequestBuilderGetRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
5757
* @return Promise<ConfigurationBaselineCollectionResponse|null>
5858
* @throws Exception
59+
* @link https://learn.microsoft.com/graph/api/configurationmanagement-list-configurationsnapshots?view=graph-rest-beta Find more info here
5960
*/
6061
public function get(?ConfigurationSnapshotsRequestBuilderGetRequestConfiguration $requestConfiguration = null): Promise {
6162
$requestInfo = $this->toGetRequestInformation($requestConfiguration);
@@ -81,7 +82,7 @@ public function post(ConfigurationBaseline $body, ?ConfigurationSnapshotsRequest
8182
}
8283

8384
/**
84-
* A container for configuration snapshot baselines.
85+
* Get a list of configurationBaseline objects that represent configuration snapshots and their properties.
8586
* @param ConfigurationSnapshotsRequestBuilderGetRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
8687
* @return RequestInformation
8788
*/

src/Generated/Admin/ConfigurationManagement/ConfigurationSnapshots/ConfigurationSnapshotsRequestBuilderGetQueryParameters.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
use Microsoft\Kiota\Abstractions\QueryParameter;
66

77
/**
8-
* A container for configuration snapshot baselines.
8+
* Get a list of configurationBaseline objects that represent configuration snapshots and their properties.
99
*/
1010
class ConfigurationSnapshotsRequestBuilderGetQueryParameters
1111
{

src/Generated/ApplicationTemplates/ApplicationTemplatesRequestBuilder.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ public function __construct($pathParametersOrRawUrl, RequestAdapter $requestAdap
5151
}
5252

5353
/**
54-
* Retrieve a list of applicationTemplate objects from the Microsoft Entra application gallery. Details about optional risk properties such as riskScore and riskFactors are available with either the Microsoft Entra Suite or Microsoft Entra Internet Access license.
54+
* Retrieve a list of applicationTemplate objects from the Microsoft Entra application gallery. Details about optional risk properties such as riskScore and riskFactors are available with either the Microsoft Entra Suite or Microsoft Entra Internet Access license. If a risk property is included in the request without appropriate license, a @microsoft.graph.licenseRequired OData annotation is returned in the response.
5555
* @param ApplicationTemplatesRequestBuilderGetRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
5656
* @return Promise<ApplicationTemplateCollectionResponse|null>
5757
* @throws Exception
@@ -66,7 +66,7 @@ public function get(?ApplicationTemplatesRequestBuilderGetRequestConfiguration $
6666
}
6767

6868
/**
69-
* Retrieve a list of applicationTemplate objects from the Microsoft Entra application gallery. Details about optional risk properties such as riskScore and riskFactors are available with either the Microsoft Entra Suite or Microsoft Entra Internet Access license.
69+
* Retrieve a list of applicationTemplate objects from the Microsoft Entra application gallery. Details about optional risk properties such as riskScore and riskFactors are available with either the Microsoft Entra Suite or Microsoft Entra Internet Access license. If a risk property is included in the request without appropriate license, a @microsoft.graph.licenseRequired OData annotation is returned in the response.
7070
* @param ApplicationTemplatesRequestBuilderGetRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
7171
* @return RequestInformation
7272
*/

src/Generated/ApplicationTemplates/ApplicationTemplatesRequestBuilderGetQueryParameters.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
use Microsoft\Kiota\Abstractions\QueryParameter;
66

77
/**
8-
* Retrieve a list of applicationTemplate objects from the Microsoft Entra application gallery. Details about optional risk properties such as riskScore and riskFactors are available with either the Microsoft Entra Suite or Microsoft Entra Internet Access license.
8+
* Retrieve a list of applicationTemplate objects from the Microsoft Entra application gallery. Details about optional risk properties such as riskScore and riskFactors are available with either the Microsoft Entra Suite or Microsoft Entra Internet Access license. If a risk property is included in the request without appropriate license, a @microsoft.graph.licenseRequired OData annotation is returned in the response.
99
*/
1010
class ApplicationTemplatesRequestBuilderGetQueryParameters
1111
{

src/Generated/Chats/Item/ChatItemRequestBuilder.php

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
use Microsoft\Graph\Beta\Generated\Chats\Item\SendActivityNotification\SendActivityNotificationRequestBuilder;
2020
use Microsoft\Graph\Beta\Generated\Chats\Item\StartMigration\StartMigrationRequestBuilder;
2121
use Microsoft\Graph\Beta\Generated\Chats\Item\Tabs\TabsRequestBuilder;
22+
use Microsoft\Graph\Beta\Generated\Chats\Item\TargetedMessages\TargetedMessagesRequestBuilder;
2223
use Microsoft\Graph\Beta\Generated\Chats\Item\UnhideForUser\UnhideForUserRequestBuilder;
2324
use Microsoft\Graph\Beta\Generated\Models\Chat;
2425
use Microsoft\Graph\Beta\Generated\Models\ODataErrors\ODataError;
@@ -137,6 +138,13 @@ public function tabs(): TabsRequestBuilder {
137138
return new TabsRequestBuilder($this->pathParameters, $this->requestAdapter);
138139
}
139140

141+
/**
142+
* Provides operations to manage the targetedMessages property of the microsoft.graph.chat entity.
143+
*/
144+
public function targetedMessages(): TargetedMessagesRequestBuilder {
145+
return new TargetedMessagesRequestBuilder($this->pathParameters, $this->requestAdapter);
146+
}
147+
140148
/**
141149
* Provides operations to call the unhideForUser method.
142150
*/
Lines changed: 78 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,78 @@
1+
<?php
2+
3+
namespace Microsoft\Graph\Beta\Generated\Chats\Item\TargetedMessages\Count;
4+
5+
use Exception;
6+
use Http\Promise\Promise;
7+
use Microsoft\Graph\Beta\Generated\Models\ODataErrors\ODataError;
8+
use Microsoft\Kiota\Abstractions\BaseRequestBuilder;
9+
use Microsoft\Kiota\Abstractions\HttpMethod;
10+
use Microsoft\Kiota\Abstractions\RequestAdapter;
11+
use Microsoft\Kiota\Abstractions\RequestInformation;
12+
13+
/**
14+
* Provides operations to count the resources in the collection.
15+
*/
16+
class CountRequestBuilder extends BaseRequestBuilder
17+
{
18+
/**
19+
* Instantiates a new CountRequestBuilder and sets the default values.
20+
* @param array<string, mixed>|string $pathParametersOrRawUrl Path parameters for the request or a String representing the raw URL.
21+
* @param RequestAdapter $requestAdapter The request adapter to use to execute the requests.
22+
*/
23+
public function __construct($pathParametersOrRawUrl, RequestAdapter $requestAdapter) {
24+
parent::__construct($requestAdapter, [], '{+baseurl}/chats/{chat%2Did}/targetedMessages/$count{?%24filter,%24search}');
25+
if (is_array($pathParametersOrRawUrl)) {
26+
$this->pathParameters = $pathParametersOrRawUrl;
27+
} else {
28+
$this->pathParameters = ['request-raw-url' => $pathParametersOrRawUrl];
29+
}
30+
}
31+
32+
/**
33+
* Get the number of the resource
34+
* @param CountRequestBuilderGetRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
35+
* @return Promise<int|null>
36+
* @throws Exception
37+
*/
38+
public function get(?CountRequestBuilderGetRequestConfiguration $requestConfiguration = null): Promise {
39+
$requestInfo = $this->toGetRequestInformation($requestConfiguration);
40+
$errorMappings = [
41+
'XXX' => [ODataError::class, 'createFromDiscriminatorValue'],
42+
];
43+
/** @var Promise<int|null> $result */
44+
$result = $this->requestAdapter->sendPrimitiveAsync($requestInfo, 'int', $errorMappings);
45+
return $result;
46+
}
47+
48+
/**
49+
* Get the number of the resource
50+
* @param CountRequestBuilderGetRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
51+
* @return RequestInformation
52+
*/
53+
public function toGetRequestInformation(?CountRequestBuilderGetRequestConfiguration $requestConfiguration = null): RequestInformation {
54+
$requestInfo = new RequestInformation();
55+
$requestInfo->urlTemplate = $this->urlTemplate;
56+
$requestInfo->pathParameters = $this->pathParameters;
57+
$requestInfo->httpMethod = HttpMethod::GET;
58+
if ($requestConfiguration !== null) {
59+
$requestInfo->addHeaders($requestConfiguration->headers);
60+
if ($requestConfiguration->queryParameters !== null) {
61+
$requestInfo->setQueryParameters($requestConfiguration->queryParameters);
62+
}
63+
$requestInfo->addRequestOptions(...$requestConfiguration->options);
64+
}
65+
$requestInfo->tryAddHeader('Accept', "text/plain;q=0.9");
66+
return $requestInfo;
67+
}
68+
69+
/**
70+
* Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored.
71+
* @param string $rawUrl The raw URL to use for the request builder.
72+
* @return CountRequestBuilder
73+
*/
74+
public function withUrl(string $rawUrl): CountRequestBuilder {
75+
return new CountRequestBuilder($rawUrl, $this->requestAdapter);
76+
}
77+
78+
}
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
<?php
2+
3+
namespace Microsoft\Graph\Beta\Generated\Chats\Item\TargetedMessages\Count;
4+
5+
use Microsoft\Kiota\Abstractions\QueryParameter;
6+
7+
/**
8+
* Get the number of the resource
9+
*/
10+
class CountRequestBuilderGetQueryParameters
11+
{
12+
/**
13+
* @QueryParameter("%24filter")
14+
* @var string|null $filter Filter items by property values
15+
*/
16+
public ?string $filter = null;
17+
18+
/**
19+
* @QueryParameter("%24search")
20+
* @var string|null $search Search items by search phrases
21+
*/
22+
public ?string $search = null;
23+
24+
/**
25+
* Instantiates a new CountRequestBuilderGetQueryParameters and sets the default values.
26+
* @param string|null $filter Filter items by property values
27+
* @param string|null $search Search items by search phrases
28+
*/
29+
public function __construct(?string $filter = null, ?string $search = null) {
30+
$this->filter = $filter;
31+
$this->search = $search;
32+
}
33+
34+
}
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
<?php
2+
3+
namespace Microsoft\Graph\Beta\Generated\Chats\Item\TargetedMessages\Count;
4+
5+
use Microsoft\Kiota\Abstractions\BaseRequestConfiguration;
6+
use Microsoft\Kiota\Abstractions\RequestOption;
7+
8+
/**
9+
* Configuration for the request such as headers, query parameters, and middleware options.
10+
*/
11+
class CountRequestBuilderGetRequestConfiguration extends BaseRequestConfiguration
12+
{
13+
/**
14+
* @var CountRequestBuilderGetQueryParameters|null $queryParameters Request query parameters
15+
*/
16+
public ?CountRequestBuilderGetQueryParameters $queryParameters = null;
17+
18+
/**
19+
* Instantiates a new CountRequestBuilderGetRequestConfiguration and sets the default values.
20+
* @param array<string, array<string>|string>|null $headers Request headers
21+
* @param array<RequestOption>|null $options Request options
22+
* @param CountRequestBuilderGetQueryParameters|null $queryParameters Request query parameters
23+
*/
24+
public function __construct(?array $headers = null, ?array $options = null, ?CountRequestBuilderGetQueryParameters $queryParameters = null) {
25+
parent::__construct($headers ?? [], $options ?? []);
26+
$this->queryParameters = $queryParameters;
27+
}
28+
29+
/**
30+
* Instantiates a new CountRequestBuilderGetQueryParameters.
31+
* @param string|null $filter Filter items by property values
32+
* @param string|null $search Search items by search phrases
33+
* @return CountRequestBuilderGetQueryParameters
34+
*/
35+
public static function createQueryParameters(?string $filter = null, ?string $search = null): CountRequestBuilderGetQueryParameters {
36+
return new CountRequestBuilderGetQueryParameters($filter, $search);
37+
}
38+
39+
}
Lines changed: 78 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,78 @@
1+
<?php
2+
3+
namespace Microsoft\Graph\Beta\Generated\Chats\Item\TargetedMessages\Item\HostedContents\Count;
4+
5+
use Exception;
6+
use Http\Promise\Promise;
7+
use Microsoft\Graph\Beta\Generated\Models\ODataErrors\ODataError;
8+
use Microsoft\Kiota\Abstractions\BaseRequestBuilder;
9+
use Microsoft\Kiota\Abstractions\HttpMethod;
10+
use Microsoft\Kiota\Abstractions\RequestAdapter;
11+
use Microsoft\Kiota\Abstractions\RequestInformation;
12+
13+
/**
14+
* Provides operations to count the resources in the collection.
15+
*/
16+
class CountRequestBuilder extends BaseRequestBuilder
17+
{
18+
/**
19+
* Instantiates a new CountRequestBuilder and sets the default values.
20+
* @param array<string, mixed>|string $pathParametersOrRawUrl Path parameters for the request or a String representing the raw URL.
21+
* @param RequestAdapter $requestAdapter The request adapter to use to execute the requests.
22+
*/
23+
public function __construct($pathParametersOrRawUrl, RequestAdapter $requestAdapter) {
24+
parent::__construct($requestAdapter, [], '{+baseurl}/chats/{chat%2Did}/targetedMessages/{targetedChatMessage%2Did}/hostedContents/$count{?%24filter,%24search}');
25+
if (is_array($pathParametersOrRawUrl)) {
26+
$this->pathParameters = $pathParametersOrRawUrl;
27+
} else {
28+
$this->pathParameters = ['request-raw-url' => $pathParametersOrRawUrl];
29+
}
30+
}
31+
32+
/**
33+
* Get the number of the resource
34+
* @param CountRequestBuilderGetRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
35+
* @return Promise<int|null>
36+
* @throws Exception
37+
*/
38+
public function get(?CountRequestBuilderGetRequestConfiguration $requestConfiguration = null): Promise {
39+
$requestInfo = $this->toGetRequestInformation($requestConfiguration);
40+
$errorMappings = [
41+
'XXX' => [ODataError::class, 'createFromDiscriminatorValue'],
42+
];
43+
/** @var Promise<int|null> $result */
44+
$result = $this->requestAdapter->sendPrimitiveAsync($requestInfo, 'int', $errorMappings);
45+
return $result;
46+
}
47+
48+
/**
49+
* Get the number of the resource
50+
* @param CountRequestBuilderGetRequestConfiguration|null $requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
51+
* @return RequestInformation
52+
*/
53+
public function toGetRequestInformation(?CountRequestBuilderGetRequestConfiguration $requestConfiguration = null): RequestInformation {
54+
$requestInfo = new RequestInformation();
55+
$requestInfo->urlTemplate = $this->urlTemplate;
56+
$requestInfo->pathParameters = $this->pathParameters;
57+
$requestInfo->httpMethod = HttpMethod::GET;
58+
if ($requestConfiguration !== null) {
59+
$requestInfo->addHeaders($requestConfiguration->headers);
60+
if ($requestConfiguration->queryParameters !== null) {
61+
$requestInfo->setQueryParameters($requestConfiguration->queryParameters);
62+
}
63+
$requestInfo->addRequestOptions(...$requestConfiguration->options);
64+
}
65+
$requestInfo->tryAddHeader('Accept', "text/plain;q=0.9");
66+
return $requestInfo;
67+
}
68+
69+
/**
70+
* Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored.
71+
* @param string $rawUrl The raw URL to use for the request builder.
72+
* @return CountRequestBuilder
73+
*/
74+
public function withUrl(string $rawUrl): CountRequestBuilder {
75+
return new CountRequestBuilder($rawUrl, $this->requestAdapter);
76+
}
77+
78+
}
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
<?php
2+
3+
namespace Microsoft\Graph\Beta\Generated\Chats\Item\TargetedMessages\Item\HostedContents\Count;
4+
5+
use Microsoft\Kiota\Abstractions\QueryParameter;
6+
7+
/**
8+
* Get the number of the resource
9+
*/
10+
class CountRequestBuilderGetQueryParameters
11+
{
12+
/**
13+
* @QueryParameter("%24filter")
14+
* @var string|null $filter Filter items by property values
15+
*/
16+
public ?string $filter = null;
17+
18+
/**
19+
* @QueryParameter("%24search")
20+
* @var string|null $search Search items by search phrases
21+
*/
22+
public ?string $search = null;
23+
24+
/**
25+
* Instantiates a new CountRequestBuilderGetQueryParameters and sets the default values.
26+
* @param string|null $filter Filter items by property values
27+
* @param string|null $search Search items by search phrases
28+
*/
29+
public function __construct(?string $filter = null, ?string $search = null) {
30+
$this->filter = $filter;
31+
$this->search = $search;
32+
}
33+
34+
}

0 commit comments

Comments
 (0)