Skip to content

Instantly share code, notes, and snippets.

@ashgansh
Created November 30, 2018 11:31
Show Gist options
  • Save ashgansh/b1ce745d82d6fa704cf7c489cc196105 to your computer and use it in GitHub Desktop.
Save ashgansh/b1ce745d82d6fa704cf7c489cc196105 to your computer and use it in GitHub Desktop.
const signerData = {
currency : 'ETH',
paymentAddress : PAYMENT_ADDRESS,
expectedAmount : '10000000000000000000',
data: { description: 'request-signer signed request' },
}
export async function signRequest() {
// you need get the necessary information to sign
// pass in your API_KEY to be able to sign requests
const response = await axios.post(SIGNER_URL, requestData, {headers: { authorization: `${API_KEY}` }})
return response.data;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment