HomeGuidesAPI Reference
Submit Documentation FeedbackJoin Developer CommunityOptimizely GitHubOptimizely NuGetLog In

Initialize your first app

Initialize an app from scratch with the Optimizely Connect Platform (OCP) command-line interface (CLI).

This is the second step in creating your first app with OCP. Make sure you configure the OCP CLI before continuing. Complete these steps to scaffold an app on your local machine.

Initialize an app using the CLI

To create your app structure, run opti app init in the directory and follow the on-screen instructions. In this example, we build a marketing application.

  1. Enter the name of your app in the Name of your app prompt.



    In this example, the app is named My New Marketing App.

  2. Accept the default value for the ID of your app field.
  3. Update the Version to 0.0.0-dev.1.



    For more information on app versioning in OCP, see Update your app version.

  4. Enter a brief summary of your app in the App Summary field.
  5. Enter your support URL in the Support URL field.



    This must be a valid URL.

  6. Enter a valid email address in the Contact email address field.
  7. In the Select the category for the app prompt, select Marketing.
  8. In the Select a template project prompt, select Basic Sample. This builds a scaffold for a marketing app.
  9. In the Project directory name prompt, press enter to accept the directory name.



    The default is a hyphenated version of the app name you entered in step 1.

  10. Now, the CLI runs through the build process and creates the scaffold for the app. Move into the new directory or drop into your favorite code editor to take a look at the structure and files provided for your app.

Your app is now built on your local machine. For more information on the OCP app structure, see App Structure.

Next, learn how to publish your OCP app to the App Directory.


Publish Your First App