Skip to content

UserDirectRouteGetRequest

Bases: OCIRequest

Get the direct route setting and the list of DTGs/Trunk Identities assigned to a user. The response is either UserDirectRouteGetResponse or ErrorResponse.

Attributes:

user_id (str):
Source code in src/mercury_ocip_fast/commands/commands.py
@dataclass(kw_only=True)
class UserDirectRouteGetRequest(OCIRequest):
    """Get the direct route setting and the list of DTGs/Trunk Identities assigned to a user.
        The response is either UserDirectRouteGetResponse or ErrorResponse.

    Attributes:

        user_id (str):

    """

    user_id: str = field(metadata={"alias": "userId"})

Responses

Bases: OCIDataResponse

Response to UserDirectRouteGetRequest. Contains the direct route setting and the list of DTGs/Trunk Identities assigned to a user.

Attributes:

outgoing_dtg_policy (str):

outgoing_trunk_identity_policy (str):

direct_route_identity_list (Optional[DirectRouteIdentifiers]):
Source code in src/mercury_ocip_fast/commands/commands.py
@dataclass(kw_only=True)
class UserDirectRouteGetResponse(OCIDataResponse):
    """Response to UserDirectRouteGetRequest.
        Contains the direct route setting and the list of DTGs/Trunk Identities assigned to a user.

    Attributes:

        outgoing_dtg_policy (str):

        outgoing_trunk_identity_policy (str):

        direct_route_identity_list (Optional[DirectRouteIdentifiers]):

    """

    outgoing_dtg_policy: str = field(metadata={"alias": "outgoingDTGPolicy"})

    outgoing_trunk_identity_policy: str = field(
        metadata={"alias": "outgoingTrunkIdentityPolicy"}
    )

    direct_route_identity_list: Optional[DirectRouteIdentifiers] = field(
        default=None, metadata={"alias": "directRouteIdentityList"}
    )

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 UserDirectRouteGetRequest

client = Client()

command = UserDirectRouteGetRequest(
    user_id=...,
)

response = client.command(command)

print(response)

Example 2 with Raw Command

from mercury_ocip_fast.client import Client

client = Client()

response = client.raw_command("UserDirectRouteGetRequest",
    user_id=...,
)

print(response)