Skip to content

Commercial peer

Commercial Peer Product Blocks.

PassiveSessionStates = [SessionState.PROVISIONED, SessionState.DISABLED, SessionState.IMPORTED_ONLY] module-attribute

The passive session states are used for pre-filling form pages that allow for modification of a BGP peer.

SessionState

Bases: strEnum

Session state of the Peering connection.

Source code in gso/products/product_blocks/commercial_peer.py
class SessionState(strEnum):
    """Session state of the Peering connection."""

    PROVISIONED = "provisioning"
    """Provisioning."""
    ACTIVE = "active"
    """Active."""
    DISABLED = "disabled"
    """Disabled."""
    DENY_ALL = "deny_all"
    """Deny all."""
    IMPORTED_ONLY = "imported_only"
    """Imported only."""

PROVISIONED = 'provisioning' class-attribute instance-attribute

Provisioning.

ACTIVE = 'active' class-attribute instance-attribute

Active.

DISABLED = 'disabled' class-attribute instance-attribute

Disabled.

DENY_ALL = 'deny_all' class-attribute instance-attribute

Deny all.

IMPORTED_ONLY = 'imported_only' class-attribute instance-attribute

Imported only.

PeeringConnectionInactive

Bases: ProductBlockModel

A Peering Connection that's currently inactive. See PeeringConnectionBlock.

Source code in gso/products/product_blocks/commercial_peer.py
class PeeringConnectionInactive(
    ProductBlockModel, lifecycle=[SubscriptionLifecycle.INITIAL], product_block_name="PeeringConnectionBlock"
):
    """A Peering Connection that's currently inactive. See `PeeringConnectionBlock`."""

    bgp_session_v4: BGPSessionInactive | None = None
    bgp_session_v6: BGPSessionInactive | None = None
    minimum_hold_timer: int | None = None
    session_state: SessionState
    placement_port: IXPortBlockInactive | PrivatePeerPortBlockInactive | TransitProviderPortBlockInactive | None = None

PeeringConnectionProvisioning

Bases: PeeringConnectionInactive

A Peering Connection that's currently being provisioned. See PeeringConnectionBlock.

Source code in gso/products/product_blocks/commercial_peer.py
class PeeringConnectionProvisioning(PeeringConnectionInactive, lifecycle=[SubscriptionLifecycle.PROVISIONING]):
    """A Peering Connection that's currently being provisioned. See `PeeringConnectionBlock`."""

    bgp_session_v4: BGPSessionProvisioning | None = None
    bgp_session_v6: BGPSessionProvisioning | None = None
    minimum_hold_timer: int | None = None
    session_state: SessionState
    placement_port: (
        IXPortBlockProvisioning | PrivatePeerPortBlockProvisioning | TransitProviderPortBlockProvisioning | None
    ) = None

PeeringConnection

Bases: PeeringConnectionProvisioning

A Peering Connection that's currently active.

Source code in gso/products/product_blocks/commercial_peer.py
class PeeringConnection(PeeringConnectionProvisioning, lifecycle=[SubscriptionLifecycle.ACTIVE]):
    """A Peering Connection that's currently active."""

    bgp_session_v4: BGPSession | None
    bgp_session_v6: BGPSession | None
    minimum_hold_timer: int | None
    session_state: SessionState
    placement_port: IXPortBlock | PrivatePeerPortBlock | TransitProviderPortBlock | None

CommercialPeerBlockInactive

Bases: ProductBlockModel

A Commercial Peer that's not yet provisioned. See CommercialPeerBlock.

Source code in gso/products/product_blocks/commercial_peer.py
class CommercialPeerBlockInactive(
    ProductBlockModel, lifecycle=[SubscriptionLifecycle.INITIAL], product_block_name="CommercialPeerBlock"
):
    """A Commercial Peer that's not yet provisioned. See ``CommercialPeerBlock``."""

    peering_connection_list: list[PeeringConnectionInactive] = Field(default_factory=list)
    prefix_limit_v4: NonNegativeInt | None = None
    prefix_limit_v6: NonNegativeInt | None = None
    partner_asn: NonNegativeInt | None = None
    partner_org_name: str | None = None

CommercialPeerBlockProvisioning

Bases: CommercialPeerBlockInactive

An CommercialPeer that's being provisioned. See CommercialPeerBlock.

Source code in gso/products/product_blocks/commercial_peer.py
class CommercialPeerBlockProvisioning(CommercialPeerBlockInactive, lifecycle=[SubscriptionLifecycle.PROVISIONING]):
    """An CommercialPeer that's being provisioned. See ``CommercialPeerBlock``."""

    peering_connection_list: list[PeeringConnectionProvisioning] = Field(default_factory=list)  # type: ignore[assignment]
    prefix_limit_v4: NonNegativeInt | None = None
    prefix_limit_v6: NonNegativeInt | None = None
    partner_asn: NonNegativeInt | None = None
    partner_org_name: str | None = None

CommercialPeerBlock

Bases: CommercialPeerBlockProvisioning

An Internet Exchange Port that's active.

Attributes:

Name Type Description
peering_connection_list list[PeeringConnection]

List of Peering Connections associated with this Commercial Peer

prefix_limit_v4 NonNegativeInt | None

Maximum number of IPv4 prefixes allowed for this Commercial Peer

prefix_limit_v6 NonNegativeInt | None

Maximum number of IPv6 prefixes allowed for this Commercial Peer

partner_asn NonNegativeInt | None

ASN of the partner for this Commercial Peer

partner_org_name str | None

Name of the partner organization for this Commercial Peer

Source code in gso/products/product_blocks/commercial_peer.py
class CommercialPeerBlock(CommercialPeerBlockProvisioning, lifecycle=[SubscriptionLifecycle.ACTIVE]):
    """An Internet Exchange Port that's active.

    Attributes:
        peering_connection_list: List of Peering Connections associated with this Commercial Peer
        prefix_limit_v4: Maximum number of IPv4 prefixes allowed for this Commercial Peer
        prefix_limit_v6: Maximum number of IPv6 prefixes allowed for this Commercial Peer
        partner_asn: ASN of the partner for this Commercial Peer
        partner_org_name: Name of the partner organization for this Commercial Peer
    """

    peering_connection_list: list[PeeringConnection] = Field(default_factory=list)  # type: ignore[assignment]
    prefix_limit_v4: NonNegativeInt | None
    prefix_limit_v6: NonNegativeInt | None
    partner_asn: NonNegativeInt | None
    partner_org_name: str | None