diff --git a/.release-please-manifest.json b/.release-please-manifest.json
index 32a4dbb4e..87081a10a 100644
--- a/.release-please-manifest.json
+++ b/.release-please-manifest.json
@@ -1,3 +1,3 @@
{
- ".": "0.299.0"
+ ".": "0.300.0"
}
\ No newline at end of file
diff --git a/.stats.yml b/.stats.yml
index 28f0f87b7..d35c27b7d 100644
--- a/.stats.yml
+++ b/.stats.yml
@@ -1,4 +1,4 @@
configured_endpoints: 216
-openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/increase%2Fincrease-740517a6a575bb225c5bfa111ab83611c58533d5b1514f505aab22185f4a8992.yml
-openapi_spec_hash: 8bfd6dcf11d076c24e4f092dc7e151ac
-config_hash: 29e452035e915a07cd64333b10a83077
+openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/increase%2Fincrease-b6c7f7c551cd8635ddf3fa27eb1040a4e3888c8190326472c19fd919a5e2c8c5.yml
+openapi_spec_hash: 287cbadcab1cec9f352da22a4e39c160
+config_hash: 632b628b59d8f0b717153b3d8133f6cb
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 658e2a7a7..3d6016266 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,5 +1,13 @@
# Changelog
+## 0.300.0 (2025-08-26)
+
+Full Changelog: [v0.299.0...v0.300.0](https://github.com/Increase/increase-java/compare/v0.299.0...v0.300.0)
+
+### Features
+
+* **api:** api update ([4207dc1](https://github.com/Increase/increase-java/commit/4207dc15626ab13b06de3281e911f89ccb6bc789))
+
## 0.299.0 (2025-08-26)
Full Changelog: [v0.298.0...v0.299.0](https://github.com/Increase/increase-java/compare/v0.298.0...v0.299.0)
diff --git a/README.md b/README.md
index dfa17b3d6..18e23f7dc 100644
--- a/README.md
+++ b/README.md
@@ -2,8 +2,8 @@
-[](https://central.sonatype.com/artifact/com.increase.api/increase-java/0.299.0)
-[](https://javadoc.io/doc/com.increase.api/increase-java/0.299.0)
+[](https://central.sonatype.com/artifact/com.increase.api/increase-java/0.300.0)
+[](https://javadoc.io/doc/com.increase.api/increase-java/0.300.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.299.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.300.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.299.0")
+implementation("com.increase.api:increase-java:0.300.0")
```
### Maven
@@ -33,7 +33,7 @@ implementation("com.increase.api:increase-java:0.299.0")
com.increase.api
increase-java
- 0.299.0
+ 0.300.0
```
diff --git a/build.gradle.kts b/build.gradle.kts
index 5da6f768e..146501e69 100644
--- a/build.gradle.kts
+++ b/build.gradle.kts
@@ -8,7 +8,7 @@ repositories {
allprojects {
group = "com.increase.api"
- version = "0.299.0" // x-release-please-version
+ version = "0.300.0" // x-release-please-version
}
subprojects {
diff --git a/increase-java-core/src/main/kotlin/com/increase/api/models/simulations/inboundfundsholds/InboundFundsHoldReleaseResponse.kt b/increase-java-core/src/main/kotlin/com/increase/api/models/simulations/inboundfundsholds/InboundFundsHoldReleaseResponse.kt
deleted file mode 100644
index 9ff82d30d..000000000
--- a/increase-java-core/src/main/kotlin/com/increase/api/models/simulations/inboundfundsholds/InboundFundsHoldReleaseResponse.kt
+++ /dev/null
@@ -1,1035 +0,0 @@
-// File generated from our OpenAPI spec by Stainless.
-
-package com.increase.api.models.simulations.inboundfundsholds
-
-import com.fasterxml.jackson.annotation.JsonAnyGetter
-import com.fasterxml.jackson.annotation.JsonAnySetter
-import com.fasterxml.jackson.annotation.JsonCreator
-import com.fasterxml.jackson.annotation.JsonProperty
-import com.increase.api.core.Enum
-import com.increase.api.core.ExcludeMissing
-import com.increase.api.core.JsonField
-import com.increase.api.core.JsonMissing
-import com.increase.api.core.JsonValue
-import com.increase.api.core.checkRequired
-import com.increase.api.errors.IncreaseInvalidDataException
-import java.time.OffsetDateTime
-import java.util.Collections
-import java.util.Objects
-import java.util.Optional
-import kotlin.jvm.optionals.getOrNull
-
-/**
- * We hold funds for certain transaction types to account for return windows where funds might still
- * be clawed back by the sending institution.
- */
-class InboundFundsHoldReleaseResponse
-private constructor(
- private val id: JsonField,
- private val amount: JsonField,
- private val automaticallyReleasesAt: JsonField,
- private val createdAt: JsonField,
- private val currency: JsonField,
- private val heldTransactionId: JsonField,
- private val pendingTransactionId: JsonField,
- private val releasedAt: JsonField,
- private val status: JsonField,
- private val type: JsonField,
- private val additionalProperties: MutableMap,
-) {
-
- @JsonCreator
- private constructor(
- @JsonProperty("id") @ExcludeMissing id: JsonField = JsonMissing.of(),
- @JsonProperty("amount") @ExcludeMissing amount: JsonField = JsonMissing.of(),
- @JsonProperty("automatically_releases_at")
- @ExcludeMissing
- automaticallyReleasesAt: JsonField = JsonMissing.of(),
- @JsonProperty("created_at")
- @ExcludeMissing
- createdAt: JsonField = JsonMissing.of(),
- @JsonProperty("currency") @ExcludeMissing currency: JsonField = JsonMissing.of(),
- @JsonProperty("held_transaction_id")
- @ExcludeMissing
- heldTransactionId: JsonField = JsonMissing.of(),
- @JsonProperty("pending_transaction_id")
- @ExcludeMissing
- pendingTransactionId: JsonField = JsonMissing.of(),
- @JsonProperty("released_at")
- @ExcludeMissing
- releasedAt: JsonField = JsonMissing.of(),
- @JsonProperty("status") @ExcludeMissing status: JsonField = JsonMissing.of(),
- @JsonProperty("type") @ExcludeMissing type: JsonField = JsonMissing.of(),
- ) : this(
- id,
- amount,
- automaticallyReleasesAt,
- createdAt,
- currency,
- heldTransactionId,
- pendingTransactionId,
- releasedAt,
- status,
- type,
- mutableMapOf(),
- )
-
- /**
- * The Inbound Funds Hold 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).
- */
- fun id(): String = id.getRequired("id")
-
- /**
- * The held amount in the minor unit of the account's currency. For dollars, for example, this
- * is cents.
- *
- * @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 amount(): Long = amount.getRequired("amount")
-
- /**
- * When the hold will be released automatically. Certain conditions may cause it to be released
- * before this time.
- *
- * @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 automaticallyReleasesAt(): OffsetDateTime =
- automaticallyReleasesAt.getRequired("automatically_releases_at")
-
- /**
- * The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) time at which the hold was created.
- *
- * @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 createdAt(): OffsetDateTime = createdAt.getRequired("created_at")
-
- /**
- * The [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) code for the hold'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).
- */
- fun currency(): Currency = currency.getRequired("currency")
-
- /**
- * The ID of the Transaction for which funds were held.
- *
- * @throws IncreaseInvalidDataException if the JSON field has an unexpected type (e.g. if the
- * server responded with an unexpected value).
- */
- fun heldTransactionId(): Optional = heldTransactionId.getOptional("held_transaction_id")
-
- /**
- * The ID of the Pending Transaction representing the held funds.
- *
- * @throws IncreaseInvalidDataException if the JSON field has an unexpected type (e.g. if the
- * server responded with an unexpected value).
- */
- fun pendingTransactionId(): Optional =
- pendingTransactionId.getOptional("pending_transaction_id")
-
- /**
- * When the hold was released (if it has been released).
- *
- * @throws IncreaseInvalidDataException if the JSON field has an unexpected type (e.g. if the
- * server responded with an unexpected value).
- */
- fun releasedAt(): Optional = releasedAt.getOptional("released_at")
-
- /**
- * The status of the hold.
- *
- * @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 status(): Status = status.getRequired("status")
-
- /**
- * A constant representing the object's type. For this resource it will always be
- * `inbound_funds_hold`.
- *
- * @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 type(): Type = type.getRequired("type")
-
- /**
- * Returns the raw JSON value of [id].
- *
- * Unlike [id], this method doesn't throw if the JSON field has an unexpected type.
- */
- @JsonProperty("id") @ExcludeMissing fun _id(): JsonField = id
-
- /**
- * Returns the raw JSON value of [amount].
- *
- * Unlike [amount], this method doesn't throw if the JSON field has an unexpected type.
- */
- @JsonProperty("amount") @ExcludeMissing fun _amount(): JsonField = amount
-
- /**
- * Returns the raw JSON value of [automaticallyReleasesAt].
- *
- * Unlike [automaticallyReleasesAt], this method doesn't throw if the JSON field has an
- * unexpected type.
- */
- @JsonProperty("automatically_releases_at")
- @ExcludeMissing
- fun _automaticallyReleasesAt(): JsonField = automaticallyReleasesAt
-
- /**
- * Returns the raw JSON value of [createdAt].
- *
- * Unlike [createdAt], this method doesn't throw if the JSON field has an unexpected type.
- */
- @JsonProperty("created_at")
- @ExcludeMissing
- fun _createdAt(): JsonField = createdAt
-
- /**
- * Returns the raw JSON value of [currency].
- *
- * Unlike [currency], this method doesn't throw if the JSON field has an unexpected type.
- */
- @JsonProperty("currency") @ExcludeMissing fun _currency(): JsonField = currency
-
- /**
- * Returns the raw JSON value of [heldTransactionId].
- *
- * Unlike [heldTransactionId], this method doesn't throw if the JSON field has an unexpected
- * type.
- */
- @JsonProperty("held_transaction_id")
- @ExcludeMissing
- fun _heldTransactionId(): JsonField = heldTransactionId
-
- /**
- * Returns the raw JSON value of [pendingTransactionId].
- *
- * Unlike [pendingTransactionId], this method doesn't throw if the JSON field has an unexpected
- * type.
- */
- @JsonProperty("pending_transaction_id")
- @ExcludeMissing
- fun _pendingTransactionId(): JsonField = pendingTransactionId
-
- /**
- * Returns the raw JSON value of [releasedAt].
- *
- * Unlike [releasedAt], this method doesn't throw if the JSON field has an unexpected type.
- */
- @JsonProperty("released_at")
- @ExcludeMissing
- fun _releasedAt(): JsonField = releasedAt
-
- /**
- * Returns the raw JSON value of [status].
- *
- * Unlike [status], this method doesn't throw if the JSON field has an unexpected type.
- */
- @JsonProperty("status") @ExcludeMissing fun _status(): JsonField = status
-
- /**
- * Returns the raw JSON value of [type].
- *
- * Unlike [type], this method doesn't throw if the JSON field has an unexpected type.
- */
- @JsonProperty("type") @ExcludeMissing fun _type(): JsonField = type
-
- @JsonAnySetter
- private fun putAdditionalProperty(key: String, value: JsonValue) {
- additionalProperties.put(key, value)
- }
-
- @JsonAnyGetter
- @ExcludeMissing
- fun _additionalProperties(): Map =
- Collections.unmodifiableMap(additionalProperties)
-
- fun toBuilder() = Builder().from(this)
-
- companion object {
-
- /**
- * Returns a mutable builder for constructing an instance of
- * [InboundFundsHoldReleaseResponse].
- *
- * The following fields are required:
- * ```java
- * .id()
- * .amount()
- * .automaticallyReleasesAt()
- * .createdAt()
- * .currency()
- * .heldTransactionId()
- * .pendingTransactionId()
- * .releasedAt()
- * .status()
- * .type()
- * ```
- */
- @JvmStatic fun builder() = Builder()
- }
-
- /** A builder for [InboundFundsHoldReleaseResponse]. */
- class Builder internal constructor() {
-
- private var id: JsonField? = null
- private var amount: JsonField? = null
- private var automaticallyReleasesAt: JsonField? = null
- private var createdAt: JsonField? = null
- private var currency: JsonField? = null
- private var heldTransactionId: JsonField? = null
- private var pendingTransactionId: JsonField? = null
- private var releasedAt: JsonField? = null
- private var status: JsonField? = null
- private var type: JsonField? = null
- private var additionalProperties: MutableMap = mutableMapOf()
-
- @JvmSynthetic
- internal fun from(inboundFundsHoldReleaseResponse: InboundFundsHoldReleaseResponse) =
- apply {
- id = inboundFundsHoldReleaseResponse.id
- amount = inboundFundsHoldReleaseResponse.amount
- automaticallyReleasesAt = inboundFundsHoldReleaseResponse.automaticallyReleasesAt
- createdAt = inboundFundsHoldReleaseResponse.createdAt
- currency = inboundFundsHoldReleaseResponse.currency
- heldTransactionId = inboundFundsHoldReleaseResponse.heldTransactionId
- pendingTransactionId = inboundFundsHoldReleaseResponse.pendingTransactionId
- releasedAt = inboundFundsHoldReleaseResponse.releasedAt
- status = inboundFundsHoldReleaseResponse.status
- type = inboundFundsHoldReleaseResponse.type
- additionalProperties =
- inboundFundsHoldReleaseResponse.additionalProperties.toMutableMap()
- }
-
- /** The Inbound Funds Hold identifier. */
- fun id(id: String) = id(JsonField.of(id))
-
- /**
- * Sets [Builder.id] to an arbitrary JSON value.
- *
- * You should usually call [Builder.id] with a well-typed [String] value instead. This
- * method is primarily for setting the field to an undocumented or not yet supported value.
- */
- fun id(id: JsonField) = apply { this.id = id }
-
- /**
- * The held amount in the minor unit of the account's currency. For dollars, for example,
- * this is cents.
- */
- fun amount(amount: Long) = amount(JsonField.of(amount))
-
- /**
- * Sets [Builder.amount] to an arbitrary JSON value.
- *
- * You should usually call [Builder.amount] with a well-typed [Long] value instead. This
- * method is primarily for setting the field to an undocumented or not yet supported value.
- */
- fun amount(amount: JsonField) = apply { this.amount = amount }
-
- /**
- * When the hold will be released automatically. Certain conditions may cause it to be
- * released before this time.
- */
- fun automaticallyReleasesAt(automaticallyReleasesAt: OffsetDateTime) =
- automaticallyReleasesAt(JsonField.of(automaticallyReleasesAt))
-
- /**
- * Sets [Builder.automaticallyReleasesAt] to an arbitrary JSON value.
- *
- * You should usually call [Builder.automaticallyReleasesAt] with a well-typed
- * [OffsetDateTime] value instead. This method is primarily for setting the field to an
- * undocumented or not yet supported value.
- */
- fun automaticallyReleasesAt(automaticallyReleasesAt: JsonField) = apply {
- this.automaticallyReleasesAt = automaticallyReleasesAt
- }
-
- /**
- * The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) time at which the hold was
- * created.
- */
- fun createdAt(createdAt: OffsetDateTime) = createdAt(JsonField.of(createdAt))
-
- /**
- * Sets [Builder.createdAt] to an arbitrary JSON value.
- *
- * You should usually call [Builder.createdAt] with a well-typed [OffsetDateTime] value
- * instead. This method is primarily for setting the field to an undocumented or not yet
- * supported value.
- */
- fun createdAt(createdAt: JsonField) = apply { this.createdAt = createdAt }
-
- /** The [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) code for the hold's currency. */
- fun currency(currency: Currency) = currency(JsonField.of(currency))
-
- /**
- * Sets [Builder.currency] to an arbitrary JSON value.
- *
- * You should usually call [Builder.currency] with a well-typed [Currency] value instead.
- * This method is primarily for setting the field to an undocumented or not yet supported
- * value.
- */
- fun currency(currency: JsonField) = apply { this.currency = currency }
-
- /** The ID of the Transaction for which funds were held. */
- fun heldTransactionId(heldTransactionId: String?) =
- heldTransactionId(JsonField.ofNullable(heldTransactionId))
-
- /** Alias for calling [Builder.heldTransactionId] with `heldTransactionId.orElse(null)`. */
- fun heldTransactionId(heldTransactionId: Optional) =
- heldTransactionId(heldTransactionId.getOrNull())
-
- /**
- * Sets [Builder.heldTransactionId] to an arbitrary JSON value.
- *
- * You should usually call [Builder.heldTransactionId] with a well-typed [String] value
- * instead. This method is primarily for setting the field to an undocumented or not yet
- * supported value.
- */
- fun heldTransactionId(heldTransactionId: JsonField) = apply {
- this.heldTransactionId = heldTransactionId
- }
-
- /** The ID of the Pending Transaction representing the held funds. */
- fun pendingTransactionId(pendingTransactionId: String?) =
- pendingTransactionId(JsonField.ofNullable(pendingTransactionId))
-
- /**
- * Alias for calling [Builder.pendingTransactionId] with
- * `pendingTransactionId.orElse(null)`.
- */
- fun pendingTransactionId(pendingTransactionId: Optional) =
- pendingTransactionId(pendingTransactionId.getOrNull())
-
- /**
- * Sets [Builder.pendingTransactionId] to an arbitrary JSON value.
- *
- * You should usually call [Builder.pendingTransactionId] with a well-typed [String] value
- * instead. This method is primarily for setting the field to an undocumented or not yet
- * supported value.
- */
- fun pendingTransactionId(pendingTransactionId: JsonField) = apply {
- this.pendingTransactionId = pendingTransactionId
- }
-
- /** When the hold was released (if it has been released). */
- fun releasedAt(releasedAt: OffsetDateTime?) = releasedAt(JsonField.ofNullable(releasedAt))
-
- /** Alias for calling [Builder.releasedAt] with `releasedAt.orElse(null)`. */
- fun releasedAt(releasedAt: Optional) = releasedAt(releasedAt.getOrNull())
-
- /**
- * Sets [Builder.releasedAt] to an arbitrary JSON value.
- *
- * You should usually call [Builder.releasedAt] with a well-typed [OffsetDateTime] value
- * instead. This method is primarily for setting the field to an undocumented or not yet
- * supported value.
- */
- fun releasedAt(releasedAt: JsonField) = apply {
- this.releasedAt = releasedAt
- }
-
- /** The status of the hold. */
- fun status(status: Status) = status(JsonField.of(status))
-
- /**
- * Sets [Builder.status] to an arbitrary JSON value.
- *
- * You should usually call [Builder.status] with a well-typed [Status] value instead. This
- * method is primarily for setting the field to an undocumented or not yet supported value.
- */
- fun status(status: JsonField) = apply { this.status = status }
-
- /**
- * A constant representing the object's type. For this resource it will always be
- * `inbound_funds_hold`.
- */
- fun type(type: Type) = type(JsonField.of(type))
-
- /**
- * Sets [Builder.type] to an arbitrary JSON value.
- *
- * You should usually call [Builder.type] with a well-typed [Type] value instead. This
- * method is primarily for setting the field to an undocumented or not yet supported value.
- */
- fun type(type: JsonField) = apply { this.type = type }
-
- fun additionalProperties(additionalProperties: Map) = apply {
- this.additionalProperties.clear()
- putAllAdditionalProperties(additionalProperties)
- }
-
- fun putAdditionalProperty(key: String, value: JsonValue) = apply {
- additionalProperties.put(key, value)
- }
-
- fun putAllAdditionalProperties(additionalProperties: Map) = apply {
- this.additionalProperties.putAll(additionalProperties)
- }
-
- fun removeAdditionalProperty(key: String) = apply { additionalProperties.remove(key) }
-
- fun removeAllAdditionalProperties(keys: Set) = apply {
- keys.forEach(::removeAdditionalProperty)
- }
-
- /**
- * Returns an immutable instance of [InboundFundsHoldReleaseResponse].
- *
- * Further updates to this [Builder] will not mutate the returned instance.
- *
- * The following fields are required:
- * ```java
- * .id()
- * .amount()
- * .automaticallyReleasesAt()
- * .createdAt()
- * .currency()
- * .heldTransactionId()
- * .pendingTransactionId()
- * .releasedAt()
- * .status()
- * .type()
- * ```
- *
- * @throws IllegalStateException if any required field is unset.
- */
- fun build(): InboundFundsHoldReleaseResponse =
- InboundFundsHoldReleaseResponse(
- checkRequired("id", id),
- checkRequired("amount", amount),
- checkRequired("automaticallyReleasesAt", automaticallyReleasesAt),
- checkRequired("createdAt", createdAt),
- checkRequired("currency", currency),
- checkRequired("heldTransactionId", heldTransactionId),
- checkRequired("pendingTransactionId", pendingTransactionId),
- checkRequired("releasedAt", releasedAt),
- checkRequired("status", status),
- checkRequired("type", type),
- additionalProperties.toMutableMap(),
- )
- }
-
- private var validated: Boolean = false
-
- fun validate(): InboundFundsHoldReleaseResponse = apply {
- if (validated) {
- return@apply
- }
-
- id()
- amount()
- automaticallyReleasesAt()
- createdAt()
- currency().validate()
- heldTransactionId()
- pendingTransactionId()
- releasedAt()
- status().validate()
- type().validate()
- 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 (id.asKnown().isPresent) 1 else 0) +
- (if (amount.asKnown().isPresent) 1 else 0) +
- (if (automaticallyReleasesAt.asKnown().isPresent) 1 else 0) +
- (if (createdAt.asKnown().isPresent) 1 else 0) +
- (currency.asKnown().getOrNull()?.validity() ?: 0) +
- (if (heldTransactionId.asKnown().isPresent) 1 else 0) +
- (if (pendingTransactionId.asKnown().isPresent) 1 else 0) +
- (if (releasedAt.asKnown().isPresent) 1 else 0) +
- (status.asKnown().getOrNull()?.validity() ?: 0) +
- (type.asKnown().getOrNull()?.validity() ?: 0)
-
- /** The [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) code for the hold's currency. */
- class Currency @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 {
-
- /** Canadian Dollar (CAD) */
- @JvmField val CAD = of("CAD")
-
- /** Swiss Franc (CHF) */
- @JvmField val CHF = of("CHF")
-
- /** Euro (EUR) */
- @JvmField val EUR = of("EUR")
-
- /** British Pound (GBP) */
- @JvmField val GBP = of("GBP")
-
- /** Japanese Yen (JPY) */
- @JvmField val JPY = of("JPY")
-
- /** US Dollar (USD) */
- @JvmField val USD = of("USD")
-
- @JvmStatic fun of(value: String) = Currency(JsonField.of(value))
- }
-
- /** An enum containing [Currency]'s known values. */
- enum class Known {
- /** Canadian Dollar (CAD) */
- CAD,
- /** Swiss Franc (CHF) */
- CHF,
- /** Euro (EUR) */
- EUR,
- /** British Pound (GBP) */
- GBP,
- /** Japanese Yen (JPY) */
- JPY,
- /** US Dollar (USD) */
- 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,
- /** Swiss Franc (CHF) */
- CHF,
- /** Euro (EUR) */
- EUR,
- /** British Pound (GBP) */
- GBP,
- /** Japanese Yen (JPY) */
- 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
- CHF -> Value.CHF
- EUR -> Value.EUR
- GBP -> Value.GBP
- JPY -> Value.JPY
- USD -> Value.USD
- 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
- CHF -> Known.CHF
- EUR -> Known.EUR
- GBP -> Known.GBP
- JPY -> Known.JPY
- USD -> Known.USD
- else -> throw IncreaseInvalidDataException("Unknown Currency: $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(): Currency = 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 Currency && value == other.value
- }
-
- override fun hashCode() = value.hashCode()
-
- override fun toString() = value.toString()
- }
-
- /** The status of the hold. */
- class Status @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 {
-
- /** Funds are still being held. */
- @JvmField val HELD = of("held")
-
- /** Funds have been released. */
- @JvmField val COMPLETE = of("complete")
-
- @JvmStatic fun of(value: String) = Status(JsonField.of(value))
- }
-
- /** An enum containing [Status]'s known values. */
- enum class Known {
- /** Funds are still being held. */
- HELD,
- /** Funds have been released. */
- COMPLETE,
- }
-
- /**
- * 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 {
- /** Funds are still being held. */
- HELD,
- /** Funds have been released. */
- COMPLETE,
- /** 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) {
- HELD -> Value.HELD
- COMPLETE -> Value.COMPLETE
- 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) {
- HELD -> Known.HELD
- COMPLETE -> Known.COMPLETE
- else -> throw IncreaseInvalidDataException("Unknown Status: $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(): Status = 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 Status && value == other.value
- }
-
- override fun hashCode() = value.hashCode()
-
- override fun toString() = value.toString()
- }
-
- /**
- * A constant representing the object's type. For this resource it will always be
- * `inbound_funds_hold`.
- */
- class Type @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 INBOUND_FUNDS_HOLD = of("inbound_funds_hold")
-
- @JvmStatic fun of(value: String) = Type(JsonField.of(value))
- }
-
- /** An enum containing [Type]'s known values. */
- enum class Known {
- INBOUND_FUNDS_HOLD
- }
-
- /**
- * 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 {
- INBOUND_FUNDS_HOLD,
- /** 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) {
- INBOUND_FUNDS_HOLD -> Value.INBOUND_FUNDS_HOLD
- 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) {
- INBOUND_FUNDS_HOLD -> Known.INBOUND_FUNDS_HOLD
- else -> throw IncreaseInvalidDataException("Unknown Type: $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(): Type = 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 Type && value == other.value
- }
-
- override fun hashCode() = value.hashCode()
-
- override fun toString() = value.toString()
- }
-
- override fun equals(other: Any?): Boolean {
- if (this === other) {
- return true
- }
-
- return other is InboundFundsHoldReleaseResponse &&
- id == other.id &&
- amount == other.amount &&
- automaticallyReleasesAt == other.automaticallyReleasesAt &&
- createdAt == other.createdAt &&
- currency == other.currency &&
- heldTransactionId == other.heldTransactionId &&
- pendingTransactionId == other.pendingTransactionId &&
- releasedAt == other.releasedAt &&
- status == other.status &&
- type == other.type &&
- additionalProperties == other.additionalProperties
- }
-
- private val hashCode: Int by lazy {
- Objects.hash(
- id,
- amount,
- automaticallyReleasesAt,
- createdAt,
- currency,
- heldTransactionId,
- pendingTransactionId,
- releasedAt,
- status,
- type,
- additionalProperties,
- )
- }
-
- override fun hashCode(): Int = hashCode
-
- override fun toString() =
- "InboundFundsHoldReleaseResponse{id=$id, amount=$amount, automaticallyReleasesAt=$automaticallyReleasesAt, createdAt=$createdAt, currency=$currency, heldTransactionId=$heldTransactionId, pendingTransactionId=$pendingTransactionId, releasedAt=$releasedAt, status=$status, type=$type, additionalProperties=$additionalProperties}"
-}
diff --git a/increase-java-core/src/main/kotlin/com/increase/api/models/simulations/inboundfundsholds/InboundFundsHoldReleaseParams.kt b/increase-java-core/src/main/kotlin/com/increase/api/models/simulations/pendingtransactions/PendingTransactionReleaseInboundFundsHoldParams.kt
similarity index 73%
rename from increase-java-core/src/main/kotlin/com/increase/api/models/simulations/inboundfundsholds/InboundFundsHoldReleaseParams.kt
rename to increase-java-core/src/main/kotlin/com/increase/api/models/simulations/pendingtransactions/PendingTransactionReleaseInboundFundsHoldParams.kt
index 55b27f095..e011f49b0 100644
--- a/increase-java-core/src/main/kotlin/com/increase/api/models/simulations/inboundfundsholds/InboundFundsHoldReleaseParams.kt
+++ b/increase-java-core/src/main/kotlin/com/increase/api/models/simulations/pendingtransactions/PendingTransactionReleaseInboundFundsHoldParams.kt
@@ -1,6 +1,6 @@
// File generated from our OpenAPI spec by Stainless.
-package com.increase.api.models.simulations.inboundfundsholds
+package com.increase.api.models.simulations.pendingtransactions
import com.increase.api.core.JsonValue
import com.increase.api.core.Params
@@ -13,18 +13,21 @@ import kotlin.jvm.optionals.getOrNull
/**
* This endpoint simulates immediately releasing an Inbound Funds Hold, which might be created as a
- * result of e.g., an ACH debit.
+ * result of, for example, an ACH debit.
*/
-class InboundFundsHoldReleaseParams
+class PendingTransactionReleaseInboundFundsHoldParams
private constructor(
- private val inboundFundsHoldId: String?,
+ private val pendingTransactionId: String?,
private val additionalHeaders: Headers,
private val additionalQueryParams: QueryParams,
private val additionalBodyProperties: Map,
) : Params {
- /** The inbound funds hold to release. */
- fun inboundFundsHoldId(): Optional = Optional.ofNullable(inboundFundsHoldId)
+ /**
+ * The pending transaction to release. The pending transaction must have a `inbound_funds_hold`
+ * source.
+ */
+ fun pendingTransactionId(): Optional = Optional.ofNullable(pendingTransactionId)
/** Additional body properties to send with the request. */
fun _additionalBodyProperties(): Map = additionalBodyProperties
@@ -39,42 +42,53 @@ private constructor(
companion object {
- @JvmStatic fun none(): InboundFundsHoldReleaseParams = builder().build()
+ @JvmStatic fun none(): PendingTransactionReleaseInboundFundsHoldParams = builder().build()
/**
* Returns a mutable builder for constructing an instance of
- * [InboundFundsHoldReleaseParams].
+ * [PendingTransactionReleaseInboundFundsHoldParams].
*/
@JvmStatic fun builder() = Builder()
}
- /** A builder for [InboundFundsHoldReleaseParams]. */
+ /** A builder for [PendingTransactionReleaseInboundFundsHoldParams]. */
class Builder internal constructor() {
- private var inboundFundsHoldId: String? = null
+ private var pendingTransactionId: String? = null
private var additionalHeaders: Headers.Builder = Headers.builder()
private var additionalQueryParams: QueryParams.Builder = QueryParams.builder()
private var additionalBodyProperties: MutableMap = mutableMapOf()
@JvmSynthetic
- internal fun from(inboundFundsHoldReleaseParams: InboundFundsHoldReleaseParams) = apply {
- inboundFundsHoldId = inboundFundsHoldReleaseParams.inboundFundsHoldId
- additionalHeaders = inboundFundsHoldReleaseParams.additionalHeaders.toBuilder()
- additionalQueryParams = inboundFundsHoldReleaseParams.additionalQueryParams.toBuilder()
+ internal fun from(
+ pendingTransactionReleaseInboundFundsHoldParams:
+ PendingTransactionReleaseInboundFundsHoldParams
+ ) = apply {
+ pendingTransactionId =
+ pendingTransactionReleaseInboundFundsHoldParams.pendingTransactionId
+ additionalHeaders =
+ pendingTransactionReleaseInboundFundsHoldParams.additionalHeaders.toBuilder()
+ additionalQueryParams =
+ pendingTransactionReleaseInboundFundsHoldParams.additionalQueryParams.toBuilder()
additionalBodyProperties =
- inboundFundsHoldReleaseParams.additionalBodyProperties.toMutableMap()
+ pendingTransactionReleaseInboundFundsHoldParams.additionalBodyProperties
+ .toMutableMap()
}
- /** The inbound funds hold to release. */
- fun inboundFundsHoldId(inboundFundsHoldId: String?) = apply {
- this.inboundFundsHoldId = inboundFundsHoldId
+ /**
+ * The pending transaction to release. The pending transaction must have a
+ * `inbound_funds_hold` source.
+ */
+ fun pendingTransactionId(pendingTransactionId: String?) = apply {
+ this.pendingTransactionId = pendingTransactionId
}
/**
- * Alias for calling [Builder.inboundFundsHoldId] with `inboundFundsHoldId.orElse(null)`.
+ * Alias for calling [Builder.pendingTransactionId] with
+ * `pendingTransactionId.orElse(null)`.
*/
- fun inboundFundsHoldId(inboundFundsHoldId: Optional) =
- inboundFundsHoldId(inboundFundsHoldId.getOrNull())
+ fun pendingTransactionId(pendingTransactionId: Optional) =
+ pendingTransactionId(pendingTransactionId.getOrNull())
fun additionalHeaders(additionalHeaders: Headers) = apply {
this.additionalHeaders.clear()
@@ -197,13 +211,13 @@ private constructor(
}
/**
- * Returns an immutable instance of [InboundFundsHoldReleaseParams].
+ * Returns an immutable instance of [PendingTransactionReleaseInboundFundsHoldParams].
*
* Further updates to this [Builder] will not mutate the returned instance.
*/
- fun build(): InboundFundsHoldReleaseParams =
- InboundFundsHoldReleaseParams(
- inboundFundsHoldId,
+ fun build(): PendingTransactionReleaseInboundFundsHoldParams =
+ PendingTransactionReleaseInboundFundsHoldParams(
+ pendingTransactionId,
additionalHeaders.build(),
additionalQueryParams.build(),
additionalBodyProperties.toImmutable(),
@@ -215,7 +229,7 @@ private constructor(
fun _pathParam(index: Int): String =
when (index) {
- 0 -> inboundFundsHoldId ?: ""
+ 0 -> pendingTransactionId ?: ""
else -> ""
}
@@ -228,8 +242,8 @@ private constructor(
return true
}
- return other is InboundFundsHoldReleaseParams &&
- inboundFundsHoldId == other.inboundFundsHoldId &&
+ return other is PendingTransactionReleaseInboundFundsHoldParams &&
+ pendingTransactionId == other.pendingTransactionId &&
additionalHeaders == other.additionalHeaders &&
additionalQueryParams == other.additionalQueryParams &&
additionalBodyProperties == other.additionalBodyProperties
@@ -237,12 +251,12 @@ private constructor(
override fun hashCode(): Int =
Objects.hash(
- inboundFundsHoldId,
+ pendingTransactionId,
additionalHeaders,
additionalQueryParams,
additionalBodyProperties,
)
override fun toString() =
- "InboundFundsHoldReleaseParams{inboundFundsHoldId=$inboundFundsHoldId, additionalHeaders=$additionalHeaders, additionalQueryParams=$additionalQueryParams, additionalBodyProperties=$additionalBodyProperties}"
+ "PendingTransactionReleaseInboundFundsHoldParams{pendingTransactionId=$pendingTransactionId, additionalHeaders=$additionalHeaders, additionalQueryParams=$additionalQueryParams, additionalBodyProperties=$additionalBodyProperties}"
}
diff --git a/increase-java-core/src/main/kotlin/com/increase/api/services/async/SimulationServiceAsync.kt b/increase-java-core/src/main/kotlin/com/increase/api/services/async/SimulationServiceAsync.kt
index b59f3d6ea..291b3b9a3 100644
--- a/increase-java-core/src/main/kotlin/com/increase/api/services/async/SimulationServiceAsync.kt
+++ b/increase-java-core/src/main/kotlin/com/increase/api/services/async/SimulationServiceAsync.kt
@@ -21,12 +21,12 @@ import com.increase.api.services.async.simulations.DigitalWalletTokenRequestServ
import com.increase.api.services.async.simulations.DocumentServiceAsync
import com.increase.api.services.async.simulations.InboundAchTransferServiceAsync
import com.increase.api.services.async.simulations.InboundCheckDepositServiceAsync
-import com.increase.api.services.async.simulations.InboundFundsHoldServiceAsync
import com.increase.api.services.async.simulations.InboundMailItemServiceAsync
import com.increase.api.services.async.simulations.InboundRealTimePaymentsTransferServiceAsync
import com.increase.api.services.async.simulations.InboundWireDrawdownRequestServiceAsync
import com.increase.api.services.async.simulations.InboundWireTransferServiceAsync
import com.increase.api.services.async.simulations.InterestPaymentServiceAsync
+import com.increase.api.services.async.simulations.PendingTransactionServiceAsync
import com.increase.api.services.async.simulations.PhysicalCardServiceAsync
import com.increase.api.services.async.simulations.ProgramServiceAsync
import com.increase.api.services.async.simulations.RealTimePaymentsTransferServiceAsync
@@ -70,7 +70,7 @@ interface SimulationServiceAsync {
fun digitalWalletTokenRequests(): DigitalWalletTokenRequestServiceAsync
- fun inboundFundsHolds(): InboundFundsHoldServiceAsync
+ fun pendingTransactions(): PendingTransactionServiceAsync
fun accountTransfers(): AccountTransferServiceAsync
@@ -143,7 +143,7 @@ interface SimulationServiceAsync {
fun digitalWalletTokenRequests(): DigitalWalletTokenRequestServiceAsync.WithRawResponse
- fun inboundFundsHolds(): InboundFundsHoldServiceAsync.WithRawResponse
+ fun pendingTransactions(): PendingTransactionServiceAsync.WithRawResponse
fun accountTransfers(): AccountTransferServiceAsync.WithRawResponse
diff --git a/increase-java-core/src/main/kotlin/com/increase/api/services/async/SimulationServiceAsyncImpl.kt b/increase-java-core/src/main/kotlin/com/increase/api/services/async/SimulationServiceAsyncImpl.kt
index b641f550b..6235fa644 100644
--- a/increase-java-core/src/main/kotlin/com/increase/api/services/async/SimulationServiceAsyncImpl.kt
+++ b/increase-java-core/src/main/kotlin/com/increase/api/services/async/SimulationServiceAsyncImpl.kt
@@ -39,8 +39,6 @@ import com.increase.api.services.async.simulations.InboundAchTransferServiceAsyn
import com.increase.api.services.async.simulations.InboundAchTransferServiceAsyncImpl
import com.increase.api.services.async.simulations.InboundCheckDepositServiceAsync
import com.increase.api.services.async.simulations.InboundCheckDepositServiceAsyncImpl
-import com.increase.api.services.async.simulations.InboundFundsHoldServiceAsync
-import com.increase.api.services.async.simulations.InboundFundsHoldServiceAsyncImpl
import com.increase.api.services.async.simulations.InboundMailItemServiceAsync
import com.increase.api.services.async.simulations.InboundMailItemServiceAsyncImpl
import com.increase.api.services.async.simulations.InboundRealTimePaymentsTransferServiceAsync
@@ -51,6 +49,8 @@ import com.increase.api.services.async.simulations.InboundWireTransferServiceAsy
import com.increase.api.services.async.simulations.InboundWireTransferServiceAsyncImpl
import com.increase.api.services.async.simulations.InterestPaymentServiceAsync
import com.increase.api.services.async.simulations.InterestPaymentServiceAsyncImpl
+import com.increase.api.services.async.simulations.PendingTransactionServiceAsync
+import com.increase.api.services.async.simulations.PendingTransactionServiceAsyncImpl
import com.increase.api.services.async.simulations.PhysicalCardServiceAsync
import com.increase.api.services.async.simulations.PhysicalCardServiceAsyncImpl
import com.increase.api.services.async.simulations.ProgramServiceAsync
@@ -114,8 +114,8 @@ class SimulationServiceAsyncImpl internal constructor(private val clientOptions:
DigitalWalletTokenRequestServiceAsyncImpl(clientOptions)
}
- private val inboundFundsHolds: InboundFundsHoldServiceAsync by lazy {
- InboundFundsHoldServiceAsyncImpl(clientOptions)
+ private val pendingTransactions: PendingTransactionServiceAsync by lazy {
+ PendingTransactionServiceAsyncImpl(clientOptions)
}
private val accountTransfers: AccountTransferServiceAsync by lazy {
@@ -212,7 +212,7 @@ class SimulationServiceAsyncImpl internal constructor(private val clientOptions:
override fun digitalWalletTokenRequests(): DigitalWalletTokenRequestServiceAsync =
digitalWalletTokenRequests
- override fun inboundFundsHolds(): InboundFundsHoldServiceAsync = inboundFundsHolds
+ override fun pendingTransactions(): PendingTransactionServiceAsync = pendingTransactions
override fun accountTransfers(): AccountTransferServiceAsync = accountTransfers
@@ -301,8 +301,8 @@ class SimulationServiceAsyncImpl internal constructor(private val clientOptions:
DigitalWalletTokenRequestServiceAsyncImpl.WithRawResponseImpl(clientOptions)
}
- private val inboundFundsHolds: InboundFundsHoldServiceAsync.WithRawResponse by lazy {
- InboundFundsHoldServiceAsyncImpl.WithRawResponseImpl(clientOptions)
+ private val pendingTransactions: PendingTransactionServiceAsync.WithRawResponse by lazy {
+ PendingTransactionServiceAsyncImpl.WithRawResponseImpl(clientOptions)
}
private val accountTransfers: AccountTransferServiceAsync.WithRawResponse by lazy {
@@ -410,8 +410,8 @@ class SimulationServiceAsyncImpl internal constructor(private val clientOptions:
override fun digitalWalletTokenRequests():
DigitalWalletTokenRequestServiceAsync.WithRawResponse = digitalWalletTokenRequests
- override fun inboundFundsHolds(): InboundFundsHoldServiceAsync.WithRawResponse =
- inboundFundsHolds
+ override fun pendingTransactions(): PendingTransactionServiceAsync.WithRawResponse =
+ pendingTransactions
override fun accountTransfers(): AccountTransferServiceAsync.WithRawResponse =
accountTransfers
diff --git a/increase-java-core/src/main/kotlin/com/increase/api/services/async/simulations/InboundFundsHoldServiceAsync.kt b/increase-java-core/src/main/kotlin/com/increase/api/services/async/simulations/InboundFundsHoldServiceAsync.kt
deleted file mode 100644
index 54547eee4..000000000
--- a/increase-java-core/src/main/kotlin/com/increase/api/services/async/simulations/InboundFundsHoldServiceAsync.kt
+++ /dev/null
@@ -1,129 +0,0 @@
-// File generated from our OpenAPI spec by Stainless.
-
-package com.increase.api.services.async.simulations
-
-import com.increase.api.core.ClientOptions
-import com.increase.api.core.RequestOptions
-import com.increase.api.core.http.HttpResponseFor
-import com.increase.api.models.simulations.inboundfundsholds.InboundFundsHoldReleaseParams
-import com.increase.api.models.simulations.inboundfundsholds.InboundFundsHoldReleaseResponse
-import java.util.concurrent.CompletableFuture
-import java.util.function.Consumer
-
-interface InboundFundsHoldServiceAsync {
-
- /**
- * Returns a view of this service that provides access to raw HTTP responses for each method.
- */
- fun withRawResponse(): WithRawResponse
-
- /**
- * Returns a view of this service with the given option modifications applied.
- *
- * The original service is not modified.
- */
- fun withOptions(modifier: Consumer): InboundFundsHoldServiceAsync
-
- /**
- * This endpoint simulates immediately releasing an Inbound Funds Hold, which might be created
- * as a result of e.g., an ACH debit.
- */
- fun release(inboundFundsHoldId: String): CompletableFuture =
- release(inboundFundsHoldId, InboundFundsHoldReleaseParams.none())
-
- /** @see release */
- fun release(
- inboundFundsHoldId: String,
- params: InboundFundsHoldReleaseParams = InboundFundsHoldReleaseParams.none(),
- requestOptions: RequestOptions = RequestOptions.none(),
- ): CompletableFuture =
- release(params.toBuilder().inboundFundsHoldId(inboundFundsHoldId).build(), requestOptions)
-
- /** @see release */
- fun release(
- inboundFundsHoldId: String,
- params: InboundFundsHoldReleaseParams = InboundFundsHoldReleaseParams.none(),
- ): CompletableFuture =
- release(inboundFundsHoldId, params, RequestOptions.none())
-
- /** @see release */
- fun release(
- params: InboundFundsHoldReleaseParams,
- requestOptions: RequestOptions = RequestOptions.none(),
- ): CompletableFuture
-
- /** @see release */
- fun release(
- params: InboundFundsHoldReleaseParams
- ): CompletableFuture = release(params, RequestOptions.none())
-
- /** @see release */
- fun release(
- inboundFundsHoldId: String,
- requestOptions: RequestOptions,
- ): CompletableFuture =
- release(inboundFundsHoldId, InboundFundsHoldReleaseParams.none(), requestOptions)
-
- /**
- * A view of [InboundFundsHoldServiceAsync] that provides access to raw HTTP responses for each
- * method.
- */
- interface WithRawResponse {
-
- /**
- * Returns a view of this service with the given option modifications applied.
- *
- * The original service is not modified.
- */
- fun withOptions(
- modifier: Consumer
- ): InboundFundsHoldServiceAsync.WithRawResponse
-
- /**
- * Returns a raw HTTP response for `post
- * /simulations/inbound_funds_holds/{inbound_funds_hold_id}/release`, but is otherwise the
- * same as [InboundFundsHoldServiceAsync.release].
- */
- fun release(
- inboundFundsHoldId: String
- ): CompletableFuture> =
- release(inboundFundsHoldId, InboundFundsHoldReleaseParams.none())
-
- /** @see release */
- fun release(
- inboundFundsHoldId: String,
- params: InboundFundsHoldReleaseParams = InboundFundsHoldReleaseParams.none(),
- requestOptions: RequestOptions = RequestOptions.none(),
- ): CompletableFuture> =
- release(
- params.toBuilder().inboundFundsHoldId(inboundFundsHoldId).build(),
- requestOptions,
- )
-
- /** @see release */
- fun release(
- inboundFundsHoldId: String,
- params: InboundFundsHoldReleaseParams = InboundFundsHoldReleaseParams.none(),
- ): CompletableFuture> =
- release(inboundFundsHoldId, params, RequestOptions.none())
-
- /** @see release */
- fun release(
- params: InboundFundsHoldReleaseParams,
- requestOptions: RequestOptions = RequestOptions.none(),
- ): CompletableFuture>
-
- /** @see release */
- fun release(
- params: InboundFundsHoldReleaseParams
- ): CompletableFuture> =
- release(params, RequestOptions.none())
-
- /** @see release */
- fun release(
- inboundFundsHoldId: String,
- requestOptions: RequestOptions,
- ): CompletableFuture> =
- release(inboundFundsHoldId, InboundFundsHoldReleaseParams.none(), requestOptions)
- }
-}
diff --git a/increase-java-core/src/main/kotlin/com/increase/api/services/async/simulations/PendingTransactionServiceAsync.kt b/increase-java-core/src/main/kotlin/com/increase/api/services/async/simulations/PendingTransactionServiceAsync.kt
new file mode 100644
index 000000000..044d5ad23
--- /dev/null
+++ b/increase-java-core/src/main/kotlin/com/increase/api/services/async/simulations/PendingTransactionServiceAsync.kt
@@ -0,0 +1,153 @@
+// File generated from our OpenAPI spec by Stainless.
+
+package com.increase.api.services.async.simulations
+
+import com.increase.api.core.ClientOptions
+import com.increase.api.core.RequestOptions
+import com.increase.api.core.http.HttpResponseFor
+import com.increase.api.models.pendingtransactions.PendingTransaction
+import com.increase.api.models.simulations.pendingtransactions.PendingTransactionReleaseInboundFundsHoldParams
+import java.util.concurrent.CompletableFuture
+import java.util.function.Consumer
+
+interface PendingTransactionServiceAsync {
+
+ /**
+ * Returns a view of this service that provides access to raw HTTP responses for each method.
+ */
+ fun withRawResponse(): WithRawResponse
+
+ /**
+ * Returns a view of this service with the given option modifications applied.
+ *
+ * The original service is not modified.
+ */
+ fun withOptions(modifier: Consumer): PendingTransactionServiceAsync
+
+ /**
+ * This endpoint simulates immediately releasing an Inbound Funds Hold, which might be created
+ * as a result of, for example, an ACH debit.
+ */
+ fun releaseInboundFundsHold(
+ pendingTransactionId: String
+ ): CompletableFuture =
+ releaseInboundFundsHold(
+ pendingTransactionId,
+ PendingTransactionReleaseInboundFundsHoldParams.none(),
+ )
+
+ /** @see releaseInboundFundsHold */
+ fun releaseInboundFundsHold(
+ pendingTransactionId: String,
+ params: PendingTransactionReleaseInboundFundsHoldParams =
+ PendingTransactionReleaseInboundFundsHoldParams.none(),
+ requestOptions: RequestOptions = RequestOptions.none(),
+ ): CompletableFuture =
+ releaseInboundFundsHold(
+ params.toBuilder().pendingTransactionId(pendingTransactionId).build(),
+ requestOptions,
+ )
+
+ /** @see releaseInboundFundsHold */
+ fun releaseInboundFundsHold(
+ pendingTransactionId: String,
+ params: PendingTransactionReleaseInboundFundsHoldParams =
+ PendingTransactionReleaseInboundFundsHoldParams.none(),
+ ): CompletableFuture =
+ releaseInboundFundsHold(pendingTransactionId, params, RequestOptions.none())
+
+ /** @see releaseInboundFundsHold */
+ fun releaseInboundFundsHold(
+ params: PendingTransactionReleaseInboundFundsHoldParams,
+ requestOptions: RequestOptions = RequestOptions.none(),
+ ): CompletableFuture
+
+ /** @see releaseInboundFundsHold */
+ fun releaseInboundFundsHold(
+ params: PendingTransactionReleaseInboundFundsHoldParams
+ ): CompletableFuture =
+ releaseInboundFundsHold(params, RequestOptions.none())
+
+ /** @see releaseInboundFundsHold */
+ fun releaseInboundFundsHold(
+ pendingTransactionId: String,
+ requestOptions: RequestOptions,
+ ): CompletableFuture =
+ releaseInboundFundsHold(
+ pendingTransactionId,
+ PendingTransactionReleaseInboundFundsHoldParams.none(),
+ requestOptions,
+ )
+
+ /**
+ * A view of [PendingTransactionServiceAsync] that provides access to raw HTTP responses for
+ * each method.
+ */
+ interface WithRawResponse {
+
+ /**
+ * Returns a view of this service with the given option modifications applied.
+ *
+ * The original service is not modified.
+ */
+ fun withOptions(
+ modifier: Consumer
+ ): PendingTransactionServiceAsync.WithRawResponse
+
+ /**
+ * Returns a raw HTTP response for `post
+ * /simulations/pending_transactions/{pending_transaction_id}/release_inbound_funds_hold`,
+ * but is otherwise the same as [PendingTransactionServiceAsync.releaseInboundFundsHold].
+ */
+ fun releaseInboundFundsHold(
+ pendingTransactionId: String
+ ): CompletableFuture> =
+ releaseInboundFundsHold(
+ pendingTransactionId,
+ PendingTransactionReleaseInboundFundsHoldParams.none(),
+ )
+
+ /** @see releaseInboundFundsHold */
+ fun releaseInboundFundsHold(
+ pendingTransactionId: String,
+ params: PendingTransactionReleaseInboundFundsHoldParams =
+ PendingTransactionReleaseInboundFundsHoldParams.none(),
+ requestOptions: RequestOptions = RequestOptions.none(),
+ ): CompletableFuture> =
+ releaseInboundFundsHold(
+ params.toBuilder().pendingTransactionId(pendingTransactionId).build(),
+ requestOptions,
+ )
+
+ /** @see releaseInboundFundsHold */
+ fun releaseInboundFundsHold(
+ pendingTransactionId: String,
+ params: PendingTransactionReleaseInboundFundsHoldParams =
+ PendingTransactionReleaseInboundFundsHoldParams.none(),
+ ): CompletableFuture> =
+ releaseInboundFundsHold(pendingTransactionId, params, RequestOptions.none())
+
+ /** @see releaseInboundFundsHold */
+ fun releaseInboundFundsHold(
+ params: PendingTransactionReleaseInboundFundsHoldParams,
+ requestOptions: RequestOptions = RequestOptions.none(),
+ ): CompletableFuture>
+
+ /** @see releaseInboundFundsHold */
+ fun releaseInboundFundsHold(
+ params: PendingTransactionReleaseInboundFundsHoldParams
+ ): CompletableFuture> =
+ releaseInboundFundsHold(params, RequestOptions.none())
+
+ /** @see releaseInboundFundsHold */
+ fun releaseInboundFundsHold(
+ pendingTransactionId: String,
+ requestOptions: RequestOptions,
+ ): CompletableFuture> =
+ releaseInboundFundsHold(
+ pendingTransactionId,
+ PendingTransactionReleaseInboundFundsHoldParams.none(),
+ requestOptions,
+ )
+ }
+}
diff --git a/increase-java-core/src/main/kotlin/com/increase/api/services/async/simulations/InboundFundsHoldServiceAsyncImpl.kt b/increase-java-core/src/main/kotlin/com/increase/api/services/async/simulations/PendingTransactionServiceAsyncImpl.kt
similarity index 61%
rename from increase-java-core/src/main/kotlin/com/increase/api/services/async/simulations/InboundFundsHoldServiceAsyncImpl.kt
rename to increase-java-core/src/main/kotlin/com/increase/api/services/async/simulations/PendingTransactionServiceAsyncImpl.kt
index a440d2e92..bdfda8496 100644
--- a/increase-java-core/src/main/kotlin/com/increase/api/services/async/simulations/InboundFundsHoldServiceAsyncImpl.kt
+++ b/increase-java-core/src/main/kotlin/com/increase/api/services/async/simulations/PendingTransactionServiceAsyncImpl.kt
@@ -16,65 +16,68 @@ import com.increase.api.core.http.HttpResponseFor
import com.increase.api.core.http.json
import com.increase.api.core.http.parseable
import com.increase.api.core.prepareAsync
-import com.increase.api.models.simulations.inboundfundsholds.InboundFundsHoldReleaseParams
-import com.increase.api.models.simulations.inboundfundsholds.InboundFundsHoldReleaseResponse
+import com.increase.api.models.pendingtransactions.PendingTransaction
+import com.increase.api.models.simulations.pendingtransactions.PendingTransactionReleaseInboundFundsHoldParams
import java.util.concurrent.CompletableFuture
import java.util.function.Consumer
import kotlin.jvm.optionals.getOrNull
-class InboundFundsHoldServiceAsyncImpl
-internal constructor(private val clientOptions: ClientOptions) : InboundFundsHoldServiceAsync {
+class PendingTransactionServiceAsyncImpl
+internal constructor(private val clientOptions: ClientOptions) : PendingTransactionServiceAsync {
- private val withRawResponse: InboundFundsHoldServiceAsync.WithRawResponse by lazy {
+ private val withRawResponse: PendingTransactionServiceAsync.WithRawResponse by lazy {
WithRawResponseImpl(clientOptions)
}
- override fun withRawResponse(): InboundFundsHoldServiceAsync.WithRawResponse = withRawResponse
+ override fun withRawResponse(): PendingTransactionServiceAsync.WithRawResponse = withRawResponse
override fun withOptions(
modifier: Consumer
- ): InboundFundsHoldServiceAsync =
- InboundFundsHoldServiceAsyncImpl(clientOptions.toBuilder().apply(modifier::accept).build())
+ ): PendingTransactionServiceAsync =
+ PendingTransactionServiceAsyncImpl(
+ clientOptions.toBuilder().apply(modifier::accept).build()
+ )
- override fun release(
- params: InboundFundsHoldReleaseParams,
+ override fun releaseInboundFundsHold(
+ params: PendingTransactionReleaseInboundFundsHoldParams,
requestOptions: RequestOptions,
- ): CompletableFuture =
- // post /simulations/inbound_funds_holds/{inbound_funds_hold_id}/release
- withRawResponse().release(params, requestOptions).thenApply { it.parse() }
+ ): CompletableFuture =
+ // post
+ // /simulations/pending_transactions/{pending_transaction_id}/release_inbound_funds_hold
+ withRawResponse().releaseInboundFundsHold(params, requestOptions).thenApply { it.parse() }
class WithRawResponseImpl internal constructor(private val clientOptions: ClientOptions) :
- InboundFundsHoldServiceAsync.WithRawResponse {
+ PendingTransactionServiceAsync.WithRawResponse {
private val errorHandler: Handler =
errorHandler(errorBodyHandler(clientOptions.jsonMapper))
override fun withOptions(
modifier: Consumer
- ): InboundFundsHoldServiceAsync.WithRawResponse =
- InboundFundsHoldServiceAsyncImpl.WithRawResponseImpl(
+ ): PendingTransactionServiceAsync.WithRawResponse =
+ PendingTransactionServiceAsyncImpl.WithRawResponseImpl(
clientOptions.toBuilder().apply(modifier::accept).build()
)
- private val releaseHandler: Handler =
- jsonHandler(clientOptions.jsonMapper)
+ private val releaseInboundFundsHoldHandler: Handler =
+ jsonHandler(clientOptions.jsonMapper)
- override fun release(
- params: InboundFundsHoldReleaseParams,
+ override fun releaseInboundFundsHold(
+ params: PendingTransactionReleaseInboundFundsHoldParams,
requestOptions: RequestOptions,
- ): CompletableFuture> {
+ ): CompletableFuture> {
// We check here instead of in the params builder because this can be specified
// positionally or in the params class.
- checkRequired("inboundFundsHoldId", params.inboundFundsHoldId().getOrNull())
+ checkRequired("pendingTransactionId", params.pendingTransactionId().getOrNull())
val request =
HttpRequest.builder()
.method(HttpMethod.POST)
.baseUrl(clientOptions.baseUrl())
.addPathSegments(
"simulations",
- "inbound_funds_holds",
+ "pending_transactions",
params._pathParam(0),
- "release",
+ "release_inbound_funds_hold",
)
.apply { params._body().ifPresent { body(json(clientOptions.jsonMapper, it)) } }
.build()
@@ -85,7 +88,7 @@ internal constructor(private val clientOptions: ClientOptions) : InboundFundsHol
.thenApply { response ->
errorHandler.handle(response).parseable {
response
- .use { releaseHandler.handle(it) }
+ .use { releaseInboundFundsHoldHandler.handle(it) }
.also {
if (requestOptions.responseValidation!!) {
it.validate()
diff --git a/increase-java-core/src/main/kotlin/com/increase/api/services/blocking/SimulationService.kt b/increase-java-core/src/main/kotlin/com/increase/api/services/blocking/SimulationService.kt
index 6aa15a4c8..fa2129699 100644
--- a/increase-java-core/src/main/kotlin/com/increase/api/services/blocking/SimulationService.kt
+++ b/increase-java-core/src/main/kotlin/com/increase/api/services/blocking/SimulationService.kt
@@ -21,12 +21,12 @@ import com.increase.api.services.blocking.simulations.DigitalWalletTokenRequestS
import com.increase.api.services.blocking.simulations.DocumentService
import com.increase.api.services.blocking.simulations.InboundAchTransferService
import com.increase.api.services.blocking.simulations.InboundCheckDepositService
-import com.increase.api.services.blocking.simulations.InboundFundsHoldService
import com.increase.api.services.blocking.simulations.InboundMailItemService
import com.increase.api.services.blocking.simulations.InboundRealTimePaymentsTransferService
import com.increase.api.services.blocking.simulations.InboundWireDrawdownRequestService
import com.increase.api.services.blocking.simulations.InboundWireTransferService
import com.increase.api.services.blocking.simulations.InterestPaymentService
+import com.increase.api.services.blocking.simulations.PendingTransactionService
import com.increase.api.services.blocking.simulations.PhysicalCardService
import com.increase.api.services.blocking.simulations.ProgramService
import com.increase.api.services.blocking.simulations.RealTimePaymentsTransferService
@@ -70,7 +70,7 @@ interface SimulationService {
fun digitalWalletTokenRequests(): DigitalWalletTokenRequestService
- fun inboundFundsHolds(): InboundFundsHoldService
+ fun pendingTransactions(): PendingTransactionService
fun accountTransfers(): AccountTransferService
@@ -140,7 +140,7 @@ interface SimulationService {
fun digitalWalletTokenRequests(): DigitalWalletTokenRequestService.WithRawResponse
- fun inboundFundsHolds(): InboundFundsHoldService.WithRawResponse
+ fun pendingTransactions(): PendingTransactionService.WithRawResponse
fun accountTransfers(): AccountTransferService.WithRawResponse
diff --git a/increase-java-core/src/main/kotlin/com/increase/api/services/blocking/SimulationServiceImpl.kt b/increase-java-core/src/main/kotlin/com/increase/api/services/blocking/SimulationServiceImpl.kt
index 3306bb0d7..4f5a1e117 100644
--- a/increase-java-core/src/main/kotlin/com/increase/api/services/blocking/SimulationServiceImpl.kt
+++ b/increase-java-core/src/main/kotlin/com/increase/api/services/blocking/SimulationServiceImpl.kt
@@ -39,8 +39,6 @@ import com.increase.api.services.blocking.simulations.InboundAchTransferService
import com.increase.api.services.blocking.simulations.InboundAchTransferServiceImpl
import com.increase.api.services.blocking.simulations.InboundCheckDepositService
import com.increase.api.services.blocking.simulations.InboundCheckDepositServiceImpl
-import com.increase.api.services.blocking.simulations.InboundFundsHoldService
-import com.increase.api.services.blocking.simulations.InboundFundsHoldServiceImpl
import com.increase.api.services.blocking.simulations.InboundMailItemService
import com.increase.api.services.blocking.simulations.InboundMailItemServiceImpl
import com.increase.api.services.blocking.simulations.InboundRealTimePaymentsTransferService
@@ -51,6 +49,8 @@ import com.increase.api.services.blocking.simulations.InboundWireTransferService
import com.increase.api.services.blocking.simulations.InboundWireTransferServiceImpl
import com.increase.api.services.blocking.simulations.InterestPaymentService
import com.increase.api.services.blocking.simulations.InterestPaymentServiceImpl
+import com.increase.api.services.blocking.simulations.PendingTransactionService
+import com.increase.api.services.blocking.simulations.PendingTransactionServiceImpl
import com.increase.api.services.blocking.simulations.PhysicalCardService
import com.increase.api.services.blocking.simulations.PhysicalCardServiceImpl
import com.increase.api.services.blocking.simulations.ProgramService
@@ -110,8 +110,8 @@ class SimulationServiceImpl internal constructor(private val clientOptions: Clie
DigitalWalletTokenRequestServiceImpl(clientOptions)
}
- private val inboundFundsHolds: InboundFundsHoldService by lazy {
- InboundFundsHoldServiceImpl(clientOptions)
+ private val pendingTransactions: PendingTransactionService by lazy {
+ PendingTransactionServiceImpl(clientOptions)
}
private val accountTransfers: AccountTransferService by lazy {
@@ -203,7 +203,7 @@ class SimulationServiceImpl internal constructor(private val clientOptions: Clie
override fun digitalWalletTokenRequests(): DigitalWalletTokenRequestService =
digitalWalletTokenRequests
- override fun inboundFundsHolds(): InboundFundsHoldService = inboundFundsHolds
+ override fun pendingTransactions(): PendingTransactionService = pendingTransactions
override fun accountTransfers(): AccountTransferService = accountTransfers
@@ -291,8 +291,8 @@ class SimulationServiceImpl internal constructor(private val clientOptions: Clie
DigitalWalletTokenRequestServiceImpl.WithRawResponseImpl(clientOptions)
}
- private val inboundFundsHolds: InboundFundsHoldService.WithRawResponse by lazy {
- InboundFundsHoldServiceImpl.WithRawResponseImpl(clientOptions)
+ private val pendingTransactions: PendingTransactionService.WithRawResponse by lazy {
+ PendingTransactionServiceImpl.WithRawResponseImpl(clientOptions)
}
private val accountTransfers: AccountTransferService.WithRawResponse by lazy {
@@ -399,8 +399,8 @@ class SimulationServiceImpl internal constructor(private val clientOptions: Clie
override fun digitalWalletTokenRequests():
DigitalWalletTokenRequestService.WithRawResponse = digitalWalletTokenRequests
- override fun inboundFundsHolds(): InboundFundsHoldService.WithRawResponse =
- inboundFundsHolds
+ override fun pendingTransactions(): PendingTransactionService.WithRawResponse =
+ pendingTransactions
override fun accountTransfers(): AccountTransferService.WithRawResponse = accountTransfers
diff --git a/increase-java-core/src/main/kotlin/com/increase/api/services/blocking/simulations/InboundFundsHoldService.kt b/increase-java-core/src/main/kotlin/com/increase/api/services/blocking/simulations/InboundFundsHoldService.kt
deleted file mode 100644
index 43a09aee5..000000000
--- a/increase-java-core/src/main/kotlin/com/increase/api/services/blocking/simulations/InboundFundsHoldService.kt
+++ /dev/null
@@ -1,130 +0,0 @@
-// File generated from our OpenAPI spec by Stainless.
-
-package com.increase.api.services.blocking.simulations
-
-import com.google.errorprone.annotations.MustBeClosed
-import com.increase.api.core.ClientOptions
-import com.increase.api.core.RequestOptions
-import com.increase.api.core.http.HttpResponseFor
-import com.increase.api.models.simulations.inboundfundsholds.InboundFundsHoldReleaseParams
-import com.increase.api.models.simulations.inboundfundsholds.InboundFundsHoldReleaseResponse
-import java.util.function.Consumer
-
-interface InboundFundsHoldService {
-
- /**
- * Returns a view of this service that provides access to raw HTTP responses for each method.
- */
- fun withRawResponse(): WithRawResponse
-
- /**
- * Returns a view of this service with the given option modifications applied.
- *
- * The original service is not modified.
- */
- fun withOptions(modifier: Consumer): InboundFundsHoldService
-
- /**
- * This endpoint simulates immediately releasing an Inbound Funds Hold, which might be created
- * as a result of e.g., an ACH debit.
- */
- fun release(inboundFundsHoldId: String): InboundFundsHoldReleaseResponse =
- release(inboundFundsHoldId, InboundFundsHoldReleaseParams.none())
-
- /** @see release */
- fun release(
- inboundFundsHoldId: String,
- params: InboundFundsHoldReleaseParams = InboundFundsHoldReleaseParams.none(),
- requestOptions: RequestOptions = RequestOptions.none(),
- ): InboundFundsHoldReleaseResponse =
- release(params.toBuilder().inboundFundsHoldId(inboundFundsHoldId).build(), requestOptions)
-
- /** @see release */
- fun release(
- inboundFundsHoldId: String,
- params: InboundFundsHoldReleaseParams = InboundFundsHoldReleaseParams.none(),
- ): InboundFundsHoldReleaseResponse = release(inboundFundsHoldId, params, RequestOptions.none())
-
- /** @see release */
- fun release(
- params: InboundFundsHoldReleaseParams,
- requestOptions: RequestOptions = RequestOptions.none(),
- ): InboundFundsHoldReleaseResponse
-
- /** @see release */
- fun release(params: InboundFundsHoldReleaseParams): InboundFundsHoldReleaseResponse =
- release(params, RequestOptions.none())
-
- /** @see release */
- fun release(
- inboundFundsHoldId: String,
- requestOptions: RequestOptions,
- ): InboundFundsHoldReleaseResponse =
- release(inboundFundsHoldId, InboundFundsHoldReleaseParams.none(), requestOptions)
-
- /**
- * A view of [InboundFundsHoldService] that provides access to raw HTTP responses for each
- * method.
- */
- interface WithRawResponse {
-
- /**
- * Returns a view of this service with the given option modifications applied.
- *
- * The original service is not modified.
- */
- fun withOptions(
- modifier: Consumer
- ): InboundFundsHoldService.WithRawResponse
-
- /**
- * Returns a raw HTTP response for `post
- * /simulations/inbound_funds_holds/{inbound_funds_hold_id}/release`, but is otherwise the
- * same as [InboundFundsHoldService.release].
- */
- @MustBeClosed
- fun release(inboundFundsHoldId: String): HttpResponseFor =
- release(inboundFundsHoldId, InboundFundsHoldReleaseParams.none())
-
- /** @see release */
- @MustBeClosed
- fun release(
- inboundFundsHoldId: String,
- params: InboundFundsHoldReleaseParams = InboundFundsHoldReleaseParams.none(),
- requestOptions: RequestOptions = RequestOptions.none(),
- ): HttpResponseFor =
- release(
- params.toBuilder().inboundFundsHoldId(inboundFundsHoldId).build(),
- requestOptions,
- )
-
- /** @see release */
- @MustBeClosed
- fun release(
- inboundFundsHoldId: String,
- params: InboundFundsHoldReleaseParams = InboundFundsHoldReleaseParams.none(),
- ): HttpResponseFor =
- release(inboundFundsHoldId, params, RequestOptions.none())
-
- /** @see release */
- @MustBeClosed
- fun release(
- params: InboundFundsHoldReleaseParams,
- requestOptions: RequestOptions = RequestOptions.none(),
- ): HttpResponseFor
-
- /** @see release */
- @MustBeClosed
- fun release(
- params: InboundFundsHoldReleaseParams
- ): HttpResponseFor = release(params, RequestOptions.none())
-
- /** @see release */
- @MustBeClosed
- fun release(
- inboundFundsHoldId: String,
- requestOptions: RequestOptions,
- ): HttpResponseFor =
- release(inboundFundsHoldId, InboundFundsHoldReleaseParams.none(), requestOptions)
- }
-}
diff --git a/increase-java-core/src/main/kotlin/com/increase/api/services/blocking/simulations/PendingTransactionService.kt b/increase-java-core/src/main/kotlin/com/increase/api/services/blocking/simulations/PendingTransactionService.kt
new file mode 100644
index 000000000..abb527a5f
--- /dev/null
+++ b/increase-java-core/src/main/kotlin/com/increase/api/services/blocking/simulations/PendingTransactionService.kt
@@ -0,0 +1,156 @@
+// File generated from our OpenAPI spec by Stainless.
+
+package com.increase.api.services.blocking.simulations
+
+import com.google.errorprone.annotations.MustBeClosed
+import com.increase.api.core.ClientOptions
+import com.increase.api.core.RequestOptions
+import com.increase.api.core.http.HttpResponseFor
+import com.increase.api.models.pendingtransactions.PendingTransaction
+import com.increase.api.models.simulations.pendingtransactions.PendingTransactionReleaseInboundFundsHoldParams
+import java.util.function.Consumer
+
+interface PendingTransactionService {
+
+ /**
+ * Returns a view of this service that provides access to raw HTTP responses for each method.
+ */
+ fun withRawResponse(): WithRawResponse
+
+ /**
+ * Returns a view of this service with the given option modifications applied.
+ *
+ * The original service is not modified.
+ */
+ fun withOptions(modifier: Consumer): PendingTransactionService
+
+ /**
+ * This endpoint simulates immediately releasing an Inbound Funds Hold, which might be created
+ * as a result of, for example, an ACH debit.
+ */
+ fun releaseInboundFundsHold(pendingTransactionId: String): PendingTransaction =
+ releaseInboundFundsHold(
+ pendingTransactionId,
+ PendingTransactionReleaseInboundFundsHoldParams.none(),
+ )
+
+ /** @see releaseInboundFundsHold */
+ fun releaseInboundFundsHold(
+ pendingTransactionId: String,
+ params: PendingTransactionReleaseInboundFundsHoldParams =
+ PendingTransactionReleaseInboundFundsHoldParams.none(),
+ requestOptions: RequestOptions = RequestOptions.none(),
+ ): PendingTransaction =
+ releaseInboundFundsHold(
+ params.toBuilder().pendingTransactionId(pendingTransactionId).build(),
+ requestOptions,
+ )
+
+ /** @see releaseInboundFundsHold */
+ fun releaseInboundFundsHold(
+ pendingTransactionId: String,
+ params: PendingTransactionReleaseInboundFundsHoldParams =
+ PendingTransactionReleaseInboundFundsHoldParams.none(),
+ ): PendingTransaction =
+ releaseInboundFundsHold(pendingTransactionId, params, RequestOptions.none())
+
+ /** @see releaseInboundFundsHold */
+ fun releaseInboundFundsHold(
+ params: PendingTransactionReleaseInboundFundsHoldParams,
+ requestOptions: RequestOptions = RequestOptions.none(),
+ ): PendingTransaction
+
+ /** @see releaseInboundFundsHold */
+ fun releaseInboundFundsHold(
+ params: PendingTransactionReleaseInboundFundsHoldParams
+ ): PendingTransaction = releaseInboundFundsHold(params, RequestOptions.none())
+
+ /** @see releaseInboundFundsHold */
+ fun releaseInboundFundsHold(
+ pendingTransactionId: String,
+ requestOptions: RequestOptions,
+ ): PendingTransaction =
+ releaseInboundFundsHold(
+ pendingTransactionId,
+ PendingTransactionReleaseInboundFundsHoldParams.none(),
+ requestOptions,
+ )
+
+ /**
+ * A view of [PendingTransactionService] that provides access to raw HTTP responses for each
+ * method.
+ */
+ interface WithRawResponse {
+
+ /**
+ * Returns a view of this service with the given option modifications applied.
+ *
+ * The original service is not modified.
+ */
+ fun withOptions(
+ modifier: Consumer
+ ): PendingTransactionService.WithRawResponse
+
+ /**
+ * Returns a raw HTTP response for `post
+ * /simulations/pending_transactions/{pending_transaction_id}/release_inbound_funds_hold`,
+ * but is otherwise the same as [PendingTransactionService.releaseInboundFundsHold].
+ */
+ @MustBeClosed
+ fun releaseInboundFundsHold(
+ pendingTransactionId: String
+ ): HttpResponseFor =
+ releaseInboundFundsHold(
+ pendingTransactionId,
+ PendingTransactionReleaseInboundFundsHoldParams.none(),
+ )
+
+ /** @see releaseInboundFundsHold */
+ @MustBeClosed
+ fun releaseInboundFundsHold(
+ pendingTransactionId: String,
+ params: PendingTransactionReleaseInboundFundsHoldParams =
+ PendingTransactionReleaseInboundFundsHoldParams.none(),
+ requestOptions: RequestOptions = RequestOptions.none(),
+ ): HttpResponseFor =
+ releaseInboundFundsHold(
+ params.toBuilder().pendingTransactionId(pendingTransactionId).build(),
+ requestOptions,
+ )
+
+ /** @see releaseInboundFundsHold */
+ @MustBeClosed
+ fun releaseInboundFundsHold(
+ pendingTransactionId: String,
+ params: PendingTransactionReleaseInboundFundsHoldParams =
+ PendingTransactionReleaseInboundFundsHoldParams.none(),
+ ): HttpResponseFor =
+ releaseInboundFundsHold(pendingTransactionId, params, RequestOptions.none())
+
+ /** @see releaseInboundFundsHold */
+ @MustBeClosed
+ fun releaseInboundFundsHold(
+ params: PendingTransactionReleaseInboundFundsHoldParams,
+ requestOptions: RequestOptions = RequestOptions.none(),
+ ): HttpResponseFor
+
+ /** @see releaseInboundFundsHold */
+ @MustBeClosed
+ fun releaseInboundFundsHold(
+ params: PendingTransactionReleaseInboundFundsHoldParams
+ ): HttpResponseFor =
+ releaseInboundFundsHold(params, RequestOptions.none())
+
+ /** @see releaseInboundFundsHold */
+ @MustBeClosed
+ fun releaseInboundFundsHold(
+ pendingTransactionId: String,
+ requestOptions: RequestOptions,
+ ): HttpResponseFor =
+ releaseInboundFundsHold(
+ pendingTransactionId,
+ PendingTransactionReleaseInboundFundsHoldParams.none(),
+ requestOptions,
+ )
+ }
+}
diff --git a/increase-java-core/src/main/kotlin/com/increase/api/services/blocking/simulations/InboundFundsHoldServiceImpl.kt b/increase-java-core/src/main/kotlin/com/increase/api/services/blocking/simulations/PendingTransactionServiceImpl.kt
similarity index 59%
rename from increase-java-core/src/main/kotlin/com/increase/api/services/blocking/simulations/InboundFundsHoldServiceImpl.kt
rename to increase-java-core/src/main/kotlin/com/increase/api/services/blocking/simulations/PendingTransactionServiceImpl.kt
index 56aa25348..44220c72c 100644
--- a/increase-java-core/src/main/kotlin/com/increase/api/services/blocking/simulations/InboundFundsHoldServiceImpl.kt
+++ b/increase-java-core/src/main/kotlin/com/increase/api/services/blocking/simulations/PendingTransactionServiceImpl.kt
@@ -16,62 +16,63 @@ import com.increase.api.core.http.HttpResponseFor
import com.increase.api.core.http.json
import com.increase.api.core.http.parseable
import com.increase.api.core.prepare
-import com.increase.api.models.simulations.inboundfundsholds.InboundFundsHoldReleaseParams
-import com.increase.api.models.simulations.inboundfundsholds.InboundFundsHoldReleaseResponse
+import com.increase.api.models.pendingtransactions.PendingTransaction
+import com.increase.api.models.simulations.pendingtransactions.PendingTransactionReleaseInboundFundsHoldParams
import java.util.function.Consumer
import kotlin.jvm.optionals.getOrNull
-class InboundFundsHoldServiceImpl internal constructor(private val clientOptions: ClientOptions) :
- InboundFundsHoldService {
+class PendingTransactionServiceImpl internal constructor(private val clientOptions: ClientOptions) :
+ PendingTransactionService {
- private val withRawResponse: InboundFundsHoldService.WithRawResponse by lazy {
+ private val withRawResponse: PendingTransactionService.WithRawResponse by lazy {
WithRawResponseImpl(clientOptions)
}
- override fun withRawResponse(): InboundFundsHoldService.WithRawResponse = withRawResponse
+ override fun withRawResponse(): PendingTransactionService.WithRawResponse = withRawResponse
- override fun withOptions(modifier: Consumer): InboundFundsHoldService =
- InboundFundsHoldServiceImpl(clientOptions.toBuilder().apply(modifier::accept).build())
+ override fun withOptions(modifier: Consumer): PendingTransactionService =
+ PendingTransactionServiceImpl(clientOptions.toBuilder().apply(modifier::accept).build())
- override fun release(
- params: InboundFundsHoldReleaseParams,
+ override fun releaseInboundFundsHold(
+ params: PendingTransactionReleaseInboundFundsHoldParams,
requestOptions: RequestOptions,
- ): InboundFundsHoldReleaseResponse =
- // post /simulations/inbound_funds_holds/{inbound_funds_hold_id}/release
- withRawResponse().release(params, requestOptions).parse()
+ ): PendingTransaction =
+ // post
+ // /simulations/pending_transactions/{pending_transaction_id}/release_inbound_funds_hold
+ withRawResponse().releaseInboundFundsHold(params, requestOptions).parse()
class WithRawResponseImpl internal constructor(private val clientOptions: ClientOptions) :
- InboundFundsHoldService.WithRawResponse {
+ PendingTransactionService.WithRawResponse {
private val errorHandler: Handler =
errorHandler(errorBodyHandler(clientOptions.jsonMapper))
override fun withOptions(
modifier: Consumer
- ): InboundFundsHoldService.WithRawResponse =
- InboundFundsHoldServiceImpl.WithRawResponseImpl(
+ ): PendingTransactionService.WithRawResponse =
+ PendingTransactionServiceImpl.WithRawResponseImpl(
clientOptions.toBuilder().apply(modifier::accept).build()
)
- private val releaseHandler: Handler =
- jsonHandler(clientOptions.jsonMapper)
+ private val releaseInboundFundsHoldHandler: Handler =
+ jsonHandler(clientOptions.jsonMapper)
- override fun release(
- params: InboundFundsHoldReleaseParams,
+ override fun releaseInboundFundsHold(
+ params: PendingTransactionReleaseInboundFundsHoldParams,
requestOptions: RequestOptions,
- ): HttpResponseFor {
+ ): HttpResponseFor {
// We check here instead of in the params builder because this can be specified
// positionally or in the params class.
- checkRequired("inboundFundsHoldId", params.inboundFundsHoldId().getOrNull())
+ checkRequired("pendingTransactionId", params.pendingTransactionId().getOrNull())
val request =
HttpRequest.builder()
.method(HttpMethod.POST)
.baseUrl(clientOptions.baseUrl())
.addPathSegments(
"simulations",
- "inbound_funds_holds",
+ "pending_transactions",
params._pathParam(0),
- "release",
+ "release_inbound_funds_hold",
)
.apply { params._body().ifPresent { body(json(clientOptions.jsonMapper, it)) } }
.build()
@@ -80,7 +81,7 @@ class InboundFundsHoldServiceImpl internal constructor(private val clientOptions
val response = clientOptions.httpClient.execute(request, requestOptions)
return errorHandler.handle(response).parseable {
response
- .use { releaseHandler.handle(it) }
+ .use { releaseInboundFundsHoldHandler.handle(it) }
.also {
if (requestOptions.responseValidation!!) {
it.validate()
diff --git a/increase-java-core/src/test/kotlin/com/increase/api/models/simulations/inboundfundsholds/InboundFundsHoldReleaseParamsTest.kt b/increase-java-core/src/test/kotlin/com/increase/api/models/simulations/inboundfundsholds/InboundFundsHoldReleaseParamsTest.kt
deleted file mode 100644
index 204f89526..000000000
--- a/increase-java-core/src/test/kotlin/com/increase/api/models/simulations/inboundfundsholds/InboundFundsHoldReleaseParamsTest.kt
+++ /dev/null
@@ -1,28 +0,0 @@
-// File generated from our OpenAPI spec by Stainless.
-
-package com.increase.api.models.simulations.inboundfundsholds
-
-import org.assertj.core.api.Assertions.assertThat
-import org.junit.jupiter.api.Test
-
-internal class InboundFundsHoldReleaseParamsTest {
-
- @Test
- fun create() {
- InboundFundsHoldReleaseParams.builder()
- .inboundFundsHoldId("inbound_funds_hold_9vuasmywdo7xb3zt4071")
- .build()
- }
-
- @Test
- fun pathParams() {
- val params =
- InboundFundsHoldReleaseParams.builder()
- .inboundFundsHoldId("inbound_funds_hold_9vuasmywdo7xb3zt4071")
- .build()
-
- assertThat(params._pathParam(0)).isEqualTo("inbound_funds_hold_9vuasmywdo7xb3zt4071")
- // out-of-bound path param
- assertThat(params._pathParam(1)).isEqualTo("")
- }
-}
diff --git a/increase-java-core/src/test/kotlin/com/increase/api/models/simulations/inboundfundsholds/InboundFundsHoldReleaseResponseTest.kt b/increase-java-core/src/test/kotlin/com/increase/api/models/simulations/inboundfundsholds/InboundFundsHoldReleaseResponseTest.kt
deleted file mode 100644
index 3da30fed3..000000000
--- a/increase-java-core/src/test/kotlin/com/increase/api/models/simulations/inboundfundsholds/InboundFundsHoldReleaseResponseTest.kt
+++ /dev/null
@@ -1,75 +0,0 @@
-// File generated from our OpenAPI spec by Stainless.
-
-package com.increase.api.models.simulations.inboundfundsholds
-
-import com.fasterxml.jackson.module.kotlin.jacksonTypeRef
-import com.increase.api.core.jsonMapper
-import java.time.OffsetDateTime
-import org.assertj.core.api.Assertions.assertThat
-import org.junit.jupiter.api.Test
-
-internal class InboundFundsHoldReleaseResponseTest {
-
- @Test
- fun create() {
- val inboundFundsHoldReleaseResponse =
- InboundFundsHoldReleaseResponse.builder()
- .id("inbound_funds_hold_9vuasmywdo7xb3zt4071")
- .amount(100L)
- .automaticallyReleasesAt(OffsetDateTime.parse("2020-01-31T23:59:59Z"))
- .createdAt(OffsetDateTime.parse("2020-01-31T23:59:59Z"))
- .currency(InboundFundsHoldReleaseResponse.Currency.USD)
- .heldTransactionId("transaction_uyrp7fld2ium70oa7oi")
- .pendingTransactionId("pending_transaction_k1sfetcau2qbvjbzgju4")
- .releasedAt(null)
- .status(InboundFundsHoldReleaseResponse.Status.HELD)
- .type(InboundFundsHoldReleaseResponse.Type.INBOUND_FUNDS_HOLD)
- .build()
-
- assertThat(inboundFundsHoldReleaseResponse.id())
- .isEqualTo("inbound_funds_hold_9vuasmywdo7xb3zt4071")
- assertThat(inboundFundsHoldReleaseResponse.amount()).isEqualTo(100L)
- assertThat(inboundFundsHoldReleaseResponse.automaticallyReleasesAt())
- .isEqualTo(OffsetDateTime.parse("2020-01-31T23:59:59Z"))
- assertThat(inboundFundsHoldReleaseResponse.createdAt())
- .isEqualTo(OffsetDateTime.parse("2020-01-31T23:59:59Z"))
- assertThat(inboundFundsHoldReleaseResponse.currency())
- .isEqualTo(InboundFundsHoldReleaseResponse.Currency.USD)
- assertThat(inboundFundsHoldReleaseResponse.heldTransactionId())
- .contains("transaction_uyrp7fld2ium70oa7oi")
- assertThat(inboundFundsHoldReleaseResponse.pendingTransactionId())
- .contains("pending_transaction_k1sfetcau2qbvjbzgju4")
- assertThat(inboundFundsHoldReleaseResponse.releasedAt()).isEmpty
- assertThat(inboundFundsHoldReleaseResponse.status())
- .isEqualTo(InboundFundsHoldReleaseResponse.Status.HELD)
- assertThat(inboundFundsHoldReleaseResponse.type())
- .isEqualTo(InboundFundsHoldReleaseResponse.Type.INBOUND_FUNDS_HOLD)
- }
-
- @Test
- fun roundtrip() {
- val jsonMapper = jsonMapper()
- val inboundFundsHoldReleaseResponse =
- InboundFundsHoldReleaseResponse.builder()
- .id("inbound_funds_hold_9vuasmywdo7xb3zt4071")
- .amount(100L)
- .automaticallyReleasesAt(OffsetDateTime.parse("2020-01-31T23:59:59Z"))
- .createdAt(OffsetDateTime.parse("2020-01-31T23:59:59Z"))
- .currency(InboundFundsHoldReleaseResponse.Currency.USD)
- .heldTransactionId("transaction_uyrp7fld2ium70oa7oi")
- .pendingTransactionId("pending_transaction_k1sfetcau2qbvjbzgju4")
- .releasedAt(null)
- .status(InboundFundsHoldReleaseResponse.Status.HELD)
- .type(InboundFundsHoldReleaseResponse.Type.INBOUND_FUNDS_HOLD)
- .build()
-
- val roundtrippedInboundFundsHoldReleaseResponse =
- jsonMapper.readValue(
- jsonMapper.writeValueAsString(inboundFundsHoldReleaseResponse),
- jacksonTypeRef(),
- )
-
- assertThat(roundtrippedInboundFundsHoldReleaseResponse)
- .isEqualTo(inboundFundsHoldReleaseResponse)
- }
-}
diff --git a/increase-java-core/src/test/kotlin/com/increase/api/models/simulations/pendingtransactions/PendingTransactionReleaseInboundFundsHoldParamsTest.kt b/increase-java-core/src/test/kotlin/com/increase/api/models/simulations/pendingtransactions/PendingTransactionReleaseInboundFundsHoldParamsTest.kt
new file mode 100644
index 000000000..7391624e2
--- /dev/null
+++ b/increase-java-core/src/test/kotlin/com/increase/api/models/simulations/pendingtransactions/PendingTransactionReleaseInboundFundsHoldParamsTest.kt
@@ -0,0 +1,28 @@
+// File generated from our OpenAPI spec by Stainless.
+
+package com.increase.api.models.simulations.pendingtransactions
+
+import org.assertj.core.api.Assertions.assertThat
+import org.junit.jupiter.api.Test
+
+internal class PendingTransactionReleaseInboundFundsHoldParamsTest {
+
+ @Test
+ fun create() {
+ PendingTransactionReleaseInboundFundsHoldParams.builder()
+ .pendingTransactionId("pending_transaction_k1sfetcau2qbvjbzgju4")
+ .build()
+ }
+
+ @Test
+ fun pathParams() {
+ val params =
+ PendingTransactionReleaseInboundFundsHoldParams.builder()
+ .pendingTransactionId("pending_transaction_k1sfetcau2qbvjbzgju4")
+ .build()
+
+ assertThat(params._pathParam(0)).isEqualTo("pending_transaction_k1sfetcau2qbvjbzgju4")
+ // out-of-bound path param
+ assertThat(params._pathParam(1)).isEqualTo("")
+ }
+}
diff --git a/increase-java-core/src/test/kotlin/com/increase/api/services/async/simulations/InboundFundsHoldServiceAsyncTest.kt b/increase-java-core/src/test/kotlin/com/increase/api/services/async/simulations/PendingTransactionServiceAsyncTest.kt
similarity index 54%
rename from increase-java-core/src/test/kotlin/com/increase/api/services/async/simulations/InboundFundsHoldServiceAsyncTest.kt
rename to increase-java-core/src/test/kotlin/com/increase/api/services/async/simulations/PendingTransactionServiceAsyncTest.kt
index 25a3007fc..3e5cc5968 100644
--- a/increase-java-core/src/test/kotlin/com/increase/api/services/async/simulations/InboundFundsHoldServiceAsyncTest.kt
+++ b/increase-java-core/src/test/kotlin/com/increase/api/services/async/simulations/PendingTransactionServiceAsyncTest.kt
@@ -8,21 +8,23 @@ import org.junit.jupiter.api.Test
import org.junit.jupiter.api.extension.ExtendWith
@ExtendWith(TestServerExtension::class)
-internal class InboundFundsHoldServiceAsyncTest {
+internal class PendingTransactionServiceAsyncTest {
@Test
- fun release() {
+ fun releaseInboundFundsHold() {
val client =
IncreaseOkHttpClientAsync.builder()
.baseUrl(TestServerExtension.BASE_URL)
.apiKey("My API Key")
.build()
- val inboundFundsHoldServiceAsync = client.simulations().inboundFundsHolds()
+ val pendingTransactionServiceAsync = client.simulations().pendingTransactions()
- val responseFuture =
- inboundFundsHoldServiceAsync.release("inbound_funds_hold_9vuasmywdo7xb3zt4071")
+ val pendingTransactionFuture =
+ pendingTransactionServiceAsync.releaseInboundFundsHold(
+ "pending_transaction_k1sfetcau2qbvjbzgju4"
+ )
- val response = responseFuture.get()
- response.validate()
+ val pendingTransaction = pendingTransactionFuture.get()
+ pendingTransaction.validate()
}
}
diff --git a/increase-java-core/src/test/kotlin/com/increase/api/services/blocking/simulations/InboundFundsHoldServiceTest.kt b/increase-java-core/src/test/kotlin/com/increase/api/services/blocking/simulations/PendingTransactionServiceTest.kt
similarity index 59%
rename from increase-java-core/src/test/kotlin/com/increase/api/services/blocking/simulations/InboundFundsHoldServiceTest.kt
rename to increase-java-core/src/test/kotlin/com/increase/api/services/blocking/simulations/PendingTransactionServiceTest.kt
index da1685d5e..9343cad48 100644
--- a/increase-java-core/src/test/kotlin/com/increase/api/services/blocking/simulations/InboundFundsHoldServiceTest.kt
+++ b/increase-java-core/src/test/kotlin/com/increase/api/services/blocking/simulations/PendingTransactionServiceTest.kt
@@ -8,19 +8,22 @@ import org.junit.jupiter.api.Test
import org.junit.jupiter.api.extension.ExtendWith
@ExtendWith(TestServerExtension::class)
-internal class InboundFundsHoldServiceTest {
+internal class PendingTransactionServiceTest {
@Test
- fun release() {
+ fun releaseInboundFundsHold() {
val client =
IncreaseOkHttpClient.builder()
.baseUrl(TestServerExtension.BASE_URL)
.apiKey("My API Key")
.build()
- val inboundFundsHoldService = client.simulations().inboundFundsHolds()
+ val pendingTransactionService = client.simulations().pendingTransactions()
- val response = inboundFundsHoldService.release("inbound_funds_hold_9vuasmywdo7xb3zt4071")
+ val pendingTransaction =
+ pendingTransactionService.releaseInboundFundsHold(
+ "pending_transaction_k1sfetcau2qbvjbzgju4"
+ )
- response.validate()
+ pendingTransaction.validate()
}
}