iComposer & AI
iComposer
iComposer IDE Support
Sidebar On this page

Introduction

The iComposer plugin for IntelliJ IDEA is a practical development tool that creatively integrates the InsureMO iComposer API into the IntelliJ IDEA workspace. This allows developers to interact with the API directly within their coding environment, minimizing the need to switch between tools. As a result, developers can focus on core coding tasks, significantly enhancing efficiency when working with the iComposer API.

Key Features

Comprehensive API Resource Management

During development, developers often need to quickly locate available APIs. The iComposer plugin offers a powerful API listing feature that efficiently displays all accessible iComposer APIs within the configured environment. With its clean interface, developers can instantly find the required API resources, regardless of quantity, saving time on manual searches.

Intuitive API Content Operation

The iComposer plugin provides a user-friendly interface for viewing and editing APIs. Developers can easily access detailed API documentation, and the powerful editing functionality supports flexible API modifications. Furthermore, the interface and code completion are designed to enhance developer workflow efficiency and productivity.

Real-time Synchronized Data Update Mechanism

When modifying the API content, saving changes to the target environment is essential. The iComposer plugin offers one-click save functionality, allowing API modifications to be directly saved to the target environment. This ensures real-time data synchronization between local and target environments and prevents development errors from data inconsistencies. Developers can then focus on coding and feature implementation.

Plugin Installation

The plugin is currently in internal testing. You can install it either by adding the InsureMO plugin repository (recommended for automatic updates) or by installing the packaged ZIP file directly. We will continue to collect feedback during this period and publish the plugin to the IntelliJ marketplace after testing completes.

Install IntelliJ IDEA

  • Visit the official IntelliJ IDEA website: IntelliJ IDEA.
  • Ensure download and install the latest version 2025.1.

Install Plugin

Use either of the following procedures.

  1. Open IntelliJ IDEA and choose Plugins from Settings/Preferences.

  2. On the Marketplace tab, select Manage Plugin Repositories and choose + to add a repository.

    iComposerIDE
  3. In the Add Repository dialog, enter https://portal.insuremo.com/api/eBao/1.0/clouddisk/v3/object/get/public?key=tools/dev/jetbrains-plugins/updatePlugins.xml&bucket=mo-public-resources, then confirm.

    iComposerIDE
  4. Return to the Marketplace tab, search for iComposer, and select Install.

    iComposerIDE
  5. If prompted, restart the IDE to complete installation.

Option 2: Install from a downloaded package

  1. Download the ZIP package: IntelliJ IComposer Plugin-1.2.18.zip.

  2. Open IntelliJ IDEA and choose Plugins from Settings/Preferences.

  3. Select the gear icon, choose Install Plugin from Disk, and select the downloaded ZIP file (for example, IntelliJ IComposer Plugin-1.2.18.zip).

    iComposerIDE
  4. If prompted, restart the IDE to apply the plugin.

    iComposerIDE

Configure iComposer Settings

  • Open your workspace in IntelliJ IDEA.
iComposerIDE iComposerIDE
  • On the right side, click the iComposer icon to access various command icons.
  • Click Open Settings.
  • Enter the information in Dev Workspace Configuration and InsureMO Tenant & Account Setting section.
  • Click OK to save the settings.
Dev Workspace ConfigurationDescription
URLThe debugging environment you’re referring to, where validation is required, could be ptdev, UAT, or similar. e.g. https://tenantCode-gi-ptdev.insuremo.com. Replace tenantCode with your own.
Tenant CodeThe tenant code you want to access.
UsernameAccount name for logging in to this tenant environment.
PasswordPassword for the account. Once saved, it cannot be viewed in plain text.
VerifyClick to let the system log in to the environment with the info above. If successful, a “Verified successfully” message will pop up. If failed, an “Authentication failed” message will appear.
InsureMO Tenant & Account Setting(BizAsset Account)Description
Tenant CodeThe tenant code you want to access.
UsernameAccount name for connecting to this tenant’s BizAsset. It can also be considered as the account credentials used to log into the tenant’s MC environment.
PasswordPassword for the account. Once saved, it cannot be viewed in plain text.
VerifyClick to let the system connected to BizAsset with the above info. If successful, a “Verified successfully” message will pop up. If failed, an “Authentication failed” message will appear.
Configure BizAsset repository (optional)Description
Git RepositoryThe service name that resolves to the Git repo URL hosting the BizAsset code.
Branch NameThe specific branch within that repo from which the BizAsset code is fetched.
Other ConfigurationDescription
Auto Load POM on StartupWhen checked, the IDE automatically loads the POM on startup to save time.
Auto Load Lingma Rules on StartupWhen checked, the latest Lingma code-style rules are synchronized on startup.
iComposerIDE

Maven Setup

note

For developers, the Maven settings file should have been configured. You can directly click Sync All Maven Projects. If synchronization fails, please follow the steps below.

Load Pom

  • If “Auto Load POM on Startup” has not been checked during configuration, you need manually click Load Pom here.
  • After successfully loading the pom.xml file, the lower right corner will prompt you to Load Maven Project, and click Load Maven Project.
iComposerIDE iComposerIDE

Prepare settings File

The company’s virtual machine network differs from the local external network, so the settings files also vary.

  • In the local external network, prepare a settings.xml file with the following content. Save the settings.xml file to a directory on the D drive, such as D:\localRepository\Maven_Repository.

    <?xml version="1.0" encoding="UTF-8"?>
    <settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd">

    <!-- Configure the local repository path -->
    <localRepository>D:\localRepository\Maven_Repository</localRepository>

    </settings>
  • In the virtual machine network, download the settings.xml. Enter the username and password for private repositories. Save the settings.xml file to a directory on the D drive, such as D:\localRepository\Maven_Repository.

To better manage disk space and improve performance, we recommend placing the Maven dependency on drive D. If you place it in a different location, please update the localRepository path in the settings.xml file accordingly.

iComposerIDE

Set Maven Paths

  • Maven project structure view will automatically appear on the right side.
  • Click Maven Settings to access the settings page.
  • In User settings file, specify the path to the saved settings.xml file, for example, D:\localRepository\settings.xml.
  • In Local repository, specify the path at the same level as the settings.xml file, for example, D:\localRepository\Maven_Repository.
iComposerIDE iComposerIDE

Load Maven Dependencies

  • Click Sync All Maven Projects.
  • If the operation fails, please check whether network restrictions are in place. If the issue remains unresolved, please contact our support team for further assistance.
iComposerIDE

Troubleshooting Dependency Fetching

  1. Network Problems

    • Cause: Unstable network connections.
    • Solution: Check your network connection.
  2. Incorrect Configuration

    • Cause: Errors in the pom.xml file or settings.xml file.
    • Solution: Verify that the dependency coordinates in the pom.xml are correct. Check the Maven repositories to confirm the correct version. Also, ensure that the settings.xml file is correctly configured.
  3. Dependency Conflicts

    • Cause: Multiple versions of the same dependency in the project.
    • Solution: Use the mvn dependency:tree command to analyze the dependency tree and identify conflicts. Resolve conflicts by specifying the correct version in the pom.xml file.
  4. Local Cache Issues

    • Cause: Corrupted or outdated local cache.
    • Solution: Clear the local Maven cache by deleting the .m2/repository directory or using the command mvn dependency:purge-local-repository. Then, rebuild the project using mvn clean install.
  5. Proxy Settings

    • Cause: Incorrect proxy settings.
    • Solution: If you are using a proxy server, ensure that the proxy settings in the settings.xml file are correct.

To effectively troubleshoot dependency fetching issues, it’s crucial to ensure a stable network connection and verify access to remote repositories. Regularly updating project dependencies and cleaning the local repository prevent issues caused by outdated or corrupted data. Additionally, IntelliJ IDEA can streamline dependency management. For example, you can invalidate caches and restart IDEA, or use the Maven Projects view to reimport dependencies, resolving many common issues. If the issue remains unresolved, please contact our support team for further assistance.

Plugin Usage

Commands

This introduction presents commands designed to boost productivity and improve the development journey.

note

The plugin is still in the development and internal testing phase, so some Commands are not available yet. The specific information will be based on the lastest version.

CommandsDescription
Load Current CodeLoads the latest code for the current API or function from the remote source.
Load All CodeLoads APIs and functions by module, or loads them all at once.
PushPush the code and metadata of the current API or function to environment.
Push and TestPush the code of the current API or function to dev environment and link to the online test UI page.
Bulk Push to DevLocally modified files can be selectively pushed to the configured dev environment.
Load All from BizAssetOnly displayed if “Configure BizAsset repository” is configured, loads all code from your configured BizAsset and branch.
Load Current from BizAssetOnly displayed if “Configure BizAsset repository” is configured, loads the latest code for the current API or function from your configured BizAsset and branch.
Commit to BizAssetOnly displayed if “Configure BizAsset repository” is configured, commit your modified API and function code to the configured BizAsset and branch.
Load All ModelsLoad the model you configured in iComposer Data Model.
Load Maven Dependency(pom.xml)Loads SDK and foundation dependency packages via pom.xml for code hints.
Add APIOpens a dialog to add a new API in the environment.
Add Service FunctionOpens a dialog to add a new function in the environment.
Update MetadataOpens a dialog to update basic information for APIs and functions.
Get Lingma RulesGet Lingma Project Rlues, which will be more helpful in assisting with the AI code generation of via Lingma AI code Assistant.
Load All SDK ClientLoads all InsureMO platform SDK client overview and swagger for reference and AI code generation.
Load Current Sdk Sample Code by ClientLoads individual Sdk Sample Code for the target SDK client for reference and AI code generation.
Load Test ResultsLoad current APIs or function test results from dev environment, along with the latest 5 user-favourite JSON records sorted by timestamp, from the environment to local storage.
Update TokensRe-generate API tokens when credentials expire.
Open SettingsOpen iComposer Settings Pane.
Open Help CenterDisplays the iComposer documentation.

Multi-Stream Development

In iComposer plugin development, in addition to the traditional centralized development model, a multi-stream development model is also supported. This model is particularly suitable for hot fix scenarios, which can improve development efficiency and reduce risks.

Centralized Development Mode

Application Scenarios: Individual development, simple function rapid validation (no team collaboration/emergency fixes required)
Core Features: Direct connection to MC environment, bypassing BizAsset version control, simplified process

Operating Steps:

  1. In the iComposer plugin configuration panel, configure the Dev Workspace Configuration environment parameters to the mc environment, then configure BizAsset repository.
  2. Click the “Load All Code” button in the plugin to fully load the MC environment code to the local.
  3. After modifying the target code locally, directly push to the MC environment for testing, and Commit the code to BizAsset after verification.

Multi-Stream Development Mode

Application Scenarios: Team collaboration development, online issue hot fix (emergency fixes)
Core Features: Must go through BizAsset version control to ensure code traceability and orderly team collaboration

Operating Steps:

  1. Configure the Dev Workspace Configuration environment parameters, such as the ptdev environment, then configure BizAsset repository.
  2. Select the corresponding code repository and branch in the iComposer plugin.
  3. Click “Load All Code” to fully load the code of the corresponding branch to the local.
  4. Modify the code that needs to be fixed locally.
  5. First push the modified code to the ptdev environment for testing.
  6. After confirming the fix is correct, Commit the code to the BizAsset main branch.

Commit(Show only “Configure BizAsset repository” is configured)

Commit your modified API and function code to the selected BizAsset. If the BizAsset data has already been updated by someone else, it will fail and show the error in the lower-right corner.

iComposerIDE

Push

  • After modifying current API or function, you can push it to the configured environment. If the remote code has already been updated by someone else, it will fail and show the error in the lower-right corner: “Compile Error: Save failed – Cannot update the new version data with old data! The newest version is 08, current version is 06“.
  • If you attempt to push changes to platform code, an error will appear in the lower-right corner: “Save failed: Can’t modify data of other tenant.”

Bulk Push to Dev

  • After modifying multiple files, you can selectively bulk push them to the configured environment. For files that fail to push, click the Message column to see the specific reason.
  • If a conflict occurs but you still want to push your local version to the environment for testing, just click the “Force Push” button on the page to complete the push.
  • For Source From BizAsset, the modified code is pushed to the configured development environment for debugging.
iComposerIDE iComposerIDE iComposerIDE iComposerIDE

Push and Test

Regardless of whether you source from Dev or BizAsset, both Push and Online Test UI always point to the configured Dev environment.
If a version mismatch between BizAsset and Dev blocks the push, use “Bulk Push to Dev” and click “Force Push” to overwrite the Dev version with your local copy, then return to run Online Test.

Load Current Code

Load the current API or function code. If the local and remote code conflict, the differences are displayed and highlighted so you can choose which to keep.

iComposerIDE iComposerIDE

Load All Code

  • You can either load all code at once or select only the modules you need. When a local file conflicts with its remote counterpart, you can choose whether to accept the remote version or keep the local one on a file-by-file basis.
  • If the tenant selects “Source From BizAsset”, only tenant-level data will be loaded. To load platform or other categories of code, switch the data source to “Source From Dev”.
iComposerIDE iComposerIDE

Add API/Service Function

Fill in the required fields on the page and select the corresponding Module and Group. Once added, groovy and metadata.json files are created under the corresponding group, just open them to edit. If the added Restful name already exists, an error “Save failed, Duplicate Restful name” will appear in the lower-right corner.

iComposerIDE iComposerIDE

Update Metadata

Update basic API/function info, for example, Module, Group, Status, Description, etc.

  • Tenant-level data: If your local version conflicts with the remote, you’ll get the error message: “Save failed – Cannot update the new version data with old data! The newest version is 06, current version is 05.”
  • Non-tenant data (read-only): Always kept in sync with the remote, no local override is allowed.
iComposerIDE

Load All SDK Client

When loading all SDK client, if you encounter a prompt indicating insufficient memory, you can adjust the memory allocation as suggested, up to 4098MB.

iComposerIDE

Shortcuts

IntelliJ IDEA automatically highlights unused code in gray, while valid code is displayed normally. It also offers a variety of shortcut operations to enhance productivity. For more information, please visit the IntelliJ IDEA Keyboard Shortcuts.

ShortcutsDescription
Double ShiftOpen the Search Everywhere window to find anything.
Ctrl + left-clickView the contents of a specific package.
Alt + EnterShow Context Actions such as Quick-fixes or assign local variable.
Ctrl + Alt + LReformat code.
Ctrl + EView recent file.
Hover 2sHover over the code for 2 seconds will display a brief introduction.
ToolsGroovy Console to test out groovy code snippet.
iComposerIDE iComposerIDE iComposerIDE iComposerIDE iComposerIDE iComposerIDE iComposerIDE

AI-assisted Debugging

Lingma Plugin

  • If needed, install the Lingma plugin to enhance coding efficiency.
  • If you have internet access, search for the Lingma plugin in Plugins and install it.
  • If you are in an intranet, click download Lingma_JetBrains_latest.zip in an internet-connected environment, then install it via Install Plugin from Disk on the intranet machine.
iComposerIDE

Lingma Project Rule

  • Executing the Get Lingma Rules command will default to loading the platform-defined project rule.
  • Users can utilize the platform’s default settings and customize their project rules.
  • This allows for flexibility in how projects are managed and debugged, especially when dealing with complex or specific requirements.
iComposerIDE

Code Optimization

  • Executing the Push Test command will link to the online testing UI page.
  • Users can click the Copy Debug to copy all relevant request bodies, parameters, logs, and responses for further analysis and code optimization in AI tools, such as Lingma AI.
  • This feature helps quickly identify issues and improve code quality through AI assistance.
iComposerIDE

JSON Optimization

  • Executing the Load Current Test Result command will load the test case.
  • The test cases can be directly fed into AI tools, like Lingma AI for optimization.
  • This operation streamlines the process of refining testing scenarios and enhancing testing coverage using AI capabilities.
iComposerIDE

Feedback
Was this page helpful?
|
Provide feedback