Re: Five Bells Wallet Client

That should work, let me know if you run into any issues

On Mon, Jul 4, 2016 at 10:05 AM, Peter Thompson <
peter.thompson@thehumanchain.com> wrote:

> Hi Evan,
>
>
>
> Understood. As per below, I've already created accounts for the red and
> blue wallets and substituted these credentials in the code. Anything else
> that needs to be configured for the demo wallet client to run against the
> hosted red and blue wallets?
>
>
>
> Thanks,
>
>
>
> Pete
>
>
>
> *From:* Evan Schwartz [mailto:evan@ripple.com]
> *Sent:* 04 July 2016 14:58
>
> *To:* Peter Thompson
> *Cc:* Interledger Community Group
> *Subject:* Re: Five Bells Wallet Client
>
>
>
> You should create two new accounts on the red and blue wallets. Those
> aren't the real passwords for alice and bob :)
>
>
>
> On Mon, Jul 4, 2016 at 4:25 AM, Peter Thompson <
> peter.thompson@thehumanchain.com> wrote:
>
> 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> 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
>
> e-mail : *peter.thompson@thehumanchain.com
> <peter.thompson@thehumanchain.com>*
>
> 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
>
> [image: cid:7047F87A-7D04-477C-8ECD-EEB05F8ABD28]
>
>
>
>
>
>
>
> --
>
> Evan Schwartz | Software Architect | Ripple
>
> [image: ripple.com] <http://ripple.com>
>



-- 
Evan Schwartz | Software Architect | Ripple
[image: ripple.com] <http://ripple.com>

Received on Monday, 4 July 2016 14:14:18 UTC