Skip to content

Commit d83034d

Browse files
feat(api): api update
1 parent 93b319e commit d83034d

File tree

4 files changed

+101
-101
lines changed

4 files changed

+101
-101
lines changed

.stats.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 24
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/unlayer%2Funlayer-4d5fbaaec8cf4a1c283a9f901d09ebf13663fec824e68284f3aee09a861eb935.yml
3-
openapi_spec_hash: 080ea72a1cecdca3399da83c5a9bfdd9
4-
config_hash: 22a4c98e4582bc0dddb1b2ae42fbccd0
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/unlayer%2Funlayer-d746e93c3c920dca97596edec38c9ec25feef644db419156ae1b538bb54b6d72.yml
3+
openapi_spec_hash: 437dce81b84c463ef9cc84dafa2ca92a
4+
config_hash: 7495c5f2aebb250bf705cf2e6f4c1205

api.md

Lines changed: 32 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,3 @@
1-
# Pages
2-
3-
Types:
4-
5-
```python
6-
from unlayer.types import PageRenderCreateResponse
7-
```
8-
9-
Methods:
10-
11-
- <code title="post /pages/v1/render">client.pages.<a href="./src/unlayer/resources/pages.py">render_create</a>(\*\*<a href="src/unlayer/types/page_render_create_params.py">params</a>) -> <a href="./src/unlayer/types/page_render_create_response.py">PageRenderCreateResponse</a></code>
12-
13-
# Emails
14-
15-
Types:
16-
17-
```python
18-
from unlayer.types import (
19-
EmailRetrieveResponse,
20-
EmailRenderCreateResponse,
21-
EmailSendCreateResponse,
22-
EmailSendTemplateTemplateResponse,
23-
)
24-
```
25-
26-
Methods:
27-
28-
- <code title="get /emails/v1/emails/{id}">client.emails.<a href="./src/unlayer/resources/emails.py">retrieve</a>(id) -> <a href="./src/unlayer/types/email_retrieve_response.py">EmailRetrieveResponse</a></code>
29-
- <code title="post /emails/v1/render">client.emails.<a href="./src/unlayer/resources/emails.py">render_create</a>(\*\*<a href="src/unlayer/types/email_render_create_params.py">params</a>) -> <a href="./src/unlayer/types/email_render_create_response.py">EmailRenderCreateResponse</a></code>
30-
- <code title="post /emails/v1/send">client.emails.<a href="./src/unlayer/resources/emails.py">send_create</a>(\*\*<a href="src/unlayer/types/email_send_create_params.py">params</a>) -> <a href="./src/unlayer/types/email_send_create_response.py">EmailSendCreateResponse</a></code>
31-
- <code title="post /emails/v1/send/template">client.emails.<a href="./src/unlayer/resources/emails.py">send_template_template</a>(\*\*<a href="src/unlayer/types/email_send_template_template_params.py">params</a>) -> <a href="./src/unlayer/types/email_send_template_template_response.py">EmailSendTemplateTemplateResponse</a></code>
32-
331
# Project
342

353
Types:
@@ -71,6 +39,26 @@ Methods:
7139
- <code title="get /project/v1/templates/{id}">client.project.<a href="./src/unlayer/resources/project.py">templates_retrieve</a>(id) -> <a href="./src/unlayer/types/project_templates_retrieve_response.py">ProjectTemplatesRetrieveResponse</a></code>
7240
- <code title="put /project/v1/templates/{id}">client.project.<a href="./src/unlayer/resources/project.py">templates_update</a>(id, \*\*<a href="src/unlayer/types/project_templates_update_params.py">params</a>) -> <a href="./src/unlayer/types/project_templates_update_response.py">ProjectTemplatesUpdateResponse</a></code>
7341

42+
# Emails
43+
44+
Types:
45+
46+
```python
47+
from unlayer.types import (
48+
EmailRetrieveResponse,
49+
EmailRenderCreateResponse,
50+
EmailSendCreateResponse,
51+
EmailSendTemplateTemplateResponse,
52+
)
53+
```
54+
55+
Methods:
56+
57+
- <code title="get /emails/v1/emails/{id}">client.emails.<a href="./src/unlayer/resources/emails.py">retrieve</a>(id) -> <a href="./src/unlayer/types/email_retrieve_response.py">EmailRetrieveResponse</a></code>
58+
- <code title="post /emails/v1/render">client.emails.<a href="./src/unlayer/resources/emails.py">render_create</a>(\*\*<a href="src/unlayer/types/email_render_create_params.py">params</a>) -> <a href="./src/unlayer/types/email_render_create_response.py">EmailRenderCreateResponse</a></code>
59+
- <code title="post /emails/v1/send">client.emails.<a href="./src/unlayer/resources/emails.py">send_create</a>(\*\*<a href="src/unlayer/types/email_send_create_params.py">params</a>) -> <a href="./src/unlayer/types/email_send_create_response.py">EmailSendCreateResponse</a></code>
60+
- <code title="post /emails/v1/send/template">client.emails.<a href="./src/unlayer/resources/emails.py">send_template_template</a>(\*\*<a href="src/unlayer/types/email_send_template_template_params.py">params</a>) -> <a href="./src/unlayer/types/email_send_template_template_response.py">EmailSendTemplateTemplateResponse</a></code>
61+
7462
# Documents
7563

7664
Types:
@@ -88,3 +76,15 @@ Methods:
8876
- <code title="get /documents/v1/documents/{id}">client.documents.<a href="./src/unlayer/resources/documents.py">documents_retrieve</a>(id) -> <a href="./src/unlayer/types/document_documents_retrieve_response.py">DocumentDocumentsRetrieveResponse</a></code>
8977
- <code title="post /documents/v1/generate">client.documents.<a href="./src/unlayer/resources/documents.py">generate_create</a>(\*\*<a href="src/unlayer/types/document_generate_create_params.py">params</a>) -> <a href="./src/unlayer/types/document_generate_create_response.py">DocumentGenerateCreateResponse</a></code>
9078
- <code title="post /documents/v1/generate/template">client.documents.<a href="./src/unlayer/resources/documents.py">generate_template_template</a>(\*\*<a href="src/unlayer/types/document_generate_template_template_params.py">params</a>) -> <a href="./src/unlayer/types/document_generate_template_template_response.py">DocumentGenerateTemplateTemplateResponse</a></code>
79+
80+
# Pages
81+
82+
Types:
83+
84+
```python
85+
from unlayer.types import PageRenderCreateResponse
86+
```
87+
88+
Methods:
89+
90+
- <code title="post /pages/v1/render">client.pages.<a href="./src/unlayer/resources/pages.py">render_create</a>(\*\*<a href="src/unlayer/types/page_render_create_params.py">params</a>) -> <a href="./src/unlayer/types/page_render_create_response.py">PageRenderCreateResponse</a></code>

src/unlayer/_client.py

Lines changed: 54 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -136,29 +136,29 @@ def __init__(
136136
)
137137

138138
@cached_property
139-
def pages(self) -> PagesResource:
140-
from .resources.pages import PagesResource
139+
def project(self) -> ProjectResource:
140+
from .resources.project import ProjectResource
141141

142-
return PagesResource(self)
142+
return ProjectResource(self)
143143

144144
@cached_property
145145
def emails(self) -> EmailsResource:
146146
from .resources.emails import EmailsResource
147147

148148
return EmailsResource(self)
149149

150-
@cached_property
151-
def project(self) -> ProjectResource:
152-
from .resources.project import ProjectResource
153-
154-
return ProjectResource(self)
155-
156150
@cached_property
157151
def documents(self) -> DocumentsResource:
158152
from .resources.documents import DocumentsResource
159153

160154
return DocumentsResource(self)
161155

156+
@cached_property
157+
def pages(self) -> PagesResource:
158+
from .resources.pages import PagesResource
159+
160+
return PagesResource(self)
161+
162162
@cached_property
163163
def with_raw_response(self) -> UnlayerWithRawResponse:
164164
return UnlayerWithRawResponse(self)
@@ -354,29 +354,29 @@ def __init__(
354354
)
355355

356356
@cached_property
357-
def pages(self) -> AsyncPagesResource:
358-
from .resources.pages import AsyncPagesResource
357+
def project(self) -> AsyncProjectResource:
358+
from .resources.project import AsyncProjectResource
359359

360-
return AsyncPagesResource(self)
360+
return AsyncProjectResource(self)
361361

362362
@cached_property
363363
def emails(self) -> AsyncEmailsResource:
364364
from .resources.emails import AsyncEmailsResource
365365

366366
return AsyncEmailsResource(self)
367367

368-
@cached_property
369-
def project(self) -> AsyncProjectResource:
370-
from .resources.project import AsyncProjectResource
371-
372-
return AsyncProjectResource(self)
373-
374368
@cached_property
375369
def documents(self) -> AsyncDocumentsResource:
376370
from .resources.documents import AsyncDocumentsResource
377371

378372
return AsyncDocumentsResource(self)
379373

374+
@cached_property
375+
def pages(self) -> AsyncPagesResource:
376+
from .resources.pages import AsyncPagesResource
377+
378+
return AsyncPagesResource(self)
379+
380380
@cached_property
381381
def with_raw_response(self) -> AsyncUnlayerWithRawResponse:
382382
return AsyncUnlayerWithRawResponse(self)
@@ -499,29 +499,29 @@ def __init__(self, client: Unlayer) -> None:
499499
self._client = client
500500

501501
@cached_property
502-
def pages(self) -> pages.PagesResourceWithRawResponse:
503-
from .resources.pages import PagesResourceWithRawResponse
502+
def project(self) -> project.ProjectResourceWithRawResponse:
503+
from .resources.project import ProjectResourceWithRawResponse
504504

505-
return PagesResourceWithRawResponse(self._client.pages)
505+
return ProjectResourceWithRawResponse(self._client.project)
506506

507507
@cached_property
508508
def emails(self) -> emails.EmailsResourceWithRawResponse:
509509
from .resources.emails import EmailsResourceWithRawResponse
510510

511511
return EmailsResourceWithRawResponse(self._client.emails)
512512

513-
@cached_property
514-
def project(self) -> project.ProjectResourceWithRawResponse:
515-
from .resources.project import ProjectResourceWithRawResponse
516-
517-
return ProjectResourceWithRawResponse(self._client.project)
518-
519513
@cached_property
520514
def documents(self) -> documents.DocumentsResourceWithRawResponse:
521515
from .resources.documents import DocumentsResourceWithRawResponse
522516

523517
return DocumentsResourceWithRawResponse(self._client.documents)
524518

519+
@cached_property
520+
def pages(self) -> pages.PagesResourceWithRawResponse:
521+
from .resources.pages import PagesResourceWithRawResponse
522+
523+
return PagesResourceWithRawResponse(self._client.pages)
524+
525525

526526
class AsyncUnlayerWithRawResponse:
527527
_client: AsyncUnlayer
@@ -530,29 +530,29 @@ def __init__(self, client: AsyncUnlayer) -> None:
530530
self._client = client
531531

532532
@cached_property
533-
def pages(self) -> pages.AsyncPagesResourceWithRawResponse:
534-
from .resources.pages import AsyncPagesResourceWithRawResponse
533+
def project(self) -> project.AsyncProjectResourceWithRawResponse:
534+
from .resources.project import AsyncProjectResourceWithRawResponse
535535

536-
return AsyncPagesResourceWithRawResponse(self._client.pages)
536+
return AsyncProjectResourceWithRawResponse(self._client.project)
537537

538538
@cached_property
539539
def emails(self) -> emails.AsyncEmailsResourceWithRawResponse:
540540
from .resources.emails import AsyncEmailsResourceWithRawResponse
541541

542542
return AsyncEmailsResourceWithRawResponse(self._client.emails)
543543

544-
@cached_property
545-
def project(self) -> project.AsyncProjectResourceWithRawResponse:
546-
from .resources.project import AsyncProjectResourceWithRawResponse
547-
548-
return AsyncProjectResourceWithRawResponse(self._client.project)
549-
550544
@cached_property
551545
def documents(self) -> documents.AsyncDocumentsResourceWithRawResponse:
552546
from .resources.documents import AsyncDocumentsResourceWithRawResponse
553547

554548
return AsyncDocumentsResourceWithRawResponse(self._client.documents)
555549

550+
@cached_property
551+
def pages(self) -> pages.AsyncPagesResourceWithRawResponse:
552+
from .resources.pages import AsyncPagesResourceWithRawResponse
553+
554+
return AsyncPagesResourceWithRawResponse(self._client.pages)
555+
556556

557557
class UnlayerWithStreamedResponse:
558558
_client: Unlayer
@@ -561,29 +561,29 @@ def __init__(self, client: Unlayer) -> None:
561561
self._client = client
562562

563563
@cached_property
564-
def pages(self) -> pages.PagesResourceWithStreamingResponse:
565-
from .resources.pages import PagesResourceWithStreamingResponse
564+
def project(self) -> project.ProjectResourceWithStreamingResponse:
565+
from .resources.project import ProjectResourceWithStreamingResponse
566566

567-
return PagesResourceWithStreamingResponse(self._client.pages)
567+
return ProjectResourceWithStreamingResponse(self._client.project)
568568

569569
@cached_property
570570
def emails(self) -> emails.EmailsResourceWithStreamingResponse:
571571
from .resources.emails import EmailsResourceWithStreamingResponse
572572

573573
return EmailsResourceWithStreamingResponse(self._client.emails)
574574

575-
@cached_property
576-
def project(self) -> project.ProjectResourceWithStreamingResponse:
577-
from .resources.project import ProjectResourceWithStreamingResponse
578-
579-
return ProjectResourceWithStreamingResponse(self._client.project)
580-
581575
@cached_property
582576
def documents(self) -> documents.DocumentsResourceWithStreamingResponse:
583577
from .resources.documents import DocumentsResourceWithStreamingResponse
584578

585579
return DocumentsResourceWithStreamingResponse(self._client.documents)
586580

581+
@cached_property
582+
def pages(self) -> pages.PagesResourceWithStreamingResponse:
583+
from .resources.pages import PagesResourceWithStreamingResponse
584+
585+
return PagesResourceWithStreamingResponse(self._client.pages)
586+
587587

588588
class AsyncUnlayerWithStreamedResponse:
589589
_client: AsyncUnlayer
@@ -592,29 +592,29 @@ def __init__(self, client: AsyncUnlayer) -> None:
592592
self._client = client
593593

594594
@cached_property
595-
def pages(self) -> pages.AsyncPagesResourceWithStreamingResponse:
596-
from .resources.pages import AsyncPagesResourceWithStreamingResponse
595+
def project(self) -> project.AsyncProjectResourceWithStreamingResponse:
596+
from .resources.project import AsyncProjectResourceWithStreamingResponse
597597

598-
return AsyncPagesResourceWithStreamingResponse(self._client.pages)
598+
return AsyncProjectResourceWithStreamingResponse(self._client.project)
599599

600600
@cached_property
601601
def emails(self) -> emails.AsyncEmailsResourceWithStreamingResponse:
602602
from .resources.emails import AsyncEmailsResourceWithStreamingResponse
603603

604604
return AsyncEmailsResourceWithStreamingResponse(self._client.emails)
605605

606-
@cached_property
607-
def project(self) -> project.AsyncProjectResourceWithStreamingResponse:
608-
from .resources.project import AsyncProjectResourceWithStreamingResponse
609-
610-
return AsyncProjectResourceWithStreamingResponse(self._client.project)
611-
612606
@cached_property
613607
def documents(self) -> documents.AsyncDocumentsResourceWithStreamingResponse:
614608
from .resources.documents import AsyncDocumentsResourceWithStreamingResponse
615609

616610
return AsyncDocumentsResourceWithStreamingResponse(self._client.documents)
617611

612+
@cached_property
613+
def pages(self) -> pages.AsyncPagesResourceWithStreamingResponse:
614+
from .resources.pages import AsyncPagesResourceWithStreamingResponse
615+
616+
return AsyncPagesResourceWithStreamingResponse(self._client.pages)
617+
618618

619619
Client = Unlayer
620620

src/unlayer/resources/__init__.py

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -34,28 +34,28 @@
3434
)
3535

3636
__all__ = [
37-
"PagesResource",
38-
"AsyncPagesResource",
39-
"PagesResourceWithRawResponse",
40-
"AsyncPagesResourceWithRawResponse",
41-
"PagesResourceWithStreamingResponse",
42-
"AsyncPagesResourceWithStreamingResponse",
43-
"EmailsResource",
44-
"AsyncEmailsResource",
45-
"EmailsResourceWithRawResponse",
46-
"AsyncEmailsResourceWithRawResponse",
47-
"EmailsResourceWithStreamingResponse",
48-
"AsyncEmailsResourceWithStreamingResponse",
4937
"ProjectResource",
5038
"AsyncProjectResource",
5139
"ProjectResourceWithRawResponse",
5240
"AsyncProjectResourceWithRawResponse",
5341
"ProjectResourceWithStreamingResponse",
5442
"AsyncProjectResourceWithStreamingResponse",
43+
"EmailsResource",
44+
"AsyncEmailsResource",
45+
"EmailsResourceWithRawResponse",
46+
"AsyncEmailsResourceWithRawResponse",
47+
"EmailsResourceWithStreamingResponse",
48+
"AsyncEmailsResourceWithStreamingResponse",
5549
"DocumentsResource",
5650
"AsyncDocumentsResource",
5751
"DocumentsResourceWithRawResponse",
5852
"AsyncDocumentsResourceWithRawResponse",
5953
"DocumentsResourceWithStreamingResponse",
6054
"AsyncDocumentsResourceWithStreamingResponse",
55+
"PagesResource",
56+
"AsyncPagesResource",
57+
"PagesResourceWithRawResponse",
58+
"AsyncPagesResourceWithRawResponse",
59+
"PagesResourceWithStreamingResponse",
60+
"AsyncPagesResourceWithStreamingResponse",
6161
]

0 commit comments

Comments
 (0)