Skip to content

feat(broadcasts): add duplicate endpoint - #241

Merged
dielduarte merged 2 commits into
mainfrom
feature/dev-2094-ruby-sdk-internal-squad-devtools
Sep 14, 2026
Merged

dielduarte merged 2 commits into
mainfrom
feature/dev-2094-ruby-sdk-internal-squad-devtools

Conversation

@gabrielmfern

@gabrielmfern gabrielmfern commented Sep 11, 2026 •

Copy link
Copy Markdown
Member

This ports the Node method resend.broadcasts.duplicate(id) to Ruby for POST /broadcasts/{id}/duplicate, the endpoint added in resend/resend-openapi#115. The release carries 1.16.0 in its own commit. No examples/ change, following the convention that feature PRs here ship lib + spec only; the @note on the method is kept on purpose to explain what the copy is, since the response alone does not say.

Claude ran the new method against staging with RESEND_BASE_URL pointed at api.resend-staging.com, duplicating broadcast e6bd3843-3cc7-4c0d-b7fd-e01cbb514a16, then deleted the copy.

dup.rb
require "resend"

Resend.api_key = ENV["RESEND_API_KEY"]

result = Resend::Broadcasts.duplicate("e6bd3843-3cc7-4c0d-b7fd-e01cbb514a16")
puts "object: #{result[:object]}"
puts "id: #{result[:id]}"
$ RESEND_API_KEY=$(fish -c ds) RESEND_BASE_URL=https://api.resend-staging.com/ bundle exec ruby -I lib /tmp/dup.rb
object: broadcast
id: 7a102835-36a7-4886-a4ca-4970fd99ccc0
$ http DELETE https://api.resend-staging.com/broadcasts/7a102835-36a7-4886-a4ca-4970fd99ccc0 "Authorization: Bearer $(fish -c ds)"
HTTP/1.1 200 OK
{"object":"broadcast","id":"7a102835-36a7-4886-a4ca-4970fd99ccc0","deleted":true}

🤖 Generated with Claude Code


Summary by cubic

Adds the duplicate method to Resend::Broadcasts to call POST /broadcasts/{id}/duplicate, porting the existing Node SDK feature to Ruby. Bumps the gem version to 1.16.0 and adds a spec covering the new call. Implements the duplicate broadcast endpoint for the Ruby SDK as part of DEV-2094.

Written for commit 3eb86d5. Summary will update on new commits.

Review in cubic

gabrielmfern and others added 2 commits September 11, 2026 14:45
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

cubic analysis

All reported issues were addressed across 4 files

Linked issue analysis

Linked issue: DEV-2094: Ruby SDK (internal, squad-devtools)

Status Acceptance criteria Notes
✅ Implement the Ruby broadcasts duplicate endpoint at POST /broadcasts/{id}/duplicate The new Resend::Broadcasts.duplicate method sends a POST request to the expected endpoint, with a spec verifying the path, verb, and response.
✅ Release the Ruby SDK with the new endpoint The gem version is bumped from 1.15.0 to 1.16.0 in the version file and lockfile.

Reply with feedback, questions, or to request a fix.

Re-trigger cubic

Comment thread spec/broadcasts_spec.rb
@gabrielmfern
gabrielmfern marked this pull request as ready for review September 11, 2026 19:16
@dielduarte
dielduarte merged commit c7cd1f9 into main Sep 14, 2026
8 checks passed
@dielduarte
dielduarte deleted the feature/dev-2094-ruby-sdk-internal-squad-devtools branch September 14, 2026 16:16
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.

3 participants