CreateSubscriptionRequest class

Annotations
  • @JsonSerializable()

Constructors

CreateSubscriptionRequest({required String locationId, required String planId, required String customerId, String? idempotencyKey, String? startDate, String? canceledDate, String? taxPercentage, Money? priceOverrideMoney, String? cardId, String? timezone, SubscriptionSource? source})
const
CreateSubscriptionRequest.fromJson(Map<String, dynamic> json)
Converts a Map to an CreateSubscriptionRequest
factory

Properties

canceledDate String?
The YYYY-MM-DD-formatted date when the newly created subscription is scheduled for cancellation.
final
cardId String?
The ID of the subscriber's card to charge. If it is not specified, the subscriber receives an invoice via email.
final
customerId String
The ID of the customer subscribing to the subscription plan.
final
hashCode int
The hash code for this object.
no setterinherited
idempotencyKey String?
A unique string that identifies this CreateSubscription request. If you do not provide a unique string (or provide an empty string as the value), the endpoint treats each request as independent.
final
locationId String
The ID of the location the subscription is associated with.
final
planId String
The ID of the subscription plan created using the Catalog API.
final
priceOverrideMoney Money?
A custom price to apply for the subscription. If specified, it overrides the price configured by the subscription plan.
final
props List<Object?>
The list of properties that will be used to determine whether two instances are equal.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
source SubscriptionSource?
The origination details of the subscription.
final
startDate String?
The YYYY-MM-DD-formatted date to start the subscription. If it is unspecified, the subscription starts immediately.
final
stringify bool?
If set to true, the toString method will be overridden to output this instance's props.
no setterinherited
taxPercentage String?
The tax to add when billing the subscription. The percentage is expressed in decimal form, using a '.' as the decimal separator and without a '%' sign. For example, a value of 7.5 corresponds to 7.5%.
final
timezone String?
The timezone that is used in date calculations for the subscription. If unset, defaults to the location timezone. If a timezone is not configured for the location, defaults to "America/New_York". Format: the IANA Timezone Database identifier for the location timezone.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
Converts a CreateSubscriptionRequest to a Map
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited