1.1.0 • Published 2 years ago

@exponential/utils v1.1.0

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

utils


validateCredential

This method can be used to validate calls made from the Exponential server to the API. To use this, download this package and import validateCredential then use it as a middleware in api.

Installation:

npm install @exponential/utils

Quick Start:

const { validateCredential } = require('@exponential/utils');

app.get("/path-to-be-authenticated-1", validateCredential.bind(null, process.env.API_SECRET), async (req, res) => {

})

app.post("/path-to-be-authenticated-2", validateCredential.bind(null, process.env.API_SECRET), async (req, res) => {

})
1.1.0

2 years ago

1.0.8

2 years ago

1.0.7

2 years ago

1.0.6

2 years ago

1.0.5

2 years ago

1.0.4

2 years ago

1.0.3

2 years ago

1.0.2

2 years ago

1.0.1

2 years ago