WebAPI

open class WebAPI

Represents a single interface that exists within the Web API.

Constructors

Link copied to clipboard
constructor(httpClient: OkHttpClient, baseAddress: String, _interface: String, webAPIKey: String)

Types

Link copied to clipboard
Thrown when WebAPI request fails (non success response code).

Properties

Link copied to clipboard
val baseAddress: HttpUrl
Link copied to clipboard
val DEFAULT_BASE_ADDRESS: String = "https://api.steampowered.com/"
Link copied to clipboard

Functions

Link copied to clipboard
open fun call(function: String): KeyValue
open fun call(function: String, version: Int): KeyValue
open fun call(httpMethod: String, function: String): KeyValue
open fun call(function: String, parameters: Map<String, String>): KeyValue
open fun call(function: String, callback: Consumer<KeyValue>, error: Consumer<WebAPI.WebAPIRequestException>)
open fun call(function: String, version: Int, parameters: Map<String, String>): KeyValue
open fun call(httpMethod: String, function: String, version: Int): KeyValue
open fun call(httpMethod: String, function: String, parameters: Map<String, String>): KeyValue
open fun call(function: String, version: Int, callback: Consumer<KeyValue>, error: Consumer<WebAPI.WebAPIRequestException>)
open fun call(httpMethod: String, function: String, callback: Consumer<KeyValue>, error: Consumer<WebAPI.WebAPIRequestException>)
open fun call(httpMethod: String, function: String, version: Int, parameters: Map<String, String>): KeyValue
open fun call(function: String, parameters: Map<String, String>, callback: Consumer<KeyValue>, error: Consumer<WebAPI.WebAPIRequestException>)
open fun call(httpMethod: String, function: String, version: Int, callback: Consumer<KeyValue>, error: Consumer<WebAPI.WebAPIRequestException>)
open fun call(httpMethod: String, function: String, parameters: Map<String, String>, callback: Consumer<KeyValue>, error: Consumer<WebAPI.WebAPIRequestException>)
open fun call(httpMethod: String, function: String, version: Int, parameters: Map<String, String>, callback: Consumer<KeyValue>, error: Consumer<WebAPI.WebAPIRequestException>)
Manually calls the specified Web API function with the provided details.
Link copied to clipboard
open fun getInterface(): String