capo-lambda-web 0.2.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- capo_lambda_web/__init__.py +71 -0
- capo_lambda_web/_async.py +25 -0
- capo_lambda_web/_auth/_identity.py +16 -0
- capo_lambda_web/_auth/_providers.py +886 -0
- capo_lambda_web/_auth/_signers.py +121 -0
- capo_lambda_web/_auth/_sigv4.py +579 -0
- capo_lambda_web/_auth/_zapros_handler.py +80 -0
- capo_lambda_web/_body.py +221 -0
- capo_lambda_web/_iter.py +113 -0
- capo_lambda_web/_operations/lambda_web/create_web_function.py +184 -0
- capo_lambda_web/_operations/lambda_web/create_web_function_endpoint.py +194 -0
- capo_lambda_web/_operations/lambda_web/create_web_function_revision.py +188 -0
- capo_lambda_web/_operations/lambda_web/delete_resource_policy.py +147 -0
- capo_lambda_web/_operations/lambda_web/delete_web_function.py +145 -0
- capo_lambda_web/_operations/lambda_web/delete_web_function_endpoint.py +149 -0
- capo_lambda_web/_operations/lambda_web/delete_web_function_revision.py +149 -0
- capo_lambda_web/_operations/lambda_web/get_resource_policy.py +165 -0
- capo_lambda_web/_operations/lambda_web/get_web_account_settings.py +155 -0
- capo_lambda_web/_operations/lambda_web/get_web_function.py +171 -0
- capo_lambda_web/_operations/lambda_web/get_web_function_endpoint.py +180 -0
- capo_lambda_web/_operations/lambda_web/get_web_function_revision.py +174 -0
- capo_lambda_web/_operations/lambda_web/list_tags.py +164 -0
- capo_lambda_web/_operations/lambda_web/list_web_function_endpoints.py +176 -0
- capo_lambda_web/_operations/lambda_web/list_web_function_revisions.py +176 -0
- capo_lambda_web/_operations/lambda_web/list_web_functions.py +168 -0
- capo_lambda_web/_operations/lambda_web/put_resource_policy.py +179 -0
- capo_lambda_web/_operations/lambda_web/tag_resource.py +155 -0
- capo_lambda_web/_operations/lambda_web/untag_resource.py +148 -0
- capo_lambda_web/_operations/lambda_web/update_web_function_endpoint.py +196 -0
- capo_lambda_web/_pagination.py +21 -0
- capo_lambda_web/_protocol/__init__.py +1 -0
- capo_lambda_web/_protocol/errors.py +93 -0
- capo_lambda_web/_protocol/eventstream.py +240 -0
- capo_lambda_web/_protocol/serialize.py +47 -0
- capo_lambda_web/_protocol/xml.py +33 -0
- capo_lambda_web/_resources/lambda_web/web_function.py +477 -0
- capo_lambda_web/_rule_engine/__init__.py +0 -0
- capo_lambda_web/_rule_engine/_aws_partition.py +160 -0
- capo_lambda_web/_rule_engine/_endpoint_rule_set.py +135 -0
- capo_lambda_web/_rule_engine/_endpoint_runtime.py +389 -0
- capo_lambda_web/_services/_aws_config.py +160 -0
- capo_lambda_web/_services/_pipeline.py +264 -0
- capo_lambda_web/_services/async_lambda_web.py +1394 -0
- capo_lambda_web/_services/lambda_web.py +1374 -0
- capo_lambda_web/errors/__init__.py +36 -0
- capo_lambda_web/errors/_base.py +94 -0
- capo_lambda_web/errors/access_denied_exception.py +48 -0
- capo_lambda_web/errors/conflict_exception.py +58 -0
- capo_lambda_web/errors/internal_server_exception.py +47 -0
- capo_lambda_web/errors/resource_not_found_exception.py +60 -0
- capo_lambda_web/errors/service_quota_exceeded_exception.py +74 -0
- capo_lambda_web/errors/throttling_exception.py +60 -0
- capo_lambda_web/errors/validation_exception.py +46 -0
- capo_lambda_web/py.typed +0 -0
- capo_lambda_web/types/_prelude/blob.py +12 -0
- capo_lambda_web/types/_prelude/timestamp.py +17 -0
- capo_lambda_web/types/account_quotas.py +47 -0
- capo_lambda_web/types/account_usage.py +26 -0
- capo_lambda_web/types/application_log_level.py +22 -0
- capo_lambda_web/types/auth_type.py +18 -0
- capo_lambda_web/types/auto_deployment_mode.py +18 -0
- capo_lambda_web/types/build_config.py +55 -0
- capo_lambda_web/types/code_config.py +37 -0
- capo_lambda_web/types/create_web_function_endpoint_request.py +164 -0
- capo_lambda_web/types/create_web_function_endpoint_response.py +291 -0
- capo_lambda_web/types/create_web_function_request.py +72 -0
- capo_lambda_web/types/create_web_function_response.py +144 -0
- capo_lambda_web/types/create_web_function_revision_request.py +76 -0
- capo_lambda_web/types/create_web_function_revision_response.py +157 -0
- capo_lambda_web/types/date_time.py +20 -0
- capo_lambda_web/types/delete_resource_policy_request.py +29 -0
- capo_lambda_web/types/delete_web_function_endpoint_request.py +27 -0
- capo_lambda_web/types/delete_web_function_request.py +24 -0
- capo_lambda_web/types/delete_web_function_revision_request.py +27 -0
- capo_lambda_web/types/description.py +5 -0
- capo_lambda_web/types/domain_name.py +5 -0
- capo_lambda_web/types/endpoint_arn.py +5 -0
- capo_lambda_web/types/endpoint_config.py +134 -0
- capo_lambda_web/types/endpoint_name.py +5 -0
- capo_lambda_web/types/endpoint_state.py +20 -0
- capo_lambda_web/types/endpoint_type.py +19 -0
- capo_lambda_web/types/endpoint_update_status.py +19 -0
- capo_lambda_web/types/environment_variables.py +22 -0
- capo_lambda_web/types/filter.py +46 -0
- capo_lambda_web/types/filter_list.py +29 -0
- capo_lambda_web/types/filter_value_list.py +14 -0
- capo_lambda_web/types/function_arn.py +5 -0
- capo_lambda_web/types/function_endpoint_summary.py +249 -0
- capo_lambda_web/types/function_endpoint_summary_list.py +33 -0
- capo_lambda_web/types/function_name.py +5 -0
- capo_lambda_web/types/function_revision_summary.py +83 -0
- capo_lambda_web/types/function_revision_summary_list.py +33 -0
- capo_lambda_web/types/function_state.py +20 -0
- capo_lambda_web/types/function_summary.py +91 -0
- capo_lambda_web/types/function_summary_list.py +31 -0
- capo_lambda_web/types/get_resource_policy_request.py +24 -0
- capo_lambda_web/types/get_resource_policy_response.py +39 -0
- capo_lambda_web/types/get_web_account_settings_request.py +18 -0
- capo_lambda_web/types/get_web_account_settings_response.py +59 -0
- capo_lambda_web/types/get_web_function_endpoint_request.py +27 -0
- capo_lambda_web/types/get_web_function_endpoint_response.py +285 -0
- capo_lambda_web/types/get_web_function_request.py +24 -0
- capo_lambda_web/types/get_web_function_response.py +91 -0
- capo_lambda_web/types/get_web_function_revision_request.py +27 -0
- capo_lambda_web/types/get_web_function_revision_response.py +155 -0
- capo_lambda_web/types/kms_key_arn.py +5 -0
- capo_lambda_web/types/list_tags_request.py +24 -0
- capo_lambda_web/types/list_tags_response.py +32 -0
- capo_lambda_web/types/list_web_function_endpoints_request.py +54 -0
- capo_lambda_web/types/list_web_function_endpoints_response.py +52 -0
- capo_lambda_web/types/list_web_function_revisions_request.py +54 -0
- capo_lambda_web/types/list_web_function_revisions_response.py +52 -0
- capo_lambda_web/types/list_web_functions_request.py +51 -0
- capo_lambda_web/types/list_web_functions_response.py +46 -0
- capo_lambda_web/types/logging_config.py +67 -0
- capo_lambda_web/types/max_results.py +5 -0
- capo_lambda_web/types/next_token.py +5 -0
- capo_lambda_web/types/policy_revision_id.py +5 -0
- capo_lambda_web/types/put_resource_policy_request.py +43 -0
- capo_lambda_web/types/put_resource_policy_response.py +39 -0
- capo_lambda_web/types/region.py +5 -0
- capo_lambda_web/types/region_list.py +17 -0
- capo_lambda_web/types/regional_endpoint.py +140 -0
- capo_lambda_web/types/regional_endpoints.py +33 -0
- capo_lambda_web/types/resource_arn.py +5 -0
- capo_lambda_web/types/resource_policy.py +5 -0
- capo_lambda_web/types/revision_arn.py +5 -0
- capo_lambda_web/types/revision_config.py +69 -0
- capo_lambda_web/types/revision_error.py +40 -0
- capo_lambda_web/types/revision_errors.py +29 -0
- capo_lambda_web/types/revision_id.py +5 -0
- capo_lambda_web/types/revision_state.py +19 -0
- capo_lambda_web/types/revision_weight.py +38 -0
- capo_lambda_web/types/revision_weight_list.py +31 -0
- capo_lambda_web/types/role_arn.py +5 -0
- capo_lambda_web/types/runtime_config.py +26 -0
- capo_lambda_web/types/s3_object.py +39 -0
- capo_lambda_web/types/scaling_config.py +23 -0
- capo_lambda_web/types/service_config.py +87 -0
- capo_lambda_web/types/system_log_level.py +19 -0
- capo_lambda_web/types/tag_key.py +5 -0
- capo_lambda_web/types/tag_key_list.py +17 -0
- capo_lambda_web/types/tag_resource_request.py +38 -0
- capo_lambda_web/types/tags.py +25 -0
- capo_lambda_web/types/telemetry_config.py +36 -0
- capo_lambda_web/types/throttle_config.py +23 -0
- capo_lambda_web/types/untag_resource_request.py +27 -0
- capo_lambda_web/types/update_web_function_endpoint_request.py +121 -0
- capo_lambda_web/types/update_web_function_endpoint_response.py +291 -0
- capo_lambda_web-0.2.0.dist-info/METADATA +104 -0
- capo_lambda_web-0.2.0.dist-info/RECORD +154 -0
- capo_lambda_web-0.2.0.dist-info/WHEEL +5 -0
- capo_lambda_web-0.2.0.dist-info/licenses/LICENSE +21 -0
- capo_lambda_web-0.2.0.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"""Generated from Smithy shape ``com.amazonaws.lambdaweb#EndpointState``."""
|
|
2
|
+
|
|
3
|
+
from typing import Literal, TypeAlias, cast
|
|
4
|
+
|
|
5
|
+
"""<p>The state of a web function endpoint. Possible values: <code>Pending</code> (endpoint is being created), <code>Active</code> (endpoint is ready to receive traffic), <code>Failed</code> (endpoint creation or update failed), <code>Deleting</code> (endpoint is being deleted).</p>"""
|
|
6
|
+
EndpointState: TypeAlias = Literal[
|
|
7
|
+
"Pending",
|
|
8
|
+
"Active",
|
|
9
|
+
"Failed",
|
|
10
|
+
"Deleting",
|
|
11
|
+
]
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
# --- restJson1 ser/de ---
|
|
15
|
+
def serialize_json(value: EndpointState) -> str:
|
|
16
|
+
return value
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
def deserialize_json(data: str) -> EndpointState:
|
|
20
|
+
return cast(EndpointState, data)
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"""Generated from Smithy shape ``com.amazonaws.lambdaweb#EndpointType``."""
|
|
2
|
+
|
|
3
|
+
from typing import Literal, TypeAlias, cast
|
|
4
|
+
|
|
5
|
+
"""<p>The type of a web function endpoint. Possible values: <code>HomeRegion</code> (serves from the Region where the function was created), <code>MultiRegion</code> (replicates across chosen Regions and routes to the nearest), <code>PerRegion</code> (separate endpoint per Region).</p>"""
|
|
6
|
+
EndpointType: TypeAlias = Literal[
|
|
7
|
+
"HomeRegion",
|
|
8
|
+
"MultiRegion",
|
|
9
|
+
"PerRegion",
|
|
10
|
+
]
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
# --- restJson1 ser/de ---
|
|
14
|
+
def serialize_json(value: EndpointType) -> str:
|
|
15
|
+
return value
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
def deserialize_json(data: str) -> EndpointType:
|
|
19
|
+
return cast(EndpointType, data)
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"""Generated from Smithy shape ``com.amazonaws.lambdaweb#EndpointUpdateStatus``."""
|
|
2
|
+
|
|
3
|
+
from typing import Literal, TypeAlias, cast
|
|
4
|
+
|
|
5
|
+
"""<p>The status of the most recent update to an endpoint. Possible values: <code>InProgress</code> (update is in progress), <code>Successful</code> (update completed successfully), <code>Failed</code> (update failed).</p>"""
|
|
6
|
+
EndpointUpdateStatus: TypeAlias = Literal[
|
|
7
|
+
"InProgress",
|
|
8
|
+
"Successful",
|
|
9
|
+
"Failed",
|
|
10
|
+
]
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
# --- restJson1 ser/de ---
|
|
14
|
+
def serialize_json(value: EndpointUpdateStatus) -> str:
|
|
15
|
+
return value
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
def deserialize_json(data: str) -> EndpointUpdateStatus:
|
|
19
|
+
return cast(EndpointUpdateStatus, data)
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
"""Generated from Smithy shape ``com.amazonaws.lambdaweb#EnvironmentVariables``."""
|
|
2
|
+
|
|
3
|
+
from typing import TypeAlias
|
|
4
|
+
|
|
5
|
+
EnvironmentVariables: TypeAlias = dict["str", "str"]
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
# --- restJson1 ser/de ---
|
|
9
|
+
def serialize_json(input_to_serialize: EnvironmentVariables) -> dict:
|
|
10
|
+
out: dict = {}
|
|
11
|
+
for key, value in input_to_serialize.items():
|
|
12
|
+
out[key] = value
|
|
13
|
+
return out
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
def deserialize_json(data: dict) -> EnvironmentVariables:
|
|
17
|
+
out: EnvironmentVariables = {}
|
|
18
|
+
for key, value in data.items():
|
|
19
|
+
if value is None:
|
|
20
|
+
continue
|
|
21
|
+
out[key] = value
|
|
22
|
+
return out
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
"""Generated from Smithy shape ``com.amazonaws.lambdaweb#Filter``."""
|
|
2
|
+
|
|
3
|
+
from typing import TYPE_CHECKING
|
|
4
|
+
|
|
5
|
+
from typing_extensions import TypedDict
|
|
6
|
+
|
|
7
|
+
from capo_lambda_web.errors import DeserializationError
|
|
8
|
+
|
|
9
|
+
if TYPE_CHECKING:
|
|
10
|
+
import capo_lambda_web.types.filter_value_list
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
class Filter(TypedDict, closed=True):
|
|
14
|
+
name: "str"
|
|
15
|
+
"""<p>The name of the filter field.</p>"""
|
|
16
|
+
values: "capo_lambda_web.types.filter_value_list.FilterValueList"
|
|
17
|
+
"""<p>The values to match for the filter.</p>"""
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
# --- restJson1 ser/de ---
|
|
21
|
+
def serialize_json(value: Filter) -> dict:
|
|
22
|
+
out: dict = {}
|
|
23
|
+
out["name"] = value["name"]
|
|
24
|
+
import capo_lambda_web.types.filter_value_list
|
|
25
|
+
|
|
26
|
+
out["values"] = capo_lambda_web.types.filter_value_list.serialize_json(
|
|
27
|
+
value["values"]
|
|
28
|
+
)
|
|
29
|
+
return out
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
def deserialize_json(data: dict) -> Filter:
|
|
33
|
+
out: Filter = {} # type: ignore[typeddict-item]
|
|
34
|
+
if data.get("name") is not None:
|
|
35
|
+
out["name"] = data["name"]
|
|
36
|
+
else:
|
|
37
|
+
raise DeserializationError("Filter.name required")
|
|
38
|
+
if data.get("values") is not None:
|
|
39
|
+
import capo_lambda_web.types.filter_value_list
|
|
40
|
+
|
|
41
|
+
out["values"] = capo_lambda_web.types.filter_value_list.deserialize_json(
|
|
42
|
+
data["values"]
|
|
43
|
+
)
|
|
44
|
+
else:
|
|
45
|
+
raise DeserializationError("Filter.values required")
|
|
46
|
+
return out
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"""Generated from Smithy shape ``com.amazonaws.lambdaweb#FilterList``."""
|
|
2
|
+
|
|
3
|
+
from typing import TYPE_CHECKING, TypeAlias
|
|
4
|
+
|
|
5
|
+
if TYPE_CHECKING:
|
|
6
|
+
import capo_lambda_web.types.filter
|
|
7
|
+
|
|
8
|
+
FilterList: TypeAlias = list["capo_lambda_web.types.filter.Filter"]
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
# --- restJson1 ser/de ---
|
|
12
|
+
def serialize_json(value: FilterList) -> list:
|
|
13
|
+
import capo_lambda_web.types.filter
|
|
14
|
+
|
|
15
|
+
out: list = []
|
|
16
|
+
for item in value:
|
|
17
|
+
out.append(capo_lambda_web.types.filter.serialize_json(item))
|
|
18
|
+
return out
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
def deserialize_json(data: list) -> FilterList:
|
|
22
|
+
import capo_lambda_web.types.filter
|
|
23
|
+
|
|
24
|
+
out: FilterList = []
|
|
25
|
+
for item in data:
|
|
26
|
+
if item is None:
|
|
27
|
+
continue
|
|
28
|
+
out.append(capo_lambda_web.types.filter.deserialize_json(item))
|
|
29
|
+
return out
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"""Generated from Smithy shape ``com.amazonaws.lambdaweb#FilterValueList``."""
|
|
2
|
+
|
|
3
|
+
from typing import TypeAlias
|
|
4
|
+
|
|
5
|
+
FilterValueList: TypeAlias = list["str"]
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
# --- restJson1 ser/de ---
|
|
9
|
+
def serialize_json(value: FilterValueList) -> list:
|
|
10
|
+
return list(value)
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
def deserialize_json(data: list) -> FilterValueList:
|
|
14
|
+
return [item for item in data if item is not None]
|
|
@@ -0,0 +1,249 @@
|
|
|
1
|
+
"""Generated from Smithy shape ``com.amazonaws.lambdaweb#FunctionEndpointSummary``."""
|
|
2
|
+
|
|
3
|
+
from typing import TYPE_CHECKING
|
|
4
|
+
|
|
5
|
+
from typing_extensions import NotRequired, TypedDict
|
|
6
|
+
|
|
7
|
+
from capo_lambda_web.errors import DeserializationError
|
|
8
|
+
|
|
9
|
+
if TYPE_CHECKING:
|
|
10
|
+
import capo_lambda_web.types.auth_type
|
|
11
|
+
import capo_lambda_web.types.auto_deployment_mode
|
|
12
|
+
import capo_lambda_web.types.date_time
|
|
13
|
+
import capo_lambda_web.types.description
|
|
14
|
+
import capo_lambda_web.types.domain_name
|
|
15
|
+
import capo_lambda_web.types.endpoint_arn
|
|
16
|
+
import capo_lambda_web.types.endpoint_name
|
|
17
|
+
import capo_lambda_web.types.endpoint_state
|
|
18
|
+
import capo_lambda_web.types.endpoint_type
|
|
19
|
+
import capo_lambda_web.types.endpoint_update_status
|
|
20
|
+
import capo_lambda_web.types.region_list
|
|
21
|
+
import capo_lambda_web.types.revision_weight_list
|
|
22
|
+
import capo_lambda_web.types.scaling_config
|
|
23
|
+
import capo_lambda_web.types.throttle_config
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
class FunctionEndpointSummary(TypedDict, closed=True):
|
|
27
|
+
endpoint_arn: "capo_lambda_web.types.endpoint_arn.EndpointArn"
|
|
28
|
+
"""<p>The Amazon Resource Name (ARN) of the endpoint.</p>"""
|
|
29
|
+
endpoint_name: "capo_lambda_web.types.endpoint_name.EndpointName"
|
|
30
|
+
"""<p>The name of the endpoint.</p>"""
|
|
31
|
+
description: NotRequired["capo_lambda_web.types.description.Description"]
|
|
32
|
+
"""<p>A description of the endpoint.</p>"""
|
|
33
|
+
endpoint_type: "capo_lambda_web.types.endpoint_type.EndpointType"
|
|
34
|
+
"""<p>The type of the endpoint.</p>"""
|
|
35
|
+
domain_name: "capo_lambda_web.types.domain_name.DomainName"
|
|
36
|
+
"""<p>The domain name of the endpoint.</p>"""
|
|
37
|
+
auth_type: "capo_lambda_web.types.auth_type.AuthType"
|
|
38
|
+
"""<p>The authorization type for the endpoint.</p>"""
|
|
39
|
+
auto_deployment_mode: (
|
|
40
|
+
"capo_lambda_web.types.auto_deployment_mode.AutoDeploymentMode"
|
|
41
|
+
)
|
|
42
|
+
"""<p>The auto-deployment mode for the endpoint.</p>"""
|
|
43
|
+
revision_weights: "capo_lambda_web.types.revision_weight_list.RevisionWeightList"
|
|
44
|
+
"""<p>The revision weights for the endpoint.</p>"""
|
|
45
|
+
regions: "capo_lambda_web.types.region_list.RegionList"
|
|
46
|
+
"""<p>The list of Regions for the endpoint.</p>"""
|
|
47
|
+
scaling_config: NotRequired["capo_lambda_web.types.scaling_config.ScalingConfig"]
|
|
48
|
+
"""<p>The scaling configuration for the endpoint. This field is absent if the endpoint has no scaling configuration.</p>"""
|
|
49
|
+
throttle_config: NotRequired["capo_lambda_web.types.throttle_config.ThrottleConfig"]
|
|
50
|
+
"""<p>The throttling configuration for the endpoint. This field is absent if the endpoint has no throttling configuration.</p>"""
|
|
51
|
+
state: "capo_lambda_web.types.endpoint_state.EndpointState"
|
|
52
|
+
"""<p>The current state of the endpoint.</p>"""
|
|
53
|
+
state_reason: "str"
|
|
54
|
+
"""<p>The reason for the current state of the endpoint.</p>"""
|
|
55
|
+
update_status: NotRequired[
|
|
56
|
+
"capo_lambda_web.types.endpoint_update_status.EndpointUpdateStatus"
|
|
57
|
+
]
|
|
58
|
+
"""<p>The status of the most recent update to the endpoint.</p>"""
|
|
59
|
+
update_status_reason: NotRequired["str"]
|
|
60
|
+
"""<p>The reason for the current update status of the endpoint.</p>"""
|
|
61
|
+
created_at: "capo_lambda_web.types.date_time.DateTime"
|
|
62
|
+
"""<p>The date and time the endpoint was created.</p>"""
|
|
63
|
+
updated_at: "capo_lambda_web.types.date_time.DateTime"
|
|
64
|
+
"""<p>The date and time the endpoint was last updated.</p>"""
|
|
65
|
+
|
|
66
|
+
|
|
67
|
+
# --- restJson1 ser/de ---
|
|
68
|
+
def serialize_json(value: FunctionEndpointSummary) -> dict:
|
|
69
|
+
out: dict = {}
|
|
70
|
+
out["endpointArn"] = value["endpoint_arn"]
|
|
71
|
+
out["endpointName"] = value["endpoint_name"]
|
|
72
|
+
if "description" in value:
|
|
73
|
+
out["description"] = value["description"]
|
|
74
|
+
import capo_lambda_web.types.endpoint_type
|
|
75
|
+
|
|
76
|
+
out["endpointType"] = capo_lambda_web.types.endpoint_type.serialize_json(
|
|
77
|
+
value["endpoint_type"]
|
|
78
|
+
)
|
|
79
|
+
out["domainName"] = value["domain_name"]
|
|
80
|
+
import capo_lambda_web.types.auth_type
|
|
81
|
+
|
|
82
|
+
out["authType"] = capo_lambda_web.types.auth_type.serialize_json(value["auth_type"])
|
|
83
|
+
import capo_lambda_web.types.auto_deployment_mode
|
|
84
|
+
|
|
85
|
+
out["autoDeploymentMode"] = (
|
|
86
|
+
capo_lambda_web.types.auto_deployment_mode.serialize_json(
|
|
87
|
+
value["auto_deployment_mode"]
|
|
88
|
+
)
|
|
89
|
+
)
|
|
90
|
+
import capo_lambda_web.types.revision_weight_list
|
|
91
|
+
|
|
92
|
+
out["revisionWeights"] = capo_lambda_web.types.revision_weight_list.serialize_json(
|
|
93
|
+
value["revision_weights"]
|
|
94
|
+
)
|
|
95
|
+
import capo_lambda_web.types.region_list
|
|
96
|
+
|
|
97
|
+
out["regions"] = capo_lambda_web.types.region_list.serialize_json(value["regions"])
|
|
98
|
+
if "scaling_config" in value:
|
|
99
|
+
import capo_lambda_web.types.scaling_config
|
|
100
|
+
|
|
101
|
+
out["scalingConfig"] = capo_lambda_web.types.scaling_config.serialize_json(
|
|
102
|
+
value["scaling_config"]
|
|
103
|
+
)
|
|
104
|
+
if "throttle_config" in value:
|
|
105
|
+
import capo_lambda_web.types.throttle_config
|
|
106
|
+
|
|
107
|
+
out["throttleConfig"] = capo_lambda_web.types.throttle_config.serialize_json(
|
|
108
|
+
value["throttle_config"]
|
|
109
|
+
)
|
|
110
|
+
import capo_lambda_web.types.endpoint_state
|
|
111
|
+
|
|
112
|
+
out["state"] = capo_lambda_web.types.endpoint_state.serialize_json(value["state"])
|
|
113
|
+
out["stateReason"] = value["state_reason"]
|
|
114
|
+
if "update_status" in value:
|
|
115
|
+
import capo_lambda_web.types.endpoint_update_status
|
|
116
|
+
|
|
117
|
+
out["updateStatus"] = (
|
|
118
|
+
capo_lambda_web.types.endpoint_update_status.serialize_json(
|
|
119
|
+
value["update_status"]
|
|
120
|
+
)
|
|
121
|
+
)
|
|
122
|
+
if "update_status_reason" in value:
|
|
123
|
+
out["updateStatusReason"] = value["update_status_reason"]
|
|
124
|
+
import capo_lambda_web.types.date_time
|
|
125
|
+
|
|
126
|
+
out["createdAt"] = capo_lambda_web.types.date_time.serialize_json(
|
|
127
|
+
value["created_at"]
|
|
128
|
+
)
|
|
129
|
+
import capo_lambda_web.types.date_time
|
|
130
|
+
|
|
131
|
+
out["updatedAt"] = capo_lambda_web.types.date_time.serialize_json(
|
|
132
|
+
value["updated_at"]
|
|
133
|
+
)
|
|
134
|
+
return out
|
|
135
|
+
|
|
136
|
+
|
|
137
|
+
def deserialize_json(data: dict) -> FunctionEndpointSummary:
|
|
138
|
+
out: FunctionEndpointSummary = {} # type: ignore[typeddict-item]
|
|
139
|
+
if data.get("endpointArn") is not None:
|
|
140
|
+
out["endpoint_arn"] = data["endpointArn"]
|
|
141
|
+
else:
|
|
142
|
+
raise DeserializationError("FunctionEndpointSummary.endpoint_arn required")
|
|
143
|
+
if data.get("endpointName") is not None:
|
|
144
|
+
out["endpoint_name"] = data["endpointName"]
|
|
145
|
+
else:
|
|
146
|
+
raise DeserializationError("FunctionEndpointSummary.endpoint_name required")
|
|
147
|
+
if data.get("description") is not None:
|
|
148
|
+
out["description"] = data["description"]
|
|
149
|
+
if data.get("endpointType") is not None:
|
|
150
|
+
import capo_lambda_web.types.endpoint_type
|
|
151
|
+
|
|
152
|
+
out["endpoint_type"] = capo_lambda_web.types.endpoint_type.deserialize_json(
|
|
153
|
+
data["endpointType"]
|
|
154
|
+
)
|
|
155
|
+
else:
|
|
156
|
+
raise DeserializationError("FunctionEndpointSummary.endpoint_type required")
|
|
157
|
+
if data.get("domainName") is not None:
|
|
158
|
+
out["domain_name"] = data["domainName"]
|
|
159
|
+
else:
|
|
160
|
+
raise DeserializationError("FunctionEndpointSummary.domain_name required")
|
|
161
|
+
if data.get("authType") is not None:
|
|
162
|
+
import capo_lambda_web.types.auth_type
|
|
163
|
+
|
|
164
|
+
out["auth_type"] = capo_lambda_web.types.auth_type.deserialize_json(
|
|
165
|
+
data["authType"]
|
|
166
|
+
)
|
|
167
|
+
else:
|
|
168
|
+
raise DeserializationError("FunctionEndpointSummary.auth_type required")
|
|
169
|
+
if data.get("autoDeploymentMode") is not None:
|
|
170
|
+
import capo_lambda_web.types.auto_deployment_mode
|
|
171
|
+
|
|
172
|
+
out["auto_deployment_mode"] = (
|
|
173
|
+
capo_lambda_web.types.auto_deployment_mode.deserialize_json(
|
|
174
|
+
data["autoDeploymentMode"]
|
|
175
|
+
)
|
|
176
|
+
)
|
|
177
|
+
else:
|
|
178
|
+
raise DeserializationError(
|
|
179
|
+
"FunctionEndpointSummary.auto_deployment_mode required"
|
|
180
|
+
)
|
|
181
|
+
if data.get("revisionWeights") is not None:
|
|
182
|
+
import capo_lambda_web.types.revision_weight_list
|
|
183
|
+
|
|
184
|
+
out["revision_weights"] = (
|
|
185
|
+
capo_lambda_web.types.revision_weight_list.deserialize_json(
|
|
186
|
+
data["revisionWeights"]
|
|
187
|
+
)
|
|
188
|
+
)
|
|
189
|
+
else:
|
|
190
|
+
raise DeserializationError("FunctionEndpointSummary.revision_weights required")
|
|
191
|
+
if data.get("regions") is not None:
|
|
192
|
+
import capo_lambda_web.types.region_list
|
|
193
|
+
|
|
194
|
+
out["regions"] = capo_lambda_web.types.region_list.deserialize_json(
|
|
195
|
+
data["regions"]
|
|
196
|
+
)
|
|
197
|
+
else:
|
|
198
|
+
raise DeserializationError("FunctionEndpointSummary.regions required")
|
|
199
|
+
if data.get("scalingConfig") is not None:
|
|
200
|
+
import capo_lambda_web.types.scaling_config
|
|
201
|
+
|
|
202
|
+
out["scaling_config"] = capo_lambda_web.types.scaling_config.deserialize_json(
|
|
203
|
+
data["scalingConfig"]
|
|
204
|
+
)
|
|
205
|
+
if data.get("throttleConfig") is not None:
|
|
206
|
+
import capo_lambda_web.types.throttle_config
|
|
207
|
+
|
|
208
|
+
out["throttle_config"] = capo_lambda_web.types.throttle_config.deserialize_json(
|
|
209
|
+
data["throttleConfig"]
|
|
210
|
+
)
|
|
211
|
+
if data.get("state") is not None:
|
|
212
|
+
import capo_lambda_web.types.endpoint_state
|
|
213
|
+
|
|
214
|
+
out["state"] = capo_lambda_web.types.endpoint_state.deserialize_json(
|
|
215
|
+
data["state"]
|
|
216
|
+
)
|
|
217
|
+
else:
|
|
218
|
+
raise DeserializationError("FunctionEndpointSummary.state required")
|
|
219
|
+
if data.get("stateReason") is not None:
|
|
220
|
+
out["state_reason"] = data["stateReason"]
|
|
221
|
+
else:
|
|
222
|
+
raise DeserializationError("FunctionEndpointSummary.state_reason required")
|
|
223
|
+
if data.get("updateStatus") is not None:
|
|
224
|
+
import capo_lambda_web.types.endpoint_update_status
|
|
225
|
+
|
|
226
|
+
out["update_status"] = (
|
|
227
|
+
capo_lambda_web.types.endpoint_update_status.deserialize_json(
|
|
228
|
+
data["updateStatus"]
|
|
229
|
+
)
|
|
230
|
+
)
|
|
231
|
+
if data.get("updateStatusReason") is not None:
|
|
232
|
+
out["update_status_reason"] = data["updateStatusReason"]
|
|
233
|
+
if data.get("createdAt") is not None:
|
|
234
|
+
import capo_lambda_web.types.date_time
|
|
235
|
+
|
|
236
|
+
out["created_at"] = capo_lambda_web.types.date_time.deserialize_json(
|
|
237
|
+
data["createdAt"]
|
|
238
|
+
)
|
|
239
|
+
else:
|
|
240
|
+
raise DeserializationError("FunctionEndpointSummary.created_at required")
|
|
241
|
+
if data.get("updatedAt") is not None:
|
|
242
|
+
import capo_lambda_web.types.date_time
|
|
243
|
+
|
|
244
|
+
out["updated_at"] = capo_lambda_web.types.date_time.deserialize_json(
|
|
245
|
+
data["updatedAt"]
|
|
246
|
+
)
|
|
247
|
+
else:
|
|
248
|
+
raise DeserializationError("FunctionEndpointSummary.updated_at required")
|
|
249
|
+
return out
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
"""Generated from Smithy shape ``com.amazonaws.lambdaweb#FunctionEndpointSummaryList``."""
|
|
2
|
+
|
|
3
|
+
from typing import TYPE_CHECKING, TypeAlias
|
|
4
|
+
|
|
5
|
+
if TYPE_CHECKING:
|
|
6
|
+
import capo_lambda_web.types.function_endpoint_summary
|
|
7
|
+
|
|
8
|
+
FunctionEndpointSummaryList: TypeAlias = list[
|
|
9
|
+
"capo_lambda_web.types.function_endpoint_summary.FunctionEndpointSummary"
|
|
10
|
+
]
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
# --- restJson1 ser/de ---
|
|
14
|
+
def serialize_json(value: FunctionEndpointSummaryList) -> list:
|
|
15
|
+
import capo_lambda_web.types.function_endpoint_summary
|
|
16
|
+
|
|
17
|
+
out: list = []
|
|
18
|
+
for item in value:
|
|
19
|
+
out.append(capo_lambda_web.types.function_endpoint_summary.serialize_json(item))
|
|
20
|
+
return out
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
def deserialize_json(data: list) -> FunctionEndpointSummaryList:
|
|
24
|
+
import capo_lambda_web.types.function_endpoint_summary
|
|
25
|
+
|
|
26
|
+
out: FunctionEndpointSummaryList = []
|
|
27
|
+
for item in data:
|
|
28
|
+
if item is None:
|
|
29
|
+
continue
|
|
30
|
+
out.append(
|
|
31
|
+
capo_lambda_web.types.function_endpoint_summary.deserialize_json(item)
|
|
32
|
+
)
|
|
33
|
+
return out
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
"""Generated from Smithy shape ``com.amazonaws.lambdaweb#FunctionRevisionSummary``."""
|
|
2
|
+
|
|
3
|
+
from typing import TYPE_CHECKING
|
|
4
|
+
|
|
5
|
+
from typing_extensions import NotRequired, TypedDict
|
|
6
|
+
|
|
7
|
+
from capo_lambda_web.errors import DeserializationError
|
|
8
|
+
|
|
9
|
+
if TYPE_CHECKING:
|
|
10
|
+
import capo_lambda_web.types.date_time
|
|
11
|
+
import capo_lambda_web.types.description
|
|
12
|
+
import capo_lambda_web.types.revision_arn
|
|
13
|
+
import capo_lambda_web.types.revision_id
|
|
14
|
+
import capo_lambda_web.types.revision_state
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
class FunctionRevisionSummary(TypedDict, closed=True):
|
|
18
|
+
revision_arn: "capo_lambda_web.types.revision_arn.RevisionArn"
|
|
19
|
+
"""<p>The Amazon Resource Name (ARN) of the revision.</p>"""
|
|
20
|
+
revision_id: "capo_lambda_web.types.revision_id.RevisionId"
|
|
21
|
+
"""<p>The identifier of the revision.</p>"""
|
|
22
|
+
description: NotRequired["capo_lambda_web.types.description.Description"]
|
|
23
|
+
"""<p>A description of the revision.</p>"""
|
|
24
|
+
state: "capo_lambda_web.types.revision_state.RevisionState"
|
|
25
|
+
"""<p>The current state of the revision.</p>"""
|
|
26
|
+
state_reason: "str"
|
|
27
|
+
"""<p>The reason for the current state of the revision.</p>"""
|
|
28
|
+
created_at: "capo_lambda_web.types.date_time.DateTime"
|
|
29
|
+
"""<p>The date and time the revision was created.</p>"""
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
# --- restJson1 ser/de ---
|
|
33
|
+
def serialize_json(value: FunctionRevisionSummary) -> dict:
|
|
34
|
+
out: dict = {}
|
|
35
|
+
out["revisionArn"] = value["revision_arn"]
|
|
36
|
+
out["revisionId"] = value["revision_id"]
|
|
37
|
+
if "description" in value:
|
|
38
|
+
out["description"] = value["description"]
|
|
39
|
+
import capo_lambda_web.types.revision_state
|
|
40
|
+
|
|
41
|
+
out["state"] = capo_lambda_web.types.revision_state.serialize_json(value["state"])
|
|
42
|
+
out["stateReason"] = value["state_reason"]
|
|
43
|
+
import capo_lambda_web.types.date_time
|
|
44
|
+
|
|
45
|
+
out["createdAt"] = capo_lambda_web.types.date_time.serialize_json(
|
|
46
|
+
value["created_at"]
|
|
47
|
+
)
|
|
48
|
+
return out
|
|
49
|
+
|
|
50
|
+
|
|
51
|
+
def deserialize_json(data: dict) -> FunctionRevisionSummary:
|
|
52
|
+
out: FunctionRevisionSummary = {} # type: ignore[typeddict-item]
|
|
53
|
+
if data.get("revisionArn") is not None:
|
|
54
|
+
out["revision_arn"] = data["revisionArn"]
|
|
55
|
+
else:
|
|
56
|
+
raise DeserializationError("FunctionRevisionSummary.revision_arn required")
|
|
57
|
+
if data.get("revisionId") is not None:
|
|
58
|
+
out["revision_id"] = data["revisionId"]
|
|
59
|
+
else:
|
|
60
|
+
raise DeserializationError("FunctionRevisionSummary.revision_id required")
|
|
61
|
+
if data.get("description") is not None:
|
|
62
|
+
out["description"] = data["description"]
|
|
63
|
+
if data.get("state") is not None:
|
|
64
|
+
import capo_lambda_web.types.revision_state
|
|
65
|
+
|
|
66
|
+
out["state"] = capo_lambda_web.types.revision_state.deserialize_json(
|
|
67
|
+
data["state"]
|
|
68
|
+
)
|
|
69
|
+
else:
|
|
70
|
+
raise DeserializationError("FunctionRevisionSummary.state required")
|
|
71
|
+
if data.get("stateReason") is not None:
|
|
72
|
+
out["state_reason"] = data["stateReason"]
|
|
73
|
+
else:
|
|
74
|
+
raise DeserializationError("FunctionRevisionSummary.state_reason required")
|
|
75
|
+
if data.get("createdAt") is not None:
|
|
76
|
+
import capo_lambda_web.types.date_time
|
|
77
|
+
|
|
78
|
+
out["created_at"] = capo_lambda_web.types.date_time.deserialize_json(
|
|
79
|
+
data["createdAt"]
|
|
80
|
+
)
|
|
81
|
+
else:
|
|
82
|
+
raise DeserializationError("FunctionRevisionSummary.created_at required")
|
|
83
|
+
return out
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
"""Generated from Smithy shape ``com.amazonaws.lambdaweb#FunctionRevisionSummaryList``."""
|
|
2
|
+
|
|
3
|
+
from typing import TYPE_CHECKING, TypeAlias
|
|
4
|
+
|
|
5
|
+
if TYPE_CHECKING:
|
|
6
|
+
import capo_lambda_web.types.function_revision_summary
|
|
7
|
+
|
|
8
|
+
FunctionRevisionSummaryList: TypeAlias = list[
|
|
9
|
+
"capo_lambda_web.types.function_revision_summary.FunctionRevisionSummary"
|
|
10
|
+
]
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
# --- restJson1 ser/de ---
|
|
14
|
+
def serialize_json(value: FunctionRevisionSummaryList) -> list:
|
|
15
|
+
import capo_lambda_web.types.function_revision_summary
|
|
16
|
+
|
|
17
|
+
out: list = []
|
|
18
|
+
for item in value:
|
|
19
|
+
out.append(capo_lambda_web.types.function_revision_summary.serialize_json(item))
|
|
20
|
+
return out
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
def deserialize_json(data: list) -> FunctionRevisionSummaryList:
|
|
24
|
+
import capo_lambda_web.types.function_revision_summary
|
|
25
|
+
|
|
26
|
+
out: FunctionRevisionSummaryList = []
|
|
27
|
+
for item in data:
|
|
28
|
+
if item is None:
|
|
29
|
+
continue
|
|
30
|
+
out.append(
|
|
31
|
+
capo_lambda_web.types.function_revision_summary.deserialize_json(item)
|
|
32
|
+
)
|
|
33
|
+
return out
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"""Generated from Smithy shape ``com.amazonaws.lambdaweb#FunctionState``."""
|
|
2
|
+
|
|
3
|
+
from typing import Literal, TypeAlias, cast
|
|
4
|
+
|
|
5
|
+
"""<p>The state of a web function. Possible values: <code>Pending</code> (function is being created), <code>Active</code> (function is ready to use), <code>Failed</code> (function creation or update failed), <code>Deleting</code> (function is being deleted).</p>"""
|
|
6
|
+
FunctionState: TypeAlias = Literal[
|
|
7
|
+
"Pending",
|
|
8
|
+
"Active",
|
|
9
|
+
"Failed",
|
|
10
|
+
"Deleting",
|
|
11
|
+
]
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
# --- restJson1 ser/de ---
|
|
15
|
+
def serialize_json(value: FunctionState) -> str:
|
|
16
|
+
return value
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
def deserialize_json(data: str) -> FunctionState:
|
|
20
|
+
return cast(FunctionState, data)
|