Skip to content

Webpage Code Extractor API is a Node.js application with two endpoints: /view to fetch full HTML of a webpage, and /source to extract and filter HTML, CSS, and JavaScript code. It supports inline and external resources, offering combined or specific code retrieval for easy webpage analysis.

Notifications You must be signed in to change notification settings

9112000/WEB-Source

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Webpage Code Extractor API

This Node.js application provides two endpoints to fetch and analyze webpage content:

Endpoints

1. iFrame (Optional)

  • Purpose: Fetch and display the complete HTML of a webpage
  • Parameter: url (required) - The URL of the webpage to fetch
  • Example: http://localhost:3000/iframe?url=https://example.com (Optional)

2. Source

  • Purpose: Extract and combine HTML, CSS, and JavaScript code from a webpage
  • Parameters:
    • url (required) - The URL of the webpage to analyze
    • source (optional) - Filter by source type (html, css, or js)
  • Features:
    • Extracts inline and external CSS
    • Extracts inline and external JavaScript
    • Can return combined code or filtered by type
  • Examples:
    • All code: http://localhost:3000/source?url=https://example.com
    • Other: http://localhost:3000/source?url=https://example.com&source=CSS
    • Only HTML: http://localhost:3000/source?url=https://example.com&source=

About

Webpage Code Extractor API is a Node.js application with two endpoints: /view to fetch full HTML of a webpage, and /source to extract and filter HTML, CSS, and JavaScript code. It supports inline and external resources, offering combined or specific code retrieval for easy webpage analysis.

Topics

Resources

Stars

Watchers

Forks