diff --git a/.release-please-manifest.json b/.release-please-manifest.json
index 6db19b95..4ad3fef3 100644
--- a/.release-please-manifest.json
+++ b/.release-please-manifest.json
@@ -1,3 +1,3 @@
{
- ".": "0.17.0"
+ ".": "0.18.0"
}
\ No newline at end of file
diff --git a/.stats.yml b/.stats.yml
index 7dd05a09..c4326132 100644
--- a/.stats.yml
+++ b/.stats.yml
@@ -1,2 +1,2 @@
configured_endpoints: 101
-openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/orb%2Forb-52bd3046e73f201c4d08edfa92756791c015be907691a7893f8e7782cc2aea6f.yml
+openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/orb%2Forb-b6d60f8edbdc94e65f06b0b002cc8e1f27aceccc67917bea849425701ba82fb8.yml
diff --git a/CHANGELOG.md b/CHANGELOG.md
index a522676e..7ea7cb79 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,5 +1,13 @@
# Changelog
+## 0.18.0 (2025-01-06)
+
+Full Changelog: [v0.17.0...v0.18.0](https://github.com/orbcorp/orb-java/compare/v0.17.0...v0.18.0)
+
+### Features
+
+* **api:** api update ([#174](https://github.com/orbcorp/orb-java/issues/174)) ([61c6949](https://github.com/orbcorp/orb-java/commit/61c6949cf074b8467e46af430f4c60636a147bc0))
+
## 0.17.0 (2025-01-03)
Full Changelog: [v0.16.0...v0.17.0](https://github.com/orbcorp/orb-java/compare/v0.16.0...v0.17.0)
diff --git a/README.md b/README.md
index bcde54e2..02ce69eb 100644
--- a/README.md
+++ b/README.md
@@ -2,7 +2,7 @@
-[](https://central.sonatype.com/artifact/com.withorb.api/orb-java/0.17.0)
+[](https://central.sonatype.com/artifact/com.withorb.api/orb-java/0.18.0)
@@ -25,7 +25,7 @@ The REST API documentation can be foundĀ on [docs.withorb.com](https://docs.with
```kotlin
-implementation("com.withorb.api:orb-java:0.17.0")
+implementation("com.withorb.api:orb-java:0.18.0")
```
#### Maven
@@ -34,7 +34,7 @@ implementation("com.withorb.api:orb-java:0.17.0")
com.withorb.api
orb-java
- 0.17.0
+ 0.18.0
```
diff --git a/build.gradle.kts b/build.gradle.kts
index 26a41426..42210ec6 100644
--- a/build.gradle.kts
+++ b/build.gradle.kts
@@ -4,7 +4,7 @@ plugins {
allprojects {
group = "com.withorb.api"
- version = "0.17.0" // x-release-please-version
+ version = "0.18.0" // x-release-please-version
}
diff --git a/orb-java-core/src/main/kotlin/com/withorb/api/models/Invoice.kt b/orb-java-core/src/main/kotlin/com/withorb/api/models/Invoice.kt
index 32ed4df8..d1470fa7 100644
--- a/orb-java-core/src/main/kotlin/com/withorb/api/models/Invoice.kt
+++ b/orb-java-core/src/main/kotlin/com/withorb/api/models/Invoice.kt
@@ -237,8 +237,10 @@ private constructor(
fun discounts(): List = discounts.getRequired("discounts")
- /** When the invoice payment is due. */
- fun dueDate(): OffsetDateTime = dueDate.getRequired("due_date")
+ /**
+ * When the invoice payment is due. The due date is null if the invoice is not yet finalized.
+ */
+ fun dueDate(): Optional = Optional.ofNullable(dueDate.getNullable("due_date"))
fun id(): String = id.getRequired("id")
@@ -503,7 +505,9 @@ private constructor(
@JsonProperty("discounts") @ExcludeMissing fun _discounts() = discounts
- /** When the invoice payment is due. */
+ /**
+ * When the invoice payment is due. The due date is null if the invoice is not yet finalized.
+ */
@JsonProperty("due_date") @ExcludeMissing fun _dueDate() = dueDate
@JsonProperty("id") @ExcludeMissing fun _id() = id
@@ -1011,10 +1015,16 @@ private constructor(
this.discounts = discounts
}
- /** When the invoice payment is due. */
+ /**
+ * When the invoice payment is due. The due date is null if the invoice is not yet
+ * finalized.
+ */
fun dueDate(dueDate: OffsetDateTime) = dueDate(JsonField.of(dueDate))
- /** When the invoice payment is due. */
+ /**
+ * When the invoice payment is due. The due date is null if the invoice is not yet
+ * finalized.
+ */
fun dueDate(dueDate: JsonField) = apply { this.dueDate = dueDate }
fun id(id: String) = id(JsonField.of(id))
diff --git a/orb-java-core/src/main/kotlin/com/withorb/api/models/InvoiceFetchUpcomingResponse.kt b/orb-java-core/src/main/kotlin/com/withorb/api/models/InvoiceFetchUpcomingResponse.kt
index 603079a1..83801157 100644
--- a/orb-java-core/src/main/kotlin/com/withorb/api/models/InvoiceFetchUpcomingResponse.kt
+++ b/orb-java-core/src/main/kotlin/com/withorb/api/models/InvoiceFetchUpcomingResponse.kt
@@ -230,8 +230,10 @@ private constructor(
fun discounts(): List = discounts.getRequired("discounts")
- /** When the invoice payment is due. */
- fun dueDate(): OffsetDateTime = dueDate.getRequired("due_date")
+ /**
+ * When the invoice payment is due. The due date is null if the invoice is not yet finalized.
+ */
+ fun dueDate(): Optional = Optional.ofNullable(dueDate.getNullable("due_date"))
fun id(): String = id.getRequired("id")
@@ -496,7 +498,9 @@ private constructor(
@JsonProperty("discounts") @ExcludeMissing fun _discounts() = discounts
- /** When the invoice payment is due. */
+ /**
+ * When the invoice payment is due. The due date is null if the invoice is not yet finalized.
+ */
@JsonProperty("due_date") @ExcludeMissing fun _dueDate() = dueDate
@JsonProperty("id") @ExcludeMissing fun _id() = id
@@ -1004,10 +1008,16 @@ private constructor(
this.discounts = discounts
}
- /** When the invoice payment is due. */
+ /**
+ * When the invoice payment is due. The due date is null if the invoice is not yet
+ * finalized.
+ */
fun dueDate(dueDate: OffsetDateTime) = dueDate(JsonField.of(dueDate))
- /** When the invoice payment is due. */
+ /**
+ * When the invoice payment is due. The due date is null if the invoice is not yet
+ * finalized.
+ */
fun dueDate(dueDate: JsonField) = apply { this.dueDate = dueDate }
fun id(id: String) = id(JsonField.of(id))
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceFetchUpcomingResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceFetchUpcomingResponseTest.kt
index c07c0a7b..81cca665 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceFetchUpcomingResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceFetchUpcomingResponseTest.kt
@@ -455,7 +455,7 @@ class InvoiceFetchUpcomingResponseTest {
)
)
assertThat(invoiceFetchUpcomingResponse.dueDate())
- .isEqualTo(OffsetDateTime.parse("2022-05-30T07:00:00+00:00"))
+ .contains(OffsetDateTime.parse("2022-05-30T07:00:00+00:00"))
assertThat(invoiceFetchUpcomingResponse.eligibleToIssueAt())
.contains(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
assertThat(invoiceFetchUpcomingResponse.hostedInvoiceUrl()).contains("hosted_invoice_url")
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceTest.kt
index 978faec7..a15c40ba 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceTest.kt
@@ -423,7 +423,7 @@ class InvoiceTest {
.build()
)
)
- assertThat(invoice.dueDate()).isEqualTo(OffsetDateTime.parse("2022-05-30T07:00:00+00:00"))
+ assertThat(invoice.dueDate()).contains(OffsetDateTime.parse("2022-05-30T07:00:00+00:00"))
assertThat(invoice.eligibleToIssueAt())
.contains(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
assertThat(invoice.hostedInvoiceUrl()).contains("hosted_invoice_url")