Earn Digital Cash From Your App

The Anypay Platform Makes It Super Easy To Profit By Bitcoin In Your App Or Website

Register Your API Keys

https://admin.anypayinc.com/api-keys

Requesting Payment with HTTP

const ANYPAY_API_SECRET = 'YOUR_API_KEY_HERE'
const http = require('superagent')
const requestJSON = {
template: [{
currency: 'DASH',
to: [{
currency: 'USD',
amount: 150,
address: 'XhEh7yEzbJtViSrmJEiJ73CVp1C37j8eW7'
}, {
currency: 'USD',
amount: 10,
address: 'XnEw2KjfLVAy1hSXMFWLCcod5X7rLM581p'
}]
}],
options: {
webhook: 'https://paypow.com/anypay/webhooks/payments',
redirect: 'https://paypow.com/anypay//payments'
}
}
let response = await http
.post('https://api.anypayinc.com/r')
.send(requestJSON)
.auth(ANYPAY_API_KEY, '')

Requesting Payment with Node.js

In this example we request payment in either DASH or BCH. Each payment request requires two different outputs one for five dollars and one for one dollar.

import { app } from 'anypay'
anypay = app(process.env.ANYPAY_API_SECRET)
let bill = 15
let tip = 3
let dashOption = {
currency: 'DASH',
to: [{
currency: 'USD',
amount: bill,
address: 'XhEh7yEzbJtViSrmJEiJ73CVp1C37j8eW7'
}, {
currency: 'USD',
amount: tip,
address: 'XnEw2KjfLVAy1hSXMFWLCcod5X7rLM581p'
}]
}
let bitcoincashOption = {
currency: 'BCH',
to: [{
currency: 'USD',
amount: bill,
address: 'bitcoincash:qztlw4ft8euq9wvzk27hh6lxtac2z4clay0w8v79zm'
}, {
currency: 'USD',
amount: tip,
address: 'bitcoincash:qp3cjuygakccjvq4k3ge3jjfmcalhz8a2sq2e0yum3'
}]
}
let request = await anypay.request([
dashOption, bitcoincashOption
], {
webhook: 'https://paypow.com/anypay/webhooks/payments',
redirect: 'https://paypow.com/anypay/webhooks/payments'
})
console.log(request)