# Overview

Monaca CI (Continuous Integration & Deployment) is a service that has been integrated within the current Monaca development environment stack to automate building and deployment cycles.&#x20;

This automation process is done by using webhooks. Webhooks allow you to build or set up integrations that subscribe to certain events (for example, code commit and branch/tag creation) on GitHub and many other Git services. For Monaca CI, every time you push your project code to the GitHub, GitHub will send a HTTP POST payload to the Monaca server. If the received information meets the Monaca CI configuration, the automation will begin.

Therefore, Monaca CI lets developers focus more on the code and less on the backend process of building, testing and deploying an app.

## Prerequisite

In order to use Monaca CI, you will need to integrate GitHub with your Monaca account. If you haven't done it, please follow the instructions below:

1. Link your Monaca account to GitHub. Please refer to [GitHub Integration](/products_guide/monaca_ide/version_control/github_integration.md).
2. Connect your project to your GitHub repository. Please refer to [Connecting a Monaca project to a new GitHub repository](/products_guide/monaca_ide/version_control/github_integration.md#connecting-a-monaca-project-to-a-new-github-repository).

## Getting started with Monaca CI

Assuming you have successfully linked a GitHub repository to your project, you are now ready to enable Monaca CI. Please do as follows:

1. From the Monaca Cloud IDE menu, go to **Configure → Continuous Integration**.
2. Monaca CI is disabled by default. To enable it, check the Triggers and then save it. That’s it! Now your Monaca CI is ready. You can start pushing your project code to the valid branch or tag as configured. Then, you should be able to find the built files under the `Build History` panel.

![](https://docs.monaca.io/images/monaca_ide/manual/monaca_ci/overview/3_en.png)

{% hint style="warning" %}
You have to start the build manually in the IDE (one time only) before the Monaca CI can start the automatic build later. This is because you will need to input a valid keystore (for Android) or upload the right provisioning profile (for iOS) for release build.
{% endhint %}

## Automating deploy services

You can also automate your app distribution process with Monaca CI. In order to do this, please do as follows:

1. From the Monaca Cloud IDE menu, go to **Configure → Deploy Services**.
2. Click **Add Deploy Service**.
3. Choose a deployment service and fill in the required information:
   * `Config Alias`: a unique identifier for each service
   * `Username (DeployGate only)`: app’s owner’s username or organization registered in DeployGate
   * `API Key` (DeployGate) or `API Token` (HockeyApp/Appetize): API key provided by the deployment service provider. For more information on how to get the API key for each service, please refer to [Deploy Services](/products_guide/monaca_ide/monaca_ci/supported_services.md).

![DeployGate](https://docs.monaca.io/images/monaca_ide/manual/monaca_ci/overview/1.png)

{% hint style="info" %}
You can have multiple deploy services configured in Monaca CI. You can also have multiple aliases for each deploy service. Please refer to [Deploy Services ](/products_guide/monaca_ide/monaca_ci/supported_services.md)regarding currently supported and upcoming deploy services.
{% endhint %}

## Monaca CI execution procedure

To use the Monaca CI to create a release build for iOS and Android when pushing the project code to a branch called `master`, read the following instructions. You can also use the Monaca CI to distribute the built files to two deployment services such as DeployGate and HockeyApp.

1. Push the code to GitHub.
2. If the code is pushed to a valid GitHub’s branch/tag, the Monaca server will start building your project. Please go to **Build → CI History** to see the live process of the Monaca CI. After the build is completed, you can find the built files in the `Build History` panel (**Build → Build History**).

![Preparing to Build](/files/-Mfg377aac9SkWhs9dKU)

![Building Complete](/files/-Mfg38c3P59TRhricPEg)

![Build Complete](/files/-Mfg3CXg8cpt0bsbSUqQ)

3\. When the build process is successfully completed in the Monaca server, the build files will be sent to the configured deployment services.


---

# 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://en.docs.monaca.io/products_guide/monaca_ide/monaca_ci/overview.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.
