Skip to content

UserCallMeNowAddCriteriaRequest

Bases: OCIRequest

Add a criterion to the user's call me now service. The criterion added is automatically active. The response is either a SuccessResponse or an ErrorResponse.

Attributes:

user_id (str):

criteria_name (str):

time_schedule (Optional[TimeSchedule]):

holiday_schedule (Optional[HolidaySchedule]):

reject_call (bool):

to_dn_criteria (CallMeNowToDnCriteria):
Source code in src/mercury_ocip_fast/commands/commands.py
@dataclass(kw_only=True)
class UserCallMeNowAddCriteriaRequest(OCIRequest):
    """Add a criterion to the user's call me now service.  The criterion added is automatically active.
        The response is either a SuccessResponse or an ErrorResponse.

    Attributes:

        user_id (str):

        criteria_name (str):

        time_schedule (Optional[TimeSchedule]):

        holiday_schedule (Optional[HolidaySchedule]):

        reject_call (bool):

        to_dn_criteria (CallMeNowToDnCriteria):

    """

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

    criteria_name: str = field(metadata={"alias": "criteriaName"})

    time_schedule: Optional[TimeSchedule] = field(
        default=None, metadata={"alias": "timeSchedule"}
    )

    holiday_schedule: Optional[HolidaySchedule] = field(
        default=None, metadata={"alias": "holidaySchedule"}
    )

    reject_call: bool = field(metadata={"alias": "rejectCall"})

    to_dn_criteria: CallMeNowToDnCriteria = field(metadata={"alias": "toDnCriteria"})

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 UserCallMeNowAddCriteriaRequest

client = Client()

command = UserCallMeNowAddCriteriaRequest(
    user_id=...,
    criteria_name=...,
    time_schedule=...,
    holiday_schedule=...,
    reject_call=...,
    to_dn_criteria=...,
)

response = client.command(command)

print(response)

Example 2 with Raw Command

from mercury_ocip_fast.client import Client

client = Client()

response = client.raw_command("UserCallMeNowAddCriteriaRequest",
    user_id=...,
    criteria_name=...,
    time_schedule=...,
    holiday_schedule=...,
    reject_call=...,
    to_dn_criteria=...,
)

print(response)