Skip to content

Keeps track of transactions sent via Gnosis Safe contacts and confirmed transactions. It also keeps track of Ether and ERC20 token transfers to Safe contracts.

License

Notifications You must be signed in to change notification settings

rsksmart/safe-transaction-service

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Build Status Coverage Status Python 3.8 Django 3

Gnosis Transaction Service

Keeps track of transactions sent via Gnosis Safe contracts. It uses events and tracing to index the txs.

Transactions are detected in an automatic way, so there is no need of informing the service about the transactions as in previous versions of the Transaction Service.

Transactions can also be sent to the service to allow offchain collecting of signatures or informing the owners about a transaction that is pending to be sent to the blockchain.

Swagger (Mainnet version) Swagger (Rinkeby version)

Index of contents

Setup for production

This is the recommended configuration for running a production Transaction service. docker-compose is required for running the project.

Configure the parameters needed on .env. These parameters need to be changed:

  • ETHEREUM_NODE_URL: Http/s address of a ethereum node. It can be the same than ETHEREUM_TRACING_NODE_URL.
  • ETHEREUM_TRACING_NODE_URL: Http/s address of a Ethereum Parity node with tracing enabled.

If you need the Usd conversion for tokens don't forget to configure:

  • ETH_UNISWAP_FACTORY_ADDRESS: Checksummed address of Uniswap Factory contract.
  • ETH_KYBER_NETWORK_PROXY_ADDRESS: Checksummed address of Kyber Network Proxy contract.

If you don't want to use trace_filter for the internal tx indexing and just rely on trace_block, set:

  • ETH_INTERNAL_NO_FILTER=1

For more parameters check base.py file.

Then:

docker-compose build --force-rm
docker-compose up

The service should be running in localhost:8000. You can test everything is set up:

curl 'http://localhost:8000/api/v1/about/'

For example, to set up a Göerli node:

Run a Parity node in your local computer:

parity --chain goerli --tracing on --db-path=/media/ethereum/parity --unsafe-expose

Edit .env so docker points to he host Parity:

ETHEREUM_NODE_URL=http://172.17.0.1:8545
ETHEREUM_TRACING_NODE_URL=http://172.17.0.1:8545

Then:

docker-compose build --force-rm
docker-compose up

Contributors

About

Keeps track of transactions sent via Gnosis Safe contacts and confirmed transactions. It also keeps track of Ether and ERC20 token transfers to Safe contracts.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Python 99.0%
  • Other 1.0%