Skip to content

[client] add scheduleAt field support#47

Open
capcom6 wants to merge 1 commit intomasterfrom
client/mesages-scheduled-at-support
Open

[client] add scheduleAt field support#47
capcom6 wants to merge 1 commit intomasterfrom
client/mesages-scheduled-at-support

Conversation

@capcom6
Copy link
Copy Markdown
Member

@capcom6 capcom6 commented Apr 11, 2026

Summary by CodeRabbit

  • New Features
    • SMS messages can now be scheduled for future delivery by specifying a scheduled delivery time.

@codecov
Copy link
Copy Markdown

codecov bot commented Apr 11, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.

Files with missing lines Coverage Δ
smsgateway/domain_messages.go 100.00% <100.00%> (ø)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 6cfad481cb

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread smsgateway/domain_messages.go
@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Apr 11, 2026

Walkthrough

This PR updates the Message struct in domain_messages.go by reordering struct field tags (moving example before validate), adding a new optional ScheduleAt field for scheduled message delivery, and adding date-time format specification to the ValidUntil field.

Changes

Cohort / File(s) Summary
Message Struct Metadata Updates
smsgateway/domain_messages.go
Reordered struct tags for multiple fields (ID, DeviceID, Message, PhoneNumbers, IsEncrypted, SimNumber, WithDeliveryReport, Priority) to prioritize example before validate/omitempty; added format:"date-time" tag to ValidUntil field; introduced new optional ScheduleAt *time.Time field with json:"scheduleAt,omitempty" and format:"date-time" tags for scheduled message delivery.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

Possibly related PRs

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 inconclusive)

Check name Status Explanation Resolution
Title check ❓ Inconclusive The PR title mentions 'scheduleAt' but the raw summary and objectives reference 'scheduledAt' (with 'd'), indicating inconsistency in naming conventions across the PR. Clarify the correct field name: is it 'scheduleAt' or 'scheduledAt'? Update the title and code to use consistent naming throughout the pull request.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


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

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown

@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: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@smsgateway/domain_messages.go`:
- Line 97: Message.Validate() currently doesn't enforce the documented "must be
in the future" constraint for ScheduleAt; update the Message.Validate() method
to check if ScheduleAt is non-nil and if so ensure scheduleAt.After(time.Now())
(or .UTC() if you normalize times) and return a clear validation error (e.g.,
"scheduleAt must be in the future") when the check fails; reference the
ScheduleAt field and Message.Validate() so you add the nil check and After
comparison inside that validation path and include the new error in the existing
validation error handling.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 768da7d2-4feb-4192-8239-fff8f87d460e

📥 Commits

Reviewing files that changed from the base of the PR and between 6fc2205 and 6cfad48.

📒 Files selected for processing (1)
  • smsgateway/domain_messages.go

Comment thread smsgateway/domain_messages.go
@capcom6 capcom6 force-pushed the client/mesages-scheduled-at-support branch from 9fe33ca to 91d2438 Compare April 12, 2026 01:34
@capcom6 capcom6 changed the title [client] add scheduledAt field support [client] add scheduleAt field support Apr 12, 2026
@capcom6 capcom6 added the ready label Apr 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant