npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@akamai-consulting/edgegrid-js-fetch

v0.1.5

Published

Signing and fetch library the Akamai OPEN EdgeGrid Authentication scheme in a JS environment that supports the fetch spec

Readme

EdgeGrid for Node.js

Build Status

This library implements an Authentication handler for the Akamai EdgeGrid Authentication scheme in JavaScript for environments supporting the WHATWG Fetch Standard

Install

npm install --save @akamai-consulting/edgegrid-js-fetch

Authentication

You can obtain the authentication credentials through an API client. Requests to the API are marked with a timestamp and a signature and are executed immediately.

  1. Create authentication credentials.

  2. Place your credentials in an EdgeGrid file ~/.edgerc, in the [default] section.

    [default]
    client_secret = C113nt53KR3TN6N90yVuAgICxIRwsObLi0E67/N8eRN=
    host = akab-h05tnam3wl42son7nktnlnnx-kbob3i3v.luna.akamaiapis.net
    access_token = akab-acc35t0k3nodujqunph3w7hzp7-gtm6ij
    client_token = akab-c113ntt0k3n4qtari252bfxxbsl-yvsdj
  3. Use your local .edgerc by creating a stream providing contents of your edgerc file.

    import {EdgeGridCredentials, EdgeGrid}  from '@akamai-consulting/edgegrid-js-fetch';
    
    const config = await EdgeGridCredentials.parseEdgercStream(
      Readable.toWeb(fs.createReadStream(
        path.join(os.homedir(), '.edgerc')
      ))
    );

    Alternatively, you can hard code your credentials by passing the credential values to the EdgeGridCredentials() constructor.

    import {EdgeGridCredentials, EdgeGrid}  from '@akamai-consulting/edgegrid-js-fetch';
    
    const clientSecret = "C113nt53KR3TN6N90yVuAgICxIRwsObLi0E67/N8eRN=",
          host = "akab-h05tnam3wl42son7nktnlnnx-kbob3i3v.luna.akamaiapis.net";
          accessToken = "akab-acc35t0k3nodujqunph3w7hzp7-gtm6ij",
          clientToken = "akab-c113ntt0k3n4qtari252bfxxbsl-yvsdj",
           
    
    const config = new EdgeGridCredentials(client_secret, host, access_token, client_token);

Use

The EdgeGrid class can be used to create a signed Request object

// Create EdgeGrid object from config
const eg = new EdgeGrid(config);

// Create Signed Request to get list of EdgeWorkers
const request = await eg.signRequest('/edgeworkers/v1/ids');

// Make request using the standard `fetch`
const response = await fetch(request);

The EdgeGrid class can also be used to directly perform a fetch, with the same options as the standard fetch

// Create EdgeGrid object from config
const eg = new EdgeGrid(config);

// Sign and fetch in a single step
const response = await eg.fetch('/edgeworkers/v1/ids');

Reporting issues

To report an issue or make a suggestion, create a new GitHub issue.

License

Copyright 2025 Akamai Technologies, Inc. All rights reserved.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use these files except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.