Authentication

How to authenticate requests to the Transfers Connect API

To authenticate API requests, your public and private keys should be passed as request headers. Here's a JavaScript example with Apollo Boost:

const ApolloClient = require('apollo-boost').default;

const publicKey = process.env.MERCHANT_PUBLIC_KEY
const privateKey = process.env.MERCHANT_PRIVATE_KEY

const client = new ApolloClient({
    uri: process.env.TRANSFERS_CONNECT_API,
    fetch: fetch,
    headers: {
        authorization: 'Bearer ' + publicKey,
        'Private-Key': privateKey,
    }
})

Last updated