Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

embedly/embedly-lambda-proxy

Open more actions menu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Embedly Lambda Proxy

This is not meant to be a production service, just an example of using Amazon Lambda to create a proxy to Embedly's API.

Install

This uses serverless to deploy code to lambda

npm install -g serverless
npm install

Serverless needs AWS Creds to deploy, so add them to your .bash_profile

export AWS_ACCESS_KEY_ID=YOUR_KEY
export AWS_SECRET_ACCESS_KEY=YOUR_SECRET

Finally you'll need to edit embedly.js and add your API_KEY.

Deploy

Just run serverless deploy. Severless should output the following:

Serverless: Packaging service...
...
endpoints:
  GET - https://{id}.execute-api.us-east-1.amazonaws.com/dev/oembed
  GET - https://{id}.execute-api.us-east-1.amazonaws.com/dev/extract
functions:
  oembed: aws-nodejs-dev-oembed
  extract: aws-nodejs-dev-extract

You can now use these endpoints

window.fetch('https://{id}.execute-api.us-east-1.amazonaws.com/dev/oembed?url=http://embed.ly')
  .then((r)=> r.json())
  .then(console.log)

done.

About

An example lambda proxy to Embedly's API

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published
Morty Proxy This is a proxified and sanitized view of the page, visit original site.