Skip to content

Conversation

@vitalii-t
Copy link
Collaborator

@vitalii-t vitalii-t commented Sep 4, 2025

Motivation

Next steps implementing Mailtrap API - Email Templates

Changes

  • Added the EmailTemplates interface and implementation
  • Added request and response models
  • Covered with unit tests
  • Added an example class

Summary by CodeRabbit

  • New Features

    • Added Email Templates management to the client: create, list, retrieve, update, and delete templates.
    • Added request and response models for email templates.
    • Added an example demonstrating end-to-end Email Templates usage.
  • Bug Fixes

    • Enabled cascading validation for nested inbox create/update payloads.
  • Tests

    • Added tests covering Email Templates CRUD flows and validation error scenarios.

@coderabbitai
Copy link

coderabbitai bot commented Sep 4, 2025

Walkthrough

Adds Email Templates feature: API interface and implementation, request/response models, client wiring (API wrapper, client field, factory creation), example usage, unit tests with fixtures, and cascading validation on inbox request models.

Changes

Cohort / File(s) Summary
Email Templates API (interface & impl)
src/main/java/io/mailtrap/api/emailtemplates/EmailTemplates.java, src/main/java/io/mailtrap/api/emailtemplates/EmailTemplatesImpl.java
New EmailTemplates interface and EmailTemplatesImpl implementing CRUD operations against /api/accounts/{accountId}/email_templates..., with request validation on create/update.
Client integration
src/main/java/io/mailtrap/client/MailtrapClient.java, src/main/java/io/mailtrap/client/api/MailtrapEmailTemplatesApi.java, src/main/java/io/mailtrap/factory/MailtrapClientFactory.java
Adds MailtrapEmailTemplatesApi, exposes it as a new final field/getter on MailtrapClient, and wires EmailTemplatesImpl -> MailtrapEmailTemplatesApi in MailtrapClientFactory, updating constructor parameters.
Request models for templates
src/main/java/io/mailtrap/model/request/emailtemplates/*
Adds EmailTemplate, CreateEmailTemplateRequest, UpdateEmailTemplateRequest with Jackson mappings and Jakarta validation annotations.
Response model for templates
src/main/java/io/mailtrap/model/response/emailtemplates/EmailTemplateResponse.java
Adds EmailTemplateResponse DTO with id, uuid, metadata, body fields, and timestamp mappings.
Inbox request validation tweaks
src/main/java/io/mailtrap/model/request/inboxes/CreateInboxRequest.java, src/main/java/io/mailtrap/model/request/inboxes/UpdateInboxRequest.java
Adds @Valid to nested inbox payload fields to enable cascading validation.
Example
examples/java/io/mailtrap/examples/emailtemplates/EmailTemplates.java
New Java example demonstrating a linear CRUD flow using the Mailtrap client and printing results.
Tests & fixtures
src/test/java/io/mailtrap/api/emailtemplates/EmailTemplatesImplTest.java, src/test/java/io/mailtrap/testutils/BaseTest.java, src/test/resources/api/emailtemplates/*
New unit tests covering list/create/get/update/delete and validation failures; adds JSON fixtures and emailTemplateId test constant.

Sequence Diagram(s)

sequenceDiagram
  autonumber
  actor Dev as Developer App
  participant Factory as MailtrapClientFactory
  participant Client as MailtrapClient
  participant ApiWrap as MailtrapEmailTemplatesApi
  participant Service as EmailTemplatesImpl
  participant HTTP as Mailtrap HTTP Service

  Dev->>Factory: createMailtrapClient(config)
  Factory->>ApiWrap: new MailtrapEmailTemplatesApi(new EmailTemplatesImpl(config, validator))
  Factory-->>Dev: MailtrapClient(..., emailTemplatesApi, ...)
  Dev->>Client: emailTemplatesApi().emailTemplates().createEmailTemplate(accId, req)
  Client->>ApiWrap: emailTemplates()
  ApiWrap->>Service: createEmailTemplate(accId, req)
  Service->>Service: validateRequestBodyAndThrowException(req)
  Service->>HTTP: POST /api/accounts/{accId}/email_templates
  HTTP-->>Service: 201 EmailTemplateResponse
  Service-->>Dev: EmailTemplateResponse
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

Possibly related PRs

Suggested reviewers

  • mklocek
  • vittorius

Poem

Thump-thump my paws on keys so bright,
New templates hop to life tonight.
CRUD we nibble, bytes we chew,
JSON carrots, fresh and new.
Validations keep the burrow neat — ship it on bunny feet! 🥕🐇


📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

💡 Knowledge Base configuration:

  • MCP integration is disabled by default for public repositories
  • Jira integration is disabled by default for public repositories
  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between 7dfc546 and 38be8ef.

📒 Files selected for processing (1)
  • examples/java/io/mailtrap/examples/emailtemplates/EmailTemplates.java (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • examples/java/io/mailtrap/examples/emailtemplates/EmailTemplates.java
✨ Finishing Touches
  • 📝 Generate Docstrings
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch feature/email-templates

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

CodeRabbit Commands (Invoked using PR/Issue comments)

Type @coderabbitai help to get the list of available commands.

Other keywords and placeholders

  • Add @coderabbitai ignore or @coderabbit ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Status, Documentation and Community

  • Visit our Status Page to check the current availability of CodeRabbit.
  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🧹 Nitpick comments (17)
src/test/resources/api/emailtemplates/updateEmailTemplateRequest.json (1)

1-9: Consider modeling partial update if the endpoint is PATCH

If the update endpoint supports PATCH semantics, trimming unchanged fields keeps the fixture focused on the delta. If it’s PUT, ignore.

Example minimal PATCH-style fixture:

 {
   "email_template": {
-    "name": "My Updated Email Template",
-    "category": "Promotion",
-    "subject": "Promotion Template subject",
-    "body_text": "Promotion Text body",
-    "body_html": "<div>Promotion body</div>"
+    "name": "My Updated Email Template"
   }
 }
src/main/java/io/mailtrap/model/request/inboxes/CreateInboxRequest.java (1)

22-24: Strengthen string validation on name

@Size doesn’t fail on null/blank. Consider @NotBlank alongside @Size.

Add:

 import jakarta.validation.constraints.Size;
+import jakarta.validation.constraints.NotBlank;

         @JsonProperty("name")
-        @Size(min = 2, max = 100)
+        @NotBlank
+        @Size(min = 2, max = 100)
         private String name;
src/test/resources/api/emailtemplates/updateEmailTemplateResponse.json (1)

1-11: Make updated_at reflect a real update

For clarity, set updated_at later than created_at.

   "created_at": "2025-09-05T01:00:00Z",
-  "updated_at": "2025-09-05T01:00:00Z"
+  "updated_at": "2025-09-05T01:05:00Z"
src/main/java/io/mailtrap/model/request/inboxes/UpdateInboxRequest.java (2)

5-5: Also require presence of the nested object.

Add @NotNull to ensure the "inbox" payload is provided; otherwise Bean Validation won’t catch a missing body.

Apply:

-import jakarta.validation.Valid;
+import jakarta.validation.Valid;
+import jakarta.validation.constraints.NotNull;
@@
-    @Valid
+    @Valid
+    @NotNull
     @JsonProperty("inbox")
     private InboxUpdateData inboxUpdateData;

Also applies to: 14-16


10-20: Optional: add no-args ctors for Jackson-friendly deserialization.

If these models are ever deserialized from JSON, consider @NoArgsConstructor for both classes.

Apply:

 import lombok.AllArgsConstructor;
 import lombok.Getter;
+import lombok.NoArgsConstructor;
@@
 @Getter
 @AllArgsConstructor
+@NoArgsConstructor
 public class UpdateInboxRequest extends AbstractModel {
@@
     @Getter
     @AllArgsConstructor
+    @NoArgsConstructor
     public static class InboxUpdateData {
src/main/java/io/mailtrap/model/response/emailtemplates/EmailTemplateResponse.java (1)

3-5: Harden mapping against unknown fields.

Add @JsonIgnoreProperties(ignoreUnknown = true) to avoid breakage if API returns extra fields.

Apply:

-import com.fasterxml.jackson.annotation.JsonProperty;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
@@
-@Data
-public class EmailTemplateResponse {
+@Data
+@JsonIgnoreProperties(ignoreUnknown = true)
+public class EmailTemplateResponse {

Also applies to: 8-9

src/main/java/io/mailtrap/client/api/MailtrapEmailTemplatesApi.java (1)

8-13: Guard against nulls on dependency

Annotate the dependency as non-null to fail fast if miswired.

 import io.mailtrap.api.emailtemplates.EmailTemplates;
 import lombok.Getter;
 import lombok.RequiredArgsConstructor;
 import lombok.experimental.Accessors;
+import lombok.NonNull;

 @Getter
 @Accessors(fluent = true)
 @RequiredArgsConstructor
 public class MailtrapEmailTemplatesApi {
-  private final EmailTemplates emailTemplates;
+  private final @NonNull EmailTemplates emailTemplates;
 }
src/main/java/io/mailtrap/model/request/emailtemplates/CreateEmailTemplateRequest.java (1)

1-19: Parity with Update DTO + safer Jackson usage

Match Update DTO’s NON_NULL policy and add a protected no-args ctor for Jackson deserialization flexibility (future-proofing).

 package io.mailtrap.model.request.emailtemplates;

 import com.fasterxml.jackson.annotation.JsonProperty;
+import com.fasterxml.jackson.annotation.JsonInclude;
 import io.mailtrap.model.AbstractModel;
 import jakarta.validation.Valid;
 import jakarta.validation.constraints.NotNull;
 import lombok.AllArgsConstructor;
 import lombok.Getter;
+import lombok.AccessLevel;
+import lombok.NoArgsConstructor;

 @Getter
 @AllArgsConstructor
+@NoArgsConstructor(access = AccessLevel.PROTECTED)
+@JsonInclude(JsonInclude.Include.NON_NULL)
 public class CreateEmailTemplateRequest extends AbstractModel {

   @Valid
   @NotNull
   @JsonProperty("email_template")
   private EmailTemplate emailTemplate;

 }
src/main/java/io/mailtrap/model/request/emailtemplates/UpdateEmailTemplateRequest.java (1)

1-21: Add protected no-args constructor for Jackson

Keeps DTOs easy to deserialize if needed (tests/examples or future features).

 package io.mailtrap.model.request.emailtemplates;

 import com.fasterxml.jackson.annotation.JsonInclude;
 import com.fasterxml.jackson.annotation.JsonProperty;
 import io.mailtrap.model.AbstractModel;
 import jakarta.validation.Valid;
 import jakarta.validation.constraints.NotNull;
 import lombok.AllArgsConstructor;
 import lombok.Getter;
+import lombok.AccessLevel;
+import lombok.NoArgsConstructor;

 @Getter
 @AllArgsConstructor
 @JsonInclude(JsonInclude.Include.NON_NULL)
+@NoArgsConstructor(access = AccessLevel.PROTECTED)
 public class UpdateEmailTemplateRequest extends AbstractModel {

   @Valid
   @NotNull
   @JsonProperty("email_template")
   private EmailTemplate emailTemplate;

 }
examples/java/io/mailtrap/examples/emailtemplates/EmailTemplates.java (3)

12-14: Avoid hardcoding secrets; read from environment.

Safer for examples and prevents accidental token leaks.

-  private static final String TOKEN = "<YOUR MAILTRAP TOKEN>";
-  private static final long ACCOUNT_ID = 1L;
+  private static final String TOKEN = System.getenv("MAILTRAP_TOKEN");
+  private static final long ACCOUNT_ID = Long.parseLong(System.getenv().getOrDefault("MAILTRAP_ACCOUNT_ID", "0"));

26-27: Remove no-op instantiation.

This object is unused.

-    new EmailTemplate(EMAIL_TEMPLATE_NAME, EMAIL_TEMPLATE_CATEGORY, EMAIL_TEMPLATE_SUBJECT, EMAIL_TEMPLATE_BODY_TEXT, EMAIL_TEMPLATE_BODY_HTML);

21-70: Optional: basic error handling for example flow.

Wrap calls to show typical failure handling and avoid noisy stack traces in examples.

   public static void main(String[] args) {
-    final var config = new MailtrapConfig.Builder()
+    final var config = new MailtrapConfig.Builder()
         .token(TOKEN)
         .build();
-
-    final var client = MailtrapClientFactory.createMailtrapClient(config);
+    final var client = MailtrapClientFactory.createMailtrapClient(config);
+    try {
       // ... existing example calls ...
-    client.emailTemplatesApi().emailTemplates()
-        .deleteEmailTemplate(ACCOUNT_ID, updatedEmailTemplate.getId());
+      client.emailTemplatesApi().emailTemplates()
+          .deleteEmailTemplate(ACCOUNT_ID, updatedEmailTemplate.getId());
+    } catch (Exception e) {
+      System.err.println("Email Templates API example failed: " + e.getMessage());
+    }
   }
src/test/java/io/mailtrap/api/emailtemplates/EmailTemplatesImplTest.java (3)

94-96: Fix typo in test name (WIthWith).

Minor readability nit.

-  void test_createEmailTemplate_shouldFailOnValidationWIthNullableBody() {
+  void test_createEmailTemplate_shouldFailOnValidationWithNullableBody() {

88-91: Make assertion less brittle against message formatting changes.

Assert key parts separately to reduce coupling to exact text.

-    assertTrue(exception.getMessage().contains("Violations: emailTemplate.name=size must be between 1 and 255"));
+    assertTrue(exception.getMessage().contains("emailTemplate.name"));
+    assertTrue(exception.getMessage().contains("size must be between 1 and 255"));

138-141: Same robustness tweak for update validation message.

-    assertTrue(exception.getMessage().contains("Violations: emailTemplate.subject=size must be between 1 and 255"));
+    assertTrue(exception.getMessage().contains("emailTemplate.subject"));
+    assertTrue(exception.getMessage().contains("size must be between 1 and 255"));
src/main/java/io/mailtrap/api/emailtemplates/EmailTemplatesImpl.java (2)

21-29: Path building is duplicated; extract helpers.

Improves maintainability and reduces formatting mistakes.

 public class EmailTemplatesImpl extends ApiResourceWithValidation implements EmailTemplates {
@@
   public List<EmailTemplateResponse> getAllTemplates(long accountId) {
-    return
-        httpClient.getList(
-            String.format(apiHost + "/api/accounts/%d/email_templates", accountId),
-            new RequestData(),
-            EmailTemplateResponse.class
-        );
+    return httpClient.getList(path(accountId), new RequestData(), EmailTemplateResponse.class);
   }
@@
-        httpClient.post(
-            String.format(apiHost + "/api/accounts/%d/email_templates", accountId),
-            request,
-            new RequestData(),
-            EmailTemplateResponse.class
-        );
+        httpClient.post(path(accountId), request, new RequestData(), EmailTemplateResponse.class);
@@
-        httpClient.get(
-            String.format(apiHost + "/api/accounts/%d/email_templates/%d", accountId, emailTemplateId),
-            new RequestData(),
-            EmailTemplateResponse.class
-        );
+        httpClient.get(path(accountId, emailTemplateId), new RequestData(), EmailTemplateResponse.class);
@@
-        httpClient.patch(
-            String.format(apiHost + "/api/accounts/%d/email_templates/%d", accountId, emailTemplateId),
-            request,
-            new RequestData(),
-            EmailTemplateResponse.class
-        );
+        httpClient.patch(path(accountId, emailTemplateId), request, new RequestData(), EmailTemplateResponse.class);
@@
-    httpClient
-        .delete(
-            String.format(apiHost + "/api/accounts/%d/email_templates/%d", accountId, emailTemplateId),
-            new RequestData(),
-            Void.class
-        );
+    httpClient.delete(path(accountId, emailTemplateId), new RequestData(), Void.class);
+  }
+
+  private String path(long accountId) {
+    return String.format(apiHost + "/api/accounts/%d/email_templates", accountId);
+  }
+
+  private String path(long accountId, long emailTemplateId) {
+    return String.format(apiHost + "/api/accounts/%d/email_templates/%d", accountId, emailTemplateId);
   }

31-42: Validate IDs early to fail fast on obvious input mistakes.

Check positive IDs before network calls.

   public EmailTemplateResponse createEmailTemplate(long accountId, CreateEmailTemplateRequest request) {
+    if (accountId <= 0) {
+      throw new IllegalArgumentException("accountId must be > 0");
+    }
     validateRequestBodyAndThrowException(request);

And similarly add at the start of:

  • getAllTemplates(long accountId)
  • getEmailTemplate(long accountId, long emailTemplateId)
  • updateEmailTemplate(long accountId, long emailTemplateId, UpdateEmailTemplateRequest request)
  • deleteEmailTemplate(long accountId, long emailTemplateId)
📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

💡 Knowledge Base configuration:

  • MCP integration is disabled by default for public repositories
  • Jira integration is disabled by default for public repositories
  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between b3ae7da and 7dfc546.

📒 Files selected for processing (20)
  • examples/java/io/mailtrap/examples/emailtemplates/EmailTemplates.java (1 hunks)
  • src/main/java/io/mailtrap/api/emailtemplates/EmailTemplates.java (1 hunks)
  • src/main/java/io/mailtrap/api/emailtemplates/EmailTemplatesImpl.java (1 hunks)
  • src/main/java/io/mailtrap/client/MailtrapClient.java (1 hunks)
  • src/main/java/io/mailtrap/client/api/MailtrapEmailTemplatesApi.java (1 hunks)
  • src/main/java/io/mailtrap/factory/MailtrapClientFactory.java (3 hunks)
  • src/main/java/io/mailtrap/model/request/emailtemplates/CreateEmailTemplateRequest.java (1 hunks)
  • src/main/java/io/mailtrap/model/request/emailtemplates/EmailTemplate.java (1 hunks)
  • src/main/java/io/mailtrap/model/request/emailtemplates/UpdateEmailTemplateRequest.java (1 hunks)
  • src/main/java/io/mailtrap/model/request/inboxes/CreateInboxRequest.java (2 hunks)
  • src/main/java/io/mailtrap/model/request/inboxes/UpdateInboxRequest.java (2 hunks)
  • src/main/java/io/mailtrap/model/response/emailtemplates/EmailTemplateResponse.java (1 hunks)
  • src/test/java/io/mailtrap/api/emailtemplates/EmailTemplatesImplTest.java (1 hunks)
  • src/test/java/io/mailtrap/testutils/BaseTest.java (1 hunks)
  • src/test/resources/api/emailtemplates/createEmailTemplateRequest.json (1 hunks)
  • src/test/resources/api/emailtemplates/createEmailTemplateResponse.json (1 hunks)
  • src/test/resources/api/emailtemplates/getAllEmailTemplatesResponse.json (1 hunks)
  • src/test/resources/api/emailtemplates/getEmailTemplateResponse.json (1 hunks)
  • src/test/resources/api/emailtemplates/updateEmailTemplateRequest.json (1 hunks)
  • src/test/resources/api/emailtemplates/updateEmailTemplateResponse.json (1 hunks)
🧰 Additional context used
🧬 Code graph analysis (2)
src/main/java/io/mailtrap/client/api/MailtrapEmailTemplatesApi.java (1)
src/main/java/io/mailtrap/model/request/emailtemplates/CreateEmailTemplateRequest.java (1)
  • Getter (10-19)
src/main/java/io/mailtrap/model/request/emailtemplates/CreateEmailTemplateRequest.java (1)
src/main/java/io/mailtrap/model/AbstractModel.java (1)
  • AbstractModel (10-29)
🔇 Additional comments (13)
src/test/resources/api/emailtemplates/createEmailTemplateResponse.json (1)

1-11: Fixture LGTM

Payload structure and fields look consistent with the EmailTemplateResponse DTO and other fixtures.

src/main/java/io/mailtrap/model/request/inboxes/CreateInboxRequest.java (1)

14-16: Good call adding @Valid for cascading validation

This enables nested constraints on InboxCreateData to be enforced.

src/test/resources/api/emailtemplates/getEmailTemplateResponse.json (1)

1-11: Fixture LGTM

Fields and types align with the response DTO; consistent with other email template fixtures.

src/main/java/io/mailtrap/model/request/inboxes/UpdateInboxRequest.java (1)

14-16: Cascading validation enabled — LGTM.

Adding @Valid on the nested payload is correct and aligns with the validation on InboxUpdateData.

src/test/resources/api/emailtemplates/getAllEmailTemplatesResponse.json (1)

1-24: Fixture looks good.

Fields and snake_case keys match EmailTemplateResponse.

src/main/java/io/mailtrap/model/request/emailtemplates/EmailTemplate.java (1)

3-8: Enforce non-blank fields & require body content

  • Replace @NotNull @Size(min=1, max=255) on name, category, subject with:
    @NotBlank
    @Size(max = 255)
  • Add an @AssertTrue method to the class:
    @AssertTrue(message = "Either body_text or body_html must be provided")
    private boolean hasBodyContent() {
      return (bodyText != null && !bodyText.isBlank())
          || (bodyHtml != null && !bodyHtml.isBlank());
    }
    and import jakarta.validation.constraints.AssertTrue.
  • Confirm that @Size(max = 10_000_000) on the body fields aligns with Mailtrap’s server limits to prevent oversized payloads.
src/test/resources/api/emailtemplates/createEmailTemplateRequest.json (1)

1-9: Request fixture — LGTM.

Covers both body_text and body_html paths.

src/test/java/io/mailtrap/testutils/BaseTest.java (1)

26-26: LGTM: fixture ID for templates added

The emailTemplateId = 2222L aligns with the new fixtures and test usage.

src/main/java/io/mailtrap/client/MailtrapClient.java (1)

51-56: All MailtrapClient constructor invocations have been updated with the new parameter
Verified the sole instantiation in MailtrapClientFactory (now passing emailTemplatesApi at line 55); no further updates required.

src/main/java/io/mailtrap/api/emailtemplates/EmailTemplates.java (2)

9-55: Interface shape looks good and cohesive.

CRUD surface and DTO types are clear.


17-17: Ignore the rename suggestion: getAllTemplates follows the established getAll… naming used by other collection endpoints (e.g. getAllAccounts, getAllContactFields), so no change is needed.

Likely an incorrect or invalid review comment.

src/main/java/io/mailtrap/factory/MailtrapClientFactory.java (2)

100-104: Good separation for API wiring.

Helper keeps factory readable and follows existing pattern.


51-56: Constructor arity is correct and all call sites are in sync
MailtrapClientFactory’s new MailtrapClient(...) invocation matches the Lombok-generated constructor parameters; no other instantiations detected.

@vitalii-t vitalii-t merged commit c709eb3 into main Sep 8, 2025
2 checks passed
@vitalii-t vitalii-t deleted the feature/email-templates branch September 8, 2025 20:24
@coderabbitai coderabbitai bot mentioned this pull request Sep 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants