This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import _ from 'lodash' | |
import crypto from 'crypto' | |
import urllib from 'url' | |
import querystring from 'querystring' | |
const SignedHeaders = 'content-type;host;x-hyper-content-sha256;x-hyper-date' | |
const HeaderContentHash = 'X-Hyper-Content-Sha256' | |
const Algorithm = 'HYPER-HMAC-SHA256' | |
const Region = 'us-west-1' | |
const Service = 'hyper' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const aws4 = require('hyper-aws4') | |
const https = require('https') | |
const credential = require('./credential') | |
const createError = (status, message) => { | |
const error = new Error(message) | |
error.status = status | |
return error | |
} |