Giter Club home page Giter Club logo

cryptonabber-offramp's Introduction

cryptonabber-offramp

A CLI tool to make offramping with YNAB integration easier. It does the following:

  • For the configured offramp accounts, calculate the total outbound transactions, per account, that are outbound for a week, starting from a week from today
    • e.g., if you are executing this on February 2, it will retrieve outbound transactions for February 9 through Febrary 15, inclusive
  • For each account and for the configured source and destination account, generate the transactions in YNAB tracking:
  • The send of the funds from your wallet to the address being used for offramping
  • Transactions from the offramp address to each of the accounts to which funds are being offramped
  • Generates a QR code that can be scanned to send the funds to be used for offramping

Usage

This tool receives two parameters:

  • An access-token parameter containing your YNAB personal access token
  • A file parameter describing the location of the YAML file to drive the behavior of this tool

It will look like:

./cryptonabber-offramp --access-token="FAKE04678" --file="config.yaml"

Configuration

Below describes the expected structure of the YAML configuration file:

recipient_address: "<the address to which the funds are to be sent for offramping>"
contract_address: "<the contract adrdess of funds to be sent>"
decimals: <the number of decimals for the funds to be sent>
chain_id: <the ID of the chain on which the funds are to be sent>
qr_code_type: "<optional; the type of QR code to be generated; defaults to erc681 if not specified>"
ynab_budget_name: "<the name of the budget under which the involved accounts reside>"
ynab_accounts:
  funds_origin_account: "<the name of the account you use to track the wallet from which you'll be sending funds>"
  funds_recipient_account: "<the name of the account you use to track the address to which you'll be sending funds for offboarding>"
  offramp_accounts:
    - "<a list of the names of accounts to which the funds are to be offramped>"

QR Code Type

By default, this tool generates an ERC-681-compliant QR code. You can set the YAML file with the following values to change that:

  • erc681: the default; this generates an ERC-681-compliant QR code
  • recipient_only: the QR code will merely contain the address to which the funds are to be sent

cryptonabber-offramp's People

Contributors

dependabot[bot] avatar jrh3k5 avatar

Watchers

 avatar

cryptonabber-offramp's Issues

Allow selection of date range

Right now, the date range is hard-coded to starting a week after the current date. It should default that, but allow entry of the desired date range.

Transaction created for zero balance movement

If, during the given time period, there are no funds to move to a particular account, the tool still creates a zero-balance transaction moving funds between the offramp account and the destination account. It should not create a transaction at all in such a case.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.