New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

urls-crawler

Package Overview
Dependencies
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

urls-crawler

Crawl all urls of a domain

  • 1.0.11
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
2
decreased by-85.71%
Maintainers
1
Weekly downloads
 
Created
Source

Urls Crawler

About this Package

Provide a fully qualified url to fetch all urls belongs to that domain.

It will give Active and dead urls in a object as output

It will save output in a file named as urls.json

Install:

npm install urls-crawler

Fetch urls

const Urls = require('urls-crawler').default
let urls = new Urls("https://www.example.com/")

urls.getAllUrls()
.then( allUrls => {
  let activeUrls = allUrls.active
  let deadUrls   = allUrls.dead 
  console.log("Active urls: ", activeUrls)
  console.log("Dead urls: ", deadUrls)
})
.catch( err => console.log(err))

Fetch urls of a blog

let urls = new Urls("https://www.example.com/blog/")

You can Specify a regex in parameters for specific url paths, Like specifying

let urls = new Urls("https://www.example.com/", "/blog")

It will fetch all urls which have /blog in their url path

Keywords

FAQs

Package last updated on 02 Mar 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc