> ## Documentation Index
> Fetch the complete documentation index at: https://apidoc.cometapi.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Use IntelliJ Translation Plugin with CometAPI

> Use this guide to configure IntelliJ Translation Plugin with CometAPI by setting the base URL, API key, and model or provider options.

The [IntelliJ Translation Plugin](https://plugins.jetbrains.com/plugin/8579-translation) adds AI translation capabilities directly into JetBrains IDEs. Connect it to CometAPI to translate code and text without leaving your editor.

## Prerequisites

* [IntelliJ IDEA](https://www.jetbrains.com/idea/) or another JetBrains IDE

* Translation Plugin installed — search for **Translation** in the JetBrains Marketplace

  <Frame>
    <img src="https://mintcdn.com/cometapi/mA1ovj6s0e3RM42l/images/integrations/810968_352994.png?fit=max&auto=format&n=mA1ovj6s0e3RM42l&q=85&s=3ea7331394d52a903c9b550830689eef" alt="JetBrains Marketplace showing the Translation plugin" width="972" height="806" data-path="images/integrations/810968_352994.png" />
  </Frame>

* A [CometAPI](https://www.cometapi.com) account with an active API key

## Setup

<Steps>
  <Step title="Get your CometAPI API key">
    Log in to the [CometAPI dashboard](https://www.cometapi.com/console). Click **Add API Key** and copy your key.

    <Frame>
      <img src="https://mintcdn.com/cometapi/E4FFvyMYmaOZoldp/images/integrations/810968_360264.png?fit=max&auto=format&n=E4FFvyMYmaOZoldp&q=85&s=686b18e5eda53581cd92f39b18683c01" alt="CometAPI dashboard — API keys section" width="1920" height="1005" data-path="images/integrations/810968_360264.png" />
    </Frame>

    <Frame>
      <img src="https://mintcdn.com/cometapi/E4FFvyMYmaOZoldp/images/integrations/810968_360265.png?fit=max&auto=format&n=E4FFvyMYmaOZoldp&q=85&s=4a5a528f1fbbeb3da7ace18066b73bd1" alt="Add API Key dialog in CometAPI console" width="1914" height="999" data-path="images/integrations/810968_360265.png" />
    </Frame>

    <Frame>
      <img src="https://mintcdn.com/cometapi/E4FFvyMYmaOZoldp/images/integrations/810968_360266.png?fit=max&auto=format&n=E4FFvyMYmaOZoldp&q=85&s=8462dfff1cf0a880c44effc7dccbc131" alt="CometAPI API key and base URL" width="1920" height="975" data-path="images/integrations/810968_360266.png" />
    </Frame>
  </Step>

  <Step title="Configure the translation engine">
    Click the Translation Plugin icon in the IDE toolbar → **Settings** → **Translation**. Select **OpenAI Translation** as the engine. In the settings panel on the right, enter `https://api.cometapi.com` in the **API Endpoint** field (the second field defaults to `/v1/chat/completions`). Paste your CometAPI key into **API Key** and click **Confirm**.

    <Frame>
      <img src="https://mintcdn.com/cometapi/SZhlxZhCnMLn__BW/images/overview/810968_364191.png?fit=max&auto=format&n=SZhlxZhCnMLn__BW&q=85&s=aef81a83f29f8eb16655ed4060425f50" alt="CometAPI dashboard — Add API Key button and key list" width="3824" height="1892" data-path="images/overview/810968_364191.png" />
    </Frame>

    <Frame>
      <img src="https://mintcdn.com/cometapi/HhtmQffktazbxUvS/images/overview/810968_364193.png?fit=max&auto=format&n=HhtmQffktazbxUvS&q=85&s=d893f659267150d0faf45f99eb5dffc1" alt="CometAPI API key details" width="2434" height="1232" data-path="images/overview/810968_364193.png" />
    </Frame>
  </Step>

  <Step title="Test the integration">
    Click **Test Service** in the plugin settings. A successful verification confirms the setup is working.

    <Frame>
      <img src="https://mintcdn.com/cometapi/mA1ovj6s0e3RM42l/images/integrations/810968_352997.png?fit=max&auto=format&n=mA1ovj6s0e3RM42l&q=85&s=2acec03c1fcd4584cf8448d588cf5d68" alt="IntelliJ Translation Plugin test — successful result" width="1092" height="944" data-path="images/integrations/810968_352997.png" />
    </Frame>
  </Step>
</Steps>

<Tip>
  To add custom models, enter the current model ID in the plugin’s model configuration field.

  <Frame>
    <img src="https://mintcdn.com/cometapi/mA1ovj6s0e3RM42l/images/integrations/810968_352998.png?fit=max&auto=format&n=mA1ovj6s0e3RM42l&q=85&s=1138ce4ff04851f6db1ff996ea91f667" alt="IntelliJ Translation Plugin model settings showing a custom model added" width="1215" height="874" data-path="images/integrations/810968_352998.png" />
  </Frame>
</Tip>
