Home Manual Reference Source Repository
public class | source

API

Handles requests to the ESC Geoservice.

Constructor Summary

Public Constructor
public

Create a new instance of the API.

Member Summary

Public Members
public

Method Summary

Public Methods
public

Lookup currency information.

public

async geoip(ip: String | null): Promise<Object, Error>

Lookup GeoIP info for a given IP address.

Public Constructors

public constructor() source

Create a new instance of the API.

Public Members

public rootUrl: String source

Public Methods

public async currency(): Promise<Object, Error> source

Lookup currency information.

Return:

Promise<Object, Error>

public async geoip(ip: String | null): Promise<Object, Error> source

Lookup GeoIP info for a given IP address. Uses local IP if not provided.

Params:

NameTypeAttributeDescription
ip String | null

Return:

Promise<Object, Error>

GeoIP info. Throws if request fails.