recurly 4.7.0 → 4.11.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (43) hide show
  1. checksums.yaml +4 -4
  2. data/.bumpversion.cfg +1 -1
  3. data/.travis.yml +3 -1
  4. data/CHANGELOG.md +48 -0
  5. data/GETTING_STARTED.md +1 -1
  6. data/lib/recurly/client/operations.rb +48 -3
  7. data/lib/recurly/client.rb +12 -4
  8. data/lib/recurly/connection_pool.rb +11 -9
  9. data/lib/recurly/requests/account_create.rb +4 -0
  10. data/lib/recurly/requests/account_purchase.rb +4 -0
  11. data/lib/recurly/requests/account_update.rb +4 -0
  12. data/lib/recurly/requests/add_on_pricing.rb +4 -0
  13. data/lib/recurly/requests/billing_info_create.rb +24 -0
  14. data/lib/recurly/requests/dunning_campaigns_bulk_update.rb +18 -0
  15. data/lib/recurly/requests/invoice_collect.rb +1 -1
  16. data/lib/recurly/requests/line_item_create.rb +4 -0
  17. data/lib/recurly/requests/plan_create.rb +4 -0
  18. data/lib/recurly/requests/plan_pricing.rb +4 -0
  19. data/lib/recurly/requests/plan_update.rb +4 -0
  20. data/lib/recurly/requests/pricing.rb +4 -0
  21. data/lib/recurly/requests/purchase_create.rb +1 -1
  22. data/lib/recurly/requests/subscription_change_create.rb +5 -1
  23. data/lib/recurly/requests/subscription_change_shipping_create.rb +8 -0
  24. data/lib/recurly/requests/subscription_create.rb +5 -1
  25. data/lib/recurly/requests/subscription_purchase.rb +4 -0
  26. data/lib/recurly/requests/subscription_update.rb +9 -1
  27. data/lib/recurly/resources/account.rb +4 -0
  28. data/lib/recurly/resources/account_mini.rb +4 -0
  29. data/lib/recurly/resources/add_on_pricing.rb +4 -0
  30. data/lib/recurly/resources/dunning_campaign.rb +50 -0
  31. data/lib/recurly/resources/dunning_campaigns_bulk_update_response.rb +18 -0
  32. data/lib/recurly/resources/dunning_cycle.rb +58 -0
  33. data/lib/recurly/resources/dunning_interval.rb +18 -0
  34. data/lib/recurly/resources/invoice.rb +5 -1
  35. data/lib/recurly/resources/line_item.rb +4 -0
  36. data/lib/recurly/resources/plan.rb +4 -0
  37. data/lib/recurly/resources/plan_pricing.rb +4 -0
  38. data/lib/recurly/resources/pricing.rb +4 -0
  39. data/lib/recurly/resources/subscription.rb +16 -0
  40. data/lib/recurly/resources/subscription_change.rb +4 -0
  41. data/lib/recurly/version.rb +1 -1
  42. data/openapi/api.yaml +525 -11
  43. metadata +8 -3
data/openapi/api.yaml CHANGED
@@ -219,6 +219,7 @@ x-tagGroups:
219
219
  - site
220
220
  - custom_field_definition
221
221
  - shipping_method
222
+ - dunning_campaigns
222
223
  tags:
223
224
  - name: site
224
225
  x-displayName: Site
@@ -332,6 +333,9 @@ tags:
332
333
  - name: automated_exports
333
334
  x-displayName: Automated Exports
334
335
  description: Automated exports of customer data.
336
+ - name: dunning_campaigns
337
+ x-displayName: Dunning Campaigns
338
+ description: Settings used when attempting to dun customers whose payments are declined.
335
339
  paths:
336
340
  "/sites":
337
341
  get:
@@ -12607,7 +12611,16 @@ paths:
12607
12611
  - subscription_change
12608
12612
  operationId: create_subscription_change
12609
12613
  summary: Create a new subscription change
12610
- description: Calling this will overwrite an existing, pending subscription change.
12614
+ description: |
12615
+ Calling this will overwrite an existing, pending subscription change.
12616
+
12617
+ If a subscription has a pending change, and a change is submitted which matches
12618
+ the subscription as it currently exists, the pending change will be deleted,
12619
+ and you will receive a 204 No Content response.
12620
+
12621
+ If a subscription has no pending
12622
+ change, and a change is submitted which matches the subscription as it currently
12623
+ exists, a 422 Unprocessable Entity validation error will be returned.
12611
12624
  parameters:
12612
12625
  - "$ref": "#/components/parameters/subscription_id"
12613
12626
  requestBody:
@@ -12623,6 +12636,8 @@ paths:
12623
12636
  application/json:
12624
12637
  schema:
12625
12638
  "$ref": "#/components/schemas/SubscriptionChange"
12639
+ '204':
12640
+ description: The previous pending change was reverted.
12626
12641
  '404':
12627
12642
  description: Incorrect site ID.
12628
12643
  content:
@@ -14432,6 +14447,107 @@ paths:
14432
14447
  err.(*recurly.Error); ok {\n\tfmt.Printf(\"Unexpected Recurly error: %v\",
14433
14448
  e)\n\treturn nil, err\n}\n\nfor _, file := range exportFiles.Files {\n\tfmt.Println(\"Export
14434
14449
  file download URL: \", file.Href)\n}"
14450
+ "/dunning_campaigns":
14451
+ get:
14452
+ tags:
14453
+ - dunning_campaigns
14454
+ operationId: list_dunning_campaigns
14455
+ summary: Show the dunning campaigns for a site
14456
+ description: See the [Pagination Guide](/guides/pagination.html) to learn how
14457
+ to use pagination in the API and Client Libraries.
14458
+ parameters:
14459
+ - "$ref": "#/components/parameters/sort_dates"
14460
+ responses:
14461
+ '200':
14462
+ description: A list of the the dunning_campaigns on an account.
14463
+ content:
14464
+ application/json:
14465
+ schema:
14466
+ "$ref": "#/components/schemas/DunningCampaignList"
14467
+ '404':
14468
+ description: Incorrect site.
14469
+ content:
14470
+ application/json:
14471
+ schema:
14472
+ "$ref": "#/components/schemas/Error"
14473
+ default:
14474
+ description: Unexpected error.
14475
+ content:
14476
+ application/json:
14477
+ schema:
14478
+ "$ref": "#/components/schemas/Error"
14479
+ x-code-samples: []
14480
+ "/dunning_campaigns/{dunning_campaign_id}":
14481
+ parameters:
14482
+ - "$ref": "#/components/parameters/dunning_campaign_id"
14483
+ get:
14484
+ tags:
14485
+ - dunning_campaigns
14486
+ operationId: get_dunning_campaign
14487
+ summary: Show the settings for a dunning campaign
14488
+ responses:
14489
+ '200':
14490
+ description: Settings for a dunning campaign.
14491
+ content:
14492
+ application/json:
14493
+ schema:
14494
+ "$ref": "#/components/schemas/DunningCampaign"
14495
+ '400':
14496
+ description: Bad request; perhaps missing or invalid parameters.
14497
+ content:
14498
+ application/json:
14499
+ schema:
14500
+ "$ref": "#/components/schemas/Error"
14501
+ '404':
14502
+ description: Incorrect site or campaign ID.
14503
+ content:
14504
+ application/json:
14505
+ schema:
14506
+ "$ref": "#/components/schemas/Error"
14507
+ default:
14508
+ description: Unexpected error.
14509
+ content:
14510
+ application/json:
14511
+ schema:
14512
+ "$ref": "#/components/schemas/Error"
14513
+ x-code-samples: []
14514
+ "/dunning_campaigns/{dunning_campaign_id}/bulk_update":
14515
+ put:
14516
+ tags:
14517
+ - dunning_campaigns
14518
+ operationId: put_dunning_campaign_bulk_update
14519
+ summary: Assign a dunning campaign to multiple plans
14520
+ requestBody:
14521
+ content:
14522
+ application/json:
14523
+ schema:
14524
+ "$ref": "#/components/schemas/DunningCampaignsBulkUpdate"
14525
+ responses:
14526
+ '200':
14527
+ description: A list of updated plans.
14528
+ content:
14529
+ application/json:
14530
+ schema:
14531
+ "$ref": "#/components/schemas/DunningCampaignsBulkUpdateResponse"
14532
+ '400':
14533
+ description: Bad request; perhaps missing or invalid parameters.
14534
+ content:
14535
+ application/json:
14536
+ schema:
14537
+ "$ref": "#/components/schemas/Error"
14538
+ '404':
14539
+ description: Incorrect site or campaign ID.
14540
+ content:
14541
+ application/json:
14542
+ schema:
14543
+ "$ref": "#/components/schemas/Error"
14544
+ default:
14545
+ description: Unexpected error.
14546
+ content:
14547
+ application/json:
14548
+ schema:
14549
+ "$ref": "#/components/schemas/Error"
14550
+ x-code-samples: []
14435
14551
  servers:
14436
14552
  - url: https://v3.recurly.com
14437
14553
  components:
@@ -14463,7 +14579,8 @@ components:
14463
14579
  billing_info_id:
14464
14580
  name: billing_info_id
14465
14581
  in: path
14466
- description: Billing Info ID.
14582
+ description: Billing Info ID. Can ONLY be used for sites utilizing the Wallet
14583
+ feature.
14467
14584
  required: true
14468
14585
  schema:
14469
14586
  type: string
@@ -14575,6 +14692,13 @@ components:
14575
14692
  required: true
14576
14693
  schema:
14577
14694
  type: string
14695
+ dunning_campaign_id:
14696
+ name: dunning_campaign_id
14697
+ in: path
14698
+ description: Dunning Campaign ID, e.g. `e28zov4fw0v2`.
14699
+ required: true
14700
+ schema:
14701
+ type: string
14578
14702
  ids:
14579
14703
  name: ids
14580
14704
  in: query
@@ -15324,6 +15448,14 @@ components:
15324
15448
  created by this request. Supports 'moto' value, which is the acronym for
15325
15449
  mail order and telephone transactions.
15326
15450
  "$ref": "#/components/schemas/GatewayTransactionTypeEnum"
15451
+ dunning_campaign_id:
15452
+ type: string
15453
+ title: Dunning Campaign ID
15454
+ description: Unique ID to identify a dunning campaign. Available when the
15455
+ Dunning Campaigns feature is enabled. Used to specify if a non-default
15456
+ dunning campaign should be assigned to this account. For sites without
15457
+ multiple dunning campaigns enabled, the default dunning campaign will
15458
+ always be used.
15327
15459
  address:
15328
15460
  "$ref": "#/components/schemas/Address"
15329
15461
  billing_info:
@@ -15394,6 +15526,14 @@ components:
15394
15526
  specifically whether the account is self-paying or will rely on the parent
15395
15527
  account to pay.
15396
15528
  "$ref": "#/components/schemas/BillToEnum"
15529
+ dunning_campaign_id:
15530
+ type: string
15531
+ title: Dunning Campaign ID
15532
+ description: Unique ID to identify a dunning campaign. Available when the
15533
+ Dunning Campaigns feature is enabled. Used to specify if a non-default
15534
+ dunning campaign should be assigned to this account. For sites without
15535
+ multiple dunning campaigns enabled, the default dunning campaign will
15536
+ always be used.
15397
15537
  address:
15398
15538
  "$ref": "#/components/schemas/Address"
15399
15539
  billing_info:
@@ -15459,6 +15599,14 @@ components:
15459
15599
  bill_to:
15460
15600
  type: string
15461
15601
  maxLength: 6
15602
+ dunning_campaign_id:
15603
+ type: string
15604
+ title: Dunning Campaign ID
15605
+ description: Unique ID to identify a dunning campaign. Available when the
15606
+ Dunning Campaigns feature is enabled. Used to specify if a non-default
15607
+ dunning campaign should be assigned to this account. For sites without
15608
+ multiple dunning campaigns enabled, the default dunning campaign will
15609
+ always be used.
15462
15610
  AccountBalance:
15463
15611
  type: object
15464
15612
  properties:
@@ -16198,6 +16346,28 @@ components:
16198
16346
  characters comprising a country code; two check digits; and a number that
16199
16347
  includes the domestic bank account number, branch identifier, and potential
16200
16348
  routing information
16349
+ name_on_account:
16350
+ type: string
16351
+ maxLength: 255
16352
+ description: The name associated with the bank account (ACH, SEPA, Bacs
16353
+ only)
16354
+ account_number:
16355
+ type: string
16356
+ maxLength: 255
16357
+ description: The bank account number. (ACH, Bacs only)
16358
+ routing_number:
16359
+ type: string
16360
+ maxLength: 15
16361
+ description: The bank's rounting number. (ACH only)
16362
+ sort_code:
16363
+ type: string
16364
+ maxLength: 15
16365
+ description: Bank identifier code for UK based banks. Required for Bacs
16366
+ based billing infos. (Bacs only)
16367
+ type:
16368
+ "$ref": "#/components/schemas/AchTypeEnum"
16369
+ account_type:
16370
+ "$ref": "#/components/schemas/AchAccountTypeEnum"
16201
16371
  tax_identifier:
16202
16372
  type: string
16203
16373
  description: Tax identifier is required if adding a billing info that is
@@ -17208,7 +17378,8 @@ components:
17208
17378
  description: The `billing_info_id` is the value that represents a specific
17209
17379
  billing info for an end customer. When `billing_info_id` is used to assign
17210
17380
  billing info to the subscription, all future billing events for the subscription
17211
- will bill to the specified billing info.
17381
+ will bill to the specified billing info. `billing_info_id` can ONLY be
17382
+ used for sites utilizing the Wallet feature.
17212
17383
  subscription_ids:
17213
17384
  type: array
17214
17385
  title: Subscription IDs
@@ -17375,6 +17546,13 @@ components:
17375
17546
  format: date-time
17376
17547
  title: Closed at
17377
17548
  description: Date invoice was marked paid or failed.
17549
+ dunning_campaign_id:
17550
+ type: string
17551
+ title: Dunning Campaign ID
17552
+ description: Unique ID to identify the dunning campaign used when dunning
17553
+ the invoice. Available when the Dunning Campaigns feature is enabled.
17554
+ For sites without multiple dunning campaigns enabled, this will always
17555
+ be the default dunning campaign.
17378
17556
  InvoiceCreate:
17379
17557
  type: object
17380
17558
  properties:
@@ -17458,7 +17636,8 @@ components:
17458
17636
  description: The `billing_info_id` is the value that represents a specific
17459
17637
  billing info for an end customer. When `billing_info_id` is used to assign
17460
17638
  billing info to the subscription, all future billing events for the subscription
17461
- will bill to the specified billing info.
17639
+ will bill to the specified billing info. `billing_info_id` can ONLY be
17640
+ used for sites utilizing the Wallet feature.
17462
17641
  InvoiceCollection:
17463
17642
  type: object
17464
17643
  title: Invoice collection
@@ -17744,6 +17923,12 @@ components:
17744
17923
  "$ref": "#/components/schemas/LegacyCategoryEnum"
17745
17924
  account:
17746
17925
  "$ref": "#/components/schemas/AccountMini"
17926
+ bill_for_account_id:
17927
+ type: string
17928
+ title: Bill For Account ID
17929
+ maxLength: 13
17930
+ description: The UUID of the account responsible for originating the line
17931
+ item.
17747
17932
  subscription_id:
17748
17933
  type: string
17749
17934
  title: Subscription ID
@@ -17996,6 +18181,13 @@ components:
17996
18181
  A positive or negative amount with `type=credit` will result in a negative `unit_amount`.
17997
18182
  If `item_code`/`item_id` is present, `unit_amount` can be passed in, to override the
17998
18183
  `Item`'s `unit_amount`. If `item_code`/`item_id` is not present then `unit_amount` is required.
18184
+ tax_inclusive:
18185
+ type: boolean
18186
+ title: Tax Inclusive?
18187
+ default: false
18188
+ description: Determines whether or not tax is included in the unit amount.
18189
+ The Tax Inclusive Pricing feature (separate from the Mixed Tax Pricing
18190
+ feature) must be enabled to use this flag.
17999
18191
  quantity:
18000
18192
  type: integer
18001
18193
  title: Quantity
@@ -18287,6 +18479,14 @@ components:
18287
18479
  Used to determine whether items can be assigned as add-ons to individual subscriptions.
18288
18480
  If `true`, items can be assigned as add-ons to individual subscription add-ons.
18289
18481
  If `false`, only plan add-ons can be used.
18482
+ dunning_campaign_id:
18483
+ type: string
18484
+ title: Dunning Campaign ID
18485
+ description: Unique ID to identify a dunning campaign. Available when the
18486
+ Dunning Campaigns feature is enabled. Used to specify if a non-default
18487
+ dunning campaign should be assigned to this plan. For sites without multiple
18488
+ dunning campaigns enabled, the default dunning campaign will always be
18489
+ used.
18290
18490
  created_at:
18291
18491
  type: string
18292
18492
  format: date-time
@@ -18443,6 +18643,14 @@ components:
18443
18643
  Used to determine whether items can be assigned as add-ons to individual subscriptions.
18444
18644
  If `true`, items can be assigned as add-ons to individual subscription add-ons.
18445
18645
  If `false`, only plan add-ons can be used.
18646
+ dunning_campaign_id:
18647
+ type: string
18648
+ title: Dunning Campaign ID
18649
+ description: Unique ID to identify a dunning campaign. Available when the
18650
+ Dunning Campaigns feature is enabled. Used to specify if a non-default
18651
+ dunning campaign should be assigned to this plan. For sites without multiple
18652
+ dunning campaigns enabled, the default dunning campaign will always be
18653
+ used.
18446
18654
  required:
18447
18655
  - code
18448
18656
  - name
@@ -18493,6 +18701,13 @@ components:
18493
18701
  title: Unit price
18494
18702
  minimum: 0
18495
18703
  maximum: 1000000
18704
+ tax_inclusive:
18705
+ type: boolean
18706
+ title: Tax Inclusive?
18707
+ default: false
18708
+ description: Determines whether or not tax is included in the unit amount.
18709
+ The Tax Inclusive Pricing feature (separate from the Mixed Tax Pricing
18710
+ feature) must be enabled to use this flag.
18496
18711
  PlanUpdate:
18497
18712
  type: object
18498
18713
  properties:
@@ -18619,6 +18834,14 @@ components:
18619
18834
  Used to determine whether items can be assigned as add-ons to individual subscriptions.
18620
18835
  If `true`, items can be assigned as add-ons to individual subscription add-ons.
18621
18836
  If `false`, only plan add-ons can be used.
18837
+ dunning_campaign_id:
18838
+ type: string
18839
+ title: Dunning Campaign ID
18840
+ description: Unique ID to identify a dunning campaign. Available when the
18841
+ Dunning Campaigns feature is enabled. Used to specify if a non-default
18842
+ dunning campaign should be assigned to this plan. For sites without multiple
18843
+ dunning campaigns enabled, the default dunning campaign will always be
18844
+ used.
18622
18845
  AddOnPricing:
18623
18846
  type: object
18624
18847
  properties:
@@ -18643,6 +18866,13 @@ components:
18643
18866
  description: |
18644
18867
  Allows up to 9 decimal places. Only supported when `add_on_type` = `usage`.
18645
18868
  If `unit_amount_decimal` is provided, `unit_amount` cannot be provided.
18869
+ tax_inclusive:
18870
+ type: boolean
18871
+ title: Tax Inclusive?
18872
+ default: false
18873
+ description: Determines whether or not tax is included in the unit amount.
18874
+ The Tax Inclusive Pricing feature (separate from the Mixed Tax Pricing
18875
+ feature) must be enabled to use this flag.
18646
18876
  required:
18647
18877
  - currency
18648
18878
  TierPricing:
@@ -18685,6 +18915,13 @@ components:
18685
18915
  title: Unit price
18686
18916
  minimum: 0
18687
18917
  maximum: 1000000
18918
+ tax_inclusive:
18919
+ type: boolean
18920
+ title: Tax Inclusive?
18921
+ default: false
18922
+ description: Determines whether or not tax is included in the unit amount.
18923
+ The Tax Inclusive Pricing feature (separate from the Mixed Tax Pricing
18924
+ feature) must be enabled to use this flag.
18688
18925
  required:
18689
18926
  - currency
18690
18927
  - unit_amount
@@ -19276,6 +19513,16 @@ components:
19276
19513
  format: float
19277
19514
  title: Estimated total, before tax.
19278
19515
  minimum: 0
19516
+ tax:
19517
+ type: number
19518
+ format: float
19519
+ title: Estimated tax
19520
+ tax_info:
19521
+ "$ref": "#/components/schemas/TaxInfo"
19522
+ total:
19523
+ type: number
19524
+ format: float
19525
+ title: Estimated total
19279
19526
  collection_method:
19280
19527
  title: Collection method
19281
19528
  default: automatic
@@ -19335,6 +19582,12 @@ components:
19335
19582
  set. This timestamp is used for alerting customers to reauthorize in 3
19336
19583
  years in accordance with NACHA rules. If a subscription becomes inactive
19337
19584
  or the billing info is no longer a bank account, this timestamp is cleared.
19585
+ gateway_code:
19586
+ type: string
19587
+ title: Gateway Code
19588
+ description: If present, this subscription's transactions will use the payment
19589
+ gateway with this code.
19590
+ maxLength: 13
19338
19591
  billing_info_id:
19339
19592
  type: string
19340
19593
  title: Billing Info ID
@@ -19606,6 +19859,13 @@ components:
19606
19859
  type: number
19607
19860
  format: float
19608
19861
  title: Unit amount
19862
+ tax_inclusive:
19863
+ type: boolean
19864
+ title: Tax Inclusive?
19865
+ default: false
19866
+ description: Determines whether or not tax is included in the unit amount.
19867
+ The Tax Inclusive Pricing feature (separate from the Mixed Tax Pricing
19868
+ feature) must be enabled to use this flag.
19609
19869
  quantity:
19610
19870
  type: integer
19611
19871
  title: Subscription quantity
@@ -19693,6 +19953,13 @@ components:
19693
19953
  be used.
19694
19954
  minimum: 0
19695
19955
  maximum: 1000000
19956
+ tax_inclusive:
19957
+ type: boolean
19958
+ title: Tax Inclusive?
19959
+ default: false
19960
+ description: Determines whether or not tax is included in the unit amount.
19961
+ The Tax Inclusive Pricing feature (separate from the Mixed Tax Pricing
19962
+ feature) must be enabled to use this flag.
19696
19963
  quantity:
19697
19964
  type: integer
19698
19965
  title: Quantity
@@ -19767,8 +20034,10 @@ components:
19767
20034
  SubscriptionChangeShippingCreate:
19768
20035
  type: object
19769
20036
  title: Shipping details that will be changed on a subscription
19770
- description: The shipping address can currently only be changed immediately,
19771
- using SubscriptionUpdate.
20037
+ description: Shipping addresses are tied to a customer's account. Each account
20038
+ can have up to 20 different shipping addresses, and if you have enabled multiple
20039
+ subscriptions per account, you can associate different shipping addresses
20040
+ to each subscription.
19772
20041
  properties:
19773
20042
  method_id:
19774
20043
  type: string
@@ -19789,6 +20058,13 @@ components:
19789
20058
  format: float
19790
20059
  title: Assigns the subscription's shipping cost. If this is greater than
19791
20060
  zero then a `method_id` or `method_code` is required.
20061
+ address_id:
20062
+ type: string
20063
+ titpe: Shipping address ID
20064
+ description: Assign a shipping address from the account's existing shipping
20065
+ addresses. If this and address are both present, address will take precedence.
20066
+ address:
20067
+ "$ref": "#/components/schemas/ShippingAddressCreate"
19792
20068
  SubscriptionCreate:
19793
20069
  type: object
19794
20070
  properties:
@@ -19812,7 +20088,8 @@ components:
19812
20088
  description: The `billing_info_id` is the value that represents a specific
19813
20089
  billing info for an end customer. When `billing_info_id` is used to assign
19814
20090
  billing info to the subscription, all future billing events for the subscription
19815
- will bill to the specified billing info.
20091
+ will bill to the specified billing info. `billing_info_id` can ONLY be
20092
+ used for sites utilizing the Wallet feature.
19816
20093
  shipping:
19817
20094
  title: Shipping address
19818
20095
  description: Create a shipping address on the account and assign it to the
@@ -19836,6 +20113,13 @@ components:
19836
20113
  the subscription plan for the provided currency.
19837
20114
  minimum: 0
19838
20115
  maximum: 1000000
20116
+ tax_inclusive:
20117
+ type: boolean
20118
+ title: Tax Inclusive?
20119
+ default: false
20120
+ description: Determines whether or not tax is included in the unit amount.
20121
+ The Tax Inclusive Pricing feature (separate from the Mixed Tax Pricing
20122
+ feature) must be enabled to use this flag.
19839
20123
  quantity:
19840
20124
  type: integer
19841
20125
  title: Quantity
@@ -19967,6 +20251,13 @@ components:
19967
20251
  the subscription plan for the provided currency.
19968
20252
  minimum: 0
19969
20253
  maximum: 1000000
20254
+ tax_inclusive:
20255
+ type: boolean
20256
+ title: Tax Inclusive?
20257
+ default: false
20258
+ description: Determines whether or not tax is included in the unit amount.
20259
+ The Tax Inclusive Pricing feature (separate from the Mixed Tax Pricing
20260
+ feature) must be enabled to use this flag.
19970
20261
  quantity:
19971
20262
  type: integer
19972
20263
  title: Quantity
@@ -20097,6 +20388,19 @@ components:
20097
20388
  at 31 days exactly.
20098
20389
  minimum: 0
20099
20390
  default: 0
20391
+ gateway_code:
20392
+ type: string
20393
+ title: Gateway Code
20394
+ description: If present, this subscription's transactions will use the payment
20395
+ gateway with this code.
20396
+ maxLength: 13
20397
+ tax_inclusive:
20398
+ type: boolean
20399
+ title: Tax Inclusive?
20400
+ default: false
20401
+ description: Determines whether or not tax is included in the unit amount.
20402
+ The Tax Inclusive Pricing feature (separate from the Mixed Tax Pricing
20403
+ feature) must be enabled to use this flag.
20100
20404
  shipping:
20101
20405
  "$ref": "#/components/schemas/SubscriptionShippingUpdate"
20102
20406
  billing_info_id:
@@ -20105,7 +20409,8 @@ components:
20105
20409
  description: The `billing_info_id` is the value that represents a specific
20106
20410
  billing info for an end customer. When `billing_info_id` is used to assign
20107
20411
  billing info to the subscription, all future billing events for the subscription
20108
- will bill to the specified billing info.
20412
+ will bill to the specified billing info. `billing_info_id` can ONLY be
20413
+ used for sites utilizing the Wallet feature.
20109
20414
  SubscriptionPause:
20110
20415
  type: object
20111
20416
  properties:
@@ -20703,7 +21008,8 @@ components:
20703
21008
  description: The `billing_info_id` is the value that represents a specific
20704
21009
  billing info for an end customer. When `billing_info_id` is used to assign
20705
21010
  billing info to the subscription, all future billing events for the subscription
20706
- will bill to the specified billing info.
21011
+ will bill to the specified billing info. `billing_info_id` can ONLY be
21012
+ used for sites utilizing the Wallet feature.
20707
21013
  collection_method:
20708
21014
  title: Collection method
20709
21015
  description: Must be set to manual in order to preview a purchase for an
@@ -20803,6 +21109,150 @@ components:
20803
21109
  required:
20804
21110
  - currency
20805
21111
  - account
21112
+ DunningCampaign:
21113
+ type: object
21114
+ description: Settings for a dunning campaign.
21115
+ properties:
21116
+ id:
21117
+ type: string
21118
+ object:
21119
+ type: string
21120
+ title: Object type
21121
+ code:
21122
+ type: string
21123
+ description: Campaign code.
21124
+ name:
21125
+ type: string
21126
+ description: Campaign name.
21127
+ description:
21128
+ type: string
21129
+ description: Campaign description.
21130
+ default_campaign:
21131
+ type: boolean
21132
+ description: Whether or not this is the default campaign for accounts or
21133
+ plans without an assigned dunning campaign.
21134
+ dunning_cycles:
21135
+ type: array
21136
+ description: Dunning Cycle settings.
21137
+ items:
21138
+ "$ref": "#/components/schemas/DunningCycle"
21139
+ created_at:
21140
+ type: string
21141
+ format: date-time
21142
+ description: When the current campaign was created in Recurly.
21143
+ updated_at:
21144
+ type: string
21145
+ format: date-time
21146
+ description: When the current campaign was updated in Recurly.
21147
+ deleted_at:
21148
+ type: string
21149
+ format: date-time
21150
+ description: When the current campaign was deleted in Recurly.
21151
+ DunningCampaignList:
21152
+ type: object
21153
+ properties:
21154
+ object:
21155
+ type: string
21156
+ title: Object type
21157
+ description: Will always be List.
21158
+ has_more:
21159
+ type: boolean
21160
+ description: Indicates there are more results on subsequent pages.
21161
+ next:
21162
+ type: string
21163
+ description: Path to subsequent page of results.
21164
+ data:
21165
+ type: array
21166
+ items:
21167
+ "$ref": "#/components/schemas/DunningCampaign"
21168
+ DunningCycle:
21169
+ type: object
21170
+ properties:
21171
+ type:
21172
+ "$ref": "#/components/schemas/DunningCycleTypeEnum"
21173
+ applies_to_manual_trial:
21174
+ type: boolean
21175
+ description: Whether the dunning settings will be applied to manual trials.
21176
+ Only applies to trial cycles.
21177
+ first_communication_interval:
21178
+ type: integer
21179
+ description: The number of days after a transaction failure before the first
21180
+ dunning email is sent.
21181
+ send_immediately_on_hard_decline:
21182
+ type: boolean
21183
+ description: Whether or not to send an extra email immediately to customers
21184
+ whose initial payment attempt fails with either a hard decline or invalid
21185
+ billing info.
21186
+ intervals:
21187
+ type: array
21188
+ description: Dunning intervals.
21189
+ items:
21190
+ "$ref": "#/components/schemas/DunningInterval"
21191
+ expire_subscription:
21192
+ type: boolean
21193
+ description: Whether the subscription(s) should be cancelled at the end
21194
+ of the dunning cycle.
21195
+ fail_invoice:
21196
+ type: boolean
21197
+ description: Whether the invoice should be failed at the end of the dunning
21198
+ cycle.
21199
+ total_dunning_days:
21200
+ type: integer
21201
+ description: The number of days between the first dunning email being sent
21202
+ and the end of the dunning cycle.
21203
+ total_recycling_days:
21204
+ type: integer
21205
+ description: The number of days between a transaction failure and the end
21206
+ of the dunning cycle.
21207
+ version:
21208
+ type: integer
21209
+ description: Current campaign version.
21210
+ created_at:
21211
+ type: string
21212
+ format: date-time
21213
+ description: When the current settings were created in Recurly.
21214
+ updated_at:
21215
+ type: string
21216
+ format: date-time
21217
+ description: When the current settings were updated in Recurly.
21218
+ DunningInterval:
21219
+ properties:
21220
+ days:
21221
+ type: integer
21222
+ description: Number of days before sending the next email.
21223
+ email_template:
21224
+ type: string
21225
+ description: Email template being used.
21226
+ DunningCampaignsBulkUpdate:
21227
+ properties:
21228
+ plan_codes:
21229
+ type: array
21230
+ maxItems: 200
21231
+ description: List of `plan_codes` associated with the Plans for which the
21232
+ dunning campaign should be updated. Required unless `plan_ids` is present.
21233
+ items:
21234
+ type: string
21235
+ plan_ids:
21236
+ type: array
21237
+ maxItems: 200
21238
+ description: List of `plan_ids` associated with the Plans for which the
21239
+ dunning campaign should be updated. Required unless `plan_codes` is present.
21240
+ items:
21241
+ type: string
21242
+ DunningCampaignsBulkUpdateResponse:
21243
+ properties:
21244
+ object:
21245
+ type: string
21246
+ title: Object type
21247
+ readOnly: true
21248
+ plans:
21249
+ type: array
21250
+ title: Plans
21251
+ description: An array containing all of the `Plan` resources that have been
21252
+ updated.
21253
+ maxItems: 200
21254
+ items:
21255
+ "$ref": "#/components/schemas/Plan"
20806
21256
  PaymentMethod:
20807
21257
  properties:
20808
21258
  object:
@@ -21027,20 +21477,26 @@ components:
21027
21477
  - en-AU
21028
21478
  - en-CA
21029
21479
  - en-GB
21480
+ - en-IE
21030
21481
  - en-NZ
21031
21482
  - en-US
21032
21483
  - es-ES
21033
21484
  - es-MX
21034
21485
  - es-US
21486
+ - fi-FI
21035
21487
  - fr-CA
21036
21488
  - fr-FR
21037
21489
  - hi-IN
21490
+ - it-IT
21038
21491
  - ja-JP
21492
+ - ko-KR
21039
21493
  - nl-BE
21040
21494
  - nl-NL
21041
21495
  - pt-BR
21042
21496
  - pt-PT
21497
+ - ro-RO
21043
21498
  - ru-RU
21499
+ - sk-SK
21044
21500
  - tr-TR
21045
21501
  - zh-CN
21046
21502
  BillToEnum:
@@ -21180,16 +21636,22 @@ components:
21180
21636
  OriginEnum:
21181
21637
  type: string
21182
21638
  enum:
21639
+ - carryforward_credit
21640
+ - carryforward_gift_credit
21183
21641
  - credit
21642
+ - external_refund
21184
21643
  - gift_card
21185
21644
  - immediate_change
21645
+ - import
21186
21646
  - line_item_refund
21187
21647
  - open_amount_refund
21648
+ - prepayment
21188
21649
  - purchase
21650
+ - refund
21189
21651
  - renewal
21190
21652
  - termination
21653
+ - usage_correction
21191
21654
  - write_off
21192
- - prepayment
21193
21655
  InvoiceStateEnum:
21194
21656
  type: string
21195
21657
  enum:
@@ -21426,6 +21888,7 @@ components:
21426
21888
  - roku
21427
21889
  - sepadirectdebit
21428
21890
  - wire_transfer
21891
+ - braintree_v_zero
21429
21892
  CardTypeEnum:
21430
21893
  type: string
21431
21894
  enum:
@@ -21442,6 +21905,7 @@ components:
21442
21905
  - Union Pay
21443
21906
  - Unknown
21444
21907
  - Visa
21908
+ - Tarjeta Naranja
21445
21909
  AccountTypeEnum:
21446
21910
  type: string
21447
21911
  enum:
@@ -21500,6 +21964,7 @@ components:
21500
21964
  - ach_transactions_not_supported
21501
21965
  - ach_validation_exception
21502
21966
  - amazon_amount_exceeded
21967
+ - amazon_declined_review
21503
21968
  - amazon_invalid_authorization_status
21504
21969
  - amazon_invalid_close_attempt
21505
21970
  - amazon_invalid_create_order_reference
@@ -21516,13 +21981,17 @@ components:
21516
21981
  - batch_processing_error
21517
21982
  - billing_agreement_already_accepted
21518
21983
  - billing_agreement_not_accepted
21984
+ - billing_agreement_not_found
21985
+ - billing_agreement_replaced
21519
21986
  - call_issuer
21520
21987
  - call_issuer_update_cardholder_data
21988
+ - cancelled
21521
21989
  - cannot_refund_unsettled_transactions
21522
21990
  - card_not_activated
21523
21991
  - card_type_not_accepted
21524
21992
  - cardholder_requested_stop
21525
21993
  - contact_gateway
21994
+ - contract_not_found
21526
21995
  - currency_not_supported
21527
21996
  - customer_canceled_transaction
21528
21997
  - cvv_required
@@ -21534,9 +22003,12 @@ components:
21534
22003
  - declined_saveable
21535
22004
  - declined_security_code
21536
22005
  - deposit_referenced_chargeback
22006
+ - direct_debit_type_not_accepted
21537
22007
  - duplicate_transaction
21538
22008
  - exceeds_daily_limit
22009
+ - exceeds_max_amount
21539
22010
  - expired_card
22011
+ - finbot_disconnect
21540
22012
  - finbot_unavailable
21541
22013
  - fraud_address
21542
22014
  - fraud_address_recurly
@@ -21544,36 +22016,45 @@ components:
21544
22016
  - fraud_gateway
21545
22017
  - fraud_generic
21546
22018
  - fraud_ip_address
22019
+ - fraud_manual_decision
21547
22020
  - fraud_risk_check
21548
22021
  - fraud_security_code
21549
22022
  - fraud_stolen_card
21550
22023
  - fraud_too_many_attempts
21551
22024
  - fraud_velocity
22025
+ - gateway_account_setup_incomplete
21552
22026
  - gateway_error
21553
22027
  - gateway_rate_limited
21554
22028
  - gateway_timeout
21555
22029
  - gateway_token_not_found
21556
22030
  - gateway_unavailable
22031
+ - gateway_validation_exception
21557
22032
  - insufficient_funds
21558
22033
  - invalid_account_number
21559
22034
  - invalid_amount
22035
+ - invalid_billing_agreement_status
21560
22036
  - invalid_card_number
21561
22037
  - invalid_data
21562
22038
  - invalid_email
21563
- - invalid_gateway_configuration
21564
22039
  - invalid_gateway_access_token
22040
+ - invalid_gateway_configuration
21565
22041
  - invalid_issuer
21566
22042
  - invalid_login
21567
22043
  - invalid_merchant_type
22044
+ - invalid_name
22045
+ - invalid_payment_method
22046
+ - invalid_payment_method_hard
21568
22047
  - invalid_transaction
21569
22048
  - issuer_unavailable
21570
22049
  - merch_max_transaction_limit_exceeded
22050
+ - moneybot_disconnect
21571
22051
  - moneybot_unavailable
21572
22052
  - no_billing_information
21573
22053
  - no_gateway
21574
22054
  - no_gateway_found_for_transaction_amount
21575
22055
  - partial_approval
21576
22056
  - partial_credits_not_supported
22057
+ - payer_authentication_rejected
21577
22058
  - payment_cannot_void_authorization
21578
22059
  - payment_not_accepted
21579
22060
  - paypal_account_issue
@@ -21583,7 +22064,9 @@ components:
21583
22064
  - paypal_hard_decline
21584
22065
  - paypal_invalid_billing_agreement
21585
22066
  - paypal_primary_declined
22067
+ - processor_not_available
21586
22068
  - processor_unavailable
22069
+ - recurly_credentials_not_found
21587
22070
  - recurly_error
21588
22071
  - recurly_failed_to_get_token
21589
22072
  - recurly_token_mismatch
@@ -21591,10 +22074,19 @@ components:
21591
22074
  - reference_transactions_not_enabled
21592
22075
  - restricted_card
21593
22076
  - restricted_card_chargeback
22077
+ - rjs_token_expired
22078
+ - roku_invalid_card_number
22079
+ - roku_invalid_cib
22080
+ - roku_invalid_payment_method
22081
+ - roku_zip_code_mismatch
21594
22082
  - simultaneous
21595
22083
  - ssl_error
21596
22084
  - temporary_hold
22085
+ - three_d_secure_action_required
22086
+ - three_d_secure_action_result_token_mismatch
21597
22087
  - three_d_secure_authentication
22088
+ - three_d_secure_connection_error
22089
+ - three_d_secure_credential_error
21598
22090
  - three_d_secure_not_supported
21599
22091
  - too_many_attempts
21600
22092
  - total_credit_exceeds_capture
@@ -21606,10 +22098,13 @@ components:
21606
22098
  - transaction_cannot_be_voided
21607
22099
  - transaction_failed_to_settle
21608
22100
  - transaction_not_found
22101
+ - transaction_service_v2_disconnect
22102
+ - transaction_service_v2_unavailable
21609
22103
  - transaction_settled
21610
22104
  - transaction_stale_at_gateway
21611
22105
  - try_again
21612
22106
  - unknown
22107
+ - unmapped_partner_error
21613
22108
  - vaultly_service_unavailable
21614
22109
  - zero_dollar_auth_not_supported
21615
22110
  ExportDates:
@@ -21655,3 +22150,22 @@ components:
21655
22150
  enum:
21656
22151
  - cpf
21657
22152
  - cuit
22153
+ DunningCycleTypeEnum:
22154
+ type: string
22155
+ description: The type of invoice this cycle applies to.
22156
+ enum:
22157
+ - automatic
22158
+ - manual
22159
+ - trial
22160
+ AchTypeEnum:
22161
+ type: string
22162
+ description: The payment method type for a non-credit card based billing info.
22163
+ The value of `bacs` is the only accepted value (Bacs only)
22164
+ enum:
22165
+ - bacs
22166
+ AchAccountTypeEnum:
22167
+ type: string
22168
+ description: The bank account type. (ACH only)
22169
+ enum:
22170
+ - checking
22171
+ - savings