SimpleOnchainApi class

Simple client for mint + balance using a public key as API credential. Backend must accept this public key in the header (e.g. x-api-key).

Constructors

SimpleOnchainApi({String baseUrl = 'https://ga-api.onchainlabs.ch', required String publicKey})
const

Properties

baseUrl String
final
hashCode int
The hash code for this object.
no setterinherited
publicKey String
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

balanceOf(String address) Future<Map<String, dynamic>>
Get token balance for address.
mint({required String address, required String amount, bool waitForTx = false}) Future<Map<String, dynamic>>
Mint tokens to address.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited