update_api
async
¶
update_api(
api_id: __string,
*,
config_overrides: Optional[AsyncApiGatewayV2ClientConfig] = None,
api_key_selection_expression: Optional[SelectionExpression] = None,
cors_configuration: Optional[Cors] = None,
credentials_arn: Optional[Arn] = None,
description: Optional[StringWithLengthBetween0And1024] = None,
disable_schema_validation: Optional[__boolean] = None,
disable_execute_api_endpoint: Optional[__boolean] = None,
ip_address_type: Optional[IpAddressType] = None,
name: Optional[StringWithLengthBetween1And128] = None,
route_key: Optional[SelectionKey] = None,
route_selection_expression: Optional[SelectionExpression] = None,
target: Optional[UriWithLengthBetween1And2048] = None,
version: Optional[StringWithLengthBetween1And64] = None,
) -> UpdateApiResponse
Updates an Api resource.
Parameters:
-
api_id(__string) –The API identifier.
-
api_key_selection_expression(Optional[SelectionExpression], default:None) –An API key selection expression. Supported only for WebSocket APIs. See API Key Selection Expressions.
-
cors_configuration(Optional[Cors], default:None) –A CORS configuration. Supported only for HTTP APIs.
-
credentials_arn(Optional[Arn], default:None) –This property is part of quick create. It specifies the credentials required for the integration, if any. For a Lambda integration, three options are available. To specify an IAM Role for API Gateway to assume, use the role's Amazon Resource Name (ARN). To require that the caller's identity be passed through from the request, specify arn:aws:iam::*:user/*. To use resource-based permissions on supported AWS services, don't specify this parameter. Currently, this property is not used for HTTP integrations. If provided, this value replaces the credentials associated with the quick create integration. Supported only for HTTP APIs.
-
description(Optional[StringWithLengthBetween0And1024], default:None) –The description of the API.
-
disable_schema_validation(Optional[__boolean], default:None) –Avoid validating models when creating a deployment. Supported only for WebSocket APIs.
-
disable_execute_api_endpoint(Optional[__boolean], default:None) –Specifies whether clients can invoke your API by using the default execute-api endpoint. By default, clients can invoke your API with the default https://{api_id}.execute-api.{region}.amazonaws.com endpoint. To require that clients use a custom domain name to invoke your API, disable the default endpoint.
-
ip_address_type(Optional[IpAddressType], default:None) –The IP address types that can invoke your API or domain name.
-
name(Optional[StringWithLengthBetween1And128], default:None) –The name of the API.
-
route_key(Optional[SelectionKey], default:None) –This property is part of quick create. If not specified, the route created using quick create is kept. Otherwise, this value replaces the route key of the quick create route. Additional routes may still be added after the API is updated. Supported only for HTTP APIs.
-
route_selection_expression(Optional[SelectionExpression], default:None) –The route selection expression for the API. For HTTP APIs, the routeSelectionExpression must be ${request.method} ${request.path}. If not provided, this will be the default for HTTP APIs. This property is required for WebSocket APIs.
-
target(Optional[UriWithLengthBetween1And2048], default:None) –This property is part of quick create. For HTTP integrations, specify a fully qualified URL. For Lambda integrations, specify a function ARN. The type of the integration will be HTTP_PROXY or AWS_PROXY, respectively. The value provided updates the integration URI and integration type. You can update a quick-created target, but you can't remove it from an API. Supported only for HTTP APIs.
-
version(Optional[StringWithLengthBetween1And64], default:None) –A version identifier for the API.
Raises:
-
BadRequestException–The request is not valid, for example, the input is incomplete or incorrect. See the accompanying error message for details.
-
ConflictException–The requested operation would cause a conflict with the current state of a service resource associated with the request. Resolve the conflict before retrying this request. See the accompanying error message for details.
-
NotFoundException–The resource specified in the request was not found. See the message field for more information.
-
TooManyRequestsException–A limit has been exceeded. See the accompanying error message for details.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_apigatewayv2/_services/async_api_gateway_v2.py
5532 5533 5534 5535 5536 5537 5538 5539 5540 5541 5542 5543 5544 5545 5546 5547 5548 5549 5550 5551 5552 5553 5554 5555 5556 5557 5558 5559 5560 5561 5562 5563 5564 5565 5566 5567 5568 5569 5570 5571 5572 5573 5574 5575 5576 5577 5578 5579 5580 5581 5582 5583 5584 5585 5586 5587 5588 5589 5590 5591 5592 5593 5594 5595 5596 5597 5598 5599 5600 5601 5602 5603 5604 5605 5606 5607 5608 5609 5610 5611 5612 5613 5614 5615 5616 5617 5618 5619 5620 5621 5622 5623 5624 5625 5626 5627 5628 5629 5630 5631 5632 5633 5634 5635 5636 5637 5638 5639 5640 5641 5642 5643 5644 5645 5646 5647 | |