Skip to content
This repository was archived by the owner on Jun 6, 2023. It is now read-only.

Commit 81ae8bf

Browse files
committed
document list method filters
1 parent 570b624 commit 81ae8bf

File tree

5 files changed

+63
-0
lines changed

5 files changed

+63
-0
lines changed

lib/machines/list.js

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,32 @@ var assign = require('lodash.assign');
88
* @method list
99
* @description List information about all machines available to either the current
1010
* authenticated user or the team, if the user belongs to a team.
11+
* The list method takes an optional first argument to limit the returned machine objects.
12+
* @param {object} [filter] - An optional filter object to limit the returned machine objects
13+
* @param {string} [filter.machineId] - Optional machine id to match on. Note: must be specified as "machineId", not "id".
14+
* @param {string} [filter.name] - Optional name to match on
15+
* @param {string} [filter.os] - Optional os to match on
16+
* @param {string} [filter.ram] - Optional ram value to match on
17+
* @param {number} [filter.cpus] - Optional cpu count to mactch on
18+
* @param {string} [filter.gpu] - Optional gpu to match on
19+
* @param {string} [filter.storageTotal] - Optional storageTotal value to match on
20+
* @param {string} [filter.storageUsed] - Optional storageUsed value to match on
21+
* @param {string} [filter.usageRate] - Optional usageRate value to match on
22+
* @param {number} [filter.shutdownTimeoutInHours] - Optional shutdownTimeoutInHours value to mactch on
23+
* @param {boolean} [filter.performAutoSnapshot] - Optional performAutoSnapshot value to match on, either true or false
24+
* @param {string} [filter.autoSnapshotFrequency] - Optional autoSnapshotFrequency value to mactch on
25+
* @param {number} [filter.autoSnapshotSaveCount] - Optional autoSnapshotSaveCount value to mactch on
26+
* @param {string} [filter.agentType] - Optional agentType value to mactch on
27+
* @param {string} [filter.dtCreated] - Optional datatime created value to match on
28+
* @param {string} [filter.state] - Optional state value to mactch on
29+
* @param {string} [filter.networkId] - Optional networkId to mactch on
30+
* @param {string} [filter.privateIpAddress] - Optional privateIpAddress to mactch on
31+
* @param {string} [filter.publicIpAddress] - Optional publicIpAddress to mactch on
32+
* @param {string} [filter.region] - Optional region to mactch on
33+
* @param {string} [filter.userId] - Optional userId to mactch on
34+
* @param {string} [filter.teamId] - Optional teamId to mactch on
35+
* @param {string} [filter.scriptId] - Optional scriptId to mactch on
36+
* @param {string} [filter.dtLastRun] - Optional script datatime last run value to match on
1137
* @param {function} cb - Node-style error-first callback function
1238
* @returns {array} [ machine, ... ] - JSON array of machine objects
1339
* @example

lib/networks/list.js

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,15 @@ var assign = require('lodash.assign');
88
* @method list
99
* @description List information about all networks available to either the current
1010
* authenticated user or the team, if the user belongs to a team.
11+
* The list method takes an optional first argument to limit the returned network objects.
12+
* @param {object} [filter] - An optional filter object to limit the returned network objects
13+
* @param {string} [filter.id] - Optional network id to match on
14+
* @param {string} [filter.name] - Optional name to match on
15+
* @param {string} [filter.region] - Optional region to match on
16+
* @param {string} [filter.dtCreated] - Optional datatime created value to match on
17+
* @param {string} [filter.network] - Optional network to mactch on
18+
* @param {string} [filter.netmask] - Optional netmask to mactch on
19+
* @param {string} [filter.teamId] - Optional teamId to mactch on
1120
* @param {function} cb - Node-style error-first callback function
1221
* @returns {array} [ network, ... ] - JSON array of network objects
1322
* @example

lib/scripts/list.js

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,16 @@ var assign = require('lodash.assign');
88
* @method list
99
* @description List information about all scripts assigned to either the current
1010
* authenticated user or the team, if the user belongs to a team.
11+
* The list method takes an optional first argument to limit the returned script objects.
12+
* @param {object} [filter] - An optional filter object to limit the returned script objects
13+
* @param {string} [filter.id] - Optional script id to match on
14+
* @param {string} [filter.ownerType] - Optional ownerType to match on, either 'user' or 'team'
15+
* @param {string} [filter.ownerId] - Optional ownerId to match on, either a userId or teamId
16+
* @param {string} [filter.name] - Optional name to match on
17+
* @param {string} [filter.description] - Optional description to mactch on
18+
* @param {string} [filter.dtCreated] - Optional datatime created value to match on
19+
* @param {boolean} [filter.isEnabled] - Optional isEnabled value to match on, either true or false
20+
* @param {boolean} [filter.runOnce] - Optional runOnce value to match on, either true or false
1121
* @param {function} cb - Node-style error-first callback function
1222
* @returns {array} [ script, ... ] - JSON array of script objects
1323
* @example

lib/templates/list.js

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,16 @@ var assign = require('lodash.assign');
88
* @method list
99
* @description List information about all templates available to either the current
1010
* authenticated user or the team, if the user belongs to a team.
11+
* The list method takes an optional first argument to limit the returned template objects.
12+
* @param {object} [filter] - An optional filter object to limit the returned template objects
13+
* @param {string} [filter.id] - Optional template id to match on
14+
* @param {string} [filter.name] - Optional name to match on
15+
* @param {string} [filter.label] - Optional label to mactch on
16+
* @param {string} [filter.os] - Optional os to match on
17+
* @param {string} [filter.dtCreated] - Optional datatime created value to match on
18+
* @param {string} [filter.teamId] - Optional teamId to match on
19+
* @param {string} [filter.userId] - Optional userId to match on
20+
* @param {string} [filter.region] - Optional region to match on
1121
* @param {function} cb - Node-style error-first callback function
1222
* @returns {array} [ template, ... ] - JSON array of template objects
1323
* @example

lib/users/list.js

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,14 @@ var assign = require('lodash.assign');
88
* @method list
99
* @description List information about all users available to either the current
1010
* authenticated user or the team, if the user belongs to a team.
11+
* The list method takes an optional first argument to limit the returned user objects.
12+
* @param {object} [filter] - An optional filter object to limit the returned user objects
13+
* @param {string} [filter.id] - Optional user id to match on
14+
* @param {string} [filter.email] - Optional email to match on
15+
* @param {string} [filter.firstname] - Optional firstname to mactch on
16+
* @param {string} [filter.lastname] - Optional lastname to match on
17+
* @param {string} [filter.dtCreated] - Optional datatime created value to match on
18+
* @param {string} [filter.teamId] - Optional teamId to match on
1119
* @param {function} cb - Node-style error-first callback function
1220
* @returns {array} [ user, ... ] - JSON array of user objects
1321
* @example

0 commit comments

Comments
 (0)