diff --git a/.release-please-manifest.json b/.release-please-manifest.json
index 79bee3809..a61c73cba 100644
--- a/.release-please-manifest.json
+++ b/.release-please-manifest.json
@@ -1,3 +1,3 @@
{
- ".": "0.334.0"
+ ".": "0.335.0"
}
\ No newline at end of file
diff --git a/.stats.yml b/.stats.yml
index 776d32426..afc57da05 100644
--- a/.stats.yml
+++ b/.stats.yml
@@ -1,4 +1,4 @@
configured_endpoints: 214
-openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/increase%2Fincrease-beb9032c2ea0fb6fb46727701c252d27d8f2f77688472dc922fb10afb142dd1c.yml
-openapi_spec_hash: dc5aa90744d4e0958a9a2d652adda0ba
+openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/increase%2Fincrease-4c440e14682c4e4c886da6d05b2f5ff539a3aadc6906bb4069a5df45e0d3cae9.yml
+openapi_spec_hash: e400be1da67cec4ce706eda1868dd86b
config_hash: 8dadd60eab7ab858cf06c6a8633ed9f3
diff --git a/CHANGELOG.md b/CHANGELOG.md
index eecd622bf..402349667 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,5 +1,13 @@
# Changelog
+## 0.335.0 (2025-09-24)
+
+Full Changelog: [v0.334.0...v0.335.0](https://github.com/Increase/increase-java/compare/v0.334.0...v0.335.0)
+
+### Features
+
+* **api:** api update ([5ea52d4](https://github.com/Increase/increase-java/commit/5ea52d46b591f405709fab21b9d58ae74b70908b))
+
## 0.334.0 (2025-09-23)
Full Changelog: [v0.333.0...v0.334.0](https://github.com/Increase/increase-java/compare/v0.333.0...v0.334.0)
diff --git a/README.md b/README.md
index a71e1e995..418ddf6a2 100644
--- a/README.md
+++ b/README.md
@@ -2,8 +2,8 @@
-[](https://central.sonatype.com/artifact/com.increase.api/increase-java/0.334.0)
-[](https://javadoc.io/doc/com.increase.api/increase-java/0.334.0)
+[](https://central.sonatype.com/artifact/com.increase.api/increase-java/0.335.0)
+[](https://javadoc.io/doc/com.increase.api/increase-java/0.335.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.334.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.335.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.334.0")
+implementation("com.increase.api:increase-java:0.335.0")
```
### Maven
@@ -33,7 +33,7 @@ implementation("com.increase.api:increase-java:0.334.0")
com.increase.api
increase-java
- 0.334.0
+ 0.335.0
```
diff --git a/build.gradle.kts b/build.gradle.kts
index 357c58f13..1fd08b904 100644
--- a/build.gradle.kts
+++ b/build.gradle.kts
@@ -8,7 +8,7 @@ repositories {
allprojects {
group = "com.increase.api"
- version = "0.334.0" // x-release-please-version
+ version = "0.335.0" // x-release-please-version
}
subprojects {
diff --git a/increase-java-core/src/main/kotlin/com/increase/api/models/accounttransfers/AccountTransfer.kt b/increase-java-core/src/main/kotlin/com/increase/api/models/accounttransfers/AccountTransfer.kt
index 4a86c1d35..bfa31d0a4 100644
--- a/increase-java-core/src/main/kotlin/com/increase/api/models/accounttransfers/AccountTransfer.kt
+++ b/increase-java-core/src/main/kotlin/com/increase/api/models/accounttransfers/AccountTransfer.kt
@@ -19,7 +19,13 @@ import java.util.Objects
import java.util.Optional
import kotlin.jvm.optionals.getOrNull
-/** Account transfers move funds between your own accounts at Increase. */
+/**
+ * Account transfers move funds between your own accounts at Increase (accounting systems often
+ * refer to these as Book Transfers). Account Transfers are free and synchronous. Upon creation they
+ * create two Transactions, one negative on the originating account and one positive on the
+ * destination account (unless the transfer requires approval, in which case the Transactions will
+ * be created when the transfer is approved).
+ */
class AccountTransfer
private constructor(
private val id: JsonField,
@@ -34,7 +40,6 @@ private constructor(
private val destinationAccountId: JsonField,
private val destinationTransactionId: JsonField,
private val idempotencyKey: JsonField,
- private val network: JsonField,
private val pendingTransactionId: JsonField,
private val status: JsonField,
private val transactionId: JsonField,
@@ -70,7 +75,6 @@ private constructor(
@JsonProperty("idempotency_key")
@ExcludeMissing
idempotencyKey: JsonField = JsonMissing.of(),
- @JsonProperty("network") @ExcludeMissing network: JsonField = JsonMissing.of(),
@JsonProperty("pending_transaction_id")
@ExcludeMissing
pendingTransactionId: JsonField = JsonMissing.of(),
@@ -92,7 +96,6 @@ private constructor(
destinationAccountId,
destinationTransactionId,
idempotencyKey,
- network,
pendingTransactionId,
status,
transactionId,
@@ -101,7 +104,7 @@ private constructor(
)
/**
- * The account transfer's identifier.
+ * The Account Transfer's identifier.
*
* @throws IncreaseInvalidDataException if the JSON field has an unexpected type or is
* unexpectedly missing or null (e.g. if the server responded with an unexpected value).
@@ -109,7 +112,7 @@ private constructor(
fun id(): String = id.getRequired("id")
/**
- * The Account to which the transfer belongs.
+ * The Account from which the transfer originated.
*
* @throws IncreaseInvalidDataException if the JSON field has an unexpected type or is
* unexpectedly missing or null (e.g. if the server responded with an unexpected value).
@@ -117,8 +120,8 @@ private constructor(
fun accountId(): String = accountId.getRequired("account_id")
/**
- * The transfer amount in the minor unit of the destination account currency. For dollars, for
- * example, this is cents.
+ * The transfer amount in cents. This will always be positive and indicates the amount of money
+ * leaving the originating account.
*
* @throws IncreaseInvalidDataException if the JSON field has an unexpected type or is
* unexpectedly missing or null (e.g. if the server responded with an unexpected value).
@@ -161,8 +164,7 @@ private constructor(
fun createdBy(): Optional = createdBy.getOptional("created_by")
/**
- * The [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) code for the destination account
- * currency.
+ * The [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) code for the transfer's currency.
*
* @throws IncreaseInvalidDataException if the JSON field has an unexpected type or is
* unexpectedly missing or null (e.g. if the server responded with an unexpected value).
@@ -170,7 +172,8 @@ private constructor(
fun currency(): Currency = currency.getRequired("currency")
/**
- * The description that will show on the transactions.
+ * An internal-facing description for the transfer for display in the API and dashboard. This
+ * will also show in the description of the created Transactions.
*
* @throws IncreaseInvalidDataException if the JSON field has an unexpected type or is
* unexpectedly missing or null (e.g. if the server responded with an unexpected value).
@@ -178,7 +181,7 @@ private constructor(
fun description(): String = description.getRequired("description")
/**
- * The destination account's identifier.
+ * The destination Account's identifier.
*
* @throws IncreaseInvalidDataException if the JSON field has an unexpected type or is
* unexpectedly missing or null (e.g. if the server responded with an unexpected value).
@@ -186,7 +189,7 @@ private constructor(
fun destinationAccountId(): String = destinationAccountId.getRequired("destination_account_id")
/**
- * The ID for the transaction receiving the transfer.
+ * The identifier of the Transaction on the destination Account representing the received funds.
*
* @throws IncreaseInvalidDataException if the JSON field has an unexpected type (e.g. if the
* server responded with an unexpected value).
@@ -204,14 +207,6 @@ private constructor(
*/
fun idempotencyKey(): Optional = idempotencyKey.getOptional("idempotency_key")
- /**
- * The transfer's network.
- *
- * @throws IncreaseInvalidDataException if the JSON field has an unexpected type or is
- * unexpectedly missing or null (e.g. if the server responded with an unexpected value).
- */
- fun network(): Network = network.getRequired("network")
-
/**
* The ID for the pending transaction representing the transfer. A pending transaction is
* created when the transfer
@@ -233,7 +228,8 @@ private constructor(
fun status(): Status = status.getRequired("status")
/**
- * The ID for the transaction funding the transfer.
+ * The identifier of the Transaction on the originating account representing the transferred
+ * funds.
*
* @throws IncreaseInvalidDataException if the JSON field has an unexpected type (e.g. if the
* server responded with an unexpected value).
@@ -345,13 +341,6 @@ private constructor(
@ExcludeMissing
fun _idempotencyKey(): JsonField = idempotencyKey
- /**
- * Returns the raw JSON value of [network].
- *
- * Unlike [network], this method doesn't throw if the JSON field has an unexpected type.
- */
- @JsonProperty("network") @ExcludeMissing fun _network(): JsonField = network
-
/**
* Returns the raw JSON value of [pendingTransactionId].
*
@@ -416,7 +405,6 @@ private constructor(
* .destinationAccountId()
* .destinationTransactionId()
* .idempotencyKey()
- * .network()
* .pendingTransactionId()
* .status()
* .transactionId()
@@ -441,7 +429,6 @@ private constructor(
private var destinationAccountId: JsonField? = null
private var destinationTransactionId: JsonField? = null
private var idempotencyKey: JsonField? = null
- private var network: JsonField? = null
private var pendingTransactionId: JsonField? = null
private var status: JsonField? = null
private var transactionId: JsonField? = null
@@ -462,7 +449,6 @@ private constructor(
destinationAccountId = accountTransfer.destinationAccountId
destinationTransactionId = accountTransfer.destinationTransactionId
idempotencyKey = accountTransfer.idempotencyKey
- network = accountTransfer.network
pendingTransactionId = accountTransfer.pendingTransactionId
status = accountTransfer.status
transactionId = accountTransfer.transactionId
@@ -470,7 +456,7 @@ private constructor(
additionalProperties = accountTransfer.additionalProperties.toMutableMap()
}
- /** The account transfer's identifier. */
+ /** The Account Transfer's identifier. */
fun id(id: String) = id(JsonField.of(id))
/**
@@ -481,7 +467,7 @@ private constructor(
*/
fun id(id: JsonField) = apply { this.id = id }
- /** The Account to which the transfer belongs. */
+ /** The Account from which the transfer originated. */
fun accountId(accountId: String) = accountId(JsonField.of(accountId))
/**
@@ -494,8 +480,8 @@ private constructor(
fun accountId(accountId: JsonField) = apply { this.accountId = accountId }
/**
- * The transfer amount in the minor unit of the destination account currency. For dollars,
- * for example, this is cents.
+ * The transfer amount in cents. This will always be positive and indicates the amount of
+ * money leaving the originating account.
*/
fun amount(amount: Long) = amount(JsonField.of(amount))
@@ -578,8 +564,7 @@ private constructor(
fun createdBy(createdBy: JsonField) = apply { this.createdBy = createdBy }
/**
- * The [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) code for the destination account
- * currency.
+ * The [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) code for the transfer's currency.
*/
fun currency(currency: Currency) = currency(JsonField.of(currency))
@@ -592,7 +577,10 @@ private constructor(
*/
fun currency(currency: JsonField) = apply { this.currency = currency }
- /** The description that will show on the transactions. */
+ /**
+ * An internal-facing description for the transfer for display in the API and dashboard.
+ * This will also show in the description of the created Transactions.
+ */
fun description(description: String) = description(JsonField.of(description))
/**
@@ -604,7 +592,7 @@ private constructor(
*/
fun description(description: JsonField) = apply { this.description = description }
- /** The destination account's identifier. */
+ /** The destination Account's identifier. */
fun destinationAccountId(destinationAccountId: String) =
destinationAccountId(JsonField.of(destinationAccountId))
@@ -619,7 +607,10 @@ private constructor(
this.destinationAccountId = destinationAccountId
}
- /** The ID for the transaction receiving the transfer. */
+ /**
+ * The identifier of the Transaction on the destination Account representing the received
+ * funds.
+ */
fun destinationTransactionId(destinationTransactionId: String?) =
destinationTransactionId(JsonField.ofNullable(destinationTransactionId))
@@ -664,17 +655,6 @@ private constructor(
this.idempotencyKey = idempotencyKey
}
- /** The transfer's network. */
- fun network(network: Network) = network(JsonField.of(network))
-
- /**
- * Sets [Builder.network] to an arbitrary JSON value.
- *
- * You should usually call [Builder.network] with a well-typed [Network] value instead. This
- * method is primarily for setting the field to an undocumented or not yet supported value.
- */
- fun network(network: JsonField) = apply { this.network = network }
-
/**
* The ID for the pending transaction representing the transfer. A pending transaction is
* created when the transfer
@@ -713,7 +693,10 @@ private constructor(
*/
fun status(status: JsonField) = apply { this.status = status }
- /** The ID for the transaction funding the transfer. */
+ /**
+ * The identifier of the Transaction on the originating account representing the transferred
+ * funds.
+ */
fun transactionId(transactionId: String?) =
transactionId(JsonField.ofNullable(transactionId))
@@ -784,7 +767,6 @@ private constructor(
* .destinationAccountId()
* .destinationTransactionId()
* .idempotencyKey()
- * .network()
* .pendingTransactionId()
* .status()
* .transactionId()
@@ -807,7 +789,6 @@ private constructor(
checkRequired("destinationAccountId", destinationAccountId),
checkRequired("destinationTransactionId", destinationTransactionId),
checkRequired("idempotencyKey", idempotencyKey),
- checkRequired("network", network),
checkRequired("pendingTransactionId", pendingTransactionId),
checkRequired("status", status),
checkRequired("transactionId", transactionId),
@@ -835,7 +816,6 @@ private constructor(
destinationAccountId()
destinationTransactionId()
idempotencyKey()
- network().validate()
pendingTransactionId()
status().validate()
transactionId()
@@ -870,7 +850,6 @@ private constructor(
(if (destinationAccountId.asKnown().isPresent) 1 else 0) +
(if (destinationTransactionId.asKnown().isPresent) 1 else 0) +
(if (idempotencyKey.asKnown().isPresent) 1 else 0) +
- (network.asKnown().getOrNull()?.validity() ?: 0) +
(if (pendingTransactionId.asKnown().isPresent) 1 else 0) +
(status.asKnown().getOrNull()?.validity() ?: 0) +
(if (transactionId.asKnown().isPresent) 1 else 0) +
@@ -2272,10 +2251,7 @@ private constructor(
"CreatedBy{apiKey=$apiKey, category=$category, oauthApplication=$oauthApplication, user=$user, additionalProperties=$additionalProperties}"
}
- /**
- * The [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) code for the destination account
- * currency.
- */
+ /** The [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) code for the transfer's currency. */
class Currency @JsonCreator private constructor(private val value: JsonField) : Enum {
/**
@@ -2445,128 +2421,6 @@ private constructor(
override fun toString() = value.toString()
}
- /** The transfer's network. */
- class Network @JsonCreator private constructor(private val value: JsonField) : 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 = value
-
- companion object {
-
- @JvmField val ACCOUNT = of("account")
-
- @JvmStatic fun of(value: String) = Network(JsonField.of(value))
- }
-
- /** An enum containing [Network]'s known values. */
- enum class Known {
- ACCOUNT
- }
-
- /**
- * An enum containing [Network]'s known values, as well as an [_UNKNOWN] member.
- *
- * An instance of [Network] 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 [Network] 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
- else -> throw IncreaseInvalidDataException("Unknown Network: $value")
- }
-
- /**
- * Returns this class instance's primitive wire representation.
- *
- * This differs from the [toString] method because that method is primarily for debugging
- * and generally doesn't throw.
- *
- * @throws IncreaseInvalidDataException if this class instance's value does not have the
- * expected primitive type.
- */
- fun asString(): String =
- _value().asString().orElseThrow {
- IncreaseInvalidDataException("Value is not a String")
- }
-
- private var validated: Boolean = false
-
- fun validate(): Network = apply {
- if (validated) {
- return@apply
- }
-
- known()
- validated = true
- }
-
- fun isValid(): Boolean =
- try {
- validate()
- true
- } catch (e: IncreaseInvalidDataException) {
- false
- }
-
- /**
- * Returns a score indicating how many valid values are contained in this object
- * recursively.
- *
- * Used for best match union deserialization.
- */
- @JvmSynthetic internal fun validity(): Int = if (value() == Value._UNKNOWN) 0 else 1
-
- override fun equals(other: Any?): Boolean {
- if (this === other) {
- return true
- }
-
- return other is Network && value == other.value
- }
-
- override fun hashCode() = value.hashCode()
-
- override fun toString() = value.toString()
- }
-
/** The lifecycle status of the transfer. */
class Status @JsonCreator private constructor(private val value: JsonField) : Enum {
@@ -2582,10 +2436,10 @@ private constructor(
companion object {
- /** The transfer is pending approval. */
+ /** The transfer is pending approval from your team. */
@JvmField val PENDING_APPROVAL = of("pending_approval")
- /** The transfer has been canceled. */
+ /** The transfer was pending approval from your team and has been canceled. */
@JvmField val CANCELED = of("canceled")
/** The transfer has been completed. */
@@ -2596,9 +2450,9 @@ private constructor(
/** An enum containing [Status]'s known values. */
enum class Known {
- /** The transfer is pending approval. */
+ /** The transfer is pending approval from your team. */
PENDING_APPROVAL,
- /** The transfer has been canceled. */
+ /** The transfer was pending approval from your team and has been canceled. */
CANCELED,
/** The transfer has been completed. */
COMPLETE,
@@ -2614,9 +2468,9 @@ private constructor(
* - It was constructed with an arbitrary value using the [of] method.
*/
enum class Value {
- /** The transfer is pending approval. */
+ /** The transfer is pending approval from your team. */
PENDING_APPROVAL,
- /** The transfer has been canceled. */
+ /** The transfer was pending approval from your team and has been canceled. */
CANCELED,
/** The transfer has been completed. */
COMPLETE,
@@ -2853,7 +2707,6 @@ private constructor(
destinationAccountId == other.destinationAccountId &&
destinationTransactionId == other.destinationTransactionId &&
idempotencyKey == other.idempotencyKey &&
- network == other.network &&
pendingTransactionId == other.pendingTransactionId &&
status == other.status &&
transactionId == other.transactionId &&
@@ -2875,7 +2728,6 @@ private constructor(
destinationAccountId,
destinationTransactionId,
idempotencyKey,
- network,
pendingTransactionId,
status,
transactionId,
@@ -2887,5 +2739,5 @@ private constructor(
override fun hashCode(): Int = hashCode
override fun toString() =
- "AccountTransfer{id=$id, accountId=$accountId, amount=$amount, approval=$approval, cancellation=$cancellation, createdAt=$createdAt, createdBy=$createdBy, currency=$currency, description=$description, destinationAccountId=$destinationAccountId, destinationTransactionId=$destinationTransactionId, idempotencyKey=$idempotencyKey, network=$network, pendingTransactionId=$pendingTransactionId, status=$status, transactionId=$transactionId, type=$type, additionalProperties=$additionalProperties}"
+ "AccountTransfer{id=$id, accountId=$accountId, amount=$amount, approval=$approval, cancellation=$cancellation, createdAt=$createdAt, createdBy=$createdBy, currency=$currency, description=$description, destinationAccountId=$destinationAccountId, destinationTransactionId=$destinationTransactionId, idempotencyKey=$idempotencyKey, pendingTransactionId=$pendingTransactionId, status=$status, transactionId=$transactionId, type=$type, additionalProperties=$additionalProperties}"
}
diff --git a/increase-java-core/src/main/kotlin/com/increase/api/models/accounttransfers/AccountTransferApproveParams.kt b/increase-java-core/src/main/kotlin/com/increase/api/models/accounttransfers/AccountTransferApproveParams.kt
index 421c7ef85..53b323584 100644
--- a/increase-java-core/src/main/kotlin/com/increase/api/models/accounttransfers/AccountTransferApproveParams.kt
+++ b/increase-java-core/src/main/kotlin/com/increase/api/models/accounttransfers/AccountTransferApproveParams.kt
@@ -11,7 +11,7 @@ import java.util.Objects
import java.util.Optional
import kotlin.jvm.optionals.getOrNull
-/** Approve an Account Transfer */
+/** Approves an Account Transfer in status `pending_approval`. */
class AccountTransferApproveParams
private constructor(
private val accountTransferId: String?,
diff --git a/increase-java-core/src/main/kotlin/com/increase/api/models/accounttransfers/AccountTransferCancelParams.kt b/increase-java-core/src/main/kotlin/com/increase/api/models/accounttransfers/AccountTransferCancelParams.kt
index 43ec6c5de..95962ee8b 100644
--- a/increase-java-core/src/main/kotlin/com/increase/api/models/accounttransfers/AccountTransferCancelParams.kt
+++ b/increase-java-core/src/main/kotlin/com/increase/api/models/accounttransfers/AccountTransferCancelParams.kt
@@ -11,7 +11,7 @@ import java.util.Objects
import java.util.Optional
import kotlin.jvm.optionals.getOrNull
-/** Cancel an Account Transfer */
+/** Cancels an Account Transfer in status `pending_approval`. */
class AccountTransferCancelParams
private constructor(
private val accountTransferId: String?,
diff --git a/increase-java-core/src/main/kotlin/com/increase/api/models/accounttransfers/AccountTransferCreateParams.kt b/increase-java-core/src/main/kotlin/com/increase/api/models/accounttransfers/AccountTransferCreateParams.kt
index fed9bad75..20877e9ca 100644
--- a/increase-java-core/src/main/kotlin/com/increase/api/models/accounttransfers/AccountTransferCreateParams.kt
+++ b/increase-java-core/src/main/kotlin/com/increase/api/models/accounttransfers/AccountTransferCreateParams.kt
@@ -28,7 +28,7 @@ private constructor(
) : Params {
/**
- * The identifier for the account that will send the transfer.
+ * The identifier for the originating Account that will send the transfer.
*
* @throws IncreaseInvalidDataException if the JSON field has an unexpected type or is
* unexpectedly missing or null (e.g. if the server responded with an unexpected value).
@@ -45,7 +45,8 @@ private constructor(
fun amount(): Long = body.amount()
/**
- * The description you choose to give the transfer.
+ * An internal-facing description for the transfer for display in the API and dashboard. This
+ * will also show in the description of the created Transactions.
*
* @throws IncreaseInvalidDataException if the JSON field has an unexpected type or is
* unexpectedly missing or null (e.g. if the server responded with an unexpected value).
@@ -53,7 +54,7 @@ private constructor(
fun description(): String = body.description()
/**
- * The identifier for the account that will receive the transfer.
+ * The identifier for the destination Account that will receive the transfer.
*
* @throws IncreaseInvalidDataException if the JSON field has an unexpected type or is
* unexpectedly missing or null (e.g. if the server responded with an unexpected value).
@@ -61,7 +62,8 @@ private constructor(
fun destinationAccountId(): String = body.destinationAccountId()
/**
- * Whether the transfer requires explicit approval via the dashboard or API.
+ * Whether the transfer should require explicit approval via the dashboard or API. For more
+ * information, see [Transfer Approvals](/documentation/transfer-approvals).
*
* @throws IncreaseInvalidDataException if the JSON field has an unexpected type (e.g. if the
* server responded with an unexpected value).
@@ -158,7 +160,7 @@ private constructor(
*/
fun body(body: Body) = apply { this.body = body.toBuilder() }
- /** The identifier for the account that will send the transfer. */
+ /** The identifier for the originating Account that will send the transfer. */
fun accountId(accountId: String) = apply { body.accountId(accountId) }
/**
@@ -184,7 +186,10 @@ private constructor(
*/
fun amount(amount: JsonField) = apply { body.amount(amount) }
- /** The description you choose to give the transfer. */
+ /**
+ * An internal-facing description for the transfer for display in the API and dashboard.
+ * This will also show in the description of the created Transactions.
+ */
fun description(description: String) = apply { body.description(description) }
/**
@@ -196,7 +201,7 @@ private constructor(
*/
fun description(description: JsonField) = apply { body.description(description) }
- /** The identifier for the account that will receive the transfer. */
+ /** The identifier for the destination Account that will receive the transfer. */
fun destinationAccountId(destinationAccountId: String) = apply {
body.destinationAccountId(destinationAccountId)
}
@@ -212,7 +217,10 @@ private constructor(
body.destinationAccountId(destinationAccountId)
}
- /** Whether the transfer requires explicit approval via the dashboard or API. */
+ /**
+ * Whether the transfer should require explicit approval via the dashboard or API. For more
+ * information, see [Transfer Approvals](/documentation/transfer-approvals).
+ */
fun requireApproval(requireApproval: Boolean) = apply {
body.requireApproval(requireApproval)
}
@@ -409,7 +417,7 @@ private constructor(
)
/**
- * The identifier for the account that will send the transfer.
+ * The identifier for the originating Account that will send the transfer.
*
* @throws IncreaseInvalidDataException if the JSON field has an unexpected type or is
* unexpectedly missing or null (e.g. if the server responded with an unexpected value).
@@ -426,7 +434,8 @@ private constructor(
fun amount(): Long = amount.getRequired("amount")
/**
- * The description you choose to give the transfer.
+ * An internal-facing description for the transfer for display in the API and dashboard.
+ * This will also show in the description of the created Transactions.
*
* @throws IncreaseInvalidDataException if the JSON field has an unexpected type or is
* unexpectedly missing or null (e.g. if the server responded with an unexpected value).
@@ -434,7 +443,7 @@ private constructor(
fun description(): String = description.getRequired("description")
/**
- * The identifier for the account that will receive the transfer.
+ * The identifier for the destination Account that will receive the transfer.
*
* @throws IncreaseInvalidDataException if the JSON field has an unexpected type or is
* unexpectedly missing or null (e.g. if the server responded with an unexpected value).
@@ -443,7 +452,8 @@ private constructor(
destinationAccountId.getRequired("destination_account_id")
/**
- * Whether the transfer requires explicit approval via the dashboard or API.
+ * Whether the transfer should require explicit approval via the dashboard or API. For more
+ * information, see [Transfer Approvals](/documentation/transfer-approvals).
*
* @throws IncreaseInvalidDataException if the JSON field has an unexpected type (e.g. if
* the server responded with an unexpected value).
@@ -541,7 +551,7 @@ private constructor(
additionalProperties = body.additionalProperties.toMutableMap()
}
- /** The identifier for the account that will send the transfer. */
+ /** The identifier for the originating Account that will send the transfer. */
fun accountId(accountId: String) = accountId(JsonField.of(accountId))
/**
@@ -568,7 +578,10 @@ private constructor(
*/
fun amount(amount: JsonField) = apply { this.amount = amount }
- /** The description you choose to give the transfer. */
+ /**
+ * An internal-facing description for the transfer for display in the API and dashboard.
+ * This will also show in the description of the created Transactions.
+ */
fun description(description: String) = description(JsonField.of(description))
/**
@@ -582,7 +595,7 @@ private constructor(
this.description = description
}
- /** The identifier for the account that will receive the transfer. */
+ /** The identifier for the destination Account that will receive the transfer. */
fun destinationAccountId(destinationAccountId: String) =
destinationAccountId(JsonField.of(destinationAccountId))
@@ -597,7 +610,10 @@ private constructor(
this.destinationAccountId = destinationAccountId
}
- /** Whether the transfer requires explicit approval via the dashboard or API. */
+ /**
+ * Whether the transfer should require explicit approval via the dashboard or API. For
+ * more information, see [Transfer Approvals](/documentation/transfer-approvals).
+ */
fun requireApproval(requireApproval: Boolean) =
requireApproval(JsonField.of(requireApproval))
diff --git a/increase-java-core/src/main/kotlin/com/increase/api/services/async/AccountTransferServiceAsync.kt b/increase-java-core/src/main/kotlin/com/increase/api/services/async/AccountTransferServiceAsync.kt
index b4e85178f..04ab44dce 100644
--- a/increase-java-core/src/main/kotlin/com/increase/api/services/async/AccountTransferServiceAsync.kt
+++ b/increase-java-core/src/main/kotlin/com/increase/api/services/async/AccountTransferServiceAsync.kt
@@ -94,7 +94,7 @@ interface AccountTransferServiceAsync {
fun list(requestOptions: RequestOptions): CompletableFuture =
list(AccountTransferListParams.none(), requestOptions)
- /** Approve an Account Transfer */
+ /** Approves an Account Transfer in status `pending_approval`. */
fun approve(accountTransferId: String): CompletableFuture =
approve(accountTransferId, AccountTransferApproveParams.none())
@@ -130,7 +130,7 @@ interface AccountTransferServiceAsync {
): CompletableFuture =
approve(accountTransferId, AccountTransferApproveParams.none(), requestOptions)
- /** Cancel an Account Transfer */
+ /** Cancels an Account Transfer in status `pending_approval`. */
fun cancel(accountTransferId: String): CompletableFuture =
cancel(accountTransferId, AccountTransferCancelParams.none())
diff --git a/increase-java-core/src/main/kotlin/com/increase/api/services/blocking/AccountTransferService.kt b/increase-java-core/src/main/kotlin/com/increase/api/services/blocking/AccountTransferService.kt
index f65b36641..8b809fa2d 100644
--- a/increase-java-core/src/main/kotlin/com/increase/api/services/blocking/AccountTransferService.kt
+++ b/increase-java-core/src/main/kotlin/com/increase/api/services/blocking/AccountTransferService.kt
@@ -89,7 +89,7 @@ interface AccountTransferService {
fun list(requestOptions: RequestOptions): AccountTransferListPage =
list(AccountTransferListParams.none(), requestOptions)
- /** Approve an Account Transfer */
+ /** Approves an Account Transfer in status `pending_approval`. */
fun approve(accountTransferId: String): AccountTransfer =
approve(accountTransferId, AccountTransferApproveParams.none())
@@ -121,7 +121,7 @@ interface AccountTransferService {
fun approve(accountTransferId: String, requestOptions: RequestOptions): AccountTransfer =
approve(accountTransferId, AccountTransferApproveParams.none(), requestOptions)
- /** Cancel an Account Transfer */
+ /** Cancels an Account Transfer in status `pending_approval`. */
fun cancel(accountTransferId: String): AccountTransfer =
cancel(accountTransferId, AccountTransferCancelParams.none())
diff --git a/increase-java-core/src/test/kotlin/com/increase/api/models/accounttransfers/AccountTransferListPageResponseTest.kt b/increase-java-core/src/test/kotlin/com/increase/api/models/accounttransfers/AccountTransferListPageResponseTest.kt
index bc0d1d51e..31b8858cf 100644
--- a/increase-java-core/src/test/kotlin/com/increase/api/models/accounttransfers/AccountTransferListPageResponseTest.kt
+++ b/increase-java-core/src/test/kotlin/com/increase/api/models/accounttransfers/AccountTransferListPageResponseTest.kt
@@ -57,7 +57,6 @@ internal class AccountTransferListPageResponseTest {
.destinationAccountId("account_uf16sut2ct5bevmq3eh")
.destinationTransactionId("transaction_j3itv8dtk5o8pw3p1xj4")
.idempotencyKey(null)
- .network(AccountTransfer.Network.ACCOUNT)
.pendingTransactionId(null)
.status(AccountTransfer.Status.COMPLETE)
.transactionId("transaction_uyrp7fld2ium70oa7oi")
@@ -111,7 +110,6 @@ internal class AccountTransferListPageResponseTest {
.destinationAccountId("account_uf16sut2ct5bevmq3eh")
.destinationTransactionId("transaction_j3itv8dtk5o8pw3p1xj4")
.idempotencyKey(null)
- .network(AccountTransfer.Network.ACCOUNT)
.pendingTransactionId(null)
.status(AccountTransfer.Status.COMPLETE)
.transactionId("transaction_uyrp7fld2ium70oa7oi")
@@ -169,7 +167,6 @@ internal class AccountTransferListPageResponseTest {
.destinationAccountId("account_uf16sut2ct5bevmq3eh")
.destinationTransactionId("transaction_j3itv8dtk5o8pw3p1xj4")
.idempotencyKey(null)
- .network(AccountTransfer.Network.ACCOUNT)
.pendingTransactionId(null)
.status(AccountTransfer.Status.COMPLETE)
.transactionId("transaction_uyrp7fld2ium70oa7oi")
diff --git a/increase-java-core/src/test/kotlin/com/increase/api/models/accounttransfers/AccountTransferTest.kt b/increase-java-core/src/test/kotlin/com/increase/api/models/accounttransfers/AccountTransferTest.kt
index 947195bd7..2d838855b 100644
--- a/increase-java-core/src/test/kotlin/com/increase/api/models/accounttransfers/AccountTransferTest.kt
+++ b/increase-java-core/src/test/kotlin/com/increase/api/models/accounttransfers/AccountTransferTest.kt
@@ -55,7 +55,6 @@ internal class AccountTransferTest {
.destinationAccountId("account_uf16sut2ct5bevmq3eh")
.destinationTransactionId("transaction_j3itv8dtk5o8pw3p1xj4")
.idempotencyKey(null)
- .network(AccountTransfer.Network.ACCOUNT)
.pendingTransactionId(null)
.status(AccountTransfer.Status.COMPLETE)
.transactionId("transaction_uyrp7fld2ium70oa7oi")
@@ -104,7 +103,6 @@ internal class AccountTransferTest {
assertThat(accountTransfer.destinationTransactionId())
.contains("transaction_j3itv8dtk5o8pw3p1xj4")
assertThat(accountTransfer.idempotencyKey()).isEmpty
- assertThat(accountTransfer.network()).isEqualTo(AccountTransfer.Network.ACCOUNT)
assertThat(accountTransfer.pendingTransactionId()).isEmpty
assertThat(accountTransfer.status()).isEqualTo(AccountTransfer.Status.COMPLETE)
assertThat(accountTransfer.transactionId()).contains("transaction_uyrp7fld2ium70oa7oi")
@@ -157,7 +155,6 @@ internal class AccountTransferTest {
.destinationAccountId("account_uf16sut2ct5bevmq3eh")
.destinationTransactionId("transaction_j3itv8dtk5o8pw3p1xj4")
.idempotencyKey(null)
- .network(AccountTransfer.Network.ACCOUNT)
.pendingTransactionId(null)
.status(AccountTransfer.Status.COMPLETE)
.transactionId("transaction_uyrp7fld2ium70oa7oi")