Skip to content

Commit fff156b

Browse files
authored
Merge pull request #313 from recurly/v3-v2021-02-25-19578875009
Generated Latest Changes for v2021-02-25
2 parents 2618ecd + 07e245e commit fff156b

11 files changed

Lines changed: 327 additions & 0 deletions

openapi/api.yaml

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20911,6 +20911,8 @@ components:
2091120911
default: 0
2091220912
net_terms_type:
2091320913
"$ref": "#/components/schemas/NetTermsTypeEnum"
20914+
credit_application_policy:
20915+
"$ref": "#/components/schemas/CreditApplicationPolicy"
2091420916
po_number:
2091520917
type: string
2091620918
title: Purchase order number
@@ -22507,6 +22509,19 @@ components:
2250722509
format: float
2250822510
title: Tax In Cents
2250922511
description: The tax converted to the currency.
22512+
rate:
22513+
type: string
22514+
title: Rate
22515+
description: The conversion rate to the currency.
22516+
source:
22517+
type: string
22518+
title: Source
22519+
description: The source of the conversion rate.
22520+
date:
22521+
type: string
22522+
title: Date
22523+
format: date
22524+
description: The date of the conversion rate.
2251022525
ShippingAddressCreate:
2251122526
type: object
2251222527
properties:
@@ -23125,6 +23140,8 @@ components:
2312523140
default: 0
2312623141
net_terms_type:
2312723142
"$ref": "#/components/schemas/NetTermsTypeEnum"
23143+
credit_application_policy:
23144+
"$ref": "#/components/schemas/CreditApplicationPolicy"
2312823145
terms_and_conditions:
2312923146
type: string
2313023147
title: Terms and conditions
@@ -23976,6 +23993,8 @@ components:
2397623993
default: 0
2397723994
net_terms_type:
2397823995
"$ref": "#/components/schemas/NetTermsTypeEnum"
23996+
credit_application_policy:
23997+
"$ref": "#/components/schemas/CreditApplicationPolicy"
2397923998
gateway_code:
2398023999
type: string
2398124000
title: Gateway Code
@@ -24107,6 +24126,8 @@ components:
2410724126
description: The new set of ramp intervals for the subscription.
2410824127
items:
2410924128
"$ref": "#/components/schemas/SubscriptionRampInterval"
24129+
credit_application_policy:
24130+
"$ref": "#/components/schemas/CreditApplicationPolicy"
2411024131
bulk:
2411124132
type: boolean
2411224133
description: Optional field to be used only when needing to bypass the 60
@@ -24195,6 +24216,8 @@ components:
2419524216
default: 0
2419624217
net_terms_type:
2419724218
"$ref": "#/components/schemas/NetTermsTypeEnum"
24219+
credit_application_policy:
24220+
"$ref": "#/components/schemas/CreditApplicationPolicy"
2419824221
gateway_code:
2419924222
type: string
2420024223
title: Gateway Code
@@ -25033,6 +25056,8 @@ components:
2503325056
default: 0
2503425057
net_terms_type:
2503525058
"$ref": "#/components/schemas/NetTermsTypeEnum"
25059+
credit_application_policy_override:
25060+
"$ref": "#/components/schemas/CreditApplicationPolicy"
2503625061
terms_and_conditions:
2503725062
type: string
2503825063
title: Terms and conditions
@@ -27038,6 +27063,28 @@ components:
2703827063
enum:
2703927064
- automatic
2704027065
- manual
27066+
CreditApplicationPolicy:
27067+
type: object
27068+
title: Credit Application Policy
27069+
description: |
27070+
Controls whether credit invoices are automatically applied to new invoices.
27071+
The `mode` field determines the application behavior.
27072+
properties:
27073+
mode:
27074+
"$ref": "#/components/schemas/CreditApplicationModeEnum"
27075+
required:
27076+
- mode
27077+
CreditApplicationModeEnum:
27078+
type: string
27079+
title: Credit Application Mode
27080+
description: |
27081+
Determines which credit invoices are applied to invoices:
27082+
- `all`: All available credit invoices are applied (default)
27083+
- `none`: No credit invoices are applied automatically
27084+
enum:
27085+
- all
27086+
- none
27087+
default: all
2704127088
InvoiceRefundTypeEnum:
2704227089
type: string
2704327090
enum:

src/main/java/com/recurly/v3/Constants.java

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -862,6 +862,17 @@ public enum CollectionMethod {
862862

863863
};
864864

865+
public enum CreditApplicationMode {
866+
UNDEFINED,
867+
868+
@SerializedName("all")
869+
ALL,
870+
871+
@SerializedName("none")
872+
NONE,
873+
874+
};
875+
865876
public enum InvoiceRefundType {
866877
UNDEFINED,
867878

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
/**
2+
* This file is automatically created by Recurly's OpenAPI generation process and thus any edits you
3+
* make by hand will be lost. If you wish to make a change to this file, please create a Github
4+
* issue explaining the changes you need and we will usher them to the appropriate places.
5+
*/
6+
package com.recurly.v3.requests;
7+
8+
import com.google.gson.annotations.Expose;
9+
import com.google.gson.annotations.SerializedName;
10+
import com.recurly.v3.Constants;
11+
import com.recurly.v3.Request;
12+
import com.recurly.v3.resources.*;
13+
14+
public class CreditApplicationPolicy extends Request {
15+
16+
/**
17+
* Determines which credit invoices are applied to invoices: - `all`: All available credit
18+
* invoices are applied (default) - `none`: No credit invoices are applied automatically
19+
*/
20+
@SerializedName("mode")
21+
@Expose
22+
private Constants.CreditApplicationMode mode;
23+
24+
/**
25+
* Determines which credit invoices are applied to invoices: - `all`: All available credit
26+
* invoices are applied (default) - `none`: No credit invoices are applied automatically
27+
*/
28+
public Constants.CreditApplicationMode getMode() {
29+
return this.mode;
30+
}
31+
32+
/**
33+
* @param mode Determines which credit invoices are applied to invoices: - `all`: All available
34+
* credit invoices are applied (default) - `none`: No credit invoices are applied
35+
* automatically
36+
*/
37+
public void setMode(final Constants.CreditApplicationMode mode) {
38+
this.mode = mode;
39+
}
40+
}

src/main/java/com/recurly/v3/requests/InvoiceCreate.java

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,14 @@ public class InvoiceCreate extends Request {
5252
@Expose
5353
private Constants.CollectionMethod collectionMethod;
5454

55+
/**
56+
* Controls whether credit invoices are automatically applied to new invoices. The `mode` field
57+
* determines the application behavior.
58+
*/
59+
@SerializedName("credit_application_policy")
60+
@Expose
61+
private CreditApplicationPolicy creditApplicationPolicy;
62+
5563
/**
5664
* This will default to the Customer Notes text specified on the Invoice Settings for credit
5765
* invoices. Specify customer notes to add or override Customer Notes on credit invoices.
@@ -204,6 +212,22 @@ public void setCollectionMethod(final Constants.CollectionMethod collectionMetho
204212
this.collectionMethod = collectionMethod;
205213
}
206214

215+
/**
216+
* Controls whether credit invoices are automatically applied to new invoices. The `mode` field
217+
* determines the application behavior.
218+
*/
219+
public CreditApplicationPolicy getCreditApplicationPolicy() {
220+
return this.creditApplicationPolicy;
221+
}
222+
223+
/**
224+
* @param creditApplicationPolicy Controls whether credit invoices are automatically applied to
225+
* new invoices. The `mode` field determines the application behavior.
226+
*/
227+
public void setCreditApplicationPolicy(final CreditApplicationPolicy creditApplicationPolicy) {
228+
this.creditApplicationPolicy = creditApplicationPolicy;
229+
}
230+
207231
/**
208232
* This will default to the Customer Notes text specified on the Invoice Settings for credit
209233
* invoices. Specify customer notes to add or override Customer Notes on credit invoices.

src/main/java/com/recurly/v3/requests/PurchaseCreate.java

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,14 @@ public class PurchaseCreate extends Request {
6464
@Expose
6565
private List<String> couponCodes;
6666

67+
/**
68+
* Controls whether credit invoices are automatically applied to new invoices. The `mode` field
69+
* determines the application behavior.
70+
*/
71+
@SerializedName("credit_application_policy_override")
72+
@Expose
73+
private CreditApplicationPolicy creditApplicationPolicyOverride;
74+
6775
/** Notes to be put on the credit invoice resulting from credits in the purchase, if any. */
6876
@SerializedName("credit_customer_notes")
6977
@Expose
@@ -277,6 +285,23 @@ public void setCouponCodes(final List<String> couponCodes) {
277285
this.couponCodes = couponCodes;
278286
}
279287

288+
/**
289+
* Controls whether credit invoices are automatically applied to new invoices. The `mode` field
290+
* determines the application behavior.
291+
*/
292+
public CreditApplicationPolicy getCreditApplicationPolicyOverride() {
293+
return this.creditApplicationPolicyOverride;
294+
}
295+
296+
/**
297+
* @param creditApplicationPolicyOverride Controls whether credit invoices are automatically
298+
* applied to new invoices. The `mode` field determines the application behavior.
299+
*/
300+
public void setCreditApplicationPolicyOverride(
301+
final CreditApplicationPolicy creditApplicationPolicyOverride) {
302+
this.creditApplicationPolicyOverride = creditApplicationPolicyOverride;
303+
}
304+
280305
/** Notes to be put on the credit invoice resulting from credits in the purchase, if any. */
281306
public String getCreditCustomerNotes() {
282307
return this.creditCustomerNotes;

src/main/java/com/recurly/v3/requests/SubscriptionCreate.java

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,14 @@ public class SubscriptionCreate extends Request {
8080
@Expose
8181
private List<String> couponCodes;
8282

83+
/**
84+
* Controls whether credit invoices are automatically applied to new invoices. The `mode` field
85+
* determines the application behavior.
86+
*/
87+
@SerializedName("credit_application_policy")
88+
@Expose
89+
private CreditApplicationPolicy creditApplicationPolicy;
90+
8391
/**
8492
* If there are pending credits on the account that will be invoiced during the subscription
8593
* creation, these will be used as the Customer Notes on the credit invoice.
@@ -428,6 +436,22 @@ public void setCouponCodes(final List<String> couponCodes) {
428436
this.couponCodes = couponCodes;
429437
}
430438

439+
/**
440+
* Controls whether credit invoices are automatically applied to new invoices. The `mode` field
441+
* determines the application behavior.
442+
*/
443+
public CreditApplicationPolicy getCreditApplicationPolicy() {
444+
return this.creditApplicationPolicy;
445+
}
446+
447+
/**
448+
* @param creditApplicationPolicy Controls whether credit invoices are automatically applied to
449+
* new invoices. The `mode` field determines the application behavior.
450+
*/
451+
public void setCreditApplicationPolicy(final CreditApplicationPolicy creditApplicationPolicy) {
452+
this.creditApplicationPolicy = creditApplicationPolicy;
453+
}
454+
431455
/**
432456
* If there are pending credits on the account that will be invoiced during the subscription
433457
* creation, these will be used as the Customer Notes on the credit invoice.

src/main/java/com/recurly/v3/requests/SubscriptionPurchase.java

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,14 @@ public class SubscriptionPurchase extends Request {
3434
@Expose
3535
private Boolean bulk;
3636

37+
/**
38+
* Controls whether credit invoices are automatically applied to new invoices. The `mode` field
39+
* determines the application behavior.
40+
*/
41+
@SerializedName("credit_application_policy")
42+
@Expose
43+
private CreditApplicationPolicy creditApplicationPolicy;
44+
3745
/**
3846
* The custom fields will only be altered when they are included in a request. Sending an empty
3947
* array will not remove any existing values. To remove a field send the name with a null or empty
@@ -187,6 +195,22 @@ public void setBulk(final Boolean bulk) {
187195
this.bulk = bulk;
188196
}
189197

198+
/**
199+
* Controls whether credit invoices are automatically applied to new invoices. The `mode` field
200+
* determines the application behavior.
201+
*/
202+
public CreditApplicationPolicy getCreditApplicationPolicy() {
203+
return this.creditApplicationPolicy;
204+
}
205+
206+
/**
207+
* @param creditApplicationPolicy Controls whether credit invoices are automatically applied to
208+
* new invoices. The `mode` field determines the application behavior.
209+
*/
210+
public void setCreditApplicationPolicy(final CreditApplicationPolicy creditApplicationPolicy) {
211+
this.creditApplicationPolicy = creditApplicationPolicy;
212+
}
213+
190214
/**
191215
* The custom fields will only be altered when they are included in a request. Sending an empty
192216
* array will not remove any existing values. To remove a field send the name with a null or empty

src/main/java/com/recurly/v3/requests/SubscriptionUpdate.java

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,14 @@ public class SubscriptionUpdate extends Request {
3535
@Expose
3636
private Constants.CollectionMethod collectionMethod;
3737

38+
/**
39+
* Controls whether credit invoices are automatically applied to new invoices. The `mode` field
40+
* determines the application behavior.
41+
*/
42+
@SerializedName("credit_application_policy")
43+
@Expose
44+
private CreditApplicationPolicy creditApplicationPolicy;
45+
3846
/**
3947
* The custom fields will only be altered when they are included in a request. Sending an empty
4048
* array will not remove any existing values. To remove a field send the name with a null or empty
@@ -190,6 +198,22 @@ public void setCollectionMethod(final Constants.CollectionMethod collectionMetho
190198
this.collectionMethod = collectionMethod;
191199
}
192200

201+
/**
202+
* Controls whether credit invoices are automatically applied to new invoices. The `mode` field
203+
* determines the application behavior.
204+
*/
205+
public CreditApplicationPolicy getCreditApplicationPolicy() {
206+
return this.creditApplicationPolicy;
207+
}
208+
209+
/**
210+
* @param creditApplicationPolicy Controls whether credit invoices are automatically applied to
211+
* new invoices. The `mode` field determines the application behavior.
212+
*/
213+
public void setCreditApplicationPolicy(final CreditApplicationPolicy creditApplicationPolicy) {
214+
this.creditApplicationPolicy = creditApplicationPolicy;
215+
}
216+
193217
/**
194218
* The custom fields will only be altered when they are included in a request. Sending an empty
195219
* array will not remove any existing values. To remove a field send the name with a null or empty
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
/**
2+
* This file is automatically created by Recurly's OpenAPI generation process and thus any edits you
3+
* make by hand will be lost. If you wish to make a change to this file, please create a Github
4+
* issue explaining the changes you need and we will usher them to the appropriate places.
5+
*/
6+
package com.recurly.v3.resources;
7+
8+
import com.google.gson.annotations.Expose;
9+
import com.google.gson.annotations.SerializedName;
10+
import com.recurly.v3.Constants;
11+
import com.recurly.v3.Resource;
12+
13+
public class CreditApplicationPolicy extends Resource {
14+
15+
/**
16+
* Determines which credit invoices are applied to invoices: - `all`: All available credit
17+
* invoices are applied (default) - `none`: No credit invoices are applied automatically
18+
*/
19+
@SerializedName("mode")
20+
@Expose
21+
private Constants.CreditApplicationMode mode;
22+
23+
/**
24+
* Determines which credit invoices are applied to invoices: - `all`: All available credit
25+
* invoices are applied (default) - `none`: No credit invoices are applied automatically
26+
*/
27+
public Constants.CreditApplicationMode getMode() {
28+
return this.mode;
29+
}
30+
31+
/**
32+
* @param mode Determines which credit invoices are applied to invoices: - `all`: All available
33+
* credit invoices are applied (default) - `none`: No credit invoices are applied
34+
* automatically
35+
*/
36+
public void setMode(final Constants.CreditApplicationMode mode) {
37+
this.mode = mode;
38+
}
39+
}

0 commit comments

Comments
 (0)