Elastic Load Balancing v2 (elbv2)
Primary Models
Primary models are models that you can act on directly. They are the models that represent resources in the AWS service, and are acted on by the managers.
- pydantic model botocraft.services.elbv2.Listener[source]
Bases:
PrimaryBoto3ModelInformation about a listener.
Show JSON schema
{ "title": "Listener", "description": "Information about a listener.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "LoadBalancerArn": { "title": "Loadbalancerarn", "type": "string" }, "Port": { "title": "Port", "type": "integer" }, "Protocol": { "anyOf": [ { "enum": [ "HTTP", "HTTPS", "TCP", "TLS", "UDP", "TCP_UDP", "GENEVE", "QUIC", "TCP_QUIC" ], "type": "string" }, { "type": "null" } ], "default": "HTTPS", "title": "Protocol" }, "ListenerArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Listenerarn" }, "Certificates": { "anyOf": [ { "items": { "$ref": "#/$defs/Certificate" }, "type": "array" }, { "type": "null" } ], "title": "Certificates" }, "SslPolicy": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Sslpolicy" }, "DefaultActions": { "anyOf": [ { "items": { "$ref": "#/$defs/Action" }, "type": "array" }, { "type": "null" } ], "title": "Defaultactions" }, "AlpnPolicy": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Alpnpolicy" }, "MutualAuthentication": { "anyOf": [ { "$ref": "#/$defs/MutualAuthenticationAttributes" }, { "type": "null" } ], "default": null } }, "$defs": { "Action": { "description": "Information about an action.\n\nEach rule must include exactly one of the following routing actions: ``forward``, ``fixed-response``, or ``redirect``,\nand it must be the last action to be performed.\n\nOptionally, a rule for an HTTPS listener can also include one of the following user authentication actions:\n``authenticate-oidc``, ``authenticate-cognito``, or ``jwt-validation``.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Type": { "default": null, "enum": [ "forward", "authenticate-oidc", "authenticate-cognito", "redirect", "fixed-response", "jwt-validation" ], "title": "Type", "type": "string" }, "TargetGroupArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Targetgrouparn" }, "AuthenticateOidcConfig": { "anyOf": [ { "$ref": "#/$defs/AuthenticateOidcActionConfig" }, { "type": "null" } ], "default": null }, "AuthenticateCognitoConfig": { "anyOf": [ { "$ref": "#/$defs/AuthenticateCognitoActionConfig" }, { "type": "null" } ], "default": null }, "Order": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Order" }, "RedirectConfig": { "anyOf": [ { "$ref": "#/$defs/RedirectActionConfig" }, { "type": "null" } ], "default": null }, "FixedResponseConfig": { "anyOf": [ { "$ref": "#/$defs/FixedResponseActionConfig" }, { "type": "null" } ], "default": null }, "ForwardConfig": { "anyOf": [ { "$ref": "#/$defs/ForwardActionConfig" }, { "type": "null" } ], "default": null }, "JwtValidationConfig": { "anyOf": [ { "$ref": "#/$defs/JwtValidationActionConfig" }, { "type": "null" } ], "default": null } }, "title": "Action", "type": "object" }, "AuthenticateCognitoActionConfig": { "description": "Request parameters to use when integrating with Amazon Cognito to authenticate\nusers.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "UserPoolArn": { "title": "Userpoolarn", "type": "string" }, "UserPoolClientId": { "title": "Userpoolclientid", "type": "string" }, "UserPoolDomain": { "title": "Userpooldomain", "type": "string" }, "SessionCookieName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Sessioncookiename" }, "Scope": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Scope" }, "SessionTimeout": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Sessiontimeout" }, "AuthenticationRequestExtraParams": { "anyOf": [ { "additionalProperties": { "type": "string" }, "type": "object" }, { "type": "null" } ], "title": "Authenticationrequestextraparams" }, "OnUnauthenticatedRequest": { "anyOf": [ { "enum": [ "deny", "allow", "authenticate" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Onunauthenticatedrequest" } }, "required": [ "UserPoolArn", "UserPoolClientId", "UserPoolDomain" ], "title": "AuthenticateCognitoActionConfig", "type": "object" }, "AuthenticateOidcActionConfig": { "description": "Request parameters when using an identity provider (IdP) that is compliant with\nOpenID Connect (OIDC) to authenticate users.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Issuer": { "title": "Issuer", "type": "string" }, "AuthorizationEndpoint": { "title": "Authorizationendpoint", "type": "string" }, "TokenEndpoint": { "title": "Tokenendpoint", "type": "string" }, "UserInfoEndpoint": { "title": "Userinfoendpoint", "type": "string" }, "ClientId": { "title": "Clientid", "type": "string" }, "ClientSecret": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Clientsecret" }, "SessionCookieName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Sessioncookiename" }, "Scope": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Scope" }, "SessionTimeout": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Sessiontimeout" }, "AuthenticationRequestExtraParams": { "anyOf": [ { "additionalProperties": { "type": "string" }, "type": "object" }, { "type": "null" } ], "title": "Authenticationrequestextraparams" }, "OnUnauthenticatedRequest": { "anyOf": [ { "enum": [ "deny", "allow", "authenticate" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Onunauthenticatedrequest" }, "UseExistingClientSecret": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Useexistingclientsecret" } }, "required": [ "Issuer", "AuthorizationEndpoint", "TokenEndpoint", "UserInfoEndpoint", "ClientId" ], "title": "AuthenticateOidcActionConfig", "type": "object" }, "Certificate": { "additionalProperties": true, "description": "Information about an SSL server certificate.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "CertificateArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Certificatearn" }, "IsDefault": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Isdefault" } }, "title": "Certificate", "type": "object" }, "ElbV2TargetGroupStickinessConfig": { "description": "Information about the target group stickiness for a rule.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Enabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Enabled" }, "DurationSeconds": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Durationseconds" } }, "title": "ElbV2TargetGroupStickinessConfig", "type": "object" }, "FixedResponseActionConfig": { "description": "Information about an action that returns a custom HTTP response.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "MessageBody": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Messagebody" }, "StatusCode": { "title": "Statuscode", "type": "string" }, "ContentType": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Contenttype" } }, "required": [ "StatusCode" ], "title": "FixedResponseActionConfig", "type": "object" }, "ForwardActionConfig": { "description": "Information about a forward action.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroups": { "anyOf": [ { "items": { "$ref": "#/$defs/TargetGroupTuple" }, "type": "array" }, { "type": "null" } ], "title": "Targetgroups" }, "TargetGroupStickinessConfig": { "anyOf": [ { "$ref": "#/$defs/ElbV2TargetGroupStickinessConfig" }, { "type": "null" } ], "default": null } }, "title": "ForwardActionConfig", "type": "object" }, "JwtValidationActionAdditionalClaim": { "description": "Information about an additional claim to validate.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Format": { "enum": [ "single-string", "string-array", "space-separated-values" ], "title": "Format", "type": "string" }, "Name": { "title": "Name", "type": "string" }, "Values": { "items": { "type": "string" }, "title": "Values", "type": "array" } }, "required": [ "Format", "Name", "Values" ], "title": "JwtValidationActionAdditionalClaim", "type": "object" }, "JwtValidationActionConfig": { "description": "Information about a JSON Web Token (JWT) validation action.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "JwksEndpoint": { "title": "Jwksendpoint", "type": "string" }, "Issuer": { "title": "Issuer", "type": "string" }, "AdditionalClaims": { "anyOf": [ { "items": { "$ref": "#/$defs/JwtValidationActionAdditionalClaim" }, "type": "array" }, { "type": "null" } ], "title": "Additionalclaims" } }, "required": [ "JwksEndpoint", "Issuer" ], "title": "JwtValidationActionConfig", "type": "object" }, "MutualAuthenticationAttributes": { "description": "Information about the mutual authentication attributes of a listener.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Mode": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Mode" }, "TrustStoreArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Truststorearn" }, "IgnoreClientCertificateExpiry": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Ignoreclientcertificateexpiry" }, "TrustStoreAssociationStatus": { "anyOf": [ { "enum": [ "active", "removed" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Truststoreassociationstatus" }, "AdvertiseTrustStoreCaNames": { "anyOf": [ { "enum": [ "on", "off" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Advertisetruststorecanames" } }, "title": "MutualAuthenticationAttributes", "type": "object" }, "RedirectActionConfig": { "description": "Information about a redirect action.\n\nA URI consists of the following components: protocol://hostname:port/path?query. You must modify at least one of the\nfollowing components to avoid a redirect loop: protocol, hostname, port, or path. Any components that you do not modify\nretain their original values.\n\nYou can reuse URI components using the following reserved keywords:\n\n* #{protocol}\n* #{host}\n* #{port}\n* #{path} (the leading \"/\" is removed)\n* #{query}\n\nFor example, you can change the path to \"/new/#{path}\", the hostname to \"example.#{host}\", or the query to\n\"#{query}&value=xyz\".", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Protocol": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Protocol" }, "Port": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Port" }, "Host": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Host" }, "Path": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Path" }, "Query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Query" }, "StatusCode": { "enum": [ "HTTP_301", "HTTP_302" ], "title": "Statuscode", "type": "string" } }, "required": [ "StatusCode" ], "title": "RedirectActionConfig", "type": "object" }, "TargetGroupTuple": { "description": "Information about how traffic will be distributed between multiple target groups in\na forward rule.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroupArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Targetgrouparn" }, "Weight": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Weight" } }, "title": "TargetGroupTuple", "type": "object" } }, "required": [ "LoadBalancerArn", "Port" ] }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field AlpnPolicy: builtins.list[str] | None [Optional]
[TLS listener] The name of the Application-Layer Protocol Negotiation (ALPN) policy.
- field Certificates: builtins.list[Certificate] | None [Optional]
[HTTPS or TLS listener] The default certificate for the listener.
- field DefaultActions: builtins.list[Action] | None [Optional]
The default actions for the listener.
- field MutualAuthentication: MutualAuthenticationAttributes | None = None
The mutual authentication configuration information.
- field Protocol: Literal['HTTP', 'HTTPS', 'TCP', 'TLS', 'UDP', 'TCP_UDP', 'GENEVE', 'QUIC', 'TCP_QUIC'] | None = 'HTTPS'
The protocol for connections from clients to the load balancer.
- field SslPolicy: str | None = None
[HTTPS or TLS listener] The security policy that defines which protocols and ciphers are supported.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- manager_class
alias of
ListenerManager
- delete()
Delete the model.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- save(**kwargs)
Save the model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- property arn: str | None
Return the ARN of the model. This is the value of the
ListenerArnattribute.- Returns:
The ARN of the model instance.
- property load_balancer: LoadBalancer | None
Return the
LoadBalancerobject that this listener belongs to, if any.Note
The output of this property is cached on the model instance, so calling this multiple times will not result in multiple calls to the AWS API. If you need a fresh copy of the data, you can re-get the model instance from the manager.
- property name: str | None
Get the name of the model instance.
- Returns:
The name of the model instance.
- Raises:
ValueError – If the model has no name identity field.
- objects: ClassVar[classproperty]
Get the manager for this model, and set it as a class property
- property pk: str | None
Return the primary key of the model. This is the value of the
ListenerArnattribute.- Returns:
The primary key of the model instance.
- property rules: list[botocraft.services.elbv2.Rule] | None
Return the ARNs of
Ruleobjects that belong to this listener, if any.Note
The output of this property is cached on the model instance, so calling this multiple times will not result in multiple calls to the AWS API. If you need a fresh copy of the data, you can re-get the model instance from the manager.
- pydantic model botocraft.services.elbv2.LoadBalancer[source]
Bases:
PrimaryBoto3ModelInformation about a load balancer.
Show JSON schema
{ "title": "LoadBalancer", "description": "Information about a load balancer.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "LoadBalancerName": { "title": "Loadbalancername", "type": "string" }, "Scheme": { "anyOf": [ { "enum": [ "internet-facing", "internal" ], "type": "string" }, { "type": "null" } ], "default": "internet-facing", "title": "Scheme" }, "Type": { "anyOf": [ { "enum": [ "application", "network", "gateway" ], "type": "string" }, { "type": "null" } ], "default": "application", "title": "Type" }, "IpAddressType": { "anyOf": [ { "enum": [ "ipv4", "dualstack", "dualstack-without-public-ipv4" ], "type": "string" }, { "type": "null" } ], "default": "ipv4", "title": "Ipaddresstype" }, "LoadBalancerArn": { "default": null, "title": "Loadbalancerarn", "type": "string" }, "DNSName": { "default": null, "title": "Dnsname", "type": "string" }, "CanonicalHostedZoneId": { "default": null, "title": "Canonicalhostedzoneid", "type": "string" }, "CreatedTime": { "default": null, "format": "date-time", "title": "Createdtime", "type": "string" }, "VpcId": { "default": null, "title": "Vpcid", "type": "string" }, "State": { "$ref": "#/$defs/LoadBalancerState", "default": null }, "AvailabilityZones": { "items": { "$ref": "#/$defs/AvailabilityZone" }, "title": "Availabilityzones", "type": "array" }, "SecurityGroups": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Securitygroups" }, "CustomerOwnedIpv4Pool": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Customerownedipv4Pool" }, "EnforceSecurityGroupInboundRulesOnPrivateLinkTraffic": { "default": null, "title": "Enforcesecuritygroupinboundrulesonprivatelinktraffic", "type": "string" }, "EnablePrefixForIpv6SourceNat": { "anyOf": [ { "enum": [ "on", "off" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Enableprefixforipv6Sourcenat" }, "IpamPools": { "anyOf": [ { "$ref": "#/$defs/ElbV2IpamPools" }, { "type": "null" } ], "default": null } }, "$defs": { "AvailabilityZone": { "description": "Information about an Availability Zone.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "ZoneName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Zonename" }, "SubnetId": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Subnetid" }, "OutpostId": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Outpostid" }, "LoadBalancerAddresses": { "anyOf": [ { "items": { "$ref": "#/$defs/LoadBalancerAddress" }, "type": "array" }, { "type": "null" } ], "title": "Loadbalanceraddresses" }, "SourceNatIpv6Prefixes": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Sourcenatipv6Prefixes" } }, "title": "AvailabilityZone", "type": "object" }, "ElbV2IpamPools": { "description": "An IPAM pool is a collection of IP address CIDRs.\n\nIPAM pools enable you to organize your IP addresses according to your routing and\nsecurity needs.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Ipv4IpamPoolId": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Ipv4Ipampoolid" } }, "title": "ElbV2IpamPools", "type": "object" }, "LoadBalancerAddress": { "description": "Information about a static IP address for a load balancer.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "IpAddress": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Ipaddress" }, "AllocationId": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Allocationid" }, "PrivateIPv4Address": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Privateipv4Address" }, "IPv6Address": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Ipv6Address" } }, "title": "LoadBalancerAddress", "type": "object" }, "LoadBalancerState": { "description": "Information about the state of the load balancer.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Code": { "anyOf": [ { "enum": [ "active", "provisioning", "active_impaired", "failed" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Code" }, "Reason": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Reason" } }, "title": "LoadBalancerState", "type": "object" } }, "required": [ "LoadBalancerName" ] }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field AvailabilityZones: builtins.list[AvailabilityZone] [Optional]
The subnets for the load balancer.
- field CanonicalHostedZoneId: str = None
The ID of the Amazon Route 53 hosted zone associated with the load balancer.
- field CustomerOwnedIpv4Pool: str | None = None
[Application Load Balancers on Outposts] The ID of the customer-owned address pool.
- field EnablePrefixForIpv6SourceNat: Literal['on', 'off'] | None = None
[Network Load Balancers with UDP listeners] Indicates whether to use an IPv6 prefix from each subnet for source NAT.
The IP address type must be
dualstack. The default value isoff.
- field EnforceSecurityGroupInboundRulesOnPrivateLinkTraffic: str = None
Indicates whether to evaluate inbound security group rules for traffic sent to a Network Load Balancer through Amazon Web Services PrivateLink.
- field IpAddressType: Literal['ipv4', 'dualstack', 'dualstack-without-public-ipv4'] | None = 'ipv4'
The type of IP addresses used for public or private connections by the subnets attached to your load balancer.
- field IpamPools: ElbV2IpamPools | None = None
[Application Load Balancers] The IPAM pool in use by the load balancer, if configured.
- field Scheme: Literal['internet-facing', 'internal'] | None = 'internet-facing'
The nodes of an Internet-facing load balancer have public IP addresses.
The DNS name of an Internet-facing load balancer is publicly resolvable to the public IP addresses of the nodes. Therefore, Internet-facing load balancers can route requests from clients over the internet.
- field SecurityGroups: builtins.list[str] | None [Optional]
The IDs of the security groups for the load balancer.
- field State: LoadBalancerState = None
The state of the load balancer.
- field Type: Literal['application', 'network', 'gateway'] | None = 'application'
The type of load balancer.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- manager_class
alias of
LoadBalancerManager
- attributes() list[botocraft.services.elbv2.LoadBalancerAttribute][source]
Return the attributes of the load balancer.
These are stored separately from the load balancer object
- delete()
Delete the model.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- save(**kwargs)
Save the model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- property arn: str | None
Return the ARN of the model. This is the value of the
LoadBalancerArnattribute.- Returns:
The ARN of the model instance.
- property listeners: list[botocraft.services.elbv2.Listener] | None
Return the ARNs of
Listenerobjects that belong to this load balancer, if any.Note
The output of this property is cached on the model instance, so calling this multiple times will not result in multiple calls to the AWS API. If you need a fresh copy of the data, you can re-get the model instance from the manager.
- property name: str | None
Return the name of the model. This is the value of the
LoadBalancerNameattribute.- Returns:
The name of the model instance.
- objects: ClassVar[classproperty]
Get the manager for this model, and set it as a class property
- property pk: str | None
Return the primary key of the model. This is the value of the
LoadBalancerArnattribute.- Returns:
The primary key of the model instance.
- property security_groups: list[botocraft.services.ec2.SecurityGroup] | None
Return the ARNs of
SecurityGroupobjects that belong to this load balancer, if any.Note
The output of this property is cached on the model instance, so calling this multiple times will not result in multiple calls to the AWS API. If you need a fresh copy of the data, you can re-get the model instance from the manager.
- property vpc: Vpc | None
Return the
Vpcobject that this load balancer belongs to, if any.Note
The output of this property is cached on the model instance, so calling this multiple times will not result in multiple calls to the AWS API. If you need a fresh copy of the data, you can re-get the model instance from the manager.
- pydantic model botocraft.services.elbv2.Rule[source]
Bases:
PrimaryBoto3ModelInformation about a rule.
Show JSON schema
{ "title": "Rule", "description": "Information about a rule.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Priority": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "1", "title": "Priority" }, "Conditions": { "items": { "$ref": "#/$defs/RuleCondition" }, "title": "Conditions", "type": "array" }, "Actions": { "items": { "$ref": "#/$defs/Action" }, "title": "Actions", "type": "array" }, "IsDefault": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Isdefault" }, "RuleArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Rulearn" }, "Transforms": { "anyOf": [ { "items": { "$ref": "#/$defs/RuleTransform" }, "type": "array" }, { "type": "null" } ], "title": "Transforms" } }, "$defs": { "Action": { "description": "Information about an action.\n\nEach rule must include exactly one of the following routing actions: ``forward``, ``fixed-response``, or ``redirect``,\nand it must be the last action to be performed.\n\nOptionally, a rule for an HTTPS listener can also include one of the following user authentication actions:\n``authenticate-oidc``, ``authenticate-cognito``, or ``jwt-validation``.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Type": { "default": null, "enum": [ "forward", "authenticate-oidc", "authenticate-cognito", "redirect", "fixed-response", "jwt-validation" ], "title": "Type", "type": "string" }, "TargetGroupArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Targetgrouparn" }, "AuthenticateOidcConfig": { "anyOf": [ { "$ref": "#/$defs/AuthenticateOidcActionConfig" }, { "type": "null" } ], "default": null }, "AuthenticateCognitoConfig": { "anyOf": [ { "$ref": "#/$defs/AuthenticateCognitoActionConfig" }, { "type": "null" } ], "default": null }, "Order": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Order" }, "RedirectConfig": { "anyOf": [ { "$ref": "#/$defs/RedirectActionConfig" }, { "type": "null" } ], "default": null }, "FixedResponseConfig": { "anyOf": [ { "$ref": "#/$defs/FixedResponseActionConfig" }, { "type": "null" } ], "default": null }, "ForwardConfig": { "anyOf": [ { "$ref": "#/$defs/ForwardActionConfig" }, { "type": "null" } ], "default": null }, "JwtValidationConfig": { "anyOf": [ { "$ref": "#/$defs/JwtValidationActionConfig" }, { "type": "null" } ], "default": null } }, "title": "Action", "type": "object" }, "AuthenticateCognitoActionConfig": { "description": "Request parameters to use when integrating with Amazon Cognito to authenticate\nusers.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "UserPoolArn": { "title": "Userpoolarn", "type": "string" }, "UserPoolClientId": { "title": "Userpoolclientid", "type": "string" }, "UserPoolDomain": { "title": "Userpooldomain", "type": "string" }, "SessionCookieName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Sessioncookiename" }, "Scope": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Scope" }, "SessionTimeout": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Sessiontimeout" }, "AuthenticationRequestExtraParams": { "anyOf": [ { "additionalProperties": { "type": "string" }, "type": "object" }, { "type": "null" } ], "title": "Authenticationrequestextraparams" }, "OnUnauthenticatedRequest": { "anyOf": [ { "enum": [ "deny", "allow", "authenticate" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Onunauthenticatedrequest" } }, "required": [ "UserPoolArn", "UserPoolClientId", "UserPoolDomain" ], "title": "AuthenticateCognitoActionConfig", "type": "object" }, "AuthenticateOidcActionConfig": { "description": "Request parameters when using an identity provider (IdP) that is compliant with\nOpenID Connect (OIDC) to authenticate users.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Issuer": { "title": "Issuer", "type": "string" }, "AuthorizationEndpoint": { "title": "Authorizationendpoint", "type": "string" }, "TokenEndpoint": { "title": "Tokenendpoint", "type": "string" }, "UserInfoEndpoint": { "title": "Userinfoendpoint", "type": "string" }, "ClientId": { "title": "Clientid", "type": "string" }, "ClientSecret": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Clientsecret" }, "SessionCookieName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Sessioncookiename" }, "Scope": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Scope" }, "SessionTimeout": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Sessiontimeout" }, "AuthenticationRequestExtraParams": { "anyOf": [ { "additionalProperties": { "type": "string" }, "type": "object" }, { "type": "null" } ], "title": "Authenticationrequestextraparams" }, "OnUnauthenticatedRequest": { "anyOf": [ { "enum": [ "deny", "allow", "authenticate" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Onunauthenticatedrequest" }, "UseExistingClientSecret": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Useexistingclientsecret" } }, "required": [ "Issuer", "AuthorizationEndpoint", "TokenEndpoint", "UserInfoEndpoint", "ClientId" ], "title": "AuthenticateOidcActionConfig", "type": "object" }, "ElbV2HostHeaderRewriteConfig": { "description": "Information about a host header rewrite transform.\n\nThis transform matches a pattern in the host header in an HTTP request and replaces\nit with the specified string.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Rewrites": { "anyOf": [ { "items": { "$ref": "#/$defs/RewriteConfig" }, "type": "array" }, { "type": "null" } ], "title": "Rewrites" } }, "title": "ElbV2HostHeaderRewriteConfig", "type": "object" }, "ElbV2TargetGroupStickinessConfig": { "description": "Information about the target group stickiness for a rule.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Enabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Enabled" }, "DurationSeconds": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Durationseconds" } }, "title": "ElbV2TargetGroupStickinessConfig", "type": "object" }, "ElbV2UrlRewriteConfig": { "description": "Information about a URL rewrite transform.\n\nThis transform matches a pattern in the request URL and replaces it with the\nspecified string.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Rewrites": { "anyOf": [ { "items": { "$ref": "#/$defs/RewriteConfig" }, "type": "array" }, { "type": "null" } ], "title": "Rewrites" } }, "title": "ElbV2UrlRewriteConfig", "type": "object" }, "FixedResponseActionConfig": { "description": "Information about an action that returns a custom HTTP response.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "MessageBody": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Messagebody" }, "StatusCode": { "title": "Statuscode", "type": "string" }, "ContentType": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Contenttype" } }, "required": [ "StatusCode" ], "title": "FixedResponseActionConfig", "type": "object" }, "ForwardActionConfig": { "description": "Information about a forward action.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroups": { "anyOf": [ { "items": { "$ref": "#/$defs/TargetGroupTuple" }, "type": "array" }, { "type": "null" } ], "title": "Targetgroups" }, "TargetGroupStickinessConfig": { "anyOf": [ { "$ref": "#/$defs/ElbV2TargetGroupStickinessConfig" }, { "type": "null" } ], "default": null } }, "title": "ForwardActionConfig", "type": "object" }, "HostHeaderConditionConfig": { "description": "Information about a host header condition.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" }, "RegexValues": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Regexvalues" } }, "title": "HostHeaderConditionConfig", "type": "object" }, "HttpHeaderConditionConfig": { "description": "Information about an HTTP header condition.\n\nThere is a set of standard HTTP header fields. You can also define custom HTTP\nheader fields.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "HttpHeaderName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Httpheadername" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" }, "RegexValues": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Regexvalues" } }, "title": "HttpHeaderConditionConfig", "type": "object" }, "HttpRequestMethodConditionConfig": { "description": "Information about an HTTP method condition.\n\nHTTP defines a set of request methods, also referred to as HTTP verbs. For more\ninformation, see the\n`HTTP Method Registry <https://www.iana.org/assignments/http-methods/http-methods.xhtml>`_.\nYou can also define custom HTTP methods.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" } }, "title": "HttpRequestMethodConditionConfig", "type": "object" }, "JwtValidationActionAdditionalClaim": { "description": "Information about an additional claim to validate.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Format": { "enum": [ "single-string", "string-array", "space-separated-values" ], "title": "Format", "type": "string" }, "Name": { "title": "Name", "type": "string" }, "Values": { "items": { "type": "string" }, "title": "Values", "type": "array" } }, "required": [ "Format", "Name", "Values" ], "title": "JwtValidationActionAdditionalClaim", "type": "object" }, "JwtValidationActionConfig": { "description": "Information about a JSON Web Token (JWT) validation action.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "JwksEndpoint": { "title": "Jwksendpoint", "type": "string" }, "Issuer": { "title": "Issuer", "type": "string" }, "AdditionalClaims": { "anyOf": [ { "items": { "$ref": "#/$defs/JwtValidationActionAdditionalClaim" }, "type": "array" }, { "type": "null" } ], "title": "Additionalclaims" } }, "required": [ "JwksEndpoint", "Issuer" ], "title": "JwtValidationActionConfig", "type": "object" }, "PathPatternConditionConfig": { "description": "Information about a path pattern condition.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" }, "RegexValues": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Regexvalues" } }, "title": "PathPatternConditionConfig", "type": "object" }, "QueryStringConditionConfig": { "description": "Information about a query string condition.\n\nThe query string component of a URI starts after the first '?' character and is\nterminated by either a '#' character or the end of the URI. A typical query string\ncontains key/value pairs separated by '&' characters. The allowed characters are\nspecified by RFC 3986. Any character can be percentage encoded.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "$ref": "#/$defs/QueryStringKeyValuePair" }, "type": "array" }, { "type": "null" } ], "title": "Values" } }, "title": "QueryStringConditionConfig", "type": "object" }, "QueryStringKeyValuePair": { "description": "Information about a key/value pair.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Key": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Key" }, "Value": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Value" } }, "title": "QueryStringKeyValuePair", "type": "object" }, "RedirectActionConfig": { "description": "Information about a redirect action.\n\nA URI consists of the following components: protocol://hostname:port/path?query. You must modify at least one of the\nfollowing components to avoid a redirect loop: protocol, hostname, port, or path. Any components that you do not modify\nretain their original values.\n\nYou can reuse URI components using the following reserved keywords:\n\n* #{protocol}\n* #{host}\n* #{port}\n* #{path} (the leading \"/\" is removed)\n* #{query}\n\nFor example, you can change the path to \"/new/#{path}\", the hostname to \"example.#{host}\", or the query to\n\"#{query}&value=xyz\".", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Protocol": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Protocol" }, "Port": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Port" }, "Host": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Host" }, "Path": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Path" }, "Query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Query" }, "StatusCode": { "enum": [ "HTTP_301", "HTTP_302" ], "title": "Statuscode", "type": "string" } }, "required": [ "StatusCode" ], "title": "RedirectActionConfig", "type": "object" }, "RewriteConfig": { "description": "Information about a rewrite transform.\n\nThis transform matches a pattern and replaces it with the specified string.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Regex": { "title": "Regex", "type": "string" }, "Replace": { "title": "Replace", "type": "string" } }, "required": [ "Regex", "Replace" ], "title": "RewriteConfig", "type": "object" }, "RuleCondition": { "description": "Information about a condition for a rule.\n\nEach rule can optionally include up to one of each of the following conditions: ``http-request-method``, ``host-\nheader``, ``path-pattern``, and ``source-ip``. Each rule can also optionally include one or more of each of the\nfollowing conditions: ``http-header`` and ``query-string``. Note that the value for a condition can't be empty.\n\nFor more information, see `Quotas for your Application Load\nBalancers <https://docs.aws.amazon.com/elasticloadbalancing/latest/application/load-balancer-limits.html>`_.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Field": { "default": null, "title": "Field", "type": "string" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" }, "HostHeaderConfig": { "anyOf": [ { "$ref": "#/$defs/HostHeaderConditionConfig" }, { "type": "null" } ], "default": null }, "PathPatternConfig": { "anyOf": [ { "$ref": "#/$defs/PathPatternConditionConfig" }, { "type": "null" } ], "default": null }, "HttpHeaderConfig": { "anyOf": [ { "$ref": "#/$defs/HttpHeaderConditionConfig" }, { "type": "null" } ], "default": null }, "QueryStringConfig": { "anyOf": [ { "$ref": "#/$defs/QueryStringConditionConfig" }, { "type": "null" } ], "default": null }, "HttpRequestMethodConfig": { "anyOf": [ { "$ref": "#/$defs/HttpRequestMethodConditionConfig" }, { "type": "null" } ], "default": null }, "SourceIpConfig": { "anyOf": [ { "$ref": "#/$defs/SourceIpConditionConfig" }, { "type": "null" } ], "default": null }, "RegexValues": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Regexvalues" } }, "title": "RuleCondition", "type": "object" }, "RuleTransform": { "description": "Information about a transform to apply to requests that match a rule.\n\nTransforms are applied to requests before they are sent to targets.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Type": { "enum": [ "host-header-rewrite", "url-rewrite" ], "title": "Type", "type": "string" }, "HostHeaderRewriteConfig": { "anyOf": [ { "$ref": "#/$defs/ElbV2HostHeaderRewriteConfig" }, { "type": "null" } ], "default": null }, "UrlRewriteConfig": { "anyOf": [ { "$ref": "#/$defs/ElbV2UrlRewriteConfig" }, { "type": "null" } ], "default": null } }, "required": [ "Type" ], "title": "RuleTransform", "type": "object" }, "SourceIpConditionConfig": { "description": "Information about a source IP condition.\n\nYou can use this condition to route based on the IP address of the source that\nconnects to the load balancer. If a client is behind a proxy, this is the IP address\nof the proxy not the IP address of the client.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" } }, "title": "SourceIpConditionConfig", "type": "object" }, "TargetGroupTuple": { "description": "Information about how traffic will be distributed between multiple target groups in\na forward rule.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroupArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Targetgrouparn" }, "Weight": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Weight" } }, "title": "TargetGroupTuple", "type": "object" } }, "required": [ "Conditions", "Actions" ] }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field Actions: builtins.list[Action] [Required]
The actions.
Each rule must include exactly one of the following types of actions:
forward,redirect, orfixed-response, and it must be the last action to be performed.
- field Conditions: builtins.list[RuleCondition] [Required]
The conditions.
Each rule can include zero or one of the following conditions:
http-request-method,host-header,path-pattern, andsource-ip, and zero or more of the following conditions:http-headerandquery-string.
- field Transforms: builtins.list[RuleTransform] | None [Optional]
The transforms for the rule.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- manager_class
alias of
RuleManager
- delete()
Delete the model.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- save(**kwargs)
Save the model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- property arn: str | None
Return the ARN of the model. This is the value of the
RuleArnattribute.- Returns:
The ARN of the model instance.
- property name: str | None
Get the name of the model instance.
- Returns:
The name of the model instance.
- Raises:
ValueError – If the model has no name identity field.
- objects: ClassVar[classproperty]
Get the manager for this model, and set it as a class property
- pydantic model botocraft.services.elbv2.TargetGroup[source]
Bases:
PrimaryBoto3ModelInformation about a target group.
Show JSON schema
{ "title": "TargetGroup", "description": "Information about a target group.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroupName": { "title": "Targetgroupname", "type": "string" }, "Protocol": { "anyOf": [ { "enum": [ "HTTP", "HTTPS", "TCP", "TLS", "UDP", "TCP_UDP", "GENEVE", "QUIC", "TCP_QUIC" ], "type": "string" }, { "type": "null" } ], "default": "HTTPS", "title": "Protocol" }, "Port": { "title": "Port", "type": "integer" }, "VpcId": { "title": "Vpcid", "type": "string" }, "TargetType": { "anyOf": [ { "enum": [ "instance", "ip", "lambda", "alb" ], "type": "string" }, { "type": "null" } ], "default": "ip", "title": "Targettype" }, "IpAddressType": { "anyOf": [ { "enum": [ "ipv4", "ipv6" ], "type": "string" }, { "type": "null" } ], "default": "ipv4", "title": "Ipaddresstype" }, "TargetGroupArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Targetgrouparn" }, "HealthCheckProtocol": { "anyOf": [ { "enum": [ "HTTP", "HTTPS", "TCP", "TLS", "UDP", "TCP_UDP", "GENEVE", "QUIC", "TCP_QUIC" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Healthcheckprotocol" }, "HealthCheckPort": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Healthcheckport" }, "HealthCheckEnabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Healthcheckenabled" }, "HealthCheckIntervalSeconds": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Healthcheckintervalseconds" }, "HealthCheckTimeoutSeconds": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Healthchecktimeoutseconds" }, "HealthyThresholdCount": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Healthythresholdcount" }, "UnhealthyThresholdCount": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Unhealthythresholdcount" }, "HealthCheckPath": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Healthcheckpath" }, "Matcher": { "anyOf": [ { "$ref": "#/$defs/ResponseCodeMatcher" }, { "type": "null" } ], "default": null }, "LoadBalancerArns": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Loadbalancerarns" }, "ProtocolVersion": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Protocolversion" }, "TargetControlPort": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Targetcontrolport" } }, "$defs": { "ResponseCodeMatcher": { "description": "The codes to use when checking for a successful response from a target.\n\nIf the protocol version is gRPC, these are gRPC codes. Otherwise, these are HTTP\ncodes.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "HttpCode": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Httpcode" }, "GrpcCode": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Grpccode" } }, "title": "ResponseCodeMatcher", "type": "object" } }, "required": [ "TargetGroupName", "Port", "VpcId" ] }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field HealthCheckIntervalSeconds: int | None = None
The approximate amount of time, in seconds, between health checks of an individual target.
- field HealthCheckProtocol: Literal['HTTP', 'HTTPS', 'TCP', 'TLS', 'UDP', 'TCP_UDP', 'GENEVE', 'QUIC', 'TCP_QUIC'] | None = None
The protocol to use to connect with the target.
The GENEVE, TLS, UDP, and TCP_UDP protocols are not supported for health checks.
- field HealthCheckTimeoutSeconds: int | None = None
The amount of time, in seconds, during which no response means a failed health check.
- field HealthyThresholdCount: int | None = None
The number of consecutive health checks successes required before considering an unhealthy target healthy.
- field IpAddressType: Literal['ipv4', 'ipv6'] | None = 'ipv4'
The IP address type.
The default value is
ipv4.
- field LoadBalancerArns: builtins.list[str] | None [Optional]
The Amazon Resource Name (ARN) of the load balancer that routes traffic to this target group.
You can use each target group with only one load balancer.
- field Matcher: ResponseCodeMatcher | None = None
The HTTP or gRPC codes to use when checking for a successful response from a target.
- field Port: int [Required]
The port on which the targets are listening.
This parameter is not used if the target is a Lambda function.
- field Protocol: Literal['HTTP', 'HTTPS', 'TCP', 'TLS', 'UDP', 'TCP_UDP', 'GENEVE', 'QUIC', 'TCP_QUIC'] | None = 'HTTPS'
The protocol to use for routing traffic to the targets.
- field ProtocolVersion: str | None = None
[HTTP/HTTPS protocol] The protocol version.
The possible values are
GRPC,HTTP1, andHTTP2.
- field TargetControlPort: int | None = None
The port on which the target control agent and application load balancer exchange management traffic for the target optimizer feature.
- field TargetType: Literal['instance', 'ip', 'lambda', 'alb'] | None = 'ip'
The type of target that you must specify when registering targets with this target group.
The possible values are
instance(register targets by instance ID),ip(register targets by IP address),lambda(register a single Lambda function as a target), oralb(register a single Application Load Balancer as a target).
- field UnhealthyThresholdCount: int | None = None
The number of consecutive health check failures required before considering the target unhealthy.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- manager_class
alias of
TargetGroupManager
- delete()
Delete the model.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- save(**kwargs)
Save the model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- targets() list[botocraft.services.elbv2.TargetHealthDescription] | None[source]
Return the targets for the target group.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- property arn: str | None
Return the ARN of the model. This is the value of the
TargetGroupArnattribute.- Returns:
The ARN of the model instance.
- property load_balancers: list[botocraft.services.elbv2.LoadBalancer] | None
Return the ARNs of
LoadBalancerobjects that this target group belongs to, if any.Note
The output of this property is cached on the model instance, so calling this multiple times will not result in multiple calls to the AWS API. If you need a fresh copy of the data, you can re-get the model instance from the manager.
- property name: str | None
Return the name of the model. This is the value of the
TargetGroupNameattribute.- Returns:
The name of the model instance.
- objects: ClassVar[classproperty]
Get the manager for this model, and set it as a class property
- property pk: str | None
Return the primary key of the model. This is the value of the
TargetGroupArnattribute.- Returns:
The primary key of the model instance.
- property vpc: Vpc | None
Return the
Vpcobject that this target group belongs to, if any.Note
The output of this property is cached on the model instance, so calling this multiple times will not result in multiple calls to the AWS API. If you need a fresh copy of the data, you can re-get the model instance from the manager.
Managers
Managers work with the primary models to provide a high-level interface to the AWS service. They are responsible for creating, updating, and deleting the resources in the service, as well as any additional operations that are available for those models.
- class botocraft.services.elbv2.ListenerManager[source]
Bases:
Boto3ModelManager- create(model: Listener, Tags: list[botocraft.services.common.Tag] | None = None) list[botocraft.services.elbv2.Listener][source]
Creates a listener for the specified Application Load Balancer, Network Load Balancer, or Gateway Load Balancer.
- Parameters:
model – The
Listenerto create.- Keyword Arguments:
Tags – The tags to assign to the listener.
- delete(ListenerArn: str) None[source]
Deletes the specified listener.
- Parameters:
ListenerArn – The Amazon Resource Name (ARN) of the listener.
- get(ListenerArn: str) Listener | None[source]
Describes the specified listeners or the listeners for the specified Application Load Balancer, Network Load Balancer, or Gateway Load Balancer. You must specify either a load balancer or one or more listeners.
- Parameters:
ListenerArn – The Amazon Resource Names (ARN) of the listener.
- list(*, LoadBalancerArn: str | None = None, ListenerArns: list[str] | None = None) PrimaryBoto3ModelQuerySet[source]
Describes the specified listeners or the listeners for the specified Application Load Balancer, Network Load Balancer, or Gateway Load Balancer. You must specify either a load balancer or one or more listeners.
- Keyword Arguments:
LoadBalancerArn – The Amazon Resource Name (ARN) of the load balancer.
ListenerArns – The Amazon Resource Names (ARN) of the listeners.
- class botocraft.services.elbv2.LoadBalancerManager[source]
Bases:
LoadBalancerManagerMixin,Boto3ModelManager- attributes(LoadBalancerArn: str) list[botocraft.services.elbv2.LoadBalancerAttribute][source]
Describes the attributes for the specified Application Load Balancer, Network Load Balancer, or Gateway Load Balancer.
- Parameters:
LoadBalancerArn – The Amazon Resource Name (ARN) of the load balancer.
- create(model: LoadBalancer, SubnetMappings: list[botocraft.services.elbv2.SubnetMapping] | None = None, Tags: list[botocraft.services.common.Tag] | None = None) list[botocraft.services.elbv2.LoadBalancer][source]
Creates an Application Load Balancer, Network Load Balancer, or Gateway Load Balancer.
- Parameters:
model – The
LoadBalancerto create.- Keyword Arguments:
SubnetMappings – The IDs of the subnets. You can specify only one subnet per Availability Zone. You must specify either subnets or subnet mappings, but not both.
Tags – The tags to assign to the load balancer.
- delete(LoadBalancerArn: str) None[source]
Deletes the specified Application Load Balancer, Network Load Balancer, or Gateway Load Balancer. Deleting a load balancer also deletes its listeners.
- Parameters:
LoadBalancerArn – The Amazon Resource Name (ARN) of the load balancer.
- list(*, LoadBalancerArns: list[str] | None = None, Names: list[str] | None = None) PrimaryBoto3ModelQuerySet[source]
Describes the specified load balancers or all of your load balancers.
- Keyword Arguments:
LoadBalancerArns – The Amazon Resource Names (ARN) of the load balancers. You can specify up to 20 load balancers in a single call.
Names – The names of the load balancers.
- class botocraft.services.elbv2.RuleManager[source]
Bases:
Boto3ModelManager- create(model: Rule, ListenerArn: str, Tags: list[botocraft.services.common.Tag] | None = None) list[botocraft.services.elbv2.Rule][source]
Creates a rule for the specified listener. The listener must be associated with an Application Load Balancer.
- Parameters:
model – The
Ruleto create.ListenerArn – The Amazon Resource Name (ARN) of the listener.
- Keyword Arguments:
Tags – The tags to assign to the rule.
- delete(RuleArn: str) None[source]
Deletes the specified rule.
- Parameters:
RuleArn – The Amazon Resource Name (ARN) of the rule.
- get(RuleArn: str) Rule | None[source]
Describes the specified rules or the rules for the specified listener. You must specify either a listener or rules.
- Parameters:
RuleArn – The Amazon Resource Names (ARN) of the rule.
- list(*, ListenerArn: str | None = None, RuleArns: list[str] | None = None) PrimaryBoto3ModelQuerySet[source]
Describes the specified rules or the rules for the specified listener. You must specify either a listener or rules.
- Keyword Arguments:
ListenerArn – The Amazon Resource Name (ARN) of the listener.
RuleArns – The Amazon Resource Names (ARN) of the rules.
- update(model: Rule, ResetTransforms: bool | None = None) list[botocraft.services.elbv2.Rule][source]
Replaces the specified properties of the specified rule. Any properties that you do not specify are unchanged.
- Parameters:
model – The
Ruleto update.- Keyword Arguments:
ResetTransforms – Indicates whether to remove all transforms from the rule. If you specify
ResetTransforms, you can’t specifyTransforms.
- class botocraft.services.elbv2.TargetGroupManager[source]
Bases:
Boto3ModelManager- create(model: TargetGroup, Name: str, Tags: list[botocraft.services.common.Tag] | None = None) list[botocraft.services.elbv2.TargetGroup][source]
Creates a target group.
- Parameters:
model – The
TargetGroupto create.Name – The name of the target group.
- Keyword Arguments:
Tags – The tags to assign to the target group.
- delete(TargetGroupArn: str) None[source]
Deletes the specified target group.
- Parameters:
TargetGroupArn – The Amazon Resource Name (ARN) of the target group.
- get(*, TargetGroupArn: str | None = None, Name: str | None = None) TargetGroup | None[source]
Describes the specified target groups or all of your target groups. By default, all target groups are described. Alternatively, you can specify one of the following to filter the results: the ARN of the load balancer, the names of one or more target groups, or the ARNs of one or more target groups.
- Keyword Arguments:
TargetGroupArn – The Amazon Resource Names (ARN) of the target group.
Name – The name of the target group.
- list(*, LoadBalancerArn: str | None = None, TargetGroupArns: list[str] | None = None, Names: list[str] | None = None) PrimaryBoto3ModelQuerySet[source]
Describes the specified target groups or all of your target groups. By default, all target groups are described. Alternatively, you can specify one of the following to filter the results: the ARN of the load balancer, the names of one or more target groups, or the ARNs of one or more target groups.
- Keyword Arguments:
LoadBalancerArn – The Amazon Resource Name (ARN) of the load balancer.
TargetGroupArns – The Amazon Resource Names (ARN) of the target groups.
Names – The names of the target groups.
- targets(TargetGroupArn: str, *, Targets: list[botocraft.services.elbv2.TargetDescription] | None = None, Include: list[Literal['AnomalyDetection', 'All']] | None = None) list[botocraft.services.elbv2.TargetHealthDescription] | None[source]
Describes the health of the specified targets or all of your targets.
- Parameters:
TargetGroupArn – The Amazon Resource Name (ARN) of the target group.
- Keyword Arguments:
Targets – The targets.
Include – Used to include anomaly detection information.
- update(model: TargetGroup) list[botocraft.services.elbv2.TargetGroup][source]
Modifies the health checks used when evaluating the health state of the targets in the specified target group.
- Parameters:
model – The
TargetGroupto update.
Secondary Models
Secondary models are models that are used by the primary models to organize their data. They are not acted on directly, but are used to describe the structure of the fields in the primary models or other secondary models.
- pydantic model botocraft.services.elbv2.Action[source]
Bases:
Boto3ModelInformation about an action.
Each rule must include exactly one of the following routing actions:
forward,fixed-response, orredirect, and it must be the last action to be performed.Optionally, a rule for an HTTPS listener can also include one of the following user authentication actions:
authenticate-oidc,authenticate-cognito, orjwt-validation.Show JSON schema
{ "title": "Action", "description": "Information about an action.\n\nEach rule must include exactly one of the following routing actions: ``forward``, ``fixed-response``, or ``redirect``,\nand it must be the last action to be performed.\n\nOptionally, a rule for an HTTPS listener can also include one of the following user authentication actions:\n``authenticate-oidc``, ``authenticate-cognito``, or ``jwt-validation``.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Type": { "default": null, "enum": [ "forward", "authenticate-oidc", "authenticate-cognito", "redirect", "fixed-response", "jwt-validation" ], "title": "Type", "type": "string" }, "TargetGroupArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Targetgrouparn" }, "AuthenticateOidcConfig": { "anyOf": [ { "$ref": "#/$defs/AuthenticateOidcActionConfig" }, { "type": "null" } ], "default": null }, "AuthenticateCognitoConfig": { "anyOf": [ { "$ref": "#/$defs/AuthenticateCognitoActionConfig" }, { "type": "null" } ], "default": null }, "Order": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Order" }, "RedirectConfig": { "anyOf": [ { "$ref": "#/$defs/RedirectActionConfig" }, { "type": "null" } ], "default": null }, "FixedResponseConfig": { "anyOf": [ { "$ref": "#/$defs/FixedResponseActionConfig" }, { "type": "null" } ], "default": null }, "ForwardConfig": { "anyOf": [ { "$ref": "#/$defs/ForwardActionConfig" }, { "type": "null" } ], "default": null }, "JwtValidationConfig": { "anyOf": [ { "$ref": "#/$defs/JwtValidationActionConfig" }, { "type": "null" } ], "default": null } }, "$defs": { "AuthenticateCognitoActionConfig": { "description": "Request parameters to use when integrating with Amazon Cognito to authenticate\nusers.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "UserPoolArn": { "title": "Userpoolarn", "type": "string" }, "UserPoolClientId": { "title": "Userpoolclientid", "type": "string" }, "UserPoolDomain": { "title": "Userpooldomain", "type": "string" }, "SessionCookieName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Sessioncookiename" }, "Scope": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Scope" }, "SessionTimeout": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Sessiontimeout" }, "AuthenticationRequestExtraParams": { "anyOf": [ { "additionalProperties": { "type": "string" }, "type": "object" }, { "type": "null" } ], "title": "Authenticationrequestextraparams" }, "OnUnauthenticatedRequest": { "anyOf": [ { "enum": [ "deny", "allow", "authenticate" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Onunauthenticatedrequest" } }, "required": [ "UserPoolArn", "UserPoolClientId", "UserPoolDomain" ], "title": "AuthenticateCognitoActionConfig", "type": "object" }, "AuthenticateOidcActionConfig": { "description": "Request parameters when using an identity provider (IdP) that is compliant with\nOpenID Connect (OIDC) to authenticate users.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Issuer": { "title": "Issuer", "type": "string" }, "AuthorizationEndpoint": { "title": "Authorizationendpoint", "type": "string" }, "TokenEndpoint": { "title": "Tokenendpoint", "type": "string" }, "UserInfoEndpoint": { "title": "Userinfoendpoint", "type": "string" }, "ClientId": { "title": "Clientid", "type": "string" }, "ClientSecret": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Clientsecret" }, "SessionCookieName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Sessioncookiename" }, "Scope": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Scope" }, "SessionTimeout": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Sessiontimeout" }, "AuthenticationRequestExtraParams": { "anyOf": [ { "additionalProperties": { "type": "string" }, "type": "object" }, { "type": "null" } ], "title": "Authenticationrequestextraparams" }, "OnUnauthenticatedRequest": { "anyOf": [ { "enum": [ "deny", "allow", "authenticate" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Onunauthenticatedrequest" }, "UseExistingClientSecret": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Useexistingclientsecret" } }, "required": [ "Issuer", "AuthorizationEndpoint", "TokenEndpoint", "UserInfoEndpoint", "ClientId" ], "title": "AuthenticateOidcActionConfig", "type": "object" }, "ElbV2TargetGroupStickinessConfig": { "description": "Information about the target group stickiness for a rule.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Enabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Enabled" }, "DurationSeconds": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Durationseconds" } }, "title": "ElbV2TargetGroupStickinessConfig", "type": "object" }, "FixedResponseActionConfig": { "description": "Information about an action that returns a custom HTTP response.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "MessageBody": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Messagebody" }, "StatusCode": { "title": "Statuscode", "type": "string" }, "ContentType": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Contenttype" } }, "required": [ "StatusCode" ], "title": "FixedResponseActionConfig", "type": "object" }, "ForwardActionConfig": { "description": "Information about a forward action.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroups": { "anyOf": [ { "items": { "$ref": "#/$defs/TargetGroupTuple" }, "type": "array" }, { "type": "null" } ], "title": "Targetgroups" }, "TargetGroupStickinessConfig": { "anyOf": [ { "$ref": "#/$defs/ElbV2TargetGroupStickinessConfig" }, { "type": "null" } ], "default": null } }, "title": "ForwardActionConfig", "type": "object" }, "JwtValidationActionAdditionalClaim": { "description": "Information about an additional claim to validate.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Format": { "enum": [ "single-string", "string-array", "space-separated-values" ], "title": "Format", "type": "string" }, "Name": { "title": "Name", "type": "string" }, "Values": { "items": { "type": "string" }, "title": "Values", "type": "array" } }, "required": [ "Format", "Name", "Values" ], "title": "JwtValidationActionAdditionalClaim", "type": "object" }, "JwtValidationActionConfig": { "description": "Information about a JSON Web Token (JWT) validation action.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "JwksEndpoint": { "title": "Jwksendpoint", "type": "string" }, "Issuer": { "title": "Issuer", "type": "string" }, "AdditionalClaims": { "anyOf": [ { "items": { "$ref": "#/$defs/JwtValidationActionAdditionalClaim" }, "type": "array" }, { "type": "null" } ], "title": "Additionalclaims" } }, "required": [ "JwksEndpoint", "Issuer" ], "title": "JwtValidationActionConfig", "type": "object" }, "RedirectActionConfig": { "description": "Information about a redirect action.\n\nA URI consists of the following components: protocol://hostname:port/path?query. You must modify at least one of the\nfollowing components to avoid a redirect loop: protocol, hostname, port, or path. Any components that you do not modify\nretain their original values.\n\nYou can reuse URI components using the following reserved keywords:\n\n* #{protocol}\n* #{host}\n* #{port}\n* #{path} (the leading \"/\" is removed)\n* #{query}\n\nFor example, you can change the path to \"/new/#{path}\", the hostname to \"example.#{host}\", or the query to\n\"#{query}&value=xyz\".", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Protocol": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Protocol" }, "Port": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Port" }, "Host": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Host" }, "Path": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Path" }, "Query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Query" }, "StatusCode": { "enum": [ "HTTP_301", "HTTP_302" ], "title": "Statuscode", "type": "string" } }, "required": [ "StatusCode" ], "title": "RedirectActionConfig", "type": "object" }, "TargetGroupTuple": { "description": "Information about how traffic will be distributed between multiple target groups in\na forward rule.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroupArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Targetgrouparn" }, "Weight": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Weight" } }, "title": "TargetGroupTuple", "type": "object" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
AuthenticateCognitoConfig (botocraft.services.elbv2.AuthenticateCognitoActionConfig | None)AuthenticateOidcConfig (botocraft.services.elbv2.AuthenticateOidcActionConfig | None)FixedResponseConfig (botocraft.services.elbv2.FixedResponseActionConfig | None)ForwardConfig (botocraft.services.elbv2.ForwardActionConfig | None)JwtValidationConfig (botocraft.services.elbv2.JwtValidationActionConfig | None)RedirectConfig (botocraft.services.elbv2.RedirectActionConfig | None)
- field ActionType: Literal['forward', 'authenticate-oidc', 'authenticate-cognito', 'redirect', 'fixed-response', 'jwt-validation'] = None (alias 'Type')
The type of action.
- field AuthenticateCognitoConfig: AuthenticateCognitoActionConfig | None = None
[HTTPS listeners] Information for using Amazon Cognito to authenticate users.
Specify only when
Typeisauthenticate-cognito.
- field AuthenticateOidcConfig: AuthenticateOidcActionConfig | None = None
[HTTPS listeners] Information about an identity provider that is compliant with OpenID Connect (OIDC).
Specify only when
Typeisauthenticate-oidc.
- field FixedResponseConfig: FixedResponseActionConfig | None = None
[Application Load Balancer] Information for creating an action that returns a custom HTTP response.
Specify only when
Typeisfixed-response.
- field ForwardConfig: ForwardActionConfig | None = None
Information for creating an action that distributes requests among multiple target groups.
Specify only when
Typeisforward.
- field JwtValidationConfig: JwtValidationActionConfig | None = None
[HTTPS listeners] Information for validating JWT access tokens in client requests.
Specify only when
Typeisjwt- validation.
- field Order: int | None = None
The order for the action.
This value is required for rules with multiple actions. The action with the lowest value for order is performed first.
- field RedirectConfig: RedirectActionConfig | None = None
[Application Load Balancer] Information for creating a redirect action.
Specify only when
Typeisredirect.
- field TargetGroupArn: str | None = None
The Amazon Resource Name (ARN) of the target group.
Specify only when
Typeisforwardand you want to route to a single target group. To route to multiple target groups, you must useForwardConfiginstead.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.AuthenticateCognitoActionConfig[source]
Bases:
Boto3ModelRequest parameters to use when integrating with Amazon Cognito to authenticate users.
Show JSON schema
{ "title": "AuthenticateCognitoActionConfig", "description": "Request parameters to use when integrating with Amazon Cognito to authenticate\nusers.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "UserPoolArn": { "title": "Userpoolarn", "type": "string" }, "UserPoolClientId": { "title": "Userpoolclientid", "type": "string" }, "UserPoolDomain": { "title": "Userpooldomain", "type": "string" }, "SessionCookieName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Sessioncookiename" }, "Scope": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Scope" }, "SessionTimeout": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Sessiontimeout" }, "AuthenticationRequestExtraParams": { "anyOf": [ { "additionalProperties": { "type": "string" }, "type": "object" }, { "type": "null" } ], "title": "Authenticationrequestextraparams" }, "OnUnauthenticatedRequest": { "anyOf": [ { "enum": [ "deny", "allow", "authenticate" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Onunauthenticatedrequest" } }, "required": [ "UserPoolArn", "UserPoolClientId", "UserPoolDomain" ] }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field AuthenticationRequestExtraParams: dict[str, str] | None [Optional]
The query parameters (up to 10) to include in the redirect request to the authorization endpoint.
- field OnUnauthenticatedRequest: Literal['deny', 'allow', 'authenticate'] | None = None
The behavior if the user is not authenticated.
The following are possible values:
- field Scope: str | None = None
The set of user claims to be requested from the IdP.
The default is
openid.
- field SessionCookieName: str | None = None
The name of the cookie used to maintain session information.
The default is AWSELBAuthSessionCookie.
- field SessionTimeout: int | None = None
The maximum duration of the authentication session, in seconds.
The default is 604800 seconds (7 days).
- field UserPoolDomain: str [Required]
The domain prefix or fully-qualified domain name of the Amazon Cognito user pool.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.AuthenticateOidcActionConfig[source]
Bases:
Boto3ModelRequest parameters when using an identity provider (IdP) that is compliant with OpenID Connect (OIDC) to authenticate users.
Show JSON schema
{ "title": "AuthenticateOidcActionConfig", "description": "Request parameters when using an identity provider (IdP) that is compliant with\nOpenID Connect (OIDC) to authenticate users.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Issuer": { "title": "Issuer", "type": "string" }, "AuthorizationEndpoint": { "title": "Authorizationendpoint", "type": "string" }, "TokenEndpoint": { "title": "Tokenendpoint", "type": "string" }, "UserInfoEndpoint": { "title": "Userinfoendpoint", "type": "string" }, "ClientId": { "title": "Clientid", "type": "string" }, "ClientSecret": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Clientsecret" }, "SessionCookieName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Sessioncookiename" }, "Scope": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Scope" }, "SessionTimeout": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Sessiontimeout" }, "AuthenticationRequestExtraParams": { "anyOf": [ { "additionalProperties": { "type": "string" }, "type": "object" }, { "type": "null" } ], "title": "Authenticationrequestextraparams" }, "OnUnauthenticatedRequest": { "anyOf": [ { "enum": [ "deny", "allow", "authenticate" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Onunauthenticatedrequest" }, "UseExistingClientSecret": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Useexistingclientsecret" } }, "required": [ "Issuer", "AuthorizationEndpoint", "TokenEndpoint", "UserInfoEndpoint", "ClientId" ] }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field AuthenticationRequestExtraParams: dict[str, str] | None [Optional]
The query parameters (up to 10) to include in the redirect request to the authorization endpoint.
- field AuthorizationEndpoint: str [Required]
The authorization endpoint of the IdP.
This must be a full URL, including the HTTPS protocol, the domain, and the path.
- field ClientSecret: str | None = None
The OAuth 2.0 client secret.
This parameter is required if you are creating a rule. If you are modifying a rule, you can omit this parameter if you set
UseExistingClientSecretto true.
- field Issuer: str [Required]
The OIDC issuer identifier of the IdP.
This must be a full URL, including the HTTPS protocol, the domain, and the path.
- field OnUnauthenticatedRequest: Literal['deny', 'allow', 'authenticate'] | None = None
The behavior if the user is not authenticated.
The following are possible values:
- field Scope: str | None = None
The set of user claims to be requested from the IdP.
The default is
openid.
- field SessionCookieName: str | None = None
The name of the cookie used to maintain session information.
The default is AWSELBAuthSessionCookie.
- field SessionTimeout: int | None = None
The maximum duration of the authentication session, in seconds.
The default is 604800 seconds (7 days).
- field TokenEndpoint: str [Required]
The token endpoint of the IdP.
This must be a full URL, including the HTTPS protocol, the domain, and the path.
- field UseExistingClientSecret: bool | None = None
Indicates whether to use the existing client secret when modifying a rule.
If you are creating a rule, you can omit this parameter or set it to false.
- field UserInfoEndpoint: str [Required]
The user info endpoint of the IdP.
This must be a full URL, including the HTTPS protocol, the domain, and the path.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.AvailabilityZone[source]
Bases:
Boto3ModelInformation about an Availability Zone.
Show JSON schema
{ "title": "AvailabilityZone", "description": "Information about an Availability Zone.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "ZoneName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Zonename" }, "SubnetId": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Subnetid" }, "OutpostId": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Outpostid" }, "LoadBalancerAddresses": { "anyOf": [ { "items": { "$ref": "#/$defs/LoadBalancerAddress" }, "type": "array" }, { "type": "null" } ], "title": "Loadbalanceraddresses" }, "SourceNatIpv6Prefixes": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Sourcenatipv6Prefixes" } }, "$defs": { "LoadBalancerAddress": { "description": "Information about a static IP address for a load balancer.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "IpAddress": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Ipaddress" }, "AllocationId": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Allocationid" }, "PrivateIPv4Address": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Privateipv4Address" }, "IPv6Address": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Ipv6Address" } }, "title": "LoadBalancerAddress", "type": "object" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field LoadBalancerAddresses: builtins.list[LoadBalancerAddress] | None [Optional]
[Network Load Balancers] If you need static IP addresses for your load balancer, you can specify one Elastic IP address per Availability Zone when you create an internal-facing load balancer.
For internal load balancers, you can specify a private IP address from the IPv4 range of the subnet.
- field SourceNatIpv6Prefixes: builtins.list[str] | None [Optional]
[Network Load Balancers with UDP listeners] The IPv6 prefixes to use for source NAT.
For each subnet, specify an IPv6 prefix (/80 netmask) from the subnet CIDR block or
auto_assignedto use an IPv6 prefix selected at random from the subnet CIDR block.
- field SubnetId: str | None = None
The ID of the subnet.
You can specify one subnet per Availability Zone.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.Certificate[source]
Bases:
ReadonlyBoto3ModelInformation about an SSL server certificate.
Show JSON schema
{ "title": "Certificate", "description": "Information about an SSL server certificate.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "CertificateArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Certificatearn" }, "IsDefault": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Isdefault" } }, "additionalProperties": true }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
frozen: bool = True
extra: str = allow
- Fields:
- field IsDefault: bool | None = None
Indicates whether the certificate is the default certificate.
Do not set this value when specifying a certificate as an input. This value is not included in the output when describing a listener, but is included when describing listener certificates.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.ElbV2HostHeaderRewriteConfig[source]
Bases:
Boto3ModelInformation about a host header rewrite transform.
This transform matches a pattern in the host header in an HTTP request and replaces it with the specified string.
Show JSON schema
{ "title": "ElbV2HostHeaderRewriteConfig", "description": "Information about a host header rewrite transform.\n\nThis transform matches a pattern in the host header in an HTTP request and replaces\nit with the specified string.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Rewrites": { "anyOf": [ { "items": { "$ref": "#/$defs/RewriteConfig" }, "type": "array" }, { "type": "null" } ], "title": "Rewrites" } }, "$defs": { "RewriteConfig": { "description": "Information about a rewrite transform.\n\nThis transform matches a pattern and replaces it with the specified string.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Regex": { "title": "Regex", "type": "string" }, "Replace": { "title": "Replace", "type": "string" } }, "required": [ "Regex", "Replace" ], "title": "RewriteConfig", "type": "object" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field Rewrites: builtins.list[RewriteConfig] | None [Optional]
The host header rewrite transform.
Each transform consists of a regular expression to match and a replacement string.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.ElbV2IpamPools[source]
Bases:
Boto3ModelAn IPAM pool is a collection of IP address CIDRs.
IPAM pools enable you to organize your IP addresses according to your routing and security needs.
Show JSON schema
{ "title": "ElbV2IpamPools", "description": "An IPAM pool is a collection of IP address CIDRs.\n\nIPAM pools enable you to organize your IP addresses according to your routing and\nsecurity needs.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Ipv4IpamPoolId": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Ipv4Ipampoolid" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.ElbV2TargetGroupStickinessConfig[source]
Bases:
Boto3ModelInformation about the target group stickiness for a rule.
Show JSON schema
{ "title": "ElbV2TargetGroupStickinessConfig", "description": "Information about the target group stickiness for a rule.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Enabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Enabled" }, "DurationSeconds": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Durationseconds" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field DurationSeconds: int | None = None
[Application Load Balancers] The time period, in seconds, during which requests from a client should be routed to the same target group.
The range is 1-604800 seconds (7 days). You must specify this value when enabling target group stickiness.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.ElbV2UrlRewriteConfig[source]
Bases:
Boto3ModelInformation about a URL rewrite transform.
This transform matches a pattern in the request URL and replaces it with the specified string.
Show JSON schema
{ "title": "ElbV2UrlRewriteConfig", "description": "Information about a URL rewrite transform.\n\nThis transform matches a pattern in the request URL and replaces it with the\nspecified string.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Rewrites": { "anyOf": [ { "items": { "$ref": "#/$defs/RewriteConfig" }, "type": "array" }, { "type": "null" } ], "title": "Rewrites" } }, "$defs": { "RewriteConfig": { "description": "Information about a rewrite transform.\n\nThis transform matches a pattern and replaces it with the specified string.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Regex": { "title": "Regex", "type": "string" }, "Replace": { "title": "Replace", "type": "string" } }, "required": [ "Regex", "Replace" ], "title": "RewriteConfig", "type": "object" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field Rewrites: builtins.list[RewriteConfig] | None [Optional]
The URL rewrite transform to apply to the request.
The transform consists of a regular expression to match and a replacement string.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.FixedResponseActionConfig[source]
Bases:
Boto3ModelInformation about an action that returns a custom HTTP response.
Show JSON schema
{ "title": "FixedResponseActionConfig", "description": "Information about an action that returns a custom HTTP response.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "MessageBody": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Messagebody" }, "StatusCode": { "title": "Statuscode", "type": "string" }, "ContentType": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Contenttype" } }, "required": [ "StatusCode" ] }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.ForwardActionConfig[source]
Bases:
Boto3ModelInformation about a forward action.
Show JSON schema
{ "title": "ForwardActionConfig", "description": "Information about a forward action.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroups": { "anyOf": [ { "items": { "$ref": "#/$defs/TargetGroupTuple" }, "type": "array" }, { "type": "null" } ], "title": "Targetgroups" }, "TargetGroupStickinessConfig": { "anyOf": [ { "$ref": "#/$defs/ElbV2TargetGroupStickinessConfig" }, { "type": "null" } ], "default": null } }, "$defs": { "ElbV2TargetGroupStickinessConfig": { "description": "Information about the target group stickiness for a rule.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Enabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Enabled" }, "DurationSeconds": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Durationseconds" } }, "title": "ElbV2TargetGroupStickinessConfig", "type": "object" }, "TargetGroupTuple": { "description": "Information about how traffic will be distributed between multiple target groups in\na forward rule.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroupArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Targetgrouparn" }, "Weight": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Weight" } }, "title": "TargetGroupTuple", "type": "object" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field TargetGroupStickinessConfig: ElbV2TargetGroupStickinessConfig | None = None
The target group stickiness for the rule.
- field TargetGroups: builtins.list[TargetGroupTuple] | None [Optional]
The target groups.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.HostHeaderConditionConfig[source]
Bases:
Boto3ModelInformation about a host header condition.
Show JSON schema
{ "title": "HostHeaderConditionConfig", "description": "Information about a host header condition.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" }, "RegexValues": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Regexvalues" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field RegexValues: builtins.list[str] | None [Optional]
The regular expressions to compare against the host header.
The maximum length of each string is 128 characters.
- field Values: builtins.list[str] | None [Optional]
The host names.
The maximum length of each string is 128 characters. The comparison is case insensitive. The following wildcard characters are supported: * (matches 0 or more characters) and ? (matches exactly 1 character). You must include at least one “.” character. You can include only alphabetical characters after the final “.” character.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.HttpHeaderConditionConfig[source]
Bases:
Boto3ModelInformation about an HTTP header condition.
There is a set of standard HTTP header fields. You can also define custom HTTP header fields.
Show JSON schema
{ "title": "HttpHeaderConditionConfig", "description": "Information about an HTTP header condition.\n\nThere is a set of standard HTTP header fields. You can also define custom HTTP\nheader fields.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "HttpHeaderName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Httpheadername" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" }, "RegexValues": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Regexvalues" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field HttpHeaderName: str | None = None
The name of the HTTP header field.
The maximum length is 40 characters. The header name is case insensitive. The allowed characters are specified by RFC 7230. Wildcards are not supported.
- field RegexValues: builtins.list[str] | None [Optional]
The regular expression to compare against the HTTP header.
The maximum length of each string is 128 characters.
- field Values: builtins.list[str] | None [Optional]
The strings to compare against the value of the HTTP header.
The maximum length of each string is 128 characters. The comparison strings are case insensitive. The following wildcard characters are supported: * (matches 0 or more characters) and ? (matches exactly 1 character).
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.HttpRequestMethodConditionConfig[source]
Bases:
Boto3ModelInformation about an HTTP method condition.
HTTP defines a set of request methods, also referred to as HTTP verbs. For more information, see the HTTP Method Registry. You can also define custom HTTP methods.
Show JSON schema
{ "title": "HttpRequestMethodConditionConfig", "description": "Information about an HTTP method condition.\n\nHTTP defines a set of request methods, also referred to as HTTP verbs. For more\ninformation, see the\n`HTTP Method Registry <https://www.iana.org/assignments/http-methods/http-methods.xhtml>`_.\nYou can also define custom HTTP methods.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field Values: builtins.list[str] | None [Optional]
The name of the request method.
The maximum length is 40 characters. The allowed characters are A-Z, hyphen (-), and underscore (_). The comparison is case sensitive. Wildcards are not supported; therefore, the method name must be an exact match.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.JwtValidationActionAdditionalClaim[source]
Bases:
Boto3ModelInformation about an additional claim to validate.
Show JSON schema
{ "title": "JwtValidationActionAdditionalClaim", "description": "Information about an additional claim to validate.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Format": { "enum": [ "single-string", "string-array", "space-separated-values" ], "title": "Format", "type": "string" }, "Name": { "title": "Name", "type": "string" }, "Values": { "items": { "type": "string" }, "title": "Values", "type": "array" } }, "required": [ "Format", "Name", "Values" ] }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field Format: Literal['single-string', 'string-array', 'space-separated-values'] [Required]
The format of the claim value.
- field Name: str [Required]
The name of the claim.
You can’t specify
exp,iss,nbf, oriatbecause we validate them by default.
- field Values: builtins.list[str] [Required]
The claim value.
The maximum size of the list is 10. Each value can be up to 256 characters in length. If the format is
space-separated-values, the values can’t include spaces.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.JwtValidationActionConfig[source]
Bases:
Boto3ModelInformation about a JSON Web Token (JWT) validation action.
Show JSON schema
{ "title": "JwtValidationActionConfig", "description": "Information about a JSON Web Token (JWT) validation action.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "JwksEndpoint": { "title": "Jwksendpoint", "type": "string" }, "Issuer": { "title": "Issuer", "type": "string" }, "AdditionalClaims": { "anyOf": [ { "items": { "$ref": "#/$defs/JwtValidationActionAdditionalClaim" }, "type": "array" }, { "type": "null" } ], "title": "Additionalclaims" } }, "$defs": { "JwtValidationActionAdditionalClaim": { "description": "Information about an additional claim to validate.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Format": { "enum": [ "single-string", "string-array", "space-separated-values" ], "title": "Format", "type": "string" }, "Name": { "title": "Name", "type": "string" }, "Values": { "items": { "type": "string" }, "title": "Values", "type": "array" } }, "required": [ "Format", "Name", "Values" ], "title": "JwtValidationActionAdditionalClaim", "type": "object" } }, "required": [ "JwksEndpoint", "Issuer" ] }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field AdditionalClaims: builtins.list[JwtValidationActionAdditionalClaim] | None [Optional]
Additional claims to validate.
The maximum size of the list is 10. We validate the
exp,iss,nbf, andiatclaims by default.
- field JwksEndpoint: str [Required]
The JSON Web Key Set (JWKS) endpoint.
This endpoint contains JSON Web Keys (JWK) that are used to validate signatures from the provider.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.LoadBalancerAddress[source]
Bases:
Boto3ModelInformation about a static IP address for a load balancer.
Show JSON schema
{ "title": "LoadBalancerAddress", "description": "Information about a static IP address for a load balancer.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "IpAddress": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Ipaddress" }, "AllocationId": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Allocationid" }, "PrivateIPv4Address": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Privateipv4Address" }, "IPv6Address": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Ipv6Address" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field AllocationId: str | None = None
[Network Load Balancers] The allocation ID of the Elastic IP address for an internal-facing load balancer.
- field PrivateIPv4Address: str | None = None
[Network Load Balancers] The private IPv4 address for an internal load balancer.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.LoadBalancerState[source]
Bases:
Boto3ModelInformation about the state of the load balancer.
Show JSON schema
{ "title": "LoadBalancerState", "description": "Information about the state of the load balancer.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Code": { "anyOf": [ { "enum": [ "active", "provisioning", "active_impaired", "failed" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Code" }, "Reason": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Reason" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field Code: Literal['active', 'provisioning', 'active_impaired', 'failed'] | None = None
The state code.
The initial state of the load balancer is
provisioning. After the load balancer is fully set up and ready to route traffic, its state isactive. If load balancer is routing traffic but does not have the resources it needs to scale, its state is``active_impaired``. If the load balancer could not be set up, its state isfailed.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.MutualAuthenticationAttributes[source]
Bases:
Boto3ModelInformation about the mutual authentication attributes of a listener.
Show JSON schema
{ "title": "MutualAuthenticationAttributes", "description": "Information about the mutual authentication attributes of a listener.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Mode": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Mode" }, "TrustStoreArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Truststorearn" }, "IgnoreClientCertificateExpiry": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Ignoreclientcertificateexpiry" }, "TrustStoreAssociationStatus": { "anyOf": [ { "enum": [ "active", "removed" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Truststoreassociationstatus" }, "AdvertiseTrustStoreCaNames": { "anyOf": [ { "enum": [ "on", "off" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Advertisetruststorecanames" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field AdvertiseTrustStoreCaNames: Literal['on', 'off'] | None = None
Indicates whether trust store CA certificate names are advertised.
- field IgnoreClientCertificateExpiry: bool | None = None
Indicates whether expired client certificates are ignored.
- field Mode: str | None = None
The client certificate handling method.
Options are
off,passthroughorverify. The default value isoff.
- field TrustStoreAssociationStatus: Literal['active', 'removed'] | None = None
Indicates a shared trust stores association status.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.PathPatternConditionConfig[source]
Bases:
Boto3ModelInformation about a path pattern condition.
Show JSON schema
{ "title": "PathPatternConditionConfig", "description": "Information about a path pattern condition.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" }, "RegexValues": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Regexvalues" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field RegexValues: builtins.list[str] | None [Optional]
The regular expressions to compare against the request URL.
The maximum length of each string is 128 characters.
- field Values: builtins.list[str] | None [Optional]
The path patterns to compare against the request URL.
The maximum length of each string is 128 characters. The comparison is case sensitive. The following wildcard characters are supported: * (matches 0 or more characters) and ? (matches exactly 1 character).
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.QueryStringConditionConfig[source]
Bases:
Boto3ModelInformation about a query string condition.
The query string component of a URI starts after the first ‘?’ character and is terminated by either a ‘#’ character or the end of the URI. A typical query string contains key/value pairs separated by ‘&’ characters. The allowed characters are specified by RFC 3986. Any character can be percentage encoded.
Show JSON schema
{ "title": "QueryStringConditionConfig", "description": "Information about a query string condition.\n\nThe query string component of a URI starts after the first '?' character and is\nterminated by either a '#' character or the end of the URI. A typical query string\ncontains key/value pairs separated by '&' characters. The allowed characters are\nspecified by RFC 3986. Any character can be percentage encoded.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "$ref": "#/$defs/QueryStringKeyValuePair" }, "type": "array" }, { "type": "null" } ], "title": "Values" } }, "$defs": { "QueryStringKeyValuePair": { "description": "Information about a key/value pair.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Key": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Key" }, "Value": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Value" } }, "title": "QueryStringKeyValuePair", "type": "object" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field Values: builtins.list[QueryStringKeyValuePair] | None [Optional]
The key/value pairs or values to find in the query string.
The maximum length of each string is 128 characters. The comparison is case insensitive. The following wildcard characters are supported: * (matches 0 or more characters) and ? (matches exactly 1 character). To search for a literal ‘*’ or ‘?’ character in a query string, you must escape these characters in
Valuesusing a ‘’ character.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.QueryStringKeyValuePair[source]
Bases:
Boto3ModelInformation about a key/value pair.
Show JSON schema
{ "title": "QueryStringKeyValuePair", "description": "Information about a key/value pair.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Key": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Key" }, "Value": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Value" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.RedirectActionConfig[source]
Bases:
Boto3ModelInformation about a redirect action.
A URI consists of the following components: protocol://hostname:port/path?query. You must modify at least one of the following components to avoid a redirect loop: protocol, hostname, port, or path. Any components that you do not modify retain their original values.
You can reuse URI components using the following reserved keywords:
#{protocol}
#{host}
#{port}
#{path} (the leading “/” is removed)
#{query}
For example, you can change the path to “/new/#{path}”, the hostname to “example.#{host}”, or the query to “#{query}&value=xyz”.
Show JSON schema
{ "title": "RedirectActionConfig", "description": "Information about a redirect action.\n\nA URI consists of the following components: protocol://hostname:port/path?query. You must modify at least one of the\nfollowing components to avoid a redirect loop: protocol, hostname, port, or path. Any components that you do not modify\nretain their original values.\n\nYou can reuse URI components using the following reserved keywords:\n\n* #{protocol}\n* #{host}\n* #{port}\n* #{path} (the leading \"/\" is removed)\n* #{query}\n\nFor example, you can change the path to \"/new/#{path}\", the hostname to \"example.#{host}\", or the query to\n\"#{query}&value=xyz\".", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Protocol": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Protocol" }, "Port": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Port" }, "Host": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Host" }, "Path": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Path" }, "Query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Query" }, "StatusCode": { "enum": [ "HTTP_301", "HTTP_302" ], "title": "Statuscode", "type": "string" } }, "required": [ "StatusCode" ] }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field Host: str | None = None
The hostname.
This component is not percent-encoded. The hostname can contain #{host}.
- field Path: str | None = None
The absolute path, starting with the leading “/”.
This component is not percent-encoded. The path can contain #{host}, #{path}, and #{port}.
- field Protocol: str | None = None
The protocol.
You can specify HTTP, HTTPS, or #{protocol}. You can redirect HTTP to HTTP, HTTP to HTTPS, and HTTPS to HTTPS. You can’t redirect HTTPS to HTTP.
- field Query: str | None = None
The query parameters, URL-encoded when necessary, but not percent-encoded.
Do not include the leading “?”, as it is automatically added. You can specify any of the reserved keywords.
- field StatusCode: Literal['HTTP_301', 'HTTP_302'] [Required]
The HTTP redirect code.
The redirect is either permanent (HTTP 301) or temporary (HTTP 302).
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.ResponseCodeMatcher[source]
Bases:
Boto3ModelThe codes to use when checking for a successful response from a target.
If the protocol version is gRPC, these are gRPC codes. Otherwise, these are HTTP codes.
Show JSON schema
{ "title": "ResponseCodeMatcher", "description": "The codes to use when checking for a successful response from a target.\n\nIf the protocol version is gRPC, these are gRPC codes. Otherwise, these are HTTP\ncodes.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "HttpCode": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Httpcode" }, "GrpcCode": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Grpccode" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field GrpcCode: str | None = None
You can specify values between 0 and 99.
You can specify multiple values (for example, “0,1”) or a range of values (for example, “0-5”). The default value is 12.
- field HttpCode: str | None = None
For Application Load Balancers, you can specify values between 200 and 499, with the default value being 200.
You can specify multiple values (for example, “200,202”) or a range of values (for example, “200-299”).
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.RewriteConfig[source]
Bases:
Boto3ModelInformation about a rewrite transform.
This transform matches a pattern and replaces it with the specified string.
Show JSON schema
{ "title": "RewriteConfig", "description": "Information about a rewrite transform.\n\nThis transform matches a pattern and replaces it with the specified string.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Regex": { "title": "Regex", "type": "string" }, "Replace": { "title": "Replace", "type": "string" } }, "required": [ "Regex", "Replace" ] }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field Regex: str [Required]
The regular expression to match in the input string.
The maximum length of the string is 1,024 characters.
- field Replace: str [Required]
The replacement string to use when rewriting the matched input.
The maximum length of the string is 1,024 characters. You can specify capture groups in the regular expression (for example, $1 and $2).
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.RuleCondition[source]
Bases:
Boto3ModelInformation about a condition for a rule.
Each rule can optionally include up to one of each of the following conditions:
http-request-method,host- header,path-pattern, andsource-ip. Each rule can also optionally include one or more of each of the following conditions:http-headerandquery-string. Note that the value for a condition can’t be empty.For more information, see Quotas for your Application Load Balancers.
Show JSON schema
{ "title": "RuleCondition", "description": "Information about a condition for a rule.\n\nEach rule can optionally include up to one of each of the following conditions: ``http-request-method``, ``host-\nheader``, ``path-pattern``, and ``source-ip``. Each rule can also optionally include one or more of each of the\nfollowing conditions: ``http-header`` and ``query-string``. Note that the value for a condition can't be empty.\n\nFor more information, see `Quotas for your Application Load\nBalancers <https://docs.aws.amazon.com/elasticloadbalancing/latest/application/load-balancer-limits.html>`_.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Field": { "default": null, "title": "Field", "type": "string" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" }, "HostHeaderConfig": { "anyOf": [ { "$ref": "#/$defs/HostHeaderConditionConfig" }, { "type": "null" } ], "default": null }, "PathPatternConfig": { "anyOf": [ { "$ref": "#/$defs/PathPatternConditionConfig" }, { "type": "null" } ], "default": null }, "HttpHeaderConfig": { "anyOf": [ { "$ref": "#/$defs/HttpHeaderConditionConfig" }, { "type": "null" } ], "default": null }, "QueryStringConfig": { "anyOf": [ { "$ref": "#/$defs/QueryStringConditionConfig" }, { "type": "null" } ], "default": null }, "HttpRequestMethodConfig": { "anyOf": [ { "$ref": "#/$defs/HttpRequestMethodConditionConfig" }, { "type": "null" } ], "default": null }, "SourceIpConfig": { "anyOf": [ { "$ref": "#/$defs/SourceIpConditionConfig" }, { "type": "null" } ], "default": null }, "RegexValues": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Regexvalues" } }, "$defs": { "HostHeaderConditionConfig": { "description": "Information about a host header condition.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" }, "RegexValues": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Regexvalues" } }, "title": "HostHeaderConditionConfig", "type": "object" }, "HttpHeaderConditionConfig": { "description": "Information about an HTTP header condition.\n\nThere is a set of standard HTTP header fields. You can also define custom HTTP\nheader fields.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "HttpHeaderName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Httpheadername" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" }, "RegexValues": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Regexvalues" } }, "title": "HttpHeaderConditionConfig", "type": "object" }, "HttpRequestMethodConditionConfig": { "description": "Information about an HTTP method condition.\n\nHTTP defines a set of request methods, also referred to as HTTP verbs. For more\ninformation, see the\n`HTTP Method Registry <https://www.iana.org/assignments/http-methods/http-methods.xhtml>`_.\nYou can also define custom HTTP methods.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" } }, "title": "HttpRequestMethodConditionConfig", "type": "object" }, "PathPatternConditionConfig": { "description": "Information about a path pattern condition.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" }, "RegexValues": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Regexvalues" } }, "title": "PathPatternConditionConfig", "type": "object" }, "QueryStringConditionConfig": { "description": "Information about a query string condition.\n\nThe query string component of a URI starts after the first '?' character and is\nterminated by either a '#' character or the end of the URI. A typical query string\ncontains key/value pairs separated by '&' characters. The allowed characters are\nspecified by RFC 3986. Any character can be percentage encoded.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "$ref": "#/$defs/QueryStringKeyValuePair" }, "type": "array" }, { "type": "null" } ], "title": "Values" } }, "title": "QueryStringConditionConfig", "type": "object" }, "QueryStringKeyValuePair": { "description": "Information about a key/value pair.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Key": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Key" }, "Value": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Value" } }, "title": "QueryStringKeyValuePair", "type": "object" }, "SourceIpConditionConfig": { "description": "Information about a source IP condition.\n\nYou can use this condition to route based on the IP address of the source that\nconnects to the load balancer. If a client is behind a proxy, this is the IP address\nof the proxy not the IP address of the client.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" } }, "title": "SourceIpConditionConfig", "type": "object" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
HostHeaderConfig (botocraft.services.elbv2.HostHeaderConditionConfig | None)HttpHeaderConfig (botocraft.services.elbv2.HttpHeaderConditionConfig | None)HttpRequestMethodConfig (botocraft.services.elbv2.HttpRequestMethodConditionConfig | None)PathPatternConfig (botocraft.services.elbv2.PathPatternConditionConfig | None)QueryStringConfig (botocraft.services.elbv2.QueryStringConditionConfig | None)SourceIpConfig (botocraft.services.elbv2.SourceIpConditionConfig | None)
- field FieldName: str = None (alias 'Field')
The field in the HTTP request.
The following are the possible values:
- field HostHeaderConfig: HostHeaderConditionConfig | None = None
Information for a host header condition.
Specify only when
Fieldishost-header.
- field HttpHeaderConfig: HttpHeaderConditionConfig | None = None
Information for an HTTP header condition.
Specify only when
Fieldishttp-header.
- field HttpRequestMethodConfig: HttpRequestMethodConditionConfig | None = None
Information for an HTTP method condition.
Specify only when
Fieldishttp-request-method.
- field PathPatternConfig: PathPatternConditionConfig | None = None
Information for a path pattern condition.
Specify only when
Fieldispath-pattern.
- field QueryStringConfig: QueryStringConditionConfig | None = None
Information for a query string condition.
Specify only when
Fieldisquery-string.
- field RegexValues: builtins.list[str] | None [Optional]
The regular expressions to match against the condition field.
The maximum length of each string is 128 characters. Specify only when
Fieldishttp-header,host-header, orpath-pattern.
- field SourceIpConfig: SourceIpConditionConfig | None = None
Information for a source IP condition.
Specify only when
Fieldissource-ip.
- field Values: builtins.list[str] | None [Optional]
The condition value.
Specify only when
Fieldishost-headerorpath-pattern. Alternatively, to specify multiple host names or multiple path patterns, useHostHeaderConfigorPathPatternConfig.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.RuleTransform[source]
Bases:
Boto3ModelInformation about a transform to apply to requests that match a rule.
Transforms are applied to requests before they are sent to targets.
Show JSON schema
{ "title": "RuleTransform", "description": "Information about a transform to apply to requests that match a rule.\n\nTransforms are applied to requests before they are sent to targets.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Type": { "enum": [ "host-header-rewrite", "url-rewrite" ], "title": "Type", "type": "string" }, "HostHeaderRewriteConfig": { "anyOf": [ { "$ref": "#/$defs/ElbV2HostHeaderRewriteConfig" }, { "type": "null" } ], "default": null }, "UrlRewriteConfig": { "anyOf": [ { "$ref": "#/$defs/ElbV2UrlRewriteConfig" }, { "type": "null" } ], "default": null } }, "$defs": { "ElbV2HostHeaderRewriteConfig": { "description": "Information about a host header rewrite transform.\n\nThis transform matches a pattern in the host header in an HTTP request and replaces\nit with the specified string.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Rewrites": { "anyOf": [ { "items": { "$ref": "#/$defs/RewriteConfig" }, "type": "array" }, { "type": "null" } ], "title": "Rewrites" } }, "title": "ElbV2HostHeaderRewriteConfig", "type": "object" }, "ElbV2UrlRewriteConfig": { "description": "Information about a URL rewrite transform.\n\nThis transform matches a pattern in the request URL and replaces it with the\nspecified string.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Rewrites": { "anyOf": [ { "items": { "$ref": "#/$defs/RewriteConfig" }, "type": "array" }, { "type": "null" } ], "title": "Rewrites" } }, "title": "ElbV2UrlRewriteConfig", "type": "object" }, "RewriteConfig": { "description": "Information about a rewrite transform.\n\nThis transform matches a pattern and replaces it with the specified string.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Regex": { "title": "Regex", "type": "string" }, "Replace": { "title": "Replace", "type": "string" } }, "required": [ "Regex", "Replace" ], "title": "RewriteConfig", "type": "object" } }, "required": [ "Type" ] }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field HostHeaderRewriteConfig: ElbV2HostHeaderRewriteConfig | None = None
Information about a host header rewrite transform.
This transform modifies the host header in an HTTP request. Specify only when
Typeishost-header-rewrite.
- field UrlRewriteConfig: ElbV2UrlRewriteConfig | None = None
Information about a URL rewrite transform.
This transform modifies the request URL. Specify only when
Typeisurl- rewrite.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.SourceIpConditionConfig[source]
Bases:
Boto3ModelInformation about a source IP condition.
You can use this condition to route based on the IP address of the source that connects to the load balancer. If a client is behind a proxy, this is the IP address of the proxy not the IP address of the client.
Show JSON schema
{ "title": "SourceIpConditionConfig", "description": "Information about a source IP condition.\n\nYou can use this condition to route based on the IP address of the source that\nconnects to the load balancer. If a client is behind a proxy, this is the IP address\nof the proxy not the IP address of the client.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field Values: builtins.list[str] | None [Optional]
The source IP addresses, in CIDR format.
You can use both IPv4 and IPv6 addresses. Wildcards are not supported.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.TargetDescription[source]
Bases:
Boto3ModelInformation about a target.
Show JSON schema
{ "title": "TargetDescription", "description": "Information about a target.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Id": { "title": "Id", "type": "string" }, "Port": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Port" }, "AvailabilityZone": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Availabilityzone" }, "QuicServerId": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Quicserverid" } }, "required": [ "Id" ] }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field AvailabilityZone: str | None = None
An Availability Zone or
all.This determines whether the target receives traffic from the load balancer nodes in the specified Availability Zone or from all enabled Availability Zones for the load balancer.
- field Id: str [Required]
The ID of the target.
If the target type of the target group is
instance, specify an instance ID. If the target type isip, specify an IP address. If the target type islambda, specify the ARN of the Lambda function. If the target type isalb, specify the ARN of the Application Load Balancer target.
- field Port: int | None = None
The port on which the target is listening.
If the target group protocol is GENEVE, the supported port is 6081. If the target type is
alb, the targeted Application Load Balancer must have at least one listener whose port matches the target group port. This parameter is not used if the target is a Lambda function.
- field QuicServerId: str | None = None
The server ID for the targets.
This value is required if the protocol is
QUICorTCP_QUICand can’t be used with other protocols.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.TargetGroupTuple[source]
Bases:
Boto3ModelInformation about how traffic will be distributed between multiple target groups in a forward rule.
Show JSON schema
{ "title": "TargetGroupTuple", "description": "Information about how traffic will be distributed between multiple target groups in\na forward rule.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroupArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Targetgrouparn" }, "Weight": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Weight" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
Request/Response Models
Request/response models are models that are used to describe the structure of the data that is sent to and received from the AWS service. They are used by the managers to send requests to the service and to parse the responses that are received.
You will not often use them directly – typically they are used by the managers internally to send requests and parse responses – but they are included here for completeness, and because occasionally we return them directly to you because they have some useful additional information.
- pydantic model botocraft.services.elbv2.AnomalyDetectionInfo[source]
Bases:
Boto3ModelInformation about anomaly detection and mitigation.
Show JSON schema
{ "title": "AnomalyDetectionInfo", "description": "Information about anomaly detection and mitigation.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Result": { "anyOf": [ { "enum": [ "anomalous", "normal" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Result" }, "MitigationInEffect": { "anyOf": [ { "enum": [ "yes", "no" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Mitigationineffect" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field MitigationInEffect: Literal['yes', 'no'] | None = None
Indicates whether anomaly mitigation is in progress.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.CreateListenerOutput[source]
Bases:
Boto3ModelShow JSON schema
{ "title": "CreateListenerOutput", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Listeners": { "anyOf": [ { "items": { "$ref": "#/$defs/Listener" }, "type": "array" }, { "type": "null" } ], "title": "Listeners" } }, "$defs": { "Action": { "description": "Information about an action.\n\nEach rule must include exactly one of the following routing actions: ``forward``, ``fixed-response``, or ``redirect``,\nand it must be the last action to be performed.\n\nOptionally, a rule for an HTTPS listener can also include one of the following user authentication actions:\n``authenticate-oidc``, ``authenticate-cognito``, or ``jwt-validation``.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Type": { "default": null, "enum": [ "forward", "authenticate-oidc", "authenticate-cognito", "redirect", "fixed-response", "jwt-validation" ], "title": "Type", "type": "string" }, "TargetGroupArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Targetgrouparn" }, "AuthenticateOidcConfig": { "anyOf": [ { "$ref": "#/$defs/AuthenticateOidcActionConfig" }, { "type": "null" } ], "default": null }, "AuthenticateCognitoConfig": { "anyOf": [ { "$ref": "#/$defs/AuthenticateCognitoActionConfig" }, { "type": "null" } ], "default": null }, "Order": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Order" }, "RedirectConfig": { "anyOf": [ { "$ref": "#/$defs/RedirectActionConfig" }, { "type": "null" } ], "default": null }, "FixedResponseConfig": { "anyOf": [ { "$ref": "#/$defs/FixedResponseActionConfig" }, { "type": "null" } ], "default": null }, "ForwardConfig": { "anyOf": [ { "$ref": "#/$defs/ForwardActionConfig" }, { "type": "null" } ], "default": null }, "JwtValidationConfig": { "anyOf": [ { "$ref": "#/$defs/JwtValidationActionConfig" }, { "type": "null" } ], "default": null } }, "title": "Action", "type": "object" }, "AuthenticateCognitoActionConfig": { "description": "Request parameters to use when integrating with Amazon Cognito to authenticate\nusers.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "UserPoolArn": { "title": "Userpoolarn", "type": "string" }, "UserPoolClientId": { "title": "Userpoolclientid", "type": "string" }, "UserPoolDomain": { "title": "Userpooldomain", "type": "string" }, "SessionCookieName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Sessioncookiename" }, "Scope": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Scope" }, "SessionTimeout": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Sessiontimeout" }, "AuthenticationRequestExtraParams": { "anyOf": [ { "additionalProperties": { "type": "string" }, "type": "object" }, { "type": "null" } ], "title": "Authenticationrequestextraparams" }, "OnUnauthenticatedRequest": { "anyOf": [ { "enum": [ "deny", "allow", "authenticate" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Onunauthenticatedrequest" } }, "required": [ "UserPoolArn", "UserPoolClientId", "UserPoolDomain" ], "title": "AuthenticateCognitoActionConfig", "type": "object" }, "AuthenticateOidcActionConfig": { "description": "Request parameters when using an identity provider (IdP) that is compliant with\nOpenID Connect (OIDC) to authenticate users.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Issuer": { "title": "Issuer", "type": "string" }, "AuthorizationEndpoint": { "title": "Authorizationendpoint", "type": "string" }, "TokenEndpoint": { "title": "Tokenendpoint", "type": "string" }, "UserInfoEndpoint": { "title": "Userinfoendpoint", "type": "string" }, "ClientId": { "title": "Clientid", "type": "string" }, "ClientSecret": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Clientsecret" }, "SessionCookieName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Sessioncookiename" }, "Scope": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Scope" }, "SessionTimeout": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Sessiontimeout" }, "AuthenticationRequestExtraParams": { "anyOf": [ { "additionalProperties": { "type": "string" }, "type": "object" }, { "type": "null" } ], "title": "Authenticationrequestextraparams" }, "OnUnauthenticatedRequest": { "anyOf": [ { "enum": [ "deny", "allow", "authenticate" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Onunauthenticatedrequest" }, "UseExistingClientSecret": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Useexistingclientsecret" } }, "required": [ "Issuer", "AuthorizationEndpoint", "TokenEndpoint", "UserInfoEndpoint", "ClientId" ], "title": "AuthenticateOidcActionConfig", "type": "object" }, "Certificate": { "additionalProperties": true, "description": "Information about an SSL server certificate.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "CertificateArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Certificatearn" }, "IsDefault": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Isdefault" } }, "title": "Certificate", "type": "object" }, "ElbV2TargetGroupStickinessConfig": { "description": "Information about the target group stickiness for a rule.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Enabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Enabled" }, "DurationSeconds": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Durationseconds" } }, "title": "ElbV2TargetGroupStickinessConfig", "type": "object" }, "FixedResponseActionConfig": { "description": "Information about an action that returns a custom HTTP response.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "MessageBody": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Messagebody" }, "StatusCode": { "title": "Statuscode", "type": "string" }, "ContentType": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Contenttype" } }, "required": [ "StatusCode" ], "title": "FixedResponseActionConfig", "type": "object" }, "ForwardActionConfig": { "description": "Information about a forward action.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroups": { "anyOf": [ { "items": { "$ref": "#/$defs/TargetGroupTuple" }, "type": "array" }, { "type": "null" } ], "title": "Targetgroups" }, "TargetGroupStickinessConfig": { "anyOf": [ { "$ref": "#/$defs/ElbV2TargetGroupStickinessConfig" }, { "type": "null" } ], "default": null } }, "title": "ForwardActionConfig", "type": "object" }, "JwtValidationActionAdditionalClaim": { "description": "Information about an additional claim to validate.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Format": { "enum": [ "single-string", "string-array", "space-separated-values" ], "title": "Format", "type": "string" }, "Name": { "title": "Name", "type": "string" }, "Values": { "items": { "type": "string" }, "title": "Values", "type": "array" } }, "required": [ "Format", "Name", "Values" ], "title": "JwtValidationActionAdditionalClaim", "type": "object" }, "JwtValidationActionConfig": { "description": "Information about a JSON Web Token (JWT) validation action.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "JwksEndpoint": { "title": "Jwksendpoint", "type": "string" }, "Issuer": { "title": "Issuer", "type": "string" }, "AdditionalClaims": { "anyOf": [ { "items": { "$ref": "#/$defs/JwtValidationActionAdditionalClaim" }, "type": "array" }, { "type": "null" } ], "title": "Additionalclaims" } }, "required": [ "JwksEndpoint", "Issuer" ], "title": "JwtValidationActionConfig", "type": "object" }, "Listener": { "description": "Information about a listener.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "LoadBalancerArn": { "title": "Loadbalancerarn", "type": "string" }, "Port": { "title": "Port", "type": "integer" }, "Protocol": { "anyOf": [ { "enum": [ "HTTP", "HTTPS", "TCP", "TLS", "UDP", "TCP_UDP", "GENEVE", "QUIC", "TCP_QUIC" ], "type": "string" }, { "type": "null" } ], "default": "HTTPS", "title": "Protocol" }, "ListenerArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Listenerarn" }, "Certificates": { "anyOf": [ { "items": { "$ref": "#/$defs/Certificate" }, "type": "array" }, { "type": "null" } ], "title": "Certificates" }, "SslPolicy": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Sslpolicy" }, "DefaultActions": { "anyOf": [ { "items": { "$ref": "#/$defs/Action" }, "type": "array" }, { "type": "null" } ], "title": "Defaultactions" }, "AlpnPolicy": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Alpnpolicy" }, "MutualAuthentication": { "anyOf": [ { "$ref": "#/$defs/MutualAuthenticationAttributes" }, { "type": "null" } ], "default": null } }, "required": [ "LoadBalancerArn", "Port" ], "title": "Listener", "type": "object" }, "MutualAuthenticationAttributes": { "description": "Information about the mutual authentication attributes of a listener.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Mode": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Mode" }, "TrustStoreArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Truststorearn" }, "IgnoreClientCertificateExpiry": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Ignoreclientcertificateexpiry" }, "TrustStoreAssociationStatus": { "anyOf": [ { "enum": [ "active", "removed" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Truststoreassociationstatus" }, "AdvertiseTrustStoreCaNames": { "anyOf": [ { "enum": [ "on", "off" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Advertisetruststorecanames" } }, "title": "MutualAuthenticationAttributes", "type": "object" }, "RedirectActionConfig": { "description": "Information about a redirect action.\n\nA URI consists of the following components: protocol://hostname:port/path?query. You must modify at least one of the\nfollowing components to avoid a redirect loop: protocol, hostname, port, or path. Any components that you do not modify\nretain their original values.\n\nYou can reuse URI components using the following reserved keywords:\n\n* #{protocol}\n* #{host}\n* #{port}\n* #{path} (the leading \"/\" is removed)\n* #{query}\n\nFor example, you can change the path to \"/new/#{path}\", the hostname to \"example.#{host}\", or the query to\n\"#{query}&value=xyz\".", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Protocol": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Protocol" }, "Port": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Port" }, "Host": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Host" }, "Path": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Path" }, "Query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Query" }, "StatusCode": { "enum": [ "HTTP_301", "HTTP_302" ], "title": "Statuscode", "type": "string" } }, "required": [ "StatusCode" ], "title": "RedirectActionConfig", "type": "object" }, "TargetGroupTuple": { "description": "Information about how traffic will be distributed between multiple target groups in\na forward rule.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroupArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Targetgrouparn" }, "Weight": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Weight" } }, "title": "TargetGroupTuple", "type": "object" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.CreateLoadBalancerOutput[source]
Bases:
Boto3ModelShow JSON schema
{ "title": "CreateLoadBalancerOutput", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "LoadBalancers": { "anyOf": [ { "items": { "$ref": "#/$defs/LoadBalancer" }, "type": "array" }, { "type": "null" } ], "title": "Loadbalancers" } }, "$defs": { "AvailabilityZone": { "description": "Information about an Availability Zone.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "ZoneName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Zonename" }, "SubnetId": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Subnetid" }, "OutpostId": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Outpostid" }, "LoadBalancerAddresses": { "anyOf": [ { "items": { "$ref": "#/$defs/LoadBalancerAddress" }, "type": "array" }, { "type": "null" } ], "title": "Loadbalanceraddresses" }, "SourceNatIpv6Prefixes": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Sourcenatipv6Prefixes" } }, "title": "AvailabilityZone", "type": "object" }, "ElbV2IpamPools": { "description": "An IPAM pool is a collection of IP address CIDRs.\n\nIPAM pools enable you to organize your IP addresses according to your routing and\nsecurity needs.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Ipv4IpamPoolId": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Ipv4Ipampoolid" } }, "title": "ElbV2IpamPools", "type": "object" }, "LoadBalancer": { "description": "Information about a load balancer.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "LoadBalancerName": { "title": "Loadbalancername", "type": "string" }, "Scheme": { "anyOf": [ { "enum": [ "internet-facing", "internal" ], "type": "string" }, { "type": "null" } ], "default": "internet-facing", "title": "Scheme" }, "Type": { "anyOf": [ { "enum": [ "application", "network", "gateway" ], "type": "string" }, { "type": "null" } ], "default": "application", "title": "Type" }, "IpAddressType": { "anyOf": [ { "enum": [ "ipv4", "dualstack", "dualstack-without-public-ipv4" ], "type": "string" }, { "type": "null" } ], "default": "ipv4", "title": "Ipaddresstype" }, "LoadBalancerArn": { "default": null, "title": "Loadbalancerarn", "type": "string" }, "DNSName": { "default": null, "title": "Dnsname", "type": "string" }, "CanonicalHostedZoneId": { "default": null, "title": "Canonicalhostedzoneid", "type": "string" }, "CreatedTime": { "default": null, "format": "date-time", "title": "Createdtime", "type": "string" }, "VpcId": { "default": null, "title": "Vpcid", "type": "string" }, "State": { "$ref": "#/$defs/LoadBalancerState", "default": null }, "AvailabilityZones": { "items": { "$ref": "#/$defs/AvailabilityZone" }, "title": "Availabilityzones", "type": "array" }, "SecurityGroups": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Securitygroups" }, "CustomerOwnedIpv4Pool": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Customerownedipv4Pool" }, "EnforceSecurityGroupInboundRulesOnPrivateLinkTraffic": { "default": null, "title": "Enforcesecuritygroupinboundrulesonprivatelinktraffic", "type": "string" }, "EnablePrefixForIpv6SourceNat": { "anyOf": [ { "enum": [ "on", "off" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Enableprefixforipv6Sourcenat" }, "IpamPools": { "anyOf": [ { "$ref": "#/$defs/ElbV2IpamPools" }, { "type": "null" } ], "default": null } }, "required": [ "LoadBalancerName" ], "title": "LoadBalancer", "type": "object" }, "LoadBalancerAddress": { "description": "Information about a static IP address for a load balancer.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "IpAddress": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Ipaddress" }, "AllocationId": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Allocationid" }, "PrivateIPv4Address": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Privateipv4Address" }, "IPv6Address": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Ipv6Address" } }, "title": "LoadBalancerAddress", "type": "object" }, "LoadBalancerState": { "description": "Information about the state of the load balancer.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Code": { "anyOf": [ { "enum": [ "active", "provisioning", "active_impaired", "failed" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Code" }, "Reason": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Reason" } }, "title": "LoadBalancerState", "type": "object" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field LoadBalancers: builtins.list[LoadBalancer] | None [Optional]
Information about the load balancer.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.CreateRuleOutput[source]
Bases:
Boto3ModelShow JSON schema
{ "title": "CreateRuleOutput", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Rules": { "anyOf": [ { "items": { "$ref": "#/$defs/Rule" }, "type": "array" }, { "type": "null" } ], "title": "Rules" } }, "$defs": { "Action": { "description": "Information about an action.\n\nEach rule must include exactly one of the following routing actions: ``forward``, ``fixed-response``, or ``redirect``,\nand it must be the last action to be performed.\n\nOptionally, a rule for an HTTPS listener can also include one of the following user authentication actions:\n``authenticate-oidc``, ``authenticate-cognito``, or ``jwt-validation``.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Type": { "default": null, "enum": [ "forward", "authenticate-oidc", "authenticate-cognito", "redirect", "fixed-response", "jwt-validation" ], "title": "Type", "type": "string" }, "TargetGroupArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Targetgrouparn" }, "AuthenticateOidcConfig": { "anyOf": [ { "$ref": "#/$defs/AuthenticateOidcActionConfig" }, { "type": "null" } ], "default": null }, "AuthenticateCognitoConfig": { "anyOf": [ { "$ref": "#/$defs/AuthenticateCognitoActionConfig" }, { "type": "null" } ], "default": null }, "Order": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Order" }, "RedirectConfig": { "anyOf": [ { "$ref": "#/$defs/RedirectActionConfig" }, { "type": "null" } ], "default": null }, "FixedResponseConfig": { "anyOf": [ { "$ref": "#/$defs/FixedResponseActionConfig" }, { "type": "null" } ], "default": null }, "ForwardConfig": { "anyOf": [ { "$ref": "#/$defs/ForwardActionConfig" }, { "type": "null" } ], "default": null }, "JwtValidationConfig": { "anyOf": [ { "$ref": "#/$defs/JwtValidationActionConfig" }, { "type": "null" } ], "default": null } }, "title": "Action", "type": "object" }, "AuthenticateCognitoActionConfig": { "description": "Request parameters to use when integrating with Amazon Cognito to authenticate\nusers.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "UserPoolArn": { "title": "Userpoolarn", "type": "string" }, "UserPoolClientId": { "title": "Userpoolclientid", "type": "string" }, "UserPoolDomain": { "title": "Userpooldomain", "type": "string" }, "SessionCookieName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Sessioncookiename" }, "Scope": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Scope" }, "SessionTimeout": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Sessiontimeout" }, "AuthenticationRequestExtraParams": { "anyOf": [ { "additionalProperties": { "type": "string" }, "type": "object" }, { "type": "null" } ], "title": "Authenticationrequestextraparams" }, "OnUnauthenticatedRequest": { "anyOf": [ { "enum": [ "deny", "allow", "authenticate" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Onunauthenticatedrequest" } }, "required": [ "UserPoolArn", "UserPoolClientId", "UserPoolDomain" ], "title": "AuthenticateCognitoActionConfig", "type": "object" }, "AuthenticateOidcActionConfig": { "description": "Request parameters when using an identity provider (IdP) that is compliant with\nOpenID Connect (OIDC) to authenticate users.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Issuer": { "title": "Issuer", "type": "string" }, "AuthorizationEndpoint": { "title": "Authorizationendpoint", "type": "string" }, "TokenEndpoint": { "title": "Tokenendpoint", "type": "string" }, "UserInfoEndpoint": { "title": "Userinfoendpoint", "type": "string" }, "ClientId": { "title": "Clientid", "type": "string" }, "ClientSecret": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Clientsecret" }, "SessionCookieName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Sessioncookiename" }, "Scope": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Scope" }, "SessionTimeout": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Sessiontimeout" }, "AuthenticationRequestExtraParams": { "anyOf": [ { "additionalProperties": { "type": "string" }, "type": "object" }, { "type": "null" } ], "title": "Authenticationrequestextraparams" }, "OnUnauthenticatedRequest": { "anyOf": [ { "enum": [ "deny", "allow", "authenticate" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Onunauthenticatedrequest" }, "UseExistingClientSecret": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Useexistingclientsecret" } }, "required": [ "Issuer", "AuthorizationEndpoint", "TokenEndpoint", "UserInfoEndpoint", "ClientId" ], "title": "AuthenticateOidcActionConfig", "type": "object" }, "ElbV2HostHeaderRewriteConfig": { "description": "Information about a host header rewrite transform.\n\nThis transform matches a pattern in the host header in an HTTP request and replaces\nit with the specified string.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Rewrites": { "anyOf": [ { "items": { "$ref": "#/$defs/RewriteConfig" }, "type": "array" }, { "type": "null" } ], "title": "Rewrites" } }, "title": "ElbV2HostHeaderRewriteConfig", "type": "object" }, "ElbV2TargetGroupStickinessConfig": { "description": "Information about the target group stickiness for a rule.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Enabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Enabled" }, "DurationSeconds": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Durationseconds" } }, "title": "ElbV2TargetGroupStickinessConfig", "type": "object" }, "ElbV2UrlRewriteConfig": { "description": "Information about a URL rewrite transform.\n\nThis transform matches a pattern in the request URL and replaces it with the\nspecified string.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Rewrites": { "anyOf": [ { "items": { "$ref": "#/$defs/RewriteConfig" }, "type": "array" }, { "type": "null" } ], "title": "Rewrites" } }, "title": "ElbV2UrlRewriteConfig", "type": "object" }, "FixedResponseActionConfig": { "description": "Information about an action that returns a custom HTTP response.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "MessageBody": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Messagebody" }, "StatusCode": { "title": "Statuscode", "type": "string" }, "ContentType": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Contenttype" } }, "required": [ "StatusCode" ], "title": "FixedResponseActionConfig", "type": "object" }, "ForwardActionConfig": { "description": "Information about a forward action.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroups": { "anyOf": [ { "items": { "$ref": "#/$defs/TargetGroupTuple" }, "type": "array" }, { "type": "null" } ], "title": "Targetgroups" }, "TargetGroupStickinessConfig": { "anyOf": [ { "$ref": "#/$defs/ElbV2TargetGroupStickinessConfig" }, { "type": "null" } ], "default": null } }, "title": "ForwardActionConfig", "type": "object" }, "HostHeaderConditionConfig": { "description": "Information about a host header condition.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" }, "RegexValues": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Regexvalues" } }, "title": "HostHeaderConditionConfig", "type": "object" }, "HttpHeaderConditionConfig": { "description": "Information about an HTTP header condition.\n\nThere is a set of standard HTTP header fields. You can also define custom HTTP\nheader fields.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "HttpHeaderName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Httpheadername" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" }, "RegexValues": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Regexvalues" } }, "title": "HttpHeaderConditionConfig", "type": "object" }, "HttpRequestMethodConditionConfig": { "description": "Information about an HTTP method condition.\n\nHTTP defines a set of request methods, also referred to as HTTP verbs. For more\ninformation, see the\n`HTTP Method Registry <https://www.iana.org/assignments/http-methods/http-methods.xhtml>`_.\nYou can also define custom HTTP methods.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" } }, "title": "HttpRequestMethodConditionConfig", "type": "object" }, "JwtValidationActionAdditionalClaim": { "description": "Information about an additional claim to validate.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Format": { "enum": [ "single-string", "string-array", "space-separated-values" ], "title": "Format", "type": "string" }, "Name": { "title": "Name", "type": "string" }, "Values": { "items": { "type": "string" }, "title": "Values", "type": "array" } }, "required": [ "Format", "Name", "Values" ], "title": "JwtValidationActionAdditionalClaim", "type": "object" }, "JwtValidationActionConfig": { "description": "Information about a JSON Web Token (JWT) validation action.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "JwksEndpoint": { "title": "Jwksendpoint", "type": "string" }, "Issuer": { "title": "Issuer", "type": "string" }, "AdditionalClaims": { "anyOf": [ { "items": { "$ref": "#/$defs/JwtValidationActionAdditionalClaim" }, "type": "array" }, { "type": "null" } ], "title": "Additionalclaims" } }, "required": [ "JwksEndpoint", "Issuer" ], "title": "JwtValidationActionConfig", "type": "object" }, "PathPatternConditionConfig": { "description": "Information about a path pattern condition.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" }, "RegexValues": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Regexvalues" } }, "title": "PathPatternConditionConfig", "type": "object" }, "QueryStringConditionConfig": { "description": "Information about a query string condition.\n\nThe query string component of a URI starts after the first '?' character and is\nterminated by either a '#' character or the end of the URI. A typical query string\ncontains key/value pairs separated by '&' characters. The allowed characters are\nspecified by RFC 3986. Any character can be percentage encoded.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "$ref": "#/$defs/QueryStringKeyValuePair" }, "type": "array" }, { "type": "null" } ], "title": "Values" } }, "title": "QueryStringConditionConfig", "type": "object" }, "QueryStringKeyValuePair": { "description": "Information about a key/value pair.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Key": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Key" }, "Value": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Value" } }, "title": "QueryStringKeyValuePair", "type": "object" }, "RedirectActionConfig": { "description": "Information about a redirect action.\n\nA URI consists of the following components: protocol://hostname:port/path?query. You must modify at least one of the\nfollowing components to avoid a redirect loop: protocol, hostname, port, or path. Any components that you do not modify\nretain their original values.\n\nYou can reuse URI components using the following reserved keywords:\n\n* #{protocol}\n* #{host}\n* #{port}\n* #{path} (the leading \"/\" is removed)\n* #{query}\n\nFor example, you can change the path to \"/new/#{path}\", the hostname to \"example.#{host}\", or the query to\n\"#{query}&value=xyz\".", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Protocol": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Protocol" }, "Port": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Port" }, "Host": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Host" }, "Path": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Path" }, "Query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Query" }, "StatusCode": { "enum": [ "HTTP_301", "HTTP_302" ], "title": "Statuscode", "type": "string" } }, "required": [ "StatusCode" ], "title": "RedirectActionConfig", "type": "object" }, "RewriteConfig": { "description": "Information about a rewrite transform.\n\nThis transform matches a pattern and replaces it with the specified string.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Regex": { "title": "Regex", "type": "string" }, "Replace": { "title": "Replace", "type": "string" } }, "required": [ "Regex", "Replace" ], "title": "RewriteConfig", "type": "object" }, "Rule": { "description": "Information about a rule.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Priority": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "1", "title": "Priority" }, "Conditions": { "items": { "$ref": "#/$defs/RuleCondition" }, "title": "Conditions", "type": "array" }, "Actions": { "items": { "$ref": "#/$defs/Action" }, "title": "Actions", "type": "array" }, "IsDefault": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Isdefault" }, "RuleArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Rulearn" }, "Transforms": { "anyOf": [ { "items": { "$ref": "#/$defs/RuleTransform" }, "type": "array" }, { "type": "null" } ], "title": "Transforms" } }, "required": [ "Conditions", "Actions" ], "title": "Rule", "type": "object" }, "RuleCondition": { "description": "Information about a condition for a rule.\n\nEach rule can optionally include up to one of each of the following conditions: ``http-request-method``, ``host-\nheader``, ``path-pattern``, and ``source-ip``. Each rule can also optionally include one or more of each of the\nfollowing conditions: ``http-header`` and ``query-string``. Note that the value for a condition can't be empty.\n\nFor more information, see `Quotas for your Application Load\nBalancers <https://docs.aws.amazon.com/elasticloadbalancing/latest/application/load-balancer-limits.html>`_.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Field": { "default": null, "title": "Field", "type": "string" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" }, "HostHeaderConfig": { "anyOf": [ { "$ref": "#/$defs/HostHeaderConditionConfig" }, { "type": "null" } ], "default": null }, "PathPatternConfig": { "anyOf": [ { "$ref": "#/$defs/PathPatternConditionConfig" }, { "type": "null" } ], "default": null }, "HttpHeaderConfig": { "anyOf": [ { "$ref": "#/$defs/HttpHeaderConditionConfig" }, { "type": "null" } ], "default": null }, "QueryStringConfig": { "anyOf": [ { "$ref": "#/$defs/QueryStringConditionConfig" }, { "type": "null" } ], "default": null }, "HttpRequestMethodConfig": { "anyOf": [ { "$ref": "#/$defs/HttpRequestMethodConditionConfig" }, { "type": "null" } ], "default": null }, "SourceIpConfig": { "anyOf": [ { "$ref": "#/$defs/SourceIpConditionConfig" }, { "type": "null" } ], "default": null }, "RegexValues": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Regexvalues" } }, "title": "RuleCondition", "type": "object" }, "RuleTransform": { "description": "Information about a transform to apply to requests that match a rule.\n\nTransforms are applied to requests before they are sent to targets.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Type": { "enum": [ "host-header-rewrite", "url-rewrite" ], "title": "Type", "type": "string" }, "HostHeaderRewriteConfig": { "anyOf": [ { "$ref": "#/$defs/ElbV2HostHeaderRewriteConfig" }, { "type": "null" } ], "default": null }, "UrlRewriteConfig": { "anyOf": [ { "$ref": "#/$defs/ElbV2UrlRewriteConfig" }, { "type": "null" } ], "default": null } }, "required": [ "Type" ], "title": "RuleTransform", "type": "object" }, "SourceIpConditionConfig": { "description": "Information about a source IP condition.\n\nYou can use this condition to route based on the IP address of the source that\nconnects to the load balancer. If a client is behind a proxy, this is the IP address\nof the proxy not the IP address of the client.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" } }, "title": "SourceIpConditionConfig", "type": "object" }, "TargetGroupTuple": { "description": "Information about how traffic will be distributed between multiple target groups in\na forward rule.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroupArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Targetgrouparn" }, "Weight": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Weight" } }, "title": "TargetGroupTuple", "type": "object" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.CreateTargetGroupOutput[source]
Bases:
Boto3ModelShow JSON schema
{ "title": "CreateTargetGroupOutput", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroups": { "anyOf": [ { "items": { "$ref": "#/$defs/TargetGroup" }, "type": "array" }, { "type": "null" } ], "title": "Targetgroups" } }, "$defs": { "ResponseCodeMatcher": { "description": "The codes to use when checking for a successful response from a target.\n\nIf the protocol version is gRPC, these are gRPC codes. Otherwise, these are HTTP\ncodes.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "HttpCode": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Httpcode" }, "GrpcCode": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Grpccode" } }, "title": "ResponseCodeMatcher", "type": "object" }, "TargetGroup": { "description": "Information about a target group.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroupName": { "title": "Targetgroupname", "type": "string" }, "Protocol": { "anyOf": [ { "enum": [ "HTTP", "HTTPS", "TCP", "TLS", "UDP", "TCP_UDP", "GENEVE", "QUIC", "TCP_QUIC" ], "type": "string" }, { "type": "null" } ], "default": "HTTPS", "title": "Protocol" }, "Port": { "title": "Port", "type": "integer" }, "VpcId": { "title": "Vpcid", "type": "string" }, "TargetType": { "anyOf": [ { "enum": [ "instance", "ip", "lambda", "alb" ], "type": "string" }, { "type": "null" } ], "default": "ip", "title": "Targettype" }, "IpAddressType": { "anyOf": [ { "enum": [ "ipv4", "ipv6" ], "type": "string" }, { "type": "null" } ], "default": "ipv4", "title": "Ipaddresstype" }, "TargetGroupArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Targetgrouparn" }, "HealthCheckProtocol": { "anyOf": [ { "enum": [ "HTTP", "HTTPS", "TCP", "TLS", "UDP", "TCP_UDP", "GENEVE", "QUIC", "TCP_QUIC" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Healthcheckprotocol" }, "HealthCheckPort": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Healthcheckport" }, "HealthCheckEnabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Healthcheckenabled" }, "HealthCheckIntervalSeconds": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Healthcheckintervalseconds" }, "HealthCheckTimeoutSeconds": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Healthchecktimeoutseconds" }, "HealthyThresholdCount": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Healthythresholdcount" }, "UnhealthyThresholdCount": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Unhealthythresholdcount" }, "HealthCheckPath": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Healthcheckpath" }, "Matcher": { "anyOf": [ { "$ref": "#/$defs/ResponseCodeMatcher" }, { "type": "null" } ], "default": null }, "LoadBalancerArns": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Loadbalancerarns" }, "ProtocolVersion": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Protocolversion" }, "TargetControlPort": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Targetcontrolport" } }, "required": [ "TargetGroupName", "Port", "VpcId" ], "title": "TargetGroup", "type": "object" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field TargetGroups: builtins.list[TargetGroup] | None [Optional]
Information about the target group.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.DeleteListenerOutput[source]
Bases:
Boto3ModelShow JSON schema
{ "title": "DeleteListenerOutput", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.DeleteLoadBalancerOutput[source]
Bases:
Boto3ModelShow JSON schema
{ "title": "DeleteLoadBalancerOutput", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.DeleteRuleOutput[source]
Bases:
Boto3ModelShow JSON schema
{ "title": "DeleteRuleOutput", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.DeleteTargetGroupOutput[source]
Bases:
Boto3ModelShow JSON schema
{ "title": "DeleteTargetGroupOutput", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.DescribeListenersOutput[source]
Bases:
Boto3ModelShow JSON schema
{ "title": "DescribeListenersOutput", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Listeners": { "anyOf": [ { "items": { "$ref": "#/$defs/Listener" }, "type": "array" }, { "type": "null" } ], "title": "Listeners" }, "NextMarker": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Nextmarker" } }, "$defs": { "Action": { "description": "Information about an action.\n\nEach rule must include exactly one of the following routing actions: ``forward``, ``fixed-response``, or ``redirect``,\nand it must be the last action to be performed.\n\nOptionally, a rule for an HTTPS listener can also include one of the following user authentication actions:\n``authenticate-oidc``, ``authenticate-cognito``, or ``jwt-validation``.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Type": { "default": null, "enum": [ "forward", "authenticate-oidc", "authenticate-cognito", "redirect", "fixed-response", "jwt-validation" ], "title": "Type", "type": "string" }, "TargetGroupArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Targetgrouparn" }, "AuthenticateOidcConfig": { "anyOf": [ { "$ref": "#/$defs/AuthenticateOidcActionConfig" }, { "type": "null" } ], "default": null }, "AuthenticateCognitoConfig": { "anyOf": [ { "$ref": "#/$defs/AuthenticateCognitoActionConfig" }, { "type": "null" } ], "default": null }, "Order": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Order" }, "RedirectConfig": { "anyOf": [ { "$ref": "#/$defs/RedirectActionConfig" }, { "type": "null" } ], "default": null }, "FixedResponseConfig": { "anyOf": [ { "$ref": "#/$defs/FixedResponseActionConfig" }, { "type": "null" } ], "default": null }, "ForwardConfig": { "anyOf": [ { "$ref": "#/$defs/ForwardActionConfig" }, { "type": "null" } ], "default": null }, "JwtValidationConfig": { "anyOf": [ { "$ref": "#/$defs/JwtValidationActionConfig" }, { "type": "null" } ], "default": null } }, "title": "Action", "type": "object" }, "AuthenticateCognitoActionConfig": { "description": "Request parameters to use when integrating with Amazon Cognito to authenticate\nusers.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "UserPoolArn": { "title": "Userpoolarn", "type": "string" }, "UserPoolClientId": { "title": "Userpoolclientid", "type": "string" }, "UserPoolDomain": { "title": "Userpooldomain", "type": "string" }, "SessionCookieName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Sessioncookiename" }, "Scope": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Scope" }, "SessionTimeout": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Sessiontimeout" }, "AuthenticationRequestExtraParams": { "anyOf": [ { "additionalProperties": { "type": "string" }, "type": "object" }, { "type": "null" } ], "title": "Authenticationrequestextraparams" }, "OnUnauthenticatedRequest": { "anyOf": [ { "enum": [ "deny", "allow", "authenticate" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Onunauthenticatedrequest" } }, "required": [ "UserPoolArn", "UserPoolClientId", "UserPoolDomain" ], "title": "AuthenticateCognitoActionConfig", "type": "object" }, "AuthenticateOidcActionConfig": { "description": "Request parameters when using an identity provider (IdP) that is compliant with\nOpenID Connect (OIDC) to authenticate users.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Issuer": { "title": "Issuer", "type": "string" }, "AuthorizationEndpoint": { "title": "Authorizationendpoint", "type": "string" }, "TokenEndpoint": { "title": "Tokenendpoint", "type": "string" }, "UserInfoEndpoint": { "title": "Userinfoendpoint", "type": "string" }, "ClientId": { "title": "Clientid", "type": "string" }, "ClientSecret": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Clientsecret" }, "SessionCookieName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Sessioncookiename" }, "Scope": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Scope" }, "SessionTimeout": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Sessiontimeout" }, "AuthenticationRequestExtraParams": { "anyOf": [ { "additionalProperties": { "type": "string" }, "type": "object" }, { "type": "null" } ], "title": "Authenticationrequestextraparams" }, "OnUnauthenticatedRequest": { "anyOf": [ { "enum": [ "deny", "allow", "authenticate" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Onunauthenticatedrequest" }, "UseExistingClientSecret": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Useexistingclientsecret" } }, "required": [ "Issuer", "AuthorizationEndpoint", "TokenEndpoint", "UserInfoEndpoint", "ClientId" ], "title": "AuthenticateOidcActionConfig", "type": "object" }, "Certificate": { "additionalProperties": true, "description": "Information about an SSL server certificate.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "CertificateArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Certificatearn" }, "IsDefault": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Isdefault" } }, "title": "Certificate", "type": "object" }, "ElbV2TargetGroupStickinessConfig": { "description": "Information about the target group stickiness for a rule.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Enabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Enabled" }, "DurationSeconds": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Durationseconds" } }, "title": "ElbV2TargetGroupStickinessConfig", "type": "object" }, "FixedResponseActionConfig": { "description": "Information about an action that returns a custom HTTP response.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "MessageBody": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Messagebody" }, "StatusCode": { "title": "Statuscode", "type": "string" }, "ContentType": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Contenttype" } }, "required": [ "StatusCode" ], "title": "FixedResponseActionConfig", "type": "object" }, "ForwardActionConfig": { "description": "Information about a forward action.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroups": { "anyOf": [ { "items": { "$ref": "#/$defs/TargetGroupTuple" }, "type": "array" }, { "type": "null" } ], "title": "Targetgroups" }, "TargetGroupStickinessConfig": { "anyOf": [ { "$ref": "#/$defs/ElbV2TargetGroupStickinessConfig" }, { "type": "null" } ], "default": null } }, "title": "ForwardActionConfig", "type": "object" }, "JwtValidationActionAdditionalClaim": { "description": "Information about an additional claim to validate.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Format": { "enum": [ "single-string", "string-array", "space-separated-values" ], "title": "Format", "type": "string" }, "Name": { "title": "Name", "type": "string" }, "Values": { "items": { "type": "string" }, "title": "Values", "type": "array" } }, "required": [ "Format", "Name", "Values" ], "title": "JwtValidationActionAdditionalClaim", "type": "object" }, "JwtValidationActionConfig": { "description": "Information about a JSON Web Token (JWT) validation action.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "JwksEndpoint": { "title": "Jwksendpoint", "type": "string" }, "Issuer": { "title": "Issuer", "type": "string" }, "AdditionalClaims": { "anyOf": [ { "items": { "$ref": "#/$defs/JwtValidationActionAdditionalClaim" }, "type": "array" }, { "type": "null" } ], "title": "Additionalclaims" } }, "required": [ "JwksEndpoint", "Issuer" ], "title": "JwtValidationActionConfig", "type": "object" }, "Listener": { "description": "Information about a listener.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "LoadBalancerArn": { "title": "Loadbalancerarn", "type": "string" }, "Port": { "title": "Port", "type": "integer" }, "Protocol": { "anyOf": [ { "enum": [ "HTTP", "HTTPS", "TCP", "TLS", "UDP", "TCP_UDP", "GENEVE", "QUIC", "TCP_QUIC" ], "type": "string" }, { "type": "null" } ], "default": "HTTPS", "title": "Protocol" }, "ListenerArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Listenerarn" }, "Certificates": { "anyOf": [ { "items": { "$ref": "#/$defs/Certificate" }, "type": "array" }, { "type": "null" } ], "title": "Certificates" }, "SslPolicy": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Sslpolicy" }, "DefaultActions": { "anyOf": [ { "items": { "$ref": "#/$defs/Action" }, "type": "array" }, { "type": "null" } ], "title": "Defaultactions" }, "AlpnPolicy": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Alpnpolicy" }, "MutualAuthentication": { "anyOf": [ { "$ref": "#/$defs/MutualAuthenticationAttributes" }, { "type": "null" } ], "default": null } }, "required": [ "LoadBalancerArn", "Port" ], "title": "Listener", "type": "object" }, "MutualAuthenticationAttributes": { "description": "Information about the mutual authentication attributes of a listener.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Mode": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Mode" }, "TrustStoreArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Truststorearn" }, "IgnoreClientCertificateExpiry": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Ignoreclientcertificateexpiry" }, "TrustStoreAssociationStatus": { "anyOf": [ { "enum": [ "active", "removed" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Truststoreassociationstatus" }, "AdvertiseTrustStoreCaNames": { "anyOf": [ { "enum": [ "on", "off" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Advertisetruststorecanames" } }, "title": "MutualAuthenticationAttributes", "type": "object" }, "RedirectActionConfig": { "description": "Information about a redirect action.\n\nA URI consists of the following components: protocol://hostname:port/path?query. You must modify at least one of the\nfollowing components to avoid a redirect loop: protocol, hostname, port, or path. Any components that you do not modify\nretain their original values.\n\nYou can reuse URI components using the following reserved keywords:\n\n* #{protocol}\n* #{host}\n* #{port}\n* #{path} (the leading \"/\" is removed)\n* #{query}\n\nFor example, you can change the path to \"/new/#{path}\", the hostname to \"example.#{host}\", or the query to\n\"#{query}&value=xyz\".", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Protocol": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Protocol" }, "Port": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Port" }, "Host": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Host" }, "Path": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Path" }, "Query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Query" }, "StatusCode": { "enum": [ "HTTP_301", "HTTP_302" ], "title": "Statuscode", "type": "string" } }, "required": [ "StatusCode" ], "title": "RedirectActionConfig", "type": "object" }, "TargetGroupTuple": { "description": "Information about how traffic will be distributed between multiple target groups in\na forward rule.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroupArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Targetgrouparn" }, "Weight": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Weight" } }, "title": "TargetGroupTuple", "type": "object" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field NextMarker: str | None = None
If there are additional results, this is the marker for the next set of results.
Otherwise, this is null.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.DescribeLoadBalancerAttributesOutput[source]
Bases:
Boto3ModelShow JSON schema
{ "title": "DescribeLoadBalancerAttributesOutput", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Attributes": { "anyOf": [ { "items": { "$ref": "#/$defs/LoadBalancerAttribute" }, "type": "array" }, { "type": "null" } ], "title": "Attributes" } }, "$defs": { "LoadBalancerAttribute": { "description": "Information about a load balancer attribute.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Key": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Key" }, "Value": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Value" } }, "title": "LoadBalancerAttribute", "type": "object" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field Attributes: builtins.list[LoadBalancerAttribute] | None [Optional]
Information about the load balancer attributes.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.DescribeLoadBalancersOutput[source]
Bases:
Boto3ModelShow JSON schema
{ "title": "DescribeLoadBalancersOutput", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "LoadBalancers": { "anyOf": [ { "items": { "$ref": "#/$defs/LoadBalancer" }, "type": "array" }, { "type": "null" } ], "title": "Loadbalancers" }, "NextMarker": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Nextmarker" } }, "$defs": { "AvailabilityZone": { "description": "Information about an Availability Zone.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "ZoneName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Zonename" }, "SubnetId": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Subnetid" }, "OutpostId": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Outpostid" }, "LoadBalancerAddresses": { "anyOf": [ { "items": { "$ref": "#/$defs/LoadBalancerAddress" }, "type": "array" }, { "type": "null" } ], "title": "Loadbalanceraddresses" }, "SourceNatIpv6Prefixes": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Sourcenatipv6Prefixes" } }, "title": "AvailabilityZone", "type": "object" }, "ElbV2IpamPools": { "description": "An IPAM pool is a collection of IP address CIDRs.\n\nIPAM pools enable you to organize your IP addresses according to your routing and\nsecurity needs.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Ipv4IpamPoolId": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Ipv4Ipampoolid" } }, "title": "ElbV2IpamPools", "type": "object" }, "LoadBalancer": { "description": "Information about a load balancer.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "LoadBalancerName": { "title": "Loadbalancername", "type": "string" }, "Scheme": { "anyOf": [ { "enum": [ "internet-facing", "internal" ], "type": "string" }, { "type": "null" } ], "default": "internet-facing", "title": "Scheme" }, "Type": { "anyOf": [ { "enum": [ "application", "network", "gateway" ], "type": "string" }, { "type": "null" } ], "default": "application", "title": "Type" }, "IpAddressType": { "anyOf": [ { "enum": [ "ipv4", "dualstack", "dualstack-without-public-ipv4" ], "type": "string" }, { "type": "null" } ], "default": "ipv4", "title": "Ipaddresstype" }, "LoadBalancerArn": { "default": null, "title": "Loadbalancerarn", "type": "string" }, "DNSName": { "default": null, "title": "Dnsname", "type": "string" }, "CanonicalHostedZoneId": { "default": null, "title": "Canonicalhostedzoneid", "type": "string" }, "CreatedTime": { "default": null, "format": "date-time", "title": "Createdtime", "type": "string" }, "VpcId": { "default": null, "title": "Vpcid", "type": "string" }, "State": { "$ref": "#/$defs/LoadBalancerState", "default": null }, "AvailabilityZones": { "items": { "$ref": "#/$defs/AvailabilityZone" }, "title": "Availabilityzones", "type": "array" }, "SecurityGroups": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Securitygroups" }, "CustomerOwnedIpv4Pool": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Customerownedipv4Pool" }, "EnforceSecurityGroupInboundRulesOnPrivateLinkTraffic": { "default": null, "title": "Enforcesecuritygroupinboundrulesonprivatelinktraffic", "type": "string" }, "EnablePrefixForIpv6SourceNat": { "anyOf": [ { "enum": [ "on", "off" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Enableprefixforipv6Sourcenat" }, "IpamPools": { "anyOf": [ { "$ref": "#/$defs/ElbV2IpamPools" }, { "type": "null" } ], "default": null } }, "required": [ "LoadBalancerName" ], "title": "LoadBalancer", "type": "object" }, "LoadBalancerAddress": { "description": "Information about a static IP address for a load balancer.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "IpAddress": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Ipaddress" }, "AllocationId": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Allocationid" }, "PrivateIPv4Address": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Privateipv4Address" }, "IPv6Address": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Ipv6Address" } }, "title": "LoadBalancerAddress", "type": "object" }, "LoadBalancerState": { "description": "Information about the state of the load balancer.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Code": { "anyOf": [ { "enum": [ "active", "provisioning", "active_impaired", "failed" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Code" }, "Reason": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Reason" } }, "title": "LoadBalancerState", "type": "object" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field LoadBalancers: builtins.list[LoadBalancer] | None [Optional]
Information about the load balancers.
- field NextMarker: str | None = None
If there are additional results, this is the marker for the next set of results.
Otherwise, this is null.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.DescribeRulesOutput[source]
Bases:
Boto3ModelShow JSON schema
{ "title": "DescribeRulesOutput", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Rules": { "anyOf": [ { "items": { "$ref": "#/$defs/Rule" }, "type": "array" }, { "type": "null" } ], "title": "Rules" }, "NextMarker": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Nextmarker" } }, "$defs": { "Action": { "description": "Information about an action.\n\nEach rule must include exactly one of the following routing actions: ``forward``, ``fixed-response``, or ``redirect``,\nand it must be the last action to be performed.\n\nOptionally, a rule for an HTTPS listener can also include one of the following user authentication actions:\n``authenticate-oidc``, ``authenticate-cognito``, or ``jwt-validation``.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Type": { "default": null, "enum": [ "forward", "authenticate-oidc", "authenticate-cognito", "redirect", "fixed-response", "jwt-validation" ], "title": "Type", "type": "string" }, "TargetGroupArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Targetgrouparn" }, "AuthenticateOidcConfig": { "anyOf": [ { "$ref": "#/$defs/AuthenticateOidcActionConfig" }, { "type": "null" } ], "default": null }, "AuthenticateCognitoConfig": { "anyOf": [ { "$ref": "#/$defs/AuthenticateCognitoActionConfig" }, { "type": "null" } ], "default": null }, "Order": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Order" }, "RedirectConfig": { "anyOf": [ { "$ref": "#/$defs/RedirectActionConfig" }, { "type": "null" } ], "default": null }, "FixedResponseConfig": { "anyOf": [ { "$ref": "#/$defs/FixedResponseActionConfig" }, { "type": "null" } ], "default": null }, "ForwardConfig": { "anyOf": [ { "$ref": "#/$defs/ForwardActionConfig" }, { "type": "null" } ], "default": null }, "JwtValidationConfig": { "anyOf": [ { "$ref": "#/$defs/JwtValidationActionConfig" }, { "type": "null" } ], "default": null } }, "title": "Action", "type": "object" }, "AuthenticateCognitoActionConfig": { "description": "Request parameters to use when integrating with Amazon Cognito to authenticate\nusers.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "UserPoolArn": { "title": "Userpoolarn", "type": "string" }, "UserPoolClientId": { "title": "Userpoolclientid", "type": "string" }, "UserPoolDomain": { "title": "Userpooldomain", "type": "string" }, "SessionCookieName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Sessioncookiename" }, "Scope": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Scope" }, "SessionTimeout": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Sessiontimeout" }, "AuthenticationRequestExtraParams": { "anyOf": [ { "additionalProperties": { "type": "string" }, "type": "object" }, { "type": "null" } ], "title": "Authenticationrequestextraparams" }, "OnUnauthenticatedRequest": { "anyOf": [ { "enum": [ "deny", "allow", "authenticate" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Onunauthenticatedrequest" } }, "required": [ "UserPoolArn", "UserPoolClientId", "UserPoolDomain" ], "title": "AuthenticateCognitoActionConfig", "type": "object" }, "AuthenticateOidcActionConfig": { "description": "Request parameters when using an identity provider (IdP) that is compliant with\nOpenID Connect (OIDC) to authenticate users.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Issuer": { "title": "Issuer", "type": "string" }, "AuthorizationEndpoint": { "title": "Authorizationendpoint", "type": "string" }, "TokenEndpoint": { "title": "Tokenendpoint", "type": "string" }, "UserInfoEndpoint": { "title": "Userinfoendpoint", "type": "string" }, "ClientId": { "title": "Clientid", "type": "string" }, "ClientSecret": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Clientsecret" }, "SessionCookieName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Sessioncookiename" }, "Scope": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Scope" }, "SessionTimeout": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Sessiontimeout" }, "AuthenticationRequestExtraParams": { "anyOf": [ { "additionalProperties": { "type": "string" }, "type": "object" }, { "type": "null" } ], "title": "Authenticationrequestextraparams" }, "OnUnauthenticatedRequest": { "anyOf": [ { "enum": [ "deny", "allow", "authenticate" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Onunauthenticatedrequest" }, "UseExistingClientSecret": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Useexistingclientsecret" } }, "required": [ "Issuer", "AuthorizationEndpoint", "TokenEndpoint", "UserInfoEndpoint", "ClientId" ], "title": "AuthenticateOidcActionConfig", "type": "object" }, "ElbV2HostHeaderRewriteConfig": { "description": "Information about a host header rewrite transform.\n\nThis transform matches a pattern in the host header in an HTTP request and replaces\nit with the specified string.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Rewrites": { "anyOf": [ { "items": { "$ref": "#/$defs/RewriteConfig" }, "type": "array" }, { "type": "null" } ], "title": "Rewrites" } }, "title": "ElbV2HostHeaderRewriteConfig", "type": "object" }, "ElbV2TargetGroupStickinessConfig": { "description": "Information about the target group stickiness for a rule.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Enabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Enabled" }, "DurationSeconds": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Durationseconds" } }, "title": "ElbV2TargetGroupStickinessConfig", "type": "object" }, "ElbV2UrlRewriteConfig": { "description": "Information about a URL rewrite transform.\n\nThis transform matches a pattern in the request URL and replaces it with the\nspecified string.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Rewrites": { "anyOf": [ { "items": { "$ref": "#/$defs/RewriteConfig" }, "type": "array" }, { "type": "null" } ], "title": "Rewrites" } }, "title": "ElbV2UrlRewriteConfig", "type": "object" }, "FixedResponseActionConfig": { "description": "Information about an action that returns a custom HTTP response.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "MessageBody": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Messagebody" }, "StatusCode": { "title": "Statuscode", "type": "string" }, "ContentType": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Contenttype" } }, "required": [ "StatusCode" ], "title": "FixedResponseActionConfig", "type": "object" }, "ForwardActionConfig": { "description": "Information about a forward action.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroups": { "anyOf": [ { "items": { "$ref": "#/$defs/TargetGroupTuple" }, "type": "array" }, { "type": "null" } ], "title": "Targetgroups" }, "TargetGroupStickinessConfig": { "anyOf": [ { "$ref": "#/$defs/ElbV2TargetGroupStickinessConfig" }, { "type": "null" } ], "default": null } }, "title": "ForwardActionConfig", "type": "object" }, "HostHeaderConditionConfig": { "description": "Information about a host header condition.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" }, "RegexValues": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Regexvalues" } }, "title": "HostHeaderConditionConfig", "type": "object" }, "HttpHeaderConditionConfig": { "description": "Information about an HTTP header condition.\n\nThere is a set of standard HTTP header fields. You can also define custom HTTP\nheader fields.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "HttpHeaderName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Httpheadername" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" }, "RegexValues": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Regexvalues" } }, "title": "HttpHeaderConditionConfig", "type": "object" }, "HttpRequestMethodConditionConfig": { "description": "Information about an HTTP method condition.\n\nHTTP defines a set of request methods, also referred to as HTTP verbs. For more\ninformation, see the\n`HTTP Method Registry <https://www.iana.org/assignments/http-methods/http-methods.xhtml>`_.\nYou can also define custom HTTP methods.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" } }, "title": "HttpRequestMethodConditionConfig", "type": "object" }, "JwtValidationActionAdditionalClaim": { "description": "Information about an additional claim to validate.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Format": { "enum": [ "single-string", "string-array", "space-separated-values" ], "title": "Format", "type": "string" }, "Name": { "title": "Name", "type": "string" }, "Values": { "items": { "type": "string" }, "title": "Values", "type": "array" } }, "required": [ "Format", "Name", "Values" ], "title": "JwtValidationActionAdditionalClaim", "type": "object" }, "JwtValidationActionConfig": { "description": "Information about a JSON Web Token (JWT) validation action.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "JwksEndpoint": { "title": "Jwksendpoint", "type": "string" }, "Issuer": { "title": "Issuer", "type": "string" }, "AdditionalClaims": { "anyOf": [ { "items": { "$ref": "#/$defs/JwtValidationActionAdditionalClaim" }, "type": "array" }, { "type": "null" } ], "title": "Additionalclaims" } }, "required": [ "JwksEndpoint", "Issuer" ], "title": "JwtValidationActionConfig", "type": "object" }, "PathPatternConditionConfig": { "description": "Information about a path pattern condition.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" }, "RegexValues": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Regexvalues" } }, "title": "PathPatternConditionConfig", "type": "object" }, "QueryStringConditionConfig": { "description": "Information about a query string condition.\n\nThe query string component of a URI starts after the first '?' character and is\nterminated by either a '#' character or the end of the URI. A typical query string\ncontains key/value pairs separated by '&' characters. The allowed characters are\nspecified by RFC 3986. Any character can be percentage encoded.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "$ref": "#/$defs/QueryStringKeyValuePair" }, "type": "array" }, { "type": "null" } ], "title": "Values" } }, "title": "QueryStringConditionConfig", "type": "object" }, "QueryStringKeyValuePair": { "description": "Information about a key/value pair.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Key": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Key" }, "Value": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Value" } }, "title": "QueryStringKeyValuePair", "type": "object" }, "RedirectActionConfig": { "description": "Information about a redirect action.\n\nA URI consists of the following components: protocol://hostname:port/path?query. You must modify at least one of the\nfollowing components to avoid a redirect loop: protocol, hostname, port, or path. Any components that you do not modify\nretain their original values.\n\nYou can reuse URI components using the following reserved keywords:\n\n* #{protocol}\n* #{host}\n* #{port}\n* #{path} (the leading \"/\" is removed)\n* #{query}\n\nFor example, you can change the path to \"/new/#{path}\", the hostname to \"example.#{host}\", or the query to\n\"#{query}&value=xyz\".", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Protocol": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Protocol" }, "Port": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Port" }, "Host": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Host" }, "Path": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Path" }, "Query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Query" }, "StatusCode": { "enum": [ "HTTP_301", "HTTP_302" ], "title": "Statuscode", "type": "string" } }, "required": [ "StatusCode" ], "title": "RedirectActionConfig", "type": "object" }, "RewriteConfig": { "description": "Information about a rewrite transform.\n\nThis transform matches a pattern and replaces it with the specified string.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Regex": { "title": "Regex", "type": "string" }, "Replace": { "title": "Replace", "type": "string" } }, "required": [ "Regex", "Replace" ], "title": "RewriteConfig", "type": "object" }, "Rule": { "description": "Information about a rule.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Priority": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "1", "title": "Priority" }, "Conditions": { "items": { "$ref": "#/$defs/RuleCondition" }, "title": "Conditions", "type": "array" }, "Actions": { "items": { "$ref": "#/$defs/Action" }, "title": "Actions", "type": "array" }, "IsDefault": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Isdefault" }, "RuleArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Rulearn" }, "Transforms": { "anyOf": [ { "items": { "$ref": "#/$defs/RuleTransform" }, "type": "array" }, { "type": "null" } ], "title": "Transforms" } }, "required": [ "Conditions", "Actions" ], "title": "Rule", "type": "object" }, "RuleCondition": { "description": "Information about a condition for a rule.\n\nEach rule can optionally include up to one of each of the following conditions: ``http-request-method``, ``host-\nheader``, ``path-pattern``, and ``source-ip``. Each rule can also optionally include one or more of each of the\nfollowing conditions: ``http-header`` and ``query-string``. Note that the value for a condition can't be empty.\n\nFor more information, see `Quotas for your Application Load\nBalancers <https://docs.aws.amazon.com/elasticloadbalancing/latest/application/load-balancer-limits.html>`_.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Field": { "default": null, "title": "Field", "type": "string" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" }, "HostHeaderConfig": { "anyOf": [ { "$ref": "#/$defs/HostHeaderConditionConfig" }, { "type": "null" } ], "default": null }, "PathPatternConfig": { "anyOf": [ { "$ref": "#/$defs/PathPatternConditionConfig" }, { "type": "null" } ], "default": null }, "HttpHeaderConfig": { "anyOf": [ { "$ref": "#/$defs/HttpHeaderConditionConfig" }, { "type": "null" } ], "default": null }, "QueryStringConfig": { "anyOf": [ { "$ref": "#/$defs/QueryStringConditionConfig" }, { "type": "null" } ], "default": null }, "HttpRequestMethodConfig": { "anyOf": [ { "$ref": "#/$defs/HttpRequestMethodConditionConfig" }, { "type": "null" } ], "default": null }, "SourceIpConfig": { "anyOf": [ { "$ref": "#/$defs/SourceIpConditionConfig" }, { "type": "null" } ], "default": null }, "RegexValues": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Regexvalues" } }, "title": "RuleCondition", "type": "object" }, "RuleTransform": { "description": "Information about a transform to apply to requests that match a rule.\n\nTransforms are applied to requests before they are sent to targets.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Type": { "enum": [ "host-header-rewrite", "url-rewrite" ], "title": "Type", "type": "string" }, "HostHeaderRewriteConfig": { "anyOf": [ { "$ref": "#/$defs/ElbV2HostHeaderRewriteConfig" }, { "type": "null" } ], "default": null }, "UrlRewriteConfig": { "anyOf": [ { "$ref": "#/$defs/ElbV2UrlRewriteConfig" }, { "type": "null" } ], "default": null } }, "required": [ "Type" ], "title": "RuleTransform", "type": "object" }, "SourceIpConditionConfig": { "description": "Information about a source IP condition.\n\nYou can use this condition to route based on the IP address of the source that\nconnects to the load balancer. If a client is behind a proxy, this is the IP address\nof the proxy not the IP address of the client.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" } }, "title": "SourceIpConditionConfig", "type": "object" }, "TargetGroupTuple": { "description": "Information about how traffic will be distributed between multiple target groups in\na forward rule.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroupArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Targetgrouparn" }, "Weight": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Weight" } }, "title": "TargetGroupTuple", "type": "object" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field NextMarker: str | None = None
If there are additional results, this is the marker for the next set of results.
Otherwise, this is null.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.DescribeTargetGroupsOutput[source]
Bases:
Boto3ModelShow JSON schema
{ "title": "DescribeTargetGroupsOutput", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroups": { "anyOf": [ { "items": { "$ref": "#/$defs/TargetGroup" }, "type": "array" }, { "type": "null" } ], "title": "Targetgroups" }, "NextMarker": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Nextmarker" } }, "$defs": { "ResponseCodeMatcher": { "description": "The codes to use when checking for a successful response from a target.\n\nIf the protocol version is gRPC, these are gRPC codes. Otherwise, these are HTTP\ncodes.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "HttpCode": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Httpcode" }, "GrpcCode": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Grpccode" } }, "title": "ResponseCodeMatcher", "type": "object" }, "TargetGroup": { "description": "Information about a target group.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroupName": { "title": "Targetgroupname", "type": "string" }, "Protocol": { "anyOf": [ { "enum": [ "HTTP", "HTTPS", "TCP", "TLS", "UDP", "TCP_UDP", "GENEVE", "QUIC", "TCP_QUIC" ], "type": "string" }, { "type": "null" } ], "default": "HTTPS", "title": "Protocol" }, "Port": { "title": "Port", "type": "integer" }, "VpcId": { "title": "Vpcid", "type": "string" }, "TargetType": { "anyOf": [ { "enum": [ "instance", "ip", "lambda", "alb" ], "type": "string" }, { "type": "null" } ], "default": "ip", "title": "Targettype" }, "IpAddressType": { "anyOf": [ { "enum": [ "ipv4", "ipv6" ], "type": "string" }, { "type": "null" } ], "default": "ipv4", "title": "Ipaddresstype" }, "TargetGroupArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Targetgrouparn" }, "HealthCheckProtocol": { "anyOf": [ { "enum": [ "HTTP", "HTTPS", "TCP", "TLS", "UDP", "TCP_UDP", "GENEVE", "QUIC", "TCP_QUIC" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Healthcheckprotocol" }, "HealthCheckPort": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Healthcheckport" }, "HealthCheckEnabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Healthcheckenabled" }, "HealthCheckIntervalSeconds": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Healthcheckintervalseconds" }, "HealthCheckTimeoutSeconds": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Healthchecktimeoutseconds" }, "HealthyThresholdCount": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Healthythresholdcount" }, "UnhealthyThresholdCount": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Unhealthythresholdcount" }, "HealthCheckPath": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Healthcheckpath" }, "Matcher": { "anyOf": [ { "$ref": "#/$defs/ResponseCodeMatcher" }, { "type": "null" } ], "default": null }, "LoadBalancerArns": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Loadbalancerarns" }, "ProtocolVersion": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Protocolversion" }, "TargetControlPort": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Targetcontrolport" } }, "required": [ "TargetGroupName", "Port", "VpcId" ], "title": "TargetGroup", "type": "object" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field NextMarker: str | None = None
If there are additional results, this is the marker for the next set of results.
Otherwise, this is null.
- field TargetGroups: builtins.list[TargetGroup] | None [Optional]
Information about the target groups.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.DescribeTargetHealthOutput[source]
Bases:
Boto3ModelShow JSON schema
{ "title": "DescribeTargetHealthOutput", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetHealthDescriptions": { "anyOf": [ { "items": { "$ref": "#/$defs/TargetHealthDescription" }, "type": "array" }, { "type": "null" } ], "title": "Targethealthdescriptions" } }, "$defs": { "AnomalyDetectionInfo": { "description": "Information about anomaly detection and mitigation.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Result": { "anyOf": [ { "enum": [ "anomalous", "normal" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Result" }, "MitigationInEffect": { "anyOf": [ { "enum": [ "yes", "no" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Mitigationineffect" } }, "title": "AnomalyDetectionInfo", "type": "object" }, "ElbV2AdministrativeOverride": { "description": "Information about the override status applied to a target.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "State": { "anyOf": [ { "enum": [ "unknown", "no_override", "zonal_shift_active", "zonal_shift_delegated_to_dns" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "State" }, "Reason": { "anyOf": [ { "enum": [ "AdministrativeOverride.Unknown", "AdministrativeOverride.NoOverride", "AdministrativeOverride.ZonalShiftActive", "AdministrativeOverride.ZonalShiftDelegatedToDns" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Reason" }, "Description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" } }, "title": "ElbV2AdministrativeOverride", "type": "object" }, "TargetDescription": { "description": "Information about a target.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Id": { "title": "Id", "type": "string" }, "Port": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Port" }, "AvailabilityZone": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Availabilityzone" }, "QuicServerId": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Quicserverid" } }, "required": [ "Id" ], "title": "TargetDescription", "type": "object" }, "TargetHealthDescription": { "description": "Information about the health of a target.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Target": { "anyOf": [ { "$ref": "#/$defs/TargetDescription" }, { "type": "null" } ], "default": null }, "HealthCheckPort": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Healthcheckport" }, "TargetHealth": { "anyOf": [ { "$ref": "#/$defs/TargetHealthInfo" }, { "type": "null" } ], "default": null }, "AnomalyDetection": { "anyOf": [ { "$ref": "#/$defs/AnomalyDetectionInfo" }, { "type": "null" } ], "default": null }, "AdministrativeOverride": { "anyOf": [ { "$ref": "#/$defs/ElbV2AdministrativeOverride" }, { "type": "null" } ], "default": null } }, "title": "TargetHealthDescription", "type": "object" }, "TargetHealthInfo": { "description": "Information about the current health of a target.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "State": { "anyOf": [ { "enum": [ "initial", "healthy", "unhealthy", "unhealthy.draining", "unused", "draining", "unavailable" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "State" }, "Reason": { "anyOf": [ { "enum": [ "Elb.RegistrationInProgress", "Elb.InitialHealthChecking", "Target.ResponseCodeMismatch", "Target.Timeout", "Target.FailedHealthChecks", "Target.NotRegistered", "Target.NotInUse", "Target.DeregistrationInProgress", "Target.InvalidState", "Target.IpUnusable", "Target.HealthCheckDisabled", "Elb.InternalError" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Reason" }, "Description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" } }, "title": "TargetHealthInfo", "type": "object" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field TargetHealthDescriptions: builtins.list[TargetHealthDescription] | None [Optional]
Information about the health of the targets.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.ElbV2AdministrativeOverride[source]
Bases:
Boto3ModelInformation about the override status applied to a target.
Show JSON schema
{ "title": "ElbV2AdministrativeOverride", "description": "Information about the override status applied to a target.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "State": { "anyOf": [ { "enum": [ "unknown", "no_override", "zonal_shift_active", "zonal_shift_delegated_to_dns" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "State" }, "Reason": { "anyOf": [ { "enum": [ "AdministrativeOverride.Unknown", "AdministrativeOverride.NoOverride", "AdministrativeOverride.ZonalShiftActive", "AdministrativeOverride.ZonalShiftDelegatedToDns" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Reason" }, "Description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field Description: str | None = None
A description of the override state that provides additional details.
- field Reason: Literal['AdministrativeOverride.Unknown', 'AdministrativeOverride.NoOverride', 'AdministrativeOverride.ZonalShiftActive', 'AdministrativeOverride.ZonalShiftDelegatedToDns'] | None = None
The reason code for the state.
- field State: Literal['unknown', 'no_override', 'zonal_shift_active', 'zonal_shift_delegated_to_dns'] | None = None
The state of the override.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.LoadBalancerAttribute[source]
Bases:
Boto3ModelInformation about a load balancer attribute.
Show JSON schema
{ "title": "LoadBalancerAttribute", "description": "Information about a load balancer attribute.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Key": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Key" }, "Value": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Value" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.ModifyListenerOutput[source]
Bases:
Boto3ModelShow JSON schema
{ "title": "ModifyListenerOutput", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Listeners": { "anyOf": [ { "items": { "$ref": "#/$defs/Listener" }, "type": "array" }, { "type": "null" } ], "title": "Listeners" } }, "$defs": { "Action": { "description": "Information about an action.\n\nEach rule must include exactly one of the following routing actions: ``forward``, ``fixed-response``, or ``redirect``,\nand it must be the last action to be performed.\n\nOptionally, a rule for an HTTPS listener can also include one of the following user authentication actions:\n``authenticate-oidc``, ``authenticate-cognito``, or ``jwt-validation``.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Type": { "default": null, "enum": [ "forward", "authenticate-oidc", "authenticate-cognito", "redirect", "fixed-response", "jwt-validation" ], "title": "Type", "type": "string" }, "TargetGroupArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Targetgrouparn" }, "AuthenticateOidcConfig": { "anyOf": [ { "$ref": "#/$defs/AuthenticateOidcActionConfig" }, { "type": "null" } ], "default": null }, "AuthenticateCognitoConfig": { "anyOf": [ { "$ref": "#/$defs/AuthenticateCognitoActionConfig" }, { "type": "null" } ], "default": null }, "Order": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Order" }, "RedirectConfig": { "anyOf": [ { "$ref": "#/$defs/RedirectActionConfig" }, { "type": "null" } ], "default": null }, "FixedResponseConfig": { "anyOf": [ { "$ref": "#/$defs/FixedResponseActionConfig" }, { "type": "null" } ], "default": null }, "ForwardConfig": { "anyOf": [ { "$ref": "#/$defs/ForwardActionConfig" }, { "type": "null" } ], "default": null }, "JwtValidationConfig": { "anyOf": [ { "$ref": "#/$defs/JwtValidationActionConfig" }, { "type": "null" } ], "default": null } }, "title": "Action", "type": "object" }, "AuthenticateCognitoActionConfig": { "description": "Request parameters to use when integrating with Amazon Cognito to authenticate\nusers.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "UserPoolArn": { "title": "Userpoolarn", "type": "string" }, "UserPoolClientId": { "title": "Userpoolclientid", "type": "string" }, "UserPoolDomain": { "title": "Userpooldomain", "type": "string" }, "SessionCookieName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Sessioncookiename" }, "Scope": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Scope" }, "SessionTimeout": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Sessiontimeout" }, "AuthenticationRequestExtraParams": { "anyOf": [ { "additionalProperties": { "type": "string" }, "type": "object" }, { "type": "null" } ], "title": "Authenticationrequestextraparams" }, "OnUnauthenticatedRequest": { "anyOf": [ { "enum": [ "deny", "allow", "authenticate" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Onunauthenticatedrequest" } }, "required": [ "UserPoolArn", "UserPoolClientId", "UserPoolDomain" ], "title": "AuthenticateCognitoActionConfig", "type": "object" }, "AuthenticateOidcActionConfig": { "description": "Request parameters when using an identity provider (IdP) that is compliant with\nOpenID Connect (OIDC) to authenticate users.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Issuer": { "title": "Issuer", "type": "string" }, "AuthorizationEndpoint": { "title": "Authorizationendpoint", "type": "string" }, "TokenEndpoint": { "title": "Tokenendpoint", "type": "string" }, "UserInfoEndpoint": { "title": "Userinfoendpoint", "type": "string" }, "ClientId": { "title": "Clientid", "type": "string" }, "ClientSecret": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Clientsecret" }, "SessionCookieName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Sessioncookiename" }, "Scope": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Scope" }, "SessionTimeout": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Sessiontimeout" }, "AuthenticationRequestExtraParams": { "anyOf": [ { "additionalProperties": { "type": "string" }, "type": "object" }, { "type": "null" } ], "title": "Authenticationrequestextraparams" }, "OnUnauthenticatedRequest": { "anyOf": [ { "enum": [ "deny", "allow", "authenticate" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Onunauthenticatedrequest" }, "UseExistingClientSecret": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Useexistingclientsecret" } }, "required": [ "Issuer", "AuthorizationEndpoint", "TokenEndpoint", "UserInfoEndpoint", "ClientId" ], "title": "AuthenticateOidcActionConfig", "type": "object" }, "Certificate": { "additionalProperties": true, "description": "Information about an SSL server certificate.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "CertificateArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Certificatearn" }, "IsDefault": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Isdefault" } }, "title": "Certificate", "type": "object" }, "ElbV2TargetGroupStickinessConfig": { "description": "Information about the target group stickiness for a rule.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Enabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Enabled" }, "DurationSeconds": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Durationseconds" } }, "title": "ElbV2TargetGroupStickinessConfig", "type": "object" }, "FixedResponseActionConfig": { "description": "Information about an action that returns a custom HTTP response.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "MessageBody": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Messagebody" }, "StatusCode": { "title": "Statuscode", "type": "string" }, "ContentType": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Contenttype" } }, "required": [ "StatusCode" ], "title": "FixedResponseActionConfig", "type": "object" }, "ForwardActionConfig": { "description": "Information about a forward action.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroups": { "anyOf": [ { "items": { "$ref": "#/$defs/TargetGroupTuple" }, "type": "array" }, { "type": "null" } ], "title": "Targetgroups" }, "TargetGroupStickinessConfig": { "anyOf": [ { "$ref": "#/$defs/ElbV2TargetGroupStickinessConfig" }, { "type": "null" } ], "default": null } }, "title": "ForwardActionConfig", "type": "object" }, "JwtValidationActionAdditionalClaim": { "description": "Information about an additional claim to validate.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Format": { "enum": [ "single-string", "string-array", "space-separated-values" ], "title": "Format", "type": "string" }, "Name": { "title": "Name", "type": "string" }, "Values": { "items": { "type": "string" }, "title": "Values", "type": "array" } }, "required": [ "Format", "Name", "Values" ], "title": "JwtValidationActionAdditionalClaim", "type": "object" }, "JwtValidationActionConfig": { "description": "Information about a JSON Web Token (JWT) validation action.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "JwksEndpoint": { "title": "Jwksendpoint", "type": "string" }, "Issuer": { "title": "Issuer", "type": "string" }, "AdditionalClaims": { "anyOf": [ { "items": { "$ref": "#/$defs/JwtValidationActionAdditionalClaim" }, "type": "array" }, { "type": "null" } ], "title": "Additionalclaims" } }, "required": [ "JwksEndpoint", "Issuer" ], "title": "JwtValidationActionConfig", "type": "object" }, "Listener": { "description": "Information about a listener.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "LoadBalancerArn": { "title": "Loadbalancerarn", "type": "string" }, "Port": { "title": "Port", "type": "integer" }, "Protocol": { "anyOf": [ { "enum": [ "HTTP", "HTTPS", "TCP", "TLS", "UDP", "TCP_UDP", "GENEVE", "QUIC", "TCP_QUIC" ], "type": "string" }, { "type": "null" } ], "default": "HTTPS", "title": "Protocol" }, "ListenerArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Listenerarn" }, "Certificates": { "anyOf": [ { "items": { "$ref": "#/$defs/Certificate" }, "type": "array" }, { "type": "null" } ], "title": "Certificates" }, "SslPolicy": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Sslpolicy" }, "DefaultActions": { "anyOf": [ { "items": { "$ref": "#/$defs/Action" }, "type": "array" }, { "type": "null" } ], "title": "Defaultactions" }, "AlpnPolicy": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Alpnpolicy" }, "MutualAuthentication": { "anyOf": [ { "$ref": "#/$defs/MutualAuthenticationAttributes" }, { "type": "null" } ], "default": null } }, "required": [ "LoadBalancerArn", "Port" ], "title": "Listener", "type": "object" }, "MutualAuthenticationAttributes": { "description": "Information about the mutual authentication attributes of a listener.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Mode": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Mode" }, "TrustStoreArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Truststorearn" }, "IgnoreClientCertificateExpiry": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Ignoreclientcertificateexpiry" }, "TrustStoreAssociationStatus": { "anyOf": [ { "enum": [ "active", "removed" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Truststoreassociationstatus" }, "AdvertiseTrustStoreCaNames": { "anyOf": [ { "enum": [ "on", "off" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Advertisetruststorecanames" } }, "title": "MutualAuthenticationAttributes", "type": "object" }, "RedirectActionConfig": { "description": "Information about a redirect action.\n\nA URI consists of the following components: protocol://hostname:port/path?query. You must modify at least one of the\nfollowing components to avoid a redirect loop: protocol, hostname, port, or path. Any components that you do not modify\nretain their original values.\n\nYou can reuse URI components using the following reserved keywords:\n\n* #{protocol}\n* #{host}\n* #{port}\n* #{path} (the leading \"/\" is removed)\n* #{query}\n\nFor example, you can change the path to \"/new/#{path}\", the hostname to \"example.#{host}\", or the query to\n\"#{query}&value=xyz\".", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Protocol": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Protocol" }, "Port": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Port" }, "Host": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Host" }, "Path": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Path" }, "Query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Query" }, "StatusCode": { "enum": [ "HTTP_301", "HTTP_302" ], "title": "Statuscode", "type": "string" } }, "required": [ "StatusCode" ], "title": "RedirectActionConfig", "type": "object" }, "TargetGroupTuple": { "description": "Information about how traffic will be distributed between multiple target groups in\na forward rule.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroupArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Targetgrouparn" }, "Weight": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Weight" } }, "title": "TargetGroupTuple", "type": "object" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field Listeners: builtins.list[Listener] | None [Optional]
Information about the modified listener.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.ModifyRuleOutput[source]
Bases:
Boto3ModelShow JSON schema
{ "title": "ModifyRuleOutput", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Rules": { "anyOf": [ { "items": { "$ref": "#/$defs/Rule" }, "type": "array" }, { "type": "null" } ], "title": "Rules" } }, "$defs": { "Action": { "description": "Information about an action.\n\nEach rule must include exactly one of the following routing actions: ``forward``, ``fixed-response``, or ``redirect``,\nand it must be the last action to be performed.\n\nOptionally, a rule for an HTTPS listener can also include one of the following user authentication actions:\n``authenticate-oidc``, ``authenticate-cognito``, or ``jwt-validation``.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Type": { "default": null, "enum": [ "forward", "authenticate-oidc", "authenticate-cognito", "redirect", "fixed-response", "jwt-validation" ], "title": "Type", "type": "string" }, "TargetGroupArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Targetgrouparn" }, "AuthenticateOidcConfig": { "anyOf": [ { "$ref": "#/$defs/AuthenticateOidcActionConfig" }, { "type": "null" } ], "default": null }, "AuthenticateCognitoConfig": { "anyOf": [ { "$ref": "#/$defs/AuthenticateCognitoActionConfig" }, { "type": "null" } ], "default": null }, "Order": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Order" }, "RedirectConfig": { "anyOf": [ { "$ref": "#/$defs/RedirectActionConfig" }, { "type": "null" } ], "default": null }, "FixedResponseConfig": { "anyOf": [ { "$ref": "#/$defs/FixedResponseActionConfig" }, { "type": "null" } ], "default": null }, "ForwardConfig": { "anyOf": [ { "$ref": "#/$defs/ForwardActionConfig" }, { "type": "null" } ], "default": null }, "JwtValidationConfig": { "anyOf": [ { "$ref": "#/$defs/JwtValidationActionConfig" }, { "type": "null" } ], "default": null } }, "title": "Action", "type": "object" }, "AuthenticateCognitoActionConfig": { "description": "Request parameters to use when integrating with Amazon Cognito to authenticate\nusers.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "UserPoolArn": { "title": "Userpoolarn", "type": "string" }, "UserPoolClientId": { "title": "Userpoolclientid", "type": "string" }, "UserPoolDomain": { "title": "Userpooldomain", "type": "string" }, "SessionCookieName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Sessioncookiename" }, "Scope": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Scope" }, "SessionTimeout": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Sessiontimeout" }, "AuthenticationRequestExtraParams": { "anyOf": [ { "additionalProperties": { "type": "string" }, "type": "object" }, { "type": "null" } ], "title": "Authenticationrequestextraparams" }, "OnUnauthenticatedRequest": { "anyOf": [ { "enum": [ "deny", "allow", "authenticate" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Onunauthenticatedrequest" } }, "required": [ "UserPoolArn", "UserPoolClientId", "UserPoolDomain" ], "title": "AuthenticateCognitoActionConfig", "type": "object" }, "AuthenticateOidcActionConfig": { "description": "Request parameters when using an identity provider (IdP) that is compliant with\nOpenID Connect (OIDC) to authenticate users.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Issuer": { "title": "Issuer", "type": "string" }, "AuthorizationEndpoint": { "title": "Authorizationendpoint", "type": "string" }, "TokenEndpoint": { "title": "Tokenendpoint", "type": "string" }, "UserInfoEndpoint": { "title": "Userinfoendpoint", "type": "string" }, "ClientId": { "title": "Clientid", "type": "string" }, "ClientSecret": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Clientsecret" }, "SessionCookieName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Sessioncookiename" }, "Scope": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Scope" }, "SessionTimeout": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Sessiontimeout" }, "AuthenticationRequestExtraParams": { "anyOf": [ { "additionalProperties": { "type": "string" }, "type": "object" }, { "type": "null" } ], "title": "Authenticationrequestextraparams" }, "OnUnauthenticatedRequest": { "anyOf": [ { "enum": [ "deny", "allow", "authenticate" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Onunauthenticatedrequest" }, "UseExistingClientSecret": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Useexistingclientsecret" } }, "required": [ "Issuer", "AuthorizationEndpoint", "TokenEndpoint", "UserInfoEndpoint", "ClientId" ], "title": "AuthenticateOidcActionConfig", "type": "object" }, "ElbV2HostHeaderRewriteConfig": { "description": "Information about a host header rewrite transform.\n\nThis transform matches a pattern in the host header in an HTTP request and replaces\nit with the specified string.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Rewrites": { "anyOf": [ { "items": { "$ref": "#/$defs/RewriteConfig" }, "type": "array" }, { "type": "null" } ], "title": "Rewrites" } }, "title": "ElbV2HostHeaderRewriteConfig", "type": "object" }, "ElbV2TargetGroupStickinessConfig": { "description": "Information about the target group stickiness for a rule.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Enabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Enabled" }, "DurationSeconds": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Durationseconds" } }, "title": "ElbV2TargetGroupStickinessConfig", "type": "object" }, "ElbV2UrlRewriteConfig": { "description": "Information about a URL rewrite transform.\n\nThis transform matches a pattern in the request URL and replaces it with the\nspecified string.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Rewrites": { "anyOf": [ { "items": { "$ref": "#/$defs/RewriteConfig" }, "type": "array" }, { "type": "null" } ], "title": "Rewrites" } }, "title": "ElbV2UrlRewriteConfig", "type": "object" }, "FixedResponseActionConfig": { "description": "Information about an action that returns a custom HTTP response.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "MessageBody": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Messagebody" }, "StatusCode": { "title": "Statuscode", "type": "string" }, "ContentType": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Contenttype" } }, "required": [ "StatusCode" ], "title": "FixedResponseActionConfig", "type": "object" }, "ForwardActionConfig": { "description": "Information about a forward action.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroups": { "anyOf": [ { "items": { "$ref": "#/$defs/TargetGroupTuple" }, "type": "array" }, { "type": "null" } ], "title": "Targetgroups" }, "TargetGroupStickinessConfig": { "anyOf": [ { "$ref": "#/$defs/ElbV2TargetGroupStickinessConfig" }, { "type": "null" } ], "default": null } }, "title": "ForwardActionConfig", "type": "object" }, "HostHeaderConditionConfig": { "description": "Information about a host header condition.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" }, "RegexValues": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Regexvalues" } }, "title": "HostHeaderConditionConfig", "type": "object" }, "HttpHeaderConditionConfig": { "description": "Information about an HTTP header condition.\n\nThere is a set of standard HTTP header fields. You can also define custom HTTP\nheader fields.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "HttpHeaderName": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Httpheadername" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" }, "RegexValues": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Regexvalues" } }, "title": "HttpHeaderConditionConfig", "type": "object" }, "HttpRequestMethodConditionConfig": { "description": "Information about an HTTP method condition.\n\nHTTP defines a set of request methods, also referred to as HTTP verbs. For more\ninformation, see the\n`HTTP Method Registry <https://www.iana.org/assignments/http-methods/http-methods.xhtml>`_.\nYou can also define custom HTTP methods.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" } }, "title": "HttpRequestMethodConditionConfig", "type": "object" }, "JwtValidationActionAdditionalClaim": { "description": "Information about an additional claim to validate.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Format": { "enum": [ "single-string", "string-array", "space-separated-values" ], "title": "Format", "type": "string" }, "Name": { "title": "Name", "type": "string" }, "Values": { "items": { "type": "string" }, "title": "Values", "type": "array" } }, "required": [ "Format", "Name", "Values" ], "title": "JwtValidationActionAdditionalClaim", "type": "object" }, "JwtValidationActionConfig": { "description": "Information about a JSON Web Token (JWT) validation action.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "JwksEndpoint": { "title": "Jwksendpoint", "type": "string" }, "Issuer": { "title": "Issuer", "type": "string" }, "AdditionalClaims": { "anyOf": [ { "items": { "$ref": "#/$defs/JwtValidationActionAdditionalClaim" }, "type": "array" }, { "type": "null" } ], "title": "Additionalclaims" } }, "required": [ "JwksEndpoint", "Issuer" ], "title": "JwtValidationActionConfig", "type": "object" }, "PathPatternConditionConfig": { "description": "Information about a path pattern condition.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" }, "RegexValues": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Regexvalues" } }, "title": "PathPatternConditionConfig", "type": "object" }, "QueryStringConditionConfig": { "description": "Information about a query string condition.\n\nThe query string component of a URI starts after the first '?' character and is\nterminated by either a '#' character or the end of the URI. A typical query string\ncontains key/value pairs separated by '&' characters. The allowed characters are\nspecified by RFC 3986. Any character can be percentage encoded.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "$ref": "#/$defs/QueryStringKeyValuePair" }, "type": "array" }, { "type": "null" } ], "title": "Values" } }, "title": "QueryStringConditionConfig", "type": "object" }, "QueryStringKeyValuePair": { "description": "Information about a key/value pair.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Key": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Key" }, "Value": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Value" } }, "title": "QueryStringKeyValuePair", "type": "object" }, "RedirectActionConfig": { "description": "Information about a redirect action.\n\nA URI consists of the following components: protocol://hostname:port/path?query. You must modify at least one of the\nfollowing components to avoid a redirect loop: protocol, hostname, port, or path. Any components that you do not modify\nretain their original values.\n\nYou can reuse URI components using the following reserved keywords:\n\n* #{protocol}\n* #{host}\n* #{port}\n* #{path} (the leading \"/\" is removed)\n* #{query}\n\nFor example, you can change the path to \"/new/#{path}\", the hostname to \"example.#{host}\", or the query to\n\"#{query}&value=xyz\".", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Protocol": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Protocol" }, "Port": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Port" }, "Host": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Host" }, "Path": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Path" }, "Query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Query" }, "StatusCode": { "enum": [ "HTTP_301", "HTTP_302" ], "title": "Statuscode", "type": "string" } }, "required": [ "StatusCode" ], "title": "RedirectActionConfig", "type": "object" }, "RewriteConfig": { "description": "Information about a rewrite transform.\n\nThis transform matches a pattern and replaces it with the specified string.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Regex": { "title": "Regex", "type": "string" }, "Replace": { "title": "Replace", "type": "string" } }, "required": [ "Regex", "Replace" ], "title": "RewriteConfig", "type": "object" }, "Rule": { "description": "Information about a rule.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Priority": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "1", "title": "Priority" }, "Conditions": { "items": { "$ref": "#/$defs/RuleCondition" }, "title": "Conditions", "type": "array" }, "Actions": { "items": { "$ref": "#/$defs/Action" }, "title": "Actions", "type": "array" }, "IsDefault": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Isdefault" }, "RuleArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Rulearn" }, "Transforms": { "anyOf": [ { "items": { "$ref": "#/$defs/RuleTransform" }, "type": "array" }, { "type": "null" } ], "title": "Transforms" } }, "required": [ "Conditions", "Actions" ], "title": "Rule", "type": "object" }, "RuleCondition": { "description": "Information about a condition for a rule.\n\nEach rule can optionally include up to one of each of the following conditions: ``http-request-method``, ``host-\nheader``, ``path-pattern``, and ``source-ip``. Each rule can also optionally include one or more of each of the\nfollowing conditions: ``http-header`` and ``query-string``. Note that the value for a condition can't be empty.\n\nFor more information, see `Quotas for your Application Load\nBalancers <https://docs.aws.amazon.com/elasticloadbalancing/latest/application/load-balancer-limits.html>`_.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Field": { "default": null, "title": "Field", "type": "string" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" }, "HostHeaderConfig": { "anyOf": [ { "$ref": "#/$defs/HostHeaderConditionConfig" }, { "type": "null" } ], "default": null }, "PathPatternConfig": { "anyOf": [ { "$ref": "#/$defs/PathPatternConditionConfig" }, { "type": "null" } ], "default": null }, "HttpHeaderConfig": { "anyOf": [ { "$ref": "#/$defs/HttpHeaderConditionConfig" }, { "type": "null" } ], "default": null }, "QueryStringConfig": { "anyOf": [ { "$ref": "#/$defs/QueryStringConditionConfig" }, { "type": "null" } ], "default": null }, "HttpRequestMethodConfig": { "anyOf": [ { "$ref": "#/$defs/HttpRequestMethodConditionConfig" }, { "type": "null" } ], "default": null }, "SourceIpConfig": { "anyOf": [ { "$ref": "#/$defs/SourceIpConditionConfig" }, { "type": "null" } ], "default": null }, "RegexValues": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Regexvalues" } }, "title": "RuleCondition", "type": "object" }, "RuleTransform": { "description": "Information about a transform to apply to requests that match a rule.\n\nTransforms are applied to requests before they are sent to targets.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Type": { "enum": [ "host-header-rewrite", "url-rewrite" ], "title": "Type", "type": "string" }, "HostHeaderRewriteConfig": { "anyOf": [ { "$ref": "#/$defs/ElbV2HostHeaderRewriteConfig" }, { "type": "null" } ], "default": null }, "UrlRewriteConfig": { "anyOf": [ { "$ref": "#/$defs/ElbV2UrlRewriteConfig" }, { "type": "null" } ], "default": null } }, "required": [ "Type" ], "title": "RuleTransform", "type": "object" }, "SourceIpConditionConfig": { "description": "Information about a source IP condition.\n\nYou can use this condition to route based on the IP address of the source that\nconnects to the load balancer. If a client is behind a proxy, this is the IP address\nof the proxy not the IP address of the client.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Values": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Values" } }, "title": "SourceIpConditionConfig", "type": "object" }, "TargetGroupTuple": { "description": "Information about how traffic will be distributed between multiple target groups in\na forward rule.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroupArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Targetgrouparn" }, "Weight": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Weight" } }, "title": "TargetGroupTuple", "type": "object" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.ModifyTargetGroupOutput[source]
Bases:
Boto3ModelShow JSON schema
{ "title": "ModifyTargetGroupOutput", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroups": { "anyOf": [ { "items": { "$ref": "#/$defs/TargetGroup" }, "type": "array" }, { "type": "null" } ], "title": "Targetgroups" } }, "$defs": { "ResponseCodeMatcher": { "description": "The codes to use when checking for a successful response from a target.\n\nIf the protocol version is gRPC, these are gRPC codes. Otherwise, these are HTTP\ncodes.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "HttpCode": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Httpcode" }, "GrpcCode": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Grpccode" } }, "title": "ResponseCodeMatcher", "type": "object" }, "TargetGroup": { "description": "Information about a target group.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "TargetGroupName": { "title": "Targetgroupname", "type": "string" }, "Protocol": { "anyOf": [ { "enum": [ "HTTP", "HTTPS", "TCP", "TLS", "UDP", "TCP_UDP", "GENEVE", "QUIC", "TCP_QUIC" ], "type": "string" }, { "type": "null" } ], "default": "HTTPS", "title": "Protocol" }, "Port": { "title": "Port", "type": "integer" }, "VpcId": { "title": "Vpcid", "type": "string" }, "TargetType": { "anyOf": [ { "enum": [ "instance", "ip", "lambda", "alb" ], "type": "string" }, { "type": "null" } ], "default": "ip", "title": "Targettype" }, "IpAddressType": { "anyOf": [ { "enum": [ "ipv4", "ipv6" ], "type": "string" }, { "type": "null" } ], "default": "ipv4", "title": "Ipaddresstype" }, "TargetGroupArn": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Targetgrouparn" }, "HealthCheckProtocol": { "anyOf": [ { "enum": [ "HTTP", "HTTPS", "TCP", "TLS", "UDP", "TCP_UDP", "GENEVE", "QUIC", "TCP_QUIC" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Healthcheckprotocol" }, "HealthCheckPort": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Healthcheckport" }, "HealthCheckEnabled": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "title": "Healthcheckenabled" }, "HealthCheckIntervalSeconds": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Healthcheckintervalseconds" }, "HealthCheckTimeoutSeconds": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Healthchecktimeoutseconds" }, "HealthyThresholdCount": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Healthythresholdcount" }, "UnhealthyThresholdCount": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Unhealthythresholdcount" }, "HealthCheckPath": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Healthcheckpath" }, "Matcher": { "anyOf": [ { "$ref": "#/$defs/ResponseCodeMatcher" }, { "type": "null" } ], "default": null }, "LoadBalancerArns": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Loadbalancerarns" }, "ProtocolVersion": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Protocolversion" }, "TargetControlPort": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Targetcontrolport" } }, "required": [ "TargetGroupName", "Port", "VpcId" ], "title": "TargetGroup", "type": "object" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field TargetGroups: builtins.list[TargetGroup] | None [Optional]
Information about the modified target group.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.SubnetMapping[source]
Bases:
Boto3ModelInformation about a subnet mapping.
Show JSON schema
{ "title": "SubnetMapping", "description": "Information about a subnet mapping.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "SubnetId": { "title": "Subnetid", "type": "string" }, "AllocationId": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Allocationid" }, "PrivateIPv4Address": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Privateipv4Address" }, "IPv6Address": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Ipv6Address" }, "SourceNatIpv6Prefix": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Sourcenatipv6Prefix" } }, "required": [ "SubnetId" ] }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field AllocationId: str | None = None
[Network Load Balancers] The allocation ID of the Elastic IP address for an internet-facing load balancer.
- field PrivateIPv4Address: str | None = None
[Network Load Balancers] The private IPv4 address for an internal load balancer.
- field SourceNatIpv6Prefix: str | None = None
[Network Load Balancers with UDP listeners] The IPv6 prefix to use for source NAT.
Specify an IPv6 prefix (/80 netmask) from the subnet CIDR block or
auto_assignedto use an IPv6 prefix selected at random from the subnet CIDR block.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.TargetHealthDescription[source]
Bases:
Boto3ModelInformation about the health of a target.
Show JSON schema
{ "title": "TargetHealthDescription", "description": "Information about the health of a target.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Target": { "anyOf": [ { "$ref": "#/$defs/TargetDescription" }, { "type": "null" } ], "default": null }, "HealthCheckPort": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Healthcheckport" }, "TargetHealth": { "anyOf": [ { "$ref": "#/$defs/TargetHealthInfo" }, { "type": "null" } ], "default": null }, "AnomalyDetection": { "anyOf": [ { "$ref": "#/$defs/AnomalyDetectionInfo" }, { "type": "null" } ], "default": null }, "AdministrativeOverride": { "anyOf": [ { "$ref": "#/$defs/ElbV2AdministrativeOverride" }, { "type": "null" } ], "default": null } }, "$defs": { "AnomalyDetectionInfo": { "description": "Information about anomaly detection and mitigation.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Result": { "anyOf": [ { "enum": [ "anomalous", "normal" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Result" }, "MitigationInEffect": { "anyOf": [ { "enum": [ "yes", "no" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Mitigationineffect" } }, "title": "AnomalyDetectionInfo", "type": "object" }, "ElbV2AdministrativeOverride": { "description": "Information about the override status applied to a target.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "State": { "anyOf": [ { "enum": [ "unknown", "no_override", "zonal_shift_active", "zonal_shift_delegated_to_dns" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "State" }, "Reason": { "anyOf": [ { "enum": [ "AdministrativeOverride.Unknown", "AdministrativeOverride.NoOverride", "AdministrativeOverride.ZonalShiftActive", "AdministrativeOverride.ZonalShiftDelegatedToDns" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Reason" }, "Description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" } }, "title": "ElbV2AdministrativeOverride", "type": "object" }, "TargetDescription": { "description": "Information about a target.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "Id": { "title": "Id", "type": "string" }, "Port": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Port" }, "AvailabilityZone": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Availabilityzone" }, "QuicServerId": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Quicserverid" } }, "required": [ "Id" ], "title": "TargetDescription", "type": "object" }, "TargetHealthInfo": { "description": "Information about the current health of a target.", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "State": { "anyOf": [ { "enum": [ "initial", "healthy", "unhealthy", "unhealthy.draining", "unused", "draining", "unavailable" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "State" }, "Reason": { "anyOf": [ { "enum": [ "Elb.RegistrationInProgress", "Elb.InitialHealthChecking", "Target.ResponseCodeMismatch", "Target.Timeout", "Target.FailedHealthChecks", "Target.NotRegistered", "Target.NotInUse", "Target.DeregistrationInProgress", "Target.InvalidState", "Target.IpUnusable", "Target.HealthCheckDisabled", "Elb.InternalError" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Reason" }, "Description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" } }, "title": "TargetHealthInfo", "type": "object" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field AdministrativeOverride: ElbV2AdministrativeOverride | None = None
The administrative override information for the target.
- field AnomalyDetection: AnomalyDetectionInfo | None = None
The anomaly detection result for the target.
- field Target: TargetDescription | None = None
The description of the target.
- field TargetHealth: TargetHealthInfo | None = None
The health information for the target.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.
- pydantic model botocraft.services.elbv2.TargetHealthInfo[source]
Bases:
Boto3ModelInformation about the current health of a target.
Show JSON schema
{ "title": "TargetHealthInfo", "description": "Information about the current health of a target.", "type": "object", "properties": { "session": { "anyOf": [ {}, { "type": "null" } ], "default": null, "title": "Session" }, "State": { "anyOf": [ { "enum": [ "initial", "healthy", "unhealthy", "unhealthy.draining", "unused", "draining", "unavailable" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "State" }, "Reason": { "anyOf": [ { "enum": [ "Elb.RegistrationInProgress", "Elb.InitialHealthChecking", "Target.ResponseCodeMismatch", "Target.Timeout", "Target.FailedHealthChecks", "Target.NotRegistered", "Target.NotInUse", "Target.DeregistrationInProgress", "Target.InvalidState", "Target.IpUnusable", "Target.HealthCheckDisabled", "Elb.InternalError" ], "type": "string" }, { "type": "null" } ], "default": null, "title": "Reason" }, "Description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" } } }
- Config:
validate_assignment: bool = True
arbitrary_types_allowed: bool = True
- Fields:
- field Description: str | None = None
A description of the target health that provides additional details.
If the state is
healthy, a description is not provided.
- field Reason: Literal['Elb.RegistrationInProgress', 'Elb.InitialHealthChecking', 'Target.ResponseCodeMismatch', 'Target.Timeout', 'Target.FailedHealthChecks', 'Target.NotRegistered', 'Target.NotInUse', 'Target.DeregistrationInProgress', 'Target.InvalidState', 'Target.IpUnusable', 'Target.HealthCheckDisabled', 'Elb.InternalError'] | None = None
The reason code.
- field State: Literal['initial', 'healthy', 'unhealthy', 'unhealthy.draining', 'unused', 'draining', 'unavailable'] | None = None
The state of the target.
- field session: Any | None = None
The boto3 session to use for this model. This is set by the manager, and is used in relationships. We have to use
Anyhere because we pydantic complains vociferously if we useboto3.session.Session. We exclude it from the model dump because it’s not something that should be serialized.
- classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) Self
Creates a new instance of the Model class with validated data.
Creates a new model setting __dict__ and __pydantic_fields_set__ from trusted or pre-validated data. Default values are respected, but no other validation is performed.
- !!! note
model_construct() generally respects the model_config.extra setting on the provided model. That is, if model_config.extra == ‘allow’, then all extra passed values are added to the model instance’s __dict__ and __pydantic_extra__ fields. If model_config.extra == ‘ignore’ (the default), then all extra passed values are ignored. Because no validation is performed with a call to model_construct(), having model_config.extra == ‘forbid’ does not result in an error if extra values are passed, but they will be ignored.
- Parameters:
_fields_set – A set of field names that were originally explicitly set during instantiation. If provided, this is directly used for the [model_fields_set][pydantic.BaseModel.model_fields_set] attribute. Otherwise, the field names from the values argument will be used.
values – Trusted or pre-validated data dictionary.
- Returns:
A new instance of the Model class with validated data.
- classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) Self
Validate the given object with string data against the Pydantic model.
- Parameters:
obj – The object containing string data to validate.
strict – Whether to enforce types strictly.
context – Extra variables to pass to the validator.
by_alias – Whether to use the field’s alias when validating against the provided input data.
by_name – Whether to use the field’s name when validating against the provided input data.
- Returns:
The validated Pydantic model.
- set_session(session: Session) None
Set the boto3 session for this model.
- Parameters:
session – The boto3 session to use.
- Returns:
The model instance.
- transform(attribute: str, transformer: str | None) Any
Transform an attribute using a regular expression into something else before it is returned.
Important
This only makes sense for attributes that are strings.
transformeris a regular expression that will be used to transform the value of the attribute.If the attribute is
None, it will be returned verbatim.If
transformerisNone, the attribute will be returned verbatim.If
transformerhas no named groups, the attribute will be replaced with the value of the first group.If
transformerhas named groups, the attribute will be replaced with a dictionary of the named groups.
- Raises:
ValueError – If the attribute does not exist on the model.
RuntimeError – If the transformer fails to match the attribute value.
- Parameters:
attribute – The attribute to transform.
transformer – The regular expression to use to transform the attribute.
- Returns:
The transformed attribute.