HomeDev GuideAPI Reference
Dev GuideAPI ReferenceUser GuideGitHubNuGetDev CommunityDoc feedbackLog In
GitHubNuGetDev CommunityDoc feedback


## Code package naming convention

The first step to use the API is to bundle your web application into a code package. Use the following conventions when you name a code package (a package containing Web App binaries, configuration and so on).

\<app name>.\<package type>.app.\<version>.nupkg

  • _App name._ Optional.

  • _Package types._ Values are:

    • cms (primary Web App)

    • commerce (commerce manager)

  • _Version._ You can specify in different ways such as using a "date format" or a version number.

**Examples**



## Code package content

The package should contain the Web App-related files, which normally exists at the path _D:\\Home\\Site on the actual Azure Web App._

Only folders and files related to the code are allowed (that is, _wwwroot__applicationHost.xdt_), and a [metadata file](🔗) (optional) that should follow the package name.

**Sample folder structure**

  • myapp.cms.app.1.0.0.nupkg

    • wwwroot

      • App\_Data

        • jobs

          • continuous

            • WebJob

              • Run.cmd

              • ...

              • ...

              • ...

      • Web.config

      • Web.Integration.config

      • Web.Preproduction.config

      • Web.Production.config

    • applicationHost.xdt (optional)

    • applicationHost.Preproduction.xdt (optional)

    • applicationHost.Production.xdt (optional)

    • myapp.cms.app.nuspec (optional)

Transforms in any target environment need to be a part of the initial code package.

You can download an Optimizely Content Management System (CMS) sample site (Alloy) package example here: [alloy.cms.app.1.2.1.nupkg](🔗)

## Create a code package

You can create a package by deploying to a folder and zipping this folder.

**Example:**



You can zip this folder (_SitePackageContent_ in the example) as _cms.app.1.0.0.nupkg_  to make it a deployment package that you can use in DXP.