networks

networks

Methods

(static) list(filteropt, cb) → {array}

Source:

List information about all networks available to either the current authenticated user or the team, if the user belongs to a team. The list method takes an optional first argument to limit the returned network objects.

Examples
paperspace.networks.list(function(err, res) {
  // handle error or result
});
$ paperspace networks list
# HTTP request:
https://api.paperspace.io
GET /networks/getNetworks
x-api-key: 1ba4f98e7c0...
# Returns 200 on success
//Example return value:
[
  {
    "id": "n123abc",
    "name": "Example Network",
    "region": "East Coast (NY2)",
    "dtCreated": "2016-12-22T16:36:42.613Z",
    "network": "10.64.21.0",
    "netmask": "255.255.255.0",
    "teamId": "te456def"
  }
]
Parameters:
Name Type Attributes Description
filter object <optional>

An optional filter object to limit the returned network objects

Properties
Name Type Attributes Description
id string <optional>

Optional network id to match on

name string <optional>

Optional name to match on

region string <optional>

Optional region to match on

dtCreated string <optional>

Optional datetime created value to match on

network string <optional>

Optional network to match on

netmask string <optional>

Optional netmask to match on

teamId string <optional>

Optional teamId to match on

cb function

Node-style error-first callback function

Returns:

[ network, ... ] - JSON array of network objects

Type
array