Socket
Socket
Sign inDemoInstall

seguir-express-middleware

Package Overview
Dependencies
2
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    seguir-express-middleware

Experss middleware for seguir self-hosted social network backend and API


Version published
Weekly downloads
3
increased by200%
Maintainers
1
Created
Weekly downloads
 

Readme

Source

Seguir Express Middleware

Part of the Seguir social platform

http://cliftonc.github.io/seguir/server

Middleware

This is express middleware that you can add to your own application, that will expose a set of local endpoints that you can use to build a front end for Seguir.

We have done it this way to enable you to wire up whatever authentication mechanism you like for users, with the only requirement being that the request hits the seguir middleware with a req.user object that has a seguirID (this can be over-ridden).

req.user = {
  seguirId: '92029c7b-0ded-4d4f-b782-b2514c3dbb47'
}

Adding to your application

Assuming your express app is running on /app, you can add the endpoints via:

var Seguir = require('seguir/client');
var seguir = new Seguir(config);
var seguirMiddleware = require('seguir-express-middleware');
app.use('/social', seguirMiddleware(seguir, authApi));

[Pronounced: seh-geer]

Keywords

FAQs

Last updated on 08 May 2015

Did you know?

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc