Qodo

Qodoarrow-up-right is an AI code review platform that gives engineering teams deep codebase context to move faster without sacrificing code quality. In this guide, you’ll learn how to integrate it with Mailtrap MCP.

Note: You can use your AI agent to help you integrate Mailtrap or even migrate from another email service provider.

Prerequisites

Before you start, make sure to:

Step 1. Add Mailtrap MCP to Qodo.ai

First, open Qodo.ai from your preferred IDE. This can be VS Code, JetBrains IDEs, etc. For the purposes of this guide, we’ll use VSC.

Next, click on the Tools button right above the Qodo AI chatbox.

Then, click on + Add new MCP.

Once the following window appears after you click on Add new MCP, copy/paste the following code snippet:

Step 2. Insert Mailtrap API credentials

Next, all you need to do is replace the following values in the settings.json file:

  • MAILTRAP_API_TOKEN – Required for all functionality, used to authenticate API requests, which you can copy/paste from the credentials tab.

  • DEFAULT_FROM_EMAIL – Required for email sending. Make sure the email’s domain matches your own domain from the Sending Domains tab in Mailtrap.

You can find these credentials in your Mailtrap account by navigating to Sending DomainsIntegrationAPI.

  • MAILTRAP_ACCOUNT_ID – This is required for template management purposes. You can find the account ID under SettingsAccount Settings.

  • MAILTRAP_TEST_INBOX_ID – If you need sandbox email functionality, you can find this ID in your Sandbox.

Qodo.AI + Mailtrap MCP server possible use cases

Sandbox operations during code review

Imagine that you’re reviewing a part of the code responsible for sending emails and that you’re working in a staging environment using Sandboxarrow-up-right.

While reviewing your code, you want to trigger email-sending logic to better understand or verify behavior, test emails, etc.

This is possible from the Qodo agent, which lets you use simple prompts to, among other things:

  • Verify what the code actually does without switching to the Mailtrap UI and back to the IDE

  • Inspect basic message metadata

  • Use the returned message ID to request full message details (content, headers, etc.), and more.

Template validation during code review

Let’s say that while reviewing code, you notice a Mailtrap template ID being used and you’re unsure whether it’s the correct template.

From the Qodo agent, you can request the list of available templates in the Mailtrap account.

This allows you to quickly confirm that the referenced template is correct, directly within the review flow.

Don’t like the subject line of your template? Tweak it with a simple prompt, just like so:

Sending emails to your teammate

You’re working on designing an email or a template, and you want your teammate’s opinion.

For this, you can prompt Qodo something like this:

Migrating from another email service provider

If you’re migrating from another email service provider or just starting out with Mailtrap, you can ask the Qodo agent to update your credentials so you can start sending emails in no time.

Simply copy/paste the credentials or one of the ready-made code snippets into the chatbox and prompt the AI, like so:

Last updated

Was this helpful?