Giter Site home page Giter Site logo

safuscan-api's Introduction

SAFUSCAN API

  • copy .env-example to .env
  • Generate self-signed certificate for proxy with the commands openssl req -x509 -out ./docker-proxy-certs/safu.crt -keyout ./docker/proxy-certs/safu.key \ -newkey rsa:2048 -nodes -sha256 \ -subj '/CN=localhost' -extensions EXT -config <( \ printf "[dn]\nCN=localhost\n[req]\ndistinguished_name = dn\n[EXT]\nsubjectAltName=DNS:localhost\nkeyUsage=digitalSignature\nextendedKeyUsage=serverAuth")
  • run docker-compose up -d
  • Token query is done at : https://localhost:443/api/info with query parameter address=TOKEN_ADDRESS and refresh=BOOLEAN to renew token info

safuscan-api's People

Contributors

mark0w avatar gregmeszaros avatar safu-protocol avatar oliverlabi avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar

Forkers

agunghermwan

safuscan-api's Issues

Convert to checksum address before storing to DB

Add a simple counter - stats per token + total

  • Each time the API get request is executed 2 things should happen

  • Counter for each token contract - suggest creating a new field api_stats_counter so we know each token address "popularity"

  • Increase the total_api_calls field this is a simple counter for now so we can track the number of times the API was used (we will expand on this later, such as IP address, auth token or wallet address to have better/specific API access permissions

SLICE error

api/info?address=0xa99c3ade9b6d4c9a1b786afae64ad62ab194e0bf

/usr/src/app/build/src/routes/info.js:72
        const burnedTokens = parseInt((yield (0, bsc_scan_service_1.getBurnedTokenAmount)(contractAddress)).slice(0, -tokenDecimals)) || 0;
                                                                                                            ^

TypeError: Cannot read properties of undefined (reading 'slice')
    at /usr/src/app/build/src/routes/info.js:72:109
    at Generator.next (<anonymous>)
    at fulfilled (/usr/src/app/build/src/routes/info.js:5:58)
    at processTicksAndRejections (node:internal/process/task_queues:96:5)

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.