RE: Five Bells Wallet Client

Hi Evan,

Many thanks. I was slightly confused as to how the Interledger modules were setup with NodeJS/NPM.

I've now successfully installed everything and in the process of trying to run the client example. I've created send.js with the code below (substituting the login credentials for ones I've created on the blue and red demo sites) and also receive.js.

Both JS files run without error but nothing is reported to the node console log for either. Receive.js also exists straight away where I would have expected it to wait for a payment.

I expect it's something simple I've missed but if you could advise accordingly that would be fantastic?

Thanks,

Pete

send.js:
const WalletClient = require('five-bells-wallet-client')

const sender = new WalletClient({
  address: 'alice@red.ilpdemo.org',
  password: 'super-secret-password'
})

sender.on('connect', () => {
  console.log('Sender connected')
})

sender.send({
  destination: 'bob@blue.ilpdemo.org',
  destinationAmount: '0.01',
  message: 'Still love you!',
  onQuote: (payment) => {
    console.log('Received a quote; this will cost us: ' + payment.sourceAmount)
  }
}).then((payment) => {
  console.log('Sent payment:', payment)
  console.log('')
}).catch((err) => {
  console.error(err.stack)
})

.and also receive.js with the following:

const WalletClient = require('five-bells-wallet-client')



const receiver = new WalletClient({

  address: 'bob@blue.ilpdemo.org',

  password: 'ultra-secret-password'

})



receiver.on('connect', () => {

  console.log('Receiver connected')

})



receiver.on('incoming', (payment) => {

  console.log('Received ' + payment.destinationAmount + ' bucks!')

  console.log(payment.sourceAccount + ' says: ' + payment.message)

})


From: Evan Schwartz [mailto:evan@ripple.com]
Sent: 01 July 2016 15:33
To: Peter Thompson
Cc: Interledger Community Group
Subject: Re: Five Bells Wallet Client


Hi Peter,

If you clone the repo you just need to run "npm install". If you want to install it as a dependency in another repo, run "npm install five-bells-wallet-client".

Best,
Evan
On Jul 1, 2016 10:24 AM, "Peter Thompson" <peter.thompson@thehumanchain.com<mailto:peter.thompson@thehumanchain.com>> wrote:
Dear Interledger,

I'm a technical consultant and developer attending the Interledger Workshop next week. In preparation for the workshop, I have been trying to deploy and test the Interledger client examples from Github but have been running into some issues.

I'm running Ubuntu for my development environment and have node v5.12.0 and npm v3.8.6 installed successfully. I've cloned the five-bells-wallet client from Github but when I run 'npm install five-bells-wallet-client --save' from the five-bells-wallet directory I get an NPM error:

'Refusing to install five-bells-wallet-client as a dependency of itself.'

Could you advise as to where I'm going wrong?

Kind Regards,

Pete

Peter Thompson
The Human Chain
Mobile : +44 (0) 7590 991 707<tel:%2B44%20%280%29%207590%20991%20707>
e-mail : peter.thompson@thehumanchain.com<mailto:peter.thompson@thehumanchain.com>
www.thehumanchain.com<http://www.thehumanchain.com/>

The Human Chain Ltd is a company registered in England and Wales with company number 3530984.
Office : Magdalen Centre, The Oxford Science Park, Oxford, OX4 4GA, UK

P Please consider your environmental responsibility before printing this e-mail
www.digitalservicestoolkit.com<http://www.digitalservicestoolkit.com>
[cid:image001.png@01D1D5D6.015154C0]

Received on Monday, 4 July 2016 08:26:12 UTC