mirror of
https://github.com/documentationjs/documentation.git
synced 2026-02-01 14:53:07 +00:00
* Compare strings as lowercase, to permit for v4+ compatibility * Fix bad reference to loc.name * Update README badge and fixture * Remove brfs dependency * Remove traverse * Remove browser transform support
184 lines
4.8 KiB
JSON
184 lines
4.8 KiB
JSON
[
|
|
{
|
|
"description": "Attempt to establish a cookie-based session in exchange for credentials.",
|
|
"tags": [
|
|
{
|
|
"title": "function",
|
|
"description": null,
|
|
"lineNumber": 1,
|
|
"name": null
|
|
},
|
|
{
|
|
"title": "name",
|
|
"description": null,
|
|
"lineNumber": 2,
|
|
"name": "sessions.create"
|
|
},
|
|
{
|
|
"title": "param",
|
|
"description": null,
|
|
"lineNumber": 3,
|
|
"type": {
|
|
"type": "NameExpression",
|
|
"name": "object"
|
|
},
|
|
"name": "credentials",
|
|
"properties": [
|
|
{
|
|
"title": "param",
|
|
"description": "Login username. Also accepted as `username` or `email`.",
|
|
"lineNumber": 4,
|
|
"type": {
|
|
"type": "NameExpression",
|
|
"name": "string"
|
|
},
|
|
"name": "credentials.name"
|
|
},
|
|
{
|
|
"title": "param",
|
|
"description": "Login password",
|
|
"lineNumber": 5,
|
|
"type": {
|
|
"type": "NameExpression",
|
|
"name": "string"
|
|
},
|
|
"name": "credentials.password"
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"title": "param",
|
|
"description": "Login username. Also accepted as `username` or `email`.",
|
|
"lineNumber": 4,
|
|
"type": {
|
|
"type": "NameExpression",
|
|
"name": "string"
|
|
},
|
|
"name": "credentials.name"
|
|
},
|
|
{
|
|
"title": "param",
|
|
"description": "Login password",
|
|
"lineNumber": 5,
|
|
"type": {
|
|
"type": "NameExpression",
|
|
"name": "string"
|
|
},
|
|
"name": "credentials.password"
|
|
},
|
|
{
|
|
"title": "param",
|
|
"description": "Gets passed `(err, { success:Boolean })`.",
|
|
"lineNumber": 6,
|
|
"type": {
|
|
"type": "OptionalType",
|
|
"expression": {
|
|
"type": "NameExpression",
|
|
"name": "function"
|
|
}
|
|
},
|
|
"name": "callback"
|
|
},
|
|
{
|
|
"title": "returns",
|
|
"description": "promise, to be resolved on success or rejected on failure",
|
|
"lineNumber": 7,
|
|
"type": {
|
|
"type": "NameExpression",
|
|
"name": "Promise"
|
|
}
|
|
}
|
|
],
|
|
"loc": {
|
|
"start": {
|
|
"line": 1,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 9,
|
|
"column": 3
|
|
}
|
|
},
|
|
"context": {
|
|
"loc": {
|
|
"start": {
|
|
"line": 10,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 14,
|
|
"column": 3
|
|
}
|
|
},
|
|
"code": "/** Attempt to establish a cookie-based session in exchange for credentials.\n * @function\n * @name sessions.create\n * @param {object} credentials\n * @param {string} credentials.name Login username. Also accepted as `username` or `email`.\n * @param {string} credentials.password Login password\n * @param {function} [callback] Gets passed `(err, { success:Boolean })`.\n * @returns {Promise} promise, to be resolved on success or rejected on failure\n */\nsessions.addMethod('create', 'POST / form', {\n // normalize request body params\n before({ body }) {\n }\n});\n"
|
|
},
|
|
"errors": [],
|
|
"function": null,
|
|
"name": "sessions.create",
|
|
"params": [
|
|
{
|
|
"title": "param",
|
|
"description": null,
|
|
"lineNumber": 3,
|
|
"type": {
|
|
"type": "NameExpression",
|
|
"name": "object"
|
|
},
|
|
"name": "credentials",
|
|
"properties": [
|
|
{
|
|
"title": "param",
|
|
"description": "Login username. Also accepted as `username` or `email`.",
|
|
"lineNumber": 4,
|
|
"type": {
|
|
"type": "NameExpression",
|
|
"name": "string"
|
|
},
|
|
"name": "credentials.name"
|
|
},
|
|
{
|
|
"title": "param",
|
|
"description": "Login password",
|
|
"lineNumber": 5,
|
|
"type": {
|
|
"type": "NameExpression",
|
|
"name": "string"
|
|
},
|
|
"name": "credentials.password"
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"title": "param",
|
|
"description": "Gets passed `(err, { success:Boolean })`.",
|
|
"lineNumber": 6,
|
|
"type": {
|
|
"type": "OptionalType",
|
|
"expression": {
|
|
"type": "NameExpression",
|
|
"name": "function"
|
|
}
|
|
},
|
|
"name": "callback"
|
|
}
|
|
],
|
|
"returns": [
|
|
{
|
|
"title": "returns",
|
|
"description": "promise, to be resolved on success or rejected on failure",
|
|
"lineNumber": 7,
|
|
"type": {
|
|
"type": "NameExpression",
|
|
"name": "Promise"
|
|
}
|
|
}
|
|
],
|
|
"members": {
|
|
"instance": [],
|
|
"static": []
|
|
},
|
|
"path": [
|
|
"sessions.create"
|
|
]
|
|
}
|
|
] |