Update API.md

This commit is contained in:
AJ ONeal 2017-08-02 18:47:07 -06:00
parent 9fc0436bf2
commit 79071b95c2
1 changed files with 5 additions and 5 deletions

10
API.md
View File

@ -146,16 +146,16 @@ module.exports.create = function (conf, deps, app) {
}; };
``` ```
Special methods for `app`: ### Special methods for `app`:
--------------------------
### app.handlePromise(request, response, promise, message); ```
app.handlePromise(request, response, promise, message);
```
`handlePromise` will respond to the request with the result of `promise` as JSON. `handlePromise` will respond to the request with the result of `promise` as JSON.
If there is an error, it will include `message` in order to help you debug. If there is an error, it will include `message` in order to help you debug.
Special properties of `request`: ### Special properties of `request`:
--------------------------------
```js ```js
req.getSiteCapability(pkg) // Promises a capability on behalf of the current site (req.experienceId) without exposing secrets req.getSiteCapability(pkg) // Promises a capability on behalf of the current site (req.experienceId) without exposing secrets