Skip to content

jaimeiniesta/pageinspector

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Page Inspector

Page Inspector, MetaInspector as a service is a simple web service that allows you to scrape web pages for its meta data using the MetaInspector gem.

page inspector screenshot

Why?

To provide an easy way to get a web page attributes in JSON format.

Deploying

This is a Sinatra app, ready to be deployed into production on your server. This is extremely easy to do on Heroku, you just need to push it and you're ready to go.

Using it

The app has just one entry point, that accepts a single parameter for the URL to be shown, here's an example:

http://pageinspectordemo.herokuapp.com/scrape?url=https://github.com

This will fetch the URL and return its data in JSON format, that's all.

Following redirections

This app uses the OpenUriRedirections gem, that patches Ruby's OpenURI to allow redirections from HTTP to HTTPS and vice versa.

Specifying an User Agent

To be done.

Getting development env ready

Install gems for development

bundle install

Launch app in development:

We use the rerun gem so that it detects changes in the filesystem and reloads the app automatically.

rerun 'ruby app.rb'

The local server will be accessible at http://localhost:4567

License

This is free open source software uses the MIT license.

About

MetaInspector as a service

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages