UNPKG

572 BJavaScriptView Raw
1const { getAPIKey } = require('./userConf');
2const { list } = require('../sdk');
3
4/**
5 * List currently deployed functions.
6 *
7 * @returns {object} Map of function name to tag, mod date and digest.
8 * e.g.
9 * {
10 * "foo": {
11 * "tags": {
12 * "latest": {
13 * "modifiedAt": "2018-05-21T12:13:15.145Z",
14 * "digest": "b8c7c75d25fd6d5d93518373f4bbbd7e11ee28fcb609fc28b6f134c5eaa0c9ba"
15 * }
16 * }
17 * }
18 * }
19 */
20const listCLI = async function listCLI() {
21 const apiKey = await getAPIKey();
22 return list(apiKey);
23};
24
25module.exports = listCLI;