Skip to content

mahboubii/serverless-mercury-parser

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Mercury Parser Lambda Function

Description

This module allows you quickly deploy your own version of Mercury Parser as a serverless function

Supported Providers

  • AWS

Deployment

  • Installing the serverless cli
# If you're using yarn
yarn global add serverless
yarn install

# If you're using npm
npm install serverless -g
npm install

# Deploying the function
serverless deploy

Usage

GET https://API.amazonaws.com/dev/parser?qs=[url]

The result looks like this:

{
	"title": "Thunder (mascot)",
	"content": "<div><div><p>This is the content of the page!</div></div>",
	"author": "Wikipedia Contributors",
	"date_published": "2016-09-16T20:56:00.000Z",
	"lead_image_url": null,
	"dek": null,
	"next_page_url": null,
	"url": "https://en.wikipedia.org/wiki/Thunder_(mascot)",
	"domain": "en.wikipedia.org",
	"excerpt": "Thunder Thunder is the stage name for the horse who is the official live animal mascot for the Denver Broncos",
	"word_count": 4677,
	"direction": "ltr",
	"total_pages": 1,
	"rendered_pages": 1
}