diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 234d0c4..a7a373a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -24,8 +24,7 @@ jobs: runs-on: ${{ github.repository == 'stainless-sdks/moderation-api-ruby' && 'depot-ubuntu-24.04' || 'ubuntu-latest' }} if: |- github.repository == 'stainless-sdks/moderation-api-ruby' && - (github.event_name == 'push' || github.event.pull_request.head.repo.fork) && - (github.event_name != 'push' || github.event.head_commit.message != 'codegen metadata') + (github.event_name == 'push' || github.event.pull_request.head.repo.fork) && (github.event_name != 'push' || github.event.head_commit.message != 'codegen metadata') steps: - uses: actions/checkout@v6 - name: Set up Ruby diff --git a/.release-please-manifest.json b/.release-please-manifest.json index d362570..e6c39ad 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "2.10.1" + ".": "2.11.0" } \ No newline at end of file diff --git a/.stats.yml b/.stats.yml index 3a6a221..f17b8ce 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 27 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/moderation-api%2Fmoderation-api-815dce43cbb14e41f094bdbca84682c0b379dcfd02b7e8800f9d8b45c00a76fd.yml -openapi_spec_hash: ab7d073e793fe5a556e64d39963aea93 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/moderation-api%2Fmoderation-api-a4934bf1e7f1348c021b48224f7a7110a6e41838253dda4fbcc720dd2d2ed6b7.yml +openapi_spec_hash: 537542216811907b1d4ebf23a54dc669 config_hash: 6b825a08e19dfb747c5dc1766502b789 diff --git a/CHANGELOG.md b/CHANGELOG.md index ccbb7da..0edb7af 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,18 @@ # Changelog +## 2.11.0 (2026-03-31) + +Full Changelog: [v2.10.1...v2.11.0](https://github.com/moderation-api/sdk-ruby/compare/v2.10.1...v2.11.0) + +### Features + +* **api:** api update ([7003628](https://github.com/moderation-api/sdk-ruby/commit/70036284e49ac86dd1de5f1e9b10f908c35571cc)) + + +### Chores + +* **ci:** support opting out of skipping builds on metadata-only commits ([8cbba6f](https://github.com/moderation-api/sdk-ruby/commit/8cbba6fe84670b175bb6283c543ecff4bad13006)) + ## 2.10.1 (2026-03-27) Full Changelog: [v2.10.0...v2.10.1](https://github.com/moderation-api/sdk-ruby/compare/v2.10.0...v2.10.1) diff --git a/Gemfile.lock b/Gemfile.lock index 460fe66..fae76af 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -11,7 +11,7 @@ GIT PATH remote: . specs: - moderation_api (2.10.1) + moderation_api (2.11.0) cgi connection_pool diff --git a/README.md b/README.md index 6982c00..256dc38 100644 --- a/README.md +++ b/README.md @@ -15,7 +15,7 @@ To use this gem, install via Bundler by adding the following to your application ```ruby -gem "moderation_api", "~> 2.10.1" +gem "moderation_api", "~> 2.11.0" ``` diff --git a/lib/moderation_api/models/content_submit_response.rb b/lib/moderation_api/models/content_submit_response.rb index 2fea42d..76cae70 100644 --- a/lib/moderation_api/models/content_submit_response.rb +++ b/lib/moderation_api/models/content_submit_response.rb @@ -201,7 +201,14 @@ class Content < ModerationAPI::Internal::Type::BaseModel union: -> { ModerationAPI::Models::ContentSubmitResponse::Content::Modified }, nil?: true - # @!method initialize(id:, masked:, modified:) + # @!attribute transcript + # The transcribed text from audio content. Only present when audio moderation is + # used and transcript inclusion is enabled on the channel. + # + # @return [String, nil] + optional :transcript, String, nil?: true + + # @!method initialize(id:, masked:, modified:, transcript: nil) # Some parameter documentations has been truncated, see # {ModerationAPI::Models::ContentSubmitResponse::Content} for more details. # @@ -212,6 +219,8 @@ class Content < ModerationAPI::Internal::Type::BaseModel # @param masked [Boolean] Whether any values have been masked. # # @param modified [String, Hash{Symbol=>Object}, Hash{Symbol=>ModerationAPI::Models::ContentSubmitResponse::Content::Modified::ModifiedNestedObjectContent::Text, ModerationAPI::Models::ContentSubmitResponse::Content::Modified::ModifiedNestedObjectContent::Image, ModerationAPI::Models::ContentSubmitResponse::Content::Modified::ModifiedNestedObjectContent::Video, ModerationAPI::Models::ContentSubmitResponse::Content::Modified::ModifiedNestedObjectContent::Audio}, nil] The modified content, if any. + # + # @param transcript [String, nil] The transcribed text from audio content. Only present when audio moderation is u # The modified content, if any. # diff --git a/lib/moderation_api/version.rb b/lib/moderation_api/version.rb index 19aff7f..0f2d00a 100644 --- a/lib/moderation_api/version.rb +++ b/lib/moderation_api/version.rb @@ -1,5 +1,5 @@ # frozen_string_literal: true module ModerationAPI - VERSION = "2.10.1" + VERSION = "2.11.0" end diff --git a/rbi/moderation_api/models/content_submit_response.rbi b/rbi/moderation_api/models/content_submit_response.rbi index 3407fee..94a4ac0 100644 --- a/rbi/moderation_api/models/content_submit_response.rbi +++ b/rbi/moderation_api/models/content_submit_response.rbi @@ -447,6 +447,11 @@ module ModerationAPI end attr_accessor :modified + # The transcribed text from audio content. Only present when audio moderation is + # used and transcript inclusion is enabled on the channel. + sig { returns(T.nilable(String)) } + attr_accessor :transcript + # Potentially modified content. sig do params( @@ -455,7 +460,8 @@ module ModerationAPI modified: T.nilable( ModerationAPI::Models::ContentSubmitResponse::Content::Modified::Variants - ) + ), + transcript: T.nilable(String) ).returns(T.attached_class) end def self.new( @@ -465,7 +471,10 @@ module ModerationAPI # Whether any values have been masked. masked:, # The modified content, if any. - modified: + modified:, + # The transcribed text from audio content. Only present when audio moderation is + # used and transcript inclusion is enabled on the channel. + transcript: nil ) end @@ -477,7 +486,8 @@ module ModerationAPI modified: T.nilable( ModerationAPI::Models::ContentSubmitResponse::Content::Modified::Variants - ) + ), + transcript: T.nilable(String) } ) end diff --git a/sig/moderation_api/models/content_submit_response.rbs b/sig/moderation_api/models/content_submit_response.rbs index 6f20819..d0ff6ec 100644 --- a/sig/moderation_api/models/content_submit_response.rbs +++ b/sig/moderation_api/models/content_submit_response.rbs @@ -132,7 +132,8 @@ module ModerationAPI { id: String, masked: bool, - modified: ModerationAPI::Models::ContentSubmitResponse::Content::modified? + modified: ModerationAPI::Models::ContentSubmitResponse::Content::modified?, + transcript: String? } class Content < ModerationAPI::Internal::Type::BaseModel @@ -142,16 +143,20 @@ module ModerationAPI attr_accessor modified: ModerationAPI::Models::ContentSubmitResponse::Content::modified? + attr_accessor transcript: String? + def initialize: ( id: String, masked: bool, - modified: ModerationAPI::Models::ContentSubmitResponse::Content::modified? + modified: ModerationAPI::Models::ContentSubmitResponse::Content::modified?, + ?transcript: String? ) -> void def to_hash: -> { id: String, masked: bool, - modified: ModerationAPI::Models::ContentSubmitResponse::Content::modified? + modified: ModerationAPI::Models::ContentSubmitResponse::Content::modified?, + transcript: String? } type modified =