SubscriptionResponseInterface

Type
Interface
Namespace
craft\commerce\base
Implemented by
craft\commerce\models\responses\DummySubscriptionResponse
Since
2.0

This interface class functions that a Subscription response needs to implement

View source (opens new window)

# Public Methods

Method Description
getData() Returns the response data.
getNextPaymentDate() Returns the time of next payment.
getReference() Returns the subscription reference.
getTrialDays() Returns the number of trial days on the subscription.
isCanceled() Returns whether the subscription is canceled.
isInactive() Whether the subscription is unpaid.
isScheduledForCancellation() Returns whether the subscription is scheduled to be canceled.

# getData()

Returns the response data.

View source (opens new window)

Returns

mixed

# getNextPaymentDate()

Returns the time of next payment.

View source (opens new window)

Returns

DateTime (opens new window)

# getReference()

Returns the subscription reference.

View source (opens new window)

Returns

string (opens new window)

# getTrialDays()

Returns the number of trial days on the subscription.

View source (opens new window)

Returns

integer (opens new window)

# isCanceled()

Returns whether the subscription is canceled.

View source (opens new window)

Returns

boolean (opens new window)

# isInactive()

Whether the subscription is unpaid.

View source (opens new window)

Returns

boolean (opens new window)

# isScheduledForCancellation()

Returns whether the subscription is scheduled to be canceled.

View source (opens new window)

Returns

boolean (opens new window)