bitvavo / node-bitvavo-api

Node wrapper for the Bitvavo API
ISC License
19 stars 15 forks source link

add "apiUrl" and "wsUrl" options #2

Closed maozedong closed 4 years ago

maozedong commented 4 years ago

Hi! Thanks for useful api client! It saves a lot of time

One part is missing currently - it's useful to be able to set custom rest and ws api urls. For example it can be used in integration tests. It's a common scenario to create mocking server on localhost and use it with tests.

Options like this can be very useful

const bitvavo = require('bitvavo')().options({
  restUrl: 'http://localhost:8080'
  wsUrl: 'ws://localhost:8081'
})
joeri-vv commented 4 years ago

We've updated all SDK's to include this option, restUrl and wsUrl can now both be set through the options function.