PATCH | /subscriptions/{SubscriptionId}/changeplan |
---|
Name | Parameter | Data Type | Required | Description |
---|---|---|---|---|
SubscriptionId | path | string | Yes | Subscription Id to be updated |
GameType | query | string | No | Gamtype |
Plan | query | string | No | The new subscription plan or null if unchanged. |
PaymentMethod | query | PaymentMethodType? | No | The new payment method or leave blank to keep the payment method. Can also be left blank if specifying a nonce/token instead. |
PaymentMethodNonce | query | string | No | The new payment method nonce if changing payment method from a nonce. |
PaymentMethodToken | query | string | No | The new payment method token if changing payment method from a token. |
CardholderName | query | string | No | Cardholder name if specifying a credit card nonce |
FundingSourceId | query | string | No | The new funding source id to use or null if unchanged. |
StartFromArtUnionId | query | string | No | The art union to start from. Either provide starting art union or starting date |
StartDate | query | DateTime? | No | New date from which the lottery should start. Either provide starting art union or starting date |
EndDate | query | DateTime? | No | Date when the subscription should end |
NoEndDate | query | bool? | No | True, to set the subscription to never expire |
RequestReference | query | RequestReference | No | Attribution values associated to the request if any |
Cash |
Cheque |
MoneyOrder |
CreditCard |
PayPal |
DirectDebit |
Wallet |
GooglePay |
ApplePay |
Name | Parameter | Data Type | Required | Description |
---|---|---|---|---|
CampaignId | form | string | No | |
RetailChannelId | form | string | Yes | |
ReferenceId | form | string | No |
Name | Parameter | Data Type | Required | Description |
---|---|---|---|---|
SubscriptionId | form | string | No | |
CustomerId | form | string | No | |
StartFromArtUnionId | form | string | No | |
PaymentMethod | form | PaymentMethodType | No | |
FundingSourceId | form | string | No | |
Plan | form | string | No | |
GameType | form | string | No | |
StartDate | form | DateTime | No | |
EndDate | form | DateTime? | No | |
SubscriptionSuspension | form | IEnumerable<SubscriptionSuspension> | No | |
Status | form | SubscriptionStatus | No | |
SubscribedDate | form | DateTime | No | |
CreditCard | form | CreditCard | No | |
GooglePayAccount | form | GooglePayAccount | No | |
ApplePayAccount | form | ApplePayAccount | No | |
PayPal | form | PayPalAccount | No | |
ReasonCode | form | string | No |
Name | Parameter | Data Type | Required | Description |
---|---|---|---|---|
SubscriptionId | form | string | No | |
StartDate | form | DateTime | No | |
EndDate | form | DateTime? | No | |
ReasonCode | form | string | No |
Pending |
Active |
Suspended |
Cancelled |
Name | Parameter | Data Type | Required | Description |
---|---|---|---|---|
CreditCardId | form | string | No | |
CardToken | form | string | No | |
Token | form | string | No | |
CardholderName | form | string | No | |
CardType | form | CreditCardType | No | |
UniqueNumberIdentifier | form | string | No | |
ExpirationMonth | form | string | No | |
ExpirationYear | form | string | No | |
Bin | form | string | No | |
LastFour | form | string | No | The last 4 digits of the credit card number |
IsDefault | form | bool | No | |
Disabled | form | bool | No | |
LastModified | form | DateTime | No |
Unknown |
AmericanExpress |
CarteBlanche |
ChinaUnionPay |
DinersClub |
Discover |
JCB |
Laser |
Maestro |
MasterCard |
Solo |
Switch |
Visa |
Name | Parameter | Data Type | Required | Description |
---|---|---|---|---|
UniqueCardId | form | string | No | |
SourceCardType | form | string | No | |
CustomerId | form | string | No | |
ExpirationMonth | form | string | No | |
ExpirationYear | form | string | No | |
Bin | form | string | No | The first 6 digits of the credit card, known as the Bank Identification Number. |
GoogleTransactionId | form | string | No | The last 4 digits of the credit card number |
SourceCardLast4 | form | string | No | |
CardholderName | form | string | No | |
CreatedAt | form | DateTime | No | The date/time the payment method was created |
Token | form | string | No | The payment method token |
Disabled | form | bool | No | |
IsDefault | form | bool | No |
Name | Parameter | Data Type | Required | Description |
---|---|---|---|---|
UniqueCardId | form | string | No | |
CardType | form | string | No | |
CustomerId | form | string | No | |
ExpirationMonth | form | string | No | |
ExpirationYear | form | string | No | |
Bin | form | string | No | The first 6 digits of the credit card, known as the Bank Identification Number. |
LastFour | form | string | No | The last 4 digits of the credit card number |
CardholderName | form | string | No | |
CreatedAt | form | DateTime | No | The date/time the payment method was created |
Token | form | string | No | |
IsDefault | form | bool | No | |
Disabled | form | bool | No |
Name | Parameter | Data Type | Required | Description |
---|---|---|---|---|
PayPalAccountId | form | string | No | The unique identifier of the PayPal acount in Dynamics |
Token | form | string | No | The payment method token |
form | string | No | The email address belonging to the Paypal account | |
BillingAgreementId | form | string | No | The unique identifier of the vaulted payment flow agreement between the customer's PayPal account and RSL PayPal business account |
CreatedAt | form | DateTime | No | The date/time the payment method was created |
IsDefault | form | bool | No | |
Disabled | form | bool | No | |
IsNewCustomerPayPalFee | form | bool? | No | Whether to apply a different fee for customer coming from PayPal |
To override the Content-type in your clients, use the HTTP Accept Header, append the .csv suffix or ?format=csv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
PATCH /subscriptions/{SubscriptionId}/changeplan HTTP/1.1
Host: azs-stg-lotteries-web.azurewebsites.net
Accept: text/csv
Content-Type: text/csv
Content-Length: length
{"subscriptionId":"String","gameType":"String","plan":"String","paymentMethod":"Cash","paymentMethodNonce":"String","paymentMethodToken":"String","cardholderName":"String","fundingSourceId":"String","startFromArtUnionId":"String","startDate":"0001-01-01T00:00:00.0000000","endDate":"0001-01-01T00:00:00.0000000","noEndDate":false,"requestReference":{"campaignId":"String","retailChannelId":"String","referenceId":"String"}}
HTTP/1.1 200 OK Content-Type: text/csv Content-Length: length {"subscriptionId":"String","customerId":"String","startFromArtUnionId":"String","paymentMethod":"Cash","fundingSourceId":"String","plan":"String","gameType":"String","startDate":"0001-01-01T00:00:00.0000000","endDate":"0001-01-01T00:00:00.0000000","status":"Pending","subscribedDate":"0001-01-01T00:00:00.0000000","creditCard":{"creditCardId":"String","cardToken":"String","token":"String","cardholderName":"String","cardType":"Unknown","uniqueNumberIdentifier":"String","expirationMonth":"String","expirationYear":"String","bin":"String","lastFour":"String","isDefault":false,"disabled":false,"lastModified":"0001-01-01T00:00:00.0000000"},"googlePayAccount":{"uniqueCardId":"String","sourceCardType":"String","customerId":"String","expirationMonth":"String","expirationYear":"String","bin":"String","googleTransactionId":"String","sourceCardLast4":"String","cardholderName":"String","createdAt":"0001-01-01T00:00:00.0000000","token":"String","disabled":false,"isDefault":false},"applePayAccount":{"uniqueCardId":"String","cardType":"String","customerId":"String","expirationMonth":"String","expirationYear":"String","bin":"String","lastFour":"String","cardholderName":"String","createdAt":"0001-01-01T00:00:00.0000000","token":"String","isDefault":false,"disabled":false},"payPal":{"payPalAccountId":"String","token":"String","email":"String","billingAgreementId":"String","createdAt":"0001-01-01T00:00:00.0000000","isDefault":false,"disabled":false,"isNewCustomerPayPalFee":false},"reasonCode":"String"}