diff --git a/.release-please-manifest.json b/.release-please-manifest.json index c3ae3e4ab..18952c86a 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "0.379.0" + ".": "0.380.0" } \ No newline at end of file diff --git a/.stats.yml b/.stats.yml index beed026f6..989a349be 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 230 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/increase%2Fincrease-6b5ac6804e3261a05214c5891c95222ef1b5e9003f211ab32db1d03a7531835a.yml -openapi_spec_hash: 611c8d38ba7122a428f57f3069aac84a +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/increase%2Fincrease-e2b7de6202d48efc0e77fd72d2788987e6e3ecf2dfff8a491b88fe9a838f0bd5.yml +openapi_spec_hash: 5af8bcd38aae780c364688cb048d258b config_hash: ff2eb5f192b4de36611b37b27961c2d8 diff --git a/CHANGELOG.md b/CHANGELOG.md index d3cb295a5..bf2ed187c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,13 @@ # Changelog +## 0.380.0 (2025-12-15) + +Full Changelog: [v0.379.0...v0.380.0](https://github.com/Increase/increase-java/compare/v0.379.0...v0.380.0) + +### Features + +* **api:** api update ([e010cfe](https://github.com/Increase/increase-java/commit/e010cfecbadad5976c5d1afef0c783164e64260a)) + ## 0.379.0 (2025-12-15) Full Changelog: [v0.378.0...v0.379.0](https://github.com/Increase/increase-java/compare/v0.378.0...v0.379.0) diff --git a/README.md b/README.md index 795112bbc..9f878ca54 100644 --- a/README.md +++ b/README.md @@ -2,8 +2,8 @@ -[![Maven Central](https://img.shields.io/maven-central/v/com.increase.api/increase-java)](https://central.sonatype.com/artifact/com.increase.api/increase-java/0.379.0) -[![javadoc](https://javadoc.io/badge2/com.increase.api/increase-java/0.379.0/javadoc.svg)](https://javadoc.io/doc/com.increase.api/increase-java/0.379.0) +[![Maven Central](https://img.shields.io/maven-central/v/com.increase.api/increase-java)](https://central.sonatype.com/artifact/com.increase.api/increase-java/0.380.0) +[![javadoc](https://javadoc.io/badge2/com.increase.api/increase-java/0.380.0/javadoc.svg)](https://javadoc.io/doc/com.increase.api/increase-java/0.380.0) @@ -13,7 +13,7 @@ The Increase Java SDK is similar to the Increase Kotlin SDK but with minor diffe -The REST API documentation can be found on [increase.com](https://increase.com/documentation). Javadocs are available on [javadoc.io](https://javadoc.io/doc/com.increase.api/increase-java/0.379.0). +The REST API documentation can be found on [increase.com](https://increase.com/documentation). Javadocs are available on [javadoc.io](https://javadoc.io/doc/com.increase.api/increase-java/0.380.0). @@ -24,7 +24,7 @@ The REST API documentation can be found on [increase.com](https://increase.com/d ### Gradle ```kotlin -implementation("com.increase.api:increase-java:0.379.0") +implementation("com.increase.api:increase-java:0.380.0") ``` ### Maven @@ -33,7 +33,7 @@ implementation("com.increase.api:increase-java:0.379.0") com.increase.api increase-java - 0.379.0 + 0.380.0 ``` diff --git a/build.gradle.kts b/build.gradle.kts index 6956d85ca..9ceaf8edd 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -8,7 +8,7 @@ repositories { allprojects { group = "com.increase.api" - version = "0.379.0" // x-release-please-version + version = "0.380.0" // x-release-please-version } subprojects { diff --git a/increase-java-core/src/main/kotlin/com/increase/api/models/checktransfers/CheckTransfer.kt b/increase-java-core/src/main/kotlin/com/increase/api/models/checktransfers/CheckTransfer.kt index 3f67ec005..7e5b7cdfe 100644 --- a/increase-java-core/src/main/kotlin/com/increase/api/models/checktransfers/CheckTransfer.kt +++ b/increase-java-core/src/main/kotlin/com/increase/api/models/checktransfers/CheckTransfer.kt @@ -4629,6 +4629,7 @@ private constructor( private val line1: JsonField, private val line2: JsonField, private val name: JsonField, + private val phone: JsonField, private val postalCode: JsonField, private val state: JsonField, private val additionalProperties: MutableMap, @@ -4640,11 +4641,12 @@ private constructor( @JsonProperty("line1") @ExcludeMissing line1: JsonField = JsonMissing.of(), @JsonProperty("line2") @ExcludeMissing line2: JsonField = JsonMissing.of(), @JsonProperty("name") @ExcludeMissing name: JsonField = JsonMissing.of(), + @JsonProperty("phone") @ExcludeMissing phone: JsonField = JsonMissing.of(), @JsonProperty("postal_code") @ExcludeMissing postalCode: JsonField = JsonMissing.of(), @JsonProperty("state") @ExcludeMissing state: JsonField = JsonMissing.of(), - ) : this(city, line1, line2, name, postalCode, state, mutableMapOf()) + ) : this(city, line1, line2, name, phone, postalCode, state, mutableMapOf()) /** * The city of the check's destination. @@ -4678,6 +4680,15 @@ private constructor( */ fun name(): Optional = name.getOptional("name") + /** + * The shipper's phone number to be used in case of delivery issues. Only used for FedEx + * overnight shipping. + * + * @throws IncreaseInvalidDataException if the JSON field has an unexpected type (e.g. + * if the server responded with an unexpected value). + */ + fun phone(): Optional = phone.getOptional("phone") + /** * The postal code of the check's destination. * @@ -4722,6 +4733,13 @@ private constructor( */ @JsonProperty("name") @ExcludeMissing fun _name(): JsonField = name + /** + * Returns the raw JSON value of [phone]. + * + * Unlike [phone], this method doesn't throw if the JSON field has an unexpected type. + */ + @JsonProperty("phone") @ExcludeMissing fun _phone(): JsonField = phone + /** * Returns the raw JSON value of [postalCode]. * @@ -4762,6 +4780,7 @@ private constructor( * .line1() * .line2() * .name() + * .phone() * .postalCode() * .state() * ``` @@ -4776,6 +4795,7 @@ private constructor( private var line1: JsonField? = null private var line2: JsonField? = null private var name: JsonField? = null + private var phone: JsonField? = null private var postalCode: JsonField? = null private var state: JsonField? = null private var additionalProperties: MutableMap = mutableMapOf() @@ -4786,6 +4806,7 @@ private constructor( line1 = returnAddress.line1 line2 = returnAddress.line2 name = returnAddress.name + phone = returnAddress.phone postalCode = returnAddress.postalCode state = returnAddress.state additionalProperties = returnAddress.additionalProperties.toMutableMap() @@ -4851,6 +4872,24 @@ private constructor( */ fun name(name: JsonField) = apply { this.name = name } + /** + * The shipper's phone number to be used in case of delivery issues. Only used for + * FedEx overnight shipping. + */ + fun phone(phone: String?) = phone(JsonField.ofNullable(phone)) + + /** Alias for calling [Builder.phone] with `phone.orElse(null)`. */ + fun phone(phone: Optional) = phone(phone.getOrNull()) + + /** + * Sets [Builder.phone] to an arbitrary JSON value. + * + * You should usually call [Builder.phone] with a well-typed [String] value instead. + * This method is primarily for setting the field to an undocumented or not yet + * supported value. + */ + fun phone(phone: JsonField) = apply { this.phone = phone } + /** The postal code of the check's destination. */ fun postalCode(postalCode: String?) = postalCode(JsonField.ofNullable(postalCode)) @@ -4916,6 +4955,7 @@ private constructor( * .line1() * .line2() * .name() + * .phone() * .postalCode() * .state() * ``` @@ -4928,6 +4968,7 @@ private constructor( checkRequired("line1", line1), checkRequired("line2", line2), checkRequired("name", name), + checkRequired("phone", phone), checkRequired("postalCode", postalCode), checkRequired("state", state), additionalProperties.toMutableMap(), @@ -4945,6 +4986,7 @@ private constructor( line1() line2() name() + phone() postalCode() state() validated = true @@ -4970,6 +5012,7 @@ private constructor( (if (line1.asKnown().isPresent) 1 else 0) + (if (line2.asKnown().isPresent) 1 else 0) + (if (name.asKnown().isPresent) 1 else 0) + + (if (phone.asKnown().isPresent) 1 else 0) + (if (postalCode.asKnown().isPresent) 1 else 0) + (if (state.asKnown().isPresent) 1 else 0) @@ -4983,19 +5026,29 @@ private constructor( line1 == other.line1 && line2 == other.line2 && name == other.name && + phone == other.phone && postalCode == other.postalCode && state == other.state && additionalProperties == other.additionalProperties } private val hashCode: Int by lazy { - Objects.hash(city, line1, line2, name, postalCode, state, additionalProperties) + Objects.hash( + city, + line1, + line2, + name, + phone, + postalCode, + state, + additionalProperties, + ) } override fun hashCode(): Int = hashCode override fun toString() = - "ReturnAddress{city=$city, line1=$line1, line2=$line2, name=$name, postalCode=$postalCode, state=$state, additionalProperties=$additionalProperties}" + "ReturnAddress{city=$city, line1=$line1, line2=$line2, name=$name, phone=$phone, postalCode=$postalCode, state=$state, additionalProperties=$additionalProperties}" } /** The shipping method for the check. */ diff --git a/increase-java-core/src/main/kotlin/com/increase/api/models/checktransfers/CheckTransferCreateParams.kt b/increase-java-core/src/main/kotlin/com/increase/api/models/checktransfers/CheckTransferCreateParams.kt index 61b29052c..46a32103f 100644 --- a/increase-java-core/src/main/kotlin/com/increase/api/models/checktransfers/CheckTransferCreateParams.kt +++ b/increase-java-core/src/main/kotlin/com/increase/api/models/checktransfers/CheckTransferCreateParams.kt @@ -2122,9 +2122,9 @@ private constructor( fun name(): Optional = name.getOptional("name") /** - * The phone number to associate with the check's destination address. The number is - * only used when `shipping_method` is `fedex_overnight` and will be supplied to FedEx - * to be used in case of delivery issues. + * The phone number to associate with the check's destination address. The phone number + * is only used when `shipping_method` is `fedex_overnight` and will be supplied to + * FedEx to be used in case of delivery issues. * * @throws IncreaseInvalidDataException if the JSON field has an unexpected type (e.g. * if the server responded with an unexpected value). @@ -2313,9 +2313,9 @@ private constructor( fun name(name: JsonField) = apply { this.name = name } /** - * The phone number to associate with the check's destination address. The number is - * only used when `shipping_method` is `fedex_overnight` and will be supplied to - * FedEx to be used in case of delivery issues. + * The phone number to associate with the check's destination address. The phone + * number is only used when `shipping_method` is `fedex_overnight` and will be + * supplied to FedEx to be used in case of delivery issues. */ fun phone(phone: String) = phone(JsonField.of(phone)) @@ -2631,6 +2631,7 @@ private constructor( private val postalCode: JsonField, private val state: JsonField, private val line2: JsonField, + private val phone: JsonField, private val additionalProperties: MutableMap, ) { @@ -2644,7 +2645,8 @@ private constructor( postalCode: JsonField = JsonMissing.of(), @JsonProperty("state") @ExcludeMissing state: JsonField = JsonMissing.of(), @JsonProperty("line2") @ExcludeMissing line2: JsonField = JsonMissing.of(), - ) : this(city, line1, name, postalCode, state, line2, mutableMapOf()) + @JsonProperty("phone") @ExcludeMissing phone: JsonField = JsonMissing.of(), + ) : this(city, line1, name, postalCode, state, line2, phone, mutableMapOf()) /** * The city of the return address. @@ -2699,6 +2701,16 @@ private constructor( */ fun line2(): Optional = line2.getOptional("line2") + /** + * The phone number to associate with the shipper. The phone number is only used when + * `shipping_method` is `fedex_overnight` and will be supplied to FedEx to be used in + * case of delivery issues. + * + * @throws IncreaseInvalidDataException if the JSON field has an unexpected type (e.g. + * if the server responded with an unexpected value). + */ + fun phone(): Optional = phone.getOptional("phone") + /** * Returns the raw JSON value of [city]. * @@ -2744,6 +2756,13 @@ private constructor( */ @JsonProperty("line2") @ExcludeMissing fun _line2(): JsonField = line2 + /** + * Returns the raw JSON value of [phone]. + * + * Unlike [phone], this method doesn't throw if the JSON field has an unexpected type. + */ + @JsonProperty("phone") @ExcludeMissing fun _phone(): JsonField = phone + @JsonAnySetter private fun putAdditionalProperty(key: String, value: JsonValue) { additionalProperties.put(key, value) @@ -2782,6 +2801,7 @@ private constructor( private var postalCode: JsonField? = null private var state: JsonField? = null private var line2: JsonField = JsonMissing.of() + private var phone: JsonField = JsonMissing.of() private var additionalProperties: MutableMap = mutableMapOf() @JvmSynthetic @@ -2792,6 +2812,7 @@ private constructor( postalCode = returnAddress.postalCode state = returnAddress.state line2 = returnAddress.line2 + phone = returnAddress.phone additionalProperties = returnAddress.additionalProperties.toMutableMap() } @@ -2869,6 +2890,22 @@ private constructor( */ fun line2(line2: JsonField) = apply { this.line2 = line2 } + /** + * The phone number to associate with the shipper. The phone number is only used + * when `shipping_method` is `fedex_overnight` and will be supplied to FedEx to be + * used in case of delivery issues. + */ + fun phone(phone: String) = phone(JsonField.of(phone)) + + /** + * Sets [Builder.phone] to an arbitrary JSON value. + * + * You should usually call [Builder.phone] with a well-typed [String] value instead. + * This method is primarily for setting the field to an undocumented or not yet + * supported value. + */ + fun phone(phone: JsonField) = apply { this.phone = phone } + fun additionalProperties(additionalProperties: Map) = apply { this.additionalProperties.clear() putAllAdditionalProperties(additionalProperties) @@ -2915,6 +2952,7 @@ private constructor( checkRequired("postalCode", postalCode), checkRequired("state", state), line2, + phone, additionalProperties.toMutableMap(), ) } @@ -2932,6 +2970,7 @@ private constructor( postalCode() state() line2() + phone() validated = true } @@ -2956,7 +2995,8 @@ private constructor( (if (name.asKnown().isPresent) 1 else 0) + (if (postalCode.asKnown().isPresent) 1 else 0) + (if (state.asKnown().isPresent) 1 else 0) + - (if (line2.asKnown().isPresent) 1 else 0) + (if (line2.asKnown().isPresent) 1 else 0) + + (if (phone.asKnown().isPresent) 1 else 0) override fun equals(other: Any?): Boolean { if (this === other) { @@ -2970,17 +3010,27 @@ private constructor( postalCode == other.postalCode && state == other.state && line2 == other.line2 && + phone == other.phone && additionalProperties == other.additionalProperties } private val hashCode: Int by lazy { - Objects.hash(city, line1, name, postalCode, state, line2, additionalProperties) + Objects.hash( + city, + line1, + name, + postalCode, + state, + line2, + phone, + additionalProperties, + ) } override fun hashCode(): Int = hashCode override fun toString() = - "ReturnAddress{city=$city, line1=$line1, name=$name, postalCode=$postalCode, state=$state, line2=$line2, additionalProperties=$additionalProperties}" + "ReturnAddress{city=$city, line1=$line1, name=$name, postalCode=$postalCode, state=$state, line2=$line2, phone=$phone, additionalProperties=$additionalProperties}" } /** diff --git a/increase-java-core/src/test/kotlin/com/increase/api/models/checktransfers/CheckTransferCreateParamsTest.kt b/increase-java-core/src/test/kotlin/com/increase/api/models/checktransfers/CheckTransferCreateParamsTest.kt index 541cdc3b9..43751b33b 100644 --- a/increase-java-core/src/test/kotlin/com/increase/api/models/checktransfers/CheckTransferCreateParamsTest.kt +++ b/increase-java-core/src/test/kotlin/com/increase/api/models/checktransfers/CheckTransferCreateParamsTest.kt @@ -48,6 +48,7 @@ internal class CheckTransferCreateParamsTest { .postalCode("x") .state("x") .line2("x") + .phone("x") .build() ) .shippingMethod( @@ -103,6 +104,7 @@ internal class CheckTransferCreateParamsTest { .postalCode("x") .state("x") .line2("x") + .phone("x") .build() ) .shippingMethod( @@ -159,6 +161,7 @@ internal class CheckTransferCreateParamsTest { .postalCode("x") .state("x") .line2("x") + .phone("x") .build() ) .shippingMethod( diff --git a/increase-java-core/src/test/kotlin/com/increase/api/models/checktransfers/CheckTransferListPageResponseTest.kt b/increase-java-core/src/test/kotlin/com/increase/api/models/checktransfers/CheckTransferListPageResponseTest.kt index 12480a8d6..e127df55b 100644 --- a/increase-java-core/src/test/kotlin/com/increase/api/models/checktransfers/CheckTransferListPageResponseTest.kt +++ b/increase-java-core/src/test/kotlin/com/increase/api/models/checktransfers/CheckTransferListPageResponseTest.kt @@ -77,7 +77,7 @@ internal class CheckTransferListPageResponseTest { .line1("33 Liberty Street") .line2(null) .name("Ian Crease") - .phone(null) + .phone("+16505046304") .postalCode("10045") .state("NY") .build() @@ -104,6 +104,7 @@ internal class CheckTransferListPageResponseTest { .line1("33 Liberty Street") .line2(null) .name("Ian Crease") + .phone("+16505046304") .postalCode("10045") .state("NY") .build() @@ -232,7 +233,7 @@ internal class CheckTransferListPageResponseTest { .line1("33 Liberty Street") .line2(null) .name("Ian Crease") - .phone(null) + .phone("+16505046304") .postalCode("10045") .state("NY") .build() @@ -259,6 +260,7 @@ internal class CheckTransferListPageResponseTest { .line1("33 Liberty Street") .line2(null) .name("Ian Crease") + .phone("+16505046304") .postalCode("10045") .state("NY") .build() @@ -387,7 +389,7 @@ internal class CheckTransferListPageResponseTest { .line1("33 Liberty Street") .line2(null) .name("Ian Crease") - .phone(null) + .phone("+16505046304") .postalCode("10045") .state("NY") .build() @@ -414,6 +416,7 @@ internal class CheckTransferListPageResponseTest { .line1("33 Liberty Street") .line2(null) .name("Ian Crease") + .phone("+16505046304") .postalCode("10045") .state("NY") .build() diff --git a/increase-java-core/src/test/kotlin/com/increase/api/models/checktransfers/CheckTransferTest.kt b/increase-java-core/src/test/kotlin/com/increase/api/models/checktransfers/CheckTransferTest.kt index 23ef72d5f..e5e8af8f3 100644 --- a/increase-java-core/src/test/kotlin/com/increase/api/models/checktransfers/CheckTransferTest.kt +++ b/increase-java-core/src/test/kotlin/com/increase/api/models/checktransfers/CheckTransferTest.kt @@ -71,7 +71,7 @@ internal class CheckTransferTest { .line1("33 Liberty Street") .line2(null) .name("Ian Crease") - .phone(null) + .phone("+16505046304") .postalCode("10045") .state("NY") .build() @@ -98,6 +98,7 @@ internal class CheckTransferTest { .line1("33 Liberty Street") .line2(null) .name("Ian Crease") + .phone("+16505046304") .postalCode("10045") .state("NY") .build() @@ -216,7 +217,7 @@ internal class CheckTransferTest { .line1("33 Liberty Street") .line2(null) .name("Ian Crease") - .phone(null) + .phone("+16505046304") .postalCode("10045") .state("NY") .build() @@ -243,6 +244,7 @@ internal class CheckTransferTest { .line1("33 Liberty Street") .line2(null) .name("Ian Crease") + .phone("+16505046304") .postalCode("10045") .state("NY") .build() @@ -360,7 +362,7 @@ internal class CheckTransferTest { .line1("33 Liberty Street") .line2(null) .name("Ian Crease") - .phone(null) + .phone("+16505046304") .postalCode("10045") .state("NY") .build() @@ -387,6 +389,7 @@ internal class CheckTransferTest { .line1("33 Liberty Street") .line2(null) .name("Ian Crease") + .phone("+16505046304") .postalCode("10045") .state("NY") .build() diff --git a/increase-java-core/src/test/kotlin/com/increase/api/services/async/CheckTransferServiceAsyncTest.kt b/increase-java-core/src/test/kotlin/com/increase/api/services/async/CheckTransferServiceAsyncTest.kt index fc4c2180d..db2d3ec70 100644 --- a/increase-java-core/src/test/kotlin/com/increase/api/services/async/CheckTransferServiceAsyncTest.kt +++ b/increase-java-core/src/test/kotlin/com/increase/api/services/async/CheckTransferServiceAsyncTest.kt @@ -62,6 +62,7 @@ internal class CheckTransferServiceAsyncTest { .postalCode("x") .state("x") .line2("x") + .phone("x") .build() ) .shippingMethod( diff --git a/increase-java-core/src/test/kotlin/com/increase/api/services/blocking/CheckTransferServiceTest.kt b/increase-java-core/src/test/kotlin/com/increase/api/services/blocking/CheckTransferServiceTest.kt index d1755c695..68e50c46b 100644 --- a/increase-java-core/src/test/kotlin/com/increase/api/services/blocking/CheckTransferServiceTest.kt +++ b/increase-java-core/src/test/kotlin/com/increase/api/services/blocking/CheckTransferServiceTest.kt @@ -62,6 +62,7 @@ internal class CheckTransferServiceTest { .postalCode("x") .state("x") .line2("x") + .phone("x") .build() ) .shippingMethod(