express-client-validator
Version:
The purpose of this module is to be plugged in as a middleware when an app needs to validate the requests are coming from allowable clients.
35 lines (33 loc) • 769 B
JavaScript
// Generated by CoffeeScript 2.5.1
(function() {
module.exports = {
type: 'array',
minItems: 1,
items: {
type: 'object',
required: ["url", "methods", "clientIds"],
properties: {
url: {
description: 'the url pattern to restrict',
type: 'string',
minLength: 1
},
methods: {
description: 'a list of methods that are supported. e.g. GET, PUT',
type: 'array',
items: {
type: 'string'
},
minItems: 1
},
clientIds: {
description: 'a list of client ids that are supported.',
type: 'array',
items: {
type: 'string'
}
}
}
}
};
}).call(this);