scaleway.lb.v1 package

Submodules

scaleway.lb.v1.api module

class scaleway.lb.v1.api.LbV1API(client: Client, *, bypass_validation: bool = False)

Bases: API

This API allows you to manage your Load Balancers.

add_backend_servers(*, backend_id: str, server_ip: List[str], region: str | None = None) Backend

Add a set of servers in a given backend. :param backend_id: Backend ID. :param server_ip: List of IP addresses to add to backend servers. :param region: Region to target. If none is passed will use default region from the config. :return: Backend

Usage:

result = api.add_backend_servers(
    backend_id="example",
    server_ip=[],
)
attach_private_network(*, lb_id: str, private_network_id: str, region: str | None = None, static_config: PrivateNetworkStaticConfig | None = None, dhcp_config: PrivateNetworkDHCPConfig | None = None, ipam_config: PrivateNetworkIpamConfig | None = None, ipam_ids: List[str] | None = None) PrivateNetwork

Add load balancer on instance private network. :param lb_id: Load Balancer ID. :param private_network_id: Private Network ID. :param region: Region to target. If none is passed will use default region from the config. :param static_config: Object containing an array of a local IP address for the Load Balancer on this Private Network. One-Of (‘config’): at most one of ‘static_config’, ‘dhcp_config’, ‘ipam_config’ could be set. :param dhcp_config: Defines whether to let DHCP assign IP addresses. One-Of (‘config’): at most one of ‘static_config’, ‘dhcp_config’, ‘ipam_config’ could be set. :param ipam_config: For internal use only. One-Of (‘config’): at most one of ‘static_config’, ‘dhcp_config’, ‘ipam_config’ could be set. :param ipam_ids: IPAM ID of a pre-reserved IP address to assign to the Load Balancer on this Private Network. In the future, it will be possible to specify multiple IPs in this field (IPv4 and IPv6), for now only one ID of an IPv4 address is expected. When null, a new private IP address is created for the Load Balancer on this Private Network. :return: PrivateNetwork

Usage:

result = api.attach_private_network(
    lb_id="example",
    private_network_id="example",
)
create_acl(*, frontend_id: str, action: AclAction, index: int, description: str, region: str | None = None, name: str | None = None, match: AclMatch | None = None) Acl

Create an ACL for a given frontend. :param frontend_id: Frontend ID to attach the ACL to. :param action: Action to take when incoming traffic matches an ACL filter. :param index: Priority of this ACL (ACLs are applied in ascending order, 0 is the first ACL executed). :param description: ACL description. :param region: Region to target. If none is passed will use default region from the config. :param name: ACL name. :param match: ACL match filter object. One of ip_subnet, ips_edge_services or http_filter & http_filter_value are required. :return: Acl

Usage:

result = api.create_acl(
    frontend_id="example",
    action=AclAction(),
    index=1,
    description="example",
)
create_backend(*, forward_protocol: Protocol, forward_port: int, forward_port_algorithm: ForwardPortAlgorithm, sticky_sessions: StickySessionsType, sticky_sessions_cookie_name: str, lb_id: str, health_check: HealthCheck, server_ip: List[str], region: str | None = None, name: str | None = None, send_proxy_v2: bool | None = None, timeout_server: str | None = None, timeout_connect: str | None = None, timeout_tunnel: str | None = None, on_marked_down_action: OnMarkedDownAction | None = None, proxy_protocol: ProxyProtocol | None = None, failover_host: str | None = None, ssl_bridging: bool | None = None, ignore_ssl_server_verify: bool | None = None, redispatch_attempt_count: int | None = None, max_retries: int | None = None, max_connections: int | None = None, timeout_queue: str | None = None) Backend

Create a backend in a given load balancer. :param forward_protocol: Protocol to be used by the backend when forwarding traffic to backend servers. :param forward_port: Port to be used by the backend when forwarding traffic to backend servers. :param forward_port_algorithm: Load balancing algorithm to be used when determining which backend server to forward new traffic to. :param sticky_sessions: Defines whether to activate sticky sessions (binding a particular session to a particular backend server) and the method to use if so. None disables sticky sessions. Cookie-based uses an HTTP cookie TO stick a session to a backend server. Table-based uses the source (client) IP address to stick a session to a backend server. :param sticky_sessions_cookie_name: Cookie name for cookie-based sticky sessions. :param lb_id: Load Balancer ID. :param health_check: Object defining the health check to be carried out by the backend when checking the status and health of backend servers. :param server_ip: List of backend server IP addresses (IPv4 or IPv6) the backend should forward traffic to. :param region: Region to target. If none is passed will use default region from the config. :param name: Name for the backend. :param send_proxy_v2: Deprecated in favor of proxy_protocol field. :param timeout_server: Maximum allowed time for a backend server to process a request. :param timeout_connect: Maximum allowed time for establishing a connection to a backend server. :param timeout_tunnel: Maximum allowed tunnel inactivity time after Websocket is established (takes precedence over client and server timeout). :param on_marked_down_action: Action to take when a backend server is marked as down. :param proxy_protocol: Protocol to use between the Load Balancer and backend servers. Allows the backend servers to be informed of the client’s real IP address. The PROXY protocol must be supported by the backend servers’ software. :param failover_host: Scaleway Object Storage bucket website to be served as failover if all backend servers are down, e.g. failover-website.s3-website.fr-par.scw.cloud. :param ssl_bridging: Defines whether to enable SSL bridging between the Load Balancer and backend servers. :param ignore_ssl_server_verify: Defines whether the server certificate verification should be ignored. :param redispatch_attempt_count: Whether to use another backend server on each attempt. :param max_retries: Number of retries when a backend server connection failed. :param max_connections: Maximum number of connections allowed per backend server. :param timeout_queue: Maximum time for a request to be left pending in queue when max_connections is reached. :return: Backend

Usage:

result = api.create_backend(
    forward_protocol=Protocol.tcp,
    forward_port=1,
    forward_port_algorithm=ForwardPortAlgorithm.roundrobin,
    sticky_sessions=StickySessionsType.none,
    sticky_sessions_cookie_name="example",
    lb_id="example",
    health_check=HealthCheck(),
    server_ip=[],
)
create_certificate(*, lb_id: str, region: str | None = None, name: str | None = None, letsencrypt: CreateCertificateRequestLetsencryptConfig | None = None, custom_certificate: CreateCertificateRequestCustomCertificate | None = None) Certificate

Create a TLS certificate. Generate a new TLS certificate using Let’s Encrypt or import your certificate. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :param name: Name for the certificate. :param letsencrypt: Object to define a new Let’s Encrypt certificate to be generated. One-Of (‘type’): at most one of ‘letsencrypt’, ‘custom_certificate’ could be set. :param custom_certificate: Object to define an existing custom certificate to be imported. One-Of (‘type’): at most one of ‘letsencrypt’, ‘custom_certificate’ could be set. :return: Certificate

Usage:

result = api.create_certificate(
    lb_id="example",
)
create_frontend(*, inbound_port: int, lb_id: str, backend_id: str, enable_http3: bool, enable_access_logs: bool, region: str | None = None, name: str | None = None, timeout_client: str | None = None, certificate_id: str | None = None, certificate_ids: List[str] | None = None, connection_rate_limit: int | None = None) Frontend

Create a frontend in a given load balancer. :param inbound_port: Port the frontend should listen on. :param lb_id: Load Balancer ID (ID of the Load Balancer to attach the frontend to). :param backend_id: Backend ID (ID of the backend the frontend should pass traffic to). :param enable_http3: Defines whether to enable HTTP/3 protocol on the frontend. :param enable_access_logs: Defines whether to enable access logs on the frontend. :param region: Region to target. If none is passed will use default region from the config. :param name: Name for the frontend. :param timeout_client: Maximum allowed inactivity time on the client side. :param certificate_id: Certificate ID, deprecated in favor of certificate_ids array. :param certificate_ids: List of SSL/TLS certificate IDs to bind to the frontend. :param connection_rate_limit: Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. :return: Frontend

Usage:

result = api.create_frontend(
    inbound_port=1,
    lb_id="example",
    backend_id="example",
    enable_http3=False,
    enable_access_logs=False,
)
create_ip(*, is_ipv6: bool, region: str | None = None, organization_id: str | None = None, project_id: str | None = None, reverse: str | None = None, tags: List[str] | None = None) Ip

Create an IP. :param is_ipv6: If true, creates a Flexible IP with an ipv6 address. :param region: Region to target. If none is passed will use default region from the config. :param organization_id: Organization ID of the Organization where the IP address should be created. One-Of (‘project_identifier’): at most one of ‘project_id’, ‘organization_id’ could be set. :param project_id: Project ID of the Project where the IP address should be created. One-Of (‘project_identifier’): at most one of ‘project_id’, ‘organization_id’ could be set. :param reverse: Reverse DNS (domain name) for the IP address. :param tags: List of tags for the IP. :return: Ip

Usage:

result = api.create_ip(
    is_ipv6=False,
)
create_lb(*, description: str, type_: str, region: str | None = None, organization_id: str | None = None, project_id: str | None = None, name: str | None = None, ip_id: str | None = None, assign_flexible_ip: bool | None = None, assign_flexible_ipv6: bool | None = None, ip_ids: List[str] | None = None, tags: List[str] | None = None, ssl_compatibility_level: SSLCompatibilityLevel | None = None) Lb

Create a load balancer. :param description: Description for the Load Balancer. :param type_: Load Balancer commercial offer type. Use the Load Balancer types endpoint to retrieve a list of available offer types. :param region: Region to target. If none is passed will use default region from the config. :param organization_id: Scaleway Organization to create the Load Balancer in. One-Of (‘project_identifier’): at most one of ‘project_id’, ‘organization_id’ could be set. :param project_id: Scaleway Project to create the Load Balancer in. One-Of (‘project_identifier’): at most one of ‘project_id’, ‘organization_id’ could be set. :param name: Name for the Load Balancer. :param ip_id: ID of an existing flexible IP address to attach to the Load Balancer. :param assign_flexible_ip: Defines whether to automatically assign a flexible public IP to the Load Balancer. Default value is true (assign). :param assign_flexible_ipv6: Defines whether to automatically assign a flexible public IPv6 to the Load Balancer. Default value is false (do not assign). :param ip_ids: List of IP IDs to attach to the Load Balancer. :param tags: List of tags for the Load Balancer. :param ssl_compatibility_level: Determines the minimal SSL version which needs to be supported on the client side, in an SSL/TLS offloading context. Intermediate is suitable for general-purpose servers with a variety of clients, recommended for almost all systems. Modern is suitable for services with clients that support TLS 1.3 and do not need backward compatibility. Old is compatible with a small number of very old clients and should be used only as a last resort. :return: Lb

Usage:

result = api.create_lb(
    description="example",
    type="example",
)
create_route(*, frontend_id: str, backend_id: str, region: str | None = None, match: RouteMatch | None = None) Route

Create a backend redirection. :param frontend_id: ID of the source frontend to create the route on. :param backend_id: ID of the target backend for the route. :param region: Region to target. If none is passed will use default region from the config. :param match: Object defining the match condition for a route to be applied. If an incoming client session matches the specified condition (i.e. it has a matching SNI value or HTTP Host header value), it will be passed to the target backend. :return: Route

Usage:

result = api.create_route(
    frontend_id="example",
    backend_id="example",
)
create_subscriber(*, name: str, region: str | None = None, email_config: SubscriberEmailConfig | None = None, webhook_config: SubscriberWebhookConfig | None = None, organization_id: str | None = None, project_id: str | None = None) Subscriber

Create a subscriber, webhook or email. :param name: Subscriber name. :param region: Region to target. If none is passed will use default region from the config. :param email_config: Email address configuration. One-Of (‘config’): at most one of ‘email_config’, ‘webhook_config’ could be set. :param webhook_config: WebHook URI configuration. One-Of (‘config’): at most one of ‘email_config’, ‘webhook_config’ could be set. :param organization_id: Organization ID to create the subscriber in. One-Of (‘project_identifier’): at most one of ‘project_id’, ‘organization_id’ could be set. :param project_id: Project ID to create the subscriber in. One-Of (‘project_identifier’): at most one of ‘project_id’, ‘organization_id’ could be set. :return: Subscriber

Usage:

result = api.create_subscriber(
    name="example",
)
delete_acl(*, acl_id: str, region: str | None = None) None

Delete an ACL. :param acl_id: ACL ID. :param region: Region to target. If none is passed will use default region from the config.

Usage:

result = api.delete_acl(
    acl_id="example",
)
delete_backend(*, backend_id: str, region: str | None = None) None

Delete a backend in a given load balancer. :param backend_id: ID of the backend to delete. :param region: Region to target. If none is passed will use default region from the config.

Usage:

result = api.delete_backend(
    backend_id="example",
)
delete_certificate(*, certificate_id: str, region: str | None = None) None

Delete a TLS certificate. :param certificate_id: Certificate ID. :param region: Region to target. If none is passed will use default region from the config.

Usage:

result = api.delete_certificate(
    certificate_id="example",
)
delete_frontend(*, frontend_id: str, region: str | None = None) None

Delete a frontend. :param frontend_id: ID of the frontend to delete. :param region: Region to target. If none is passed will use default region from the config.

Usage:

result = api.delete_frontend(
    frontend_id="example",
)
delete_lb(*, lb_id: str, release_ip: bool, region: str | None = None) None

Delete a load balancer. :param lb_id: ID of the Load Balancer to delete. :param release_ip: Defines whether the Load Balancer’s flexible IP should be deleted. Set to true to release the flexible IP, or false to keep it available in your account for future Load Balancers. :param region: Region to target. If none is passed will use default region from the config.

Usage:

result = api.delete_lb(
    lb_id="example",
    release_ip=False,
)
delete_route(*, route_id: str, region: str | None = None) None

Delete a backend redirection. :param route_id: Route ID. :param region: Region to target. If none is passed will use default region from the config.

Usage:

result = api.delete_route(
    route_id="example",
)
delete_subscriber(*, subscriber_id: str, region: str | None = None) None

Delete a subscriber. :param subscriber_id: Subscriber ID. :param region: Region to target. If none is passed will use default region from the config.

Usage:

result = api.delete_subscriber(
    subscriber_id="example",
)
detach_private_network(*, lb_id: str, private_network_id: str, region: str | None = None) None

Remove load balancer of private network. :param lb_id: Load balancer ID. :param private_network_id: Set your instance private network id. :param region: Region to target. If none is passed will use default region from the config.

Usage:

result = api.detach_private_network(
    lb_id="example",
    private_network_id="example",
)
get_acl(*, acl_id: str, region: str | None = None) Acl

Get an ACL. :param acl_id: ACL ID. :param region: Region to target. If none is passed will use default region from the config. :return: Acl

Usage:

result = api.get_acl(
    acl_id="example",
)
get_backend(*, backend_id: str, region: str | None = None) Backend

Get a backend in a given load balancer. :param backend_id: Backend ID. :param region: Region to target. If none is passed will use default region from the config. :return: Backend

Usage:

result = api.get_backend(
    backend_id="example",
)
get_certificate(*, certificate_id: str, region: str | None = None) Certificate

Get a TLS certificate. :param certificate_id: Certificate ID. :param region: Region to target. If none is passed will use default region from the config. :return: Certificate

Usage:

result = api.get_certificate(
    certificate_id="example",
)
get_frontend(*, frontend_id: str, region: str | None = None) Frontend

Get a frontend. :param frontend_id: Frontend ID. :param region: Region to target. If none is passed will use default region from the config. :return: Frontend

Usage:

result = api.get_frontend(
    frontend_id="example",
)
get_ip(*, ip_id: str, region: str | None = None) Ip

Get an IP. :param ip_id: IP address ID. :param region: Region to target. If none is passed will use default region from the config. :return: Ip

Usage:

result = api.get_ip(
    ip_id="example",
)
get_lb(*, lb_id: str, region: str | None = None) Lb

Get a load balancer. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :return: Lb

Usage:

result = api.get_lb(
    lb_id="example",
)
get_lb_stats(*, lb_id: str, region: str | None = None, backend_id: str | None = None) LbStats

Get usage statistics of a given load balancer. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :param backend_id: ID of the backend. :return: LbStats :deprecated

Usage:

result = api.get_lb_stats(
    lb_id="example",
)
get_route(*, route_id: str, region: str | None = None) Route

Get single backend redirection. :param route_id: Route ID. :param region: Region to target. If none is passed will use default region from the config. :return: Route

Usage:

result = api.get_route(
    route_id="example",
)
get_subscriber(*, subscriber_id: str, region: str | None = None) Subscriber

Get a subscriber. :param subscriber_id: Subscriber ID. :param region: Region to target. If none is passed will use default region from the config. :return: Subscriber

Usage:

result = api.get_subscriber(
    subscriber_id="example",
)
list_acls(*, frontend_id: str, region: str | None = None, order_by: ListAclRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None, name: str | None = None) ListAclResponse

List ACL for a given frontend. :param frontend_id: Frontend ID (ACLs attached to this frontend will be returned in the response). :param region: Region to target. If none is passed will use default region from the config. :param order_by: Sort order of ACLs in the response. :param page: The page number to return, from the paginated results. :param page_size: The number of ACLs to return. :param name: ACL name to filter for. :return: ListAclResponse

Usage:

result = api.list_acls(
    frontend_id="example",
)
list_acls_all(*, frontend_id: str, region: str | None = None, order_by: ListAclRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None, name: str | None = None) List[Acl]

List ACL for a given frontend. :param frontend_id: Frontend ID (ACLs attached to this frontend will be returned in the response). :param region: Region to target. If none is passed will use default region from the config. :param order_by: Sort order of ACLs in the response. :param page: The page number to return, from the paginated results. :param page_size: The number of ACLs to return. :param name: ACL name to filter for. :return: List[Acl]

Usage:

result = api.list_acls_all(
    frontend_id="example",
)
list_backend_stats(*, lb_id: str, region: str | None = None, page: int | None = None, page_size: int | None = None, backend_id: str | None = None) ListBackendStatsResponse

List backend server statistics. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :param page: The page number to return, from the paginated results. :param page_size: Number of items to return. :param backend_id: ID of the backend. :return: ListBackendStatsResponse

Usage:

result = api.list_backend_stats(
    lb_id="example",
)
list_backend_stats_all(*, lb_id: str, region: str | None = None, page: int | None = None, page_size: int | None = None, backend_id: str | None = None) List[BackendServerStats]

List backend server statistics. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :param page: The page number to return, from the paginated results. :param page_size: Number of items to return. :param backend_id: ID of the backend. :return: List[BackendServerStats]

Usage:

result = api.list_backend_stats_all(
    lb_id="example",
)
list_backends(*, lb_id: str, region: str | None = None, name: str | None = None, order_by: ListBackendsRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None) ListBackendsResponse

List backends in a given load balancer. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :param name: Name of the backend to filter for. :param order_by: Sort order of backends in the response. :param page: The page number to return, from the paginated results. :param page_size: Number of backends to return. :return: ListBackendsResponse

Usage:

result = api.list_backends(
    lb_id="example",
)
list_backends_all(*, lb_id: str, region: str | None = None, name: str | None = None, order_by: ListBackendsRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None) List[Backend]

List backends in a given load balancer. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :param name: Name of the backend to filter for. :param order_by: Sort order of backends in the response. :param page: The page number to return, from the paginated results. :param page_size: Number of backends to return. :return: List[Backend]

Usage:

result = api.list_backends_all(
    lb_id="example",
)
list_certificates(*, lb_id: str, region: str | None = None, order_by: ListCertificatesRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None, name: str | None = None) ListCertificatesResponse

List all TLS certificates on a given load balancer. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :param order_by: Sort order of certificates in the response. :param page: The page number to return, from the paginated results. :param page_size: Number of certificates to return. :param name: Certificate name to filter for, only certificates of this name will be returned. :return: ListCertificatesResponse

Usage:

result = api.list_certificates(
    lb_id="example",
)
list_certificates_all(*, lb_id: str, region: str | None = None, order_by: ListCertificatesRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None, name: str | None = None) List[Certificate]

List all TLS certificates on a given load balancer. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :param order_by: Sort order of certificates in the response. :param page: The page number to return, from the paginated results. :param page_size: Number of certificates to return. :param name: Certificate name to filter for, only certificates of this name will be returned. :return: List[Certificate]

Usage:

result = api.list_certificates_all(
    lb_id="example",
)
list_frontends(*, lb_id: str, region: str | None = None, name: str | None = None, order_by: ListFrontendsRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None) ListFrontendsResponse

List frontends in a given load balancer. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :param name: Name of the frontend to filter for. :param order_by: Sort order of frontends in the response. :param page: The page number to return, from the paginated results. :param page_size: Number of frontends to return. :return: ListFrontendsResponse

Usage:

result = api.list_frontends(
    lb_id="example",
)
list_frontends_all(*, lb_id: str, region: str | None = None, name: str | None = None, order_by: ListFrontendsRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None) List[Frontend]

List frontends in a given load balancer. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :param name: Name of the frontend to filter for. :param order_by: Sort order of frontends in the response. :param page: The page number to return, from the paginated results. :param page_size: Number of frontends to return. :return: List[Frontend]

Usage:

result = api.list_frontends_all(
    lb_id="example",
)
list_i_ps(*, region: str | None = None, page: int | None = None, page_size: int | None = None, ip_address: str | None = None, organization_id: str | None = None, project_id: str | None = None, ip_type: ListIpsRequestIpType | None = None, tags: List[str] | None = None) ListIpsResponse

List IPs. :param region: Region to target. If none is passed will use default region from the config. :param page: The page number to return, from the paginated results. :param page_size: Number of IP addresses to return. :param ip_address: IP address to filter for. :param organization_id: Organization ID to filter for, only Load Balancer IP addresses from this Organization will be returned. :param project_id: Project ID to filter for, only Load Balancer IP addresses from this Project will be returned. :param ip_type: IP type to filter for. :param tags: Tag to filter for, only IPs with one or more matching tags will be returned. :return: ListIpsResponse

Usage:

result = api.list_i_ps()
list_i_ps_all(*, region: str | None = None, page: int | None = None, page_size: int | None = None, ip_address: str | None = None, organization_id: str | None = None, project_id: str | None = None, ip_type: ListIpsRequestIpType | None = None, tags: List[str] | None = None) List[Ip]

List IPs. :param region: Region to target. If none is passed will use default region from the config. :param page: The page number to return, from the paginated results. :param page_size: Number of IP addresses to return. :param ip_address: IP address to filter for. :param organization_id: Organization ID to filter for, only Load Balancer IP addresses from this Organization will be returned. :param project_id: Project ID to filter for, only Load Balancer IP addresses from this Project will be returned. :param ip_type: IP type to filter for. :param tags: Tag to filter for, only IPs with one or more matching tags will be returned. :return: List[Ip]

Usage:

result = api.list_i_ps_all()
list_lb_private_networks(*, lb_id: str, region: str | None = None, order_by: ListPrivateNetworksRequestOrderBy | None = None, page_size: int | None = None, page: int | None = None) ListLbPrivateNetworksResponse

List attached private network of load balancer. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :param order_by: Sort order of Private Network objects in the response. :param page_size: Number of objects to return. :param page: The page number to return, from the paginated results. :return: ListLbPrivateNetworksResponse

Usage:

result = api.list_lb_private_networks(
    lb_id="example",
)
list_lb_private_networks_all(*, lb_id: str, region: str | None = None, order_by: ListPrivateNetworksRequestOrderBy | None = None, page_size: int | None = None, page: int | None = None) List[PrivateNetwork]

List attached private network of load balancer. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :param order_by: Sort order of Private Network objects in the response. :param page_size: Number of objects to return. :param page: The page number to return, from the paginated results. :return: List[PrivateNetwork]

Usage:

result = api.list_lb_private_networks_all(
    lb_id="example",
)
list_lb_types(*, region: str | None = None, page: int | None = None, page_size: int | None = None) ListLbTypesResponse

List all load balancer offer type. :param region: Region to target. If none is passed will use default region from the config. :param page: The page number to return, from the paginated results. :param page_size: The number of items to return. :return: ListLbTypesResponse

Usage:

result = api.list_lb_types()
list_lb_types_all(*, region: str | None = None, page: int | None = None, page_size: int | None = None) List[LbType]

List all load balancer offer type. :param region: Region to target. If none is passed will use default region from the config. :param page: The page number to return, from the paginated results. :param page_size: The number of items to return. :return: List[LbType]

Usage:

result = api.list_lb_types_all()
list_lbs(*, region: str | None = None, name: str | None = None, order_by: ListLbsRequestOrderBy | None = None, page_size: int | None = None, page: int | None = None, organization_id: str | None = None, project_id: str | None = None, tags: List[str] | None = None) ListLbsResponse

List load balancers. :param region: Region to target. If none is passed will use default region from the config. :param name: Load Balancer name to filter for. :param order_by: Sort order of Load Balancers in the response. :param page_size: Number of Load Balancers to return. :param page: Page number to return, from the paginated results. :param organization_id: Organization ID to filter for, only Load Balancers from this Organization will be returned. :param project_id: Project ID to filter for, only Load Balancers from this Project will be returned. :param tags: Filter by tag, only Load Balancers with one or more matching tags will be returned. :return: ListLbsResponse

Usage:

result = api.list_lbs()
list_lbs_all(*, region: str | None = None, name: str | None = None, order_by: ListLbsRequestOrderBy | None = None, page_size: int | None = None, page: int | None = None, organization_id: str | None = None, project_id: str | None = None, tags: List[str] | None = None) List[Lb]

List load balancers. :param region: Region to target. If none is passed will use default region from the config. :param name: Load Balancer name to filter for. :param order_by: Sort order of Load Balancers in the response. :param page_size: Number of Load Balancers to return. :param page: Page number to return, from the paginated results. :param organization_id: Organization ID to filter for, only Load Balancers from this Organization will be returned. :param project_id: Project ID to filter for, only Load Balancers from this Project will be returned. :param tags: Filter by tag, only Load Balancers with one or more matching tags will be returned. :return: List[Lb]

Usage:

result = api.list_lbs_all()
list_routes(*, region: str | None = None, order_by: ListRoutesRequestOrderBy | None = None, page_size: int | None = None, page: int | None = None, frontend_id: str | None = None) ListRoutesResponse

List all backend redirections. :param region: Region to target. If none is passed will use default region from the config. :param order_by: Sort order of routes in the response. :param page_size: The number of route objects to return. :param page: The page number to return, from the paginated results. :param frontend_id: Frontend ID to filter for, only Routes from this Frontend will be returned. :return: ListRoutesResponse

Usage:

result = api.list_routes()
list_routes_all(*, region: str | None = None, order_by: ListRoutesRequestOrderBy | None = None, page_size: int | None = None, page: int | None = None, frontend_id: str | None = None) List[Route]

List all backend redirections. :param region: Region to target. If none is passed will use default region from the config. :param order_by: Sort order of routes in the response. :param page_size: The number of route objects to return. :param page: The page number to return, from the paginated results. :param frontend_id: Frontend ID to filter for, only Routes from this Frontend will be returned. :return: List[Route]

Usage:

result = api.list_routes_all()
list_subscriber(*, region: str | None = None, order_by: ListSubscriberRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None, name: str | None = None, organization_id: str | None = None, project_id: str | None = None) ListSubscriberResponse

List all subscriber. :param region: Region to target. If none is passed will use default region from the config. :param order_by: Sort order of subscribers in the response. :param page: The page number to return, from the paginated results. :param page_size: The number of items to return. :param name: Subscriber name to search for. :param organization_id: Filter subscribers by Organization ID. :param project_id: Filter subscribers by Project ID. :return: ListSubscriberResponse

Usage:

result = api.list_subscriber()
list_subscriber_all(*, region: str | None = None, order_by: ListSubscriberRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None, name: str | None = None, organization_id: str | None = None, project_id: str | None = None) List[Subscriber]

List all subscriber. :param region: Region to target. If none is passed will use default region from the config. :param order_by: Sort order of subscribers in the response. :param page: The page number to return, from the paginated results. :param page_size: The number of items to return. :param name: Subscriber name to search for. :param organization_id: Filter subscribers by Organization ID. :param project_id: Filter subscribers by Project ID. :return: List[Subscriber]

Usage:

result = api.list_subscriber_all()
migrate_lb(*, lb_id: str, type_: str, region: str | None = None) Lb

Migrate a load balancer. :param lb_id: Load Balancer ID. :param type_: Load Balancer type to migrate to (use the List all Load Balancer offer types endpoint to get a list of available offer types). :param region: Region to target. If none is passed will use default region from the config. :return: Lb

Usage:

result = api.migrate_lb(
    lb_id="example",
    type="example",
)
release_ip(*, ip_id: str, region: str | None = None) None

Delete an IP. :param ip_id: IP address ID. :param region: Region to target. If none is passed will use default region from the config.

Usage:

result = api.release_ip(
    ip_id="example",
)
remove_backend_servers(*, backend_id: str, server_ip: List[str], region: str | None = None) Backend

Remove a set of servers for a given backend. :param backend_id: Backend ID. :param server_ip: List of IP addresses to remove from backend servers. :param region: Region to target. If none is passed will use default region from the config. :return: Backend

Usage:

result = api.remove_backend_servers(
    backend_id="example",
    server_ip=[],
)
set_backend_servers(*, backend_id: str, server_ip: List[str], region: str | None = None) Backend

Define all servers in a given backend. :param backend_id: Backend ID. :param server_ip: List of IP addresses for backend servers. Any other existing backend servers will be removed. :param region: Region to target. If none is passed will use default region from the config. :return: Backend

Usage:

result = api.set_backend_servers(
    backend_id="example",
    server_ip=[],
)
subscribe_to_lb(*, lb_id: str, subscriber_id: str, region: str | None = None) Lb

Subscribe a subscriber to a given load balancer. :param lb_id: Load Balancer ID. :param subscriber_id: Subscriber ID. :param region: Region to target. If none is passed will use default region from the config. :return: Lb

Usage:

result = api.subscribe_to_lb(
    lb_id="example",
    subscriber_id="example",
)
unsubscribe_from_lb(*, lb_id: str, region: str | None = None) Lb

Unsubscribe a subscriber from a given load balancer. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :return: Lb

Usage:

result = api.unsubscribe_from_lb(
    lb_id="example",
)
update_acl(*, acl_id: str, name: str, action: AclAction, index: int, region: str | None = None, match: AclMatch | None = None, description: str | None = None) Acl

Update an ACL. :param acl_id: ACL ID. :param name: ACL name. :param action: Action to take when incoming traffic matches an ACL filter. :param index: Priority of this ACL (ACLs are applied in ascending order, 0 is the first ACL executed). :param region: Region to target. If none is passed will use default region from the config. :param match: ACL match filter object. One of ip_subnet, ips_edge_services or http_filter & http_filter_value are required. :param description: ACL description. :return: Acl

Usage:

result = api.update_acl(
    acl_id="example",
    name="example",
    action=AclAction(),
    index=1,
)
update_backend(*, backend_id: str, name: str, forward_protocol: Protocol, forward_port: int, forward_port_algorithm: ForwardPortAlgorithm, sticky_sessions: StickySessionsType, sticky_sessions_cookie_name: str, region: str | None = None, send_proxy_v2: bool | None = None, timeout_server: str | None = None, timeout_connect: str | None = None, timeout_tunnel: str | None = None, on_marked_down_action: OnMarkedDownAction | None = None, proxy_protocol: ProxyProtocol | None = None, failover_host: str | None = None, ssl_bridging: bool | None = None, ignore_ssl_server_verify: bool | None = None, redispatch_attempt_count: int | None = None, max_retries: int | None = None, max_connections: int | None = None, timeout_queue: str | None = None) Backend

Update a backend in a given load balancer. :param backend_id: Backend ID. :param name: Backend name. :param forward_protocol: Protocol to be used by the backend when forwarding traffic to backend servers. :param forward_port: Port to be used by the backend when forwarding traffic to backend servers. :param forward_port_algorithm: Load balancing algorithm to be used when determining which backend server to forward new traffic to. :param sticky_sessions: Defines whether to activate sticky sessions (binding a particular session to a particular backend server) and the method to use if so. None disables sticky sessions. Cookie-based uses an HTTP cookie to stick a session to a backend server. Table-based uses the source (client) IP address to stick a session to a backend server. :param sticky_sessions_cookie_name: Cookie name for cookie-based sticky sessions. :param region: Region to target. If none is passed will use default region from the config. :param send_proxy_v2: Deprecated in favor of proxy_protocol field. :param timeout_server: Maximum allowed time for a backend server to process a request. :param timeout_connect: Maximum allowed time for establishing a connection to a backend server. :param timeout_tunnel: Maximum allowed tunnel inactivity time after Websocket is established (takes precedence over client and server timeout). :param on_marked_down_action: Action to take when a backend server is marked as down. :param proxy_protocol: Protocol to use between the Load Balancer and backend servers. Allows the backend servers to be informed of the client’s real IP address. The PROXY protocol must be supported by the backend servers’ software. :param failover_host: Scaleway Object Storage bucket website to be served as failover if all backend servers are down, e.g. failover-website.s3-website.fr-par.scw.cloud. :param ssl_bridging: Defines whether to enable SSL bridging between the Load Balancer and backend servers. :param ignore_ssl_server_verify: Defines whether the server certificate verification should be ignored. :param redispatch_attempt_count: Whether to use another backend server on each attempt. :param max_retries: Number of retries when a backend server connection failed. :param max_connections: Maximum number of connections allowed per backend server. :param timeout_queue: Maximum time for a request to be left pending in queue when max_connections is reached. :return: Backend

Usage:

result = api.update_backend(
    backend_id="example",
    name="example",
    forward_protocol=Protocol.tcp,
    forward_port=1,
    forward_port_algorithm=ForwardPortAlgorithm.roundrobin,
    sticky_sessions=StickySessionsType.none,
    sticky_sessions_cookie_name="example",
)
update_certificate(*, certificate_id: str, name: str, region: str | None = None) Certificate

Update a TLS certificate. :param certificate_id: Certificate ID. :param name: Certificate name. :param region: Region to target. If none is passed will use default region from the config. :return: Certificate

Usage:

result = api.update_certificate(
    certificate_id="example",
    name="example",
)
update_frontend(*, frontend_id: str, name: str, inbound_port: int, backend_id: str, enable_http3: bool, region: str | None = None, timeout_client: str | None = None, certificate_id: str | None = None, certificate_ids: List[str] | None = None, connection_rate_limit: int | None = None, enable_access_logs: bool | None = None) Frontend

Update a frontend. :param frontend_id: Frontend ID. :param name: Frontend name. :param inbound_port: Port the frontend should listen on. :param backend_id: Backend ID (ID of the backend the frontend should pass traffic to). :param enable_http3: Defines whether to enable HTTP/3 protocol on the frontend. :param region: Region to target. If none is passed will use default region from the config. :param timeout_client: Maximum allowed inactivity time on the client side. :param certificate_id: Certificate ID, deprecated in favor of certificate_ids array. :param certificate_ids: List of SSL/TLS certificate IDs to bind to the frontend. :param connection_rate_limit: Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. :param enable_access_logs: Defines whether to enable access logs on the frontend. :return: Frontend

Usage:

result = api.update_frontend(
    frontend_id="example",
    name="example",
    inbound_port=1,
    backend_id="example",
    enable_http3=False,
)
update_health_check(*, port: int, check_max_retries: int, backend_id: str, region: str | None = None, check_delay: str | None = None, check_timeout: str | None = None, check_send_proxy: bool, tcp_config: HealthCheckTcpConfig | None = None, mysql_config: HealthCheckMysqlConfig | None = None, pgsql_config: HealthCheckPgsqlConfig | None = None, ldap_config: HealthCheckLdapConfig | None = None, redis_config: HealthCheckRedisConfig | None = None, http_config: HealthCheckHttpConfig | None = None, https_config: HealthCheckHttpsConfig | None = None, transient_check_delay: str | None = None) HealthCheck

Update an health check for a given backend. :param port: Port to use for the backend server health check. :param check_max_retries: Number of consecutive unsuccessful health checks after which the server will be considered dead. :param backend_id: Backend ID. :param region: Region to target. If none is passed will use default region from the config. :param check_delay: Time to wait between two consecutive health checks. :param check_timeout: Maximum time a backend server has to reply to the health check. :param check_send_proxy: Defines whether proxy protocol should be activated for the health check. :param tcp_config: Object to configure a basic TCP health check. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param mysql_config: Object to configure a MySQL health check. The check requires MySQL >=3.22 or <9.0. For older or newer versions, use a TCP health check. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param pgsql_config: Object to configure a PostgreSQL health check. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param ldap_config: Object to configure an LDAP health check. The response is analyzed to find the LDAPv3 response message. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param redis_config: Object to configure a Redis health check. The response is analyzed to find the +PONG response message. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param http_config: Object to configure an HTTP health check. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param https_config: Object to configure an HTTPS health check. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param transient_check_delay: Time to wait between two consecutive health checks when a backend server is in a transient state (going UP or DOWN). :return: HealthCheck

Usage:

result = api.update_health_check(
    port=1,
    check_max_retries=1,
    backend_id="example",
    check_send_proxy=False,
)
update_ip(*, ip_id: str, region: str | None = None, reverse: str | None = None, lb_id: str | None = None, tags: List[str] | None = None) Ip

Update an IP. :param ip_id: IP address ID. :param region: Region to target. If none is passed will use default region from the config. :param reverse: Reverse DNS (domain name) for the IP address. :param lb_id: ID of the server on which to attach the flexible IP. :param tags: List of tags for the IP. :return: Ip

Usage:

result = api.update_ip(
    ip_id="example",
)
update_lb(*, lb_id: str, name: str, description: str, region: str | None = None, tags: List[str] | None = None, ssl_compatibility_level: SSLCompatibilityLevel | None = None) Lb

Update a load balancer. :param lb_id: Load Balancer ID. :param name: Load Balancer name. :param description: Load Balancer description. :param region: Region to target. If none is passed will use default region from the config. :param tags: List of tags for the Load Balancer. :param ssl_compatibility_level: Determines the minimal SSL version which needs to be supported on the client side, in an SSL/TLS offloading context. Intermediate is suitable for general-purpose servers with a variety of clients, recommended for almost all systems. Modern is suitable for services with clients that support TLS 1.3 and don’t need backward compatibility. Old is compatible with a small number of very old clients and should be used only as a last resort. :return: Lb

Usage:

result = api.update_lb(
    lb_id="example",
    name="example",
    description="example",
)
update_route(*, route_id: str, backend_id: str, region: str | None = None, match: RouteMatch | None = None) Route

Edit a backend redirection. :param route_id: Route ID. :param backend_id: ID of the target backend for the route. :param region: Region to target. If none is passed will use default region from the config. :param match: Object defining the match condition for a route to be applied. If an incoming client session matches the specified condition (i.e. it has a matching SNI value or HTTP Host header value), it will be passed to the target backend. :return: Route

Usage:

result = api.update_route(
    route_id="example",
    backend_id="example",
)
update_subscriber(*, subscriber_id: str, name: str, region: str | None = None, email_config: SubscriberEmailConfig | None = None, webhook_config: SubscriberWebhookConfig | None = None) Subscriber

Update a subscriber. :param subscriber_id: Subscriber ID. :param name: Subscriber name. :param region: Region to target. If none is passed will use default region from the config. :param email_config: Email address configuration. One-Of (‘config’): at most one of ‘email_config’, ‘webhook_config’ could be set. :param webhook_config: Webhook URI configuration. One-Of (‘config’): at most one of ‘email_config’, ‘webhook_config’ could be set. :return: Subscriber

Usage:

result = api.update_subscriber(
    subscriber_id="example",
    name="example",
)
wait_for_certificate(*, certificate_id: str, region: str | None = None, options: WaitForOptions[Certificate, bool] | None = None) Certificate

Get a TLS certificate. :param certificate_id: Certificate ID. :param region: Region to target. If none is passed will use default region from the config. :return: Certificate

Usage:

result = api.get_certificate(
    certificate_id="example",
)
wait_for_lb(*, lb_id: str, region: str | None = None, options: WaitForOptions[Lb, bool] | None = None) Lb

Get a load balancer. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :return: Lb

Usage:

result = api.get_lb(
    lb_id="example",
)
class scaleway.lb.v1.api.LbV1ZonedAPI(client: Client, *, bypass_validation: bool = False)

Bases: API

This API allows you to manage your Scaleway Load Balancer services.

add_backend_servers(*, backend_id: str, server_ip: List[str], zone: str | None = None) Backend

Add a set of backend servers to a given backend. For a given backend specified by its backend ID, add a set of backend servers (identified by their IP addresses) it should forward traffic to. These will be appended to any existing set of backend servers for this backend. :param backend_id: Backend ID. :param server_ip: List of IP addresses to add to backend servers. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Backend

Usage:

result = api.add_backend_servers(
    backend_id="example",
    server_ip=[],
)
attach_private_network(*, lb_id: str, private_network_id: str, zone: str | None = None, static_config: PrivateNetworkStaticConfig | None = None, dhcp_config: PrivateNetworkDHCPConfig | None = None, ipam_config: PrivateNetworkIpamConfig | None = None, ipam_ids: List[str] | None = None) PrivateNetwork

Attach a Load Balancer to a Private Network. Attach a specified Load Balancer to a specified Private Network, defining a static or DHCP configuration for the Load Balancer on the network. :param lb_id: Load Balancer ID. :param private_network_id: Private Network ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param static_config: Object containing an array of a local IP address for the Load Balancer on this Private Network. One-Of (‘config’): at most one of ‘static_config’, ‘dhcp_config’, ‘ipam_config’ could be set. :param dhcp_config: Defines whether to let DHCP assign IP addresses. One-Of (‘config’): at most one of ‘static_config’, ‘dhcp_config’, ‘ipam_config’ could be set. :param ipam_config: For internal use only. One-Of (‘config’): at most one of ‘static_config’, ‘dhcp_config’, ‘ipam_config’ could be set. :param ipam_ids: IPAM ID of a pre-reserved IP address to assign to the Load Balancer on this Private Network. In the future, it will be possible to specify multiple IPs in this field (IPv4 and IPv6), for now only one ID of an IPv4 address is expected. When null, a new private IP address is created for the Load Balancer on this Private Network. :return: PrivateNetwork

Usage:

result = api.attach_private_network(
    lb_id="example",
    private_network_id="example",
)
create_acl(*, frontend_id: str, action: AclAction, index: int, description: str, zone: str | None = None, name: str | None = None, match: AclMatch | None = None) Acl

Create an ACL for a given frontend. Create a new ACL for a given frontend. Each ACL must have a name, an action to perform (allow or deny), and a match rule (the action is carried out when the incoming traffic matches the rule). :param frontend_id: Frontend ID to attach the ACL to. :param action: Action to take when incoming traffic matches an ACL filter. :param index: Priority of this ACL (ACLs are applied in ascending order, 0 is the first ACL executed). :param description: ACL description. :param zone: Zone to target. If none is passed will use default zone from the config. :param name: ACL name. :param match: ACL match filter object. One of ip_subnet, ips_edge_services or http_filter & http_filter_value are required. :return: Acl

Usage:

result = api.create_acl(
    frontend_id="example",
    action=AclAction(),
    index=1,
    description="example",
)
create_backend(*, forward_protocol: Protocol, forward_port: int, forward_port_algorithm: ForwardPortAlgorithm, sticky_sessions: StickySessionsType, sticky_sessions_cookie_name: str, lb_id: str, health_check: HealthCheck, server_ip: List[str], zone: str | None = None, name: str | None = None, send_proxy_v2: bool | None = None, timeout_server: str | None = None, timeout_connect: str | None = None, timeout_tunnel: str | None = None, on_marked_down_action: OnMarkedDownAction | None = None, proxy_protocol: ProxyProtocol | None = None, failover_host: str | None = None, ssl_bridging: bool | None = None, ignore_ssl_server_verify: bool | None = None, redispatch_attempt_count: int | None = None, max_retries: int | None = None, max_connections: int | None = None, timeout_queue: str | None = None) Backend

Create a backend for a given Load Balancer. Create a new backend for a given Load Balancer, specifying its full configuration including protocol, port and forwarding algorithm. :param forward_protocol: Protocol to be used by the backend when forwarding traffic to backend servers. :param forward_port: Port to be used by the backend when forwarding traffic to backend servers. :param forward_port_algorithm: Load balancing algorithm to be used when determining which backend server to forward new traffic to. :param sticky_sessions: Defines whether to activate sticky sessions (binding a particular session to a particular backend server) and the method to use if so. None disables sticky sessions. Cookie-based uses an HTTP cookie TO stick a session to a backend server. Table-based uses the source (client) IP address to stick a session to a backend server. :param sticky_sessions_cookie_name: Cookie name for cookie-based sticky sessions. :param lb_id: Load Balancer ID. :param health_check: Object defining the health check to be carried out by the backend when checking the status and health of backend servers. :param server_ip: List of backend server IP addresses (IPv4 or IPv6) the backend should forward traffic to. :param zone: Zone to target. If none is passed will use default zone from the config. :param name: Name for the backend. :param send_proxy_v2: Deprecated in favor of proxy_protocol field. :param timeout_server: Maximum allowed time for a backend server to process a request. :param timeout_connect: Maximum allowed time for establishing a connection to a backend server. :param timeout_tunnel: Maximum allowed tunnel inactivity time after Websocket is established (takes precedence over client and server timeout). :param on_marked_down_action: Action to take when a backend server is marked as down. :param proxy_protocol: Protocol to use between the Load Balancer and backend servers. Allows the backend servers to be informed of the client’s real IP address. The PROXY protocol must be supported by the backend servers’ software. :param failover_host: Scaleway Object Storage bucket website to be served as failover if all backend servers are down, e.g. failover-website.s3-website.fr-par.scw.cloud. :param ssl_bridging: Defines whether to enable SSL bridging between the Load Balancer and backend servers. :param ignore_ssl_server_verify: Defines whether the server certificate verification should be ignored. :param redispatch_attempt_count: Whether to use another backend server on each attempt. :param max_retries: Number of retries when a backend server connection failed. :param max_connections: Maximum number of connections allowed per backend server. :param timeout_queue: Maximum time for a request to be left pending in queue when max_connections is reached. :return: Backend

Usage:

result = api.create_backend(
    forward_protocol=Protocol.tcp,
    forward_port=1,
    forward_port_algorithm=ForwardPortAlgorithm.roundrobin,
    sticky_sessions=StickySessionsType.none,
    sticky_sessions_cookie_name="example",
    lb_id="example",
    health_check=HealthCheck(),
    server_ip=[],
)
create_certificate(*, lb_id: str, zone: str | None = None, name: str | None = None, letsencrypt: CreateCertificateRequestLetsencryptConfig | None = None, custom_certificate: CreateCertificateRequestCustomCertificate | None = None) Certificate

Create an SSL/TLS certificate. Generate a new SSL/TLS certificate for a given Load Balancer. You can choose to create a Let’s Encrypt certificate, or import a custom certificate. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param name: Name for the certificate. :param letsencrypt: Object to define a new Let’s Encrypt certificate to be generated. One-Of (‘type’): at most one of ‘letsencrypt’, ‘custom_certificate’ could be set. :param custom_certificate: Object to define an existing custom certificate to be imported. One-Of (‘type’): at most one of ‘letsencrypt’, ‘custom_certificate’ could be set. :return: Certificate

Usage:

result = api.create_certificate(
    lb_id="example",
)
create_frontend(*, inbound_port: int, lb_id: str, backend_id: str, enable_http3: bool, enable_access_logs: bool, zone: str | None = None, name: str | None = None, timeout_client: str | None = None, certificate_id: str | None = None, certificate_ids: List[str] | None = None, connection_rate_limit: int | None = None) Frontend

Create a frontend in a given Load Balancer. Create a new frontend for a given Load Balancer, specifying its configuration including the port it should listen on and the backend to attach it to. :param inbound_port: Port the frontend should listen on. :param lb_id: Load Balancer ID (ID of the Load Balancer to attach the frontend to). :param backend_id: Backend ID (ID of the backend the frontend should pass traffic to). :param enable_http3: Defines whether to enable HTTP/3 protocol on the frontend. :param enable_access_logs: Defines whether to enable access logs on the frontend. :param zone: Zone to target. If none is passed will use default zone from the config. :param name: Name for the frontend. :param timeout_client: Maximum allowed inactivity time on the client side. :param certificate_id: Certificate ID, deprecated in favor of certificate_ids array. :param certificate_ids: List of SSL/TLS certificate IDs to bind to the frontend. :param connection_rate_limit: Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. :return: Frontend

Usage:

result = api.create_frontend(
    inbound_port=1,
    lb_id="example",
    backend_id="example",
    enable_http3=False,
    enable_access_logs=False,
)
create_ip(*, is_ipv6: bool, zone: str | None = None, organization_id: str | None = None, project_id: str | None = None, reverse: str | None = None, tags: List[str] | None = None) Ip

Create an IP address. Create a new Load Balancer flexible IP address, in the specified Scaleway Project. This can be attached to new Load Balancers created in the future. :param is_ipv6: If true, creates a Flexible IP with an ipv6 address. :param zone: Zone to target. If none is passed will use default zone from the config. :param organization_id: Organization ID of the Organization where the IP address should be created. One-Of (‘project_identifier’): at most one of ‘project_id’, ‘organization_id’ could be set. :param project_id: Project ID of the Project where the IP address should be created. One-Of (‘project_identifier’): at most one of ‘project_id’, ‘organization_id’ could be set. :param reverse: Reverse DNS (domain name) for the IP address. :param tags: List of tags for the IP. :return: Ip

Usage:

result = api.create_ip(
    is_ipv6=False,
)
create_lb(*, description: str, type_: str, zone: str | None = None, organization_id: str | None = None, project_id: str | None = None, name: str | None = None, ip_id: str | None = None, assign_flexible_ip: bool | None = None, assign_flexible_ipv6: bool | None = None, ip_ids: List[str] | None = None, tags: List[str] | None = None, ssl_compatibility_level: SSLCompatibilityLevel | None = None) Lb

Create a Load Balancer. Create a new Load Balancer. Note that the Load Balancer will be created without frontends or backends; these must be created separately via the dedicated endpoints. :param description: Description for the Load Balancer. :param type_: Load Balancer commercial offer type. Use the Load Balancer types endpoint to retrieve a list of available offer types. :param zone: Zone to target. If none is passed will use default zone from the config. :param organization_id: Scaleway Organization to create the Load Balancer in. One-Of (‘project_identifier’): at most one of ‘project_id’, ‘organization_id’ could be set. :param project_id: Scaleway Project to create the Load Balancer in. One-Of (‘project_identifier’): at most one of ‘project_id’, ‘organization_id’ could be set. :param name: Name for the Load Balancer. :param ip_id: ID of an existing flexible IP address to attach to the Load Balancer. :param assign_flexible_ip: Defines whether to automatically assign a flexible public IP to the Load Balancer. Default value is true (assign). :param assign_flexible_ipv6: Defines whether to automatically assign a flexible public IPv6 to the Load Balancer. Default value is false (do not assign). :param ip_ids: List of IP IDs to attach to the Load Balancer. :param tags: List of tags for the Load Balancer. :param ssl_compatibility_level: Determines the minimal SSL version which needs to be supported on the client side, in an SSL/TLS offloading context. Intermediate is suitable for general-purpose servers with a variety of clients, recommended for almost all systems. Modern is suitable for services with clients that support TLS 1.3 and do not need backward compatibility. Old is compatible with a small number of very old clients and should be used only as a last resort. :return: Lb

Usage:

result = api.create_lb(
    description="example",
    type="example",
)
create_route(*, frontend_id: str, backend_id: str, zone: str | None = None, match: RouteMatch | None = None) Route

Create a route. Create a new route on a given frontend. To configure a route, specify the backend to direct to if a certain condition is matched (based on the value of the SNI field or HTTP Host header). :param frontend_id: ID of the source frontend to create the route on. :param backend_id: ID of the target backend for the route. :param zone: Zone to target. If none is passed will use default zone from the config. :param match: Object defining the match condition for a route to be applied. If an incoming client session matches the specified condition (i.e. it has a matching SNI value or HTTP Host header value), it will be passed to the target backend. :return: Route

Usage:

result = api.create_route(
    frontend_id="example",
    backend_id="example",
)
create_subscriber(*, name: str, zone: str | None = None, email_config: SubscriberEmailConfig | None = None, webhook_config: SubscriberWebhookConfig | None = None, organization_id: str | None = None, project_id: str | None = None) Subscriber

Create a subscriber. Create a new subscriber, either with an email configuration or a webhook configuration, for a specified Scaleway Project. :param name: Subscriber name. :param zone: Zone to target. If none is passed will use default zone from the config. :param email_config: Email address configuration. One-Of (‘config’): at most one of ‘email_config’, ‘webhook_config’ could be set. :param webhook_config: WebHook URI configuration. One-Of (‘config’): at most one of ‘email_config’, ‘webhook_config’ could be set. :param organization_id: Organization ID to create the subscriber in. One-Of (‘project_identifier’): at most one of ‘project_id’, ‘organization_id’ could be set. :param project_id: Project ID to create the subscriber in. One-Of (‘project_identifier’): at most one of ‘project_id’, ‘organization_id’ could be set. :return: Subscriber

Usage:

result = api.create_subscriber(
    name="example",
)
delete_acl(*, acl_id: str, zone: str | None = None) None

Delete an ACL. Delete an ACL, specified by its ACL ID. Deleting an ACL is irreversible and cannot be undone. :param acl_id: ACL ID. :param zone: Zone to target. If none is passed will use default zone from the config.

Usage:

result = api.delete_acl(
    acl_id="example",
)
delete_backend(*, backend_id: str, zone: str | None = None) None

Delete a backend of a given Load Balancer. Delete a backend of a given Load Balancer, specified by its backend ID. This action is irreversible and cannot be undone. :param backend_id: ID of the backend to delete. :param zone: Zone to target. If none is passed will use default zone from the config.

Usage:

result = api.delete_backend(
    backend_id="example",
)
delete_certificate(*, certificate_id: str, zone: str | None = None) None

Delete an SSL/TLS certificate. Delete an SSL/TLS certificate, specified by its certificate ID. Deleting a certificate is irreversible and cannot be undone. :param certificate_id: Certificate ID. :param zone: Zone to target. If none is passed will use default zone from the config.

Usage:

result = api.delete_certificate(
    certificate_id="example",
)
delete_frontend(*, frontend_id: str, zone: str | None = None) None

Delete a frontend. Delete a given frontend, specified by its frontend ID. This action is irreversible and cannot be undone. :param frontend_id: ID of the frontend to delete. :param zone: Zone to target. If none is passed will use default zone from the config.

Usage:

result = api.delete_frontend(
    frontend_id="example",
)
delete_lb(*, lb_id: str, release_ip: bool, zone: str | None = None) None

Delete a Load Balancer. Delete an existing Load Balancer, specified by its Load Balancer ID. Deleting a Load Balancer is permanent, and cannot be undone. The Load Balancer’s flexible IP address can either be deleted with the Load Balancer, or kept in your account for future use. :param lb_id: ID of the Load Balancer to delete. :param release_ip: Defines whether the Load Balancer’s flexible IP should be deleted. Set to true to release the flexible IP, or false to keep it available in your account for future Load Balancers. :param zone: Zone to target. If none is passed will use default zone from the config.

Usage:

result = api.delete_lb(
    lb_id="example",
    release_ip=False,
)
delete_route(*, route_id: str, zone: str | None = None) None

Delete a route. Delete an existing route, specified by its route ID. Deleting a route is permanent, and cannot be undone. :param route_id: Route ID. :param zone: Zone to target. If none is passed will use default zone from the config.

Usage:

result = api.delete_route(
    route_id="example",
)
delete_subscriber(*, subscriber_id: str, zone: str | None = None) None

Delete a subscriber. Delete an existing subscriber, specified by its subscriber ID. Deleting a subscriber is permanent, and cannot be undone. :param subscriber_id: Subscriber ID. :param zone: Zone to target. If none is passed will use default zone from the config.

Usage:

result = api.delete_subscriber(
    subscriber_id="example",
)
detach_private_network(*, lb_id: str, private_network_id: str, zone: str | None = None) None

Detach Load Balancer from Private Network. Detach a specified Load Balancer from a specified Private Network. :param lb_id: Load balancer ID. :param private_network_id: Set your instance private network id. :param zone: Zone to target. If none is passed will use default zone from the config.

Usage:

result = api.detach_private_network(
    lb_id="example",
    private_network_id="example",
)
get_acl(*, acl_id: str, zone: str | None = None) Acl

Get an ACL. Get information for a particular ACL, specified by its ACL ID. The response returns full details of the ACL, including its name, action, match rule and frontend. :param acl_id: ACL ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Acl

Usage:

result = api.get_acl(
    acl_id="example",
)
get_backend(*, backend_id: str, zone: str | None = None) Backend

Get a backend of a given Load Balancer. Get the full details of a given backend, specified by its backend ID. The response contains the backend’s full configuration parameters including protocol, port and forwarding algorithm. :param backend_id: Backend ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Backend

Usage:

result = api.get_backend(
    backend_id="example",
)
get_certificate(*, certificate_id: str, zone: str | None = None) Certificate

Get an SSL/TLS certificate. Get information for a particular SSL/TLS certificate, specified by its certificate ID. The response returns full details of the certificate, including its type, main domain name, and alternative domain names. :param certificate_id: Certificate ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Certificate

Usage:

result = api.get_certificate(
    certificate_id="example",
)
get_frontend(*, frontend_id: str, zone: str | None = None) Frontend

Get a frontend. Get the full details of a given frontend, specified by its frontend ID. The response contains the frontend’s full configuration parameters including the backend it is attached to, the port it listens on, and any certificates it has. :param frontend_id: Frontend ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Frontend

Usage:

result = api.get_frontend(
    frontend_id="example",
)
get_ip(*, ip_id: str, zone: str | None = None) Ip

Get an IP address. Retrieve the full details of a Load Balancer flexible IP address. :param ip_id: IP address ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Ip

Usage:

result = api.get_ip(
    ip_id="example",
)
get_lb(*, lb_id: str, zone: str | None = None) Lb

Get a Load Balancer. Retrieve information about an existing Load Balancer, specified by its Load Balancer ID. Its full details, including name, status and IP address, are returned in the response object. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Lb

Usage:

result = api.get_lb(
    lb_id="example",
)
get_lb_stats(*, lb_id: str, zone: str | None = None, backend_id: str | None = None) LbStats

Get usage statistics of a given Load Balancer. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param backend_id: ID of the backend. :return: LbStats :deprecated

Usage:

result = api.get_lb_stats(
    lb_id="example",
)
get_route(*, route_id: str, zone: str | None = None) Route

Get a route. Retrieve information about an existing route, specified by its route ID. Its full details, origin frontend, target backend and match condition, are returned in the response object. :param route_id: Route ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Route

Usage:

result = api.get_route(
    route_id="example",
)
get_subscriber(*, subscriber_id: str, zone: str | None = None) Subscriber

Get a subscriber. Retrieve information about an existing subscriber, specified by its subscriber ID. Its full details, including name and email/webhook configuration, are returned in the response object. :param subscriber_id: Subscriber ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Subscriber

Usage:

result = api.get_subscriber(
    subscriber_id="example",
)
list_acls(*, frontend_id: str, zone: str | None = None, order_by: ListAclRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None, name: str | None = None) ListAclResponse

List ACLs for a given frontend. List the ACLs for a given frontend, specified by its frontend ID. The response is an array of ACL objects, each one representing an ACL that denies or allows traffic based on certain conditions. :param frontend_id: Frontend ID (ACLs attached to this frontend will be returned in the response). :param zone: Zone to target. If none is passed will use default zone from the config. :param order_by: Sort order of ACLs in the response. :param page: The page number to return, from the paginated results. :param page_size: The number of ACLs to return. :param name: ACL name to filter for. :return: ListAclResponse

Usage:

result = api.list_acls(
    frontend_id="example",
)
list_acls_all(*, frontend_id: str, zone: str | None = None, order_by: ListAclRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None, name: str | None = None) List[Acl]

List ACLs for a given frontend. List the ACLs for a given frontend, specified by its frontend ID. The response is an array of ACL objects, each one representing an ACL that denies or allows traffic based on certain conditions. :param frontend_id: Frontend ID (ACLs attached to this frontend will be returned in the response). :param zone: Zone to target. If none is passed will use default zone from the config. :param order_by: Sort order of ACLs in the response. :param page: The page number to return, from the paginated results. :param page_size: The number of ACLs to return. :param name: ACL name to filter for. :return: List[Acl]

Usage:

result = api.list_acls_all(
    frontend_id="example",
)
list_backend_stats(*, lb_id: str, zone: str | None = None, page: int | None = None, page_size: int | None = None, backend_id: str | None = None) ListBackendStatsResponse

List backend server statistics. List information about your backend servers, including their state and the result of their last health check. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param page: The page number to return, from the paginated results. :param page_size: Number of items to return. :param backend_id: ID of the backend. :return: ListBackendStatsResponse

Usage:

result = api.list_backend_stats(
    lb_id="example",
)
list_backend_stats_all(*, lb_id: str, zone: str | None = None, page: int | None = None, page_size: int | None = None, backend_id: str | None = None) List[BackendServerStats]

List backend server statistics. List information about your backend servers, including their state and the result of their last health check. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param page: The page number to return, from the paginated results. :param page_size: Number of items to return. :param backend_id: ID of the backend. :return: List[BackendServerStats]

Usage:

result = api.list_backend_stats_all(
    lb_id="example",
)
list_backends(*, lb_id: str, zone: str | None = None, name: str | None = None, order_by: ListBackendsRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None) ListBackendsResponse

List the backends of a given Load Balancer. List all the backends of a Load Balancer, specified by its Load Balancer ID. By default, results are returned in ascending order by the creation date of each backend. The response is an array of backend objects, containing full details of each one including their configuration parameters such as protocol, port and forwarding algorithm. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param name: Name of the backend to filter for. :param order_by: Sort order of backends in the response. :param page: The page number to return, from the paginated results. :param page_size: Number of backends to return. :return: ListBackendsResponse

Usage:

result = api.list_backends(
    lb_id="example",
)
list_backends_all(*, lb_id: str, zone: str | None = None, name: str | None = None, order_by: ListBackendsRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None) List[Backend]

List the backends of a given Load Balancer. List all the backends of a Load Balancer, specified by its Load Balancer ID. By default, results are returned in ascending order by the creation date of each backend. The response is an array of backend objects, containing full details of each one including their configuration parameters such as protocol, port and forwarding algorithm. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param name: Name of the backend to filter for. :param order_by: Sort order of backends in the response. :param page: The page number to return, from the paginated results. :param page_size: Number of backends to return. :return: List[Backend]

Usage:

result = api.list_backends_all(
    lb_id="example",
)
list_certificates(*, lb_id: str, zone: str | None = None, order_by: ListCertificatesRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None, name: str | None = None) ListCertificatesResponse

List all SSL/TLS certificates on a given Load Balancer. List all the SSL/TLS certificates on a given Load Balancer. The response is an array of certificate objects, which are by default listed in ascending order of creation date. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param order_by: Sort order of certificates in the response. :param page: The page number to return, from the paginated results. :param page_size: Number of certificates to return. :param name: Certificate name to filter for, only certificates of this name will be returned. :return: ListCertificatesResponse

Usage:

result = api.list_certificates(
    lb_id="example",
)
list_certificates_all(*, lb_id: str, zone: str | None = None, order_by: ListCertificatesRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None, name: str | None = None) List[Certificate]

List all SSL/TLS certificates on a given Load Balancer. List all the SSL/TLS certificates on a given Load Balancer. The response is an array of certificate objects, which are by default listed in ascending order of creation date. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param order_by: Sort order of certificates in the response. :param page: The page number to return, from the paginated results. :param page_size: Number of certificates to return. :param name: Certificate name to filter for, only certificates of this name will be returned. :return: List[Certificate]

Usage:

result = api.list_certificates_all(
    lb_id="example",
)
list_frontends(*, lb_id: str, zone: str | None = None, name: str | None = None, order_by: ListFrontendsRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None) ListFrontendsResponse

List frontends of a given Load Balancer. List all the frontends of a Load Balancer, specified by its Load Balancer ID. By default, results are returned in ascending order by the creation date of each frontend. The response is an array of frontend objects, containing full details of each one including the port they listen on and the backend they are attached to. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param name: Name of the frontend to filter for. :param order_by: Sort order of frontends in the response. :param page: The page number to return, from the paginated results. :param page_size: Number of frontends to return. :return: ListFrontendsResponse

Usage:

result = api.list_frontends(
    lb_id="example",
)
list_frontends_all(*, lb_id: str, zone: str | None = None, name: str | None = None, order_by: ListFrontendsRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None) List[Frontend]

List frontends of a given Load Balancer. List all the frontends of a Load Balancer, specified by its Load Balancer ID. By default, results are returned in ascending order by the creation date of each frontend. The response is an array of frontend objects, containing full details of each one including the port they listen on and the backend they are attached to. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param name: Name of the frontend to filter for. :param order_by: Sort order of frontends in the response. :param page: The page number to return, from the paginated results. :param page_size: Number of frontends to return. :return: List[Frontend]

Usage:

result = api.list_frontends_all(
    lb_id="example",
)
list_i_ps(*, zone: str | None = None, page: int | None = None, page_size: int | None = None, ip_address: str | None = None, organization_id: str | None = None, project_id: str | None = None, ip_type: ListIpsRequestIpType | None = None, tags: List[str] | None = None) ListIpsResponse

List IP addresses. List the Load Balancer flexible IP addresses held in the account (filtered by Organization ID or Project ID). It is also possible to search for a specific IP address. :param zone: Zone to target. If none is passed will use default zone from the config. :param page: The page number to return, from the paginated results. :param page_size: Number of IP addresses to return. :param ip_address: IP address to filter for. :param organization_id: Organization ID to filter for, only Load Balancer IP addresses from this Organization will be returned. :param project_id: Project ID to filter for, only Load Balancer IP addresses from this Project will be returned. :param ip_type: IP type to filter for. :param tags: Tag to filter for, only IPs with one or more matching tags will be returned. :return: ListIpsResponse

Usage:

result = api.list_i_ps()
list_i_ps_all(*, zone: str | None = None, page: int | None = None, page_size: int | None = None, ip_address: str | None = None, organization_id: str | None = None, project_id: str | None = None, ip_type: ListIpsRequestIpType | None = None, tags: List[str] | None = None) List[Ip]

List IP addresses. List the Load Balancer flexible IP addresses held in the account (filtered by Organization ID or Project ID). It is also possible to search for a specific IP address. :param zone: Zone to target. If none is passed will use default zone from the config. :param page: The page number to return, from the paginated results. :param page_size: Number of IP addresses to return. :param ip_address: IP address to filter for. :param organization_id: Organization ID to filter for, only Load Balancer IP addresses from this Organization will be returned. :param project_id: Project ID to filter for, only Load Balancer IP addresses from this Project will be returned. :param ip_type: IP type to filter for. :param tags: Tag to filter for, only IPs with one or more matching tags will be returned. :return: List[Ip]

Usage:

result = api.list_i_ps_all()
list_lb_private_networks(*, lb_id: str, zone: str | None = None, order_by: ListPrivateNetworksRequestOrderBy | None = None, page_size: int | None = None, page: int | None = None) ListLbPrivateNetworksResponse

List Private Networks attached to a Load Balancer. List the Private Networks attached to a given Load Balancer, specified by its Load Balancer ID. The response is an array of Private Network objects, giving information including the status, configuration, name and creation date of each Private Network. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param order_by: Sort order of Private Network objects in the response. :param page_size: Number of objects to return. :param page: The page number to return, from the paginated results. :return: ListLbPrivateNetworksResponse

Usage:

result = api.list_lb_private_networks(
    lb_id="example",
)
list_lb_private_networks_all(*, lb_id: str, zone: str | None = None, order_by: ListPrivateNetworksRequestOrderBy | None = None, page_size: int | None = None, page: int | None = None) List[PrivateNetwork]

List Private Networks attached to a Load Balancer. List the Private Networks attached to a given Load Balancer, specified by its Load Balancer ID. The response is an array of Private Network objects, giving information including the status, configuration, name and creation date of each Private Network. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param order_by: Sort order of Private Network objects in the response. :param page_size: Number of objects to return. :param page: The page number to return, from the paginated results. :return: List[PrivateNetwork]

Usage:

result = api.list_lb_private_networks_all(
    lb_id="example",
)
list_lb_types(*, zone: str | None = None, page: int | None = None, page_size: int | None = None) ListLbTypesResponse

List all Load Balancer offer types. List all the different commercial Load Balancer types. The response includes an array of offer types, each with a name, description, and information about its stock availability. :param zone: Zone to target. If none is passed will use default zone from the config. :param page: The page number to return, from the paginated results. :param page_size: The number of items to return. :return: ListLbTypesResponse

Usage:

result = api.list_lb_types()
list_lb_types_all(*, zone: str | None = None, page: int | None = None, page_size: int | None = None) List[LbType]

List all Load Balancer offer types. List all the different commercial Load Balancer types. The response includes an array of offer types, each with a name, description, and information about its stock availability. :param zone: Zone to target. If none is passed will use default zone from the config. :param page: The page number to return, from the paginated results. :param page_size: The number of items to return. :return: List[LbType]

Usage:

result = api.list_lb_types_all()
list_lbs(*, zone: str | None = None, name: str | None = None, order_by: ListLbsRequestOrderBy | None = None, page_size: int | None = None, page: int | None = None, organization_id: str | None = None, project_id: str | None = None, tags: List[str] | None = None) ListLbsResponse

List Load Balancers. List all Load Balancers in the specified zone, for a Scaleway Organization or Scaleway Project. By default, the Load Balancers returned in the list are ordered by creation date in ascending order, though this can be modified via the order_by field. :param zone: Zone to target. If none is passed will use default zone from the config. :param name: Load Balancer name to filter for. :param order_by: Sort order of Load Balancers in the response. :param page_size: Number of Load Balancers to return. :param page: Page number to return, from the paginated results. :param organization_id: Organization ID to filter for, only Load Balancers from this Organization will be returned. :param project_id: Project ID to filter for, only Load Balancers from this Project will be returned. :param tags: Filter by tag, only Load Balancers with one or more matching tags will be returned. :return: ListLbsResponse

Usage:

result = api.list_lbs()
list_lbs_all(*, zone: str | None = None, name: str | None = None, order_by: ListLbsRequestOrderBy | None = None, page_size: int | None = None, page: int | None = None, organization_id: str | None = None, project_id: str | None = None, tags: List[str] | None = None) List[Lb]

List Load Balancers. List all Load Balancers in the specified zone, for a Scaleway Organization or Scaleway Project. By default, the Load Balancers returned in the list are ordered by creation date in ascending order, though this can be modified via the order_by field. :param zone: Zone to target. If none is passed will use default zone from the config. :param name: Load Balancer name to filter for. :param order_by: Sort order of Load Balancers in the response. :param page_size: Number of Load Balancers to return. :param page: Page number to return, from the paginated results. :param organization_id: Organization ID to filter for, only Load Balancers from this Organization will be returned. :param project_id: Project ID to filter for, only Load Balancers from this Project will be returned. :param tags: Filter by tag, only Load Balancers with one or more matching tags will be returned. :return: List[Lb]

Usage:

result = api.list_lbs_all()
list_routes(*, zone: str | None = None, order_by: ListRoutesRequestOrderBy | None = None, page_size: int | None = None, page: int | None = None, frontend_id: str | None = None) ListRoutesResponse

List all routes. List all routes for a given frontend. The response is an array of routes, each one with a specified backend to direct to if a certain condition is matched (based on the value of the SNI field or HTTP Host header). :param zone: Zone to target. If none is passed will use default zone from the config. :param order_by: Sort order of routes in the response. :param page_size: The number of route objects to return. :param page: The page number to return, from the paginated results. :param frontend_id: Frontend ID to filter for, only Routes from this Frontend will be returned. :return: ListRoutesResponse

Usage:

result = api.list_routes()
list_routes_all(*, zone: str | None = None, order_by: ListRoutesRequestOrderBy | None = None, page_size: int | None = None, page: int | None = None, frontend_id: str | None = None) List[Route]

List all routes. List all routes for a given frontend. The response is an array of routes, each one with a specified backend to direct to if a certain condition is matched (based on the value of the SNI field or HTTP Host header). :param zone: Zone to target. If none is passed will use default zone from the config. :param order_by: Sort order of routes in the response. :param page_size: The number of route objects to return. :param page: The page number to return, from the paginated results. :param frontend_id: Frontend ID to filter for, only Routes from this Frontend will be returned. :return: List[Route]

Usage:

result = api.list_routes_all()
list_subscriber(*, zone: str | None = None, order_by: ListSubscriberRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None, name: str | None = None, organization_id: str | None = None, project_id: str | None = None) ListSubscriberResponse

List all subscribers. List all subscribers to Load Balancer alerts. By default, returns all subscribers to Load Balancer alerts for the Organization associated with the authentication token used for the request. :param zone: Zone to target. If none is passed will use default zone from the config. :param order_by: Sort order of subscribers in the response. :param page: The page number to return, from the paginated results. :param page_size: The number of items to return. :param name: Subscriber name to search for. :param organization_id: Filter subscribers by Organization ID. :param project_id: Filter subscribers by Project ID. :return: ListSubscriberResponse

Usage:

result = api.list_subscriber()
list_subscriber_all(*, zone: str | None = None, order_by: ListSubscriberRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None, name: str | None = None, organization_id: str | None = None, project_id: str | None = None) List[Subscriber]

List all subscribers. List all subscribers to Load Balancer alerts. By default, returns all subscribers to Load Balancer alerts for the Organization associated with the authentication token used for the request. :param zone: Zone to target. If none is passed will use default zone from the config. :param order_by: Sort order of subscribers in the response. :param page: The page number to return, from the paginated results. :param page_size: The number of items to return. :param name: Subscriber name to search for. :param organization_id: Filter subscribers by Organization ID. :param project_id: Filter subscribers by Project ID. :return: List[Subscriber]

Usage:

result = api.list_subscriber_all()
migrate_lb(*, lb_id: str, type_: str, zone: str | None = None) Lb

Migrate a Load Balancer. Migrate an existing Load Balancer from one commercial type to another. Allows you to scale your Load Balancer up or down in terms of bandwidth or multi-cloud provision. :param lb_id: Load Balancer ID. :param type_: Load Balancer type to migrate to (use the List all Load Balancer offer types endpoint to get a list of available offer types). :param zone: Zone to target. If none is passed will use default zone from the config. :return: Lb

Usage:

result = api.migrate_lb(
    lb_id="example",
    type="example",
)
release_ip(*, ip_id: str, zone: str | None = None) None

Delete an IP address. Delete a Load Balancer flexible IP address. This action is irreversible, and cannot be undone. :param ip_id: IP address ID. :param zone: Zone to target. If none is passed will use default zone from the config.

Usage:

result = api.release_ip(
    ip_id="example",
)
remove_backend_servers(*, backend_id: str, server_ip: List[str], zone: str | None = None) Backend

Remove a set of servers for a given backend. For a given backend specified by its backend ID, remove the specified backend servers (identified by their IP addresses) so that it no longer forwards traffic to them. :param backend_id: Backend ID. :param server_ip: List of IP addresses to remove from backend servers. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Backend

Usage:

result = api.remove_backend_servers(
    backend_id="example",
    server_ip=[],
)
set_acls(*, acls: List[AclSpec], frontend_id: str, zone: str | None = None) SetAclsResponse

Define all ACLs for a given frontend. For a given frontend specified by its frontend ID, define and add the complete set of ACLS for that frontend. Any existing ACLs on this frontend will be removed. :param acls: List of ACLs for this frontend. Any other existing ACLs on this frontend will be removed. :param frontend_id: Frontend ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: SetAclsResponse

Usage:

result = api.set_acls(
    acls=[],
    frontend_id="example",
)
set_backend_servers(*, backend_id: str, server_ip: List[str], zone: str | None = None) Backend

Define all backend servers for a given backend. For a given backend specified by its backend ID, define the set of backend servers (identified by their IP addresses) that it should forward traffic to. Any existing backend servers configured for this backend will be removed. :param backend_id: Backend ID. :param server_ip: List of IP addresses for backend servers. Any other existing backend servers will be removed. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Backend

Usage:

result = api.set_backend_servers(
    backend_id="example",
    server_ip=[],
)
subscribe_to_lb(*, lb_id: str, subscriber_id: str, zone: str | None = None) Lb

Subscribe a subscriber to alerts for a given Load Balancer. Subscribe an existing subscriber to alerts for a given Load Balancer. :param lb_id: Load Balancer ID. :param subscriber_id: Subscriber ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Lb

Usage:

result = api.subscribe_to_lb(
    lb_id="example",
    subscriber_id="example",
)
unsubscribe_from_lb(*, lb_id: str, zone: str | None = None) Lb

Unsubscribe a subscriber from alerts for a given Load Balancer. Unsubscribe a subscriber from alerts for a given Load Balancer. The subscriber is not deleted, and can be resubscribed in the future if necessary. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Lb

Usage:

result = api.unsubscribe_from_lb(
    lb_id="example",
)
update_acl(*, acl_id: str, name: str, action: AclAction, index: int, zone: str | None = None, match: AclMatch | None = None, description: str | None = None) Acl

Update an ACL. Update a particular ACL, specified by its ACL ID. You can update details including its name, action and match rule. :param acl_id: ACL ID. :param name: ACL name. :param action: Action to take when incoming traffic matches an ACL filter. :param index: Priority of this ACL (ACLs are applied in ascending order, 0 is the first ACL executed). :param zone: Zone to target. If none is passed will use default zone from the config. :param match: ACL match filter object. One of ip_subnet, ips_edge_services or http_filter & http_filter_value are required. :param description: ACL description. :return: Acl

Usage:

result = api.update_acl(
    acl_id="example",
    name="example",
    action=AclAction(),
    index=1,
)
update_backend(*, backend_id: str, name: str, forward_protocol: Protocol, forward_port: int, forward_port_algorithm: ForwardPortAlgorithm, sticky_sessions: StickySessionsType, sticky_sessions_cookie_name: str, zone: str | None = None, send_proxy_v2: bool | None = None, timeout_server: str | None = None, timeout_connect: str | None = None, timeout_tunnel: str | None = None, on_marked_down_action: OnMarkedDownAction | None = None, proxy_protocol: ProxyProtocol | None = None, failover_host: str | None = None, ssl_bridging: bool | None = None, ignore_ssl_server_verify: bool | None = None, redispatch_attempt_count: int | None = None, max_retries: int | None = None, max_connections: int | None = None, timeout_queue: str | None = None) Backend

Update a backend of a given Load Balancer. Update a backend of a given Load Balancer, specified by its backend ID. Note that the request type is PUT and not PATCH. You must set all parameters. :param backend_id: Backend ID. :param name: Backend name. :param forward_protocol: Protocol to be used by the backend when forwarding traffic to backend servers. :param forward_port: Port to be used by the backend when forwarding traffic to backend servers. :param forward_port_algorithm: Load balancing algorithm to be used when determining which backend server to forward new traffic to. :param sticky_sessions: Defines whether to activate sticky sessions (binding a particular session to a particular backend server) and the method to use if so. None disables sticky sessions. Cookie-based uses an HTTP cookie to stick a session to a backend server. Table-based uses the source (client) IP address to stick a session to a backend server. :param sticky_sessions_cookie_name: Cookie name for cookie-based sticky sessions. :param zone: Zone to target. If none is passed will use default zone from the config. :param send_proxy_v2: Deprecated in favor of proxy_protocol field. :param timeout_server: Maximum allowed time for a backend server to process a request. :param timeout_connect: Maximum allowed time for establishing a connection to a backend server. :param timeout_tunnel: Maximum allowed tunnel inactivity time after Websocket is established (takes precedence over client and server timeout). :param on_marked_down_action: Action to take when a backend server is marked as down. :param proxy_protocol: Protocol to use between the Load Balancer and backend servers. Allows the backend servers to be informed of the client’s real IP address. The PROXY protocol must be supported by the backend servers’ software. :param failover_host: Scaleway Object Storage bucket website to be served as failover if all backend servers are down, e.g. failover-website.s3-website.fr-par.scw.cloud. :param ssl_bridging: Defines whether to enable SSL bridging between the Load Balancer and backend servers. :param ignore_ssl_server_verify: Defines whether the server certificate verification should be ignored. :param redispatch_attempt_count: Whether to use another backend server on each attempt. :param max_retries: Number of retries when a backend server connection failed. :param max_connections: Maximum number of connections allowed per backend server. :param timeout_queue: Maximum time for a request to be left pending in queue when max_connections is reached. :return: Backend

Usage:

result = api.update_backend(
    backend_id="example",
    name="example",
    forward_protocol=Protocol.tcp,
    forward_port=1,
    forward_port_algorithm=ForwardPortAlgorithm.roundrobin,
    sticky_sessions=StickySessionsType.none,
    sticky_sessions_cookie_name="example",
)
update_certificate(*, certificate_id: str, name: str, zone: str | None = None) Certificate

Update an SSL/TLS certificate. Update the name of a particular SSL/TLS certificate, specified by its certificate ID. :param certificate_id: Certificate ID. :param name: Certificate name. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Certificate

Usage:

result = api.update_certificate(
    certificate_id="example",
    name="example",
)
update_frontend(*, frontend_id: str, name: str, inbound_port: int, backend_id: str, enable_http3: bool, zone: str | None = None, timeout_client: str | None = None, certificate_id: str | None = None, certificate_ids: List[str] | None = None, connection_rate_limit: int | None = None, enable_access_logs: bool | None = None) Frontend

Update a frontend. Update a given frontend, specified by its frontend ID. You can update configuration parameters including its name and the port it listens on. Note that the request type is PUT and not PATCH. You must set all parameters. :param frontend_id: Frontend ID. :param name: Frontend name. :param inbound_port: Port the frontend should listen on. :param backend_id: Backend ID (ID of the backend the frontend should pass traffic to). :param enable_http3: Defines whether to enable HTTP/3 protocol on the frontend. :param zone: Zone to target. If none is passed will use default zone from the config. :param timeout_client: Maximum allowed inactivity time on the client side. :param certificate_id: Certificate ID, deprecated in favor of certificate_ids array. :param certificate_ids: List of SSL/TLS certificate IDs to bind to the frontend. :param connection_rate_limit: Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. :param enable_access_logs: Defines whether to enable access logs on the frontend. :return: Frontend

Usage:

result = api.update_frontend(
    frontend_id="example",
    name="example",
    inbound_port=1,
    backend_id="example",
    enable_http3=False,
)
update_health_check(*, port: int, check_max_retries: int, backend_id: str, zone: str | None = None, check_delay: str | None = None, check_timeout: str | None = None, check_send_proxy: bool, tcp_config: HealthCheckTcpConfig | None = None, mysql_config: HealthCheckMysqlConfig | None = None, pgsql_config: HealthCheckPgsqlConfig | None = None, ldap_config: HealthCheckLdapConfig | None = None, redis_config: HealthCheckRedisConfig | None = None, http_config: HealthCheckHttpConfig | None = None, https_config: HealthCheckHttpsConfig | None = None, transient_check_delay: str | None = None) HealthCheck

Update a health check for a given backend. Update the configuration of the health check performed by a given backend to verify the health of its backend servers, identified by its backend ID. Note that the request type is PUT and not PATCH. You must set all parameters. :param port: Port to use for the backend server health check. :param check_max_retries: Number of consecutive unsuccessful health checks after which the server will be considered dead. :param backend_id: Backend ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param check_delay: Time to wait between two consecutive health checks. :param check_timeout: Maximum time a backend server has to reply to the health check. :param check_send_proxy: Defines whether proxy protocol should be activated for the health check. :param tcp_config: Object to configure a basic TCP health check. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param mysql_config: Object to configure a MySQL health check. The check requires MySQL >=3.22 or <9.0. For older or newer versions, use a TCP health check. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param pgsql_config: Object to configure a PostgreSQL health check. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param ldap_config: Object to configure an LDAP health check. The response is analyzed to find the LDAPv3 response message. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param redis_config: Object to configure a Redis health check. The response is analyzed to find the +PONG response message. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param http_config: Object to configure an HTTP health check. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param https_config: Object to configure an HTTPS health check. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param transient_check_delay: Time to wait between two consecutive health checks when a backend server is in a transient state (going UP or DOWN). :return: HealthCheck

Usage:

result = api.update_health_check(
    port=1,
    check_max_retries=1,
    backend_id="example",
    check_send_proxy=False,
)
update_ip(*, ip_id: str, zone: str | None = None, reverse: str | None = None, lb_id: str | None = None, tags: List[str] | None = None) Ip

Update an IP address. Update the reverse DNS of a Load Balancer flexible IP address. :param ip_id: IP address ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param reverse: Reverse DNS (domain name) for the IP address. :param lb_id: ID of the server on which to attach the flexible IP. :param tags: List of tags for the IP. :return: Ip

Usage:

result = api.update_ip(
    ip_id="example",
)
update_lb(*, lb_id: str, name: str, description: str, zone: str | None = None, tags: List[str] | None = None, ssl_compatibility_level: SSLCompatibilityLevel | None = None) Lb

Update a Load Balancer. Update the parameters of an existing Load Balancer, specified by its Load Balancer ID. Note that the request type is PUT and not PATCH. You must set all parameters. :param lb_id: Load Balancer ID. :param name: Load Balancer name. :param description: Load Balancer description. :param zone: Zone to target. If none is passed will use default zone from the config. :param tags: List of tags for the Load Balancer. :param ssl_compatibility_level: Determines the minimal SSL version which needs to be supported on the client side, in an SSL/TLS offloading context. Intermediate is suitable for general-purpose servers with a variety of clients, recommended for almost all systems. Modern is suitable for services with clients that support TLS 1.3 and don’t need backward compatibility. Old is compatible with a small number of very old clients and should be used only as a last resort. :return: Lb

Usage:

result = api.update_lb(
    lb_id="example",
    name="example",
    description="example",
)
update_route(*, route_id: str, backend_id: str, zone: str | None = None, match: RouteMatch | None = None) Route

Update a route. Update the configuration of an existing route, specified by its route ID. :param route_id: Route ID. :param backend_id: ID of the target backend for the route. :param zone: Zone to target. If none is passed will use default zone from the config. :param match: Object defining the match condition for a route to be applied. If an incoming client session matches the specified condition (i.e. it has a matching SNI value or HTTP Host header value), it will be passed to the target backend. :return: Route

Usage:

result = api.update_route(
    route_id="example",
    backend_id="example",
)
update_subscriber(*, subscriber_id: str, name: str, zone: str | None = None, email_config: SubscriberEmailConfig | None = None, webhook_config: SubscriberWebhookConfig | None = None) Subscriber

Update a subscriber. Update the parameters of a given subscriber (e.g. name, webhook configuration, email configuration), specified by its subscriber ID. :param subscriber_id: Subscriber ID. :param name: Subscriber name. :param zone: Zone to target. If none is passed will use default zone from the config. :param email_config: Email address configuration. One-Of (‘config’): at most one of ‘email_config’, ‘webhook_config’ could be set. :param webhook_config: Webhook URI configuration. One-Of (‘config’): at most one of ‘email_config’, ‘webhook_config’ could be set. :return: Subscriber

Usage:

result = api.update_subscriber(
    subscriber_id="example",
    name="example",
)
wait_for_certificate(*, certificate_id: str, zone: str | None = None, options: WaitForOptions[Certificate, bool] | None = None) Certificate

Get an SSL/TLS certificate. Get information for a particular SSL/TLS certificate, specified by its certificate ID. The response returns full details of the certificate, including its type, main domain name, and alternative domain names. :param certificate_id: Certificate ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Certificate

Usage:

result = api.get_certificate(
    certificate_id="example",
)
wait_for_lb(*, lb_id: str, zone: str | None = None, options: WaitForOptions[Lb, bool] | None = None) Lb

Get a Load Balancer. Retrieve information about an existing Load Balancer, specified by its Load Balancer ID. Its full details, including name, status and IP address, are returned in the response object. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Lb

Usage:

result = api.get_lb(
    lb_id="example",
)

scaleway.lb.v1.content module

scaleway.lb.v1.content.CERTIFICATE_TRANSIENT_STATUSES: List[CertificateStatus] = [<CertificateStatus.PENDING: 'pending'>]

Lists transient statutes of the enum CertificateStatus.

scaleway.lb.v1.content.INSTANCE_TRANSIENT_STATUSES: List[InstanceStatus] = [<InstanceStatus.PENDING: 'pending'>, <InstanceStatus.MIGRATING: 'migrating'>]

Lists transient statutes of the enum InstanceStatus.

scaleway.lb.v1.content.LB_TRANSIENT_STATUSES: List[LbStatus] = [<LbStatus.PENDING: 'pending'>, <LbStatus.MIGRATING: 'migrating'>, <LbStatus.TO_CREATE: 'to_create'>, <LbStatus.CREATING: 'creating'>, <LbStatus.TO_DELETE: 'to_delete'>, <LbStatus.DELETING: 'deleting'>]

Lists transient statutes of the enum LbStatus.

scaleway.lb.v1.content.PRIVATE_NETWORK_TRANSIENT_STATUSES: List[PrivateNetworkStatus] = [<PrivateNetworkStatus.PENDING: 'pending'>]

Lists transient statutes of the enum PrivateNetworkStatus.

scaleway.lb.v1.marshalling module

scaleway.lb.v1.marshalling.marshal_AclAction(request: AclAction, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_AclActionRedirect(request: AclActionRedirect, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_AclMatch(request: AclMatch, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_AclSpec(request: AclSpec, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_AddBackendServersRequest(request: AddBackendServersRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_AttachPrivateNetworkRequest(request: AttachPrivateNetworkRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_CreateAclRequest(request: CreateAclRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_CreateBackendRequest(request: CreateBackendRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_CreateCertificateRequest(request: CreateCertificateRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_CreateCertificateRequestCustomCertificate(request: CreateCertificateRequestCustomCertificate, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_CreateCertificateRequestLetsencryptConfig(request: CreateCertificateRequestLetsencryptConfig, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_CreateFrontendRequest(request: CreateFrontendRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_CreateIpRequest(request: CreateIpRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_CreateLbRequest(request: CreateLbRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_CreateRouteRequest(request: CreateRouteRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_CreateSubscriberRequest(request: CreateSubscriberRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_HealthCheck(request: HealthCheck, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_HealthCheckHttpConfig(request: HealthCheckHttpConfig, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_HealthCheckHttpsConfig(request: HealthCheckHttpsConfig, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_HealthCheckLdapConfig(request: HealthCheckLdapConfig, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_HealthCheckMysqlConfig(request: HealthCheckMysqlConfig, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_HealthCheckPgsqlConfig(request: HealthCheckPgsqlConfig, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_HealthCheckRedisConfig(request: HealthCheckRedisConfig, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_HealthCheckTcpConfig(request: HealthCheckTcpConfig, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_MigrateLbRequest(request: MigrateLbRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_PrivateNetworkDHCPConfig(request: PrivateNetworkDHCPConfig, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_PrivateNetworkIpamConfig(request: PrivateNetworkIpamConfig, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_PrivateNetworkStaticConfig(request: PrivateNetworkStaticConfig, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_RemoveBackendServersRequest(request: RemoveBackendServersRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_RouteMatch(request: RouteMatch, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_SetBackendServersRequest(request: SetBackendServersRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_SubscribeToLbRequest(request: SubscribeToLbRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_SubscriberEmailConfig(request: SubscriberEmailConfig, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_SubscriberWebhookConfig(request: SubscriberWebhookConfig, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_UpdateAclRequest(request: UpdateAclRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_UpdateBackendRequest(request: UpdateBackendRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_UpdateCertificateRequest(request: UpdateCertificateRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_UpdateFrontendRequest(request: UpdateFrontendRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_UpdateHealthCheckRequest(request: UpdateHealthCheckRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_UpdateIpRequest(request: UpdateIpRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_UpdateLbRequest(request: UpdateLbRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_UpdateRouteRequest(request: UpdateRouteRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_UpdateSubscriberRequest(request: UpdateSubscriberRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_ZonedApiAddBackendServersRequest(request: ZonedApiAddBackendServersRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_ZonedApiAttachPrivateNetworkRequest(request: ZonedApiAttachPrivateNetworkRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_ZonedApiCreateAclRequest(request: ZonedApiCreateAclRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_ZonedApiCreateBackendRequest(request: ZonedApiCreateBackendRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_ZonedApiCreateCertificateRequest(request: ZonedApiCreateCertificateRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_ZonedApiCreateFrontendRequest(request: ZonedApiCreateFrontendRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_ZonedApiCreateIpRequest(request: ZonedApiCreateIpRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_ZonedApiCreateLbRequest(request: ZonedApiCreateLbRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_ZonedApiCreateRouteRequest(request: ZonedApiCreateRouteRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_ZonedApiCreateSubscriberRequest(request: ZonedApiCreateSubscriberRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_ZonedApiDetachPrivateNetworkRequest(request: ZonedApiDetachPrivateNetworkRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_ZonedApiMigrateLbRequest(request: ZonedApiMigrateLbRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_ZonedApiRemoveBackendServersRequest(request: ZonedApiRemoveBackendServersRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_ZonedApiSetAclsRequest(request: ZonedApiSetAclsRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_ZonedApiSetBackendServersRequest(request: ZonedApiSetBackendServersRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_ZonedApiSubscribeToLbRequest(request: ZonedApiSubscribeToLbRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_ZonedApiUpdateAclRequest(request: ZonedApiUpdateAclRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_ZonedApiUpdateBackendRequest(request: ZonedApiUpdateBackendRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_ZonedApiUpdateCertificateRequest(request: ZonedApiUpdateCertificateRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_ZonedApiUpdateFrontendRequest(request: ZonedApiUpdateFrontendRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_ZonedApiUpdateHealthCheckRequest(request: ZonedApiUpdateHealthCheckRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_ZonedApiUpdateIpRequest(request: ZonedApiUpdateIpRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_ZonedApiUpdateLbRequest(request: ZonedApiUpdateLbRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_ZonedApiUpdateRouteRequest(request: ZonedApiUpdateRouteRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.marshal_ZonedApiUpdateSubscriberRequest(request: ZonedApiUpdateSubscriberRequest, defaults: ProfileDefaults) Dict[str, Any]
scaleway.lb.v1.marshalling.unmarshal_Acl(data: Any) Acl
scaleway.lb.v1.marshalling.unmarshal_AclAction(data: Any) AclAction
scaleway.lb.v1.marshalling.unmarshal_AclActionRedirect(data: Any) AclActionRedirect
scaleway.lb.v1.marshalling.unmarshal_AclMatch(data: Any) AclMatch
scaleway.lb.v1.marshalling.unmarshal_Backend(data: Any) Backend
scaleway.lb.v1.marshalling.unmarshal_BackendServerStats(data: Any) BackendServerStats
scaleway.lb.v1.marshalling.unmarshal_Certificate(data: Any) Certificate
scaleway.lb.v1.marshalling.unmarshal_Frontend(data: Any) Frontend
scaleway.lb.v1.marshalling.unmarshal_HealthCheck(data: Any) HealthCheck
scaleway.lb.v1.marshalling.unmarshal_HealthCheckHttpConfig(data: Any) HealthCheckHttpConfig
scaleway.lb.v1.marshalling.unmarshal_HealthCheckHttpsConfig(data: Any) HealthCheckHttpsConfig
scaleway.lb.v1.marshalling.unmarshal_HealthCheckLdapConfig(data: Any) HealthCheckLdapConfig
scaleway.lb.v1.marshalling.unmarshal_HealthCheckMysqlConfig(data: Any) HealthCheckMysqlConfig
scaleway.lb.v1.marshalling.unmarshal_HealthCheckPgsqlConfig(data: Any) HealthCheckPgsqlConfig
scaleway.lb.v1.marshalling.unmarshal_HealthCheckRedisConfig(data: Any) HealthCheckRedisConfig
scaleway.lb.v1.marshalling.unmarshal_HealthCheckTcpConfig(data: Any) HealthCheckTcpConfig
scaleway.lb.v1.marshalling.unmarshal_Instance(data: Any) Instance
scaleway.lb.v1.marshalling.unmarshal_Ip(data: Any) Ip
scaleway.lb.v1.marshalling.unmarshal_Lb(data: Any) Lb
scaleway.lb.v1.marshalling.unmarshal_LbStats(data: Any) LbStats
scaleway.lb.v1.marshalling.unmarshal_LbType(data: Any) LbType
scaleway.lb.v1.marshalling.unmarshal_ListAclResponse(data: Any) ListAclResponse
scaleway.lb.v1.marshalling.unmarshal_ListBackendStatsResponse(data: Any) ListBackendStatsResponse
scaleway.lb.v1.marshalling.unmarshal_ListBackendsResponse(data: Any) ListBackendsResponse
scaleway.lb.v1.marshalling.unmarshal_ListCertificatesResponse(data: Any) ListCertificatesResponse
scaleway.lb.v1.marshalling.unmarshal_ListFrontendsResponse(data: Any) ListFrontendsResponse
scaleway.lb.v1.marshalling.unmarshal_ListIpsResponse(data: Any) ListIpsResponse
scaleway.lb.v1.marshalling.unmarshal_ListLbPrivateNetworksResponse(data: Any) ListLbPrivateNetworksResponse
scaleway.lb.v1.marshalling.unmarshal_ListLbTypesResponse(data: Any) ListLbTypesResponse
scaleway.lb.v1.marshalling.unmarshal_ListLbsResponse(data: Any) ListLbsResponse
scaleway.lb.v1.marshalling.unmarshal_ListRoutesResponse(data: Any) ListRoutesResponse
scaleway.lb.v1.marshalling.unmarshal_ListSubscriberResponse(data: Any) ListSubscriberResponse
scaleway.lb.v1.marshalling.unmarshal_PrivateNetwork(data: Any) PrivateNetwork
scaleway.lb.v1.marshalling.unmarshal_PrivateNetworkDHCPConfig(data: Any) PrivateNetworkDHCPConfig
scaleway.lb.v1.marshalling.unmarshal_PrivateNetworkIpamConfig(data: Any) PrivateNetworkIpamConfig
scaleway.lb.v1.marshalling.unmarshal_PrivateNetworkStaticConfig(data: Any) PrivateNetworkStaticConfig
scaleway.lb.v1.marshalling.unmarshal_Route(data: Any) Route
scaleway.lb.v1.marshalling.unmarshal_RouteMatch(data: Any) RouteMatch
scaleway.lb.v1.marshalling.unmarshal_SetAclsResponse(data: Any) SetAclsResponse
scaleway.lb.v1.marshalling.unmarshal_Subscriber(data: Any) Subscriber
scaleway.lb.v1.marshalling.unmarshal_SubscriberEmailConfig(data: Any) SubscriberEmailConfig
scaleway.lb.v1.marshalling.unmarshal_SubscriberWebhookConfig(data: Any) SubscriberWebhookConfig

scaleway.lb.v1.types module

class scaleway.lb.v1.types.Acl(id: 'str', name: 'str', index: 'int', description: 'str', match: 'Optional[AclMatch]' = None, action: 'Optional[AclAction]' = None, frontend: 'Optional[Frontend]' = None, created_at: 'Optional[datetime]' = None, updated_at: 'Optional[datetime]' = None)

Bases: object

action: AclAction | None = None

Action to take when incoming traffic matches an ACL filter.

created_at: datetime | None = None

Date on which the ACL was created.

description: str

ACL description.

frontend: Frontend | None = None

ACL is attached to this frontend object.

id: str

ACL ID.

index: int

Priority of this ACL (ACLs are applied in ascending order, 0 is the first ACL executed).

match: AclMatch | None = None

ACL match filter object. One of ip_subnet, ips_edge_services or http_filter & http_filter_value are required.

name: str

ACL name.

updated_at: datetime | None = None

Date on which the ACL was last updated.

class scaleway.lb.v1.types.AclAction(type_: 'AclActionType', redirect: 'Optional[AclActionRedirect]' = None)

Bases: object

redirect: AclActionRedirect | None = None

Redirection parameters when using an ACL with a redirect action.

type_: AclActionType

Action to take when incoming traffic matches an ACL filter.

class scaleway.lb.v1.types.AclActionRedirect(type_: 'AclActionRedirectRedirectType', target: 'str', code: 'Optional[int]' = 0)

Bases: object

code: int | None = 0

HTTP redirect code to use. Valid values are 301, 302, 303, 307 and 308. Default value is 302.

target: str

Redirect target. For a location redirect, you can use a URL e.g. https://scaleway.com. Using a scheme name (e.g. https, http, ftp, git) will replace the request’s original scheme. This can be useful to implement HTTP to HTTPS redirects. Valid placeholders that can be used in a location redirect to preserve parts of the original request in the redirection URL are {{host}}, {{query}}, {{path}} and {{scheme}}.

type_: AclActionRedirectRedirectType

Redirect type.

class scaleway.lb.v1.types.AclActionRedirectRedirectType(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

LOCATION = 'location'
SCHEME = 'scheme'
class scaleway.lb.v1.types.AclActionType(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

ALLOW = 'allow'
DENY = 'deny'
REDIRECT = 'redirect'
class scaleway.lb.v1.types.AclHttpFilter(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

ACL_HTTP_FILTER_NONE = 'acl_http_filter_none'
HTTP_HEADER_MATCH = 'http_header_match'
PATH_BEGIN = 'path_begin'
PATH_END = 'path_end'
REGEX = 'regex'
class scaleway.lb.v1.types.AclMatch(ip_subnet: 'List[str]', ips_edge_services: 'bool', http_filter: 'AclHttpFilter', http_filter_value: 'List[str]', invert: 'bool', http_filter_option: 'Optional[str]' = None)

Bases: object

http_filter: AclHttpFilter

Type of HTTP filter to match. Extracts the request’s URL path, which starts at the first slash and ends before the question mark (without the host part). Defines where to filter for the http_filter_value. Only supported for HTTP backends.

http_filter_option: str | None = None

Name of the HTTP header to filter on if http_header_match was selected in http_filter.

http_filter_value: List[str]

List of values to filter for.

invert: bool

Defines whether to invert the match condition. If set to true, the ACL carries out its action when the condition DOES NOT match.

ip_subnet: List[str]

List of IPs or CIDR v4/v6 addresses to filter for from the client side.

ips_edge_services: bool

Defines whether Edge Services IPs should be matched.

class scaleway.lb.v1.types.AclSpec(name: 'str', action: 'AclAction', index: 'int', description: 'str', match: 'Optional[AclMatch]' = None)

Bases: object

action: AclAction

Action to take when incoming traffic matches an ACL filter.

description: str

ACL description.

index: int

Priority of this ACL (ACLs are applied in ascending order, 0 is the first ACL executed).

match: AclMatch | None = None

ACL match filter object. One of ip_subnet, ips_edge_services or http_filter and http_filter_value are required.

name: str

ACL name.

class scaleway.lb.v1.types.AddBackendServersRequest(backend_id: 'str', server_ip: 'List[str]', region: 'Optional[ScwRegion]' = None)

Bases: object

backend_id: str

Backend ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

server_ip: List[str]

List of IP addresses to add to backend servers.

class scaleway.lb.v1.types.AttachPrivateNetworkRequest(lb_id: 'str', private_network_id: 'str', region: 'Optional[ScwRegion]' = None, ipam_ids: 'Optional[List[str]]' = <factory>, static_config: 'Optional[PrivateNetworkStaticConfig]' = None, dhcp_config: 'Optional[PrivateNetworkDHCPConfig]' = None, ipam_config: 'Optional[PrivateNetworkIpamConfig]' = None)

Bases: object

dhcp_config: PrivateNetworkDHCPConfig | None = None
ipam_config: PrivateNetworkIpamConfig | None = None
ipam_ids: List[str] | None

IPAM ID of a pre-reserved IP address to assign to the Load Balancer on this Private Network. In the future, it will be possible to specify multiple IPs in this field (IPv4 and IPv6), for now only one ID of an IPv4 address is expected. When null, a new private IP address is created for the Load Balancer on this Private Network.

lb_id: str

Load Balancer ID.

private_network_id: str

Private Network ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

static_config: PrivateNetworkStaticConfig | None = None
class scaleway.lb.v1.types.Backend(id: 'str', name: 'str', forward_protocol: 'Protocol', forward_port: 'int', forward_port_algorithm: 'ForwardPortAlgorithm', sticky_sessions: 'StickySessionsType', sticky_sessions_cookie_name: 'str', pool: 'List[str]', on_marked_down_action: 'OnMarkedDownAction', proxy_protocol: 'ProxyProtocol', health_check: 'Optional[HealthCheck]' = None, lb: 'Optional[Lb]' = None, send_proxy_v2: 'Optional[bool]' = False, timeout_server: 'Optional[str]' = None, timeout_connect: 'Optional[str]' = None, timeout_tunnel: 'Optional[str]' = None, created_at: 'Optional[datetime]' = None, updated_at: 'Optional[datetime]' = None, failover_host: 'Optional[str]' = None, ssl_bridging: 'Optional[bool]' = False, ignore_ssl_server_verify: 'Optional[bool]' = False, redispatch_attempt_count: 'Optional[int]' = 0, max_retries: 'Optional[int]' = 0, max_connections: 'Optional[int]' = 0, timeout_queue: 'Optional[str]' = None)

Bases: object

created_at: datetime | None = None

Date at which the backend was created.

failover_host: str | None = None

Scaleway Object Storage bucket website to be served as failover if all backend servers are down, e.g. failover-website.s3-website.fr-par.scw.cloud.

forward_port: int

Port used by the backend when forwarding traffic to backend servers.

forward_port_algorithm: ForwardPortAlgorithm

Load balancing algorithm to use when determining which backend server to forward new traffic to.

forward_protocol: Protocol

Protocol used by the backend when forwarding traffic to backend servers.

health_check: HealthCheck | None = None

Object defining the health check to be carried out by the backend when checking the status and health of backend servers.

id: str

Backend ID.

ignore_ssl_server_verify: bool | None = False

Defines whether the server certificate verification should be ignored.

lb: Lb | None = None

Load Balancer the backend is attached to.

max_connections: int | None = 0

Maximum number of connections allowed per backend server.

max_retries: int | None = 0

Number of retries when a backend server connection failed.

name: str

Name of the backend.

on_marked_down_action: OnMarkedDownAction

Action to take when a backend server is marked as down.

pool: List[str]

List of IP addresses of backend servers attached to this backend.

proxy_protocol: ProxyProtocol

Protocol to use between the Load Balancer and backend servers. Allows the backend servers to be informed of the client’s real IP address. The PROXY protocol must be supported by the backend servers’ software.

redispatch_attempt_count: int | None = 0

Whether to use another backend server on each attempt.

send_proxy_v2: bool | None = False

Deprecated in favor of proxy_protocol field.

ssl_bridging: bool | None = False

Defines whether to enable SSL bridging between the Load Balancer and backend servers.

sticky_sessions: StickySessionsType

Defines whether sticky sessions (binding a particular session to a particular backend server) are activated and the method to use if so. None disables sticky sessions. Cookie-based uses an HTTP cookie to stick a session to a backend server. Table-based uses the source (client) IP address to stick a session to a backend server.

Cookie name for cookie-based sticky sessions.

timeout_connect: str | None = None

Maximum allowed time for establishing a connection to a backend server.

timeout_queue: str | None = None

Maximum time for a request to be left pending in queue when max_connections is reached.

timeout_server: str | None = None

Maximum allowed time for a backend server to process a request.

timeout_tunnel: str | None = None

Maximum allowed tunnel inactivity time after Websocket is established (takes precedence over client and server timeout).

updated_at: datetime | None = None

Date at which the backend was updated.

class scaleway.lb.v1.types.BackendServerStats(instance_id: 'str', backend_id: 'str', ip: 'str', server_state: 'BackendServerStatsServerState', last_health_check_status: 'BackendServerStatsHealthCheckStatus', server_state_changed_at: 'Optional[datetime]' = None)

Bases: object

backend_id: str

Backend ID.

instance_id: str

ID of your Load Balancer’s underlying Instance.

ip: str

IPv4 or IPv6 address of the backend server.

last_health_check_status: BackendServerStatsHealthCheckStatus

Last health check status (unknown/neutral/failed/passed/condpass).

server_state: BackendServerStatsServerState

Server operational state (stopped/starting/running/stopping).

server_state_changed_at: datetime | None = None

Time since last operational change.

class scaleway.lb.v1.types.BackendServerStatsHealthCheckStatus(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

CONDPASS = 'condpass'
FAILED = 'failed'
NEUTRAL = 'neutral'
PASSED = 'passed'
UNKNOWN = 'unknown'
class scaleway.lb.v1.types.BackendServerStatsServerState(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

RUNNING = 'running'
STARTING = 'starting'
STOPPED = 'stopped'
STOPPING = 'stopping'
class scaleway.lb.v1.types.Certificate(type_: 'CertificateType', id: 'str', common_name: 'str', subject_alternative_name: 'List[str]', fingerprint: 'str', status: 'CertificateStatus', name: 'str', not_valid_before: 'Optional[datetime]' = None, not_valid_after: 'Optional[datetime]' = None, lb: 'Optional[Lb]' = None, created_at: 'Optional[datetime]' = None, updated_at: 'Optional[datetime]' = None, status_details: 'Optional[str]' = None)

Bases: object

common_name: str

Main domain name of certificate.

created_at: datetime | None = None

Date on which the certificate was created.

fingerprint: str

Identifier (SHA-1) of the certificate.

id: str

Certificate ID.

lb: Lb | None = None

Load Balancer object the certificate is attached to.

name: str

Certificate name.

not_valid_after: datetime | None = None

Upper validity bound.

not_valid_before: datetime | None = None

Lower validity bound.

status: CertificateStatus

Certificate status.

status_details: str | None = None

Additional information about the certificate status (useful in case of certificate generation failure, for example).

subject_alternative_name: List[str]

Alternative domain names.

type_: CertificateType

Certificate type (Let’s Encrypt or custom).

updated_at: datetime | None = None

Date on which the certificate was last updated.

class scaleway.lb.v1.types.CertificateStatus(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

ERROR = 'error'
PENDING = 'pending'
READY = 'ready'
class scaleway.lb.v1.types.CertificateType(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

CUSTOM = 'custom'
LETSENCRYT = 'letsencryt'
class scaleway.lb.v1.types.CreateAclRequest(frontend_id: str, action: AclAction, index: int, description: str, region: str | None = None, name: str | None = None, match: AclMatch | None = None)

Bases: object

Add an ACL to a Load Balancer frontend.

action: AclAction

Action to take when incoming traffic matches an ACL filter.

description: str

ACL description.

frontend_id: str

Frontend ID to attach the ACL to.

index: int

Priority of this ACL (ACLs are applied in ascending order, 0 is the first ACL executed).

match: AclMatch | None = None

ACL match filter object. One of ip_subnet, ips_edge_services or http_filter & http_filter_value are required.

name: str | None = None

ACL name.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.CreateBackendRequest(forward_protocol: 'Protocol', forward_port: 'int', forward_port_algorithm: 'ForwardPortAlgorithm', sticky_sessions: 'StickySessionsType', sticky_sessions_cookie_name: 'str', lb_id: 'str', health_check: 'HealthCheck', server_ip: 'List[str]', region: 'Optional[ScwRegion]' = None, name: 'Optional[str]' = None, send_proxy_v2: 'Optional[bool]' = False, timeout_server: 'Optional[str]' = None, timeout_connect: 'Optional[str]' = None, timeout_tunnel: 'Optional[str]' = None, on_marked_down_action: 'Optional[OnMarkedDownAction]' = <OnMarkedDownAction.ON_MARKED_DOWN_ACTION_NONE: 'on_marked_down_action_none'>, proxy_protocol: 'Optional[ProxyProtocol]' = <ProxyProtocol.PROXY_PROTOCOL_UNKNOWN: 'proxy_protocol_unknown'>, failover_host: 'Optional[str]' = None, ssl_bridging: 'Optional[bool]' = False, ignore_ssl_server_verify: 'Optional[bool]' = False, redispatch_attempt_count: 'Optional[int]' = 0, max_retries: 'Optional[int]' = 0, max_connections: 'Optional[int]' = 0, timeout_queue: 'Optional[str]' = None)

Bases: object

failover_host: str | None = None

Scaleway Object Storage bucket website to be served as failover if all backend servers are down, e.g. failover-website.s3-website.fr-par.scw.cloud.

forward_port: int

Port to be used by the backend when forwarding traffic to backend servers.

forward_port_algorithm: ForwardPortAlgorithm

Load balancing algorithm to be used when determining which backend server to forward new traffic to.

forward_protocol: Protocol

Protocol to be used by the backend when forwarding traffic to backend servers.

health_check: HealthCheck

Object defining the health check to be carried out by the backend when checking the status and health of backend servers.

ignore_ssl_server_verify: bool | None = False

Defines whether the server certificate verification should be ignored.

lb_id: str

Load Balancer ID.

max_connections: int | None = 0

Maximum number of connections allowed per backend server.

max_retries: int | None = 0

Number of retries when a backend server connection failed.

name: str | None = None

Name for the backend.

on_marked_down_action: OnMarkedDownAction | None = 'on_marked_down_action_none'

Action to take when a backend server is marked as down.

proxy_protocol: ProxyProtocol | None = 'proxy_protocol_unknown'

Protocol to use between the Load Balancer and backend servers. Allows the backend servers to be informed of the client’s real IP address. The PROXY protocol must be supported by the backend servers’ software.

redispatch_attempt_count: int | None = 0

Whether to use another backend server on each attempt.

region: str | None = None

Region to target. If none is passed will use default region from the config.

send_proxy_v2: bool | None = False

Deprecated in favor of proxy_protocol field.

server_ip: List[str]

List of backend server IP addresses (IPv4 or IPv6) the backend should forward traffic to.

ssl_bridging: bool | None = False

Defines whether to enable SSL bridging between the Load Balancer and backend servers.

sticky_sessions: StickySessionsType

Defines whether to activate sticky sessions (binding a particular session to a particular backend server) and the method to use if so. None disables sticky sessions. Cookie-based uses an HTTP cookie TO stick a session to a backend server. Table-based uses the source (client) IP address to stick a session to a backend server.

Cookie name for cookie-based sticky sessions.

timeout_connect: str | None = None

Maximum allowed time for establishing a connection to a backend server.

timeout_queue: str | None = None

Maximum time for a request to be left pending in queue when max_connections is reached.

timeout_server: str | None = None

Maximum allowed time for a backend server to process a request.

timeout_tunnel: str | None = None

Maximum allowed tunnel inactivity time after Websocket is established (takes precedence over client and server timeout).

class scaleway.lb.v1.types.CreateCertificateRequest(lb_id: 'str', region: 'Optional[ScwRegion]' = None, name: 'Optional[str]' = None, letsencrypt: 'Optional[CreateCertificateRequestLetsencryptConfig]' = None, custom_certificate: 'Optional[CreateCertificateRequestCustomCertificate]' = None)

Bases: object

custom_certificate: CreateCertificateRequestCustomCertificate | None = None
lb_id: str

Load Balancer ID.

letsencrypt: CreateCertificateRequestLetsencryptConfig | None = None
name: str | None = None

Name for the certificate.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.CreateCertificateRequestCustomCertificate(certificate_chain: 'str')

Bases: object

certificate_chain: str

Full PEM-formatted certificate, consisting of the entire certificate chain including public key, private key, and (optionally) Certificate Authorities.

class scaleway.lb.v1.types.CreateCertificateRequestLetsencryptConfig(common_name: 'str', subject_alternative_name: 'List[str]')

Bases: object

common_name: str

Main domain name of certificate (this domain must exist and resolve to your Load Balancer IP address).

subject_alternative_name: List[str]

Alternative domain names (all domain names must exist and resolve to your Load Balancer IP address).

class scaleway.lb.v1.types.CreateFrontendRequest(inbound_port: 'int', lb_id: 'str', backend_id: 'str', enable_http3: 'bool', enable_access_logs: 'bool', region: 'Optional[ScwRegion]' = None, name: 'Optional[str]' = None, timeout_client: 'Optional[str]' = None, certificate_id: 'Optional[str]' = None, certificate_ids: 'Optional[List[str]]' = <factory>, connection_rate_limit: 'Optional[int]' = 0)

Bases: object

backend_id: str

Backend ID (ID of the backend the frontend should pass traffic to).

certificate_id: str | None = None

Certificate ID, deprecated in favor of certificate_ids array.

certificate_ids: List[str] | None

List of SSL/TLS certificate IDs to bind to the frontend.

connection_rate_limit: int | None = 0

Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second.

enable_access_logs: bool

Defines whether to enable access logs on the frontend.

enable_http3: bool

Defines whether to enable HTTP/3 protocol on the frontend.

inbound_port: int

Port the frontend should listen on.

lb_id: str

Load Balancer ID (ID of the Load Balancer to attach the frontend to).

name: str | None = None

Name for the frontend.

region: str | None = None

Region to target. If none is passed will use default region from the config.

timeout_client: str | None = None

Maximum allowed inactivity time on the client side.

class scaleway.lb.v1.types.CreateIpRequest(is_ipv6: 'bool', region: 'Optional[ScwRegion]' = None, reverse: 'Optional[str]' = None, tags: 'Optional[List[str]]' = <factory>, project_id: 'Optional[str]' = None, organization_id: 'Optional[str]' = None)

Bases: object

is_ipv6: bool

If true, creates a Flexible IP with an ipv6 address.

organization_id: str | None = None
project_id: str | None = None
region: str | None = None

Region to target. If none is passed will use default region from the config.

reverse: str | None = None

Reverse DNS (domain name) for the IP address.

tags: List[str] | None

List of tags for the IP.

class scaleway.lb.v1.types.CreateLbRequest(description: 'str', type_: 'str', region: 'Optional[ScwRegion]' = None, name: 'Optional[str]' = None, ip_id: 'Optional[str]' = None, assign_flexible_ip: 'Optional[bool]' = False, assign_flexible_ipv6: 'Optional[bool]' = False, ip_ids: 'Optional[List[str]]' = <factory>, tags: 'Optional[List[str]]' = <factory>, ssl_compatibility_level: 'Optional[SSLCompatibilityLevel]' = <SSLCompatibilityLevel.SSL_COMPATIBILITY_LEVEL_UNKNOWN: 'ssl_compatibility_level_unknown'>, project_id: 'Optional[str]' = None, organization_id: 'Optional[str]' = None)

Bases: object

assign_flexible_ip: bool | None = False

Defines whether to automatically assign a flexible public IP to the Load Balancer. Default value is true (assign).

assign_flexible_ipv6: bool | None = False

Defines whether to automatically assign a flexible public IPv6 to the Load Balancer. Default value is false (do not assign).

description: str

Description for the Load Balancer.

ip_id: str | None = None

ID of an existing flexible IP address to attach to the Load Balancer.

ip_ids: List[str] | None

List of IP IDs to attach to the Load Balancer.

name: str | None = None

Name for the Load Balancer.

organization_id: str | None = None
project_id: str | None = None
region: str | None = None

Region to target. If none is passed will use default region from the config.

ssl_compatibility_level: SSLCompatibilityLevel | None = 'ssl_compatibility_level_unknown'

Determines the minimal SSL version which needs to be supported on the client side, in an SSL/TLS offloading context. Intermediate is suitable for general-purpose servers with a variety of clients, recommended for almost all systems. Modern is suitable for services with clients that support TLS 1.3 and do not need backward compatibility. Old is compatible with a small number of very old clients and should be used only as a last resort.

tags: List[str] | None

List of tags for the Load Balancer.

type_: str

Load Balancer commercial offer type. Use the Load Balancer types endpoint to retrieve a list of available offer types.

class scaleway.lb.v1.types.CreateRouteRequest(frontend_id: 'str', backend_id: 'str', region: 'Optional[ScwRegion]' = None, match: 'Optional[RouteMatch]' = None)

Bases: object

backend_id: str

ID of the target backend for the route.

frontend_id: str

ID of the source frontend to create the route on.

match: RouteMatch | None = None

Object defining the match condition for a route to be applied. If an incoming client session matches the specified condition (i.e. it has a matching SNI value or HTTP Host header value), it will be passed to the target backend.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.CreateSubscriberRequest(name: str, region: str | None = None, project_id: str | None = None, organization_id: str | None = None, email_config: SubscriberEmailConfig | None = None, webhook_config: SubscriberWebhookConfig | None = None)

Bases: object

Create a new alert subscriber (webhook or email).

email_config: SubscriberEmailConfig | None = None
name: str

Subscriber name.

organization_id: str | None = None
project_id: str | None = None
region: str | None = None

Region to target. If none is passed will use default region from the config.

webhook_config: SubscriberWebhookConfig | None = None
class scaleway.lb.v1.types.DeleteAclRequest(acl_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

acl_id: str

ACL ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.DeleteBackendRequest(backend_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

backend_id: str

ID of the backend to delete.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.DeleteCertificateRequest(certificate_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

certificate_id: str

Certificate ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.DeleteFrontendRequest(frontend_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

frontend_id: str

ID of the frontend to delete.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.DeleteLbRequest(lb_id: 'str', release_ip: 'bool', region: 'Optional[ScwRegion]' = None)

Bases: object

lb_id: str

ID of the Load Balancer to delete.

region: str | None = None

Region to target. If none is passed will use default region from the config.

release_ip: bool

Defines whether the Load Balancer’s flexible IP should be deleted. Set to true to release the flexible IP, or false to keep it available in your account for future Load Balancers.

class scaleway.lb.v1.types.DeleteRouteRequest(route_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

region: str | None = None

Region to target. If none is passed will use default region from the config.

route_id: str

Route ID.

class scaleway.lb.v1.types.DeleteSubscriberRequest(subscriber_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

region: str | None = None

Region to target. If none is passed will use default region from the config.

subscriber_id: str

Subscriber ID.

class scaleway.lb.v1.types.DetachPrivateNetworkRequest(lb_id: 'str', private_network_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

lb_id: str

Load balancer ID.

private_network_id: str

Set your instance private network id.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.ForwardPortAlgorithm(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

FIRST = 'first'
LEASTCONN = 'leastconn'
ROUNDROBIN = 'roundrobin'
class scaleway.lb.v1.types.Frontend(id: 'str', name: 'str', inbound_port: 'int', certificate_ids: 'List[str]', enable_http3: 'bool', enable_access_logs: 'bool', backend: 'Optional[Backend]' = None, lb: 'Optional[Lb]' = None, timeout_client: 'Optional[str]' = None, certificate: 'Optional[Certificate]' = None, created_at: 'Optional[datetime]' = None, updated_at: 'Optional[datetime]' = None, connection_rate_limit: 'Optional[int]' = 0)

Bases: object

backend: Backend | None = None

Backend object the frontend is attached to.

certificate: Certificate | None = None

Certificate, deprecated in favor of certificate_ids array.

certificate_ids: List[str]

List of SSL/TLS certificate IDs to bind to the frontend.

connection_rate_limit: int | None = 0

Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second.

created_at: datetime | None = None

Date on which the frontend was created.

enable_access_logs: bool

Defines whether to enable access logs on the frontend.

enable_http3: bool

Defines whether to enable HTTP/3 protocol on the frontend.

id: str

Frontend ID.

inbound_port: int

Port the frontend listens on.

lb: Lb | None = None

Load Balancer object the frontend is attached to.

name: str

Name of the frontend.

timeout_client: str | None = None

Maximum allowed inactivity time on the client side.

updated_at: datetime | None = None

Date on which the frontend was last updated.

class scaleway.lb.v1.types.GetAclRequest(acl_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

acl_id: str

ACL ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.GetBackendRequest(backend_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

backend_id: str

Backend ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.GetCertificateRequest(certificate_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

certificate_id: str

Certificate ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.GetFrontendRequest(frontend_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

frontend_id: str

Frontend ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.GetIpRequest(ip_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

ip_id: str

IP address ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.GetLbRequest(lb_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

lb_id: str

Load Balancer ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.GetLbStatsRequest(lb_id: str, region: str | None = None, backend_id: str | None = None)

Bases: object

Get Load Balancer stats.

backend_id: str | None = None

ID of the backend.

lb_id: str

Load Balancer ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.GetRouteRequest(route_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

region: str | None = None

Region to target. If none is passed will use default region from the config.

route_id: str

Route ID.

class scaleway.lb.v1.types.GetSubscriberRequest(subscriber_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

region: str | None = None

Region to target. If none is passed will use default region from the config.

subscriber_id: str

Subscriber ID.

class scaleway.lb.v1.types.HealthCheck(port: 'int', check_max_retries: 'int', check_send_proxy: 'bool', check_delay: 'Optional[str]' = None, check_timeout: 'Optional[str]' = None, transient_check_delay: 'Optional[str]' = None, tcp_config: 'Optional[HealthCheckTcpConfig]' = None, mysql_config: 'Optional[HealthCheckMysqlConfig]' = None, pgsql_config: 'Optional[HealthCheckPgsqlConfig]' = None, ldap_config: 'Optional[HealthCheckLdapConfig]' = None, redis_config: 'Optional[HealthCheckRedisConfig]' = None, http_config: 'Optional[HealthCheckHttpConfig]' = None, https_config: 'Optional[HealthCheckHttpsConfig]' = None)

Bases: object

check_delay: str | None = None

Time to wait between two consecutive health checks.

check_max_retries: int

Number of consecutive unsuccessful health checks after which the server will be considered dead.

check_send_proxy: bool

Defines whether proxy protocol should be activated for the health check.

check_timeout: str | None = None

Maximum time a backend server has to reply to the health check.

http_config: HealthCheckHttpConfig | None = None
https_config: HealthCheckHttpsConfig | None = None
ldap_config: HealthCheckLdapConfig | None = None
mysql_config: HealthCheckMysqlConfig | None = None
pgsql_config: HealthCheckPgsqlConfig | None = None
port: int

Port to use for the backend server health check.

redis_config: HealthCheckRedisConfig | None = None
tcp_config: HealthCheckTcpConfig | None = None
transient_check_delay: str | None = None

Time to wait between two consecutive health checks when a backend server is in a transient state (going UP or DOWN).

class scaleway.lb.v1.types.HealthCheckHttpConfig(uri: 'str', method: 'str', host_header: 'str', code: 'Optional[int]' = 0)

Bases: object

code: int | None = 0

The HTTP response code that should be returned for a health check to be considered successful.

host_header: str

The HTTP host header used when performing a health check on backend servers.

method: str

The HTTP method used when performing a health check on backend servers.

uri: str

The HTTP path to use when performing a health check on backend servers.

class scaleway.lb.v1.types.HealthCheckHttpsConfig(uri: 'str', method: 'str', host_header: 'str', sni: 'str', code: 'Optional[int]' = 0)

Bases: object

code: int | None = 0

The HTTP response code that should be returned for a health check to be considered successful.

host_header: str

The HTTP host header used when performing a health check on backend servers.

method: str

The HTTP method used when performing a health check on backend servers.

sni: str

The SNI value used when performing a health check on backend servers over SSL.

uri: str

The HTTP path to use when performing a health check on backend servers.

class scaleway.lb.v1.types.HealthCheckLdapConfig

Bases: object

class scaleway.lb.v1.types.HealthCheckMysqlConfig(user: 'str')

Bases: object

user: str

MySQL user to use for the health check.

class scaleway.lb.v1.types.HealthCheckPgsqlConfig(user: 'str')

Bases: object

user: str

PostgreSQL user to use for the health check.

class scaleway.lb.v1.types.HealthCheckRedisConfig

Bases: object

class scaleway.lb.v1.types.HealthCheckTcpConfig

Bases: object

class scaleway.lb.v1.types.Instance(id: 'str', status: 'InstanceStatus', ip_address: 'str', zone: 'ScwZone', created_at: 'Optional[datetime]' = None, updated_at: 'Optional[datetime]' = None, region: 'Optional[ScwRegion]' = None)

Bases: object

created_at: datetime | None = None

Date on which the Instance was created.

id: str

Underlying Instance ID.

ip_address: str

Instance IP address.

region: str | None = None

The region the Instance is in.

status: InstanceStatus

Instance status.

updated_at: datetime | None = None

Date on which the Instance was last updated.

zone: str

The zone the Instance is in.

class scaleway.lb.v1.types.InstanceStatus(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

ERROR = 'error'
LOCKED = 'locked'
MIGRATING = 'migrating'
PENDING = 'pending'
READY = 'ready'
STOPPED = 'stopped'
UNKNOWN = 'unknown'
class scaleway.lb.v1.types.Ip(id: 'str', ip_address: 'str', organization_id: 'str', project_id: 'str', reverse: 'str', tags: 'List[str]', zone: 'ScwZone', lb_id: 'Optional[str]' = None, region: 'Optional[ScwRegion]' = None)

Bases: object

id: str

IP address ID.

ip_address: str

IP address.

lb_id: str | None = None

Load Balancer ID.

organization_id: str

Organization ID of the Scaleway Organization the IP address is in.

project_id: str

Project ID of the Scaleway Project the IP address is in.

region: str | None = None

The region the IP address is in.

reverse: str

Reverse DNS (domain name) of the IP address.

tags: List[str]

IP tags.

zone: str

The zone the IP address is in.

class scaleway.lb.v1.types.Lb(id: 'str', name: 'str', description: 'str', status: 'LbStatus', instances: 'List[Instance]', organization_id: 'str', project_id: 'str', ip: 'List[Ip]', tags: 'List[str]', frontend_count: 'int', backend_count: 'int', type_: 'str', ssl_compatibility_level: 'SSLCompatibilityLevel', private_network_count: 'int', route_count: 'int', zone: 'ScwZone', subscriber: 'Optional[Subscriber]' = None, created_at: 'Optional[datetime]' = None, updated_at: 'Optional[datetime]' = None, region: 'Optional[ScwRegion]' = None)

Bases: object

backend_count: int

Number of backends the Load Balancer has.

created_at: datetime | None = None

Date on which the Load Balancer was created.

description: str

Load Balancer description.

frontend_count: int

Number of frontends the Load Balancer has.

id: str

Underlying Instance ID.

instances: List[Instance]

List of underlying Instances.

ip: List[Ip]

List of IP addresses attached to the Load Balancer.

name: str

Load Balancer name.

organization_id: str

Scaleway Organization ID.

private_network_count: int

Number of Private Networks attached to the Load Balancer.

project_id: str

Scaleway Project ID.

region: str | None = None

The region the Load Balancer is in.

route_count: int

Number of routes configured on the Load Balancer.

ssl_compatibility_level: SSLCompatibilityLevel

Determines the minimal SSL version which needs to be supported on client side.

status: LbStatus

Load Balancer status.

subscriber: Subscriber | None = None

Subscriber information.

tags: List[str]

Load Balancer tags.

type_: str

Load Balancer offer type.

updated_at: datetime | None = None

Date on which the Load Balancer was last updated.

zone: str

The zone the Load Balancer is in.

class scaleway.lb.v1.types.LbStats(backend_servers_stats: 'List[BackendServerStats]')

Bases: object

backend_servers_stats: List[BackendServerStats]

List of objects containing Load Balancer statistics.

class scaleway.lb.v1.types.LbStatus(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

CREATING = 'creating'
DELETING = 'deleting'
ERROR = 'error'
LOCKED = 'locked'
MIGRATING = 'migrating'
PENDING = 'pending'
READY = 'ready'
STOPPED = 'stopped'
TO_CREATE = 'to_create'
TO_DELETE = 'to_delete'
UNKNOWN = 'unknown'
class scaleway.lb.v1.types.LbType(name: 'str', stock_status: 'LbTypeStock', description: 'str', zone: 'ScwZone', region: 'Optional[ScwRegion]' = None)

Bases: object

description: str

Load Balancer commercial offer type description.

name: str

Load Balancer commercial offer type name.

region: str | None = None

The region the Load Balancer stock is in.

stock_status: LbTypeStock

Current stock status for a given Load Balancer type.

zone: str

The zone the Load Balancer stock is in.

class scaleway.lb.v1.types.LbTypeStock(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

AVAILABLE = 'available'
LOW_STOCK = 'low_stock'
OUT_OF_STOCK = 'out_of_stock'
UNKNOWN = 'unknown'
class scaleway.lb.v1.types.ListAclRequestOrderBy(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

CREATED_AT_ASC = 'created_at_asc'
CREATED_AT_DESC = 'created_at_desc'
NAME_ASC = 'name_asc'
NAME_DESC = 'name_desc'
class scaleway.lb.v1.types.ListAclResponse(acls: 'List[Acl]', total_count: 'int')

Bases: object

acls: List[Acl]

List of ACL objects.

total_count: int

The total number of objects.

class scaleway.lb.v1.types.ListAclsRequest(frontend_id: 'str', region: 'Optional[ScwRegion]' = None, order_by: 'Optional[ListAclRequestOrderBy]' = <ListAclRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0, name: 'Optional[str]' = None)

Bases: object

frontend_id: str

Frontend ID (ACLs attached to this frontend will be returned in the response).

name: str | None = None

ACL name to filter for.

order_by: ListAclRequestOrderBy | None = 'created_at_asc'

Sort order of ACLs in the response.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

The number of ACLs to return.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.ListBackendStatsRequest(lb_id: 'str', region: 'Optional[ScwRegion]' = None, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0, backend_id: 'Optional[str]' = None)

Bases: object

backend_id: str | None = None

ID of the backend.

lb_id: str

Load Balancer ID.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

Number of items to return.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.ListBackendStatsResponse(backend_servers_stats: 'List[BackendServerStats]', total_count: 'int')

Bases: object

backend_servers_stats: List[BackendServerStats]

List of objects containing backend server statistics.

total_count: int

The total number of objects.

class scaleway.lb.v1.types.ListBackendsRequest(lb_id: 'str', region: 'Optional[ScwRegion]' = None, name: 'Optional[str]' = None, order_by: 'Optional[ListBackendsRequestOrderBy]' = <ListBackendsRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0)

Bases: object

lb_id: str

Load Balancer ID.

name: str | None = None

Name of the backend to filter for.

order_by: ListBackendsRequestOrderBy | None = 'created_at_asc'

Sort order of backends in the response.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

Number of backends to return.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.ListBackendsRequestOrderBy(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

CREATED_AT_ASC = 'created_at_asc'
CREATED_AT_DESC = 'created_at_desc'
NAME_ASC = 'name_asc'
NAME_DESC = 'name_desc'
class scaleway.lb.v1.types.ListBackendsResponse(backends: 'List[Backend]', total_count: 'int')

Bases: object

backends: List[Backend]

List of backend objects of a given Load Balancer.

total_count: int

Total count of backend objects, without pagination.

class scaleway.lb.v1.types.ListCertificatesRequest(lb_id: 'str', region: 'Optional[ScwRegion]' = None, order_by: 'Optional[ListCertificatesRequestOrderBy]' = <ListCertificatesRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0, name: 'Optional[str]' = None)

Bases: object

lb_id: str

Load Balancer ID.

name: str | None = None

Certificate name to filter for, only certificates of this name will be returned.

order_by: ListCertificatesRequestOrderBy | None = 'created_at_asc'

Sort order of certificates in the response.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

Number of certificates to return.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.ListCertificatesRequestOrderBy(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

CREATED_AT_ASC = 'created_at_asc'
CREATED_AT_DESC = 'created_at_desc'
NAME_ASC = 'name_asc'
NAME_DESC = 'name_desc'
class scaleway.lb.v1.types.ListCertificatesResponse(certificates: 'List[Certificate]', total_count: 'int')

Bases: object

certificates: List[Certificate]

List of certificate objects.

total_count: int

The total number of objects.

class scaleway.lb.v1.types.ListFrontendsRequest(lb_id: 'str', region: 'Optional[ScwRegion]' = None, name: 'Optional[str]' = None, order_by: 'Optional[ListFrontendsRequestOrderBy]' = <ListFrontendsRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0)

Bases: object

lb_id: str

Load Balancer ID.

name: str | None = None

Name of the frontend to filter for.

order_by: ListFrontendsRequestOrderBy | None = 'created_at_asc'

Sort order of frontends in the response.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

Number of frontends to return.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.ListFrontendsRequestOrderBy(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

CREATED_AT_ASC = 'created_at_asc'
CREATED_AT_DESC = 'created_at_desc'
NAME_ASC = 'name_asc'
NAME_DESC = 'name_desc'
class scaleway.lb.v1.types.ListFrontendsResponse(frontends: 'List[Frontend]', total_count: 'int')

Bases: object

frontends: List[Frontend]

List of frontend objects of a given Load Balancer.

total_count: int

Total count of frontend objects, without pagination.

class scaleway.lb.v1.types.ListIPsRequest(region: 'Optional[ScwRegion]' = None, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0, ip_address: 'Optional[str]' = None, organization_id: 'Optional[str]' = None, project_id: 'Optional[str]' = None, ip_type: 'Optional[ListIpsRequestIpType]' = <ListIpsRequestIpType.ALL: 'all'>, tags: 'Optional[List[str]]' = <factory>)

Bases: object

ip_address: str | None = None

IP address to filter for.

ip_type: ListIpsRequestIpType | None = 'all'

IP type to filter for.

organization_id: str | None = None

Organization ID to filter for, only Load Balancer IP addresses from this Organization will be returned.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

Number of IP addresses to return.

project_id: str | None = None

Project ID to filter for, only Load Balancer IP addresses from this Project will be returned.

region: str | None = None

Region to target. If none is passed will use default region from the config.

tags: List[str] | None

Tag to filter for, only IPs with one or more matching tags will be returned.

class scaleway.lb.v1.types.ListIpsRequestIpType(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

ALL = 'all'
IPV4 = 'ipv4'
IPV6 = 'ipv6'
class scaleway.lb.v1.types.ListIpsResponse(ips: 'List[Ip]', total_count: 'int')

Bases: object

ips: List[Ip]

List of IP address objects.

total_count: int

Total count of IP address objects, without pagination.

class scaleway.lb.v1.types.ListLbPrivateNetworksRequest(lb_id: 'str', region: 'Optional[ScwRegion]' = None, order_by: 'Optional[ListPrivateNetworksRequestOrderBy]' = <ListPrivateNetworksRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page_size: 'Optional[int]' = 0, page: 'Optional[int]' = 0)

Bases: object

lb_id: str

Load Balancer ID.

order_by: ListPrivateNetworksRequestOrderBy | None = 'created_at_asc'

Sort order of Private Network objects in the response.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

Number of objects to return.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.ListLbPrivateNetworksResponse(private_network: 'List[PrivateNetwork]', total_count: 'int')

Bases: object

private_network: List[PrivateNetwork]

List of Private Network objects attached to the Load Balancer.

total_count: int

Total number of objects in the response.

class scaleway.lb.v1.types.ListLbTypesRequest(region: 'Optional[ScwRegion]' = None, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0)

Bases: object

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

The number of items to return.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.ListLbTypesResponse(lb_types: 'List[LbType]', total_count: 'int')

Bases: object

lb_types: List[LbType]

List of Load Balancer commercial offer type objects.

total_count: int

Total number of Load Balancer offer type objects.

class scaleway.lb.v1.types.ListLbsRequest(region: 'Optional[ScwRegion]' = None, name: 'Optional[str]' = None, order_by: 'Optional[ListLbsRequestOrderBy]' = <ListLbsRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page_size: 'Optional[int]' = 0, page: 'Optional[int]' = 0, organization_id: 'Optional[str]' = None, project_id: 'Optional[str]' = None, tags: 'Optional[List[str]]' = <factory>)

Bases: object

name: str | None = None

Load Balancer name to filter for.

order_by: ListLbsRequestOrderBy | None = 'created_at_asc'

Sort order of Load Balancers in the response.

organization_id: str | None = None

Organization ID to filter for, only Load Balancers from this Organization will be returned.

page: int | None = 0

Page number to return, from the paginated results.

page_size: int | None = 0

Number of Load Balancers to return.

project_id: str | None = None

Project ID to filter for, only Load Balancers from this Project will be returned.

region: str | None = None

Region to target. If none is passed will use default region from the config.

tags: List[str] | None

Filter by tag, only Load Balancers with one or more matching tags will be returned.

class scaleway.lb.v1.types.ListLbsRequestOrderBy(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

CREATED_AT_ASC = 'created_at_asc'
CREATED_AT_DESC = 'created_at_desc'
NAME_ASC = 'name_asc'
NAME_DESC = 'name_desc'
class scaleway.lb.v1.types.ListLbsResponse(lbs: 'List[Lb]', total_count: 'int')

Bases: object

lbs: List[Lb]

List of Load Balancer objects.

total_count: int

The total number of Load Balancer objects.

class scaleway.lb.v1.types.ListPrivateNetworksRequestOrderBy(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

CREATED_AT_ASC = 'created_at_asc'
CREATED_AT_DESC = 'created_at_desc'
class scaleway.lb.v1.types.ListRoutesRequest(region: 'Optional[ScwRegion]' = None, order_by: 'Optional[ListRoutesRequestOrderBy]' = <ListRoutesRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page_size: 'Optional[int]' = 0, page: 'Optional[int]' = 0, frontend_id: 'Optional[str]' = None)

Bases: object

frontend_id: str | None = None

Frontend ID to filter for, only Routes from this Frontend will be returned.

order_by: ListRoutesRequestOrderBy | None = 'created_at_asc'

Sort order of routes in the response.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

The number of route objects to return.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.ListRoutesRequestOrderBy(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

CREATED_AT_ASC = 'created_at_asc'
CREATED_AT_DESC = 'created_at_desc'
class scaleway.lb.v1.types.ListRoutesResponse(routes: 'List[Route]', total_count: 'int')

Bases: object

routes: List[Route]

List of route objects.

total_count: int

The total number of route objects.

class scaleway.lb.v1.types.ListSubscriberRequest(region: 'Optional[ScwRegion]' = None, order_by: 'Optional[ListSubscriberRequestOrderBy]' = <ListSubscriberRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0, name: 'Optional[str]' = None, organization_id: 'Optional[str]' = None, project_id: 'Optional[str]' = None)

Bases: object

name: str | None = None

Subscriber name to search for.

order_by: ListSubscriberRequestOrderBy | None = 'created_at_asc'

Sort order of subscribers in the response.

organization_id: str | None = None

Filter subscribers by Organization ID.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

The number of items to return.

project_id: str | None = None

Filter subscribers by Project ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.ListSubscriberRequestOrderBy(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

CREATED_AT_ASC = 'created_at_asc'
CREATED_AT_DESC = 'created_at_desc'
NAME_ASC = 'name_asc'
NAME_DESC = 'name_desc'
class scaleway.lb.v1.types.ListSubscriberResponse(subscribers: 'List[Subscriber]', total_count: 'int')

Bases: object

subscribers: List[Subscriber]

List of subscriber objects.

total_count: int

The total number of objects.

class scaleway.lb.v1.types.MigrateLbRequest(lb_id: 'str', type_: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

lb_id: str

Load Balancer ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

type_: str

Load Balancer type to migrate to (use the List all Load Balancer offer types endpoint to get a list of available offer types).

class scaleway.lb.v1.types.OnMarkedDownAction(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

ON_MARKED_DOWN_ACTION_NONE = 'on_marked_down_action_none'
SHUTDOWN_SESSIONS = 'shutdown_sessions'
class scaleway.lb.v1.types.PrivateNetwork(ipam_ids: 'List[str]', private_network_id: 'str', status: 'PrivateNetworkStatus', lb: 'Optional[Lb]' = None, created_at: 'Optional[datetime]' = None, updated_at: 'Optional[datetime]' = None, static_config: 'Optional[PrivateNetworkStaticConfig]' = None, dhcp_config: 'Optional[PrivateNetworkDHCPConfig]' = None, ipam_config: 'Optional[PrivateNetworkIpamConfig]' = None)

Bases: object

created_at: datetime | None = None

Date on which the Private Network was created.

dhcp_config: PrivateNetworkDHCPConfig | None = None
ipam_config: PrivateNetworkIpamConfig | None = None
ipam_ids: List[str]

IPAM IDs of the booked IP addresses.

lb: Lb | None = None

Load Balancer object which is attached to the Private Network.

private_network_id: str

Private Network ID.

static_config: PrivateNetworkStaticConfig | None = None
status: PrivateNetworkStatus

Status of Private Network connection.

updated_at: datetime | None = None

Date on which the PN was last updated.

class scaleway.lb.v1.types.PrivateNetworkDHCPConfig(ip_id: 'Optional[str]' = None)

Bases: object

ip_id: str | None = None
class scaleway.lb.v1.types.PrivateNetworkIpamConfig

Bases: object

class scaleway.lb.v1.types.PrivateNetworkStaticConfig(ip_address: 'Optional[List[str]]' = <factory>)

Bases: object

ip_address: List[str] | None

Array of a local IP address for the Load Balancer on this Private Network.

class scaleway.lb.v1.types.PrivateNetworkStatus(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

ERROR = 'error'
PENDING = 'pending'
READY = 'ready'
UNKNOWN = 'unknown'
class scaleway.lb.v1.types.Protocol(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

HTTP = 'http'
TCP = 'tcp'
class scaleway.lb.v1.types.ProxyProtocol(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

PROXY_PROTOCOL_NONE = 'proxy_protocol_none'
PROXY_PROTOCOL_UNKNOWN = 'proxy_protocol_unknown'
PROXY_PROTOCOL_V1 = 'proxy_protocol_v1'
PROXY_PROTOCOL_V2 = 'proxy_protocol_v2'
PROXY_PROTOCOL_V2_SSL = 'proxy_protocol_v2_ssl'
PROXY_PROTOCOL_V2_SSL_CN = 'proxy_protocol_v2_ssl_cn'
class scaleway.lb.v1.types.ReleaseIpRequest(ip_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

ip_id: str

IP address ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.RemoveBackendServersRequest(backend_id: 'str', server_ip: 'List[str]', region: 'Optional[ScwRegion]' = None)

Bases: object

backend_id: str

Backend ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

server_ip: List[str]

List of IP addresses to remove from backend servers.

class scaleway.lb.v1.types.Route(id: 'str', frontend_id: 'str', backend_id: 'str', match: 'Optional[RouteMatch]' = None, created_at: 'Optional[datetime]' = None, updated_at: 'Optional[datetime]' = None)

Bases: object

backend_id: str

ID of the target backend.

created_at: datetime | None = None

Date on which the route was created.

frontend_id: str

ID of the source frontend.

id: str

Route ID.

match: RouteMatch | None = None

Object defining the match condition for a route to be applied. If an incoming client session matches the specified condition (i.e. it has a matching SNI value or HTTP Host header value), it will be passed to the target backend.

updated_at: datetime | None = None

Date on which the route was last updated.

class scaleway.lb.v1.types.RouteMatch(match_subdomains: 'bool', sni: 'Optional[str]' = None, host_header: 'Optional[str]' = None, path_begin: 'Optional[str]' = None)

Bases: object

host_header: str | None = None
match_subdomains: bool

If true, all subdomains will match.

path_begin: str | None = None
sni: str | None = None
class scaleway.lb.v1.types.SSLCompatibilityLevel(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

SSL_COMPATIBILITY_LEVEL_INTERMEDIATE = 'ssl_compatibility_level_intermediate'
SSL_COMPATIBILITY_LEVEL_MODERN = 'ssl_compatibility_level_modern'
SSL_COMPATIBILITY_LEVEL_OLD = 'ssl_compatibility_level_old'
SSL_COMPATIBILITY_LEVEL_UNKNOWN = 'ssl_compatibility_level_unknown'
class scaleway.lb.v1.types.SetAclsResponse(acls: 'List[Acl]', total_count: 'int')

Bases: object

acls: List[Acl]

List of ACL objects.

total_count: int

The total number of ACL objects.

class scaleway.lb.v1.types.SetBackendServersRequest(backend_id: 'str', server_ip: 'List[str]', region: 'Optional[ScwRegion]' = None)

Bases: object

backend_id: str

Backend ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

server_ip: List[str]

List of IP addresses for backend servers. Any other existing backend servers will be removed.

class scaleway.lb.v1.types.StickySessionsType(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

COOKIE = 'cookie'
NONE = 'none'
TABLE = 'table'
class scaleway.lb.v1.types.SubscribeToLbRequest(lb_id: 'str', subscriber_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

lb_id: str

Load Balancer ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

subscriber_id: str

Subscriber ID.

class scaleway.lb.v1.types.Subscriber(id: str, name: str, email_config: SubscriberEmailConfig | None = None, webhook_config: SubscriberWebhookConfig | None = None)

Bases: object

Subscriber.

email_config: SubscriberEmailConfig | None = None
id: str

Subscriber ID.

name: str

Subscriber name.

webhook_config: SubscriberWebhookConfig | None = None
class scaleway.lb.v1.types.SubscriberEmailConfig(email: 'str')

Bases: object

email: str

Email address to send alerts to.

class scaleway.lb.v1.types.SubscriberWebhookConfig(uri: str)

Bases: object

Webhook alert of subscriber.

uri: str

URI to receive POST requests.

class scaleway.lb.v1.types.UnsubscribeFromLbRequest(lb_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

lb_id: str

Load Balancer ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.UpdateAclRequest(acl_id: 'str', name: 'str', action: 'AclAction', index: 'int', region: 'Optional[ScwRegion]' = None, match: 'Optional[AclMatch]' = None, description: 'Optional[str]' = None)

Bases: object

acl_id: str

ACL ID.

action: AclAction

Action to take when incoming traffic matches an ACL filter.

description: str | None = None

ACL description.

index: int

Priority of this ACL (ACLs are applied in ascending order, 0 is the first ACL executed).

match: AclMatch | None = None

ACL match filter object. One of ip_subnet, ips_edge_services or http_filter & http_filter_value are required.

name: str

ACL name.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.UpdateBackendRequest(backend_id: 'str', name: 'str', forward_protocol: 'Protocol', forward_port: 'int', forward_port_algorithm: 'ForwardPortAlgorithm', sticky_sessions: 'StickySessionsType', sticky_sessions_cookie_name: 'str', region: 'Optional[ScwRegion]' = None, send_proxy_v2: 'Optional[bool]' = False, timeout_server: 'Optional[str]' = None, timeout_connect: 'Optional[str]' = None, timeout_tunnel: 'Optional[str]' = None, on_marked_down_action: 'Optional[OnMarkedDownAction]' = <OnMarkedDownAction.ON_MARKED_DOWN_ACTION_NONE: 'on_marked_down_action_none'>, proxy_protocol: 'Optional[ProxyProtocol]' = <ProxyProtocol.PROXY_PROTOCOL_UNKNOWN: 'proxy_protocol_unknown'>, failover_host: 'Optional[str]' = None, ssl_bridging: 'Optional[bool]' = False, ignore_ssl_server_verify: 'Optional[bool]' = False, redispatch_attempt_count: 'Optional[int]' = 0, max_retries: 'Optional[int]' = 0, max_connections: 'Optional[int]' = 0, timeout_queue: 'Optional[str]' = None)

Bases: object

backend_id: str

Backend ID.

failover_host: str | None = None

Scaleway Object Storage bucket website to be served as failover if all backend servers are down, e.g. failover-website.s3-website.fr-par.scw.cloud.

forward_port: int

Port to be used by the backend when forwarding traffic to backend servers.

forward_port_algorithm: ForwardPortAlgorithm

Load balancing algorithm to be used when determining which backend server to forward new traffic to.

forward_protocol: Protocol

Protocol to be used by the backend when forwarding traffic to backend servers.

ignore_ssl_server_verify: bool | None = False

Defines whether the server certificate verification should be ignored.

max_connections: int | None = 0

Maximum number of connections allowed per backend server.

max_retries: int | None = 0

Number of retries when a backend server connection failed.

name: str

Backend name.

on_marked_down_action: OnMarkedDownAction | None = 'on_marked_down_action_none'

Action to take when a backend server is marked as down.

proxy_protocol: ProxyProtocol | None = 'proxy_protocol_unknown'

Protocol to use between the Load Balancer and backend servers. Allows the backend servers to be informed of the client’s real IP address. The PROXY protocol must be supported by the backend servers’ software.

redispatch_attempt_count: int | None = 0

Whether to use another backend server on each attempt.

region: str | None = None

Region to target. If none is passed will use default region from the config.

send_proxy_v2: bool | None = False

Deprecated in favor of proxy_protocol field.

ssl_bridging: bool | None = False

Defines whether to enable SSL bridging between the Load Balancer and backend servers.

sticky_sessions: StickySessionsType

Defines whether to activate sticky sessions (binding a particular session to a particular backend server) and the method to use if so. None disables sticky sessions. Cookie-based uses an HTTP cookie to stick a session to a backend server. Table-based uses the source (client) IP address to stick a session to a backend server.

Cookie name for cookie-based sticky sessions.

timeout_connect: str | None = None

Maximum allowed time for establishing a connection to a backend server.

timeout_queue: str | None = None

Maximum time for a request to be left pending in queue when max_connections is reached.

timeout_server: str | None = None

Maximum allowed time for a backend server to process a request.

timeout_tunnel: str | None = None

Maximum allowed tunnel inactivity time after Websocket is established (takes precedence over client and server timeout).

class scaleway.lb.v1.types.UpdateCertificateRequest(certificate_id: 'str', name: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

certificate_id: str

Certificate ID.

name: str

Certificate name.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.types.UpdateFrontendRequest(frontend_id: 'str', name: 'str', inbound_port: 'int', backend_id: 'str', enable_http3: 'bool', region: 'Optional[ScwRegion]' = None, timeout_client: 'Optional[str]' = None, certificate_id: 'Optional[str]' = None, certificate_ids: 'Optional[List[str]]' = <factory>, connection_rate_limit: 'Optional[int]' = 0, enable_access_logs: 'Optional[bool]' = False)

Bases: object

backend_id: str

Backend ID (ID of the backend the frontend should pass traffic to).

certificate_id: str | None = None

Certificate ID, deprecated in favor of certificate_ids array.

certificate_ids: List[str] | None

List of SSL/TLS certificate IDs to bind to the frontend.

connection_rate_limit: int | None = 0

Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second.

enable_access_logs: bool | None = False

Defines whether to enable access logs on the frontend.

enable_http3: bool

Defines whether to enable HTTP/3 protocol on the frontend.

frontend_id: str

Frontend ID.

inbound_port: int

Port the frontend should listen on.

name: str

Frontend name.

region: str | None = None

Region to target. If none is passed will use default region from the config.

timeout_client: str | None = None

Maximum allowed inactivity time on the client side.

class scaleway.lb.v1.types.UpdateHealthCheckRequest(port: 'int', check_max_retries: 'int', backend_id: 'str', check_send_proxy: 'bool', region: 'Optional[ScwRegion]' = None, check_delay: 'Optional[str]' = None, check_timeout: 'Optional[str]' = None, transient_check_delay: 'Optional[str]' = None, tcp_config: 'Optional[HealthCheckTcpConfig]' = None, mysql_config: 'Optional[HealthCheckMysqlConfig]' = None, pgsql_config: 'Optional[HealthCheckPgsqlConfig]' = None, ldap_config: 'Optional[HealthCheckLdapConfig]' = None, redis_config: 'Optional[HealthCheckRedisConfig]' = None, http_config: 'Optional[HealthCheckHttpConfig]' = None, https_config: 'Optional[HealthCheckHttpsConfig]' = None)

Bases: object

backend_id: str

Backend ID.

check_delay: str | None = None

Time to wait between two consecutive health checks.

check_max_retries: int

Number of consecutive unsuccessful health checks after which the server will be considered dead.

check_send_proxy: bool

Defines whether proxy protocol should be activated for the health check.

check_timeout: str | None = None

Maximum time a backend server has to reply to the health check.

http_config: HealthCheckHttpConfig | None = None
https_config: HealthCheckHttpsConfig | None = None
ldap_config: HealthCheckLdapConfig | None = None
mysql_config: HealthCheckMysqlConfig | None = None
pgsql_config: HealthCheckPgsqlConfig | None = None
port: int

Port to use for the backend server health check.

redis_config: HealthCheckRedisConfig | None = None
region: str | None = None

Region to target. If none is passed will use default region from the config.

tcp_config: HealthCheckTcpConfig | None = None
transient_check_delay: str | None = None

Time to wait between two consecutive health checks when a backend server is in a transient state (going UP or DOWN).

class scaleway.lb.v1.types.UpdateIpRequest(ip_id: 'str', region: 'Optional[ScwRegion]' = None, reverse: 'Optional[str]' = None, lb_id: 'Optional[str]' = None, tags: 'Optional[List[str]]' = <factory>)

Bases: object

ip_id: str

IP address ID.

lb_id: str | None = None

ID of the server on which to attach the flexible IP.

region: str | None = None

Region to target. If none is passed will use default region from the config.

reverse: str | None = None

Reverse DNS (domain name) for the IP address.

tags: List[str] | None

List of tags for the IP.

class scaleway.lb.v1.types.UpdateLbRequest(lb_id: 'str', name: 'str', description: 'str', region: 'Optional[ScwRegion]' = None, tags: 'Optional[List[str]]' = <factory>, ssl_compatibility_level: 'Optional[SSLCompatibilityLevel]' = <SSLCompatibilityLevel.SSL_COMPATIBILITY_LEVEL_UNKNOWN: 'ssl_compatibility_level_unknown'>)

Bases: object

description: str

Load Balancer description.

lb_id: str

Load Balancer ID.

name: str

Load Balancer name.

region: str | None = None

Region to target. If none is passed will use default region from the config.

ssl_compatibility_level: SSLCompatibilityLevel | None = 'ssl_compatibility_level_unknown'

Determines the minimal SSL version which needs to be supported on the client side, in an SSL/TLS offloading context. Intermediate is suitable for general-purpose servers with a variety of clients, recommended for almost all systems. Modern is suitable for services with clients that support TLS 1.3 and don’t need backward compatibility. Old is compatible with a small number of very old clients and should be used only as a last resort.

tags: List[str] | None

List of tags for the Load Balancer.

class scaleway.lb.v1.types.UpdateRouteRequest(route_id: 'str', backend_id: 'str', region: 'Optional[ScwRegion]' = None, match: 'Optional[RouteMatch]' = None)

Bases: object

backend_id: str

ID of the target backend for the route.

match: RouteMatch | None = None

Object defining the match condition for a route to be applied. If an incoming client session matches the specified condition (i.e. it has a matching SNI value or HTTP Host header value), it will be passed to the target backend.

region: str | None = None

Region to target. If none is passed will use default region from the config.

route_id: str

Route ID.

class scaleway.lb.v1.types.UpdateSubscriberRequest(subscriber_id: 'str', name: 'str', region: 'Optional[ScwRegion]' = None, email_config: 'Optional[SubscriberEmailConfig]' = None, webhook_config: 'Optional[SubscriberWebhookConfig]' = None)

Bases: object

email_config: SubscriberEmailConfig | None = None
name: str

Subscriber name.

region: str | None = None

Region to target. If none is passed will use default region from the config.

subscriber_id: str

Subscriber ID.

webhook_config: SubscriberWebhookConfig | None = None
class scaleway.lb.v1.types.ZonedApiAddBackendServersRequest(backend_id: 'str', server_ip: 'List[str]', zone: 'Optional[ScwZone]' = None)

Bases: object

backend_id: str

Backend ID.

server_ip: List[str]

List of IP addresses to add to backend servers.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiAttachPrivateNetworkRequest(lb_id: 'str', private_network_id: 'str', zone: 'Optional[ScwZone]' = None, ipam_ids: 'Optional[List[str]]' = <factory>, static_config: 'Optional[PrivateNetworkStaticConfig]' = None, dhcp_config: 'Optional[PrivateNetworkDHCPConfig]' = None, ipam_config: 'Optional[PrivateNetworkIpamConfig]' = None)

Bases: object

dhcp_config: PrivateNetworkDHCPConfig | None = None
ipam_config: PrivateNetworkIpamConfig | None = None
ipam_ids: List[str] | None

IPAM ID of a pre-reserved IP address to assign to the Load Balancer on this Private Network. In the future, it will be possible to specify multiple IPs in this field (IPv4 and IPv6), for now only one ID of an IPv4 address is expected. When null, a new private IP address is created for the Load Balancer on this Private Network.

lb_id: str

Load Balancer ID.

private_network_id: str

Private Network ID.

static_config: PrivateNetworkStaticConfig | None = None
zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiCreateAclRequest(frontend_id: str, action: AclAction, index: int, description: str, zone: str | None = None, name: str | None = None, match: AclMatch | None = None)

Bases: object

Add an ACL to a Load Balancer frontend.

action: AclAction

Action to take when incoming traffic matches an ACL filter.

description: str

ACL description.

frontend_id: str

Frontend ID to attach the ACL to.

index: int

Priority of this ACL (ACLs are applied in ascending order, 0 is the first ACL executed).

match: AclMatch | None = None

ACL match filter object. One of ip_subnet, ips_edge_services or http_filter & http_filter_value are required.

name: str | None = None

ACL name.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiCreateBackendRequest(forward_protocol: 'Protocol', forward_port: 'int', forward_port_algorithm: 'ForwardPortAlgorithm', sticky_sessions: 'StickySessionsType', sticky_sessions_cookie_name: 'str', lb_id: 'str', health_check: 'HealthCheck', server_ip: 'List[str]', zone: 'Optional[ScwZone]' = None, name: 'Optional[str]' = None, send_proxy_v2: 'Optional[bool]' = False, timeout_server: 'Optional[str]' = None, timeout_connect: 'Optional[str]' = None, timeout_tunnel: 'Optional[str]' = None, on_marked_down_action: 'Optional[OnMarkedDownAction]' = <OnMarkedDownAction.ON_MARKED_DOWN_ACTION_NONE: 'on_marked_down_action_none'>, proxy_protocol: 'Optional[ProxyProtocol]' = <ProxyProtocol.PROXY_PROTOCOL_UNKNOWN: 'proxy_protocol_unknown'>, failover_host: 'Optional[str]' = None, ssl_bridging: 'Optional[bool]' = False, ignore_ssl_server_verify: 'Optional[bool]' = False, redispatch_attempt_count: 'Optional[int]' = 0, max_retries: 'Optional[int]' = 0, max_connections: 'Optional[int]' = 0, timeout_queue: 'Optional[str]' = None)

Bases: object

failover_host: str | None = None

Scaleway Object Storage bucket website to be served as failover if all backend servers are down, e.g. failover-website.s3-website.fr-par.scw.cloud.

forward_port: int

Port to be used by the backend when forwarding traffic to backend servers.

forward_port_algorithm: ForwardPortAlgorithm

Load balancing algorithm to be used when determining which backend server to forward new traffic to.

forward_protocol: Protocol

Protocol to be used by the backend when forwarding traffic to backend servers.

health_check: HealthCheck

Object defining the health check to be carried out by the backend when checking the status and health of backend servers.

ignore_ssl_server_verify: bool | None = False

Defines whether the server certificate verification should be ignored.

lb_id: str

Load Balancer ID.

max_connections: int | None = 0

Maximum number of connections allowed per backend server.

max_retries: int | None = 0

Number of retries when a backend server connection failed.

name: str | None = None

Name for the backend.

on_marked_down_action: OnMarkedDownAction | None = 'on_marked_down_action_none'

Action to take when a backend server is marked as down.

proxy_protocol: ProxyProtocol | None = 'proxy_protocol_unknown'

Protocol to use between the Load Balancer and backend servers. Allows the backend servers to be informed of the client’s real IP address. The PROXY protocol must be supported by the backend servers’ software.

redispatch_attempt_count: int | None = 0

Whether to use another backend server on each attempt.

send_proxy_v2: bool | None = False

Deprecated in favor of proxy_protocol field.

server_ip: List[str]

List of backend server IP addresses (IPv4 or IPv6) the backend should forward traffic to.

ssl_bridging: bool | None = False

Defines whether to enable SSL bridging between the Load Balancer and backend servers.

sticky_sessions: StickySessionsType

Defines whether to activate sticky sessions (binding a particular session to a particular backend server) and the method to use if so. None disables sticky sessions. Cookie-based uses an HTTP cookie TO stick a session to a backend server. Table-based uses the source (client) IP address to stick a session to a backend server.

Cookie name for cookie-based sticky sessions.

timeout_connect: str | None = None

Maximum allowed time for establishing a connection to a backend server.

timeout_queue: str | None = None

Maximum time for a request to be left pending in queue when max_connections is reached.

timeout_server: str | None = None

Maximum allowed time for a backend server to process a request.

timeout_tunnel: str | None = None

Maximum allowed tunnel inactivity time after Websocket is established (takes precedence over client and server timeout).

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiCreateCertificateRequest(lb_id: 'str', zone: 'Optional[ScwZone]' = None, name: 'Optional[str]' = None, letsencrypt: 'Optional[CreateCertificateRequestLetsencryptConfig]' = None, custom_certificate: 'Optional[CreateCertificateRequestCustomCertificate]' = None)

Bases: object

custom_certificate: CreateCertificateRequestCustomCertificate | None = None
lb_id: str

Load Balancer ID.

letsencrypt: CreateCertificateRequestLetsencryptConfig | None = None
name: str | None = None

Name for the certificate.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiCreateFrontendRequest(inbound_port: 'int', lb_id: 'str', backend_id: 'str', enable_http3: 'bool', enable_access_logs: 'bool', zone: 'Optional[ScwZone]' = None, name: 'Optional[str]' = None, timeout_client: 'Optional[str]' = None, certificate_id: 'Optional[str]' = None, certificate_ids: 'Optional[List[str]]' = <factory>, connection_rate_limit: 'Optional[int]' = 0)

Bases: object

backend_id: str

Backend ID (ID of the backend the frontend should pass traffic to).

certificate_id: str | None = None

Certificate ID, deprecated in favor of certificate_ids array.

certificate_ids: List[str] | None

List of SSL/TLS certificate IDs to bind to the frontend.

connection_rate_limit: int | None = 0

Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second.

enable_access_logs: bool

Defines whether to enable access logs on the frontend.

enable_http3: bool

Defines whether to enable HTTP/3 protocol on the frontend.

inbound_port: int

Port the frontend should listen on.

lb_id: str

Load Balancer ID (ID of the Load Balancer to attach the frontend to).

name: str | None = None

Name for the frontend.

timeout_client: str | None = None

Maximum allowed inactivity time on the client side.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiCreateIpRequest(is_ipv6: 'bool', zone: 'Optional[ScwZone]' = None, reverse: 'Optional[str]' = None, tags: 'Optional[List[str]]' = <factory>, project_id: 'Optional[str]' = None, organization_id: 'Optional[str]' = None)

Bases: object

is_ipv6: bool

If true, creates a Flexible IP with an ipv6 address.

organization_id: str | None = None
project_id: str | None = None
reverse: str | None = None

Reverse DNS (domain name) for the IP address.

tags: List[str] | None

List of tags for the IP.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiCreateLbRequest(description: 'str', type_: 'str', zone: 'Optional[ScwZone]' = None, name: 'Optional[str]' = None, ip_id: 'Optional[str]' = None, assign_flexible_ip: 'Optional[bool]' = False, assign_flexible_ipv6: 'Optional[bool]' = False, ip_ids: 'Optional[List[str]]' = <factory>, tags: 'Optional[List[str]]' = <factory>, ssl_compatibility_level: 'Optional[SSLCompatibilityLevel]' = <SSLCompatibilityLevel.SSL_COMPATIBILITY_LEVEL_UNKNOWN: 'ssl_compatibility_level_unknown'>, project_id: 'Optional[str]' = None, organization_id: 'Optional[str]' = None)

Bases: object

assign_flexible_ip: bool | None = False

Defines whether to automatically assign a flexible public IP to the Load Balancer. Default value is true (assign).

assign_flexible_ipv6: bool | None = False

Defines whether to automatically assign a flexible public IPv6 to the Load Balancer. Default value is false (do not assign).

description: str

Description for the Load Balancer.

ip_id: str | None = None

ID of an existing flexible IP address to attach to the Load Balancer.

ip_ids: List[str] | None

List of IP IDs to attach to the Load Balancer.

name: str | None = None

Name for the Load Balancer.

organization_id: str | None = None
project_id: str | None = None
ssl_compatibility_level: SSLCompatibilityLevel | None = 'ssl_compatibility_level_unknown'

Determines the minimal SSL version which needs to be supported on the client side, in an SSL/TLS offloading context. Intermediate is suitable for general-purpose servers with a variety of clients, recommended for almost all systems. Modern is suitable for services with clients that support TLS 1.3 and do not need backward compatibility. Old is compatible with a small number of very old clients and should be used only as a last resort.

tags: List[str] | None

List of tags for the Load Balancer.

type_: str

Load Balancer commercial offer type. Use the Load Balancer types endpoint to retrieve a list of available offer types.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiCreateRouteRequest(frontend_id: 'str', backend_id: 'str', zone: 'Optional[ScwZone]' = None, match: 'Optional[RouteMatch]' = None)

Bases: object

backend_id: str

ID of the target backend for the route.

frontend_id: str

ID of the source frontend to create the route on.

match: RouteMatch | None = None

Object defining the match condition for a route to be applied. If an incoming client session matches the specified condition (i.e. it has a matching SNI value or HTTP Host header value), it will be passed to the target backend.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiCreateSubscriberRequest(name: str, zone: str | None = None, project_id: str | None = None, organization_id: str | None = None, email_config: SubscriberEmailConfig | None = None, webhook_config: SubscriberWebhookConfig | None = None)

Bases: object

Create a new alert subscriber (webhook or email).

email_config: SubscriberEmailConfig | None = None
name: str

Subscriber name.

organization_id: str | None = None
project_id: str | None = None
webhook_config: SubscriberWebhookConfig | None = None
zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiDeleteAclRequest(acl_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

acl_id: str

ACL ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiDeleteBackendRequest(backend_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

backend_id: str

ID of the backend to delete.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiDeleteCertificateRequest(certificate_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

certificate_id: str

Certificate ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiDeleteFrontendRequest(frontend_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

frontend_id: str

ID of the frontend to delete.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiDeleteLbRequest(lb_id: 'str', release_ip: 'bool', zone: 'Optional[ScwZone]' = None)

Bases: object

lb_id: str

ID of the Load Balancer to delete.

release_ip: bool

Defines whether the Load Balancer’s flexible IP should be deleted. Set to true to release the flexible IP, or false to keep it available in your account for future Load Balancers.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiDeleteRouteRequest(route_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

route_id: str

Route ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiDeleteSubscriberRequest(subscriber_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

subscriber_id: str

Subscriber ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiDetachPrivateNetworkRequest(lb_id: 'str', private_network_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

lb_id: str

Load balancer ID.

private_network_id: str

Set your instance private network id.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiGetAclRequest(acl_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

acl_id: str

ACL ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiGetBackendRequest(backend_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

backend_id: str

Backend ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiGetCertificateRequest(certificate_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

certificate_id: str

Certificate ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiGetFrontendRequest(frontend_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

frontend_id: str

Frontend ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiGetIpRequest(ip_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

ip_id: str

IP address ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiGetLbRequest(lb_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

lb_id: str

Load Balancer ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiGetLbStatsRequest(lb_id: str, zone: str | None = None, backend_id: str | None = None)

Bases: object

Get Load Balancer stats.

backend_id: str | None = None

ID of the backend.

lb_id: str

Load Balancer ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiGetRouteRequest(route_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

route_id: str

Route ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiGetSubscriberRequest(subscriber_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

subscriber_id: str

Subscriber ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiListAclsRequest(frontend_id: 'str', zone: 'Optional[ScwZone]' = None, order_by: 'Optional[ListAclRequestOrderBy]' = <ListAclRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0, name: 'Optional[str]' = None)

Bases: object

frontend_id: str

Frontend ID (ACLs attached to this frontend will be returned in the response).

name: str | None = None

ACL name to filter for.

order_by: ListAclRequestOrderBy | None = 'created_at_asc'

Sort order of ACLs in the response.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

The number of ACLs to return.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiListBackendStatsRequest(lb_id: 'str', zone: 'Optional[ScwZone]' = None, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0, backend_id: 'Optional[str]' = None)

Bases: object

backend_id: str | None = None

ID of the backend.

lb_id: str

Load Balancer ID.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

Number of items to return.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiListBackendsRequest(lb_id: 'str', zone: 'Optional[ScwZone]' = None, name: 'Optional[str]' = None, order_by: 'Optional[ListBackendsRequestOrderBy]' = <ListBackendsRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0)

Bases: object

lb_id: str

Load Balancer ID.

name: str | None = None

Name of the backend to filter for.

order_by: ListBackendsRequestOrderBy | None = 'created_at_asc'

Sort order of backends in the response.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

Number of backends to return.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiListCertificatesRequest(lb_id: 'str', zone: 'Optional[ScwZone]' = None, order_by: 'Optional[ListCertificatesRequestOrderBy]' = <ListCertificatesRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0, name: 'Optional[str]' = None)

Bases: object

lb_id: str

Load Balancer ID.

name: str | None = None

Certificate name to filter for, only certificates of this name will be returned.

order_by: ListCertificatesRequestOrderBy | None = 'created_at_asc'

Sort order of certificates in the response.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

Number of certificates to return.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiListFrontendsRequest(lb_id: 'str', zone: 'Optional[ScwZone]' = None, name: 'Optional[str]' = None, order_by: 'Optional[ListFrontendsRequestOrderBy]' = <ListFrontendsRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0)

Bases: object

lb_id: str

Load Balancer ID.

name: str | None = None

Name of the frontend to filter for.

order_by: ListFrontendsRequestOrderBy | None = 'created_at_asc'

Sort order of frontends in the response.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

Number of frontends to return.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiListIPsRequest(zone: 'Optional[ScwZone]' = None, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0, ip_address: 'Optional[str]' = None, organization_id: 'Optional[str]' = None, project_id: 'Optional[str]' = None, ip_type: 'Optional[ListIpsRequestIpType]' = <ListIpsRequestIpType.ALL: 'all'>, tags: 'Optional[List[str]]' = <factory>)

Bases: object

ip_address: str | None = None

IP address to filter for.

ip_type: ListIpsRequestIpType | None = 'all'

IP type to filter for.

organization_id: str | None = None

Organization ID to filter for, only Load Balancer IP addresses from this Organization will be returned.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

Number of IP addresses to return.

project_id: str | None = None

Project ID to filter for, only Load Balancer IP addresses from this Project will be returned.

tags: List[str] | None

Tag to filter for, only IPs with one or more matching tags will be returned.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiListLbPrivateNetworksRequest(lb_id: 'str', zone: 'Optional[ScwZone]' = None, order_by: 'Optional[ListPrivateNetworksRequestOrderBy]' = <ListPrivateNetworksRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page_size: 'Optional[int]' = 0, page: 'Optional[int]' = 0)

Bases: object

lb_id: str

Load Balancer ID.

order_by: ListPrivateNetworksRequestOrderBy | None = 'created_at_asc'

Sort order of Private Network objects in the response.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

Number of objects to return.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiListLbTypesRequest(zone: 'Optional[ScwZone]' = None, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0)

Bases: object

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

The number of items to return.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiListLbsRequest(zone: 'Optional[ScwZone]' = None, name: 'Optional[str]' = None, order_by: 'Optional[ListLbsRequestOrderBy]' = <ListLbsRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page_size: 'Optional[int]' = 0, page: 'Optional[int]' = 0, organization_id: 'Optional[str]' = None, project_id: 'Optional[str]' = None, tags: 'Optional[List[str]]' = <factory>)

Bases: object

name: str | None = None

Load Balancer name to filter for.

order_by: ListLbsRequestOrderBy | None = 'created_at_asc'

Sort order of Load Balancers in the response.

organization_id: str | None = None

Organization ID to filter for, only Load Balancers from this Organization will be returned.

page: int | None = 0

Page number to return, from the paginated results.

page_size: int | None = 0

Number of Load Balancers to return.

project_id: str | None = None

Project ID to filter for, only Load Balancers from this Project will be returned.

tags: List[str] | None

Filter by tag, only Load Balancers with one or more matching tags will be returned.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiListRoutesRequest(zone: 'Optional[ScwZone]' = None, order_by: 'Optional[ListRoutesRequestOrderBy]' = <ListRoutesRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page_size: 'Optional[int]' = 0, page: 'Optional[int]' = 0, frontend_id: 'Optional[str]' = None)

Bases: object

frontend_id: str | None = None

Frontend ID to filter for, only Routes from this Frontend will be returned.

order_by: ListRoutesRequestOrderBy | None = 'created_at_asc'

Sort order of routes in the response.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

The number of route objects to return.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiListSubscriberRequest(zone: 'Optional[ScwZone]' = None, order_by: 'Optional[ListSubscriberRequestOrderBy]' = <ListSubscriberRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0, name: 'Optional[str]' = None, organization_id: 'Optional[str]' = None, project_id: 'Optional[str]' = None)

Bases: object

name: str | None = None

Subscriber name to search for.

order_by: ListSubscriberRequestOrderBy | None = 'created_at_asc'

Sort order of subscribers in the response.

organization_id: str | None = None

Filter subscribers by Organization ID.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

The number of items to return.

project_id: str | None = None

Filter subscribers by Project ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiMigrateLbRequest(lb_id: 'str', type_: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

lb_id: str

Load Balancer ID.

type_: str

Load Balancer type to migrate to (use the List all Load Balancer offer types endpoint to get a list of available offer types).

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiReleaseIpRequest(ip_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

ip_id: str

IP address ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiRemoveBackendServersRequest(backend_id: 'str', server_ip: 'List[str]', zone: 'Optional[ScwZone]' = None)

Bases: object

backend_id: str

Backend ID.

server_ip: List[str]

List of IP addresses to remove from backend servers.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiSetAclsRequest(acls: 'List[AclSpec]', frontend_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

acls: List[AclSpec]

List of ACLs for this frontend. Any other existing ACLs on this frontend will be removed.

frontend_id: str

Frontend ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiSetBackendServersRequest(backend_id: 'str', server_ip: 'List[str]', zone: 'Optional[ScwZone]' = None)

Bases: object

backend_id: str

Backend ID.

server_ip: List[str]

List of IP addresses for backend servers. Any other existing backend servers will be removed.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiSubscribeToLbRequest(lb_id: 'str', subscriber_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

lb_id: str

Load Balancer ID.

subscriber_id: str

Subscriber ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiUnsubscribeFromLbRequest(lb_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

lb_id: str

Load Balancer ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiUpdateAclRequest(acl_id: 'str', name: 'str', action: 'AclAction', index: 'int', zone: 'Optional[ScwZone]' = None, match: 'Optional[AclMatch]' = None, description: 'Optional[str]' = None)

Bases: object

acl_id: str

ACL ID.

action: AclAction

Action to take when incoming traffic matches an ACL filter.

description: str | None = None

ACL description.

index: int

Priority of this ACL (ACLs are applied in ascending order, 0 is the first ACL executed).

match: AclMatch | None = None

ACL match filter object. One of ip_subnet, ips_edge_services or http_filter & http_filter_value are required.

name: str

ACL name.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiUpdateBackendRequest(backend_id: 'str', name: 'str', forward_protocol: 'Protocol', forward_port: 'int', forward_port_algorithm: 'ForwardPortAlgorithm', sticky_sessions: 'StickySessionsType', sticky_sessions_cookie_name: 'str', zone: 'Optional[ScwZone]' = None, send_proxy_v2: 'Optional[bool]' = False, timeout_server: 'Optional[str]' = None, timeout_connect: 'Optional[str]' = None, timeout_tunnel: 'Optional[str]' = None, on_marked_down_action: 'Optional[OnMarkedDownAction]' = <OnMarkedDownAction.ON_MARKED_DOWN_ACTION_NONE: 'on_marked_down_action_none'>, proxy_protocol: 'Optional[ProxyProtocol]' = <ProxyProtocol.PROXY_PROTOCOL_UNKNOWN: 'proxy_protocol_unknown'>, failover_host: 'Optional[str]' = None, ssl_bridging: 'Optional[bool]' = False, ignore_ssl_server_verify: 'Optional[bool]' = False, redispatch_attempt_count: 'Optional[int]' = 0, max_retries: 'Optional[int]' = 0, max_connections: 'Optional[int]' = 0, timeout_queue: 'Optional[str]' = None)

Bases: object

backend_id: str

Backend ID.

failover_host: str | None = None

Scaleway Object Storage bucket website to be served as failover if all backend servers are down, e.g. failover-website.s3-website.fr-par.scw.cloud.

forward_port: int

Port to be used by the backend when forwarding traffic to backend servers.

forward_port_algorithm: ForwardPortAlgorithm

Load balancing algorithm to be used when determining which backend server to forward new traffic to.

forward_protocol: Protocol

Protocol to be used by the backend when forwarding traffic to backend servers.

ignore_ssl_server_verify: bool | None = False

Defines whether the server certificate verification should be ignored.

max_connections: int | None = 0

Maximum number of connections allowed per backend server.

max_retries: int | None = 0

Number of retries when a backend server connection failed.

name: str

Backend name.

on_marked_down_action: OnMarkedDownAction | None = 'on_marked_down_action_none'

Action to take when a backend server is marked as down.

proxy_protocol: ProxyProtocol | None = 'proxy_protocol_unknown'

Protocol to use between the Load Balancer and backend servers. Allows the backend servers to be informed of the client’s real IP address. The PROXY protocol must be supported by the backend servers’ software.

redispatch_attempt_count: int | None = 0

Whether to use another backend server on each attempt.

send_proxy_v2: bool | None = False

Deprecated in favor of proxy_protocol field.

ssl_bridging: bool | None = False

Defines whether to enable SSL bridging between the Load Balancer and backend servers.

sticky_sessions: StickySessionsType

Defines whether to activate sticky sessions (binding a particular session to a particular backend server) and the method to use if so. None disables sticky sessions. Cookie-based uses an HTTP cookie to stick a session to a backend server. Table-based uses the source (client) IP address to stick a session to a backend server.

Cookie name for cookie-based sticky sessions.

timeout_connect: str | None = None

Maximum allowed time for establishing a connection to a backend server.

timeout_queue: str | None = None

Maximum time for a request to be left pending in queue when max_connections is reached.

timeout_server: str | None = None

Maximum allowed time for a backend server to process a request.

timeout_tunnel: str | None = None

Maximum allowed tunnel inactivity time after Websocket is established (takes precedence over client and server timeout).

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiUpdateCertificateRequest(certificate_id: 'str', name: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

certificate_id: str

Certificate ID.

name: str

Certificate name.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiUpdateFrontendRequest(frontend_id: 'str', name: 'str', inbound_port: 'int', backend_id: 'str', enable_http3: 'bool', zone: 'Optional[ScwZone]' = None, timeout_client: 'Optional[str]' = None, certificate_id: 'Optional[str]' = None, certificate_ids: 'Optional[List[str]]' = <factory>, connection_rate_limit: 'Optional[int]' = 0, enable_access_logs: 'Optional[bool]' = False)

Bases: object

backend_id: str

Backend ID (ID of the backend the frontend should pass traffic to).

certificate_id: str | None = None

Certificate ID, deprecated in favor of certificate_ids array.

certificate_ids: List[str] | None

List of SSL/TLS certificate IDs to bind to the frontend.

connection_rate_limit: int | None = 0

Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second.

enable_access_logs: bool | None = False

Defines whether to enable access logs on the frontend.

enable_http3: bool

Defines whether to enable HTTP/3 protocol on the frontend.

frontend_id: str

Frontend ID.

inbound_port: int

Port the frontend should listen on.

name: str

Frontend name.

timeout_client: str | None = None

Maximum allowed inactivity time on the client side.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiUpdateHealthCheckRequest(port: 'int', check_max_retries: 'int', backend_id: 'str', check_send_proxy: 'bool', zone: 'Optional[ScwZone]' = None, check_delay: 'Optional[str]' = None, check_timeout: 'Optional[str]' = None, transient_check_delay: 'Optional[str]' = None, tcp_config: 'Optional[HealthCheckTcpConfig]' = None, mysql_config: 'Optional[HealthCheckMysqlConfig]' = None, pgsql_config: 'Optional[HealthCheckPgsqlConfig]' = None, ldap_config: 'Optional[HealthCheckLdapConfig]' = None, redis_config: 'Optional[HealthCheckRedisConfig]' = None, http_config: 'Optional[HealthCheckHttpConfig]' = None, https_config: 'Optional[HealthCheckHttpsConfig]' = None)

Bases: object

backend_id: str

Backend ID.

check_delay: str | None = None

Time to wait between two consecutive health checks.

check_max_retries: int

Number of consecutive unsuccessful health checks after which the server will be considered dead.

check_send_proxy: bool

Defines whether proxy protocol should be activated for the health check.

check_timeout: str | None = None

Maximum time a backend server has to reply to the health check.

http_config: HealthCheckHttpConfig | None = None
https_config: HealthCheckHttpsConfig | None = None
ldap_config: HealthCheckLdapConfig | None = None
mysql_config: HealthCheckMysqlConfig | None = None
pgsql_config: HealthCheckPgsqlConfig | None = None
port: int

Port to use for the backend server health check.

redis_config: HealthCheckRedisConfig | None = None
tcp_config: HealthCheckTcpConfig | None = None
transient_check_delay: str | None = None

Time to wait between two consecutive health checks when a backend server is in a transient state (going UP or DOWN).

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiUpdateIpRequest(ip_id: 'str', zone: 'Optional[ScwZone]' = None, reverse: 'Optional[str]' = None, lb_id: 'Optional[str]' = None, tags: 'Optional[List[str]]' = <factory>)

Bases: object

ip_id: str

IP address ID.

lb_id: str | None = None

ID of the server on which to attach the flexible IP.

reverse: str | None = None

Reverse DNS (domain name) for the IP address.

tags: List[str] | None

List of tags for the IP.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiUpdateLbRequest(lb_id: 'str', name: 'str', description: 'str', zone: 'Optional[ScwZone]' = None, tags: 'Optional[List[str]]' = <factory>, ssl_compatibility_level: 'Optional[SSLCompatibilityLevel]' = <SSLCompatibilityLevel.SSL_COMPATIBILITY_LEVEL_UNKNOWN: 'ssl_compatibility_level_unknown'>)

Bases: object

description: str

Load Balancer description.

lb_id: str

Load Balancer ID.

name: str

Load Balancer name.

ssl_compatibility_level: SSLCompatibilityLevel | None = 'ssl_compatibility_level_unknown'

Determines the minimal SSL version which needs to be supported on the client side, in an SSL/TLS offloading context. Intermediate is suitable for general-purpose servers with a variety of clients, recommended for almost all systems. Modern is suitable for services with clients that support TLS 1.3 and don’t need backward compatibility. Old is compatible with a small number of very old clients and should be used only as a last resort.

tags: List[str] | None

List of tags for the Load Balancer.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiUpdateRouteRequest(route_id: 'str', backend_id: 'str', zone: 'Optional[ScwZone]' = None, match: 'Optional[RouteMatch]' = None)

Bases: object

backend_id: str

ID of the target backend for the route.

match: RouteMatch | None = None

Object defining the match condition for a route to be applied. If an incoming client session matches the specified condition (i.e. it has a matching SNI value or HTTP Host header value), it will be passed to the target backend.

route_id: str

Route ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.types.ZonedApiUpdateSubscriberRequest(subscriber_id: 'str', name: 'str', zone: 'Optional[ScwZone]' = None, email_config: 'Optional[SubscriberEmailConfig]' = None, webhook_config: 'Optional[SubscriberWebhookConfig]' = None)

Bases: object

email_config: SubscriberEmailConfig | None = None
name: str

Subscriber name.

subscriber_id: str

Subscriber ID.

webhook_config: SubscriberWebhookConfig | None = None
zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

Module contents

class scaleway.lb.v1.Acl(id: 'str', name: 'str', index: 'int', description: 'str', match: 'Optional[AclMatch]' = None, action: 'Optional[AclAction]' = None, frontend: 'Optional[Frontend]' = None, created_at: 'Optional[datetime]' = None, updated_at: 'Optional[datetime]' = None)

Bases: object

action: AclAction | None = None

Action to take when incoming traffic matches an ACL filter.

created_at: datetime | None = None

Date on which the ACL was created.

description: str

ACL description.

frontend: Frontend | None = None

ACL is attached to this frontend object.

id: str

ACL ID.

index: int

Priority of this ACL (ACLs are applied in ascending order, 0 is the first ACL executed).

match: AclMatch | None = None

ACL match filter object. One of ip_subnet, ips_edge_services or http_filter & http_filter_value are required.

name: str

ACL name.

updated_at: datetime | None = None

Date on which the ACL was last updated.

class scaleway.lb.v1.AclAction(type_: 'AclActionType', redirect: 'Optional[AclActionRedirect]' = None)

Bases: object

redirect: AclActionRedirect | None = None

Redirection parameters when using an ACL with a redirect action.

type_: AclActionType

Action to take when incoming traffic matches an ACL filter.

class scaleway.lb.v1.AclActionRedirect(type_: 'AclActionRedirectRedirectType', target: 'str', code: 'Optional[int]' = 0)

Bases: object

code: int | None = 0

HTTP redirect code to use. Valid values are 301, 302, 303, 307 and 308. Default value is 302.

target: str

Redirect target. For a location redirect, you can use a URL e.g. https://scaleway.com. Using a scheme name (e.g. https, http, ftp, git) will replace the request’s original scheme. This can be useful to implement HTTP to HTTPS redirects. Valid placeholders that can be used in a location redirect to preserve parts of the original request in the redirection URL are {{host}}, {{query}}, {{path}} and {{scheme}}.

type_: AclActionRedirectRedirectType

Redirect type.

class scaleway.lb.v1.AclActionRedirectRedirectType(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

LOCATION = 'location'
SCHEME = 'scheme'
class scaleway.lb.v1.AclActionType(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

ALLOW = 'allow'
DENY = 'deny'
REDIRECT = 'redirect'
class scaleway.lb.v1.AclHttpFilter(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

ACL_HTTP_FILTER_NONE = 'acl_http_filter_none'
HTTP_HEADER_MATCH = 'http_header_match'
PATH_BEGIN = 'path_begin'
PATH_END = 'path_end'
REGEX = 'regex'
class scaleway.lb.v1.AclMatch(ip_subnet: 'List[str]', ips_edge_services: 'bool', http_filter: 'AclHttpFilter', http_filter_value: 'List[str]', invert: 'bool', http_filter_option: 'Optional[str]' = None)

Bases: object

http_filter: AclHttpFilter

Type of HTTP filter to match. Extracts the request’s URL path, which starts at the first slash and ends before the question mark (without the host part). Defines where to filter for the http_filter_value. Only supported for HTTP backends.

http_filter_option: str | None = None

Name of the HTTP header to filter on if http_header_match was selected in http_filter.

http_filter_value: List[str]

List of values to filter for.

invert: bool

Defines whether to invert the match condition. If set to true, the ACL carries out its action when the condition DOES NOT match.

ip_subnet: List[str]

List of IPs or CIDR v4/v6 addresses to filter for from the client side.

ips_edge_services: bool

Defines whether Edge Services IPs should be matched.

class scaleway.lb.v1.AclSpec(name: 'str', action: 'AclAction', index: 'int', description: 'str', match: 'Optional[AclMatch]' = None)

Bases: object

action: AclAction

Action to take when incoming traffic matches an ACL filter.

description: str

ACL description.

index: int

Priority of this ACL (ACLs are applied in ascending order, 0 is the first ACL executed).

match: AclMatch | None = None

ACL match filter object. One of ip_subnet, ips_edge_services or http_filter and http_filter_value are required.

name: str

ACL name.

class scaleway.lb.v1.AddBackendServersRequest(backend_id: 'str', server_ip: 'List[str]', region: 'Optional[ScwRegion]' = None)

Bases: object

backend_id: str

Backend ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

server_ip: List[str]

List of IP addresses to add to backend servers.

class scaleway.lb.v1.AttachPrivateNetworkRequest(lb_id: 'str', private_network_id: 'str', region: 'Optional[ScwRegion]' = None, ipam_ids: 'Optional[List[str]]' = <factory>, static_config: 'Optional[PrivateNetworkStaticConfig]' = None, dhcp_config: 'Optional[PrivateNetworkDHCPConfig]' = None, ipam_config: 'Optional[PrivateNetworkIpamConfig]' = None)

Bases: object

dhcp_config: PrivateNetworkDHCPConfig | None = None
ipam_config: PrivateNetworkIpamConfig | None = None
ipam_ids: List[str] | None

IPAM ID of a pre-reserved IP address to assign to the Load Balancer on this Private Network. In the future, it will be possible to specify multiple IPs in this field (IPv4 and IPv6), for now only one ID of an IPv4 address is expected. When null, a new private IP address is created for the Load Balancer on this Private Network.

lb_id: str

Load Balancer ID.

private_network_id: str

Private Network ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

static_config: PrivateNetworkStaticConfig | None = None
class scaleway.lb.v1.Backend(id: 'str', name: 'str', forward_protocol: 'Protocol', forward_port: 'int', forward_port_algorithm: 'ForwardPortAlgorithm', sticky_sessions: 'StickySessionsType', sticky_sessions_cookie_name: 'str', pool: 'List[str]', on_marked_down_action: 'OnMarkedDownAction', proxy_protocol: 'ProxyProtocol', health_check: 'Optional[HealthCheck]' = None, lb: 'Optional[Lb]' = None, send_proxy_v2: 'Optional[bool]' = False, timeout_server: 'Optional[str]' = None, timeout_connect: 'Optional[str]' = None, timeout_tunnel: 'Optional[str]' = None, created_at: 'Optional[datetime]' = None, updated_at: 'Optional[datetime]' = None, failover_host: 'Optional[str]' = None, ssl_bridging: 'Optional[bool]' = False, ignore_ssl_server_verify: 'Optional[bool]' = False, redispatch_attempt_count: 'Optional[int]' = 0, max_retries: 'Optional[int]' = 0, max_connections: 'Optional[int]' = 0, timeout_queue: 'Optional[str]' = None)

Bases: object

created_at: datetime | None = None

Date at which the backend was created.

failover_host: str | None = None

Scaleway Object Storage bucket website to be served as failover if all backend servers are down, e.g. failover-website.s3-website.fr-par.scw.cloud.

forward_port: int

Port used by the backend when forwarding traffic to backend servers.

forward_port_algorithm: ForwardPortAlgorithm

Load balancing algorithm to use when determining which backend server to forward new traffic to.

forward_protocol: Protocol

Protocol used by the backend when forwarding traffic to backend servers.

health_check: HealthCheck | None = None

Object defining the health check to be carried out by the backend when checking the status and health of backend servers.

id: str

Backend ID.

ignore_ssl_server_verify: bool | None = False

Defines whether the server certificate verification should be ignored.

lb: Lb | None = None

Load Balancer the backend is attached to.

max_connections: int | None = 0

Maximum number of connections allowed per backend server.

max_retries: int | None = 0

Number of retries when a backend server connection failed.

name: str

Name of the backend.

on_marked_down_action: OnMarkedDownAction

Action to take when a backend server is marked as down.

pool: List[str]

List of IP addresses of backend servers attached to this backend.

proxy_protocol: ProxyProtocol

Protocol to use between the Load Balancer and backend servers. Allows the backend servers to be informed of the client’s real IP address. The PROXY protocol must be supported by the backend servers’ software.

redispatch_attempt_count: int | None = 0

Whether to use another backend server on each attempt.

send_proxy_v2: bool | None = False

Deprecated in favor of proxy_protocol field.

ssl_bridging: bool | None = False

Defines whether to enable SSL bridging between the Load Balancer and backend servers.

sticky_sessions: StickySessionsType

Defines whether sticky sessions (binding a particular session to a particular backend server) are activated and the method to use if so. None disables sticky sessions. Cookie-based uses an HTTP cookie to stick a session to a backend server. Table-based uses the source (client) IP address to stick a session to a backend server.

Cookie name for cookie-based sticky sessions.

timeout_connect: str | None = None

Maximum allowed time for establishing a connection to a backend server.

timeout_queue: str | None = None

Maximum time for a request to be left pending in queue when max_connections is reached.

timeout_server: str | None = None

Maximum allowed time for a backend server to process a request.

timeout_tunnel: str | None = None

Maximum allowed tunnel inactivity time after Websocket is established (takes precedence over client and server timeout).

updated_at: datetime | None = None

Date at which the backend was updated.

class scaleway.lb.v1.BackendServerStats(instance_id: 'str', backend_id: 'str', ip: 'str', server_state: 'BackendServerStatsServerState', last_health_check_status: 'BackendServerStatsHealthCheckStatus', server_state_changed_at: 'Optional[datetime]' = None)

Bases: object

backend_id: str

Backend ID.

instance_id: str

ID of your Load Balancer’s underlying Instance.

ip: str

IPv4 or IPv6 address of the backend server.

last_health_check_status: BackendServerStatsHealthCheckStatus

Last health check status (unknown/neutral/failed/passed/condpass).

server_state: BackendServerStatsServerState

Server operational state (stopped/starting/running/stopping).

server_state_changed_at: datetime | None = None

Time since last operational change.

class scaleway.lb.v1.BackendServerStatsHealthCheckStatus(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

CONDPASS = 'condpass'
FAILED = 'failed'
NEUTRAL = 'neutral'
PASSED = 'passed'
UNKNOWN = 'unknown'
class scaleway.lb.v1.BackendServerStatsServerState(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

RUNNING = 'running'
STARTING = 'starting'
STOPPED = 'stopped'
STOPPING = 'stopping'
class scaleway.lb.v1.Certificate(type_: 'CertificateType', id: 'str', common_name: 'str', subject_alternative_name: 'List[str]', fingerprint: 'str', status: 'CertificateStatus', name: 'str', not_valid_before: 'Optional[datetime]' = None, not_valid_after: 'Optional[datetime]' = None, lb: 'Optional[Lb]' = None, created_at: 'Optional[datetime]' = None, updated_at: 'Optional[datetime]' = None, status_details: 'Optional[str]' = None)

Bases: object

common_name: str

Main domain name of certificate.

created_at: datetime | None = None

Date on which the certificate was created.

fingerprint: str

Identifier (SHA-1) of the certificate.

id: str

Certificate ID.

lb: Lb | None = None

Load Balancer object the certificate is attached to.

name: str

Certificate name.

not_valid_after: datetime | None = None

Upper validity bound.

not_valid_before: datetime | None = None

Lower validity bound.

status: CertificateStatus

Certificate status.

status_details: str | None = None

Additional information about the certificate status (useful in case of certificate generation failure, for example).

subject_alternative_name: List[str]

Alternative domain names.

type_: CertificateType

Certificate type (Let’s Encrypt or custom).

updated_at: datetime | None = None

Date on which the certificate was last updated.

class scaleway.lb.v1.CertificateStatus(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

ERROR = 'error'
PENDING = 'pending'
READY = 'ready'
class scaleway.lb.v1.CertificateType(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

CUSTOM = 'custom'
LETSENCRYT = 'letsencryt'
class scaleway.lb.v1.CreateAclRequest(frontend_id: str, action: AclAction, index: int, description: str, region: str | None = None, name: str | None = None, match: AclMatch | None = None)

Bases: object

Add an ACL to a Load Balancer frontend.

action: AclAction

Action to take when incoming traffic matches an ACL filter.

description: str

ACL description.

frontend_id: str

Frontend ID to attach the ACL to.

index: int

Priority of this ACL (ACLs are applied in ascending order, 0 is the first ACL executed).

match: AclMatch | None = None

ACL match filter object. One of ip_subnet, ips_edge_services or http_filter & http_filter_value are required.

name: str | None = None

ACL name.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.CreateBackendRequest(forward_protocol: 'Protocol', forward_port: 'int', forward_port_algorithm: 'ForwardPortAlgorithm', sticky_sessions: 'StickySessionsType', sticky_sessions_cookie_name: 'str', lb_id: 'str', health_check: 'HealthCheck', server_ip: 'List[str]', region: 'Optional[ScwRegion]' = None, name: 'Optional[str]' = None, send_proxy_v2: 'Optional[bool]' = False, timeout_server: 'Optional[str]' = None, timeout_connect: 'Optional[str]' = None, timeout_tunnel: 'Optional[str]' = None, on_marked_down_action: 'Optional[OnMarkedDownAction]' = <OnMarkedDownAction.ON_MARKED_DOWN_ACTION_NONE: 'on_marked_down_action_none'>, proxy_protocol: 'Optional[ProxyProtocol]' = <ProxyProtocol.PROXY_PROTOCOL_UNKNOWN: 'proxy_protocol_unknown'>, failover_host: 'Optional[str]' = None, ssl_bridging: 'Optional[bool]' = False, ignore_ssl_server_verify: 'Optional[bool]' = False, redispatch_attempt_count: 'Optional[int]' = 0, max_retries: 'Optional[int]' = 0, max_connections: 'Optional[int]' = 0, timeout_queue: 'Optional[str]' = None)

Bases: object

failover_host: str | None = None

Scaleway Object Storage bucket website to be served as failover if all backend servers are down, e.g. failover-website.s3-website.fr-par.scw.cloud.

forward_port: int

Port to be used by the backend when forwarding traffic to backend servers.

forward_port_algorithm: ForwardPortAlgorithm

Load balancing algorithm to be used when determining which backend server to forward new traffic to.

forward_protocol: Protocol

Protocol to be used by the backend when forwarding traffic to backend servers.

health_check: HealthCheck

Object defining the health check to be carried out by the backend when checking the status and health of backend servers.

ignore_ssl_server_verify: bool | None = False

Defines whether the server certificate verification should be ignored.

lb_id: str

Load Balancer ID.

max_connections: int | None = 0

Maximum number of connections allowed per backend server.

max_retries: int | None = 0

Number of retries when a backend server connection failed.

name: str | None = None

Name for the backend.

on_marked_down_action: OnMarkedDownAction | None = 'on_marked_down_action_none'

Action to take when a backend server is marked as down.

proxy_protocol: ProxyProtocol | None = 'proxy_protocol_unknown'

Protocol to use between the Load Balancer and backend servers. Allows the backend servers to be informed of the client’s real IP address. The PROXY protocol must be supported by the backend servers’ software.

redispatch_attempt_count: int | None = 0

Whether to use another backend server on each attempt.

region: str | None = None

Region to target. If none is passed will use default region from the config.

send_proxy_v2: bool | None = False

Deprecated in favor of proxy_protocol field.

server_ip: List[str]

List of backend server IP addresses (IPv4 or IPv6) the backend should forward traffic to.

ssl_bridging: bool | None = False

Defines whether to enable SSL bridging between the Load Balancer and backend servers.

sticky_sessions: StickySessionsType

Defines whether to activate sticky sessions (binding a particular session to a particular backend server) and the method to use if so. None disables sticky sessions. Cookie-based uses an HTTP cookie TO stick a session to a backend server. Table-based uses the source (client) IP address to stick a session to a backend server.

Cookie name for cookie-based sticky sessions.

timeout_connect: str | None = None

Maximum allowed time for establishing a connection to a backend server.

timeout_queue: str | None = None

Maximum time for a request to be left pending in queue when max_connections is reached.

timeout_server: str | None = None

Maximum allowed time for a backend server to process a request.

timeout_tunnel: str | None = None

Maximum allowed tunnel inactivity time after Websocket is established (takes precedence over client and server timeout).

class scaleway.lb.v1.CreateCertificateRequest(lb_id: 'str', region: 'Optional[ScwRegion]' = None, name: 'Optional[str]' = None, letsencrypt: 'Optional[CreateCertificateRequestLetsencryptConfig]' = None, custom_certificate: 'Optional[CreateCertificateRequestCustomCertificate]' = None)

Bases: object

custom_certificate: CreateCertificateRequestCustomCertificate | None = None
lb_id: str

Load Balancer ID.

letsencrypt: CreateCertificateRequestLetsencryptConfig | None = None
name: str | None = None

Name for the certificate.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.CreateCertificateRequestCustomCertificate(certificate_chain: 'str')

Bases: object

certificate_chain: str

Full PEM-formatted certificate, consisting of the entire certificate chain including public key, private key, and (optionally) Certificate Authorities.

class scaleway.lb.v1.CreateCertificateRequestLetsencryptConfig(common_name: 'str', subject_alternative_name: 'List[str]')

Bases: object

common_name: str

Main domain name of certificate (this domain must exist and resolve to your Load Balancer IP address).

subject_alternative_name: List[str]

Alternative domain names (all domain names must exist and resolve to your Load Balancer IP address).

class scaleway.lb.v1.CreateFrontendRequest(inbound_port: 'int', lb_id: 'str', backend_id: 'str', enable_http3: 'bool', enable_access_logs: 'bool', region: 'Optional[ScwRegion]' = None, name: 'Optional[str]' = None, timeout_client: 'Optional[str]' = None, certificate_id: 'Optional[str]' = None, certificate_ids: 'Optional[List[str]]' = <factory>, connection_rate_limit: 'Optional[int]' = 0)

Bases: object

backend_id: str

Backend ID (ID of the backend the frontend should pass traffic to).

certificate_id: str | None = None

Certificate ID, deprecated in favor of certificate_ids array.

certificate_ids: List[str] | None

List of SSL/TLS certificate IDs to bind to the frontend.

connection_rate_limit: int | None = 0

Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second.

enable_access_logs: bool

Defines whether to enable access logs on the frontend.

enable_http3: bool

Defines whether to enable HTTP/3 protocol on the frontend.

inbound_port: int

Port the frontend should listen on.

lb_id: str

Load Balancer ID (ID of the Load Balancer to attach the frontend to).

name: str | None = None

Name for the frontend.

region: str | None = None

Region to target. If none is passed will use default region from the config.

timeout_client: str | None = None

Maximum allowed inactivity time on the client side.

class scaleway.lb.v1.CreateIpRequest(is_ipv6: 'bool', region: 'Optional[ScwRegion]' = None, reverse: 'Optional[str]' = None, tags: 'Optional[List[str]]' = <factory>, project_id: 'Optional[str]' = None, organization_id: 'Optional[str]' = None)

Bases: object

is_ipv6: bool

If true, creates a Flexible IP with an ipv6 address.

organization_id: str | None = None
project_id: str | None = None
region: str | None = None

Region to target. If none is passed will use default region from the config.

reverse: str | None = None

Reverse DNS (domain name) for the IP address.

tags: List[str] | None

List of tags for the IP.

class scaleway.lb.v1.CreateLbRequest(description: 'str', type_: 'str', region: 'Optional[ScwRegion]' = None, name: 'Optional[str]' = None, ip_id: 'Optional[str]' = None, assign_flexible_ip: 'Optional[bool]' = False, assign_flexible_ipv6: 'Optional[bool]' = False, ip_ids: 'Optional[List[str]]' = <factory>, tags: 'Optional[List[str]]' = <factory>, ssl_compatibility_level: 'Optional[SSLCompatibilityLevel]' = <SSLCompatibilityLevel.SSL_COMPATIBILITY_LEVEL_UNKNOWN: 'ssl_compatibility_level_unknown'>, project_id: 'Optional[str]' = None, organization_id: 'Optional[str]' = None)

Bases: object

assign_flexible_ip: bool | None = False

Defines whether to automatically assign a flexible public IP to the Load Balancer. Default value is true (assign).

assign_flexible_ipv6: bool | None = False

Defines whether to automatically assign a flexible public IPv6 to the Load Balancer. Default value is false (do not assign).

description: str

Description for the Load Balancer.

ip_id: str | None = None

ID of an existing flexible IP address to attach to the Load Balancer.

ip_ids: List[str] | None

List of IP IDs to attach to the Load Balancer.

name: str | None = None

Name for the Load Balancer.

organization_id: str | None = None
project_id: str | None = None
region: str | None = None

Region to target. If none is passed will use default region from the config.

ssl_compatibility_level: SSLCompatibilityLevel | None = 'ssl_compatibility_level_unknown'

Determines the minimal SSL version which needs to be supported on the client side, in an SSL/TLS offloading context. Intermediate is suitable for general-purpose servers with a variety of clients, recommended for almost all systems. Modern is suitable for services with clients that support TLS 1.3 and do not need backward compatibility. Old is compatible with a small number of very old clients and should be used only as a last resort.

tags: List[str] | None

List of tags for the Load Balancer.

type_: str

Load Balancer commercial offer type. Use the Load Balancer types endpoint to retrieve a list of available offer types.

class scaleway.lb.v1.CreateRouteRequest(frontend_id: 'str', backend_id: 'str', region: 'Optional[ScwRegion]' = None, match: 'Optional[RouteMatch]' = None)

Bases: object

backend_id: str

ID of the target backend for the route.

frontend_id: str

ID of the source frontend to create the route on.

match: RouteMatch | None = None

Object defining the match condition for a route to be applied. If an incoming client session matches the specified condition (i.e. it has a matching SNI value or HTTP Host header value), it will be passed to the target backend.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.CreateSubscriberRequest(name: str, region: str | None = None, project_id: str | None = None, organization_id: str | None = None, email_config: SubscriberEmailConfig | None = None, webhook_config: SubscriberWebhookConfig | None = None)

Bases: object

Create a new alert subscriber (webhook or email).

email_config: SubscriberEmailConfig | None = None
name: str

Subscriber name.

organization_id: str | None = None
project_id: str | None = None
region: str | None = None

Region to target. If none is passed will use default region from the config.

webhook_config: SubscriberWebhookConfig | None = None
class scaleway.lb.v1.DeleteAclRequest(acl_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

acl_id: str

ACL ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.DeleteBackendRequest(backend_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

backend_id: str

ID of the backend to delete.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.DeleteCertificateRequest(certificate_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

certificate_id: str

Certificate ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.DeleteFrontendRequest(frontend_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

frontend_id: str

ID of the frontend to delete.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.DeleteLbRequest(lb_id: 'str', release_ip: 'bool', region: 'Optional[ScwRegion]' = None)

Bases: object

lb_id: str

ID of the Load Balancer to delete.

region: str | None = None

Region to target. If none is passed will use default region from the config.

release_ip: bool

Defines whether the Load Balancer’s flexible IP should be deleted. Set to true to release the flexible IP, or false to keep it available in your account for future Load Balancers.

class scaleway.lb.v1.DeleteRouteRequest(route_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

region: str | None = None

Region to target. If none is passed will use default region from the config.

route_id: str

Route ID.

class scaleway.lb.v1.DeleteSubscriberRequest(subscriber_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

region: str | None = None

Region to target. If none is passed will use default region from the config.

subscriber_id: str

Subscriber ID.

class scaleway.lb.v1.DetachPrivateNetworkRequest(lb_id: 'str', private_network_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

lb_id: str

Load balancer ID.

private_network_id: str

Set your instance private network id.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.ForwardPortAlgorithm(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

FIRST = 'first'
LEASTCONN = 'leastconn'
ROUNDROBIN = 'roundrobin'
class scaleway.lb.v1.Frontend(id: 'str', name: 'str', inbound_port: 'int', certificate_ids: 'List[str]', enable_http3: 'bool', enable_access_logs: 'bool', backend: 'Optional[Backend]' = None, lb: 'Optional[Lb]' = None, timeout_client: 'Optional[str]' = None, certificate: 'Optional[Certificate]' = None, created_at: 'Optional[datetime]' = None, updated_at: 'Optional[datetime]' = None, connection_rate_limit: 'Optional[int]' = 0)

Bases: object

backend: Backend | None = None

Backend object the frontend is attached to.

certificate: Certificate | None = None

Certificate, deprecated in favor of certificate_ids array.

certificate_ids: List[str]

List of SSL/TLS certificate IDs to bind to the frontend.

connection_rate_limit: int | None = 0

Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second.

created_at: datetime | None = None

Date on which the frontend was created.

enable_access_logs: bool

Defines whether to enable access logs on the frontend.

enable_http3: bool

Defines whether to enable HTTP/3 protocol on the frontend.

id: str

Frontend ID.

inbound_port: int

Port the frontend listens on.

lb: Lb | None = None

Load Balancer object the frontend is attached to.

name: str

Name of the frontend.

timeout_client: str | None = None

Maximum allowed inactivity time on the client side.

updated_at: datetime | None = None

Date on which the frontend was last updated.

class scaleway.lb.v1.GetAclRequest(acl_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

acl_id: str

ACL ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.GetBackendRequest(backend_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

backend_id: str

Backend ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.GetCertificateRequest(certificate_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

certificate_id: str

Certificate ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.GetFrontendRequest(frontend_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

frontend_id: str

Frontend ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.GetIpRequest(ip_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

ip_id: str

IP address ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.GetLbRequest(lb_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

lb_id: str

Load Balancer ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.GetLbStatsRequest(lb_id: str, region: str | None = None, backend_id: str | None = None)

Bases: object

Get Load Balancer stats.

backend_id: str | None = None

ID of the backend.

lb_id: str

Load Balancer ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.GetRouteRequest(route_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

region: str | None = None

Region to target. If none is passed will use default region from the config.

route_id: str

Route ID.

class scaleway.lb.v1.GetSubscriberRequest(subscriber_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

region: str | None = None

Region to target. If none is passed will use default region from the config.

subscriber_id: str

Subscriber ID.

class scaleway.lb.v1.HealthCheck(port: 'int', check_max_retries: 'int', check_send_proxy: 'bool', check_delay: 'Optional[str]' = None, check_timeout: 'Optional[str]' = None, transient_check_delay: 'Optional[str]' = None, tcp_config: 'Optional[HealthCheckTcpConfig]' = None, mysql_config: 'Optional[HealthCheckMysqlConfig]' = None, pgsql_config: 'Optional[HealthCheckPgsqlConfig]' = None, ldap_config: 'Optional[HealthCheckLdapConfig]' = None, redis_config: 'Optional[HealthCheckRedisConfig]' = None, http_config: 'Optional[HealthCheckHttpConfig]' = None, https_config: 'Optional[HealthCheckHttpsConfig]' = None)

Bases: object

check_delay: str | None = None

Time to wait between two consecutive health checks.

check_max_retries: int

Number of consecutive unsuccessful health checks after which the server will be considered dead.

check_send_proxy: bool

Defines whether proxy protocol should be activated for the health check.

check_timeout: str | None = None

Maximum time a backend server has to reply to the health check.

http_config: HealthCheckHttpConfig | None = None
https_config: HealthCheckHttpsConfig | None = None
ldap_config: HealthCheckLdapConfig | None = None
mysql_config: HealthCheckMysqlConfig | None = None
pgsql_config: HealthCheckPgsqlConfig | None = None
port: int

Port to use for the backend server health check.

redis_config: HealthCheckRedisConfig | None = None
tcp_config: HealthCheckTcpConfig | None = None
transient_check_delay: str | None = None

Time to wait between two consecutive health checks when a backend server is in a transient state (going UP or DOWN).

class scaleway.lb.v1.HealthCheckHttpConfig(uri: 'str', method: 'str', host_header: 'str', code: 'Optional[int]' = 0)

Bases: object

code: int | None = 0

The HTTP response code that should be returned for a health check to be considered successful.

host_header: str

The HTTP host header used when performing a health check on backend servers.

method: str

The HTTP method used when performing a health check on backend servers.

uri: str

The HTTP path to use when performing a health check on backend servers.

class scaleway.lb.v1.HealthCheckHttpsConfig(uri: 'str', method: 'str', host_header: 'str', sni: 'str', code: 'Optional[int]' = 0)

Bases: object

code: int | None = 0

The HTTP response code that should be returned for a health check to be considered successful.

host_header: str

The HTTP host header used when performing a health check on backend servers.

method: str

The HTTP method used when performing a health check on backend servers.

sni: str

The SNI value used when performing a health check on backend servers over SSL.

uri: str

The HTTP path to use when performing a health check on backend servers.

class scaleway.lb.v1.HealthCheckLdapConfig

Bases: object

class scaleway.lb.v1.HealthCheckMysqlConfig(user: 'str')

Bases: object

user: str

MySQL user to use for the health check.

class scaleway.lb.v1.HealthCheckPgsqlConfig(user: 'str')

Bases: object

user: str

PostgreSQL user to use for the health check.

class scaleway.lb.v1.HealthCheckRedisConfig

Bases: object

class scaleway.lb.v1.HealthCheckTcpConfig

Bases: object

class scaleway.lb.v1.Instance(id: 'str', status: 'InstanceStatus', ip_address: 'str', zone: 'ScwZone', created_at: 'Optional[datetime]' = None, updated_at: 'Optional[datetime]' = None, region: 'Optional[ScwRegion]' = None)

Bases: object

created_at: datetime | None = None

Date on which the Instance was created.

id: str

Underlying Instance ID.

ip_address: str

Instance IP address.

region: str | None = None

The region the Instance is in.

status: InstanceStatus

Instance status.

updated_at: datetime | None = None

Date on which the Instance was last updated.

zone: str

The zone the Instance is in.

class scaleway.lb.v1.InstanceStatus(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

ERROR = 'error'
LOCKED = 'locked'
MIGRATING = 'migrating'
PENDING = 'pending'
READY = 'ready'
STOPPED = 'stopped'
UNKNOWN = 'unknown'
class scaleway.lb.v1.Ip(id: 'str', ip_address: 'str', organization_id: 'str', project_id: 'str', reverse: 'str', tags: 'List[str]', zone: 'ScwZone', lb_id: 'Optional[str]' = None, region: 'Optional[ScwRegion]' = None)

Bases: object

id: str

IP address ID.

ip_address: str

IP address.

lb_id: str | None = None

Load Balancer ID.

organization_id: str

Organization ID of the Scaleway Organization the IP address is in.

project_id: str

Project ID of the Scaleway Project the IP address is in.

region: str | None = None

The region the IP address is in.

reverse: str

Reverse DNS (domain name) of the IP address.

tags: List[str]

IP tags.

zone: str

The zone the IP address is in.

class scaleway.lb.v1.Lb(id: 'str', name: 'str', description: 'str', status: 'LbStatus', instances: 'List[Instance]', organization_id: 'str', project_id: 'str', ip: 'List[Ip]', tags: 'List[str]', frontend_count: 'int', backend_count: 'int', type_: 'str', ssl_compatibility_level: 'SSLCompatibilityLevel', private_network_count: 'int', route_count: 'int', zone: 'ScwZone', subscriber: 'Optional[Subscriber]' = None, created_at: 'Optional[datetime]' = None, updated_at: 'Optional[datetime]' = None, region: 'Optional[ScwRegion]' = None)

Bases: object

backend_count: int

Number of backends the Load Balancer has.

created_at: datetime | None = None

Date on which the Load Balancer was created.

description: str

Load Balancer description.

frontend_count: int

Number of frontends the Load Balancer has.

id: str

Underlying Instance ID.

instances: List[Instance]

List of underlying Instances.

ip: List[Ip]

List of IP addresses attached to the Load Balancer.

name: str

Load Balancer name.

organization_id: str

Scaleway Organization ID.

private_network_count: int

Number of Private Networks attached to the Load Balancer.

project_id: str

Scaleway Project ID.

region: str | None = None

The region the Load Balancer is in.

route_count: int

Number of routes configured on the Load Balancer.

ssl_compatibility_level: SSLCompatibilityLevel

Determines the minimal SSL version which needs to be supported on client side.

status: LbStatus

Load Balancer status.

subscriber: Subscriber | None = None

Subscriber information.

tags: List[str]

Load Balancer tags.

type_: str

Load Balancer offer type.

updated_at: datetime | None = None

Date on which the Load Balancer was last updated.

zone: str

The zone the Load Balancer is in.

class scaleway.lb.v1.LbStats(backend_servers_stats: 'List[BackendServerStats]')

Bases: object

backend_servers_stats: List[BackendServerStats]

List of objects containing Load Balancer statistics.

class scaleway.lb.v1.LbStatus(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

CREATING = 'creating'
DELETING = 'deleting'
ERROR = 'error'
LOCKED = 'locked'
MIGRATING = 'migrating'
PENDING = 'pending'
READY = 'ready'
STOPPED = 'stopped'
TO_CREATE = 'to_create'
TO_DELETE = 'to_delete'
UNKNOWN = 'unknown'
class scaleway.lb.v1.LbType(name: 'str', stock_status: 'LbTypeStock', description: 'str', zone: 'ScwZone', region: 'Optional[ScwRegion]' = None)

Bases: object

description: str

Load Balancer commercial offer type description.

name: str

Load Balancer commercial offer type name.

region: str | None = None

The region the Load Balancer stock is in.

stock_status: LbTypeStock

Current stock status for a given Load Balancer type.

zone: str

The zone the Load Balancer stock is in.

class scaleway.lb.v1.LbTypeStock(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

AVAILABLE = 'available'
LOW_STOCK = 'low_stock'
OUT_OF_STOCK = 'out_of_stock'
UNKNOWN = 'unknown'
class scaleway.lb.v1.LbV1API(client: Client, *, bypass_validation: bool = False)

Bases: API

This API allows you to manage your Load Balancers.

add_backend_servers(*, backend_id: str, server_ip: List[str], region: str | None = None) Backend

Add a set of servers in a given backend. :param backend_id: Backend ID. :param server_ip: List of IP addresses to add to backend servers. :param region: Region to target. If none is passed will use default region from the config. :return: Backend

Usage:

result = api.add_backend_servers(
    backend_id="example",
    server_ip=[],
)
attach_private_network(*, lb_id: str, private_network_id: str, region: str | None = None, static_config: PrivateNetworkStaticConfig | None = None, dhcp_config: PrivateNetworkDHCPConfig | None = None, ipam_config: PrivateNetworkIpamConfig | None = None, ipam_ids: List[str] | None = None) PrivateNetwork

Add load balancer on instance private network. :param lb_id: Load Balancer ID. :param private_network_id: Private Network ID. :param region: Region to target. If none is passed will use default region from the config. :param static_config: Object containing an array of a local IP address for the Load Balancer on this Private Network. One-Of (‘config’): at most one of ‘static_config’, ‘dhcp_config’, ‘ipam_config’ could be set. :param dhcp_config: Defines whether to let DHCP assign IP addresses. One-Of (‘config’): at most one of ‘static_config’, ‘dhcp_config’, ‘ipam_config’ could be set. :param ipam_config: For internal use only. One-Of (‘config’): at most one of ‘static_config’, ‘dhcp_config’, ‘ipam_config’ could be set. :param ipam_ids: IPAM ID of a pre-reserved IP address to assign to the Load Balancer on this Private Network. In the future, it will be possible to specify multiple IPs in this field (IPv4 and IPv6), for now only one ID of an IPv4 address is expected. When null, a new private IP address is created for the Load Balancer on this Private Network. :return: PrivateNetwork

Usage:

result = api.attach_private_network(
    lb_id="example",
    private_network_id="example",
)
create_acl(*, frontend_id: str, action: AclAction, index: int, description: str, region: str | None = None, name: str | None = None, match: AclMatch | None = None) Acl

Create an ACL for a given frontend. :param frontend_id: Frontend ID to attach the ACL to. :param action: Action to take when incoming traffic matches an ACL filter. :param index: Priority of this ACL (ACLs are applied in ascending order, 0 is the first ACL executed). :param description: ACL description. :param region: Region to target. If none is passed will use default region from the config. :param name: ACL name. :param match: ACL match filter object. One of ip_subnet, ips_edge_services or http_filter & http_filter_value are required. :return: Acl

Usage:

result = api.create_acl(
    frontend_id="example",
    action=AclAction(),
    index=1,
    description="example",
)
create_backend(*, forward_protocol: Protocol, forward_port: int, forward_port_algorithm: ForwardPortAlgorithm, sticky_sessions: StickySessionsType, sticky_sessions_cookie_name: str, lb_id: str, health_check: HealthCheck, server_ip: List[str], region: str | None = None, name: str | None = None, send_proxy_v2: bool | None = None, timeout_server: str | None = None, timeout_connect: str | None = None, timeout_tunnel: str | None = None, on_marked_down_action: OnMarkedDownAction | None = None, proxy_protocol: ProxyProtocol | None = None, failover_host: str | None = None, ssl_bridging: bool | None = None, ignore_ssl_server_verify: bool | None = None, redispatch_attempt_count: int | None = None, max_retries: int | None = None, max_connections: int | None = None, timeout_queue: str | None = None) Backend

Create a backend in a given load balancer. :param forward_protocol: Protocol to be used by the backend when forwarding traffic to backend servers. :param forward_port: Port to be used by the backend when forwarding traffic to backend servers. :param forward_port_algorithm: Load balancing algorithm to be used when determining which backend server to forward new traffic to. :param sticky_sessions: Defines whether to activate sticky sessions (binding a particular session to a particular backend server) and the method to use if so. None disables sticky sessions. Cookie-based uses an HTTP cookie TO stick a session to a backend server. Table-based uses the source (client) IP address to stick a session to a backend server. :param sticky_sessions_cookie_name: Cookie name for cookie-based sticky sessions. :param lb_id: Load Balancer ID. :param health_check: Object defining the health check to be carried out by the backend when checking the status and health of backend servers. :param server_ip: List of backend server IP addresses (IPv4 or IPv6) the backend should forward traffic to. :param region: Region to target. If none is passed will use default region from the config. :param name: Name for the backend. :param send_proxy_v2: Deprecated in favor of proxy_protocol field. :param timeout_server: Maximum allowed time for a backend server to process a request. :param timeout_connect: Maximum allowed time for establishing a connection to a backend server. :param timeout_tunnel: Maximum allowed tunnel inactivity time after Websocket is established (takes precedence over client and server timeout). :param on_marked_down_action: Action to take when a backend server is marked as down. :param proxy_protocol: Protocol to use between the Load Balancer and backend servers. Allows the backend servers to be informed of the client’s real IP address. The PROXY protocol must be supported by the backend servers’ software. :param failover_host: Scaleway Object Storage bucket website to be served as failover if all backend servers are down, e.g. failover-website.s3-website.fr-par.scw.cloud. :param ssl_bridging: Defines whether to enable SSL bridging between the Load Balancer and backend servers. :param ignore_ssl_server_verify: Defines whether the server certificate verification should be ignored. :param redispatch_attempt_count: Whether to use another backend server on each attempt. :param max_retries: Number of retries when a backend server connection failed. :param max_connections: Maximum number of connections allowed per backend server. :param timeout_queue: Maximum time for a request to be left pending in queue when max_connections is reached. :return: Backend

Usage:

result = api.create_backend(
    forward_protocol=Protocol.tcp,
    forward_port=1,
    forward_port_algorithm=ForwardPortAlgorithm.roundrobin,
    sticky_sessions=StickySessionsType.none,
    sticky_sessions_cookie_name="example",
    lb_id="example",
    health_check=HealthCheck(),
    server_ip=[],
)
create_certificate(*, lb_id: str, region: str | None = None, name: str | None = None, letsencrypt: CreateCertificateRequestLetsencryptConfig | None = None, custom_certificate: CreateCertificateRequestCustomCertificate | None = None) Certificate

Create a TLS certificate. Generate a new TLS certificate using Let’s Encrypt or import your certificate. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :param name: Name for the certificate. :param letsencrypt: Object to define a new Let’s Encrypt certificate to be generated. One-Of (‘type’): at most one of ‘letsencrypt’, ‘custom_certificate’ could be set. :param custom_certificate: Object to define an existing custom certificate to be imported. One-Of (‘type’): at most one of ‘letsencrypt’, ‘custom_certificate’ could be set. :return: Certificate

Usage:

result = api.create_certificate(
    lb_id="example",
)
create_frontend(*, inbound_port: int, lb_id: str, backend_id: str, enable_http3: bool, enable_access_logs: bool, region: str | None = None, name: str | None = None, timeout_client: str | None = None, certificate_id: str | None = None, certificate_ids: List[str] | None = None, connection_rate_limit: int | None = None) Frontend

Create a frontend in a given load balancer. :param inbound_port: Port the frontend should listen on. :param lb_id: Load Balancer ID (ID of the Load Balancer to attach the frontend to). :param backend_id: Backend ID (ID of the backend the frontend should pass traffic to). :param enable_http3: Defines whether to enable HTTP/3 protocol on the frontend. :param enable_access_logs: Defines whether to enable access logs on the frontend. :param region: Region to target. If none is passed will use default region from the config. :param name: Name for the frontend. :param timeout_client: Maximum allowed inactivity time on the client side. :param certificate_id: Certificate ID, deprecated in favor of certificate_ids array. :param certificate_ids: List of SSL/TLS certificate IDs to bind to the frontend. :param connection_rate_limit: Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. :return: Frontend

Usage:

result = api.create_frontend(
    inbound_port=1,
    lb_id="example",
    backend_id="example",
    enable_http3=False,
    enable_access_logs=False,
)
create_ip(*, is_ipv6: bool, region: str | None = None, organization_id: str | None = None, project_id: str | None = None, reverse: str | None = None, tags: List[str] | None = None) Ip

Create an IP. :param is_ipv6: If true, creates a Flexible IP with an ipv6 address. :param region: Region to target. If none is passed will use default region from the config. :param organization_id: Organization ID of the Organization where the IP address should be created. One-Of (‘project_identifier’): at most one of ‘project_id’, ‘organization_id’ could be set. :param project_id: Project ID of the Project where the IP address should be created. One-Of (‘project_identifier’): at most one of ‘project_id’, ‘organization_id’ could be set. :param reverse: Reverse DNS (domain name) for the IP address. :param tags: List of tags for the IP. :return: Ip

Usage:

result = api.create_ip(
    is_ipv6=False,
)
create_lb(*, description: str, type_: str, region: str | None = None, organization_id: str | None = None, project_id: str | None = None, name: str | None = None, ip_id: str | None = None, assign_flexible_ip: bool | None = None, assign_flexible_ipv6: bool | None = None, ip_ids: List[str] | None = None, tags: List[str] | None = None, ssl_compatibility_level: SSLCompatibilityLevel | None = None) Lb

Create a load balancer. :param description: Description for the Load Balancer. :param type_: Load Balancer commercial offer type. Use the Load Balancer types endpoint to retrieve a list of available offer types. :param region: Region to target. If none is passed will use default region from the config. :param organization_id: Scaleway Organization to create the Load Balancer in. One-Of (‘project_identifier’): at most one of ‘project_id’, ‘organization_id’ could be set. :param project_id: Scaleway Project to create the Load Balancer in. One-Of (‘project_identifier’): at most one of ‘project_id’, ‘organization_id’ could be set. :param name: Name for the Load Balancer. :param ip_id: ID of an existing flexible IP address to attach to the Load Balancer. :param assign_flexible_ip: Defines whether to automatically assign a flexible public IP to the Load Balancer. Default value is true (assign). :param assign_flexible_ipv6: Defines whether to automatically assign a flexible public IPv6 to the Load Balancer. Default value is false (do not assign). :param ip_ids: List of IP IDs to attach to the Load Balancer. :param tags: List of tags for the Load Balancer. :param ssl_compatibility_level: Determines the minimal SSL version which needs to be supported on the client side, in an SSL/TLS offloading context. Intermediate is suitable for general-purpose servers with a variety of clients, recommended for almost all systems. Modern is suitable for services with clients that support TLS 1.3 and do not need backward compatibility. Old is compatible with a small number of very old clients and should be used only as a last resort. :return: Lb

Usage:

result = api.create_lb(
    description="example",
    type="example",
)
create_route(*, frontend_id: str, backend_id: str, region: str | None = None, match: RouteMatch | None = None) Route

Create a backend redirection. :param frontend_id: ID of the source frontend to create the route on. :param backend_id: ID of the target backend for the route. :param region: Region to target. If none is passed will use default region from the config. :param match: Object defining the match condition for a route to be applied. If an incoming client session matches the specified condition (i.e. it has a matching SNI value or HTTP Host header value), it will be passed to the target backend. :return: Route

Usage:

result = api.create_route(
    frontend_id="example",
    backend_id="example",
)
create_subscriber(*, name: str, region: str | None = None, email_config: SubscriberEmailConfig | None = None, webhook_config: SubscriberWebhookConfig | None = None, organization_id: str | None = None, project_id: str | None = None) Subscriber

Create a subscriber, webhook or email. :param name: Subscriber name. :param region: Region to target. If none is passed will use default region from the config. :param email_config: Email address configuration. One-Of (‘config’): at most one of ‘email_config’, ‘webhook_config’ could be set. :param webhook_config: WebHook URI configuration. One-Of (‘config’): at most one of ‘email_config’, ‘webhook_config’ could be set. :param organization_id: Organization ID to create the subscriber in. One-Of (‘project_identifier’): at most one of ‘project_id’, ‘organization_id’ could be set. :param project_id: Project ID to create the subscriber in. One-Of (‘project_identifier’): at most one of ‘project_id’, ‘organization_id’ could be set. :return: Subscriber

Usage:

result = api.create_subscriber(
    name="example",
)
delete_acl(*, acl_id: str, region: str | None = None) None

Delete an ACL. :param acl_id: ACL ID. :param region: Region to target. If none is passed will use default region from the config.

Usage:

result = api.delete_acl(
    acl_id="example",
)
delete_backend(*, backend_id: str, region: str | None = None) None

Delete a backend in a given load balancer. :param backend_id: ID of the backend to delete. :param region: Region to target. If none is passed will use default region from the config.

Usage:

result = api.delete_backend(
    backend_id="example",
)
delete_certificate(*, certificate_id: str, region: str | None = None) None

Delete a TLS certificate. :param certificate_id: Certificate ID. :param region: Region to target. If none is passed will use default region from the config.

Usage:

result = api.delete_certificate(
    certificate_id="example",
)
delete_frontend(*, frontend_id: str, region: str | None = None) None

Delete a frontend. :param frontend_id: ID of the frontend to delete. :param region: Region to target. If none is passed will use default region from the config.

Usage:

result = api.delete_frontend(
    frontend_id="example",
)
delete_lb(*, lb_id: str, release_ip: bool, region: str | None = None) None

Delete a load balancer. :param lb_id: ID of the Load Balancer to delete. :param release_ip: Defines whether the Load Balancer’s flexible IP should be deleted. Set to true to release the flexible IP, or false to keep it available in your account for future Load Balancers. :param region: Region to target. If none is passed will use default region from the config.

Usage:

result = api.delete_lb(
    lb_id="example",
    release_ip=False,
)
delete_route(*, route_id: str, region: str | None = None) None

Delete a backend redirection. :param route_id: Route ID. :param region: Region to target. If none is passed will use default region from the config.

Usage:

result = api.delete_route(
    route_id="example",
)
delete_subscriber(*, subscriber_id: str, region: str | None = None) None

Delete a subscriber. :param subscriber_id: Subscriber ID. :param region: Region to target. If none is passed will use default region from the config.

Usage:

result = api.delete_subscriber(
    subscriber_id="example",
)
detach_private_network(*, lb_id: str, private_network_id: str, region: str | None = None) None

Remove load balancer of private network. :param lb_id: Load balancer ID. :param private_network_id: Set your instance private network id. :param region: Region to target. If none is passed will use default region from the config.

Usage:

result = api.detach_private_network(
    lb_id="example",
    private_network_id="example",
)
get_acl(*, acl_id: str, region: str | None = None) Acl

Get an ACL. :param acl_id: ACL ID. :param region: Region to target. If none is passed will use default region from the config. :return: Acl

Usage:

result = api.get_acl(
    acl_id="example",
)
get_backend(*, backend_id: str, region: str | None = None) Backend

Get a backend in a given load balancer. :param backend_id: Backend ID. :param region: Region to target. If none is passed will use default region from the config. :return: Backend

Usage:

result = api.get_backend(
    backend_id="example",
)
get_certificate(*, certificate_id: str, region: str | None = None) Certificate

Get a TLS certificate. :param certificate_id: Certificate ID. :param region: Region to target. If none is passed will use default region from the config. :return: Certificate

Usage:

result = api.get_certificate(
    certificate_id="example",
)
get_frontend(*, frontend_id: str, region: str | None = None) Frontend

Get a frontend. :param frontend_id: Frontend ID. :param region: Region to target. If none is passed will use default region from the config. :return: Frontend

Usage:

result = api.get_frontend(
    frontend_id="example",
)
get_ip(*, ip_id: str, region: str | None = None) Ip

Get an IP. :param ip_id: IP address ID. :param region: Region to target. If none is passed will use default region from the config. :return: Ip

Usage:

result = api.get_ip(
    ip_id="example",
)
get_lb(*, lb_id: str, region: str | None = None) Lb

Get a load balancer. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :return: Lb

Usage:

result = api.get_lb(
    lb_id="example",
)
get_lb_stats(*, lb_id: str, region: str | None = None, backend_id: str | None = None) LbStats

Get usage statistics of a given load balancer. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :param backend_id: ID of the backend. :return: LbStats :deprecated

Usage:

result = api.get_lb_stats(
    lb_id="example",
)
get_route(*, route_id: str, region: str | None = None) Route

Get single backend redirection. :param route_id: Route ID. :param region: Region to target. If none is passed will use default region from the config. :return: Route

Usage:

result = api.get_route(
    route_id="example",
)
get_subscriber(*, subscriber_id: str, region: str | None = None) Subscriber

Get a subscriber. :param subscriber_id: Subscriber ID. :param region: Region to target. If none is passed will use default region from the config. :return: Subscriber

Usage:

result = api.get_subscriber(
    subscriber_id="example",
)
list_acls(*, frontend_id: str, region: str | None = None, order_by: ListAclRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None, name: str | None = None) ListAclResponse

List ACL for a given frontend. :param frontend_id: Frontend ID (ACLs attached to this frontend will be returned in the response). :param region: Region to target. If none is passed will use default region from the config. :param order_by: Sort order of ACLs in the response. :param page: The page number to return, from the paginated results. :param page_size: The number of ACLs to return. :param name: ACL name to filter for. :return: ListAclResponse

Usage:

result = api.list_acls(
    frontend_id="example",
)
list_acls_all(*, frontend_id: str, region: str | None = None, order_by: ListAclRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None, name: str | None = None) List[Acl]

List ACL for a given frontend. :param frontend_id: Frontend ID (ACLs attached to this frontend will be returned in the response). :param region: Region to target. If none is passed will use default region from the config. :param order_by: Sort order of ACLs in the response. :param page: The page number to return, from the paginated results. :param page_size: The number of ACLs to return. :param name: ACL name to filter for. :return: List[Acl]

Usage:

result = api.list_acls_all(
    frontend_id="example",
)
list_backend_stats(*, lb_id: str, region: str | None = None, page: int | None = None, page_size: int | None = None, backend_id: str | None = None) ListBackendStatsResponse

List backend server statistics. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :param page: The page number to return, from the paginated results. :param page_size: Number of items to return. :param backend_id: ID of the backend. :return: ListBackendStatsResponse

Usage:

result = api.list_backend_stats(
    lb_id="example",
)
list_backend_stats_all(*, lb_id: str, region: str | None = None, page: int | None = None, page_size: int | None = None, backend_id: str | None = None) List[BackendServerStats]

List backend server statistics. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :param page: The page number to return, from the paginated results. :param page_size: Number of items to return. :param backend_id: ID of the backend. :return: List[BackendServerStats]

Usage:

result = api.list_backend_stats_all(
    lb_id="example",
)
list_backends(*, lb_id: str, region: str | None = None, name: str | None = None, order_by: ListBackendsRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None) ListBackendsResponse

List backends in a given load balancer. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :param name: Name of the backend to filter for. :param order_by: Sort order of backends in the response. :param page: The page number to return, from the paginated results. :param page_size: Number of backends to return. :return: ListBackendsResponse

Usage:

result = api.list_backends(
    lb_id="example",
)
list_backends_all(*, lb_id: str, region: str | None = None, name: str | None = None, order_by: ListBackendsRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None) List[Backend]

List backends in a given load balancer. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :param name: Name of the backend to filter for. :param order_by: Sort order of backends in the response. :param page: The page number to return, from the paginated results. :param page_size: Number of backends to return. :return: List[Backend]

Usage:

result = api.list_backends_all(
    lb_id="example",
)
list_certificates(*, lb_id: str, region: str | None = None, order_by: ListCertificatesRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None, name: str | None = None) ListCertificatesResponse

List all TLS certificates on a given load balancer. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :param order_by: Sort order of certificates in the response. :param page: The page number to return, from the paginated results. :param page_size: Number of certificates to return. :param name: Certificate name to filter for, only certificates of this name will be returned. :return: ListCertificatesResponse

Usage:

result = api.list_certificates(
    lb_id="example",
)
list_certificates_all(*, lb_id: str, region: str | None = None, order_by: ListCertificatesRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None, name: str | None = None) List[Certificate]

List all TLS certificates on a given load balancer. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :param order_by: Sort order of certificates in the response. :param page: The page number to return, from the paginated results. :param page_size: Number of certificates to return. :param name: Certificate name to filter for, only certificates of this name will be returned. :return: List[Certificate]

Usage:

result = api.list_certificates_all(
    lb_id="example",
)
list_frontends(*, lb_id: str, region: str | None = None, name: str | None = None, order_by: ListFrontendsRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None) ListFrontendsResponse

List frontends in a given load balancer. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :param name: Name of the frontend to filter for. :param order_by: Sort order of frontends in the response. :param page: The page number to return, from the paginated results. :param page_size: Number of frontends to return. :return: ListFrontendsResponse

Usage:

result = api.list_frontends(
    lb_id="example",
)
list_frontends_all(*, lb_id: str, region: str | None = None, name: str | None = None, order_by: ListFrontendsRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None) List[Frontend]

List frontends in a given load balancer. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :param name: Name of the frontend to filter for. :param order_by: Sort order of frontends in the response. :param page: The page number to return, from the paginated results. :param page_size: Number of frontends to return. :return: List[Frontend]

Usage:

result = api.list_frontends_all(
    lb_id="example",
)
list_i_ps(*, region: str | None = None, page: int | None = None, page_size: int | None = None, ip_address: str | None = None, organization_id: str | None = None, project_id: str | None = None, ip_type: ListIpsRequestIpType | None = None, tags: List[str] | None = None) ListIpsResponse

List IPs. :param region: Region to target. If none is passed will use default region from the config. :param page: The page number to return, from the paginated results. :param page_size: Number of IP addresses to return. :param ip_address: IP address to filter for. :param organization_id: Organization ID to filter for, only Load Balancer IP addresses from this Organization will be returned. :param project_id: Project ID to filter for, only Load Balancer IP addresses from this Project will be returned. :param ip_type: IP type to filter for. :param tags: Tag to filter for, only IPs with one or more matching tags will be returned. :return: ListIpsResponse

Usage:

result = api.list_i_ps()
list_i_ps_all(*, region: str | None = None, page: int | None = None, page_size: int | None = None, ip_address: str | None = None, organization_id: str | None = None, project_id: str | None = None, ip_type: ListIpsRequestIpType | None = None, tags: List[str] | None = None) List[Ip]

List IPs. :param region: Region to target. If none is passed will use default region from the config. :param page: The page number to return, from the paginated results. :param page_size: Number of IP addresses to return. :param ip_address: IP address to filter for. :param organization_id: Organization ID to filter for, only Load Balancer IP addresses from this Organization will be returned. :param project_id: Project ID to filter for, only Load Balancer IP addresses from this Project will be returned. :param ip_type: IP type to filter for. :param tags: Tag to filter for, only IPs with one or more matching tags will be returned. :return: List[Ip]

Usage:

result = api.list_i_ps_all()
list_lb_private_networks(*, lb_id: str, region: str | None = None, order_by: ListPrivateNetworksRequestOrderBy | None = None, page_size: int | None = None, page: int | None = None) ListLbPrivateNetworksResponse

List attached private network of load balancer. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :param order_by: Sort order of Private Network objects in the response. :param page_size: Number of objects to return. :param page: The page number to return, from the paginated results. :return: ListLbPrivateNetworksResponse

Usage:

result = api.list_lb_private_networks(
    lb_id="example",
)
list_lb_private_networks_all(*, lb_id: str, region: str | None = None, order_by: ListPrivateNetworksRequestOrderBy | None = None, page_size: int | None = None, page: int | None = None) List[PrivateNetwork]

List attached private network of load balancer. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :param order_by: Sort order of Private Network objects in the response. :param page_size: Number of objects to return. :param page: The page number to return, from the paginated results. :return: List[PrivateNetwork]

Usage:

result = api.list_lb_private_networks_all(
    lb_id="example",
)
list_lb_types(*, region: str | None = None, page: int | None = None, page_size: int | None = None) ListLbTypesResponse

List all load balancer offer type. :param region: Region to target. If none is passed will use default region from the config. :param page: The page number to return, from the paginated results. :param page_size: The number of items to return. :return: ListLbTypesResponse

Usage:

result = api.list_lb_types()
list_lb_types_all(*, region: str | None = None, page: int | None = None, page_size: int | None = None) List[LbType]

List all load balancer offer type. :param region: Region to target. If none is passed will use default region from the config. :param page: The page number to return, from the paginated results. :param page_size: The number of items to return. :return: List[LbType]

Usage:

result = api.list_lb_types_all()
list_lbs(*, region: str | None = None, name: str | None = None, order_by: ListLbsRequestOrderBy | None = None, page_size: int | None = None, page: int | None = None, organization_id: str | None = None, project_id: str | None = None, tags: List[str] | None = None) ListLbsResponse

List load balancers. :param region: Region to target. If none is passed will use default region from the config. :param name: Load Balancer name to filter for. :param order_by: Sort order of Load Balancers in the response. :param page_size: Number of Load Balancers to return. :param page: Page number to return, from the paginated results. :param organization_id: Organization ID to filter for, only Load Balancers from this Organization will be returned. :param project_id: Project ID to filter for, only Load Balancers from this Project will be returned. :param tags: Filter by tag, only Load Balancers with one or more matching tags will be returned. :return: ListLbsResponse

Usage:

result = api.list_lbs()
list_lbs_all(*, region: str | None = None, name: str | None = None, order_by: ListLbsRequestOrderBy | None = None, page_size: int | None = None, page: int | None = None, organization_id: str | None = None, project_id: str | None = None, tags: List[str] | None = None) List[Lb]

List load balancers. :param region: Region to target. If none is passed will use default region from the config. :param name: Load Balancer name to filter for. :param order_by: Sort order of Load Balancers in the response. :param page_size: Number of Load Balancers to return. :param page: Page number to return, from the paginated results. :param organization_id: Organization ID to filter for, only Load Balancers from this Organization will be returned. :param project_id: Project ID to filter for, only Load Balancers from this Project will be returned. :param tags: Filter by tag, only Load Balancers with one or more matching tags will be returned. :return: List[Lb]

Usage:

result = api.list_lbs_all()
list_routes(*, region: str | None = None, order_by: ListRoutesRequestOrderBy | None = None, page_size: int | None = None, page: int | None = None, frontend_id: str | None = None) ListRoutesResponse

List all backend redirections. :param region: Region to target. If none is passed will use default region from the config. :param order_by: Sort order of routes in the response. :param page_size: The number of route objects to return. :param page: The page number to return, from the paginated results. :param frontend_id: Frontend ID to filter for, only Routes from this Frontend will be returned. :return: ListRoutesResponse

Usage:

result = api.list_routes()
list_routes_all(*, region: str | None = None, order_by: ListRoutesRequestOrderBy | None = None, page_size: int | None = None, page: int | None = None, frontend_id: str | None = None) List[Route]

List all backend redirections. :param region: Region to target. If none is passed will use default region from the config. :param order_by: Sort order of routes in the response. :param page_size: The number of route objects to return. :param page: The page number to return, from the paginated results. :param frontend_id: Frontend ID to filter for, only Routes from this Frontend will be returned. :return: List[Route]

Usage:

result = api.list_routes_all()
list_subscriber(*, region: str | None = None, order_by: ListSubscriberRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None, name: str | None = None, organization_id: str | None = None, project_id: str | None = None) ListSubscriberResponse

List all subscriber. :param region: Region to target. If none is passed will use default region from the config. :param order_by: Sort order of subscribers in the response. :param page: The page number to return, from the paginated results. :param page_size: The number of items to return. :param name: Subscriber name to search for. :param organization_id: Filter subscribers by Organization ID. :param project_id: Filter subscribers by Project ID. :return: ListSubscriberResponse

Usage:

result = api.list_subscriber()
list_subscriber_all(*, region: str | None = None, order_by: ListSubscriberRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None, name: str | None = None, organization_id: str | None = None, project_id: str | None = None) List[Subscriber]

List all subscriber. :param region: Region to target. If none is passed will use default region from the config. :param order_by: Sort order of subscribers in the response. :param page: The page number to return, from the paginated results. :param page_size: The number of items to return. :param name: Subscriber name to search for. :param organization_id: Filter subscribers by Organization ID. :param project_id: Filter subscribers by Project ID. :return: List[Subscriber]

Usage:

result = api.list_subscriber_all()
migrate_lb(*, lb_id: str, type_: str, region: str | None = None) Lb

Migrate a load balancer. :param lb_id: Load Balancer ID. :param type_: Load Balancer type to migrate to (use the List all Load Balancer offer types endpoint to get a list of available offer types). :param region: Region to target. If none is passed will use default region from the config. :return: Lb

Usage:

result = api.migrate_lb(
    lb_id="example",
    type="example",
)
release_ip(*, ip_id: str, region: str | None = None) None

Delete an IP. :param ip_id: IP address ID. :param region: Region to target. If none is passed will use default region from the config.

Usage:

result = api.release_ip(
    ip_id="example",
)
remove_backend_servers(*, backend_id: str, server_ip: List[str], region: str | None = None) Backend

Remove a set of servers for a given backend. :param backend_id: Backend ID. :param server_ip: List of IP addresses to remove from backend servers. :param region: Region to target. If none is passed will use default region from the config. :return: Backend

Usage:

result = api.remove_backend_servers(
    backend_id="example",
    server_ip=[],
)
set_backend_servers(*, backend_id: str, server_ip: List[str], region: str | None = None) Backend

Define all servers in a given backend. :param backend_id: Backend ID. :param server_ip: List of IP addresses for backend servers. Any other existing backend servers will be removed. :param region: Region to target. If none is passed will use default region from the config. :return: Backend

Usage:

result = api.set_backend_servers(
    backend_id="example",
    server_ip=[],
)
subscribe_to_lb(*, lb_id: str, subscriber_id: str, region: str | None = None) Lb

Subscribe a subscriber to a given load balancer. :param lb_id: Load Balancer ID. :param subscriber_id: Subscriber ID. :param region: Region to target. If none is passed will use default region from the config. :return: Lb

Usage:

result = api.subscribe_to_lb(
    lb_id="example",
    subscriber_id="example",
)
unsubscribe_from_lb(*, lb_id: str, region: str | None = None) Lb

Unsubscribe a subscriber from a given load balancer. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :return: Lb

Usage:

result = api.unsubscribe_from_lb(
    lb_id="example",
)
update_acl(*, acl_id: str, name: str, action: AclAction, index: int, region: str | None = None, match: AclMatch | None = None, description: str | None = None) Acl

Update an ACL. :param acl_id: ACL ID. :param name: ACL name. :param action: Action to take when incoming traffic matches an ACL filter. :param index: Priority of this ACL (ACLs are applied in ascending order, 0 is the first ACL executed). :param region: Region to target. If none is passed will use default region from the config. :param match: ACL match filter object. One of ip_subnet, ips_edge_services or http_filter & http_filter_value are required. :param description: ACL description. :return: Acl

Usage:

result = api.update_acl(
    acl_id="example",
    name="example",
    action=AclAction(),
    index=1,
)
update_backend(*, backend_id: str, name: str, forward_protocol: Protocol, forward_port: int, forward_port_algorithm: ForwardPortAlgorithm, sticky_sessions: StickySessionsType, sticky_sessions_cookie_name: str, region: str | None = None, send_proxy_v2: bool | None = None, timeout_server: str | None = None, timeout_connect: str | None = None, timeout_tunnel: str | None = None, on_marked_down_action: OnMarkedDownAction | None = None, proxy_protocol: ProxyProtocol | None = None, failover_host: str | None = None, ssl_bridging: bool | None = None, ignore_ssl_server_verify: bool | None = None, redispatch_attempt_count: int | None = None, max_retries: int | None = None, max_connections: int | None = None, timeout_queue: str | None = None) Backend

Update a backend in a given load balancer. :param backend_id: Backend ID. :param name: Backend name. :param forward_protocol: Protocol to be used by the backend when forwarding traffic to backend servers. :param forward_port: Port to be used by the backend when forwarding traffic to backend servers. :param forward_port_algorithm: Load balancing algorithm to be used when determining which backend server to forward new traffic to. :param sticky_sessions: Defines whether to activate sticky sessions (binding a particular session to a particular backend server) and the method to use if so. None disables sticky sessions. Cookie-based uses an HTTP cookie to stick a session to a backend server. Table-based uses the source (client) IP address to stick a session to a backend server. :param sticky_sessions_cookie_name: Cookie name for cookie-based sticky sessions. :param region: Region to target. If none is passed will use default region from the config. :param send_proxy_v2: Deprecated in favor of proxy_protocol field. :param timeout_server: Maximum allowed time for a backend server to process a request. :param timeout_connect: Maximum allowed time for establishing a connection to a backend server. :param timeout_tunnel: Maximum allowed tunnel inactivity time after Websocket is established (takes precedence over client and server timeout). :param on_marked_down_action: Action to take when a backend server is marked as down. :param proxy_protocol: Protocol to use between the Load Balancer and backend servers. Allows the backend servers to be informed of the client’s real IP address. The PROXY protocol must be supported by the backend servers’ software. :param failover_host: Scaleway Object Storage bucket website to be served as failover if all backend servers are down, e.g. failover-website.s3-website.fr-par.scw.cloud. :param ssl_bridging: Defines whether to enable SSL bridging between the Load Balancer and backend servers. :param ignore_ssl_server_verify: Defines whether the server certificate verification should be ignored. :param redispatch_attempt_count: Whether to use another backend server on each attempt. :param max_retries: Number of retries when a backend server connection failed. :param max_connections: Maximum number of connections allowed per backend server. :param timeout_queue: Maximum time for a request to be left pending in queue when max_connections is reached. :return: Backend

Usage:

result = api.update_backend(
    backend_id="example",
    name="example",
    forward_protocol=Protocol.tcp,
    forward_port=1,
    forward_port_algorithm=ForwardPortAlgorithm.roundrobin,
    sticky_sessions=StickySessionsType.none,
    sticky_sessions_cookie_name="example",
)
update_certificate(*, certificate_id: str, name: str, region: str | None = None) Certificate

Update a TLS certificate. :param certificate_id: Certificate ID. :param name: Certificate name. :param region: Region to target. If none is passed will use default region from the config. :return: Certificate

Usage:

result = api.update_certificate(
    certificate_id="example",
    name="example",
)
update_frontend(*, frontend_id: str, name: str, inbound_port: int, backend_id: str, enable_http3: bool, region: str | None = None, timeout_client: str | None = None, certificate_id: str | None = None, certificate_ids: List[str] | None = None, connection_rate_limit: int | None = None, enable_access_logs: bool | None = None) Frontend

Update a frontend. :param frontend_id: Frontend ID. :param name: Frontend name. :param inbound_port: Port the frontend should listen on. :param backend_id: Backend ID (ID of the backend the frontend should pass traffic to). :param enable_http3: Defines whether to enable HTTP/3 protocol on the frontend. :param region: Region to target. If none is passed will use default region from the config. :param timeout_client: Maximum allowed inactivity time on the client side. :param certificate_id: Certificate ID, deprecated in favor of certificate_ids array. :param certificate_ids: List of SSL/TLS certificate IDs to bind to the frontend. :param connection_rate_limit: Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. :param enable_access_logs: Defines whether to enable access logs on the frontend. :return: Frontend

Usage:

result = api.update_frontend(
    frontend_id="example",
    name="example",
    inbound_port=1,
    backend_id="example",
    enable_http3=False,
)
update_health_check(*, port: int, check_max_retries: int, backend_id: str, region: str | None = None, check_delay: str | None = None, check_timeout: str | None = None, check_send_proxy: bool, tcp_config: HealthCheckTcpConfig | None = None, mysql_config: HealthCheckMysqlConfig | None = None, pgsql_config: HealthCheckPgsqlConfig | None = None, ldap_config: HealthCheckLdapConfig | None = None, redis_config: HealthCheckRedisConfig | None = None, http_config: HealthCheckHttpConfig | None = None, https_config: HealthCheckHttpsConfig | None = None, transient_check_delay: str | None = None) HealthCheck

Update an health check for a given backend. :param port: Port to use for the backend server health check. :param check_max_retries: Number of consecutive unsuccessful health checks after which the server will be considered dead. :param backend_id: Backend ID. :param region: Region to target. If none is passed will use default region from the config. :param check_delay: Time to wait between two consecutive health checks. :param check_timeout: Maximum time a backend server has to reply to the health check. :param check_send_proxy: Defines whether proxy protocol should be activated for the health check. :param tcp_config: Object to configure a basic TCP health check. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param mysql_config: Object to configure a MySQL health check. The check requires MySQL >=3.22 or <9.0. For older or newer versions, use a TCP health check. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param pgsql_config: Object to configure a PostgreSQL health check. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param ldap_config: Object to configure an LDAP health check. The response is analyzed to find the LDAPv3 response message. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param redis_config: Object to configure a Redis health check. The response is analyzed to find the +PONG response message. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param http_config: Object to configure an HTTP health check. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param https_config: Object to configure an HTTPS health check. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param transient_check_delay: Time to wait between two consecutive health checks when a backend server is in a transient state (going UP or DOWN). :return: HealthCheck

Usage:

result = api.update_health_check(
    port=1,
    check_max_retries=1,
    backend_id="example",
    check_send_proxy=False,
)
update_ip(*, ip_id: str, region: str | None = None, reverse: str | None = None, lb_id: str | None = None, tags: List[str] | None = None) Ip

Update an IP. :param ip_id: IP address ID. :param region: Region to target. If none is passed will use default region from the config. :param reverse: Reverse DNS (domain name) for the IP address. :param lb_id: ID of the server on which to attach the flexible IP. :param tags: List of tags for the IP. :return: Ip

Usage:

result = api.update_ip(
    ip_id="example",
)
update_lb(*, lb_id: str, name: str, description: str, region: str | None = None, tags: List[str] | None = None, ssl_compatibility_level: SSLCompatibilityLevel | None = None) Lb

Update a load balancer. :param lb_id: Load Balancer ID. :param name: Load Balancer name. :param description: Load Balancer description. :param region: Region to target. If none is passed will use default region from the config. :param tags: List of tags for the Load Balancer. :param ssl_compatibility_level: Determines the minimal SSL version which needs to be supported on the client side, in an SSL/TLS offloading context. Intermediate is suitable for general-purpose servers with a variety of clients, recommended for almost all systems. Modern is suitable for services with clients that support TLS 1.3 and don’t need backward compatibility. Old is compatible with a small number of very old clients and should be used only as a last resort. :return: Lb

Usage:

result = api.update_lb(
    lb_id="example",
    name="example",
    description="example",
)
update_route(*, route_id: str, backend_id: str, region: str | None = None, match: RouteMatch | None = None) Route

Edit a backend redirection. :param route_id: Route ID. :param backend_id: ID of the target backend for the route. :param region: Region to target. If none is passed will use default region from the config. :param match: Object defining the match condition for a route to be applied. If an incoming client session matches the specified condition (i.e. it has a matching SNI value or HTTP Host header value), it will be passed to the target backend. :return: Route

Usage:

result = api.update_route(
    route_id="example",
    backend_id="example",
)
update_subscriber(*, subscriber_id: str, name: str, region: str | None = None, email_config: SubscriberEmailConfig | None = None, webhook_config: SubscriberWebhookConfig | None = None) Subscriber

Update a subscriber. :param subscriber_id: Subscriber ID. :param name: Subscriber name. :param region: Region to target. If none is passed will use default region from the config. :param email_config: Email address configuration. One-Of (‘config’): at most one of ‘email_config’, ‘webhook_config’ could be set. :param webhook_config: Webhook URI configuration. One-Of (‘config’): at most one of ‘email_config’, ‘webhook_config’ could be set. :return: Subscriber

Usage:

result = api.update_subscriber(
    subscriber_id="example",
    name="example",
)
wait_for_certificate(*, certificate_id: str, region: str | None = None, options: WaitForOptions[Certificate, bool] | None = None) Certificate

Get a TLS certificate. :param certificate_id: Certificate ID. :param region: Region to target. If none is passed will use default region from the config. :return: Certificate

Usage:

result = api.get_certificate(
    certificate_id="example",
)
wait_for_lb(*, lb_id: str, region: str | None = None, options: WaitForOptions[Lb, bool] | None = None) Lb

Get a load balancer. :param lb_id: Load Balancer ID. :param region: Region to target. If none is passed will use default region from the config. :return: Lb

Usage:

result = api.get_lb(
    lb_id="example",
)
class scaleway.lb.v1.LbV1ZonedAPI(client: Client, *, bypass_validation: bool = False)

Bases: API

This API allows you to manage your Scaleway Load Balancer services.

add_backend_servers(*, backend_id: str, server_ip: List[str], zone: str | None = None) Backend

Add a set of backend servers to a given backend. For a given backend specified by its backend ID, add a set of backend servers (identified by their IP addresses) it should forward traffic to. These will be appended to any existing set of backend servers for this backend. :param backend_id: Backend ID. :param server_ip: List of IP addresses to add to backend servers. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Backend

Usage:

result = api.add_backend_servers(
    backend_id="example",
    server_ip=[],
)
attach_private_network(*, lb_id: str, private_network_id: str, zone: str | None = None, static_config: PrivateNetworkStaticConfig | None = None, dhcp_config: PrivateNetworkDHCPConfig | None = None, ipam_config: PrivateNetworkIpamConfig | None = None, ipam_ids: List[str] | None = None) PrivateNetwork

Attach a Load Balancer to a Private Network. Attach a specified Load Balancer to a specified Private Network, defining a static or DHCP configuration for the Load Balancer on the network. :param lb_id: Load Balancer ID. :param private_network_id: Private Network ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param static_config: Object containing an array of a local IP address for the Load Balancer on this Private Network. One-Of (‘config’): at most one of ‘static_config’, ‘dhcp_config’, ‘ipam_config’ could be set. :param dhcp_config: Defines whether to let DHCP assign IP addresses. One-Of (‘config’): at most one of ‘static_config’, ‘dhcp_config’, ‘ipam_config’ could be set. :param ipam_config: For internal use only. One-Of (‘config’): at most one of ‘static_config’, ‘dhcp_config’, ‘ipam_config’ could be set. :param ipam_ids: IPAM ID of a pre-reserved IP address to assign to the Load Balancer on this Private Network. In the future, it will be possible to specify multiple IPs in this field (IPv4 and IPv6), for now only one ID of an IPv4 address is expected. When null, a new private IP address is created for the Load Balancer on this Private Network. :return: PrivateNetwork

Usage:

result = api.attach_private_network(
    lb_id="example",
    private_network_id="example",
)
create_acl(*, frontend_id: str, action: AclAction, index: int, description: str, zone: str | None = None, name: str | None = None, match: AclMatch | None = None) Acl

Create an ACL for a given frontend. Create a new ACL for a given frontend. Each ACL must have a name, an action to perform (allow or deny), and a match rule (the action is carried out when the incoming traffic matches the rule). :param frontend_id: Frontend ID to attach the ACL to. :param action: Action to take when incoming traffic matches an ACL filter. :param index: Priority of this ACL (ACLs are applied in ascending order, 0 is the first ACL executed). :param description: ACL description. :param zone: Zone to target. If none is passed will use default zone from the config. :param name: ACL name. :param match: ACL match filter object. One of ip_subnet, ips_edge_services or http_filter & http_filter_value are required. :return: Acl

Usage:

result = api.create_acl(
    frontend_id="example",
    action=AclAction(),
    index=1,
    description="example",
)
create_backend(*, forward_protocol: Protocol, forward_port: int, forward_port_algorithm: ForwardPortAlgorithm, sticky_sessions: StickySessionsType, sticky_sessions_cookie_name: str, lb_id: str, health_check: HealthCheck, server_ip: List[str], zone: str | None = None, name: str | None = None, send_proxy_v2: bool | None = None, timeout_server: str | None = None, timeout_connect: str | None = None, timeout_tunnel: str | None = None, on_marked_down_action: OnMarkedDownAction | None = None, proxy_protocol: ProxyProtocol | None = None, failover_host: str | None = None, ssl_bridging: bool | None = None, ignore_ssl_server_verify: bool | None = None, redispatch_attempt_count: int | None = None, max_retries: int | None = None, max_connections: int | None = None, timeout_queue: str | None = None) Backend

Create a backend for a given Load Balancer. Create a new backend for a given Load Balancer, specifying its full configuration including protocol, port and forwarding algorithm. :param forward_protocol: Protocol to be used by the backend when forwarding traffic to backend servers. :param forward_port: Port to be used by the backend when forwarding traffic to backend servers. :param forward_port_algorithm: Load balancing algorithm to be used when determining which backend server to forward new traffic to. :param sticky_sessions: Defines whether to activate sticky sessions (binding a particular session to a particular backend server) and the method to use if so. None disables sticky sessions. Cookie-based uses an HTTP cookie TO stick a session to a backend server. Table-based uses the source (client) IP address to stick a session to a backend server. :param sticky_sessions_cookie_name: Cookie name for cookie-based sticky sessions. :param lb_id: Load Balancer ID. :param health_check: Object defining the health check to be carried out by the backend when checking the status and health of backend servers. :param server_ip: List of backend server IP addresses (IPv4 or IPv6) the backend should forward traffic to. :param zone: Zone to target. If none is passed will use default zone from the config. :param name: Name for the backend. :param send_proxy_v2: Deprecated in favor of proxy_protocol field. :param timeout_server: Maximum allowed time for a backend server to process a request. :param timeout_connect: Maximum allowed time for establishing a connection to a backend server. :param timeout_tunnel: Maximum allowed tunnel inactivity time after Websocket is established (takes precedence over client and server timeout). :param on_marked_down_action: Action to take when a backend server is marked as down. :param proxy_protocol: Protocol to use between the Load Balancer and backend servers. Allows the backend servers to be informed of the client’s real IP address. The PROXY protocol must be supported by the backend servers’ software. :param failover_host: Scaleway Object Storage bucket website to be served as failover if all backend servers are down, e.g. failover-website.s3-website.fr-par.scw.cloud. :param ssl_bridging: Defines whether to enable SSL bridging between the Load Balancer and backend servers. :param ignore_ssl_server_verify: Defines whether the server certificate verification should be ignored. :param redispatch_attempt_count: Whether to use another backend server on each attempt. :param max_retries: Number of retries when a backend server connection failed. :param max_connections: Maximum number of connections allowed per backend server. :param timeout_queue: Maximum time for a request to be left pending in queue when max_connections is reached. :return: Backend

Usage:

result = api.create_backend(
    forward_protocol=Protocol.tcp,
    forward_port=1,
    forward_port_algorithm=ForwardPortAlgorithm.roundrobin,
    sticky_sessions=StickySessionsType.none,
    sticky_sessions_cookie_name="example",
    lb_id="example",
    health_check=HealthCheck(),
    server_ip=[],
)
create_certificate(*, lb_id: str, zone: str | None = None, name: str | None = None, letsencrypt: CreateCertificateRequestLetsencryptConfig | None = None, custom_certificate: CreateCertificateRequestCustomCertificate | None = None) Certificate

Create an SSL/TLS certificate. Generate a new SSL/TLS certificate for a given Load Balancer. You can choose to create a Let’s Encrypt certificate, or import a custom certificate. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param name: Name for the certificate. :param letsencrypt: Object to define a new Let’s Encrypt certificate to be generated. One-Of (‘type’): at most one of ‘letsencrypt’, ‘custom_certificate’ could be set. :param custom_certificate: Object to define an existing custom certificate to be imported. One-Of (‘type’): at most one of ‘letsencrypt’, ‘custom_certificate’ could be set. :return: Certificate

Usage:

result = api.create_certificate(
    lb_id="example",
)
create_frontend(*, inbound_port: int, lb_id: str, backend_id: str, enable_http3: bool, enable_access_logs: bool, zone: str | None = None, name: str | None = None, timeout_client: str | None = None, certificate_id: str | None = None, certificate_ids: List[str] | None = None, connection_rate_limit: int | None = None) Frontend

Create a frontend in a given Load Balancer. Create a new frontend for a given Load Balancer, specifying its configuration including the port it should listen on and the backend to attach it to. :param inbound_port: Port the frontend should listen on. :param lb_id: Load Balancer ID (ID of the Load Balancer to attach the frontend to). :param backend_id: Backend ID (ID of the backend the frontend should pass traffic to). :param enable_http3: Defines whether to enable HTTP/3 protocol on the frontend. :param enable_access_logs: Defines whether to enable access logs on the frontend. :param zone: Zone to target. If none is passed will use default zone from the config. :param name: Name for the frontend. :param timeout_client: Maximum allowed inactivity time on the client side. :param certificate_id: Certificate ID, deprecated in favor of certificate_ids array. :param certificate_ids: List of SSL/TLS certificate IDs to bind to the frontend. :param connection_rate_limit: Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. :return: Frontend

Usage:

result = api.create_frontend(
    inbound_port=1,
    lb_id="example",
    backend_id="example",
    enable_http3=False,
    enable_access_logs=False,
)
create_ip(*, is_ipv6: bool, zone: str | None = None, organization_id: str | None = None, project_id: str | None = None, reverse: str | None = None, tags: List[str] | None = None) Ip

Create an IP address. Create a new Load Balancer flexible IP address, in the specified Scaleway Project. This can be attached to new Load Balancers created in the future. :param is_ipv6: If true, creates a Flexible IP with an ipv6 address. :param zone: Zone to target. If none is passed will use default zone from the config. :param organization_id: Organization ID of the Organization where the IP address should be created. One-Of (‘project_identifier’): at most one of ‘project_id’, ‘organization_id’ could be set. :param project_id: Project ID of the Project where the IP address should be created. One-Of (‘project_identifier’): at most one of ‘project_id’, ‘organization_id’ could be set. :param reverse: Reverse DNS (domain name) for the IP address. :param tags: List of tags for the IP. :return: Ip

Usage:

result = api.create_ip(
    is_ipv6=False,
)
create_lb(*, description: str, type_: str, zone: str | None = None, organization_id: str | None = None, project_id: str | None = None, name: str | None = None, ip_id: str | None = None, assign_flexible_ip: bool | None = None, assign_flexible_ipv6: bool | None = None, ip_ids: List[str] | None = None, tags: List[str] | None = None, ssl_compatibility_level: SSLCompatibilityLevel | None = None) Lb

Create a Load Balancer. Create a new Load Balancer. Note that the Load Balancer will be created without frontends or backends; these must be created separately via the dedicated endpoints. :param description: Description for the Load Balancer. :param type_: Load Balancer commercial offer type. Use the Load Balancer types endpoint to retrieve a list of available offer types. :param zone: Zone to target. If none is passed will use default zone from the config. :param organization_id: Scaleway Organization to create the Load Balancer in. One-Of (‘project_identifier’): at most one of ‘project_id’, ‘organization_id’ could be set. :param project_id: Scaleway Project to create the Load Balancer in. One-Of (‘project_identifier’): at most one of ‘project_id’, ‘organization_id’ could be set. :param name: Name for the Load Balancer. :param ip_id: ID of an existing flexible IP address to attach to the Load Balancer. :param assign_flexible_ip: Defines whether to automatically assign a flexible public IP to the Load Balancer. Default value is true (assign). :param assign_flexible_ipv6: Defines whether to automatically assign a flexible public IPv6 to the Load Balancer. Default value is false (do not assign). :param ip_ids: List of IP IDs to attach to the Load Balancer. :param tags: List of tags for the Load Balancer. :param ssl_compatibility_level: Determines the minimal SSL version which needs to be supported on the client side, in an SSL/TLS offloading context. Intermediate is suitable for general-purpose servers with a variety of clients, recommended for almost all systems. Modern is suitable for services with clients that support TLS 1.3 and do not need backward compatibility. Old is compatible with a small number of very old clients and should be used only as a last resort. :return: Lb

Usage:

result = api.create_lb(
    description="example",
    type="example",
)
create_route(*, frontend_id: str, backend_id: str, zone: str | None = None, match: RouteMatch | None = None) Route

Create a route. Create a new route on a given frontend. To configure a route, specify the backend to direct to if a certain condition is matched (based on the value of the SNI field or HTTP Host header). :param frontend_id: ID of the source frontend to create the route on. :param backend_id: ID of the target backend for the route. :param zone: Zone to target. If none is passed will use default zone from the config. :param match: Object defining the match condition for a route to be applied. If an incoming client session matches the specified condition (i.e. it has a matching SNI value or HTTP Host header value), it will be passed to the target backend. :return: Route

Usage:

result = api.create_route(
    frontend_id="example",
    backend_id="example",
)
create_subscriber(*, name: str, zone: str | None = None, email_config: SubscriberEmailConfig | None = None, webhook_config: SubscriberWebhookConfig | None = None, organization_id: str | None = None, project_id: str | None = None) Subscriber

Create a subscriber. Create a new subscriber, either with an email configuration or a webhook configuration, for a specified Scaleway Project. :param name: Subscriber name. :param zone: Zone to target. If none is passed will use default zone from the config. :param email_config: Email address configuration. One-Of (‘config’): at most one of ‘email_config’, ‘webhook_config’ could be set. :param webhook_config: WebHook URI configuration. One-Of (‘config’): at most one of ‘email_config’, ‘webhook_config’ could be set. :param organization_id: Organization ID to create the subscriber in. One-Of (‘project_identifier’): at most one of ‘project_id’, ‘organization_id’ could be set. :param project_id: Project ID to create the subscriber in. One-Of (‘project_identifier’): at most one of ‘project_id’, ‘organization_id’ could be set. :return: Subscriber

Usage:

result = api.create_subscriber(
    name="example",
)
delete_acl(*, acl_id: str, zone: str | None = None) None

Delete an ACL. Delete an ACL, specified by its ACL ID. Deleting an ACL is irreversible and cannot be undone. :param acl_id: ACL ID. :param zone: Zone to target. If none is passed will use default zone from the config.

Usage:

result = api.delete_acl(
    acl_id="example",
)
delete_backend(*, backend_id: str, zone: str | None = None) None

Delete a backend of a given Load Balancer. Delete a backend of a given Load Balancer, specified by its backend ID. This action is irreversible and cannot be undone. :param backend_id: ID of the backend to delete. :param zone: Zone to target. If none is passed will use default zone from the config.

Usage:

result = api.delete_backend(
    backend_id="example",
)
delete_certificate(*, certificate_id: str, zone: str | None = None) None

Delete an SSL/TLS certificate. Delete an SSL/TLS certificate, specified by its certificate ID. Deleting a certificate is irreversible and cannot be undone. :param certificate_id: Certificate ID. :param zone: Zone to target. If none is passed will use default zone from the config.

Usage:

result = api.delete_certificate(
    certificate_id="example",
)
delete_frontend(*, frontend_id: str, zone: str | None = None) None

Delete a frontend. Delete a given frontend, specified by its frontend ID. This action is irreversible and cannot be undone. :param frontend_id: ID of the frontend to delete. :param zone: Zone to target. If none is passed will use default zone from the config.

Usage:

result = api.delete_frontend(
    frontend_id="example",
)
delete_lb(*, lb_id: str, release_ip: bool, zone: str | None = None) None

Delete a Load Balancer. Delete an existing Load Balancer, specified by its Load Balancer ID. Deleting a Load Balancer is permanent, and cannot be undone. The Load Balancer’s flexible IP address can either be deleted with the Load Balancer, or kept in your account for future use. :param lb_id: ID of the Load Balancer to delete. :param release_ip: Defines whether the Load Balancer’s flexible IP should be deleted. Set to true to release the flexible IP, or false to keep it available in your account for future Load Balancers. :param zone: Zone to target. If none is passed will use default zone from the config.

Usage:

result = api.delete_lb(
    lb_id="example",
    release_ip=False,
)
delete_route(*, route_id: str, zone: str | None = None) None

Delete a route. Delete an existing route, specified by its route ID. Deleting a route is permanent, and cannot be undone. :param route_id: Route ID. :param zone: Zone to target. If none is passed will use default zone from the config.

Usage:

result = api.delete_route(
    route_id="example",
)
delete_subscriber(*, subscriber_id: str, zone: str | None = None) None

Delete a subscriber. Delete an existing subscriber, specified by its subscriber ID. Deleting a subscriber is permanent, and cannot be undone. :param subscriber_id: Subscriber ID. :param zone: Zone to target. If none is passed will use default zone from the config.

Usage:

result = api.delete_subscriber(
    subscriber_id="example",
)
detach_private_network(*, lb_id: str, private_network_id: str, zone: str | None = None) None

Detach Load Balancer from Private Network. Detach a specified Load Balancer from a specified Private Network. :param lb_id: Load balancer ID. :param private_network_id: Set your instance private network id. :param zone: Zone to target. If none is passed will use default zone from the config.

Usage:

result = api.detach_private_network(
    lb_id="example",
    private_network_id="example",
)
get_acl(*, acl_id: str, zone: str | None = None) Acl

Get an ACL. Get information for a particular ACL, specified by its ACL ID. The response returns full details of the ACL, including its name, action, match rule and frontend. :param acl_id: ACL ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Acl

Usage:

result = api.get_acl(
    acl_id="example",
)
get_backend(*, backend_id: str, zone: str | None = None) Backend

Get a backend of a given Load Balancer. Get the full details of a given backend, specified by its backend ID. The response contains the backend’s full configuration parameters including protocol, port and forwarding algorithm. :param backend_id: Backend ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Backend

Usage:

result = api.get_backend(
    backend_id="example",
)
get_certificate(*, certificate_id: str, zone: str | None = None) Certificate

Get an SSL/TLS certificate. Get information for a particular SSL/TLS certificate, specified by its certificate ID. The response returns full details of the certificate, including its type, main domain name, and alternative domain names. :param certificate_id: Certificate ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Certificate

Usage:

result = api.get_certificate(
    certificate_id="example",
)
get_frontend(*, frontend_id: str, zone: str | None = None) Frontend

Get a frontend. Get the full details of a given frontend, specified by its frontend ID. The response contains the frontend’s full configuration parameters including the backend it is attached to, the port it listens on, and any certificates it has. :param frontend_id: Frontend ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Frontend

Usage:

result = api.get_frontend(
    frontend_id="example",
)
get_ip(*, ip_id: str, zone: str | None = None) Ip

Get an IP address. Retrieve the full details of a Load Balancer flexible IP address. :param ip_id: IP address ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Ip

Usage:

result = api.get_ip(
    ip_id="example",
)
get_lb(*, lb_id: str, zone: str | None = None) Lb

Get a Load Balancer. Retrieve information about an existing Load Balancer, specified by its Load Balancer ID. Its full details, including name, status and IP address, are returned in the response object. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Lb

Usage:

result = api.get_lb(
    lb_id="example",
)
get_lb_stats(*, lb_id: str, zone: str | None = None, backend_id: str | None = None) LbStats

Get usage statistics of a given Load Balancer. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param backend_id: ID of the backend. :return: LbStats :deprecated

Usage:

result = api.get_lb_stats(
    lb_id="example",
)
get_route(*, route_id: str, zone: str | None = None) Route

Get a route. Retrieve information about an existing route, specified by its route ID. Its full details, origin frontend, target backend and match condition, are returned in the response object. :param route_id: Route ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Route

Usage:

result = api.get_route(
    route_id="example",
)
get_subscriber(*, subscriber_id: str, zone: str | None = None) Subscriber

Get a subscriber. Retrieve information about an existing subscriber, specified by its subscriber ID. Its full details, including name and email/webhook configuration, are returned in the response object. :param subscriber_id: Subscriber ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Subscriber

Usage:

result = api.get_subscriber(
    subscriber_id="example",
)
list_acls(*, frontend_id: str, zone: str | None = None, order_by: ListAclRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None, name: str | None = None) ListAclResponse

List ACLs for a given frontend. List the ACLs for a given frontend, specified by its frontend ID. The response is an array of ACL objects, each one representing an ACL that denies or allows traffic based on certain conditions. :param frontend_id: Frontend ID (ACLs attached to this frontend will be returned in the response). :param zone: Zone to target. If none is passed will use default zone from the config. :param order_by: Sort order of ACLs in the response. :param page: The page number to return, from the paginated results. :param page_size: The number of ACLs to return. :param name: ACL name to filter for. :return: ListAclResponse

Usage:

result = api.list_acls(
    frontend_id="example",
)
list_acls_all(*, frontend_id: str, zone: str | None = None, order_by: ListAclRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None, name: str | None = None) List[Acl]

List ACLs for a given frontend. List the ACLs for a given frontend, specified by its frontend ID. The response is an array of ACL objects, each one representing an ACL that denies or allows traffic based on certain conditions. :param frontend_id: Frontend ID (ACLs attached to this frontend will be returned in the response). :param zone: Zone to target. If none is passed will use default zone from the config. :param order_by: Sort order of ACLs in the response. :param page: The page number to return, from the paginated results. :param page_size: The number of ACLs to return. :param name: ACL name to filter for. :return: List[Acl]

Usage:

result = api.list_acls_all(
    frontend_id="example",
)
list_backend_stats(*, lb_id: str, zone: str | None = None, page: int | None = None, page_size: int | None = None, backend_id: str | None = None) ListBackendStatsResponse

List backend server statistics. List information about your backend servers, including their state and the result of their last health check. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param page: The page number to return, from the paginated results. :param page_size: Number of items to return. :param backend_id: ID of the backend. :return: ListBackendStatsResponse

Usage:

result = api.list_backend_stats(
    lb_id="example",
)
list_backend_stats_all(*, lb_id: str, zone: str | None = None, page: int | None = None, page_size: int | None = None, backend_id: str | None = None) List[BackendServerStats]

List backend server statistics. List information about your backend servers, including their state and the result of their last health check. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param page: The page number to return, from the paginated results. :param page_size: Number of items to return. :param backend_id: ID of the backend. :return: List[BackendServerStats]

Usage:

result = api.list_backend_stats_all(
    lb_id="example",
)
list_backends(*, lb_id: str, zone: str | None = None, name: str | None = None, order_by: ListBackendsRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None) ListBackendsResponse

List the backends of a given Load Balancer. List all the backends of a Load Balancer, specified by its Load Balancer ID. By default, results are returned in ascending order by the creation date of each backend. The response is an array of backend objects, containing full details of each one including their configuration parameters such as protocol, port and forwarding algorithm. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param name: Name of the backend to filter for. :param order_by: Sort order of backends in the response. :param page: The page number to return, from the paginated results. :param page_size: Number of backends to return. :return: ListBackendsResponse

Usage:

result = api.list_backends(
    lb_id="example",
)
list_backends_all(*, lb_id: str, zone: str | None = None, name: str | None = None, order_by: ListBackendsRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None) List[Backend]

List the backends of a given Load Balancer. List all the backends of a Load Balancer, specified by its Load Balancer ID. By default, results are returned in ascending order by the creation date of each backend. The response is an array of backend objects, containing full details of each one including their configuration parameters such as protocol, port and forwarding algorithm. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param name: Name of the backend to filter for. :param order_by: Sort order of backends in the response. :param page: The page number to return, from the paginated results. :param page_size: Number of backends to return. :return: List[Backend]

Usage:

result = api.list_backends_all(
    lb_id="example",
)
list_certificates(*, lb_id: str, zone: str | None = None, order_by: ListCertificatesRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None, name: str | None = None) ListCertificatesResponse

List all SSL/TLS certificates on a given Load Balancer. List all the SSL/TLS certificates on a given Load Balancer. The response is an array of certificate objects, which are by default listed in ascending order of creation date. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param order_by: Sort order of certificates in the response. :param page: The page number to return, from the paginated results. :param page_size: Number of certificates to return. :param name: Certificate name to filter for, only certificates of this name will be returned. :return: ListCertificatesResponse

Usage:

result = api.list_certificates(
    lb_id="example",
)
list_certificates_all(*, lb_id: str, zone: str | None = None, order_by: ListCertificatesRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None, name: str | None = None) List[Certificate]

List all SSL/TLS certificates on a given Load Balancer. List all the SSL/TLS certificates on a given Load Balancer. The response is an array of certificate objects, which are by default listed in ascending order of creation date. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param order_by: Sort order of certificates in the response. :param page: The page number to return, from the paginated results. :param page_size: Number of certificates to return. :param name: Certificate name to filter for, only certificates of this name will be returned. :return: List[Certificate]

Usage:

result = api.list_certificates_all(
    lb_id="example",
)
list_frontends(*, lb_id: str, zone: str | None = None, name: str | None = None, order_by: ListFrontendsRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None) ListFrontendsResponse

List frontends of a given Load Balancer. List all the frontends of a Load Balancer, specified by its Load Balancer ID. By default, results are returned in ascending order by the creation date of each frontend. The response is an array of frontend objects, containing full details of each one including the port they listen on and the backend they are attached to. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param name: Name of the frontend to filter for. :param order_by: Sort order of frontends in the response. :param page: The page number to return, from the paginated results. :param page_size: Number of frontends to return. :return: ListFrontendsResponse

Usage:

result = api.list_frontends(
    lb_id="example",
)
list_frontends_all(*, lb_id: str, zone: str | None = None, name: str | None = None, order_by: ListFrontendsRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None) List[Frontend]

List frontends of a given Load Balancer. List all the frontends of a Load Balancer, specified by its Load Balancer ID. By default, results are returned in ascending order by the creation date of each frontend. The response is an array of frontend objects, containing full details of each one including the port they listen on and the backend they are attached to. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param name: Name of the frontend to filter for. :param order_by: Sort order of frontends in the response. :param page: The page number to return, from the paginated results. :param page_size: Number of frontends to return. :return: List[Frontend]

Usage:

result = api.list_frontends_all(
    lb_id="example",
)
list_i_ps(*, zone: str | None = None, page: int | None = None, page_size: int | None = None, ip_address: str | None = None, organization_id: str | None = None, project_id: str | None = None, ip_type: ListIpsRequestIpType | None = None, tags: List[str] | None = None) ListIpsResponse

List IP addresses. List the Load Balancer flexible IP addresses held in the account (filtered by Organization ID or Project ID). It is also possible to search for a specific IP address. :param zone: Zone to target. If none is passed will use default zone from the config. :param page: The page number to return, from the paginated results. :param page_size: Number of IP addresses to return. :param ip_address: IP address to filter for. :param organization_id: Organization ID to filter for, only Load Balancer IP addresses from this Organization will be returned. :param project_id: Project ID to filter for, only Load Balancer IP addresses from this Project will be returned. :param ip_type: IP type to filter for. :param tags: Tag to filter for, only IPs with one or more matching tags will be returned. :return: ListIpsResponse

Usage:

result = api.list_i_ps()
list_i_ps_all(*, zone: str | None = None, page: int | None = None, page_size: int | None = None, ip_address: str | None = None, organization_id: str | None = None, project_id: str | None = None, ip_type: ListIpsRequestIpType | None = None, tags: List[str] | None = None) List[Ip]

List IP addresses. List the Load Balancer flexible IP addresses held in the account (filtered by Organization ID or Project ID). It is also possible to search for a specific IP address. :param zone: Zone to target. If none is passed will use default zone from the config. :param page: The page number to return, from the paginated results. :param page_size: Number of IP addresses to return. :param ip_address: IP address to filter for. :param organization_id: Organization ID to filter for, only Load Balancer IP addresses from this Organization will be returned. :param project_id: Project ID to filter for, only Load Balancer IP addresses from this Project will be returned. :param ip_type: IP type to filter for. :param tags: Tag to filter for, only IPs with one or more matching tags will be returned. :return: List[Ip]

Usage:

result = api.list_i_ps_all()
list_lb_private_networks(*, lb_id: str, zone: str | None = None, order_by: ListPrivateNetworksRequestOrderBy | None = None, page_size: int | None = None, page: int | None = None) ListLbPrivateNetworksResponse

List Private Networks attached to a Load Balancer. List the Private Networks attached to a given Load Balancer, specified by its Load Balancer ID. The response is an array of Private Network objects, giving information including the status, configuration, name and creation date of each Private Network. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param order_by: Sort order of Private Network objects in the response. :param page_size: Number of objects to return. :param page: The page number to return, from the paginated results. :return: ListLbPrivateNetworksResponse

Usage:

result = api.list_lb_private_networks(
    lb_id="example",
)
list_lb_private_networks_all(*, lb_id: str, zone: str | None = None, order_by: ListPrivateNetworksRequestOrderBy | None = None, page_size: int | None = None, page: int | None = None) List[PrivateNetwork]

List Private Networks attached to a Load Balancer. List the Private Networks attached to a given Load Balancer, specified by its Load Balancer ID. The response is an array of Private Network objects, giving information including the status, configuration, name and creation date of each Private Network. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param order_by: Sort order of Private Network objects in the response. :param page_size: Number of objects to return. :param page: The page number to return, from the paginated results. :return: List[PrivateNetwork]

Usage:

result = api.list_lb_private_networks_all(
    lb_id="example",
)
list_lb_types(*, zone: str | None = None, page: int | None = None, page_size: int | None = None) ListLbTypesResponse

List all Load Balancer offer types. List all the different commercial Load Balancer types. The response includes an array of offer types, each with a name, description, and information about its stock availability. :param zone: Zone to target. If none is passed will use default zone from the config. :param page: The page number to return, from the paginated results. :param page_size: The number of items to return. :return: ListLbTypesResponse

Usage:

result = api.list_lb_types()
list_lb_types_all(*, zone: str | None = None, page: int | None = None, page_size: int | None = None) List[LbType]

List all Load Balancer offer types. List all the different commercial Load Balancer types. The response includes an array of offer types, each with a name, description, and information about its stock availability. :param zone: Zone to target. If none is passed will use default zone from the config. :param page: The page number to return, from the paginated results. :param page_size: The number of items to return. :return: List[LbType]

Usage:

result = api.list_lb_types_all()
list_lbs(*, zone: str | None = None, name: str | None = None, order_by: ListLbsRequestOrderBy | None = None, page_size: int | None = None, page: int | None = None, organization_id: str | None = None, project_id: str | None = None, tags: List[str] | None = None) ListLbsResponse

List Load Balancers. List all Load Balancers in the specified zone, for a Scaleway Organization or Scaleway Project. By default, the Load Balancers returned in the list are ordered by creation date in ascending order, though this can be modified via the order_by field. :param zone: Zone to target. If none is passed will use default zone from the config. :param name: Load Balancer name to filter for. :param order_by: Sort order of Load Balancers in the response. :param page_size: Number of Load Balancers to return. :param page: Page number to return, from the paginated results. :param organization_id: Organization ID to filter for, only Load Balancers from this Organization will be returned. :param project_id: Project ID to filter for, only Load Balancers from this Project will be returned. :param tags: Filter by tag, only Load Balancers with one or more matching tags will be returned. :return: ListLbsResponse

Usage:

result = api.list_lbs()
list_lbs_all(*, zone: str | None = None, name: str | None = None, order_by: ListLbsRequestOrderBy | None = None, page_size: int | None = None, page: int | None = None, organization_id: str | None = None, project_id: str | None = None, tags: List[str] | None = None) List[Lb]

List Load Balancers. List all Load Balancers in the specified zone, for a Scaleway Organization or Scaleway Project. By default, the Load Balancers returned in the list are ordered by creation date in ascending order, though this can be modified via the order_by field. :param zone: Zone to target. If none is passed will use default zone from the config. :param name: Load Balancer name to filter for. :param order_by: Sort order of Load Balancers in the response. :param page_size: Number of Load Balancers to return. :param page: Page number to return, from the paginated results. :param organization_id: Organization ID to filter for, only Load Balancers from this Organization will be returned. :param project_id: Project ID to filter for, only Load Balancers from this Project will be returned. :param tags: Filter by tag, only Load Balancers with one or more matching tags will be returned. :return: List[Lb]

Usage:

result = api.list_lbs_all()
list_routes(*, zone: str | None = None, order_by: ListRoutesRequestOrderBy | None = None, page_size: int | None = None, page: int | None = None, frontend_id: str | None = None) ListRoutesResponse

List all routes. List all routes for a given frontend. The response is an array of routes, each one with a specified backend to direct to if a certain condition is matched (based on the value of the SNI field or HTTP Host header). :param zone: Zone to target. If none is passed will use default zone from the config. :param order_by: Sort order of routes in the response. :param page_size: The number of route objects to return. :param page: The page number to return, from the paginated results. :param frontend_id: Frontend ID to filter for, only Routes from this Frontend will be returned. :return: ListRoutesResponse

Usage:

result = api.list_routes()
list_routes_all(*, zone: str | None = None, order_by: ListRoutesRequestOrderBy | None = None, page_size: int | None = None, page: int | None = None, frontend_id: str | None = None) List[Route]

List all routes. List all routes for a given frontend. The response is an array of routes, each one with a specified backend to direct to if a certain condition is matched (based on the value of the SNI field or HTTP Host header). :param zone: Zone to target. If none is passed will use default zone from the config. :param order_by: Sort order of routes in the response. :param page_size: The number of route objects to return. :param page: The page number to return, from the paginated results. :param frontend_id: Frontend ID to filter for, only Routes from this Frontend will be returned. :return: List[Route]

Usage:

result = api.list_routes_all()
list_subscriber(*, zone: str | None = None, order_by: ListSubscriberRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None, name: str | None = None, organization_id: str | None = None, project_id: str | None = None) ListSubscriberResponse

List all subscribers. List all subscribers to Load Balancer alerts. By default, returns all subscribers to Load Balancer alerts for the Organization associated with the authentication token used for the request. :param zone: Zone to target. If none is passed will use default zone from the config. :param order_by: Sort order of subscribers in the response. :param page: The page number to return, from the paginated results. :param page_size: The number of items to return. :param name: Subscriber name to search for. :param organization_id: Filter subscribers by Organization ID. :param project_id: Filter subscribers by Project ID. :return: ListSubscriberResponse

Usage:

result = api.list_subscriber()
list_subscriber_all(*, zone: str | None = None, order_by: ListSubscriberRequestOrderBy | None = None, page: int | None = None, page_size: int | None = None, name: str | None = None, organization_id: str | None = None, project_id: str | None = None) List[Subscriber]

List all subscribers. List all subscribers to Load Balancer alerts. By default, returns all subscribers to Load Balancer alerts for the Organization associated with the authentication token used for the request. :param zone: Zone to target. If none is passed will use default zone from the config. :param order_by: Sort order of subscribers in the response. :param page: The page number to return, from the paginated results. :param page_size: The number of items to return. :param name: Subscriber name to search for. :param organization_id: Filter subscribers by Organization ID. :param project_id: Filter subscribers by Project ID. :return: List[Subscriber]

Usage:

result = api.list_subscriber_all()
migrate_lb(*, lb_id: str, type_: str, zone: str | None = None) Lb

Migrate a Load Balancer. Migrate an existing Load Balancer from one commercial type to another. Allows you to scale your Load Balancer up or down in terms of bandwidth or multi-cloud provision. :param lb_id: Load Balancer ID. :param type_: Load Balancer type to migrate to (use the List all Load Balancer offer types endpoint to get a list of available offer types). :param zone: Zone to target. If none is passed will use default zone from the config. :return: Lb

Usage:

result = api.migrate_lb(
    lb_id="example",
    type="example",
)
release_ip(*, ip_id: str, zone: str | None = None) None

Delete an IP address. Delete a Load Balancer flexible IP address. This action is irreversible, and cannot be undone. :param ip_id: IP address ID. :param zone: Zone to target. If none is passed will use default zone from the config.

Usage:

result = api.release_ip(
    ip_id="example",
)
remove_backend_servers(*, backend_id: str, server_ip: List[str], zone: str | None = None) Backend

Remove a set of servers for a given backend. For a given backend specified by its backend ID, remove the specified backend servers (identified by their IP addresses) so that it no longer forwards traffic to them. :param backend_id: Backend ID. :param server_ip: List of IP addresses to remove from backend servers. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Backend

Usage:

result = api.remove_backend_servers(
    backend_id="example",
    server_ip=[],
)
set_acls(*, acls: List[AclSpec], frontend_id: str, zone: str | None = None) SetAclsResponse

Define all ACLs for a given frontend. For a given frontend specified by its frontend ID, define and add the complete set of ACLS for that frontend. Any existing ACLs on this frontend will be removed. :param acls: List of ACLs for this frontend. Any other existing ACLs on this frontend will be removed. :param frontend_id: Frontend ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: SetAclsResponse

Usage:

result = api.set_acls(
    acls=[],
    frontend_id="example",
)
set_backend_servers(*, backend_id: str, server_ip: List[str], zone: str | None = None) Backend

Define all backend servers for a given backend. For a given backend specified by its backend ID, define the set of backend servers (identified by their IP addresses) that it should forward traffic to. Any existing backend servers configured for this backend will be removed. :param backend_id: Backend ID. :param server_ip: List of IP addresses for backend servers. Any other existing backend servers will be removed. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Backend

Usage:

result = api.set_backend_servers(
    backend_id="example",
    server_ip=[],
)
subscribe_to_lb(*, lb_id: str, subscriber_id: str, zone: str | None = None) Lb

Subscribe a subscriber to alerts for a given Load Balancer. Subscribe an existing subscriber to alerts for a given Load Balancer. :param lb_id: Load Balancer ID. :param subscriber_id: Subscriber ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Lb

Usage:

result = api.subscribe_to_lb(
    lb_id="example",
    subscriber_id="example",
)
unsubscribe_from_lb(*, lb_id: str, zone: str | None = None) Lb

Unsubscribe a subscriber from alerts for a given Load Balancer. Unsubscribe a subscriber from alerts for a given Load Balancer. The subscriber is not deleted, and can be resubscribed in the future if necessary. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Lb

Usage:

result = api.unsubscribe_from_lb(
    lb_id="example",
)
update_acl(*, acl_id: str, name: str, action: AclAction, index: int, zone: str | None = None, match: AclMatch | None = None, description: str | None = None) Acl

Update an ACL. Update a particular ACL, specified by its ACL ID. You can update details including its name, action and match rule. :param acl_id: ACL ID. :param name: ACL name. :param action: Action to take when incoming traffic matches an ACL filter. :param index: Priority of this ACL (ACLs are applied in ascending order, 0 is the first ACL executed). :param zone: Zone to target. If none is passed will use default zone from the config. :param match: ACL match filter object. One of ip_subnet, ips_edge_services or http_filter & http_filter_value are required. :param description: ACL description. :return: Acl

Usage:

result = api.update_acl(
    acl_id="example",
    name="example",
    action=AclAction(),
    index=1,
)
update_backend(*, backend_id: str, name: str, forward_protocol: Protocol, forward_port: int, forward_port_algorithm: ForwardPortAlgorithm, sticky_sessions: StickySessionsType, sticky_sessions_cookie_name: str, zone: str | None = None, send_proxy_v2: bool | None = None, timeout_server: str | None = None, timeout_connect: str | None = None, timeout_tunnel: str | None = None, on_marked_down_action: OnMarkedDownAction | None = None, proxy_protocol: ProxyProtocol | None = None, failover_host: str | None = None, ssl_bridging: bool | None = None, ignore_ssl_server_verify: bool | None = None, redispatch_attempt_count: int | None = None, max_retries: int | None = None, max_connections: int | None = None, timeout_queue: str | None = None) Backend

Update a backend of a given Load Balancer. Update a backend of a given Load Balancer, specified by its backend ID. Note that the request type is PUT and not PATCH. You must set all parameters. :param backend_id: Backend ID. :param name: Backend name. :param forward_protocol: Protocol to be used by the backend when forwarding traffic to backend servers. :param forward_port: Port to be used by the backend when forwarding traffic to backend servers. :param forward_port_algorithm: Load balancing algorithm to be used when determining which backend server to forward new traffic to. :param sticky_sessions: Defines whether to activate sticky sessions (binding a particular session to a particular backend server) and the method to use if so. None disables sticky sessions. Cookie-based uses an HTTP cookie to stick a session to a backend server. Table-based uses the source (client) IP address to stick a session to a backend server. :param sticky_sessions_cookie_name: Cookie name for cookie-based sticky sessions. :param zone: Zone to target. If none is passed will use default zone from the config. :param send_proxy_v2: Deprecated in favor of proxy_protocol field. :param timeout_server: Maximum allowed time for a backend server to process a request. :param timeout_connect: Maximum allowed time for establishing a connection to a backend server. :param timeout_tunnel: Maximum allowed tunnel inactivity time after Websocket is established (takes precedence over client and server timeout). :param on_marked_down_action: Action to take when a backend server is marked as down. :param proxy_protocol: Protocol to use between the Load Balancer and backend servers. Allows the backend servers to be informed of the client’s real IP address. The PROXY protocol must be supported by the backend servers’ software. :param failover_host: Scaleway Object Storage bucket website to be served as failover if all backend servers are down, e.g. failover-website.s3-website.fr-par.scw.cloud. :param ssl_bridging: Defines whether to enable SSL bridging between the Load Balancer and backend servers. :param ignore_ssl_server_verify: Defines whether the server certificate verification should be ignored. :param redispatch_attempt_count: Whether to use another backend server on each attempt. :param max_retries: Number of retries when a backend server connection failed. :param max_connections: Maximum number of connections allowed per backend server. :param timeout_queue: Maximum time for a request to be left pending in queue when max_connections is reached. :return: Backend

Usage:

result = api.update_backend(
    backend_id="example",
    name="example",
    forward_protocol=Protocol.tcp,
    forward_port=1,
    forward_port_algorithm=ForwardPortAlgorithm.roundrobin,
    sticky_sessions=StickySessionsType.none,
    sticky_sessions_cookie_name="example",
)
update_certificate(*, certificate_id: str, name: str, zone: str | None = None) Certificate

Update an SSL/TLS certificate. Update the name of a particular SSL/TLS certificate, specified by its certificate ID. :param certificate_id: Certificate ID. :param name: Certificate name. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Certificate

Usage:

result = api.update_certificate(
    certificate_id="example",
    name="example",
)
update_frontend(*, frontend_id: str, name: str, inbound_port: int, backend_id: str, enable_http3: bool, zone: str | None = None, timeout_client: str | None = None, certificate_id: str | None = None, certificate_ids: List[str] | None = None, connection_rate_limit: int | None = None, enable_access_logs: bool | None = None) Frontend

Update a frontend. Update a given frontend, specified by its frontend ID. You can update configuration parameters including its name and the port it listens on. Note that the request type is PUT and not PATCH. You must set all parameters. :param frontend_id: Frontend ID. :param name: Frontend name. :param inbound_port: Port the frontend should listen on. :param backend_id: Backend ID (ID of the backend the frontend should pass traffic to). :param enable_http3: Defines whether to enable HTTP/3 protocol on the frontend. :param zone: Zone to target. If none is passed will use default zone from the config. :param timeout_client: Maximum allowed inactivity time on the client side. :param certificate_id: Certificate ID, deprecated in favor of certificate_ids array. :param certificate_ids: List of SSL/TLS certificate IDs to bind to the frontend. :param connection_rate_limit: Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. :param enable_access_logs: Defines whether to enable access logs on the frontend. :return: Frontend

Usage:

result = api.update_frontend(
    frontend_id="example",
    name="example",
    inbound_port=1,
    backend_id="example",
    enable_http3=False,
)
update_health_check(*, port: int, check_max_retries: int, backend_id: str, zone: str | None = None, check_delay: str | None = None, check_timeout: str | None = None, check_send_proxy: bool, tcp_config: HealthCheckTcpConfig | None = None, mysql_config: HealthCheckMysqlConfig | None = None, pgsql_config: HealthCheckPgsqlConfig | None = None, ldap_config: HealthCheckLdapConfig | None = None, redis_config: HealthCheckRedisConfig | None = None, http_config: HealthCheckHttpConfig | None = None, https_config: HealthCheckHttpsConfig | None = None, transient_check_delay: str | None = None) HealthCheck

Update a health check for a given backend. Update the configuration of the health check performed by a given backend to verify the health of its backend servers, identified by its backend ID. Note that the request type is PUT and not PATCH. You must set all parameters. :param port: Port to use for the backend server health check. :param check_max_retries: Number of consecutive unsuccessful health checks after which the server will be considered dead. :param backend_id: Backend ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param check_delay: Time to wait between two consecutive health checks. :param check_timeout: Maximum time a backend server has to reply to the health check. :param check_send_proxy: Defines whether proxy protocol should be activated for the health check. :param tcp_config: Object to configure a basic TCP health check. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param mysql_config: Object to configure a MySQL health check. The check requires MySQL >=3.22 or <9.0. For older or newer versions, use a TCP health check. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param pgsql_config: Object to configure a PostgreSQL health check. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param ldap_config: Object to configure an LDAP health check. The response is analyzed to find the LDAPv3 response message. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param redis_config: Object to configure a Redis health check. The response is analyzed to find the +PONG response message. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param http_config: Object to configure an HTTP health check. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param https_config: Object to configure an HTTPS health check. One-Of (‘config’): at most one of ‘tcp_config’, ‘mysql_config’, ‘pgsql_config’, ‘ldap_config’, ‘redis_config’, ‘http_config’, ‘https_config’ could be set. :param transient_check_delay: Time to wait between two consecutive health checks when a backend server is in a transient state (going UP or DOWN). :return: HealthCheck

Usage:

result = api.update_health_check(
    port=1,
    check_max_retries=1,
    backend_id="example",
    check_send_proxy=False,
)
update_ip(*, ip_id: str, zone: str | None = None, reverse: str | None = None, lb_id: str | None = None, tags: List[str] | None = None) Ip

Update an IP address. Update the reverse DNS of a Load Balancer flexible IP address. :param ip_id: IP address ID. :param zone: Zone to target. If none is passed will use default zone from the config. :param reverse: Reverse DNS (domain name) for the IP address. :param lb_id: ID of the server on which to attach the flexible IP. :param tags: List of tags for the IP. :return: Ip

Usage:

result = api.update_ip(
    ip_id="example",
)
update_lb(*, lb_id: str, name: str, description: str, zone: str | None = None, tags: List[str] | None = None, ssl_compatibility_level: SSLCompatibilityLevel | None = None) Lb

Update a Load Balancer. Update the parameters of an existing Load Balancer, specified by its Load Balancer ID. Note that the request type is PUT and not PATCH. You must set all parameters. :param lb_id: Load Balancer ID. :param name: Load Balancer name. :param description: Load Balancer description. :param zone: Zone to target. If none is passed will use default zone from the config. :param tags: List of tags for the Load Balancer. :param ssl_compatibility_level: Determines the minimal SSL version which needs to be supported on the client side, in an SSL/TLS offloading context. Intermediate is suitable for general-purpose servers with a variety of clients, recommended for almost all systems. Modern is suitable for services with clients that support TLS 1.3 and don’t need backward compatibility. Old is compatible with a small number of very old clients and should be used only as a last resort. :return: Lb

Usage:

result = api.update_lb(
    lb_id="example",
    name="example",
    description="example",
)
update_route(*, route_id: str, backend_id: str, zone: str | None = None, match: RouteMatch | None = None) Route

Update a route. Update the configuration of an existing route, specified by its route ID. :param route_id: Route ID. :param backend_id: ID of the target backend for the route. :param zone: Zone to target. If none is passed will use default zone from the config. :param match: Object defining the match condition for a route to be applied. If an incoming client session matches the specified condition (i.e. it has a matching SNI value or HTTP Host header value), it will be passed to the target backend. :return: Route

Usage:

result = api.update_route(
    route_id="example",
    backend_id="example",
)
update_subscriber(*, subscriber_id: str, name: str, zone: str | None = None, email_config: SubscriberEmailConfig | None = None, webhook_config: SubscriberWebhookConfig | None = None) Subscriber

Update a subscriber. Update the parameters of a given subscriber (e.g. name, webhook configuration, email configuration), specified by its subscriber ID. :param subscriber_id: Subscriber ID. :param name: Subscriber name. :param zone: Zone to target. If none is passed will use default zone from the config. :param email_config: Email address configuration. One-Of (‘config’): at most one of ‘email_config’, ‘webhook_config’ could be set. :param webhook_config: Webhook URI configuration. One-Of (‘config’): at most one of ‘email_config’, ‘webhook_config’ could be set. :return: Subscriber

Usage:

result = api.update_subscriber(
    subscriber_id="example",
    name="example",
)
wait_for_certificate(*, certificate_id: str, zone: str | None = None, options: WaitForOptions[Certificate, bool] | None = None) Certificate

Get an SSL/TLS certificate. Get information for a particular SSL/TLS certificate, specified by its certificate ID. The response returns full details of the certificate, including its type, main domain name, and alternative domain names. :param certificate_id: Certificate ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Certificate

Usage:

result = api.get_certificate(
    certificate_id="example",
)
wait_for_lb(*, lb_id: str, zone: str | None = None, options: WaitForOptions[Lb, bool] | None = None) Lb

Get a Load Balancer. Retrieve information about an existing Load Balancer, specified by its Load Balancer ID. Its full details, including name, status and IP address, are returned in the response object. :param lb_id: Load Balancer ID. :param zone: Zone to target. If none is passed will use default zone from the config. :return: Lb

Usage:

result = api.get_lb(
    lb_id="example",
)
class scaleway.lb.v1.ListAclRequestOrderBy(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

CREATED_AT_ASC = 'created_at_asc'
CREATED_AT_DESC = 'created_at_desc'
NAME_ASC = 'name_asc'
NAME_DESC = 'name_desc'
class scaleway.lb.v1.ListAclResponse(acls: 'List[Acl]', total_count: 'int')

Bases: object

acls: List[Acl]

List of ACL objects.

total_count: int

The total number of objects.

class scaleway.lb.v1.ListAclsRequest(frontend_id: 'str', region: 'Optional[ScwRegion]' = None, order_by: 'Optional[ListAclRequestOrderBy]' = <ListAclRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0, name: 'Optional[str]' = None)

Bases: object

frontend_id: str

Frontend ID (ACLs attached to this frontend will be returned in the response).

name: str | None = None

ACL name to filter for.

order_by: ListAclRequestOrderBy | None = 'created_at_asc'

Sort order of ACLs in the response.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

The number of ACLs to return.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.ListBackendStatsRequest(lb_id: 'str', region: 'Optional[ScwRegion]' = None, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0, backend_id: 'Optional[str]' = None)

Bases: object

backend_id: str | None = None

ID of the backend.

lb_id: str

Load Balancer ID.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

Number of items to return.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.ListBackendStatsResponse(backend_servers_stats: 'List[BackendServerStats]', total_count: 'int')

Bases: object

backend_servers_stats: List[BackendServerStats]

List of objects containing backend server statistics.

total_count: int

The total number of objects.

class scaleway.lb.v1.ListBackendsRequest(lb_id: 'str', region: 'Optional[ScwRegion]' = None, name: 'Optional[str]' = None, order_by: 'Optional[ListBackendsRequestOrderBy]' = <ListBackendsRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0)

Bases: object

lb_id: str

Load Balancer ID.

name: str | None = None

Name of the backend to filter for.

order_by: ListBackendsRequestOrderBy | None = 'created_at_asc'

Sort order of backends in the response.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

Number of backends to return.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.ListBackendsRequestOrderBy(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

CREATED_AT_ASC = 'created_at_asc'
CREATED_AT_DESC = 'created_at_desc'
NAME_ASC = 'name_asc'
NAME_DESC = 'name_desc'
class scaleway.lb.v1.ListBackendsResponse(backends: 'List[Backend]', total_count: 'int')

Bases: object

backends: List[Backend]

List of backend objects of a given Load Balancer.

total_count: int

Total count of backend objects, without pagination.

class scaleway.lb.v1.ListCertificatesRequest(lb_id: 'str', region: 'Optional[ScwRegion]' = None, order_by: 'Optional[ListCertificatesRequestOrderBy]' = <ListCertificatesRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0, name: 'Optional[str]' = None)

Bases: object

lb_id: str

Load Balancer ID.

name: str | None = None

Certificate name to filter for, only certificates of this name will be returned.

order_by: ListCertificatesRequestOrderBy | None = 'created_at_asc'

Sort order of certificates in the response.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

Number of certificates to return.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.ListCertificatesRequestOrderBy(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

CREATED_AT_ASC = 'created_at_asc'
CREATED_AT_DESC = 'created_at_desc'
NAME_ASC = 'name_asc'
NAME_DESC = 'name_desc'
class scaleway.lb.v1.ListCertificatesResponse(certificates: 'List[Certificate]', total_count: 'int')

Bases: object

certificates: List[Certificate]

List of certificate objects.

total_count: int

The total number of objects.

class scaleway.lb.v1.ListFrontendsRequest(lb_id: 'str', region: 'Optional[ScwRegion]' = None, name: 'Optional[str]' = None, order_by: 'Optional[ListFrontendsRequestOrderBy]' = <ListFrontendsRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0)

Bases: object

lb_id: str

Load Balancer ID.

name: str | None = None

Name of the frontend to filter for.

order_by: ListFrontendsRequestOrderBy | None = 'created_at_asc'

Sort order of frontends in the response.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

Number of frontends to return.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.ListFrontendsRequestOrderBy(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

CREATED_AT_ASC = 'created_at_asc'
CREATED_AT_DESC = 'created_at_desc'
NAME_ASC = 'name_asc'
NAME_DESC = 'name_desc'
class scaleway.lb.v1.ListFrontendsResponse(frontends: 'List[Frontend]', total_count: 'int')

Bases: object

frontends: List[Frontend]

List of frontend objects of a given Load Balancer.

total_count: int

Total count of frontend objects, without pagination.

class scaleway.lb.v1.ListIPsRequest(region: 'Optional[ScwRegion]' = None, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0, ip_address: 'Optional[str]' = None, organization_id: 'Optional[str]' = None, project_id: 'Optional[str]' = None, ip_type: 'Optional[ListIpsRequestIpType]' = <ListIpsRequestIpType.ALL: 'all'>, tags: 'Optional[List[str]]' = <factory>)

Bases: object

ip_address: str | None = None

IP address to filter for.

ip_type: ListIpsRequestIpType | None = 'all'

IP type to filter for.

organization_id: str | None = None

Organization ID to filter for, only Load Balancer IP addresses from this Organization will be returned.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

Number of IP addresses to return.

project_id: str | None = None

Project ID to filter for, only Load Balancer IP addresses from this Project will be returned.

region: str | None = None

Region to target. If none is passed will use default region from the config.

tags: List[str] | None

Tag to filter for, only IPs with one or more matching tags will be returned.

class scaleway.lb.v1.ListIpsRequestIpType(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

ALL = 'all'
IPV4 = 'ipv4'
IPV6 = 'ipv6'
class scaleway.lb.v1.ListIpsResponse(ips: 'List[Ip]', total_count: 'int')

Bases: object

ips: List[Ip]

List of IP address objects.

total_count: int

Total count of IP address objects, without pagination.

class scaleway.lb.v1.ListLbPrivateNetworksRequest(lb_id: 'str', region: 'Optional[ScwRegion]' = None, order_by: 'Optional[ListPrivateNetworksRequestOrderBy]' = <ListPrivateNetworksRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page_size: 'Optional[int]' = 0, page: 'Optional[int]' = 0)

Bases: object

lb_id: str

Load Balancer ID.

order_by: ListPrivateNetworksRequestOrderBy | None = 'created_at_asc'

Sort order of Private Network objects in the response.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

Number of objects to return.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.ListLbPrivateNetworksResponse(private_network: 'List[PrivateNetwork]', total_count: 'int')

Bases: object

private_network: List[PrivateNetwork]

List of Private Network objects attached to the Load Balancer.

total_count: int

Total number of objects in the response.

class scaleway.lb.v1.ListLbTypesRequest(region: 'Optional[ScwRegion]' = None, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0)

Bases: object

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

The number of items to return.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.ListLbTypesResponse(lb_types: 'List[LbType]', total_count: 'int')

Bases: object

lb_types: List[LbType]

List of Load Balancer commercial offer type objects.

total_count: int

Total number of Load Balancer offer type objects.

class scaleway.lb.v1.ListLbsRequest(region: 'Optional[ScwRegion]' = None, name: 'Optional[str]' = None, order_by: 'Optional[ListLbsRequestOrderBy]' = <ListLbsRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page_size: 'Optional[int]' = 0, page: 'Optional[int]' = 0, organization_id: 'Optional[str]' = None, project_id: 'Optional[str]' = None, tags: 'Optional[List[str]]' = <factory>)

Bases: object

name: str | None = None

Load Balancer name to filter for.

order_by: ListLbsRequestOrderBy | None = 'created_at_asc'

Sort order of Load Balancers in the response.

organization_id: str | None = None

Organization ID to filter for, only Load Balancers from this Organization will be returned.

page: int | None = 0

Page number to return, from the paginated results.

page_size: int | None = 0

Number of Load Balancers to return.

project_id: str | None = None

Project ID to filter for, only Load Balancers from this Project will be returned.

region: str | None = None

Region to target. If none is passed will use default region from the config.

tags: List[str] | None

Filter by tag, only Load Balancers with one or more matching tags will be returned.

class scaleway.lb.v1.ListLbsRequestOrderBy(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

CREATED_AT_ASC = 'created_at_asc'
CREATED_AT_DESC = 'created_at_desc'
NAME_ASC = 'name_asc'
NAME_DESC = 'name_desc'
class scaleway.lb.v1.ListLbsResponse(lbs: 'List[Lb]', total_count: 'int')

Bases: object

lbs: List[Lb]

List of Load Balancer objects.

total_count: int

The total number of Load Balancer objects.

class scaleway.lb.v1.ListPrivateNetworksRequestOrderBy(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

CREATED_AT_ASC = 'created_at_asc'
CREATED_AT_DESC = 'created_at_desc'
class scaleway.lb.v1.ListRoutesRequest(region: 'Optional[ScwRegion]' = None, order_by: 'Optional[ListRoutesRequestOrderBy]' = <ListRoutesRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page_size: 'Optional[int]' = 0, page: 'Optional[int]' = 0, frontend_id: 'Optional[str]' = None)

Bases: object

frontend_id: str | None = None

Frontend ID to filter for, only Routes from this Frontend will be returned.

order_by: ListRoutesRequestOrderBy | None = 'created_at_asc'

Sort order of routes in the response.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

The number of route objects to return.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.ListRoutesRequestOrderBy(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

CREATED_AT_ASC = 'created_at_asc'
CREATED_AT_DESC = 'created_at_desc'
class scaleway.lb.v1.ListRoutesResponse(routes: 'List[Route]', total_count: 'int')

Bases: object

routes: List[Route]

List of route objects.

total_count: int

The total number of route objects.

class scaleway.lb.v1.ListSubscriberRequest(region: 'Optional[ScwRegion]' = None, order_by: 'Optional[ListSubscriberRequestOrderBy]' = <ListSubscriberRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0, name: 'Optional[str]' = None, organization_id: 'Optional[str]' = None, project_id: 'Optional[str]' = None)

Bases: object

name: str | None = None

Subscriber name to search for.

order_by: ListSubscriberRequestOrderBy | None = 'created_at_asc'

Sort order of subscribers in the response.

organization_id: str | None = None

Filter subscribers by Organization ID.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

The number of items to return.

project_id: str | None = None

Filter subscribers by Project ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.ListSubscriberRequestOrderBy(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

CREATED_AT_ASC = 'created_at_asc'
CREATED_AT_DESC = 'created_at_desc'
NAME_ASC = 'name_asc'
NAME_DESC = 'name_desc'
class scaleway.lb.v1.ListSubscriberResponse(subscribers: 'List[Subscriber]', total_count: 'int')

Bases: object

subscribers: List[Subscriber]

List of subscriber objects.

total_count: int

The total number of objects.

class scaleway.lb.v1.MigrateLbRequest(lb_id: 'str', type_: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

lb_id: str

Load Balancer ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

type_: str

Load Balancer type to migrate to (use the List all Load Balancer offer types endpoint to get a list of available offer types).

class scaleway.lb.v1.OnMarkedDownAction(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

ON_MARKED_DOWN_ACTION_NONE = 'on_marked_down_action_none'
SHUTDOWN_SESSIONS = 'shutdown_sessions'
class scaleway.lb.v1.PrivateNetwork(ipam_ids: 'List[str]', private_network_id: 'str', status: 'PrivateNetworkStatus', lb: 'Optional[Lb]' = None, created_at: 'Optional[datetime]' = None, updated_at: 'Optional[datetime]' = None, static_config: 'Optional[PrivateNetworkStaticConfig]' = None, dhcp_config: 'Optional[PrivateNetworkDHCPConfig]' = None, ipam_config: 'Optional[PrivateNetworkIpamConfig]' = None)

Bases: object

created_at: datetime | None = None

Date on which the Private Network was created.

dhcp_config: PrivateNetworkDHCPConfig | None = None
ipam_config: PrivateNetworkIpamConfig | None = None
ipam_ids: List[str]

IPAM IDs of the booked IP addresses.

lb: Lb | None = None

Load Balancer object which is attached to the Private Network.

private_network_id: str

Private Network ID.

static_config: PrivateNetworkStaticConfig | None = None
status: PrivateNetworkStatus

Status of Private Network connection.

updated_at: datetime | None = None

Date on which the PN was last updated.

class scaleway.lb.v1.PrivateNetworkDHCPConfig(ip_id: 'Optional[str]' = None)

Bases: object

ip_id: str | None = None
class scaleway.lb.v1.PrivateNetworkIpamConfig

Bases: object

class scaleway.lb.v1.PrivateNetworkStaticConfig(ip_address: 'Optional[List[str]]' = <factory>)

Bases: object

ip_address: List[str] | None

Array of a local IP address for the Load Balancer on this Private Network.

class scaleway.lb.v1.PrivateNetworkStatus(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

ERROR = 'error'
PENDING = 'pending'
READY = 'ready'
UNKNOWN = 'unknown'
class scaleway.lb.v1.Protocol(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

HTTP = 'http'
TCP = 'tcp'
class scaleway.lb.v1.ProxyProtocol(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

PROXY_PROTOCOL_NONE = 'proxy_protocol_none'
PROXY_PROTOCOL_UNKNOWN = 'proxy_protocol_unknown'
PROXY_PROTOCOL_V1 = 'proxy_protocol_v1'
PROXY_PROTOCOL_V2 = 'proxy_protocol_v2'
PROXY_PROTOCOL_V2_SSL = 'proxy_protocol_v2_ssl'
PROXY_PROTOCOL_V2_SSL_CN = 'proxy_protocol_v2_ssl_cn'
class scaleway.lb.v1.ReleaseIpRequest(ip_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

ip_id: str

IP address ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.RemoveBackendServersRequest(backend_id: 'str', server_ip: 'List[str]', region: 'Optional[ScwRegion]' = None)

Bases: object

backend_id: str

Backend ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

server_ip: List[str]

List of IP addresses to remove from backend servers.

class scaleway.lb.v1.Route(id: 'str', frontend_id: 'str', backend_id: 'str', match: 'Optional[RouteMatch]' = None, created_at: 'Optional[datetime]' = None, updated_at: 'Optional[datetime]' = None)

Bases: object

backend_id: str

ID of the target backend.

created_at: datetime | None = None

Date on which the route was created.

frontend_id: str

ID of the source frontend.

id: str

Route ID.

match: RouteMatch | None = None

Object defining the match condition for a route to be applied. If an incoming client session matches the specified condition (i.e. it has a matching SNI value or HTTP Host header value), it will be passed to the target backend.

updated_at: datetime | None = None

Date on which the route was last updated.

class scaleway.lb.v1.RouteMatch(match_subdomains: 'bool', sni: 'Optional[str]' = None, host_header: 'Optional[str]' = None, path_begin: 'Optional[str]' = None)

Bases: object

host_header: str | None = None
match_subdomains: bool

If true, all subdomains will match.

path_begin: str | None = None
sni: str | None = None
class scaleway.lb.v1.SSLCompatibilityLevel(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

SSL_COMPATIBILITY_LEVEL_INTERMEDIATE = 'ssl_compatibility_level_intermediate'
SSL_COMPATIBILITY_LEVEL_MODERN = 'ssl_compatibility_level_modern'
SSL_COMPATIBILITY_LEVEL_OLD = 'ssl_compatibility_level_old'
SSL_COMPATIBILITY_LEVEL_UNKNOWN = 'ssl_compatibility_level_unknown'
class scaleway.lb.v1.SetAclsResponse(acls: 'List[Acl]', total_count: 'int')

Bases: object

acls: List[Acl]

List of ACL objects.

total_count: int

The total number of ACL objects.

class scaleway.lb.v1.SetBackendServersRequest(backend_id: 'str', server_ip: 'List[str]', region: 'Optional[ScwRegion]' = None)

Bases: object

backend_id: str

Backend ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

server_ip: List[str]

List of IP addresses for backend servers. Any other existing backend servers will be removed.

class scaleway.lb.v1.StickySessionsType(value: str, names: Any | None = None, *args: Any, **kwargs: Any)

Bases: str, Enum

COOKIE = 'cookie'
NONE = 'none'
TABLE = 'table'
class scaleway.lb.v1.SubscribeToLbRequest(lb_id: 'str', subscriber_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

lb_id: str

Load Balancer ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

subscriber_id: str

Subscriber ID.

class scaleway.lb.v1.Subscriber(id: str, name: str, email_config: SubscriberEmailConfig | None = None, webhook_config: SubscriberWebhookConfig | None = None)

Bases: object

Subscriber.

email_config: SubscriberEmailConfig | None = None
id: str

Subscriber ID.

name: str

Subscriber name.

webhook_config: SubscriberWebhookConfig | None = None
class scaleway.lb.v1.SubscriberEmailConfig(email: 'str')

Bases: object

email: str

Email address to send alerts to.

class scaleway.lb.v1.SubscriberWebhookConfig(uri: str)

Bases: object

Webhook alert of subscriber.

uri: str

URI to receive POST requests.

class scaleway.lb.v1.UnsubscribeFromLbRequest(lb_id: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

lb_id: str

Load Balancer ID.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.UpdateAclRequest(acl_id: 'str', name: 'str', action: 'AclAction', index: 'int', region: 'Optional[ScwRegion]' = None, match: 'Optional[AclMatch]' = None, description: 'Optional[str]' = None)

Bases: object

acl_id: str

ACL ID.

action: AclAction

Action to take when incoming traffic matches an ACL filter.

description: str | None = None

ACL description.

index: int

Priority of this ACL (ACLs are applied in ascending order, 0 is the first ACL executed).

match: AclMatch | None = None

ACL match filter object. One of ip_subnet, ips_edge_services or http_filter & http_filter_value are required.

name: str

ACL name.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.UpdateBackendRequest(backend_id: 'str', name: 'str', forward_protocol: 'Protocol', forward_port: 'int', forward_port_algorithm: 'ForwardPortAlgorithm', sticky_sessions: 'StickySessionsType', sticky_sessions_cookie_name: 'str', region: 'Optional[ScwRegion]' = None, send_proxy_v2: 'Optional[bool]' = False, timeout_server: 'Optional[str]' = None, timeout_connect: 'Optional[str]' = None, timeout_tunnel: 'Optional[str]' = None, on_marked_down_action: 'Optional[OnMarkedDownAction]' = <OnMarkedDownAction.ON_MARKED_DOWN_ACTION_NONE: 'on_marked_down_action_none'>, proxy_protocol: 'Optional[ProxyProtocol]' = <ProxyProtocol.PROXY_PROTOCOL_UNKNOWN: 'proxy_protocol_unknown'>, failover_host: 'Optional[str]' = None, ssl_bridging: 'Optional[bool]' = False, ignore_ssl_server_verify: 'Optional[bool]' = False, redispatch_attempt_count: 'Optional[int]' = 0, max_retries: 'Optional[int]' = 0, max_connections: 'Optional[int]' = 0, timeout_queue: 'Optional[str]' = None)

Bases: object

backend_id: str

Backend ID.

failover_host: str | None = None

Scaleway Object Storage bucket website to be served as failover if all backend servers are down, e.g. failover-website.s3-website.fr-par.scw.cloud.

forward_port: int

Port to be used by the backend when forwarding traffic to backend servers.

forward_port_algorithm: ForwardPortAlgorithm

Load balancing algorithm to be used when determining which backend server to forward new traffic to.

forward_protocol: Protocol

Protocol to be used by the backend when forwarding traffic to backend servers.

ignore_ssl_server_verify: bool | None = False

Defines whether the server certificate verification should be ignored.

max_connections: int | None = 0

Maximum number of connections allowed per backend server.

max_retries: int | None = 0

Number of retries when a backend server connection failed.

name: str

Backend name.

on_marked_down_action: OnMarkedDownAction | None = 'on_marked_down_action_none'

Action to take when a backend server is marked as down.

proxy_protocol: ProxyProtocol | None = 'proxy_protocol_unknown'

Protocol to use between the Load Balancer and backend servers. Allows the backend servers to be informed of the client’s real IP address. The PROXY protocol must be supported by the backend servers’ software.

redispatch_attempt_count: int | None = 0

Whether to use another backend server on each attempt.

region: str | None = None

Region to target. If none is passed will use default region from the config.

send_proxy_v2: bool | None = False

Deprecated in favor of proxy_protocol field.

ssl_bridging: bool | None = False

Defines whether to enable SSL bridging between the Load Balancer and backend servers.

sticky_sessions: StickySessionsType

Defines whether to activate sticky sessions (binding a particular session to a particular backend server) and the method to use if so. None disables sticky sessions. Cookie-based uses an HTTP cookie to stick a session to a backend server. Table-based uses the source (client) IP address to stick a session to a backend server.

Cookie name for cookie-based sticky sessions.

timeout_connect: str | None = None

Maximum allowed time for establishing a connection to a backend server.

timeout_queue: str | None = None

Maximum time for a request to be left pending in queue when max_connections is reached.

timeout_server: str | None = None

Maximum allowed time for a backend server to process a request.

timeout_tunnel: str | None = None

Maximum allowed tunnel inactivity time after Websocket is established (takes precedence over client and server timeout).

class scaleway.lb.v1.UpdateCertificateRequest(certificate_id: 'str', name: 'str', region: 'Optional[ScwRegion]' = None)

Bases: object

certificate_id: str

Certificate ID.

name: str

Certificate name.

region: str | None = None

Region to target. If none is passed will use default region from the config.

class scaleway.lb.v1.UpdateFrontendRequest(frontend_id: 'str', name: 'str', inbound_port: 'int', backend_id: 'str', enable_http3: 'bool', region: 'Optional[ScwRegion]' = None, timeout_client: 'Optional[str]' = None, certificate_id: 'Optional[str]' = None, certificate_ids: 'Optional[List[str]]' = <factory>, connection_rate_limit: 'Optional[int]' = 0, enable_access_logs: 'Optional[bool]' = False)

Bases: object

backend_id: str

Backend ID (ID of the backend the frontend should pass traffic to).

certificate_id: str | None = None

Certificate ID, deprecated in favor of certificate_ids array.

certificate_ids: List[str] | None

List of SSL/TLS certificate IDs to bind to the frontend.

connection_rate_limit: int | None = 0

Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second.

enable_access_logs: bool | None = False

Defines whether to enable access logs on the frontend.

enable_http3: bool

Defines whether to enable HTTP/3 protocol on the frontend.

frontend_id: str

Frontend ID.

inbound_port: int

Port the frontend should listen on.

name: str

Frontend name.

region: str | None = None

Region to target. If none is passed will use default region from the config.

timeout_client: str | None = None

Maximum allowed inactivity time on the client side.

class scaleway.lb.v1.UpdateHealthCheckRequest(port: 'int', check_max_retries: 'int', backend_id: 'str', check_send_proxy: 'bool', region: 'Optional[ScwRegion]' = None, check_delay: 'Optional[str]' = None, check_timeout: 'Optional[str]' = None, transient_check_delay: 'Optional[str]' = None, tcp_config: 'Optional[HealthCheckTcpConfig]' = None, mysql_config: 'Optional[HealthCheckMysqlConfig]' = None, pgsql_config: 'Optional[HealthCheckPgsqlConfig]' = None, ldap_config: 'Optional[HealthCheckLdapConfig]' = None, redis_config: 'Optional[HealthCheckRedisConfig]' = None, http_config: 'Optional[HealthCheckHttpConfig]' = None, https_config: 'Optional[HealthCheckHttpsConfig]' = None)

Bases: object

backend_id: str

Backend ID.

check_delay: str | None = None

Time to wait between two consecutive health checks.

check_max_retries: int

Number of consecutive unsuccessful health checks after which the server will be considered dead.

check_send_proxy: bool

Defines whether proxy protocol should be activated for the health check.

check_timeout: str | None = None

Maximum time a backend server has to reply to the health check.

http_config: HealthCheckHttpConfig | None = None
https_config: HealthCheckHttpsConfig | None = None
ldap_config: HealthCheckLdapConfig | None = None
mysql_config: HealthCheckMysqlConfig | None = None
pgsql_config: HealthCheckPgsqlConfig | None = None
port: int

Port to use for the backend server health check.

redis_config: HealthCheckRedisConfig | None = None
region: str | None = None

Region to target. If none is passed will use default region from the config.

tcp_config: HealthCheckTcpConfig | None = None
transient_check_delay: str | None = None

Time to wait between two consecutive health checks when a backend server is in a transient state (going UP or DOWN).

class scaleway.lb.v1.UpdateIpRequest(ip_id: 'str', region: 'Optional[ScwRegion]' = None, reverse: 'Optional[str]' = None, lb_id: 'Optional[str]' = None, tags: 'Optional[List[str]]' = <factory>)

Bases: object

ip_id: str

IP address ID.

lb_id: str | None = None

ID of the server on which to attach the flexible IP.

region: str | None = None

Region to target. If none is passed will use default region from the config.

reverse: str | None = None

Reverse DNS (domain name) for the IP address.

tags: List[str] | None

List of tags for the IP.

class scaleway.lb.v1.UpdateLbRequest(lb_id: 'str', name: 'str', description: 'str', region: 'Optional[ScwRegion]' = None, tags: 'Optional[List[str]]' = <factory>, ssl_compatibility_level: 'Optional[SSLCompatibilityLevel]' = <SSLCompatibilityLevel.SSL_COMPATIBILITY_LEVEL_UNKNOWN: 'ssl_compatibility_level_unknown'>)

Bases: object

description: str

Load Balancer description.

lb_id: str

Load Balancer ID.

name: str

Load Balancer name.

region: str | None = None

Region to target. If none is passed will use default region from the config.

ssl_compatibility_level: SSLCompatibilityLevel | None = 'ssl_compatibility_level_unknown'

Determines the minimal SSL version which needs to be supported on the client side, in an SSL/TLS offloading context. Intermediate is suitable for general-purpose servers with a variety of clients, recommended for almost all systems. Modern is suitable for services with clients that support TLS 1.3 and don’t need backward compatibility. Old is compatible with a small number of very old clients and should be used only as a last resort.

tags: List[str] | None

List of tags for the Load Balancer.

class scaleway.lb.v1.UpdateRouteRequest(route_id: 'str', backend_id: 'str', region: 'Optional[ScwRegion]' = None, match: 'Optional[RouteMatch]' = None)

Bases: object

backend_id: str

ID of the target backend for the route.

match: RouteMatch | None = None

Object defining the match condition for a route to be applied. If an incoming client session matches the specified condition (i.e. it has a matching SNI value or HTTP Host header value), it will be passed to the target backend.

region: str | None = None

Region to target. If none is passed will use default region from the config.

route_id: str

Route ID.

class scaleway.lb.v1.UpdateSubscriberRequest(subscriber_id: 'str', name: 'str', region: 'Optional[ScwRegion]' = None, email_config: 'Optional[SubscriberEmailConfig]' = None, webhook_config: 'Optional[SubscriberWebhookConfig]' = None)

Bases: object

email_config: SubscriberEmailConfig | None = None
name: str

Subscriber name.

region: str | None = None

Region to target. If none is passed will use default region from the config.

subscriber_id: str

Subscriber ID.

webhook_config: SubscriberWebhookConfig | None = None
class scaleway.lb.v1.ZonedApiAddBackendServersRequest(backend_id: 'str', server_ip: 'List[str]', zone: 'Optional[ScwZone]' = None)

Bases: object

backend_id: str

Backend ID.

server_ip: List[str]

List of IP addresses to add to backend servers.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiAttachPrivateNetworkRequest(lb_id: 'str', private_network_id: 'str', zone: 'Optional[ScwZone]' = None, ipam_ids: 'Optional[List[str]]' = <factory>, static_config: 'Optional[PrivateNetworkStaticConfig]' = None, dhcp_config: 'Optional[PrivateNetworkDHCPConfig]' = None, ipam_config: 'Optional[PrivateNetworkIpamConfig]' = None)

Bases: object

dhcp_config: PrivateNetworkDHCPConfig | None = None
ipam_config: PrivateNetworkIpamConfig | None = None
ipam_ids: List[str] | None

IPAM ID of a pre-reserved IP address to assign to the Load Balancer on this Private Network. In the future, it will be possible to specify multiple IPs in this field (IPv4 and IPv6), for now only one ID of an IPv4 address is expected. When null, a new private IP address is created for the Load Balancer on this Private Network.

lb_id: str

Load Balancer ID.

private_network_id: str

Private Network ID.

static_config: PrivateNetworkStaticConfig | None = None
zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiCreateAclRequest(frontend_id: str, action: AclAction, index: int, description: str, zone: str | None = None, name: str | None = None, match: AclMatch | None = None)

Bases: object

Add an ACL to a Load Balancer frontend.

action: AclAction

Action to take when incoming traffic matches an ACL filter.

description: str

ACL description.

frontend_id: str

Frontend ID to attach the ACL to.

index: int

Priority of this ACL (ACLs are applied in ascending order, 0 is the first ACL executed).

match: AclMatch | None = None

ACL match filter object. One of ip_subnet, ips_edge_services or http_filter & http_filter_value are required.

name: str | None = None

ACL name.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiCreateBackendRequest(forward_protocol: 'Protocol', forward_port: 'int', forward_port_algorithm: 'ForwardPortAlgorithm', sticky_sessions: 'StickySessionsType', sticky_sessions_cookie_name: 'str', lb_id: 'str', health_check: 'HealthCheck', server_ip: 'List[str]', zone: 'Optional[ScwZone]' = None, name: 'Optional[str]' = None, send_proxy_v2: 'Optional[bool]' = False, timeout_server: 'Optional[str]' = None, timeout_connect: 'Optional[str]' = None, timeout_tunnel: 'Optional[str]' = None, on_marked_down_action: 'Optional[OnMarkedDownAction]' = <OnMarkedDownAction.ON_MARKED_DOWN_ACTION_NONE: 'on_marked_down_action_none'>, proxy_protocol: 'Optional[ProxyProtocol]' = <ProxyProtocol.PROXY_PROTOCOL_UNKNOWN: 'proxy_protocol_unknown'>, failover_host: 'Optional[str]' = None, ssl_bridging: 'Optional[bool]' = False, ignore_ssl_server_verify: 'Optional[bool]' = False, redispatch_attempt_count: 'Optional[int]' = 0, max_retries: 'Optional[int]' = 0, max_connections: 'Optional[int]' = 0, timeout_queue: 'Optional[str]' = None)

Bases: object

failover_host: str | None = None

Scaleway Object Storage bucket website to be served as failover if all backend servers are down, e.g. failover-website.s3-website.fr-par.scw.cloud.

forward_port: int

Port to be used by the backend when forwarding traffic to backend servers.

forward_port_algorithm: ForwardPortAlgorithm

Load balancing algorithm to be used when determining which backend server to forward new traffic to.

forward_protocol: Protocol

Protocol to be used by the backend when forwarding traffic to backend servers.

health_check: HealthCheck

Object defining the health check to be carried out by the backend when checking the status and health of backend servers.

ignore_ssl_server_verify: bool | None = False

Defines whether the server certificate verification should be ignored.

lb_id: str

Load Balancer ID.

max_connections: int | None = 0

Maximum number of connections allowed per backend server.

max_retries: int | None = 0

Number of retries when a backend server connection failed.

name: str | None = None

Name for the backend.

on_marked_down_action: OnMarkedDownAction | None = 'on_marked_down_action_none'

Action to take when a backend server is marked as down.

proxy_protocol: ProxyProtocol | None = 'proxy_protocol_unknown'

Protocol to use between the Load Balancer and backend servers. Allows the backend servers to be informed of the client’s real IP address. The PROXY protocol must be supported by the backend servers’ software.

redispatch_attempt_count: int | None = 0

Whether to use another backend server on each attempt.

send_proxy_v2: bool | None = False

Deprecated in favor of proxy_protocol field.

server_ip: List[str]

List of backend server IP addresses (IPv4 or IPv6) the backend should forward traffic to.

ssl_bridging: bool | None = False

Defines whether to enable SSL bridging between the Load Balancer and backend servers.

sticky_sessions: StickySessionsType

Defines whether to activate sticky sessions (binding a particular session to a particular backend server) and the method to use if so. None disables sticky sessions. Cookie-based uses an HTTP cookie TO stick a session to a backend server. Table-based uses the source (client) IP address to stick a session to a backend server.

Cookie name for cookie-based sticky sessions.

timeout_connect: str | None = None

Maximum allowed time for establishing a connection to a backend server.

timeout_queue: str | None = None

Maximum time for a request to be left pending in queue when max_connections is reached.

timeout_server: str | None = None

Maximum allowed time for a backend server to process a request.

timeout_tunnel: str | None = None

Maximum allowed tunnel inactivity time after Websocket is established (takes precedence over client and server timeout).

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiCreateCertificateRequest(lb_id: 'str', zone: 'Optional[ScwZone]' = None, name: 'Optional[str]' = None, letsencrypt: 'Optional[CreateCertificateRequestLetsencryptConfig]' = None, custom_certificate: 'Optional[CreateCertificateRequestCustomCertificate]' = None)

Bases: object

custom_certificate: CreateCertificateRequestCustomCertificate | None = None
lb_id: str

Load Balancer ID.

letsencrypt: CreateCertificateRequestLetsencryptConfig | None = None
name: str | None = None

Name for the certificate.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiCreateFrontendRequest(inbound_port: 'int', lb_id: 'str', backend_id: 'str', enable_http3: 'bool', enable_access_logs: 'bool', zone: 'Optional[ScwZone]' = None, name: 'Optional[str]' = None, timeout_client: 'Optional[str]' = None, certificate_id: 'Optional[str]' = None, certificate_ids: 'Optional[List[str]]' = <factory>, connection_rate_limit: 'Optional[int]' = 0)

Bases: object

backend_id: str

Backend ID (ID of the backend the frontend should pass traffic to).

certificate_id: str | None = None

Certificate ID, deprecated in favor of certificate_ids array.

certificate_ids: List[str] | None

List of SSL/TLS certificate IDs to bind to the frontend.

connection_rate_limit: int | None = 0

Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second.

enable_access_logs: bool

Defines whether to enable access logs on the frontend.

enable_http3: bool

Defines whether to enable HTTP/3 protocol on the frontend.

inbound_port: int

Port the frontend should listen on.

lb_id: str

Load Balancer ID (ID of the Load Balancer to attach the frontend to).

name: str | None = None

Name for the frontend.

timeout_client: str | None = None

Maximum allowed inactivity time on the client side.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiCreateIpRequest(is_ipv6: 'bool', zone: 'Optional[ScwZone]' = None, reverse: 'Optional[str]' = None, tags: 'Optional[List[str]]' = <factory>, project_id: 'Optional[str]' = None, organization_id: 'Optional[str]' = None)

Bases: object

is_ipv6: bool

If true, creates a Flexible IP with an ipv6 address.

organization_id: str | None = None
project_id: str | None = None
reverse: str | None = None

Reverse DNS (domain name) for the IP address.

tags: List[str] | None

List of tags for the IP.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiCreateLbRequest(description: 'str', type_: 'str', zone: 'Optional[ScwZone]' = None, name: 'Optional[str]' = None, ip_id: 'Optional[str]' = None, assign_flexible_ip: 'Optional[bool]' = False, assign_flexible_ipv6: 'Optional[bool]' = False, ip_ids: 'Optional[List[str]]' = <factory>, tags: 'Optional[List[str]]' = <factory>, ssl_compatibility_level: 'Optional[SSLCompatibilityLevel]' = <SSLCompatibilityLevel.SSL_COMPATIBILITY_LEVEL_UNKNOWN: 'ssl_compatibility_level_unknown'>, project_id: 'Optional[str]' = None, organization_id: 'Optional[str]' = None)

Bases: object

assign_flexible_ip: bool | None = False

Defines whether to automatically assign a flexible public IP to the Load Balancer. Default value is true (assign).

assign_flexible_ipv6: bool | None = False

Defines whether to automatically assign a flexible public IPv6 to the Load Balancer. Default value is false (do not assign).

description: str

Description for the Load Balancer.

ip_id: str | None = None

ID of an existing flexible IP address to attach to the Load Balancer.

ip_ids: List[str] | None

List of IP IDs to attach to the Load Balancer.

name: str | None = None

Name for the Load Balancer.

organization_id: str | None = None
project_id: str | None = None
ssl_compatibility_level: SSLCompatibilityLevel | None = 'ssl_compatibility_level_unknown'

Determines the minimal SSL version which needs to be supported on the client side, in an SSL/TLS offloading context. Intermediate is suitable for general-purpose servers with a variety of clients, recommended for almost all systems. Modern is suitable for services with clients that support TLS 1.3 and do not need backward compatibility. Old is compatible with a small number of very old clients and should be used only as a last resort.

tags: List[str] | None

List of tags for the Load Balancer.

type_: str

Load Balancer commercial offer type. Use the Load Balancer types endpoint to retrieve a list of available offer types.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiCreateRouteRequest(frontend_id: 'str', backend_id: 'str', zone: 'Optional[ScwZone]' = None, match: 'Optional[RouteMatch]' = None)

Bases: object

backend_id: str

ID of the target backend for the route.

frontend_id: str

ID of the source frontend to create the route on.

match: RouteMatch | None = None

Object defining the match condition for a route to be applied. If an incoming client session matches the specified condition (i.e. it has a matching SNI value or HTTP Host header value), it will be passed to the target backend.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiCreateSubscriberRequest(name: str, zone: str | None = None, project_id: str | None = None, organization_id: str | None = None, email_config: SubscriberEmailConfig | None = None, webhook_config: SubscriberWebhookConfig | None = None)

Bases: object

Create a new alert subscriber (webhook or email).

email_config: SubscriberEmailConfig | None = None
name: str

Subscriber name.

organization_id: str | None = None
project_id: str | None = None
webhook_config: SubscriberWebhookConfig | None = None
zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiDeleteAclRequest(acl_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

acl_id: str

ACL ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiDeleteBackendRequest(backend_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

backend_id: str

ID of the backend to delete.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiDeleteCertificateRequest(certificate_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

certificate_id: str

Certificate ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiDeleteFrontendRequest(frontend_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

frontend_id: str

ID of the frontend to delete.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiDeleteLbRequest(lb_id: 'str', release_ip: 'bool', zone: 'Optional[ScwZone]' = None)

Bases: object

lb_id: str

ID of the Load Balancer to delete.

release_ip: bool

Defines whether the Load Balancer’s flexible IP should be deleted. Set to true to release the flexible IP, or false to keep it available in your account for future Load Balancers.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiDeleteRouteRequest(route_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

route_id: str

Route ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiDeleteSubscriberRequest(subscriber_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

subscriber_id: str

Subscriber ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiDetachPrivateNetworkRequest(lb_id: 'str', private_network_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

lb_id: str

Load balancer ID.

private_network_id: str

Set your instance private network id.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiGetAclRequest(acl_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

acl_id: str

ACL ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiGetBackendRequest(backend_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

backend_id: str

Backend ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiGetCertificateRequest(certificate_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

certificate_id: str

Certificate ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiGetFrontendRequest(frontend_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

frontend_id: str

Frontend ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiGetIpRequest(ip_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

ip_id: str

IP address ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiGetLbRequest(lb_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

lb_id: str

Load Balancer ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiGetLbStatsRequest(lb_id: str, zone: str | None = None, backend_id: str | None = None)

Bases: object

Get Load Balancer stats.

backend_id: str | None = None

ID of the backend.

lb_id: str

Load Balancer ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiGetRouteRequest(route_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

route_id: str

Route ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiGetSubscriberRequest(subscriber_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

subscriber_id: str

Subscriber ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiListAclsRequest(frontend_id: 'str', zone: 'Optional[ScwZone]' = None, order_by: 'Optional[ListAclRequestOrderBy]' = <ListAclRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0, name: 'Optional[str]' = None)

Bases: object

frontend_id: str

Frontend ID (ACLs attached to this frontend will be returned in the response).

name: str | None = None

ACL name to filter for.

order_by: ListAclRequestOrderBy | None = 'created_at_asc'

Sort order of ACLs in the response.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

The number of ACLs to return.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiListBackendStatsRequest(lb_id: 'str', zone: 'Optional[ScwZone]' = None, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0, backend_id: 'Optional[str]' = None)

Bases: object

backend_id: str | None = None

ID of the backend.

lb_id: str

Load Balancer ID.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

Number of items to return.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiListBackendsRequest(lb_id: 'str', zone: 'Optional[ScwZone]' = None, name: 'Optional[str]' = None, order_by: 'Optional[ListBackendsRequestOrderBy]' = <ListBackendsRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0)

Bases: object

lb_id: str

Load Balancer ID.

name: str | None = None

Name of the backend to filter for.

order_by: ListBackendsRequestOrderBy | None = 'created_at_asc'

Sort order of backends in the response.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

Number of backends to return.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiListCertificatesRequest(lb_id: 'str', zone: 'Optional[ScwZone]' = None, order_by: 'Optional[ListCertificatesRequestOrderBy]' = <ListCertificatesRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0, name: 'Optional[str]' = None)

Bases: object

lb_id: str

Load Balancer ID.

name: str | None = None

Certificate name to filter for, only certificates of this name will be returned.

order_by: ListCertificatesRequestOrderBy | None = 'created_at_asc'

Sort order of certificates in the response.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

Number of certificates to return.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiListFrontendsRequest(lb_id: 'str', zone: 'Optional[ScwZone]' = None, name: 'Optional[str]' = None, order_by: 'Optional[ListFrontendsRequestOrderBy]' = <ListFrontendsRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0)

Bases: object

lb_id: str

Load Balancer ID.

name: str | None = None

Name of the frontend to filter for.

order_by: ListFrontendsRequestOrderBy | None = 'created_at_asc'

Sort order of frontends in the response.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

Number of frontends to return.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiListIPsRequest(zone: 'Optional[ScwZone]' = None, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0, ip_address: 'Optional[str]' = None, organization_id: 'Optional[str]' = None, project_id: 'Optional[str]' = None, ip_type: 'Optional[ListIpsRequestIpType]' = <ListIpsRequestIpType.ALL: 'all'>, tags: 'Optional[List[str]]' = <factory>)

Bases: object

ip_address: str | None = None

IP address to filter for.

ip_type: ListIpsRequestIpType | None = 'all'

IP type to filter for.

organization_id: str | None = None

Organization ID to filter for, only Load Balancer IP addresses from this Organization will be returned.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

Number of IP addresses to return.

project_id: str | None = None

Project ID to filter for, only Load Balancer IP addresses from this Project will be returned.

tags: List[str] | None

Tag to filter for, only IPs with one or more matching tags will be returned.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiListLbPrivateNetworksRequest(lb_id: 'str', zone: 'Optional[ScwZone]' = None, order_by: 'Optional[ListPrivateNetworksRequestOrderBy]' = <ListPrivateNetworksRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page_size: 'Optional[int]' = 0, page: 'Optional[int]' = 0)

Bases: object

lb_id: str

Load Balancer ID.

order_by: ListPrivateNetworksRequestOrderBy | None = 'created_at_asc'

Sort order of Private Network objects in the response.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

Number of objects to return.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiListLbTypesRequest(zone: 'Optional[ScwZone]' = None, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0)

Bases: object

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

The number of items to return.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiListLbsRequest(zone: 'Optional[ScwZone]' = None, name: 'Optional[str]' = None, order_by: 'Optional[ListLbsRequestOrderBy]' = <ListLbsRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page_size: 'Optional[int]' = 0, page: 'Optional[int]' = 0, organization_id: 'Optional[str]' = None, project_id: 'Optional[str]' = None, tags: 'Optional[List[str]]' = <factory>)

Bases: object

name: str | None = None

Load Balancer name to filter for.

order_by: ListLbsRequestOrderBy | None = 'created_at_asc'

Sort order of Load Balancers in the response.

organization_id: str | None = None

Organization ID to filter for, only Load Balancers from this Organization will be returned.

page: int | None = 0

Page number to return, from the paginated results.

page_size: int | None = 0

Number of Load Balancers to return.

project_id: str | None = None

Project ID to filter for, only Load Balancers from this Project will be returned.

tags: List[str] | None

Filter by tag, only Load Balancers with one or more matching tags will be returned.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiListRoutesRequest(zone: 'Optional[ScwZone]' = None, order_by: 'Optional[ListRoutesRequestOrderBy]' = <ListRoutesRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page_size: 'Optional[int]' = 0, page: 'Optional[int]' = 0, frontend_id: 'Optional[str]' = None)

Bases: object

frontend_id: str | None = None

Frontend ID to filter for, only Routes from this Frontend will be returned.

order_by: ListRoutesRequestOrderBy | None = 'created_at_asc'

Sort order of routes in the response.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

The number of route objects to return.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiListSubscriberRequest(zone: 'Optional[ScwZone]' = None, order_by: 'Optional[ListSubscriberRequestOrderBy]' = <ListSubscriberRequestOrderBy.CREATED_AT_ASC: 'created_at_asc'>, page: 'Optional[int]' = 0, page_size: 'Optional[int]' = 0, name: 'Optional[str]' = None, organization_id: 'Optional[str]' = None, project_id: 'Optional[str]' = None)

Bases: object

name: str | None = None

Subscriber name to search for.

order_by: ListSubscriberRequestOrderBy | None = 'created_at_asc'

Sort order of subscribers in the response.

organization_id: str | None = None

Filter subscribers by Organization ID.

page: int | None = 0

The page number to return, from the paginated results.

page_size: int | None = 0

The number of items to return.

project_id: str | None = None

Filter subscribers by Project ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiMigrateLbRequest(lb_id: 'str', type_: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

lb_id: str

Load Balancer ID.

type_: str

Load Balancer type to migrate to (use the List all Load Balancer offer types endpoint to get a list of available offer types).

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiReleaseIpRequest(ip_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

ip_id: str

IP address ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiRemoveBackendServersRequest(backend_id: 'str', server_ip: 'List[str]', zone: 'Optional[ScwZone]' = None)

Bases: object

backend_id: str

Backend ID.

server_ip: List[str]

List of IP addresses to remove from backend servers.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiSetAclsRequest(acls: 'List[AclSpec]', frontend_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

acls: List[AclSpec]

List of ACLs for this frontend. Any other existing ACLs on this frontend will be removed.

frontend_id: str

Frontend ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiSetBackendServersRequest(backend_id: 'str', server_ip: 'List[str]', zone: 'Optional[ScwZone]' = None)

Bases: object

backend_id: str

Backend ID.

server_ip: List[str]

List of IP addresses for backend servers. Any other existing backend servers will be removed.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiSubscribeToLbRequest(lb_id: 'str', subscriber_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

lb_id: str

Load Balancer ID.

subscriber_id: str

Subscriber ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiUnsubscribeFromLbRequest(lb_id: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

lb_id: str

Load Balancer ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiUpdateAclRequest(acl_id: 'str', name: 'str', action: 'AclAction', index: 'int', zone: 'Optional[ScwZone]' = None, match: 'Optional[AclMatch]' = None, description: 'Optional[str]' = None)

Bases: object

acl_id: str

ACL ID.

action: AclAction

Action to take when incoming traffic matches an ACL filter.

description: str | None = None

ACL description.

index: int

Priority of this ACL (ACLs are applied in ascending order, 0 is the first ACL executed).

match: AclMatch | None = None

ACL match filter object. One of ip_subnet, ips_edge_services or http_filter & http_filter_value are required.

name: str

ACL name.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiUpdateBackendRequest(backend_id: 'str', name: 'str', forward_protocol: 'Protocol', forward_port: 'int', forward_port_algorithm: 'ForwardPortAlgorithm', sticky_sessions: 'StickySessionsType', sticky_sessions_cookie_name: 'str', zone: 'Optional[ScwZone]' = None, send_proxy_v2: 'Optional[bool]' = False, timeout_server: 'Optional[str]' = None, timeout_connect: 'Optional[str]' = None, timeout_tunnel: 'Optional[str]' = None, on_marked_down_action: 'Optional[OnMarkedDownAction]' = <OnMarkedDownAction.ON_MARKED_DOWN_ACTION_NONE: 'on_marked_down_action_none'>, proxy_protocol: 'Optional[ProxyProtocol]' = <ProxyProtocol.PROXY_PROTOCOL_UNKNOWN: 'proxy_protocol_unknown'>, failover_host: 'Optional[str]' = None, ssl_bridging: 'Optional[bool]' = False, ignore_ssl_server_verify: 'Optional[bool]' = False, redispatch_attempt_count: 'Optional[int]' = 0, max_retries: 'Optional[int]' = 0, max_connections: 'Optional[int]' = 0, timeout_queue: 'Optional[str]' = None)

Bases: object

backend_id: str

Backend ID.

failover_host: str | None = None

Scaleway Object Storage bucket website to be served as failover if all backend servers are down, e.g. failover-website.s3-website.fr-par.scw.cloud.

forward_port: int

Port to be used by the backend when forwarding traffic to backend servers.

forward_port_algorithm: ForwardPortAlgorithm

Load balancing algorithm to be used when determining which backend server to forward new traffic to.

forward_protocol: Protocol

Protocol to be used by the backend when forwarding traffic to backend servers.

ignore_ssl_server_verify: bool | None = False

Defines whether the server certificate verification should be ignored.

max_connections: int | None = 0

Maximum number of connections allowed per backend server.

max_retries: int | None = 0

Number of retries when a backend server connection failed.

name: str

Backend name.

on_marked_down_action: OnMarkedDownAction | None = 'on_marked_down_action_none'

Action to take when a backend server is marked as down.

proxy_protocol: ProxyProtocol | None = 'proxy_protocol_unknown'

Protocol to use between the Load Balancer and backend servers. Allows the backend servers to be informed of the client’s real IP address. The PROXY protocol must be supported by the backend servers’ software.

redispatch_attempt_count: int | None = 0

Whether to use another backend server on each attempt.

send_proxy_v2: bool | None = False

Deprecated in favor of proxy_protocol field.

ssl_bridging: bool | None = False

Defines whether to enable SSL bridging between the Load Balancer and backend servers.

sticky_sessions: StickySessionsType

Defines whether to activate sticky sessions (binding a particular session to a particular backend server) and the method to use if so. None disables sticky sessions. Cookie-based uses an HTTP cookie to stick a session to a backend server. Table-based uses the source (client) IP address to stick a session to a backend server.

Cookie name for cookie-based sticky sessions.

timeout_connect: str | None = None

Maximum allowed time for establishing a connection to a backend server.

timeout_queue: str | None = None

Maximum time for a request to be left pending in queue when max_connections is reached.

timeout_server: str | None = None

Maximum allowed time for a backend server to process a request.

timeout_tunnel: str | None = None

Maximum allowed tunnel inactivity time after Websocket is established (takes precedence over client and server timeout).

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiUpdateCertificateRequest(certificate_id: 'str', name: 'str', zone: 'Optional[ScwZone]' = None)

Bases: object

certificate_id: str

Certificate ID.

name: str

Certificate name.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiUpdateFrontendRequest(frontend_id: 'str', name: 'str', inbound_port: 'int', backend_id: 'str', enable_http3: 'bool', zone: 'Optional[ScwZone]' = None, timeout_client: 'Optional[str]' = None, certificate_id: 'Optional[str]' = None, certificate_ids: 'Optional[List[str]]' = <factory>, connection_rate_limit: 'Optional[int]' = 0, enable_access_logs: 'Optional[bool]' = False)

Bases: object

backend_id: str

Backend ID (ID of the backend the frontend should pass traffic to).

certificate_id: str | None = None

Certificate ID, deprecated in favor of certificate_ids array.

certificate_ids: List[str] | None

List of SSL/TLS certificate IDs to bind to the frontend.

connection_rate_limit: int | None = 0

Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second.

enable_access_logs: bool | None = False

Defines whether to enable access logs on the frontend.

enable_http3: bool

Defines whether to enable HTTP/3 protocol on the frontend.

frontend_id: str

Frontend ID.

inbound_port: int

Port the frontend should listen on.

name: str

Frontend name.

timeout_client: str | None = None

Maximum allowed inactivity time on the client side.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiUpdateHealthCheckRequest(port: 'int', check_max_retries: 'int', backend_id: 'str', check_send_proxy: 'bool', zone: 'Optional[ScwZone]' = None, check_delay: 'Optional[str]' = None, check_timeout: 'Optional[str]' = None, transient_check_delay: 'Optional[str]' = None, tcp_config: 'Optional[HealthCheckTcpConfig]' = None, mysql_config: 'Optional[HealthCheckMysqlConfig]' = None, pgsql_config: 'Optional[HealthCheckPgsqlConfig]' = None, ldap_config: 'Optional[HealthCheckLdapConfig]' = None, redis_config: 'Optional[HealthCheckRedisConfig]' = None, http_config: 'Optional[HealthCheckHttpConfig]' = None, https_config: 'Optional[HealthCheckHttpsConfig]' = None)

Bases: object

backend_id: str

Backend ID.

check_delay: str | None = None

Time to wait between two consecutive health checks.

check_max_retries: int

Number of consecutive unsuccessful health checks after which the server will be considered dead.

check_send_proxy: bool

Defines whether proxy protocol should be activated for the health check.

check_timeout: str | None = None

Maximum time a backend server has to reply to the health check.

http_config: HealthCheckHttpConfig | None = None
https_config: HealthCheckHttpsConfig | None = None
ldap_config: HealthCheckLdapConfig | None = None
mysql_config: HealthCheckMysqlConfig | None = None
pgsql_config: HealthCheckPgsqlConfig | None = None
port: int

Port to use for the backend server health check.

redis_config: HealthCheckRedisConfig | None = None
tcp_config: HealthCheckTcpConfig | None = None
transient_check_delay: str | None = None

Time to wait between two consecutive health checks when a backend server is in a transient state (going UP or DOWN).

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiUpdateIpRequest(ip_id: 'str', zone: 'Optional[ScwZone]' = None, reverse: 'Optional[str]' = None, lb_id: 'Optional[str]' = None, tags: 'Optional[List[str]]' = <factory>)

Bases: object

ip_id: str

IP address ID.

lb_id: str | None = None

ID of the server on which to attach the flexible IP.

reverse: str | None = None

Reverse DNS (domain name) for the IP address.

tags: List[str] | None

List of tags for the IP.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiUpdateLbRequest(lb_id: 'str', name: 'str', description: 'str', zone: 'Optional[ScwZone]' = None, tags: 'Optional[List[str]]' = <factory>, ssl_compatibility_level: 'Optional[SSLCompatibilityLevel]' = <SSLCompatibilityLevel.SSL_COMPATIBILITY_LEVEL_UNKNOWN: 'ssl_compatibility_level_unknown'>)

Bases: object

description: str

Load Balancer description.

lb_id: str

Load Balancer ID.

name: str

Load Balancer name.

ssl_compatibility_level: SSLCompatibilityLevel | None = 'ssl_compatibility_level_unknown'

Determines the minimal SSL version which needs to be supported on the client side, in an SSL/TLS offloading context. Intermediate is suitable for general-purpose servers with a variety of clients, recommended for almost all systems. Modern is suitable for services with clients that support TLS 1.3 and don’t need backward compatibility. Old is compatible with a small number of very old clients and should be used only as a last resort.

tags: List[str] | None

List of tags for the Load Balancer.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiUpdateRouteRequest(route_id: 'str', backend_id: 'str', zone: 'Optional[ScwZone]' = None, match: 'Optional[RouteMatch]' = None)

Bases: object

backend_id: str

ID of the target backend for the route.

match: RouteMatch | None = None

Object defining the match condition for a route to be applied. If an incoming client session matches the specified condition (i.e. it has a matching SNI value or HTTP Host header value), it will be passed to the target backend.

route_id: str

Route ID.

zone: str | None = None

Zone to target. If none is passed will use default zone from the config.

class scaleway.lb.v1.ZonedApiUpdateSubscriberRequest(subscriber_id: 'str', name: 'str', zone: 'Optional[ScwZone]' = None, email_config: 'Optional[SubscriberEmailConfig]' = None, webhook_config: 'Optional[SubscriberWebhookConfig]' = None)

Bases: object

email_config: SubscriberEmailConfig | None = None
name: str

Subscriber name.

subscriber_id: str

Subscriber ID.

webhook_config: SubscriberWebhookConfig | None = None
zone: str | None = None

Zone to target. If none is passed will use default zone from the config.