# Release Definition

Manage sandboxes via sfp server

* [`sfp server releasedefinition generate`](#sfp-server-releasedefinition-generate)

## `sfp server releasedefinition generate`

Generate a release definition based on artifacts using git tags and publish to server

```
USAGE
  $ sfp server releasedefinition generate -c <value> -f <value> -n <value> [--json] [--repository <value>] [-e <value>] [-t <value>]
    [--sfp-server-url <value>] [-b <value>] [-m <value>] [--skip-publish] [--scope <value> --npm] [--npmrcpath <value> ]
    [--loglevel trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]

FLAGS
  -b, --branch=<value>             The branch name for the release definition (helps server track the source branch)
  -c, --gitref=<value>             (required) Utilize the tags on the source branch to generate release definition
  -e, --email=<value>              [env: SFP_SERVER_USER] Email address for authenticated user. Ignored if
                                   --application-token is provided.
  -f, --configfile=<value>         (required) Path to the release config file which determines how the release
                                   definition should be generated
  -m, --metadata=<value>           Additional metadata in json format that needs to be added to the release definition
                                   file
  -n, --releasename=<value>        (required) Set a release name on the release definition file created
  -t, --application-token=<value>  [env: SFP_SERVER_TOKEN] Application token for CI/CD authentication. Takes precedence
                                   over --email.
      --loglevel=<option>          [default: info] logging level for this command invocation
                                   <options: trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL>
      --npm                        Validate that artifacts exist in NPM registry before including them in the release
                                   definition
      --npmrcpath=<value>          Path to .npmrc file for NPM registry authentication. Defaults to user's .npmrc if not
                                   provided
      --repository=<value>         The repository identifier. E.g `owner/repo`
      --scope=<value>              NPM scope for artifacts (e.g., @myorg). Required when using --npm flag
      --sfp-server-url=<value>     [env: SFP_SERVER_URL] URL of the SFP server. Can be set via environment variable
                                   `SFP_SERVER_URL` or config: sfp config:set server-url
      --skip-publish               Skip publishing the release definition to server

GLOBAL FLAGS
  --json  Format output as json.

DESCRIPTION
  Generate a release definition based on artifacts using git tags and publish to server

EXAMPLES
  $ sfp server releasedefinition generate -n MyRelease -c HEAD -f config/release.yml

  $ sfp server releasedefinition generate -n MyRelease -c HEAD -b main -f config/release.yml

  $ sfp server releasedefinition generate -n MyRelease -c abc123 -f config/release.yml -m '{"env":"prod"}'

  $ sfp server releasedefinition generate -n MyRelease -c HEAD -b develop -f config/release.yml --skip-publish
```

*See code:* [*src/commands/server/releasedefinition/generate.ts*](https://source.flxbl.io/flxbl/sfp-pro)


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.flxbl.io/flxbl/sfp/sfp-community/cli-reference-v50-and-below/server/releasedefinition.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
