@tryghost/fastly-ip
v0.1.11
Published
Check whether an IPv4 or IPv6 address belongs to Fastly's published IP ranges. This is useful when deciding whether an incoming request or DNS result is routed through Fastly.
Maintainers
Keywords
Readme
Fastly Ip
Check whether an IPv4 or IPv6 address belongs to Fastly's published IP ranges. This is useful when deciding whether an incoming request or DNS result is routed through Fastly.
Install
npm install @tryghost/fastly-ip --save
or
pnpm add @tryghost/fastly-ip
Usage
const isFastlyIp = require('@tryghost/fastly-ip');
if (isFastlyIp('151.101.1.195')) {
console.log('Request came through Fastly');
}Develop
This is a monorepo package, managed from the repo root.
Follow the instructions for the top-level repo.
git clonethis repo &cdinto it as usual- Run
pnpm installto install top-level dependencies.
Run
pnpm --filter @tryghost/fastly-ip dev
Test
pnpm --filter @tryghost/fastly-ip lintruns lintpnpm --filter @tryghost/fastly-ip testruns lint and tests
Copyright & License
Copyright (c) 2013-2026 Ghost Foundation - Released under the MIT license.
