All Projects → shal → mono

shal / mono

Licence: MIT license
🏦 Monobank SDK

Programming Languages

go
31211 projects - #10 most used programming language

Projects that are alternatives of or similar to mono

Mono-PWA
Monobank PWA — unofficial online web client for monobank
Stars: ✭ 24 (+33.33%)
Mutual labels:  monobank, monobank-api
monobank-api-client
Monobank API client wrapper build on promises
Stars: ✭ 29 (+61.11%)
Mutual labels:  monobank, monobank-api
transliteration-php
🇺🇦 🇬🇧 🔡 🐘 PHP library for transliteration.
Stars: ✭ 34 (+88.89%)
Mutual labels:  ukraine
ukrainian-dotnet-communities
List of Ukrainian .NET communities
Stars: ✭ 16 (-11.11%)
Mutual labels:  ukraine
Transliterate
Транслитерация для Laravel
Stars: ✭ 48 (+166.67%)
Mutual labels:  ukraine
geonames-ua
Unofficial repository of State Register of Geographical Names of Ukraine https://land.gov.ua/derzhavnyi-reiestr-heohrafichnykh-nazv/
Stars: ✭ 33 (+83.33%)
Mutual labels:  ukraine
awesome-maps-ukraine
A curated list of maps of Ukraine, ukrainian mappers and tools that they use or develop for creating and publish maps
Stars: ✭ 35 (+94.44%)
Mutual labels:  ukraine
awesome-ukraine
🇺🇦 A curated list of things that show the awesome side of Ukraine
Stars: ✭ 72 (+300%)
Mutual labels:  ukraine
haskell-study-group
Група з вивчення мови Хаскель
Stars: ✭ 40 (+122.22%)
Mutual labels:  ukraine
leobot
LeoBot telepresence robot
Stars: ✭ 19 (+5.56%)
Mutual labels:  ukraine

MonoBank SDK

Circle CI Docs Go Report Version

🏦 Golang client for Mono API.

Monobank API

You can find documentation for all types of API here.

  1. Introduction
  2. Documentation
  3. Using library
  4. Example
  5. Contributions

Introduction

Read access APIs for monobank app.

Please, use personal API only in non-commersial services.

If you have a service or application and you want to centrally join the API for customer service, you need to connect to a corporate API that has more features.

This will allow monobank clients to log in to your service (for example, in a financial manager) to provide information about the status of an account or statements.

Documentation

As far as monobank have 3 types of API, we prepated three usage documentations:

Use

This package has no dependencies, install it with command below

go get github.com/shal/mono

You can take a look and inspire by following examples

Example

package main

import (
    "fmt"
    "os"
    "time"

    "github.com/shal/mono"
)

func main() {
    personal := mono.NewPersonal("token")

    user, err := personal.User(context.Background())
    if err != nil {
        fmt.Println(err.Error())
        os.Exit(1)
    }

    from := time.Now().Add(-730 * time.Hour)
    to := time.Now()

    var account mono.Account

    for _, acc := range user.Accounts {
        ccy, _ := mono.CurrencyFromISO4217(acc.CurrencyCode)
        if ccy.Code == "UAH" {
            account = acc
        }
    }

    transactions, err := personal.Transactions(context.Background(), account.ID, from, to)
    if err != nil {
        fmt.Println(err.Error())
        os.Exit(1)
    }

    fmt.Printf("Account: %s\n", account.ID)

    fmt.Println("Transactions:")
    for _, transaction := range transactions {
        fmt.Printf("%d\t%s\n", transaction.Amount, transaction.Description)
    }
}

More about this example here.

Example

License

Project released under the terms of the MIT license.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].