forked from microsoftgraph/msgraph-sdk-python
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request microsoftgraph#116 from microsoftgraph/v1.0/pipeli…
…nebuild/107286 Generated models and request builders
- Loading branch information
Showing
11,187 changed files
with
244,589 additions
and
256,864 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
VERSION: str = '1.0.0a10' | ||
VERSION: str = '1.0.0a11' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
83 changes: 83 additions & 0 deletions
83
...ment/health_overviews/item/issues/item/incident_report/incident_report_request_builder.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,83 @@ | ||
from __future__ import annotations | ||
from dataclasses import dataclass | ||
from kiota_abstractions.get_path_parameters import get_path_parameters | ||
from kiota_abstractions.method import Method | ||
from kiota_abstractions.request_adapter import RequestAdapter | ||
from kiota_abstractions.request_information import RequestInformation | ||
from kiota_abstractions.request_option import RequestOption | ||
from kiota_abstractions.response_handler import ResponseHandler | ||
from kiota_abstractions.serialization import Parsable, ParsableFactory | ||
from kiota_abstractions.utils import lazy_import | ||
from typing import Any, Callable, Dict, List, Optional, Union | ||
|
||
o_data_error = lazy_import('msgraph.generated.models.o_data_errors.o_data_error') | ||
|
||
class IncidentReportRequestBuilder(): | ||
""" | ||
Provides operations to call the incidentReport method. | ||
""" | ||
def __init__(self,request_adapter: RequestAdapter, path_parameters: Optional[Union[Dict[str, Any], str]] = None) -> None: | ||
""" | ||
Instantiates a new IncidentReportRequestBuilder and sets the default values. | ||
Args: | ||
pathParameters: The raw url or the Url template parameters for the request. | ||
requestAdapter: The request adapter to use to execute the requests. | ||
""" | ||
if path_parameters is None: | ||
raise Exception("path_parameters cannot be undefined") | ||
if request_adapter is None: | ||
raise Exception("request_adapter cannot be undefined") | ||
# Url template to use to build the URL for the current request builder | ||
self.url_template: str = "{+baseurl}/admin/serviceAnnouncement/healthOverviews/{serviceHealth%2Did}/issues/{serviceHealthIssue%2Did}/incidentReport()" | ||
|
||
url_tpl_params = get_path_parameters(path_parameters) | ||
self.path_parameters = url_tpl_params | ||
self.request_adapter = request_adapter | ||
|
||
async def get(self,request_configuration: Optional[IncidentReportRequestBuilderGetRequestConfiguration] = None) -> bytes: | ||
""" | ||
Invoke function incidentReport | ||
Args: | ||
requestConfiguration: Configuration for the request such as headers, query parameters, and middleware options. | ||
Returns: bytes | ||
""" | ||
request_info = self.to_get_request_information( | ||
request_configuration | ||
) | ||
error_mapping: Dict[str, ParsableFactory] = { | ||
"4XX": o_data_error.ODataError, | ||
"5XX": o_data_error.ODataError, | ||
} | ||
if not self.request_adapter: | ||
raise Exception("Http core is null") | ||
return await self.request_adapter.send_primitive_async(request_info, "bytes", error_mapping) | ||
|
||
def to_get_request_information(self,request_configuration: Optional[IncidentReportRequestBuilderGetRequestConfiguration] = None) -> RequestInformation: | ||
""" | ||
Invoke function incidentReport | ||
Args: | ||
requestConfiguration: Configuration for the request such as headers, query parameters, and middleware options. | ||
Returns: RequestInformation | ||
""" | ||
request_info = RequestInformation() | ||
request_info.url_template = self.url_template | ||
request_info.path_parameters = self.path_parameters | ||
request_info.http_method = Method.GET | ||
if request_configuration: | ||
request_info.add_request_headers(request_configuration.headers) | ||
request_info.add_request_options(request_configuration.options) | ||
return request_info | ||
|
||
@dataclass | ||
class IncidentReportRequestBuilderGetRequestConfiguration(): | ||
""" | ||
Configuration for the request such as headers, query parameters, and middleware options. | ||
""" | ||
# Request headers | ||
headers: Optional[Dict[str, Union[str, List[str]]]] = None | ||
|
||
# Request options | ||
options: Optional[List[RequestOption]] = None | ||
|
||
|
||
|
83 changes: 0 additions & 83 deletions
83
...views/item/issues/item/microsoft_graph_incident_report/incident_report_request_builder.py
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.