bity 0.3.5 copy "bity: ^0.3.5" to clipboard
bity: ^0.3.5 copied to clipboard

outdated

Minimalistic library for communicating with the Bity API v2.

example/main.dart

import 'package:bity/bity.dart';

void main() async {
  var client = Client('https://exchange.api.bity.com/');
  var estimate = await client
      .getEstimate(inputCurrency: "BTC", inputAmount: 1, outputCurrency: "EUR")
      .timeout(const Duration(seconds: 2));
  print('1 BTC costs $estimate EUR');

  var owner = Owner(
    "Some street",
    "Some city",
    "Some zip",
    "AT",
    "Some name",
  );
  await client.createCryptoToFiatOrder(
    inputCurrency: "BTC",
    outputAmount: 10.0,
    outputCurrency: "EUR",
    outputIban: "AT611904300234573201",
    owner: owner,
    reference: "inapay",
  );
  var orders = await client.getOrders();
  print('Orders: $orders');
  client.close();
}
0
likes
20
points
27
downloads

Publisher

unverified uploader

Weekly Downloads

Minimalistic library for communicating with the Bity API v2.

License

unknown (license)

Dependencies

http, iban

More

Packages that depend on bity