Skip to main content

create_project()

Python package: neptune-scale

Creates a project in a given Neptune workspace.

Parameters

NameTypeDefaultDescription
namestrNone Name of a project in the form workspace-name/project-name. If None, the value of the NEPTUNE_PROJECT environment variable is used.
workspacestr, optionalNoneName of your Neptune workspace. You can omit this argument if you include the workspace name in the name argument.
visibility"priv", "pub", or "workspace""priv"Level of privacy for the project. If "priv", only workspace members assigned to the project can access it (requires a subscription plan with access control). If "pub", the project is freely accessible to anyone on the internet. If "workspace", all workspace members can access it as owners.
descriptionstr, optionalNoneDescription of the project.
keystr, optionalNoneProject identifier. Must contain 1–10 upper case letters or numbers (at least one letter). For example, "PX2". If you leave it out, Neptune generates a project key for you.
fail_if_existsbool, optionalFalseIf the project already exists and this flag is set to True, an error is raised.
api_tokenstr, optionalNoneAccount's Neptune API token. If not provided, the value of the NEPTUNE_API_TOKEN environment variable is used. We recommend saving credentials as environment variables.

Returns

The name of the created project.

Examples

from neptune_scale.projects import create_project

create_project(
name="project-x",
workspace="team-alpha", # a workspace with this name must already exist
)

You can also pass the project path as a single argument, in the form workspace-name/project-name:

create_project(name="team-alpha/project-x")

More options:

create_project(
name="sandbox",
workspace="team-alpha", # a workspace with this name must already exist
visibility="workspace",
description="Sandbox project for testing purposes."
fail_if_exists=True,
api_token="h0dHBzOi8aHR0cHM6...Y2MifQ==",
)