Skip to content

Commit 3285d21

Browse files
feat(api): manual updates
1 parent c4538b4 commit 3285d21

17 files changed

Lines changed: 917 additions & 744 deletions

‎.stats.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 20
22
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/context-dev%2Fcontext.dev-c2e94e0c758b1aaba120c2a4231842fff0a120acc471fe24c7a81221e13a0482.yml
33
openapi_spec_hash: aabc231b46b1ca3375882f96c378c665
4-
config_hash: a144af00e5e74176674d0ea954cc02c5
4+
config_hash: c6eb5818596f9926ef1225a0c7a855db

‎api.md‎

Lines changed: 20 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,23 @@
1+
# Web
2+
3+
Types:
4+
5+
```python
6+
from context.dev.types import (
7+
WebWebScrapeHTMLResponse,
8+
WebWebScrapeImagesResponse,
9+
WebWebScrapeMdResponse,
10+
WebWebScrapeSitemapResponse,
11+
)
12+
```
13+
14+
Methods:
15+
16+
- <code title="get /web/scrape/html">client.web.<a href="./src/context/dev/resources/web.py">web_scrape_html</a>(\*\*<a href="src/context/dev/types/web_web_scrape_html_params.py">params</a>) -> <a href="./src/context/dev/types/web_web_scrape_html_response.py">WebWebScrapeHTMLResponse</a></code>
17+
- <code title="get /web/scrape/images">client.web.<a href="./src/context/dev/resources/web.py">web_scrape_images</a>(\*\*<a href="src/context/dev/types/web_web_scrape_images_params.py">params</a>) -> <a href="./src/context/dev/types/web_web_scrape_images_response.py">WebWebScrapeImagesResponse</a></code>
18+
- <code title="get /web/scrape/markdown">client.web.<a href="./src/context/dev/resources/web.py">web_scrape_md</a>(\*\*<a href="src/context/dev/types/web_web_scrape_md_params.py">params</a>) -> <a href="./src/context/dev/types/web_web_scrape_md_response.py">WebWebScrapeMdResponse</a></code>
19+
- <code title="get /web/scrape/sitemap">client.web.<a href="./src/context/dev/resources/web.py">web_scrape_sitemap</a>(\*\*<a href="src/context/dev/types/web_web_scrape_sitemap_params.py">params</a>) -> <a href="./src/context/dev/types/web_web_scrape_sitemap_response.py">WebWebScrapeSitemapResponse</a></code>
20+
121
# Brand
222

323
Types:
@@ -20,10 +40,6 @@ from context.dev.types import (
2040
BrandRetrieveSimplifiedResponse,
2141
BrandScreenshotResponse,
2242
BrandStyleguideResponse,
23-
BrandWebScrapeHTMLResponse,
24-
BrandWebScrapeImagesResponse,
25-
BrandWebScrapeMdResponse,
26-
BrandWebScrapeSitemapResponse,
2743
)
2844
```
2945

@@ -45,7 +61,3 @@ Methods:
4561
- <code title="get /brand/retrieve-simplified">client.brand.<a href="./src/context/dev/resources/brand.py">retrieve_simplified</a>(\*\*<a href="src/context/dev/types/brand_retrieve_simplified_params.py">params</a>) -> <a href="./src/context/dev/types/brand_retrieve_simplified_response.py">BrandRetrieveSimplifiedResponse</a></code>
4662
- <code title="get /brand/screenshot">client.brand.<a href="./src/context/dev/resources/brand.py">screenshot</a>(\*\*<a href="src/context/dev/types/brand_screenshot_params.py">params</a>) -> <a href="./src/context/dev/types/brand_screenshot_response.py">BrandScreenshotResponse</a></code>
4763
- <code title="get /brand/styleguide">client.brand.<a href="./src/context/dev/resources/brand.py">styleguide</a>(\*\*<a href="src/context/dev/types/brand_styleguide_params.py">params</a>) -> <a href="./src/context/dev/types/brand_styleguide_response.py">BrandStyleguideResponse</a></code>
48-
- <code title="get /web/scrape/html">client.brand.<a href="./src/context/dev/resources/brand.py">web_scrape_html</a>(\*\*<a href="src/context/dev/types/brand_web_scrape_html_params.py">params</a>) -> <a href="./src/context/dev/types/brand_web_scrape_html_response.py">BrandWebScrapeHTMLResponse</a></code>
49-
- <code title="get /web/scrape/images">client.brand.<a href="./src/context/dev/resources/brand.py">web_scrape_images</a>(\*\*<a href="src/context/dev/types/brand_web_scrape_images_params.py">params</a>) -> <a href="./src/context/dev/types/brand_web_scrape_images_response.py">BrandWebScrapeImagesResponse</a></code>
50-
- <code title="get /web/scrape/markdown">client.brand.<a href="./src/context/dev/resources/brand.py">web_scrape_md</a>(\*\*<a href="src/context/dev/types/brand_web_scrape_md_params.py">params</a>) -> <a href="./src/context/dev/types/brand_web_scrape_md_response.py">BrandWebScrapeMdResponse</a></code>
51-
- <code title="get /web/scrape/sitemap">client.brand.<a href="./src/context/dev/resources/brand.py">web_scrape_sitemap</a>(\*\*<a href="src/context/dev/types/brand_web_scrape_sitemap_params.py">params</a>) -> <a href="./src/context/dev/types/brand_web_scrape_sitemap_response.py">BrandWebScrapeSitemapResponse</a></code>

‎src/context/dev/_client.py‎

Lines changed: 38 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,8 @@
3131
)
3232

3333
if TYPE_CHECKING:
34-
from .resources import brand
34+
from .resources import web, brand
35+
from .resources.web import WebResource, AsyncWebResource
3536
from .resources.brand import BrandResource, AsyncBrandResource
3637

3738
__all__ = [
@@ -101,6 +102,12 @@ def __init__(
101102
_strict_response_validation=_strict_response_validation,
102103
)
103104

105+
@cached_property
106+
def web(self) -> WebResource:
107+
from .resources.web import WebResource
108+
109+
return WebResource(self)
110+
104111
@cached_property
105112
def brand(self) -> BrandResource:
106113
from .resources.brand import BrandResource
@@ -275,6 +282,12 @@ def __init__(
275282
_strict_response_validation=_strict_response_validation,
276283
)
277284

285+
@cached_property
286+
def web(self) -> AsyncWebResource:
287+
from .resources.web import AsyncWebResource
288+
289+
return AsyncWebResource(self)
290+
278291
@cached_property
279292
def brand(self) -> AsyncBrandResource:
280293
from .resources.brand import AsyncBrandResource
@@ -400,6 +413,12 @@ class ContextDevWithRawResponse:
400413
def __init__(self, client: ContextDev) -> None:
401414
self._client = client
402415

416+
@cached_property
417+
def web(self) -> web.WebResourceWithRawResponse:
418+
from .resources.web import WebResourceWithRawResponse
419+
420+
return WebResourceWithRawResponse(self._client.web)
421+
403422
@cached_property
404423
def brand(self) -> brand.BrandResourceWithRawResponse:
405424
from .resources.brand import BrandResourceWithRawResponse
@@ -413,6 +432,12 @@ class AsyncContextDevWithRawResponse:
413432
def __init__(self, client: AsyncContextDev) -> None:
414433
self._client = client
415434

435+
@cached_property
436+
def web(self) -> web.AsyncWebResourceWithRawResponse:
437+
from .resources.web import AsyncWebResourceWithRawResponse
438+
439+
return AsyncWebResourceWithRawResponse(self._client.web)
440+
416441
@cached_property
417442
def brand(self) -> brand.AsyncBrandResourceWithRawResponse:
418443
from .resources.brand import AsyncBrandResourceWithRawResponse
@@ -426,6 +451,12 @@ class ContextDevWithStreamedResponse:
426451
def __init__(self, client: ContextDev) -> None:
427452
self._client = client
428453

454+
@cached_property
455+
def web(self) -> web.WebResourceWithStreamingResponse:
456+
from .resources.web import WebResourceWithStreamingResponse
457+
458+
return WebResourceWithStreamingResponse(self._client.web)
459+
429460
@cached_property
430461
def brand(self) -> brand.BrandResourceWithStreamingResponse:
431462
from .resources.brand import BrandResourceWithStreamingResponse
@@ -439,6 +470,12 @@ class AsyncContextDevWithStreamedResponse:
439470
def __init__(self, client: AsyncContextDev) -> None:
440471
self._client = client
441472

473+
@cached_property
474+
def web(self) -> web.AsyncWebResourceWithStreamingResponse:
475+
from .resources.web import AsyncWebResourceWithStreamingResponse
476+
477+
return AsyncWebResourceWithStreamingResponse(self._client.web)
478+
442479
@cached_property
443480
def brand(self) -> brand.AsyncBrandResourceWithStreamingResponse:
444481
from .resources.brand import AsyncBrandResourceWithStreamingResponse

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

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,13 @@
11
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
22

3+
from .web import (
4+
WebResource,
5+
AsyncWebResource,
6+
WebResourceWithRawResponse,
7+
AsyncWebResourceWithRawResponse,
8+
WebResourceWithStreamingResponse,
9+
AsyncWebResourceWithStreamingResponse,
10+
)
311
from .brand import (
412
BrandResource,
513
AsyncBrandResource,
@@ -10,6 +18,12 @@
1018
)
1119

1220
__all__ = [
21+
"WebResource",
22+
"AsyncWebResource",
23+
"WebResourceWithRawResponse",
24+
"AsyncWebResourceWithRawResponse",
25+
"WebResourceWithStreamingResponse",
26+
"AsyncWebResourceWithStreamingResponse",
1327
"BrandResource",
1428
"AsyncBrandResource",
1529
"BrandResourceWithRawResponse",

0 commit comments

Comments
 (0)