# secret (private) Manage your Paperspace secrets. Secrets are used to store sensitive information such as API keys, passwords, and other credentials. Secrets are safely injected into workloads as environment variables. An environment variable that uses a Secret does not reveal the contents of the secret itself. Secrets are created at the following levels: - Project (default): these secrets are applied to all resources in a project - Global: these secrets are applied to all resources on your current team For more information, see [secrets](https://docs.digitalocean.com/products/paperspace/accounts-and-teams/use-secrets/index.html.md). ## Global Flags These flags are available on all commands. ### –log-level, -l (string, optional) Enable debug logging. One of `debug`, `info`, `warning`, `error`, or `critical`. ### –json, -j (boolean, optional) Output JSON ### –api-key (string, optional) A Paperspace public API Key used for authenticating requests ### –help, -h (boolean, optional) Show help for a command * * * ## pspace secret create Create a secret in a project or team. ### Arguments #### \[argument] (string, required) The name of the secret. Must match the pattern `^[a-zA-Z][a-zA-Z0-9_]*$`. #### \[argument] (string, required) The value of the secret ### Flags #### –project-id, -p (string, optional) The ID of the project the secret is in. If not specified, the secret is created in the project linked to your current working directory. If you are not in a project directory, you are prompted to select a project. #### –global, -g (boolean, optional) Manage a secret that is available to the entire team you are currently logged into. By default, secrets are only available to a project. #### –cwd (string, optional) The directory to create the secret in ### Global Flags These flags are available on all commands. #### –log-level, -l (string, optional) Enable debug logging. One of `debug`, `info`, `warning`, `error`, or `critical`. #### –json, -j (boolean, optional) Output JSON #### –api-key (string, optional) A Paperspace public API Key used for authenticating requests #### –help, -h (boolean, optional) Show help for a command * * * ## pspace secret get Get a secret from a project or team. ### Arguments #### \[argument] (string, required) The name of the secret to get Must match the pattern `^[a-zA-Z][a-zA-Z0-9_]*$`. ### Flags #### –project-id, -p (string, optional) The ID of the project the secret is in. If not specified, the secret is created in the project linked to your current working directory. If you are not in a project directory, you are prompted to select a project. #### –global, -g (boolean, optional) Manage a secret that is available to the entire team you are currently logged into. By default, secrets are only available to a project. #### –cwd (string, optional) The directory to create the secret in #### –fields, -F (string, optional) The fields to include in the response. ### Global Flags These flags are available on all commands. #### –log-level, -l (string, optional) Enable debug logging. One of `debug`, `info`, `warning`, `error`, or `critical`. #### –json, -j (boolean, optional) Output JSON #### –api-key (string, optional) A Paperspace public API Key used for authenticating requests #### –help, -h (boolean, optional) Show help for a command * * * ## pspace secret list List secrets in your team or project. Pick a subset of fields to display: ``` pspace secret list -F name -F dtModified ``` ### Flags #### –limit (number, optional) The number of items to return in the next page. #### –after (string, optional) The cursor to fetch the next results from. #### –orderBy (string, optional) The field to order items by. One of dtCreated. #### –asc (boolean, optional) Whether to order items ascending. #### –desc (boolean, optional) Whether to order items descending. #### –fields, -F (string, optional) The fields to include in the response. #### –project-id, -p (string, optional) The ID of the project the secret is in. If not specified, the secret is created in the project linked to your current working directory. If you are not in a project directory, you are prompted to select a project. #### –global, -g (boolean, optional) Manage a secret that is available to the entire team you are currently logged into. By default, secrets are only available to a project. #### –cwd (string, optional) The directory to create the secret in ### Global Flags These flags are available on all commands. #### –log-level, -l (string, optional) Enable debug logging. One of `debug`, `info`, `warning`, `error`, or `critical`. #### –json, -j (boolean, optional) Output JSON #### –api-key (string, optional) A Paperspace public API Key used for authenticating requests #### –help, -h (boolean, optional) Show help for a command * * * ## pspace secret update Update a secret in a project or team. ### Arguments #### \[argument] (string, required) The name of the secret Must match the pattern `^[a-zA-Z][a-zA-Z0-9_]*$`. #### \[argument] (string, required) The value of the secret ### Flags #### –project-id, -p (string, optional) The ID of the project the secret is in. If not specified, the secret is created in the project linked to your current working directory. If you are not in a project directory, you are prompted to select a project. #### –global, -g (boolean, optional) Manage a secret that is available to the entire team you are currently logged into. By default, secrets are only available to a project. #### –cwd (string, optional) The directory to create the secret in ### Global Flags These flags are available on all commands. #### –log-level, -l (string, optional) Enable debug logging. One of `debug`, `info`, `warning`, `error`, or `critical`. #### –json, -j (boolean, optional) Output JSON #### –api-key (string, optional) A Paperspace public API Key used for authenticating requests #### –help, -h (boolean, optional) Show help for a command * * * ## pspace secret delete Delete a secret from a project or team. ### Arguments #### \[argument] (string, required) The name of the secret to delete Must match the pattern `^[a-zA-Z][a-zA-Z0-9_]*$`. ### Flags #### –project-id, -p (string, optional) The ID of the project the secret is in. If not specified, the secret is created in the project linked to your current working directory. If you are not in a project directory, you are prompted to select a project. #### –global, -g (boolean, optional) Manage a secret that is available to the entire team you are currently logged into. By default, secrets are only available to a project. #### –cwd (string, optional) The directory to create the secret in ### Global Flags These flags are available on all commands. #### –log-level, -l (string, optional) Enable debug logging. One of `debug`, `info`, `warning`, `error`, or `critical`. #### –json, -j (boolean, optional) Output JSON #### –api-key (string, optional) A Paperspace public API Key used for authenticating requests #### –help, -h (boolean, optional) Show help for a command