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

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
".": "0.1.0-alpha.22"
".": "0.1.0-alpha.23"
}
4 changes: 2 additions & 2 deletions .stats.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
configured_endpoints: 13
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/brand-dev%2Fbrand.dev-e685328e362a28f152bcadfd1ca49680a80bfb7a3834fd422f2e459507305405.yml
openapi_spec_hash: 475543f86e39715f76588de6ccf70beb
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/brand-dev%2Fbrand.dev-143086f8200f34e6ace805070e2a3ddccf15e30ed7ac3a7193f6a984f2413fa2.yml
openapi_spec_hash: f15bf2b836aee764c02a4fc185f13586
config_hash: 6aaf0fe6f8877c9c5d9af95597123cb4
13 changes: 13 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,18 @@
# Changelog

## 0.1.0-alpha.23 (2025-12-11)

Full Changelog: [v0.1.0-alpha.22...v0.1.0-alpha.23](https://github.com/brand-dot-dev/java-sdk/compare/v0.1.0-alpha.22...v0.1.0-alpha.23)

### Features

* **api:** api update ([046e40d](https://github.com/brand-dot-dev/java-sdk/commit/046e40dcfdb9b4d4f0f7da34ee8bd6b0a85d39ff))


### Documentation

* remove `$` for better copy-pasteabality ([60ed63d](https://github.com/brand-dot-dev/java-sdk/commit/60ed63dc1f7defbe52e659b7584d5e5e39fa6183))

## 0.1.0-alpha.22 (2025-12-01)

Full Changelog: [v0.1.0-alpha.21...v0.1.0-alpha.22](https://github.com/brand-dot-dev/java-sdk/compare/v0.1.0-alpha.21...v0.1.0-alpha.22)
Expand Down
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

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

[![Maven Central](https://img.shields.io/maven-central/v/com.branddev.api/brand-dev-java)](https://central.sonatype.com/artifact/com.branddev.api/brand-dev-java/0.1.0-alpha.22)
[![javadoc](https://javadoc.io/badge2/com.branddev.api/brand-dev-java/0.1.0-alpha.22/javadoc.svg)](https://javadoc.io/doc/com.branddev.api/brand-dev-java/0.1.0-alpha.22)
[![Maven Central](https://img.shields.io/maven-central/v/com.branddev.api/brand-dev-java)](https://central.sonatype.com/artifact/com.branddev.api/brand-dev-java/0.1.0-alpha.23)
[![javadoc](https://javadoc.io/badge2/com.branddev.api/brand-dev-java/0.1.0-alpha.23/javadoc.svg)](https://javadoc.io/doc/com.branddev.api/brand-dev-java/0.1.0-alpha.23)

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

Expand All @@ -13,7 +13,7 @@ It is generated with [Stainless](https://www.stainless.com/).

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

The REST API documentation can be found on [docs.brand.dev](https://docs.brand.dev/). Javadocs are available on [javadoc.io](https://javadoc.io/doc/com.branddev.api/brand-dev-java/0.1.0-alpha.22).
The REST API documentation can be found on [docs.brand.dev](https://docs.brand.dev/). Javadocs are available on [javadoc.io](https://javadoc.io/doc/com.branddev.api/brand-dev-java/0.1.0-alpha.23).

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

Expand All @@ -24,7 +24,7 @@ The REST API documentation can be found on [docs.brand.dev](https://docs.brand.d
### Gradle

```kotlin
implementation("com.branddev.api:brand-dev-java:0.1.0-alpha.22")
implementation("com.branddev.api:brand-dev-java:0.1.0-alpha.23")
```

### Maven
Expand All @@ -33,7 +33,7 @@ implementation("com.branddev.api:brand-dev-java:0.1.0-alpha.22")
<dependency>
<groupId>com.branddev.api</groupId>
<artifactId>brand-dev-java</artifactId>
<version>0.1.0-alpha.22</version>
<version>0.1.0-alpha.23</version>
</dependency>
```

Expand Down Expand Up @@ -244,13 +244,13 @@ The SDK uses the standard [OkHttp logging interceptor](https://github.com/square
Enable logging by setting the `BRAND_DEV_LOG` environment variable to `info`:

```sh
$ export BRAND_DEV_LOG=info
export BRAND_DEV_LOG=info
```

Or to `debug` for more verbose logging:

```sh
$ export BRAND_DEV_LOG=debug
export BRAND_DEV_LOG=debug
```

## ProGuard and R8
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ private constructor(
private val forceLanguage: ForceLanguage?,
private val maxSpeed: Boolean?,
private val mcc: String?,
private val phone: Double?,
private val timeoutMs: Long?,
private val additionalHeaders: Headers,
private val additionalQueryParams: QueryParams,
Expand Down Expand Up @@ -55,6 +56,9 @@ private constructor(
/** Optional Merchant Category Code (MCC) to help identify the business category/industry. */
fun mcc(): Optional<String> = Optional.ofNullable(mcc)

/** Optional phone number from the transaction to help verify brand match. */
fun phone(): Optional<Double> = Optional.ofNullable(phone)

/**
* Optional timeout in milliseconds for the request. If the request takes longer than this
* value, it will be aborted with a 408 status code. Maximum allowed value is 300000ms (5
Expand Down Expand Up @@ -93,6 +97,7 @@ private constructor(
private var forceLanguage: ForceLanguage? = null
private var maxSpeed: Boolean? = null
private var mcc: String? = null
private var phone: Double? = null
private var timeoutMs: Long? = null
private var additionalHeaders: Headers.Builder = Headers.builder()
private var additionalQueryParams: QueryParams.Builder = QueryParams.builder()
Expand All @@ -106,6 +111,7 @@ private constructor(
forceLanguage = brandIdentifyFromTransactionParams.forceLanguage
maxSpeed = brandIdentifyFromTransactionParams.maxSpeed
mcc = brandIdentifyFromTransactionParams.mcc
phone = brandIdentifyFromTransactionParams.phone
timeoutMs = brandIdentifyFromTransactionParams.timeoutMs
additionalHeaders = brandIdentifyFromTransactionParams.additionalHeaders.toBuilder()
additionalQueryParams =
Expand Down Expand Up @@ -166,6 +172,19 @@ private constructor(
/** Alias for calling [Builder.mcc] with `mcc.orElse(null)`. */
fun mcc(mcc: Optional<String>) = mcc(mcc.getOrNull())

/** Optional phone number from the transaction to help verify brand match. */
fun phone(phone: Double?) = apply { this.phone = phone }

/**
* Alias for [Builder.phone].
*
* This unboxed primitive overload exists for backwards compatibility.
*/
fun phone(phone: Double) = phone(phone as Double?)

/** Alias for calling [Builder.phone] with `phone.orElse(null)`. */
fun phone(phone: Optional<Double>) = phone(phone.getOrNull())

/**
* Optional timeout in milliseconds for the request. If the request takes longer than this
* value, it will be aborted with a 408 status code. Maximum allowed value is 300000ms (5
Expand Down Expand Up @@ -301,6 +320,7 @@ private constructor(
forceLanguage,
maxSpeed,
mcc,
phone,
timeoutMs,
additionalHeaders.build(),
additionalQueryParams.build(),
Expand All @@ -318,6 +338,7 @@ private constructor(
forceLanguage?.let { put("force_language", it.toString()) }
maxSpeed?.let { put("maxSpeed", it.toString()) }
mcc?.let { put("mcc", it) }
phone?.let { put("phone", it.toString()) }
timeoutMs?.let { put("timeoutMS", it.toString()) }
putAll(additionalQueryParams)
}
Expand Down Expand Up @@ -2322,6 +2343,7 @@ private constructor(
forceLanguage == other.forceLanguage &&
maxSpeed == other.maxSpeed &&
mcc == other.mcc &&
phone == other.phone &&
timeoutMs == other.timeoutMs &&
additionalHeaders == other.additionalHeaders &&
additionalQueryParams == other.additionalQueryParams
Expand All @@ -2335,11 +2357,12 @@ private constructor(
forceLanguage,
maxSpeed,
mcc,
phone,
timeoutMs,
additionalHeaders,
additionalQueryParams,
)

override fun toString() =
"BrandIdentifyFromTransactionParams{transactionInfo=$transactionInfo, city=$city, countryGl=$countryGl, forceLanguage=$forceLanguage, maxSpeed=$maxSpeed, mcc=$mcc, timeoutMs=$timeoutMs, additionalHeaders=$additionalHeaders, additionalQueryParams=$additionalQueryParams}"
"BrandIdentifyFromTransactionParams{transactionInfo=$transactionInfo, city=$city, countryGl=$countryGl, forceLanguage=$forceLanguage, maxSpeed=$maxSpeed, mcc=$mcc, phone=$phone, timeoutMs=$timeoutMs, additionalHeaders=$additionalHeaders, additionalQueryParams=$additionalQueryParams}"
}
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ internal class BrandIdentifyFromTransactionParamsTest {
.forceLanguage(BrandIdentifyFromTransactionParams.ForceLanguage.ALBANIAN)
.maxSpeed(true)
.mcc("mcc")
.phone(0.0)
.timeoutMs(1L)
.build()
}
Expand All @@ -31,6 +32,7 @@ internal class BrandIdentifyFromTransactionParamsTest {
.forceLanguage(BrandIdentifyFromTransactionParams.ForceLanguage.ALBANIAN)
.maxSpeed(true)
.mcc("mcc")
.phone(0.0)
.timeoutMs(1L)
.build()

Expand All @@ -45,6 +47,7 @@ internal class BrandIdentifyFromTransactionParamsTest {
.put("force_language", "albanian")
.put("maxSpeed", "true")
.put("mcc", "mcc")
.put("phone", "0.0")
.put("timeoutMS", "1")
.build()
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,7 @@ internal class BrandServiceAsyncTest {
.forceLanguage(BrandIdentifyFromTransactionParams.ForceLanguage.ALBANIAN)
.maxSpeed(true)
.mcc("mcc")
.phone(0.0)
.timeoutMs(1L)
.build()
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,7 @@ internal class BrandServiceTest {
.forceLanguage(BrandIdentifyFromTransactionParams.ForceLanguage.ALBANIAN)
.maxSpeed(true)
.mcc("mcc")
.phone(0.0)
.timeoutMs(1L)
.build()
)
Expand Down
2 changes: 1 addition & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ repositories {

allprojects {
group = "com.branddev.api"
version = "0.1.0-alpha.22" // x-release-please-version
version = "0.1.0-alpha.23" // x-release-please-version
}

subprojects {
Expand Down
Loading