Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
".": "0.166.0"
".": "0.167.0"
}
2 changes: 1 addition & 1 deletion .stats.yml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
configured_endpoints: 201
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/increase%2Fincrease-936415a7c13aa6a9b75c94e06d628346ea373e89a34c5f4281dbfd68a5114b3c.yml
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/increase%2Fincrease-97fb48534a75d68acd544082e2352e69557d798f912cf62c85825e78d9102eca.yml
13 changes: 13 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,18 @@
# Changelog

## 0.167.0 (2025-01-27)

Full Changelog: [v0.166.0...v0.167.0](https://github.com/Increase/increase-java/compare/v0.166.0...v0.167.0)

### Features

* **api:** api update ([#724](https://github.com/Increase/increase-java/issues/724)) ([d53c7fe](https://github.com/Increase/increase-java/commit/d53c7fe79ec352f4ba575ca412710b6b6278aff9))


### Documentation

* builder, enum, and union comments ([#722](https://github.com/Increase/increase-java/issues/722)) ([09e5ad9](https://github.com/Increase/increase-java/commit/09e5ad906227c3942bedf48101438e3c7ca6bf71))

## 0.166.0 (2025-01-27)

Full Changelog: [v0.165.0...v0.166.0](https://github.com/Increase/increase-java/compare/v0.165.0...v0.166.0)
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<!-- x-release-please-start-version -->

[![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.166.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.167.0)

<!-- x-release-please-end -->

Expand All @@ -19,7 +19,7 @@ The REST API documentation can be found on [increase.com](https://increase.com/d
### Gradle

```kotlin
implementation("com.increase.api:increase-java:0.166.0")
implementation("com.increase.api:increase-java:0.167.0")
```

### Maven
Expand All @@ -28,7 +28,7 @@ implementation("com.increase.api:increase-java:0.166.0")
<dependency>
<groupId>com.increase.api</groupId>
<artifactId>increase-java</artifactId>
<version>0.166.0</version>
<version>0.167.0</version>
</dependency>
```

Expand Down
2 changes: 1 addition & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
allprojects {
group = "com.increase.api"
version = "0.166.0" // x-release-please-version
version = "0.167.0" // x-release-please-version
}
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ class IncreaseOkHttpClient private constructor() {
@JvmStatic fun fromEnv(): IncreaseClient = builder().fromEnv().build()
}

/** A builder for [IncreaseOkHttpClient]. */
class Builder internal constructor() {

private var clientOptions: ClientOptions.Builder = ClientOptions.builder()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ class IncreaseOkHttpClientAsync private constructor() {
@JvmStatic fun fromEnv(): IncreaseClientAsync = builder().fromEnv().build()
}

/** A builder for [IncreaseOkHttpClientAsync]. */
class Builder internal constructor() {

private var clientOptions: ClientOptions.Builder = ClientOptions.builder()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ private constructor(
@JvmStatic fun fromEnv(): ClientOptions = builder().fromEnv().build()
}

/** A builder for [ClientOptions]. */
class Builder internal constructor() {

private var httpClient: HttpClient? = null
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ private constructor(
@JvmStatic fun builder() = Builder()
}

/** A builder for [IncreaseError]. */
class Builder internal constructor() {

private var additionalProperties: MutableMap<String, JsonValue> = mutableMapOf()
Expand Down
141 changes: 141 additions & 0 deletions increase-java-core/src/main/kotlin/com/increase/api/models/Account.kt
Original file line number Diff line number Diff line change
Expand Up @@ -257,6 +257,7 @@ private constructor(
@JvmStatic fun builder() = Builder()
}

/** A builder for [Account]. */
class Builder internal constructor() {

private var id: JsonField<String>? = null
Expand Down Expand Up @@ -532,6 +533,14 @@ private constructor(
private val value: JsonField<String>,
) : Enum {

/**
* Returns this class instance's raw value.
*
* This is usually only useful if this instance was deserialized from data that doesn't
* match any known member, and you want to know that value. For example, if the SDK is on an
* older version than the API, then the API may respond with new members that the SDK is
* unaware of.
*/
@com.fasterxml.jackson.annotation.JsonValue fun _value(): JsonField<String> = value

companion object {
Expand All @@ -548,6 +557,7 @@ private constructor(
@JvmStatic fun of(value: String) = Bank(JsonField.of(value))
}

/** An enum containing [Bank]'s known values. */
enum class Known {
/** Blue Ridge Bank, N.A. */
BLUE_RIDGE_BANK,
Expand All @@ -557,16 +567,33 @@ private constructor(
GRASSHOPPER_BANK,
}

/**
* An enum containing [Bank]'s known values, as well as an [_UNKNOWN] member.
*
* An instance of [Bank] can contain an unknown value in a couple of cases:
* - It was deserialized from data that doesn't match any known member. For example, if the
* SDK is on an older version than the API, then the API may respond with new members that
* the SDK is unaware of.
* - It was constructed with an arbitrary value using the [of] method.
*/
enum class Value {
/** Blue Ridge Bank, N.A. */
BLUE_RIDGE_BANK,
/** First Internet Bank of Indiana */
FIRST_INTERNET_BANK,
/** Grasshopper Bank */
GRASSHOPPER_BANK,
/** An enum member indicating that [Bank] was instantiated with an unknown value. */
_UNKNOWN,
}

/**
* Returns an enum member corresponding to this class instance's value, or [Value._UNKNOWN]
* if the class was instantiated with an unknown value.
*
* Use the [known] method instead if you're certain the value is always known or if you want
* to throw for the unknown case.
*/
fun value(): Value =
when (this) {
BLUE_RIDGE_BANK -> Value.BLUE_RIDGE_BANK
Expand All @@ -575,6 +602,15 @@ private constructor(
else -> Value._UNKNOWN
}

/**
* Returns an enum member corresponding to this class instance's value.
*
* Use the [value] method instead if you're uncertain the value is always known and don't
* want to throw for the unknown case.
*
* @throws IncreaseInvalidDataException if this class instance's value is a not a known
* member.
*/
fun known(): Known =
when (this) {
BLUE_RIDGE_BANK -> Known.BLUE_RIDGE_BANK
Expand Down Expand Up @@ -605,6 +641,14 @@ private constructor(
private val value: JsonField<String>,
) : Enum {

/**
* Returns this class instance's raw value.
*
* This is usually only useful if this instance was deserialized from data that doesn't
* match any known member, and you want to know that value. For example, if the SDK is on an
* older version than the API, then the API may respond with new members that the SDK is
* unaware of.
*/
@com.fasterxml.jackson.annotation.JsonValue fun _value(): JsonField<String> = value

companion object {
Expand All @@ -630,6 +674,7 @@ private constructor(
@JvmStatic fun of(value: String) = Currency(JsonField.of(value))
}

/** An enum containing [Currency]'s known values. */
enum class Known {
/** Canadian Dollar (CAD) */
CAD,
Expand All @@ -645,6 +690,15 @@ private constructor(
USD,
}

/**
* An enum containing [Currency]'s known values, as well as an [_UNKNOWN] member.
*
* An instance of [Currency] can contain an unknown value in a couple of cases:
* - It was deserialized from data that doesn't match any known member. For example, if the
* SDK is on an older version than the API, then the API may respond with new members that
* the SDK is unaware of.
* - It was constructed with an arbitrary value using the [of] method.
*/
enum class Value {
/** Canadian Dollar (CAD) */
CAD,
Expand All @@ -658,9 +712,17 @@ private constructor(
JPY,
/** US Dollar (USD) */
USD,
/** An enum member indicating that [Currency] was instantiated with an unknown value. */
_UNKNOWN,
}

/**
* Returns an enum member corresponding to this class instance's value, or [Value._UNKNOWN]
* if the class was instantiated with an unknown value.
*
* Use the [known] method instead if you're certain the value is always known or if you want
* to throw for the unknown case.
*/
fun value(): Value =
when (this) {
CAD -> Value.CAD
Expand All @@ -672,6 +734,15 @@ private constructor(
else -> Value._UNKNOWN
}

/**
* Returns an enum member corresponding to this class instance's value.
*
* Use the [value] method instead if you're uncertain the value is always known and don't
* want to throw for the unknown case.
*
* @throws IncreaseInvalidDataException if this class instance's value is a not a known
* member.
*/
fun known(): Known =
when (this) {
CAD -> Known.CAD
Expand Down Expand Up @@ -705,6 +776,14 @@ private constructor(
private val value: JsonField<String>,
) : Enum {

/**
* Returns this class instance's raw value.
*
* This is usually only useful if this instance was deserialized from data that doesn't
* match any known member, and you want to know that value. For example, if the SDK is on an
* older version than the API, then the API may respond with new members that the SDK is
* unaware of.
*/
@com.fasterxml.jackson.annotation.JsonValue fun _value(): JsonField<String> = value

companion object {
Expand All @@ -718,28 +797,55 @@ private constructor(
@JvmStatic fun of(value: String) = Status(JsonField.of(value))
}

/** An enum containing [Status]'s known values. */
enum class Known {
/** Closed Accounts on which no new activity can occur. */
CLOSED,
/** Open Accounts that are ready to use. */
OPEN,
}

/**
* An enum containing [Status]'s known values, as well as an [_UNKNOWN] member.
*
* An instance of [Status] can contain an unknown value in a couple of cases:
* - It was deserialized from data that doesn't match any known member. For example, if the
* SDK is on an older version than the API, then the API may respond with new members that
* the SDK is unaware of.
* - It was constructed with an arbitrary value using the [of] method.
*/
enum class Value {
/** Closed Accounts on which no new activity can occur. */
CLOSED,
/** Open Accounts that are ready to use. */
OPEN,
/** An enum member indicating that [Status] was instantiated with an unknown value. */
_UNKNOWN,
}

/**
* Returns an enum member corresponding to this class instance's value, or [Value._UNKNOWN]
* if the class was instantiated with an unknown value.
*
* Use the [known] method instead if you're certain the value is always known or if you want
* to throw for the unknown case.
*/
fun value(): Value =
when (this) {
CLOSED -> Value.CLOSED
OPEN -> Value.OPEN
else -> Value._UNKNOWN
}

/**
* Returns an enum member corresponding to this class instance's value.
*
* Use the [value] method instead if you're uncertain the value is always known and don't
* want to throw for the unknown case.
*
* @throws IncreaseInvalidDataException if this class instance's value is a not a known
* member.
*/
fun known(): Known =
when (this) {
CLOSED -> Known.CLOSED
Expand Down Expand Up @@ -769,6 +875,14 @@ private constructor(
private val value: JsonField<String>,
) : Enum {

/**
* Returns this class instance's raw value.
*
* This is usually only useful if this instance was deserialized from data that doesn't
* match any known member, and you want to know that value. For example, if the SDK is on an
* older version than the API, then the API may respond with new members that the SDK is
* unaware of.
*/
@com.fasterxml.jackson.annotation.JsonValue fun _value(): JsonField<String> = value

companion object {
Expand All @@ -778,21 +892,48 @@ private constructor(
@JvmStatic fun of(value: String) = Type(JsonField.of(value))
}

/** An enum containing [Type]'s known values. */
enum class Known {
ACCOUNT,
}

/**
* An enum containing [Type]'s known values, as well as an [_UNKNOWN] member.
*
* An instance of [Type] can contain an unknown value in a couple of cases:
* - It was deserialized from data that doesn't match any known member. For example, if the
* SDK is on an older version than the API, then the API may respond with new members that
* the SDK is unaware of.
* - It was constructed with an arbitrary value using the [of] method.
*/
enum class Value {
ACCOUNT,
/** An enum member indicating that [Type] was instantiated with an unknown value. */
_UNKNOWN,
}

/**
* Returns an enum member corresponding to this class instance's value, or [Value._UNKNOWN]
* if the class was instantiated with an unknown value.
*
* Use the [known] method instead if you're certain the value is always known or if you want
* to throw for the unknown case.
*/
fun value(): Value =
when (this) {
ACCOUNT -> Value.ACCOUNT
else -> Value._UNKNOWN
}

/**
* Returns an enum member corresponding to this class instance's value.
*
* Use the [value] method instead if you're uncertain the value is always known and don't
* want to throw for the unknown case.
*
* @throws IncreaseInvalidDataException if this class instance's value is a not a known
* member.
*/
fun known(): Known =
when (this) {
ACCOUNT -> Known.ACCOUNT
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ private constructor(
@JvmStatic fun builder() = Builder()
}

/** A builder for [AccountBalanceParams]. */
@NoAutoDetect
class Builder internal constructor() {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ private constructor(
@JvmStatic fun builder() = Builder()
}

/** A builder for [AccountCloseParams]. */
@NoAutoDetect
class Builder internal constructor() {

Expand Down
Loading
Loading