Skip to content

Commit 7cbead0

Browse files
authored
Merge pull request #44 from context-dot-dev/release-please--branches--main--changes--next
release: 1.2.0
2 parents 316b980 + f4d6324 commit 7cbead0

8 files changed

Lines changed: 44 additions & 6 deletions

File tree

‎.release-please-manifest.json‎

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

‎.stats.yml‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 25
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/context-dev/context.dev-3024c2681b0acf12535d68f39c1b49113330548513a54b276116cd3f2eda182e.yml
3-
openapi_spec_hash: ab3a6473e575381cacd245bf54dcf0f7
4-
config_hash: b0f343b2ab3baebad7b0d6d51f0f16fc
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/context-dev/context.dev-4903d5902cec6a80f42b9adaa9cf0defa9805ff22d7ae96970d209a4f867e195.yml
3+
openapi_spec_hash: 1097891c23530dfe0155f23170daf973
4+
config_hash: c7b0cdaba3b9797b77efd89e1754d803

‎CHANGELOG.md‎

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

3+
## 1.2.0 (2026-06-25)
4+
5+
Full Changelog: [v1.1.0...v1.2.0](https://github.com/context-dot-dev/context-python-sdk/compare/v1.1.0...v1.2.0)
6+
7+
### Features
8+
9+
* **api:** api update ([5c97d99](https://github.com/context-dot-dev/context-python-sdk/commit/5c97d9910c3ea61b4440d3d3dde189b62f4de2b6))
10+
311
## 1.1.0 (2026-06-21)
412

513
Full Changelog: [v1.0.0...v1.1.0](https://github.com/context-dot-dev/context-python-sdk/compare/v1.0.0...v1.1.0)

‎pyproject.toml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "context.dev"
3-
version = "1.1.0"
3+
version = "1.2.0"
44
description = "The official Python library for the context.dev API"
55
dynamic = ["readme"]
66
license = "Apache-2.0"

‎src/context/dev/_version.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
22

33
__title__ = "context.dev"
4-
__version__ = "1.1.0" # x-release-please-version
4+
__version__ = "1.2.0" # x-release-please-version

‎src/context/dev/resources/web.py‎

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -359,6 +359,7 @@ def screenshot(
359359
handle_cookie_popup: Literal["true", "false"] | Omit = omit,
360360
max_age_ms: int | Omit = omit,
361361
page: Literal["login", "signup", "blog", "careers", "pricing", "terms", "privacy", "contact"] | Omit = omit,
362+
scroll_offset: int | Omit = omit,
362363
timeout_ms: int | Omit = omit,
363364
viewport: web_screenshot_params.Viewport | Omit = omit,
364365
wait_for_ms: int | Omit = omit,
@@ -399,6 +400,13 @@ def screenshot(
399400
provided, screenshots the main domain landing page. Only applicable when using
400401
'domain', not 'directUrl'.
401402
403+
scroll_offset: Optional vertical scroll offset in pixels for capturing a long page in
404+
viewport-sized chunks. When provided, the full page is captured once and the
405+
returned image is the viewport-sized slice that begins at this Y offset (e.g.
406+
request scrollOffset=0, then 1080, then 2160 to walk a 1920x1080 landing page
407+
top to bottom). The final slice may be shorter than the viewport height. Takes
408+
precedence over fullScreenshot. Max: 100000.
409+
402410
timeout_ms: Optional timeout in milliseconds for the request. If the request takes longer
403411
than this value, it will be aborted with a 408 status code. Maximum allowed
404412
value is 300000ms (5 minutes).
@@ -432,6 +440,7 @@ def screenshot(
432440
"handle_cookie_popup": handle_cookie_popup,
433441
"max_age_ms": max_age_ms,
434442
"page": page,
443+
"scroll_offset": scroll_offset,
435444
"timeout_ms": timeout_ms,
436445
"viewport": viewport,
437446
"wait_for_ms": wait_for_ms,
@@ -1277,6 +1286,7 @@ async def screenshot(
12771286
handle_cookie_popup: Literal["true", "false"] | Omit = omit,
12781287
max_age_ms: int | Omit = omit,
12791288
page: Literal["login", "signup", "blog", "careers", "pricing", "terms", "privacy", "contact"] | Omit = omit,
1289+
scroll_offset: int | Omit = omit,
12801290
timeout_ms: int | Omit = omit,
12811291
viewport: web_screenshot_params.Viewport | Omit = omit,
12821292
wait_for_ms: int | Omit = omit,
@@ -1317,6 +1327,13 @@ async def screenshot(
13171327
provided, screenshots the main domain landing page. Only applicable when using
13181328
'domain', not 'directUrl'.
13191329
1330+
scroll_offset: Optional vertical scroll offset in pixels for capturing a long page in
1331+
viewport-sized chunks. When provided, the full page is captured once and the
1332+
returned image is the viewport-sized slice that begins at this Y offset (e.g.
1333+
request scrollOffset=0, then 1080, then 2160 to walk a 1920x1080 landing page
1334+
top to bottom). The final slice may be shorter than the viewport height. Takes
1335+
precedence over fullScreenshot. Max: 100000.
1336+
13201337
timeout_ms: Optional timeout in milliseconds for the request. If the request takes longer
13211338
than this value, it will be aborted with a 408 status code. Maximum allowed
13221339
value is 300000ms (5 minutes).
@@ -1350,6 +1367,7 @@ async def screenshot(
13501367
"handle_cookie_popup": handle_cookie_popup,
13511368
"max_age_ms": max_age_ms,
13521369
"page": page,
1370+
"scroll_offset": scroll_offset,
13531371
"timeout_ms": timeout_ms,
13541372
"viewport": viewport,
13551373
"wait_for_ms": wait_for_ms,

‎src/context/dev/types/web_screenshot_params.py‎

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,16 @@ class WebScreenshotParams(TypedDict, total=False):
5454
applicable when using 'domain', not 'directUrl'.
5555
"""
5656

57+
scroll_offset: Annotated[int, PropertyInfo(alias="scrollOffset")]
58+
"""
59+
Optional vertical scroll offset in pixels for capturing a long page in
60+
viewport-sized chunks. When provided, the full page is captured once and the
61+
returned image is the viewport-sized slice that begins at this Y offset (e.g.
62+
request scrollOffset=0, then 1080, then 2160 to walk a 1920x1080 landing page
63+
top to bottom). The final slice may be shorter than the viewport height. Takes
64+
precedence over fullScreenshot. Max: 100000.
65+
"""
66+
5767
timeout_ms: Annotated[int, PropertyInfo(alias="timeoutMS")]
5868
"""Optional timeout in milliseconds for the request.
5969

‎tests/api_resources/test_web.py‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -248,6 +248,7 @@ def test_method_screenshot_with_all_params(self, client: ContextDev) -> None:
248248
handle_cookie_popup="true",
249249
max_age_ms=0,
250250
page="login",
251+
scroll_offset=0,
251252
timeout_ms=1000,
252253
viewport={
253254
"height": 240,
@@ -840,6 +841,7 @@ async def test_method_screenshot_with_all_params(self, async_client: AsyncContex
840841
handle_cookie_popup="true",
841842
max_age_ms=0,
842843
page="login",
844+
scroll_offset=0,
843845
timeout_ms=1000,
844846
viewport={
845847
"height": 240,

0 commit comments

Comments
 (0)