@akamai-consulting/edgegrid-js-fetch
Version:
Signing and fetch library the Akamai OPEN EdgeGrid Authentication scheme in a JS environment that supports the fetch spec
14 lines (13 loc) • 802 B
TypeScript
/**
* Generated signed Request object
*
* @param {Request} request The request Object.
* @param {string} clientToken The client token value from the .edgerc file.
* @param {string} clientSecret The client secret value from the .edgerc file.
* @param {string} accessToken The access token value from the .edgerc file.
* @param {string} [nonce] A random string used to detect replayed request messages.
* @param {string} [timestamp] The timestamp with format "yyyyMMddTHH:mm:ss+0000".
*
* @returns {Promise<Request>} A Request object containing signed Authorization header
*/
export declare function generateAuthedRequest(request: Request, clientToken: string, clientSecret: string, accessToken: string, nonce?: string, timestamp?: string): Promise<Request>;