Skip to content

SystemPreferredCarrierAddRequest

Bases: OCIRequest

Add a carrier to the system. More than one carrier may be assigned to each country code. The response is either a SuccessResponse or an ErrorResponse.

Attributes:

carrier (str):

cic (str):

country_code (str):

is_intra_lata (bool):

is_inter_lata (bool):

is_international (bool):
Source code in src/mercury_ocip_fast/commands/commands.py
@dataclass(kw_only=True)
class SystemPreferredCarrierAddRequest(OCIRequest):
    """Add a carrier to the system.
        More than one carrier may be assigned to each country code.
        The response is either a SuccessResponse or an ErrorResponse.

    Attributes:

        carrier (str):

        cic (str):

        country_code (str):

        is_intra_lata (bool):

        is_inter_lata (bool):

        is_international (bool):

    """

    carrier: str = field(metadata={"alias": "carrier"})

    cic: str = field(metadata={"alias": "cic"})

    country_code: str = field(metadata={"alias": "countryCode"})

    is_intra_lata: bool = field(metadata={"alias": "isIntraLata"})

    is_inter_lata: bool = field(metadata={"alias": "isInterLata"})

    is_international: bool = field(metadata={"alias": "isInternational"})

Responses

Bases: OCIResponse

Source code in src/mercury_ocip_fast/commands/base_command.py
class SuccessResponse(OCIResponse):
    pass

Bases: OCIResponse

Source code in src/mercury_ocip_fast/commands/base_command.py
class ErrorResponse(OCIResponse):
    errorCode: Optional[int] = None
    summary: str
    summaryEnglish: str
    detail: Optional[str] = None

Example Usage

from mercury_ocip_fast.client import Client
from mercury_ocip_fast.commands import SystemPreferredCarrierAddRequest

client = Client()

command = SystemPreferredCarrierAddRequest(
    carrier=...,
    cic=...,
    country_code=...,
    is_intra_lata=...,
    is_inter_lata=...,
    is_international=...,
)

response = client.command(command)

print(response)

Example 2 with Raw Command

from mercury_ocip_fast.client import Client

client = Client()

response = client.raw_command("SystemPreferredCarrierAddRequest",
    carrier=...,
    cic=...,
    country_code=...,
    is_intra_lata=...,
    is_inter_lata=...,
    is_international=...,
)

print(response)