Skip to content

Commit 331e1ea

Browse files
authored
Merge pull request #7 from sentdm/release-please--branches--main--changes--next
release: 0.3.1
2 parents b5444dc + 83d90c6 commit 331e1ea

File tree

132 files changed

+1011
-274
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

132 files changed

+1011
-274
lines changed

.github/workflows/ci.yml

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,44 @@ on:
1313
- 'stl-preview-base/**'
1414

1515
jobs:
16+
build:
17+
timeout-minutes: 10
18+
name: build
19+
permissions:
20+
contents: read
21+
id-token: write
22+
runs-on: ${{ github.repository == 'stainless-sdks/sent-dm-ruby' && 'depot-ubuntu-24.04' || 'ubuntu-latest' }}
23+
if: |-
24+
github.repository == 'stainless-sdks/sent-dm-ruby' &&
25+
(github.event_name == 'push' || github.event.pull_request.head.repo.fork)
26+
steps:
27+
- uses: actions/checkout@v6
28+
- name: Set up Ruby
29+
uses: ruby/setup-ruby@v1
30+
with:
31+
bundler-cache: false
32+
- run: |-
33+
bundle install
34+
35+
- name: Get GitHub OIDC Token
36+
if: |-
37+
github.repository == 'stainless-sdks/sent-dm-ruby' &&
38+
!startsWith(github.ref, 'refs/heads/stl/')
39+
id: github-oidc
40+
uses: actions/github-script@v8
41+
with:
42+
script: core.setOutput('github_token', await core.getIDToken());
43+
44+
- name: Build and upload gem artifacts
45+
if: |-
46+
github.repository == 'stainless-sdks/sent-dm-ruby' &&
47+
!startsWith(github.ref, 'refs/heads/stl/')
48+
env:
49+
URL: https://pkg.stainless.com/s
50+
AUTH: ${{ steps.github-oidc.outputs.github_token }}
51+
SHA: ${{ github.sha }}
52+
PACKAGE_NAME: sentdm
53+
run: ./scripts/utils/upload-artifact.sh
1654
lint:
1755
timeout-minutes: 10
1856
name: lint

.release-please-manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
{
2-
".": "0.3.0"
2+
".": "0.3.1"
33
}

.stats.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 44
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/sent%2Fsent-dm-433bfd8c688a6b6d2d4f964bb59121d692798f4e2bb6cb47f6110c4f0e1f638d.yml
3-
openapi_spec_hash: 5378295d401c8c1152c1946cc7dbd69f
4-
config_hash: 43a0daa5b05d44a1620e3da0ea6f4fdc
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/sent%2Fsent-dm-c1e54655c045f25bd08ecc70c87f938e429911c413c09957d83d3eb9eaab2372.yml
3+
openapi_spec_hash: 44b7f99e2660bde83eff178b9d4ec00c
4+
config_hash: d475a61f5b59375bf562f85f19b80409

CHANGELOG.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,21 @@
11
# Changelog
22

3+
## 0.3.1 (2026-03-11)
4+
5+
Full Changelog: [v0.3.0...v0.3.1](https://github.com/sentdm/sent-dm-ruby/compare/v0.3.0...v0.3.1)
6+
7+
### Bug Fixes
8+
9+
* properly mock time in ruby ci tests ([4c4ebe0](https://github.com/sentdm/sent-dm-ruby/commit/4c4ebe03e980346d3ecc508e2740ad2ded666a8e))
10+
11+
12+
### Chores
13+
14+
* **ci:** add build step ([e67706a](https://github.com/sentdm/sent-dm-ruby/commit/e67706ab8895b76ca683a3e2e47244650be6aca0))
15+
* **ci:** skip uploading artifacts on stainless-internal branches ([1d6bb94](https://github.com/sentdm/sent-dm-ruby/commit/1d6bb94d3b4eb5b4383827200ead9f557c39c72f))
16+
* **internal:** codegen related update ([0dd8713](https://github.com/sentdm/sent-dm-ruby/commit/0dd871352c089d8e40788912ba5c1eec907f4640))
17+
* **internal:** codegen related update ([7b3ead8](https://github.com/sentdm/sent-dm-ruby/commit/7b3ead8de1ffc36ea448af5eed97ac1fc4f462bb))
18+
319
## 0.3.0 (2026-02-18)
420

521
Full Changelog: [v0.2.0...v0.3.0](https://github.com/sentdm/sent-dm-ruby/compare/v0.2.0...v0.3.0)

CONTRIBUTING.md

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -66,12 +66,6 @@ $ bundle exec rake
6666

6767
## Running tests
6868

69-
Most tests require you to [set up a mock server](https://github.com/stoplightio/prism) against the OpenAPI spec to run the tests.
70-
71-
```bash
72-
$ npx prism mock path/to/your/openapi.yml
73-
```
74-
7569
```bash
7670
$ bundle exec rake test
7771
```

Gemfile.lock

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ GIT
1111
PATH
1212
remote: .
1313
specs:
14-
sentdm (0.3.0)
14+
sentdm (0.3.1)
1515
cgi
1616
connection_pool
1717

README.md

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,15 @@ The Sent Dm Ruby library provides convenient access to the Sent Dm REST API from
44

55
It is generated with [Stainless](https://www.stainless.com/).
66

7+
## MCP Server
8+
9+
Use the Sent Dm MCP Server to enable AI assistants to interact with this API, allowing them to explore endpoints, make test requests, and use documentation to help integrate this SDK into your application.
10+
11+
[![Add to Cursor](https://cursor.com/deeplink/mcp-install-dark.svg)](https://cursor.com/en-US/install-mcp?name=%40sentdm%2Fsentdm-mcp&config=eyJjb21tYW5kIjoibnB4IiwiYXJncyI6WyIteSIsIkBzZW50ZG0vc2VudGRtLW1jcCJdLCJlbnYiOnsiU0VOVF9ETV9BUElfS0VZIjoiTXkgQVBJIEtleSJ9fQ)
12+
[![Install in VS Code](https://img.shields.io/badge/_-Add_to_VS_Code-blue?style=for-the-badge&logo=data:image/svg%2bxml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGZpbGw9Im5vbmUiIHZpZXdCb3g9IjAgMCA0MCA0MCI+PHBhdGggZmlsbD0iI0VFRSIgZmlsbC1ydWxlPSJldmVub2RkIiBkPSJNMzAuMjM1IDM5Ljg4NGEyLjQ5MSAyLjQ5MSAwIDAgMS0xLjc4MS0uNzNMMTIuNyAyNC43OGwtMy40NiAyLjYyNC0zLjQwNiAyLjU4MmExLjY2NSAxLjY2NSAwIDAgMS0xLjA4Mi4zMzggMS42NjQgMS42NjQgMCAwIDEtMS4wNDYtLjQzMWwtMi4yLTJhMS42NjYgMS42NjYgMCAwIDEgMC0yLjQ2M0w3LjQ1OCAyMCA0LjY3IDE3LjQ1MyAxLjUwNyAxNC41N2ExLjY2NSAxLjY2NSAwIDAgMSAwLTIuNDYzbDIuMi0yYTEuNjY1IDEuNjY1IDAgMCAxIDIuMTMtLjA5N2w2Ljg2MyA1LjIwOUwyOC40NTIuODQ0YTIuNDg4IDIuNDg4IDAgMCAxIDEuODQxLS43MjljLjM1MS4wMDkuNjk5LjA5MSAxLjAxOS4yNDVsOC4yMzYgMy45NjFhMi41IDIuNSAwIDAgMSAxLjQxNSAyLjI1M3YuMDk5LS4wNDVWMzMuMzd2LS4wNDUuMDk1YTIuNTAxIDIuNTAxIDAgMCAxLTEuNDE2IDIuMjU3bC04LjIzNSAzLjk2MWEyLjQ5MiAyLjQ5MiAwIDAgMS0xLjA3Ny4yNDZabS43MTYtMjguOTQ3LTExLjk0OCA5LjA2MiAxMS45NTIgOS4wNjUtLjAwNC0xOC4xMjdaIi8+PC9zdmc+)](https://vscode.stainless.com/mcp/%7B%22name%22%3A%22%40sentdm%2Fsentdm-mcp%22%2C%22command%22%3A%22npx%22%2C%22args%22%3A%5B%22-y%22%2C%22%40sentdm%2Fsentdm-mcp%22%5D%2C%22env%22%3A%7B%22SENT_DM_API_KEY%22%3A%22My%20API%20Key%22%7D%7D)
13+
14+
> Note: You may need to set environment variables in your MCP client.
15+
716
## Documentation
817

918
Documentation for releases of this gem can be found [on RubyDoc](https://gemdocs.org/gems/sentdm).
@@ -17,7 +26,7 @@ To use this gem, install via Bundler by adding the following to your application
1726
<!-- x-release-please-start-version -->
1827

1928
```ruby
20-
gem "sentdm", "~> 0.3.0"
29+
gem "sentdm", "~> 0.3.1"
2130
```
2231

2332
<!-- x-release-please-end -->

lib/sentdm/client.rb

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,30 +20,38 @@ class Client < Sentdm::Internal::Transport::BaseClient
2020
# @return [String]
2121
attr_reader :api_key
2222

23+
# Configure webhook endpoints for real-time event delivery
2324
# @return [Sentdm::Resources::Webhooks]
2425
attr_reader :webhooks
2526

27+
# Invite, update, and manage organization users and roles
2628
# @return [Sentdm::Resources::Users]
2729
attr_reader :users
2830

31+
# Manage message templates with variable substitution
2932
# @return [Sentdm::Resources::Templates]
3033
attr_reader :templates
3134

35+
# Manage organization profiles
3236
# @return [Sentdm::Resources::Profiles]
3337
attr_reader :profiles
3438

39+
# Send and track SMS and WhatsApp messages
3540
# @return [Sentdm::Resources::Messages]
3641
attr_reader :messages
3742

3843
# @return [Sentdm::Resources::Lookup]
3944
attr_reader :lookup
4045

46+
# Create, update, and manage customer contact lists
4147
# @return [Sentdm::Resources::Contacts]
4248
attr_reader :contacts
4349

50+
# Register and manage 10DLC brands for SMS compliance
4451
# @return [Sentdm::Resources::Brands]
4552
attr_reader :brands
4653

54+
# Retrieve account details
4755
# @return [Sentdm::Resources::Me]
4856
attr_reader :me
4957

lib/sentdm/internal/util.rb

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -490,6 +490,37 @@ def writable_enum(&blk)
490490
JSONL_CONTENT = %r{^application/(:?x-(?:n|l)djson)|(:?(?:x-)?jsonl)}
491491

492492
class << self
493+
# @api private
494+
#
495+
# @param query [Hash{Symbol=>Object}]
496+
#
497+
# @return [Hash{Symbol=>Object}]
498+
def encode_query_params(query)
499+
out = {}
500+
query.each { write_query_param_element!(out, _1, _2) }
501+
out
502+
end
503+
504+
# @api private
505+
#
506+
# @param collection [Hash{Symbol=>Object}]
507+
# @param key [String]
508+
# @param element [Object]
509+
#
510+
# @return [nil]
511+
private def write_query_param_element!(collection, key, element)
512+
case element
513+
in Hash
514+
element.each do |name, value|
515+
write_query_param_element!(collection, "#{key}[#{name}]", value)
516+
end
517+
in Array
518+
collection[key] = element.map(&:to_s).join(",")
519+
else
520+
collection[key] = element.to_s
521+
end
522+
end
523+
493524
# @api private
494525
#
495526
# @param y [Enumerator::Yielder]

lib/sentdm/models/brand_delete_params.rb

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,20 @@ class BrandDeleteParams < Sentdm::Internal::Type::BaseModel
77
extend Sentdm::Internal::Type::RequestParameters::Converter
88
include Sentdm::Internal::Type::RequestParameters
99

10+
# @!attribute brand_id
11+
#
12+
# @return [String]
13+
required :brand_id, String
14+
1015
# @!attribute body
1116
# Request to delete a brand
1217
#
1318
# @return [Sentdm::Models::BrandDeleteParams::Body]
1419
required :body, -> { Sentdm::BrandDeleteParams::Body }
1520

16-
# @!method initialize(body:, request_options: {})
21+
# @!method initialize(brand_id:, body:, request_options: {})
22+
# @param brand_id [String]
23+
#
1724
# @param body [Sentdm::Models::BrandDeleteParams::Body] Request to delete a brand
1825
#
1926
# @param request_options [Sentdm::RequestOptions, Hash{Symbol=>Object}]

0 commit comments

Comments
 (0)