Add layer2 address separately
This commit is contained in:
parent
d9aaf2437f
commit
d1712ce1ce
7 changed files with 85 additions and 31 deletions
|
|
@ -1,12 +1,16 @@
|
|||
const axios = require('axios')
|
||||
const _ = require('lodash/fp')
|
||||
|
||||
const options = require('../../../options')
|
||||
|
||||
module.exports = {
|
||||
newAddress,
|
||||
getStatus,
|
||||
cryptoNetwork
|
||||
}
|
||||
|
||||
axios.defaults.baseURL = options.strike.baseUrl
|
||||
|
||||
function cryptoNetwork (account, cryptoCode) {
|
||||
return Promise.resolve('test')
|
||||
}
|
||||
|
|
@ -19,7 +23,7 @@ function checkCryptoCode (cryptoCode) {
|
|||
function getCharge (account, chargeId) {
|
||||
return axios({
|
||||
method: 'get',
|
||||
url: `https://api.strike.acinq.co/api/v1/charges/${chargeId}`,
|
||||
url: `v1/charges/${chargeId}`,
|
||||
auth: {username: account.token, password: ''}
|
||||
}).then(_.get('data'))
|
||||
}
|
||||
|
|
@ -33,7 +37,7 @@ function createCharge (account, info) {
|
|||
|
||||
return axios({
|
||||
method: 'post',
|
||||
url: 'https://api.strike.acinq.co/api/v1/charges',
|
||||
url: 'v1/charges',
|
||||
auth: {username: account.token, password: ''},
|
||||
data
|
||||
}).then(_.get('data'))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue