From 2b9872e68a6dd741dca45c66e5f6bcb75b701183 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Sat, 6 Jun 2026 15:15:50 +0000 Subject: [PATCH 1/3] codegen metadata --- .stats.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.stats.yml b/.stats.yml index 132441d8..b60e5a5f 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 25 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/context-dev/context.dev-9575a58bf027da9ca006bf34d9e24850ef2bbc6de0459b9fff6f26cf62e1d82d.yml -openapi_spec_hash: e68a98dbc0e29b45c42b3517eb554e6c +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/context-dev/context.dev-77c81f079d31117b328f8535234bcde15298c29437b89916a1414a32e34fc16e.yml +openapi_spec_hash: eeaa6f1cfcc0b604cc1dec505c5dc15d config_hash: f86a4e06ae5ed725aa79d58d7a8dc27c From 9aa6127b563032655648c3c24fe9564616ebe3f1 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Sun, 7 Jun 2026 15:13:01 +0000 Subject: [PATCH 2/3] feat(api): api update --- .stats.yml | 4 +- .../models/web_web_scrape_html_response.rb | 40 ++++++++- .../models/web_web_scrape_html_response.rbi | 86 ++++++++++++++++++- .../models/web_web_scrape_html_response.rbs | 22 +++++ test/context_dev/resources/web_test.rb | 1 + 5 files changed, 146 insertions(+), 7 deletions(-) diff --git a/.stats.yml b/.stats.yml index b60e5a5f..27382d2f 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 25 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/context-dev/context.dev-77c81f079d31117b328f8535234bcde15298c29437b89916a1414a32e34fc16e.yml -openapi_spec_hash: eeaa6f1cfcc0b604cc1dec505c5dc15d +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/context-dev/context.dev-de0ba2ed18ec7265b0b20d9639b3da207dd33e354f0a856091902291c6661830.yml +openapi_spec_hash: ae25efc2ac6bcab54bc3f4efaab73a55 config_hash: f86a4e06ae5ed725aa79d58d7a8dc27c diff --git a/lib/context_dev/models/web_web_scrape_html_response.rb b/lib/context_dev/models/web_web_scrape_html_response.rb index 457d41b4..44bf79e8 100644 --- a/lib/context_dev/models/web_web_scrape_html_response.rb +++ b/lib/context_dev/models/web_web_scrape_html_response.rb @@ -5,7 +5,9 @@ module Models # @see ContextDev::Resources::Web#web_scrape_html class WebWebScrapeHTMLResponse < ContextDev::Internal::Type::BaseModel # @!attribute html - # Raw HTML content of the page + # The scraped content of the page. For normal pages this is the raw HTML. When the + # page is a sitemap or feed served behind an XSL stylesheet (which browsers render + # into HTML), this is the underlying XML instead — see the `type` field. # # @return [String] required :html, String @@ -16,17 +18,29 @@ class WebWebScrapeHTMLResponse < ContextDev::Internal::Type::BaseModel # @return [Boolean, ContextDev::Models::WebWebScrapeHTMLResponse::Success] required :success, enum: -> { ContextDev::Models::WebWebScrapeHTMLResponse::Success } + # @!attribute type + # Detected content type of the returned `html` field. Sitemaps and feeds are + # surfaced as `xml`; ordinary pages are `html`. + # + # @return [Symbol, ContextDev::Models::WebWebScrapeHTMLResponse::Type] + required :type, enum: -> { ContextDev::Models::WebWebScrapeHTMLResponse::Type } + # @!attribute url # The URL that was scraped # # @return [String] required :url, String - # @!method initialize(html:, success:, url:) - # @param html [String] Raw HTML content of the page + # @!method initialize(html:, success:, type:, url:) + # Some parameter documentations has been truncated, see + # {ContextDev::Models::WebWebScrapeHTMLResponse} for more details. + # + # @param html [String] The scraped content of the page. For normal pages this is the raw HTML. When the # # @param success [Boolean, ContextDev::Models::WebWebScrapeHTMLResponse::Success] Indicates success # + # @param type [Symbol, ContextDev::Models::WebWebScrapeHTMLResponse::Type] Detected content type of the returned `html` field. Sitemaps and feeds are surfa + # # @param url [String] The URL that was scraped # Indicates success @@ -40,6 +54,26 @@ module Success # @!method self.values # @return [Array] end + + # Detected content type of the returned `html` field. Sitemaps and feeds are + # surfaced as `xml`; ordinary pages are `html`. + # + # @see ContextDev::Models::WebWebScrapeHTMLResponse#type + module Type + extend ContextDev::Internal::Type::Enum + + HTML = :html + XML = :xml + JSON = :json + TEXT = :text + CSV = :csv + MARKDOWN = :markdown + SVG = :svg + PDF = :pdf + + # @!method self.values + # @return [Array] + end end end end diff --git a/rbi/context_dev/models/web_web_scrape_html_response.rbi b/rbi/context_dev/models/web_web_scrape_html_response.rbi index 52f3eb90..a7e04010 100644 --- a/rbi/context_dev/models/web_web_scrape_html_response.rbi +++ b/rbi/context_dev/models/web_web_scrape_html_response.rbi @@ -11,7 +11,9 @@ module ContextDev ) end - # Raw HTML content of the page + # The scraped content of the page. For normal pages this is the raw HTML. When the + # page is a sitemap or feed served behind an XSL stylesheet (which browsers render + # into HTML), this is the underlying XML instead — see the `type` field. sig { returns(String) } attr_accessor :html @@ -23,6 +25,15 @@ module ContextDev end attr_accessor :success + # Detected content type of the returned `html` field. Sitemaps and feeds are + # surfaced as `xml`; ordinary pages are `html`. + sig do + returns( + ContextDev::Models::WebWebScrapeHTMLResponse::Type::TaggedSymbol + ) + end + attr_accessor :type + # The URL that was scraped sig { returns(String) } attr_accessor :url @@ -32,14 +43,20 @@ module ContextDev html: String, success: ContextDev::Models::WebWebScrapeHTMLResponse::Success::OrBoolean, + type: ContextDev::Models::WebWebScrapeHTMLResponse::Type::OrSymbol, url: String ).returns(T.attached_class) end def self.new( - # Raw HTML content of the page + # The scraped content of the page. For normal pages this is the raw HTML. When the + # page is a sitemap or feed served behind an XSL stylesheet (which browsers render + # into HTML), this is the underlying XML instead — see the `type` field. html:, # Indicates success success:, + # Detected content type of the returned `html` field. Sitemaps and feeds are + # surfaced as `xml`; ordinary pages are `html`. + type:, # The URL that was scraped url: ) @@ -51,6 +68,8 @@ module ContextDev html: String, success: ContextDev::Models::WebWebScrapeHTMLResponse::Success::TaggedBoolean, + type: + ContextDev::Models::WebWebScrapeHTMLResponse::Type::TaggedSymbol, url: String } ) @@ -87,6 +106,69 @@ module ContextDev def self.values end end + + # Detected content type of the returned `html` field. Sitemaps and feeds are + # surfaced as `xml`; ordinary pages are `html`. + module Type + extend ContextDev::Internal::Type::Enum + + TaggedSymbol = + T.type_alias do + T.all(Symbol, ContextDev::Models::WebWebScrapeHTMLResponse::Type) + end + OrSymbol = T.type_alias { T.any(Symbol, String) } + + HTML = + T.let( + :html, + ContextDev::Models::WebWebScrapeHTMLResponse::Type::TaggedSymbol + ) + XML = + T.let( + :xml, + ContextDev::Models::WebWebScrapeHTMLResponse::Type::TaggedSymbol + ) + JSON = + T.let( + :json, + ContextDev::Models::WebWebScrapeHTMLResponse::Type::TaggedSymbol + ) + TEXT = + T.let( + :text, + ContextDev::Models::WebWebScrapeHTMLResponse::Type::TaggedSymbol + ) + CSV = + T.let( + :csv, + ContextDev::Models::WebWebScrapeHTMLResponse::Type::TaggedSymbol + ) + MARKDOWN = + T.let( + :markdown, + ContextDev::Models::WebWebScrapeHTMLResponse::Type::TaggedSymbol + ) + SVG = + T.let( + :svg, + ContextDev::Models::WebWebScrapeHTMLResponse::Type::TaggedSymbol + ) + PDF = + T.let( + :pdf, + ContextDev::Models::WebWebScrapeHTMLResponse::Type::TaggedSymbol + ) + + sig do + override.returns( + T::Array[ + ContextDev::Models::WebWebScrapeHTMLResponse::Type::TaggedSymbol + ] + ) + end + def self.values + end + end end end end diff --git a/sig/context_dev/models/web_web_scrape_html_response.rbs b/sig/context_dev/models/web_web_scrape_html_response.rbs index ad04dfcb..25c1d8b4 100644 --- a/sig/context_dev/models/web_web_scrape_html_response.rbs +++ b/sig/context_dev/models/web_web_scrape_html_response.rbs @@ -4,6 +4,7 @@ module ContextDev { html: String, success: ContextDev::Models::WebWebScrapeHTMLResponse::success, + type: ContextDev::Models::WebWebScrapeHTMLResponse::type_, url: String } @@ -12,17 +13,21 @@ module ContextDev attr_accessor success: ContextDev::Models::WebWebScrapeHTMLResponse::success + attr_accessor type: ContextDev::Models::WebWebScrapeHTMLResponse::type_ + attr_accessor url: String def initialize: ( html: String, success: ContextDev::Models::WebWebScrapeHTMLResponse::success, + type: ContextDev::Models::WebWebScrapeHTMLResponse::type_, url: String ) -> void def to_hash: -> { html: String, success: ContextDev::Models::WebWebScrapeHTMLResponse::success, + type: ContextDev::Models::WebWebScrapeHTMLResponse::type_, url: String } @@ -35,6 +40,23 @@ module ContextDev def self?.values: -> ::Array[ContextDev::Models::WebWebScrapeHTMLResponse::success] end + + type type_ = :html | :xml | :json | :text | :csv | :markdown | :svg | :pdf + + module Type + extend ContextDev::Internal::Type::Enum + + HTML: :html + XML: :xml + JSON: :json + TEXT: :text + CSV: :csv + MARKDOWN: :markdown + SVG: :svg + PDF: :pdf + + def self?.values: -> ::Array[ContextDev::Models::WebWebScrapeHTMLResponse::type_] + end end end end diff --git a/test/context_dev/resources/web_test.rb b/test/context_dev/resources/web_test.rb index 6b131d34..947dbbd8 100644 --- a/test/context_dev/resources/web_test.rb +++ b/test/context_dev/resources/web_test.rb @@ -154,6 +154,7 @@ def test_web_scrape_html_required_params response => { html: String, success: ContextDev::Models::WebWebScrapeHTMLResponse::Success, + type: ContextDev::Models::WebWebScrapeHTMLResponse::Type, url: String } end From 7ed1d56a9f3019b6a07fcaa138a55ef7dfc69826 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Sun, 7 Jun 2026 15:13:24 +0000 Subject: [PATCH 3/3] release: 1.29.0 --- .release-please-manifest.json | 2 +- CHANGELOG.md | 8 ++++++++ Gemfile.lock | 2 +- README.md | 2 +- lib/context_dev/version.rb | 2 +- 5 files changed, 12 insertions(+), 4 deletions(-) diff --git a/.release-please-manifest.json b/.release-please-manifest.json index 31d82388..b8af36c3 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "1.28.0" + ".": "1.29.0" } \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index 043319ee..8c6a8a7f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,13 @@ # Changelog +## 1.29.0 (2026-06-07) + +Full Changelog: [v1.28.0...v1.29.0](https://github.com/context-dot-dev/context-ruby-sdk/compare/v1.28.0...v1.29.0) + +### Features + +* **api:** api update ([9aa6127](https://github.com/context-dot-dev/context-ruby-sdk/commit/9aa6127b563032655648c3c24fe9564616ebe3f1)) + ## 1.28.0 (2026-06-06) Full Changelog: [v1.27.0...v1.28.0](https://github.com/context-dot-dev/context-ruby-sdk/compare/v1.27.0...v1.28.0) diff --git a/Gemfile.lock b/Gemfile.lock index 9092793a..c35ce637 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -11,7 +11,7 @@ GIT PATH remote: . specs: - context.dev (1.28.0) + context.dev (1.29.0) cgi connection_pool diff --git a/README.md b/README.md index 1a184299..67ce9e28 100644 --- a/README.md +++ b/README.md @@ -26,7 +26,7 @@ To use this gem, install via Bundler by adding the following to your application ```ruby -gem "context.dev", "~> 1.28.0" +gem "context.dev", "~> 1.29.0" ``` diff --git a/lib/context_dev/version.rb b/lib/context_dev/version.rb index 2f843633..aa151347 100644 --- a/lib/context_dev/version.rb +++ b/lib/context_dev/version.rb @@ -1,5 +1,5 @@ # frozen_string_literal: true module ContextDev - VERSION = "1.28.0" + VERSION = "1.29.0" end