Markdown

For developers

Import an existing repository

A local folder becomes a platform project with repositories, pipelines and deployment, either through the agent or with ap platform projects import-local.

On this page

The import creates a project from a local folder, clones the generated repositories, overlays your files and pushes to main; it needs ap login (CLI and agent plugin).

Via the CLI

ap platform projects import-local ~/code/shop "Shop"

The command takes path and project name (or --name), clones into ~/Documents/application-platform/<organization-slug>/<project-slug>/, copies the files without touching .git, .gitlab-ci.yml and env/*.generated.env, and commits and pushes every repository.

--slug, --description and --workspace-root set slug, description and workspace folder, --flat-layout uses the layout <workspace-root>/<project-slug> without the organization level, and --skip-commit skips commit and push; for several components you map subfolders with --repositories-json:

ap platform projects import-local ~/code/shop "Shop" \
  --repositories-json '[{"path":"homepage","name":"Marketing"},{"path":"api","name":"API"}]'

Supported stacks

The import only detects stacks of the wizard; the identifiers apply to techStack in --repositories-json and the MCP tools.

Type Identifiers
App flutter, react-native-expo, nextjs, native-ios, native-android
Homepage hugo, astro
Backend nestjs, fastapi, laravel
Package (only for an unambiguous package folder) dart-package, docker-image, npm, go, kotlin, pypi, terraform-module, terraform-provider, vscode-plugin

Django, Vue, Express, Symfony, Svelte, Spring and other frameworks are not in the wizard today; the agent then stops and names the missing framework.

Via the agent

With the agent plugin installed, open the folder in Cursor, Claude Code or Codex and paste this prompt; Bring in an existing project takes you from the account to this point.

You are importing an existing local project into the Application Platform.

Prerequisites – otherwise stop immediately and say what is missing:
- Application Platform account
- MCP server "application-platform" connected (signed in via the ap CLI)

Only these stacks are allowed:
- app: Flutter, React Native (Expo), Next.js, native iOS, native Android
- homepage: Hugo, Astro
- backend: NestJS, FastAPI, Laravel
- package only when unambiguous: Dart package, Docker image, NPM, Go, PyPI, Terraform module/provider, VS Code plugin

If a framework is not in that list (Django, Vue, Express, Symfony, Svelte, Spring, …): STOP.
Say clearly: "[name] is not in the wizard today (even if it is on the roadmap)."
Do not suggest a similar stack. Do not stretch the mapping.

Use the MCP tool platform_projects_import_local with the path of this folder and a project name. It creates the project, waits until setup is ready, clones the repositories into the workspace, overlays the local files, and pushes to main.
If that tool is missing: platform_projects_demo_json, platform_projects_create, platform_watch, platform_projects_clone, then copy the files over and push.
If create, import, or watch fails, report the error. Do not work around it with your own git clone or git remote add.
Do not overwrite generated CI or environment files. Put your own values in the custom environment files.
Do not commit secrets.

The import-existing-project skill checks ap, the session (platform_whoami) and the MCP server application-platform, confirms path and project name and calls platform_projects_import_local with path and name, optionally with slug, description, workspaceRoot and repositories[] (path, name, repositoryName, type, techStack). Older clients without this tool use platform_projects_create, platform_watch (subject project) and platform_projects_clone, overlay the files without .git, .gitlab-ci.yml and env/*.generated.env, and push to main.

If create, import or watch fails, that is the answer; the agent does not clone by hand, does not invent a second API and does not write secrets into commits or replies.

Working in the workspace afterwards

From now on you work in the cloned workspace instead of the old folder; there, AGENTS.md and CLAUDE.md from local-configuration apply, and every application starts with ap run-local (Local development). The first push has already started the pipelines (Git workflow and deployment).