Metron

constructor(baseUrl: String = "https://metron.cloud/api", username: String, password: String, userAgent: String = "Kraken/", timeout: Duration = 30.seconds, maxRetries: Int = 5, cache: SQLiteCache, policy: CachePolicy? = CachePolicy(percent = 0.1, expiry = 14.days))

Parameters

baseUrl

The base url of the Metron API.

username

The username for authentication with the Metron API.

password

The password for authentication with the Metron API.

userAgent

The HTTP User-Agent sent with every request.

timeout

The maximum duration to wait for a HTTP request to complete before timing out.

maxRetries

The maximum number of retry attempts for requests that fail due to RateLimiting errors.

cache

A SQLiteCache instance for caching API responses.

policy

An optional CachePolicy that determines how long cached responses remain valid and when they should be refreshed. If null, cached responses are never marked stale.