Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

release: 0.69.0 #322

Merged
merged 38 commits into from
Nov 1, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
e69f47b
style(internal): improve terseness of handlers (#321)
stainless-app[bot] Oct 14, 2024
3cf3952
style(internal): improve terseness of Properties.kt (#323)
stainless-app[bot] Oct 14, 2024
e02eea0
style(internal): move Handlers.kt and HttpRequestBodies.kt to core (#…
Nov 1, 2024
89bb442
chore(internal): omit unnecessary code (#326)
Nov 1, 2024
26e72f3
fix(internal): remove unnecessary error handlers (#327)
stainless-app[bot] Oct 16, 2024
0534fed
feat(client): support union discriminators in deserialization (#328)
stainless-app[bot] Oct 18, 2024
44e2586
style(internal): use `if` and `if-else` instead of `when` idiomatical…
stainless-app[bot] Oct 21, 2024
d1caec0
style(client): make toString methods consistent (#330)
stainless-app[bot] Oct 21, 2024
2d660ab
chore(internal): remove empty test files (#331)
stainless-app[bot] Oct 22, 2024
7646708
feat(api): removes `transfer_transaction.created` webhook and updates…
stainless-app[bot] Oct 22, 2024
2b0e988
style(internal): update comment formatting (#333)
stainless-app[bot] Oct 22, 2024
f75a999
chore(internal): remove unnecessary `@file:Suppress("OVERLOADS_INTERF…
stainless-app[bot] Oct 22, 2024
e77faca
style(internal): improve `OkHttpClient` formatting (#335)
stainless-app[bot] Oct 22, 2024
92ddfe9
style(internal): simplify client build method (#336)
stainless-app[bot] Oct 22, 2024
954c80c
chore(internal): remove useless `@file:JvmSynthetic` (#337)
stainless-app[bot] Oct 22, 2024
cb2ccf3
chore(internal): remove unnecessary `@file:Suppress("OVERLOADS_INTERF…
stainless-app[bot] Oct 22, 2024
600591d
style(internal): improve `RetryingHttpClient` formatting (#339)
stainless-app[bot] Oct 23, 2024
8cd61db
feat(api): add `interest_details` properties to LoanTapes (#340)
stainless-app[bot] Oct 23, 2024
a871c61
fix(client): implement `hashCode` for `IsMissing` (#341)
stainless-app[bot] Oct 23, 2024
5667848
chore(api): add `PIN_BLOCKED` to `detailed_results` property on Event…
stainless-app[bot] Oct 24, 2024
c3fddaf
chore(api): adds new result types to Transactions and Events (#343)
stainless-app[bot] Oct 24, 2024
3865552
feat(client): set `X-Stainless-Runtime` header (#344)
stainless-app[bot] Oct 25, 2024
9f537ed
feat(client): add `User-Agent` header (#345)
stainless-app[bot] Oct 25, 2024
2825bb9
fix(client): accidental double-wrapping with `RetryingHttpClient` (#346)
stainless-app[bot] Oct 25, 2024
75b8c37
feat(api): updates (#347)
stainless-app[bot] Oct 28, 2024
2fd7669
feat(client): clean up resource leaks when the resource becomes phant…
stainless-app[bot] Oct 28, 2024
0f6a69b
chore(docs): updates to documentation for V2 AuthRules (#349)
stainless-app[bot] Oct 29, 2024
ee5d02e
style(client)!: rename some union classes (#350)
stainless-app[bot] Oct 30, 2024
1bf0ec1
chore(api): adds `charge_off` functionality to FinancialAccounts (#351)
stainless-app[bot] Oct 30, 2024
e642d4e
style(internal): make `getOrThrow` terse and consistent (#352)
stainless-app[bot] Oct 30, 2024
7aaa905
chore(internal): delete unused function (#353)
stainless-app[bot] Oct 30, 2024
a753c44
fix(client): remove `@JvmStatic` from error (#354)
stainless-app[bot] Oct 30, 2024
9eeab77
docs: add docstrings (#355)
stainless-app[bot] Oct 30, 2024
8f95fce
fix(client): ensure constructed objects are immutable (#356)
stainless-app[bot] Oct 31, 2024
7cdb62b
refactor(internal): polish `ClientOptions` (#357)
stainless-app[bot] Nov 1, 2024
e2755bc
feat(client): add `Headers` class (#358)
stainless-app[bot] Nov 1, 2024
b9e444a
fix: merge conflicts (#360)
stainless-app[bot] Nov 1, 2024
e278659
release: 0.69.0
stainless-app[bot] Nov 1, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
".": "0.68.0"
".": "0.69.0"
}
2 changes: 1 addition & 1 deletion .stats.yml
Original file line number Diff line number Diff line change
@@ -1 +1 @@
configured_endpoints: 155
configured_endpoints: 156
68 changes: 68 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,73 @@
# Changelog

## 0.69.0 (2024-11-01)

Full Changelog: [v0.68.0...v0.69.0](https://github.com/lithic-com/lithic-kotlin/compare/v0.68.0...v0.69.0)

### ⚠ BREAKING CHANGES

* **client:** rename some union classes ([#350](https://github.com/lithic-com/lithic-kotlin/issues/350))

### Features

* **api:** add `interest_details` properties to LoanTapes ([#340](https://github.com/lithic-com/lithic-kotlin/issues/340)) ([8cd61db](https://github.com/lithic-com/lithic-kotlin/commit/8cd61db48bfb30be01dd45a9b6eced94a5876ed8))
* **api:** removes `transfer_transaction.created` webhook and updates to VerificationApplication ([#332](https://github.com/lithic-com/lithic-kotlin/issues/332)) ([7646708](https://github.com/lithic-com/lithic-kotlin/commit/7646708cdf295bcd06fdd5c6291a724de915518f))
* **api:** updates ([#347](https://github.com/lithic-com/lithic-kotlin/issues/347)) ([75b8c37](https://github.com/lithic-com/lithic-kotlin/commit/75b8c3791da0494ef9c13c087c4f83fa71dd1ec6))
* **client:** add `Headers` class ([#358](https://github.com/lithic-com/lithic-kotlin/issues/358)) ([e2755bc](https://github.com/lithic-com/lithic-kotlin/commit/e2755bc95f68121cab9ec0ecff50a9bdf242c85e))
* **client:** add `User-Agent` header ([#345](https://github.com/lithic-com/lithic-kotlin/issues/345)) ([9f537ed](https://github.com/lithic-com/lithic-kotlin/commit/9f537ed560f4b2361e370c8d8473b1ad397516b6))
* **client:** clean up resource leaks when the resource becomes phantom reachable ([#348](https://github.com/lithic-com/lithic-kotlin/issues/348)) ([2fd7669](https://github.com/lithic-com/lithic-kotlin/commit/2fd76692053c8e6eb6b88c037eb17a366b577487))
* **client:** set `X-Stainless-Runtime` header ([#344](https://github.com/lithic-com/lithic-kotlin/issues/344)) ([3865552](https://github.com/lithic-com/lithic-kotlin/commit/3865552aa48f3206c3d2ad9ef80d5270582d286b))
* **client:** support union discriminators in deserialization ([#328](https://github.com/lithic-com/lithic-kotlin/issues/328)) ([0534fed](https://github.com/lithic-com/lithic-kotlin/commit/0534fed2b24678ea99671e5041f5379ccf096221))


### Bug Fixes

* **client:** accidental double-wrapping with `RetryingHttpClient` ([#346](https://github.com/lithic-com/lithic-kotlin/issues/346)) ([2825bb9](https://github.com/lithic-com/lithic-kotlin/commit/2825bb9c6f393758a3b51586ec69bf9ea0a22363))
* **client:** ensure constructed objects are immutable ([#356](https://github.com/lithic-com/lithic-kotlin/issues/356)) ([8f95fce](https://github.com/lithic-com/lithic-kotlin/commit/8f95fce015416d106ef90d8234129885abc71401))
* **client:** implement `hashCode` for `IsMissing` ([#341](https://github.com/lithic-com/lithic-kotlin/issues/341)) ([a871c61](https://github.com/lithic-com/lithic-kotlin/commit/a871c61d5932254a415970d3ab6e595059447159))
* **client:** remove `@JvmStatic` from error ([#354](https://github.com/lithic-com/lithic-kotlin/issues/354)) ([a753c44](https://github.com/lithic-com/lithic-kotlin/commit/a753c4496350d48b211edb872e4db453c5771a70))
* **internal:** remove unnecessary error handlers ([#327](https://github.com/lithic-com/lithic-kotlin/issues/327)) ([26e72f3](https://github.com/lithic-com/lithic-kotlin/commit/26e72f33e7ccf0b5c8e910a41ebc75729fe6b701))
* merge conflicts ([#360](https://github.com/lithic-com/lithic-kotlin/issues/360)) ([b9e444a](https://github.com/lithic-com/lithic-kotlin/commit/b9e444a6e687414d7b61713cb0d2eb57284a7de3))


### Chores

* **api:** add `PIN_BLOCKED` to `detailed_results` property on Event ([#342](https://github.com/lithic-com/lithic-kotlin/issues/342)) ([5667848](https://github.com/lithic-com/lithic-kotlin/commit/56678481b9b03ceb2f84d0c604c546f45304e1dd))
* **api:** adds `charge_off` functionality to FinancialAccounts ([#351](https://github.com/lithic-com/lithic-kotlin/issues/351)) ([1bf0ec1](https://github.com/lithic-com/lithic-kotlin/commit/1bf0ec1d1fabb366ed595e8f65eed7798dfafd7f))
* **api:** adds new result types to Transactions and Events ([#343](https://github.com/lithic-com/lithic-kotlin/issues/343)) ([c3fddaf](https://github.com/lithic-com/lithic-kotlin/commit/c3fddaf87ffd1995f6b616d84454102759834176))
* **docs:** updates to documentation for V2 AuthRules ([#349](https://github.com/lithic-com/lithic-kotlin/issues/349)) ([0f6a69b](https://github.com/lithic-com/lithic-kotlin/commit/0f6a69b7ea3303a4165fda64cabc625cc97b7143))
* **internal:** delete unused function ([#353](https://github.com/lithic-com/lithic-kotlin/issues/353)) ([7aaa905](https://github.com/lithic-com/lithic-kotlin/commit/7aaa905895c3cd860b6512e4437b88fa69dc94d3))
* **internal:** omit unnecessary code ([#326](https://github.com/lithic-com/lithic-kotlin/issues/326)) ([89bb442](https://github.com/lithic-com/lithic-kotlin/commit/89bb44292729794d196571bdf231bee71e9a1308))
* **internal:** remove empty test files ([#331](https://github.com/lithic-com/lithic-kotlin/issues/331)) ([2d660ab](https://github.com/lithic-com/lithic-kotlin/commit/2d660abbaad2ab01f0eaf2d12b2fd2da8d772497))
* **internal:** remove unnecessary `[@file](https://github.com/file):Suppress("OVERLOADS_INTERFACE")` ([#334](https://github.com/lithic-com/lithic-kotlin/issues/334)) ([f75a999](https://github.com/lithic-com/lithic-kotlin/commit/f75a999dd8fb409e3ee0ece6669de462146c42aa))
* **internal:** remove unnecessary `[@file](https://github.com/file):Suppress("OVERLOADS_INTERFACE")` ([#338](https://github.com/lithic-com/lithic-kotlin/issues/338)) ([cb2ccf3](https://github.com/lithic-com/lithic-kotlin/commit/cb2ccf3a0ef83094a987600d79f6095f0dc04577))
* **internal:** remove useless `[@file](https://github.com/file):JvmSynthetic` ([#337](https://github.com/lithic-com/lithic-kotlin/issues/337)) ([954c80c](https://github.com/lithic-com/lithic-kotlin/commit/954c80c5c29a4be4175c4a58b2b0b469c902272e))


### Documentation

* add docstrings ([#355](https://github.com/lithic-com/lithic-kotlin/issues/355)) ([9eeab77](https://github.com/lithic-com/lithic-kotlin/commit/9eeab77d798b6f75b19997a8d8a486afc90c74f0))


### Styles

* **client:** make toString methods consistent ([#330](https://github.com/lithic-com/lithic-kotlin/issues/330)) ([d1caec0](https://github.com/lithic-com/lithic-kotlin/commit/d1caec0522b94c273beb53642016d10de3286c02))
* **client:** rename some union classes ([#350](https://github.com/lithic-com/lithic-kotlin/issues/350)) ([ee5d02e](https://github.com/lithic-com/lithic-kotlin/commit/ee5d02ecc3f29ab6923eb36671314c7184f3f494))
* **internal:** improve `OkHttpClient` formatting ([#335](https://github.com/lithic-com/lithic-kotlin/issues/335)) ([e77faca](https://github.com/lithic-com/lithic-kotlin/commit/e77faca514850a4a5a780d19554aefec626d1533))
* **internal:** improve `RetryingHttpClient` formatting ([#339](https://github.com/lithic-com/lithic-kotlin/issues/339)) ([600591d](https://github.com/lithic-com/lithic-kotlin/commit/600591d6eef4c89f01caa7ab4f3e9aaf219aa02a))
* **internal:** improve terseness of handlers ([#321](https://github.com/lithic-com/lithic-kotlin/issues/321)) ([e69f47b](https://github.com/lithic-com/lithic-kotlin/commit/e69f47b54c20edd80b663b990f8b172c3c6b9384))
* **internal:** improve terseness of Properties.kt ([#323](https://github.com/lithic-com/lithic-kotlin/issues/323)) ([3cf3952](https://github.com/lithic-com/lithic-kotlin/commit/3cf39525d1d7b34209db1edf4551a05305589e26))
* **internal:** make `getOrThrow` terse and consistent ([#352](https://github.com/lithic-com/lithic-kotlin/issues/352)) ([e642d4e](https://github.com/lithic-com/lithic-kotlin/commit/e642d4ee487054b09a7b0861fba111ffd0efb6f5))
* **internal:** move Handlers.kt and HttpRequestBodies.kt to core ([#324](https://github.com/lithic-com/lithic-kotlin/issues/324)) ([e02eea0](https://github.com/lithic-com/lithic-kotlin/commit/e02eea0269df2f72c5af45dc1f9541c149d1f997))
* **internal:** simplify client build method ([#336](https://github.com/lithic-com/lithic-kotlin/issues/336)) ([92ddfe9](https://github.com/lithic-com/lithic-kotlin/commit/92ddfe90bd7b9506f1fbdad47d1636fa8a5e13c0))
* **internal:** update comment formatting ([#333](https://github.com/lithic-com/lithic-kotlin/issues/333)) ([2b0e988](https://github.com/lithic-com/lithic-kotlin/commit/2b0e9882faaa0b232446816a02044e657ec4f3d7))
* **internal:** use `if` and `if-else` instead of `when` idiomatically ([#329](https://github.com/lithic-com/lithic-kotlin/issues/329)) ([44e2586](https://github.com/lithic-com/lithic-kotlin/commit/44e2586f02d4e4716269984afe837909a5e5acb0))


### Refactors

* **internal:** polish `ClientOptions` ([#357](https://github.com/lithic-com/lithic-kotlin/issues/357)) ([7cdb62b](https://github.com/lithic-com/lithic-kotlin/commit/7cdb62bf9f5b8530f77f2cba026550d318b8b160))

## 0.68.0 (2024-10-11)

Full Changelog: [v0.67.0...v0.68.0](https://github.com/lithic-com/lithic-kotlin/compare/v0.67.0...v0.68.0)
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ The REST API documentation can be found on [docs.lithic.com](https://docs.lithi
<!-- x-release-please-start-version -->

```kotlin
implementation("com.lithic.api:lithic-kotlin:0.68.0")
implementation("com.lithic.api:lithic-kotlin:0.69.0")
```

#### Maven
Expand All @@ -28,7 +28,7 @@ implementation("com.lithic.api:lithic-kotlin:0.68.0")
<dependency>
<groupId>com.lithic.api</groupId>
<artifactId>lithic-kotlin</artifactId>
<version>0.68.0</version>
<version>0.69.0</version>
</dependency>
```

Expand Down
2 changes: 1 addition & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ plugins {

allprojects {
group = "com.lithic.api"
version = "0.68.0" // x-release-please-version
version = "0.69.0" // x-release-please-version
}

nexusPublishing {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ class LithicOkHttpClient private constructor() {

private var clientOptions: ClientOptions.Builder = ClientOptions.builder()
private var baseUrl: String = ClientOptions.PRODUCTION_URL
// default timeout for client is 1 minute
// The default timeout for the client is 1 minute.
private var timeout: Duration = Duration.ofSeconds(60)
private var proxy: Proxy? = null

Expand Down Expand Up @@ -72,8 +72,8 @@ class LithicOkHttpClient private constructor() {

fun fromEnv() = apply { clientOptions.fromEnv() }

fun build(): LithicClient {
return LithicClientImpl(
fun build(): LithicClient =
LithicClientImpl(
clientOptions
.httpClient(
OkHttpClient.builder()
Expand All @@ -84,6 +84,5 @@ class LithicOkHttpClient private constructor() {
)
.build()
)
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ class LithicOkHttpClientAsync private constructor() {

private var clientOptions: ClientOptions.Builder = ClientOptions.builder()
private var baseUrl: String = ClientOptions.PRODUCTION_URL
// default timeout for client is 1 minute
// The default timeout for the client is 1 minute.
private var timeout: Duration = Duration.ofSeconds(60)
private var proxy: Proxy? = null

Expand Down Expand Up @@ -72,8 +72,8 @@ class LithicOkHttpClientAsync private constructor() {

fun fromEnv() = apply { clientOptions.fromEnv() }

fun build(): LithicClientAsync {
return LithicClientAsyncImpl(
fun build(): LithicClientAsync =
LithicClientAsyncImpl(
clientOptions
.httpClient(
OkHttpClient.builder()
Expand All @@ -84,6 +84,5 @@ class LithicOkHttpClientAsync private constructor() {
)
.build()
)
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ private constructor(private val okHttpClient: okhttp3.OkHttpClient, private val

private fun HttpRequest.toRequest(): Request {
var body: RequestBody? = body?.toRequestBody()
// OkHttpClient always requires a request body for PUT and POST methods
// OkHttpClient always requires a request body for PUT and POST methods.
if (body == null && (method == HttpMethod.PUT || method == HttpMethod.POST)) {
body = "".toRequestBody()
}
Expand Down Expand Up @@ -108,43 +108,27 @@ private constructor(private val okHttpClient: okhttp3.OkHttpClient, private val
val length = contentLength()

return object : RequestBody() {
override fun contentType(): MediaType? {
return mediaType
}
override fun contentType(): MediaType? = mediaType

override fun contentLength(): Long {
return length
}
override fun contentLength(): Long = length

override fun isOneShot(): Boolean {
return !repeatable()
}
override fun isOneShot(): Boolean = !repeatable()

override fun writeTo(sink: BufferedSink) {
writeTo(sink.outputStream())
}
override fun writeTo(sink: BufferedSink) = writeTo(sink.outputStream())
}
}

private fun Response.toResponse(): HttpResponse {
val headers = headers.toHeaders()

return object : HttpResponse {
override fun statusCode(): Int {
return code
}
override fun statusCode(): Int = code

override fun headers(): ListMultimap<String, String> {
return headers
}
override fun headers(): ListMultimap<String, String> = headers

override fun body(): InputStream {
return body!!.byteStream()
}
override fun body(): InputStream = body!!.byteStream()

override fun close() {
body!!.close()
}
override fun close() = body!!.close()
}
}

Expand All @@ -153,9 +137,7 @@ private constructor(private val okHttpClient: okhttp3.OkHttpClient, private val
MultimapBuilder.treeKeys(String.CASE_INSENSITIVE_ORDER)
.arrayListValues()
.build<String, String>()

forEach { pair -> headers.put(pair.first, pair.second) }

return headers
}

Expand All @@ -166,7 +148,7 @@ private constructor(private val okHttpClient: okhttp3.OkHttpClient, private val
class Builder {

private var baseUrl: HttpUrl? = null
// default timeout is 1 minute
// The default timeout is 1 minute.
private var timeout: Duration = Duration.ofSeconds(60)
private var proxy: Proxy? = null

Expand All @@ -176,8 +158,8 @@ private constructor(private val okHttpClient: okhttp3.OkHttpClient, private val

fun proxy(proxy: Proxy?) = apply { this.proxy = proxy }

fun build(): OkHttpClient {
return OkHttpClient(
fun build(): OkHttpClient =
OkHttpClient(
okhttp3.OkHttpClient.Builder()
.connectTimeout(timeout)
.readTimeout(timeout)
Expand All @@ -187,7 +169,6 @@ private constructor(private val okHttpClient: okhttp3.OkHttpClient, private val
.build(),
checkNotNull(baseUrl) { "`baseUrl` is required but was not set" },
)
}
}

private suspend fun Call.executeAsync(): Response =
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
// File generated from our OpenAPI spec by Stainless.

@file:Suppress("OVERLOADS_INTERFACE") // See https://youtrack.jetbrains.com/issue/KT-36102

package com.lithic.api.client

import com.lithic.api.core.RequestOptions
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
// File generated from our OpenAPI spec by Stainless.

@file:Suppress("OVERLOADS_INTERFACE") // See https://youtrack.jetbrains.com/issue/KT-36102

package com.lithic.api.client

import com.lithic.api.core.RequestOptions
Expand Down
Loading
Loading