Giter Club home page Giter Club logo

token-headless-client's Introduction

Token Headless Client

The headless client for connecting to the Token platform

The headless client is a full client for the Chat service that exposes a control interface via Redis pubsub. It is primarily intended for use by bots.

Building executable fat jar

> gradle TokenHeadlessClientCapsule
> #path: build/libs/token-headless-1.0-SNAPSHOT-capsule.jar

Running

> java -jar build/libs/token-headless-1.0-SNAPSHOT-capsule.jar path/to/config.yml

Configuring

Configuration is done via passing a config.yml file as an argument to the client. Some configuration keys are optional, and will be pulled from ENV vars if missing.

server: https://token-chat-service.herokuapp.com # URL of Chat service
address: '0x...' # Ethereum address, pulled from env var TOKEN_CLIENT_ADDRESS if omitted
username: '' # username to be registered/updated with the ID server
seed: # wallet master seed, 12 word phrase, pulled from env var TOKEN_CLIENT_SEED if omitted
store: store # path to durable storage directory for Signal store
redis:
  uri: redis://username:password@hostname:port
  timeout: 2000

Postgres Configuration

3 different forms are accepted for Postgres configuration:

JDBC url + username/password

postgres:
  jdbcUrl: jdbc:postgresql://<host>:<port>/<dbname>
  port: 5432
  password: secret

URL

postgres:
  url: postgres://<username>:<password>@<host>:<port>/<dbname>

EnvKey (useful for environments such as Heroku that set a fixed env variable whose value is the Postgres uri)

postgres:
  envKey: DATABASE_URL

Redis Configuration

3 different forms are accepted for Redis configuration:

URI

redis:
  uri: redis://<username>:<password>@<host>:<port>

EnvKey

redis:
  envKey: REDIS_URL

Parts

redis:
  host: hostname
  port: 8000
  password: secret

Licence

Copyright (c) 2017 Token Browser, Inc

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.

token-headless-client's People

Contributors

tristan avatar lian avatar

Watchers

James Cloos avatar CrashOverride avatar

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.