Parse session token validation for Hapi
Lead Maintainer: Per Ejeklint
A scheme for route authentication by validating the Parse session token against Parse's REST API. It requires valid Parse keys when configured and a session token passed in headers. This 'parse-access-token'
scheme takes the following options:
options
- (required)parse_rest_api_key
(required) - the Parse REST API key.parse_app_id
(required) - the Parse App ID.validatedFunc
- (optional) function called after successful validation with the signaturefunction(credentials, callback)
where:credentials
- an object with the credentials received from Parse.callback
- a callback function with the signaturefunction(err, credentials)
where:err
- an internal error.credentials
- a credentials object passed back to the application inrequest.auth.credentials
. If err is null, credentials must not be null.
var Hapi = ; var server = ;server; server; server; serverstart { console;}
License MIT @ Per Ejeklint 2015