Projects

Projects

Metafold projects endpoint.

Constructor

new Projects()

Source:

Classes

Projects

Methods

(async) create(name, accessopt, dataopt)

Create a project.
Source:
Parameters:
Name Type Attributes Default Description
name string Name of the project.
access string <optional>
private Project access. By default projects are private.
data Object <optional>
Optional project data. This parameter accepts arbitrary JSON-serializable data. Helpful for tracking application state.
Returns:
Project resource.

(async) delete(idopt)

Delete a project.
Source:
Parameters:
Name Type Attributes Description
id string <optional>
Override ID of project to delete. Defaults to client project ID.

(async) duplicate(id, name, accessopt)

Duplicate a project.
Source:
Parameters:
Name Type Attributes Default Description
id string Project to duplicate.
name string New project name.
access string <optional>
private New project access. By default projects are private.
Returns:
Project resource.

(async) get(idopt)

Get a project.
Source:
Parameters:
Name Type Attributes Description
id string <optional>
Override ID of project to get. Defaults to client project ID.
Returns:
Project resource.

(async) list(paramsopt)

List projects.
Source:
Parameters:
Name Type Attributes Description
params Object <optional>
Optional list parameters.
Name Type Attributes Description
sort string <optional>
Sort string. For details on syntax see the Metafold API docs. Supported sorting fields are: "id", "user", "name", "created", or "modified".
q string <optional>
Query string. For details on syntax see the Metafold API docs. Supported search fields are: "id", "user", and "name".
Returns:
List of project resources.

(async) update(idopt, paramsopt)

Update a project.
Source:
Parameters:
Name Type Attributes Description
id string <optional>
Override ID of project to update. Defaults to client project ID.
params Object <optional>
Optional update parameters.
Name Type Attributes Description
name string <optional>
Optional project name.
access string <optional>
Optional project access.
data Object <optional>
Optional project data. This parameter accepts arbitrary JSON-serializable data. Helpful for tracking application state.
graph Object <optional>
Optional shape JSON.
Returns:
Updated project resource.