Promotion¶
-
class
oci.tenant_manager_control_plane.models.
Promotion
(**kwargs)¶ Bases:
object
Promotion information for a subscription.
Attributes
STATUS_ACTIVE
A constant which can be used with the status property of a Promotion. STATUS_EXPIRED
A constant which can be used with the status property of a Promotion. STATUS_INITIALIZED
A constant which can be used with the status property of a Promotion. amount
Gets the amount of this Promotion. currency_unit
Gets the currency_unit of this Promotion. duration
Gets the duration of this Promotion. duration_unit
Gets the duration_unit of this Promotion. is_intent_to_pay
Gets the is_intent_to_pay of this Promotion. status
Gets the status of this Promotion. time_expired
Gets the time_expired of this Promotion. time_started
Gets the time_started of this Promotion. Methods
__init__
(**kwargs)Initializes a new Promotion object with values from keyword arguments. -
STATUS_ACTIVE
= 'ACTIVE'¶ A constant which can be used with the status property of a Promotion. This constant has a value of “ACTIVE”
-
STATUS_EXPIRED
= 'EXPIRED'¶ A constant which can be used with the status property of a Promotion. This constant has a value of “EXPIRED”
-
STATUS_INITIALIZED
= 'INITIALIZED'¶ A constant which can be used with the status property of a Promotion. This constant has a value of “INITIALIZED”
-
__init__
(**kwargs)¶ Initializes a new Promotion object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class):
Parameters: - duration (int) – The value to assign to the duration property of this Promotion.
- duration_unit (str) – The value to assign to the duration_unit property of this Promotion.
- amount (float) – The value to assign to the amount property of this Promotion.
- status (str) – The value to assign to the status property of this Promotion. Allowed values for this property are: “INITIALIZED”, “ACTIVE”, “EXPIRED”, ‘UNKNOWN_ENUM_VALUE’. Any unrecognized values returned by a service will be mapped to ‘UNKNOWN_ENUM_VALUE’.
- is_intent_to_pay (bool) – The value to assign to the is_intent_to_pay property of this Promotion.
- currency_unit (str) – The value to assign to the currency_unit property of this Promotion.
- time_started (datetime) – The value to assign to the time_started property of this Promotion.
- time_expired (datetime) – The value to assign to the time_expired property of this Promotion.
-
amount
¶ Gets the amount of this Promotion. If a subscription is present, indicates the total amount of promotional subscription credits.
Returns: The amount of this Promotion. Return type: float
-
currency_unit
¶ Gets the currency_unit of this Promotion. Currency unit associated with the promotion.
Returns: The currency_unit of this Promotion. Return type: str
-
duration
¶ Gets the duration of this Promotion. Specifies how long the promotion related to the subscription, if any, is valid in duration units.
Returns: The duration of this Promotion. Return type: int
-
duration_unit
¶ Gets the duration_unit of this Promotion. Unit for the duration.
Returns: The duration_unit of this Promotion. Return type: str
-
is_intent_to_pay
¶ Gets the is_intent_to_pay of this Promotion. Speficies whether or not the customer intends to pay after the promotion has expired.
Returns: The is_intent_to_pay of this Promotion. Return type: bool
-
status
¶ Gets the status of this Promotion. If a subscription is present, indicates the current status of the subscription promotion.
Allowed values for this property are: “INITIALIZED”, “ACTIVE”, “EXPIRED”, ‘UNKNOWN_ENUM_VALUE’. Any unrecognized values returned by a service will be mapped to ‘UNKNOWN_ENUM_VALUE’.
Returns: The status of this Promotion. Return type: str
-
time_expired
¶ Gets the time_expired of this Promotion. Date and time when the promotion ends.
Returns: The time_expired of this Promotion. Return type: datetime
-
time_started
¶ Gets the time_started of this Promotion. Date and time when the promotion starts.
Returns: The time_started of this Promotion. Return type: datetime
-