diff --git a/README.md b/README.md
index fada801..8049751 100644
--- a/README.md
+++ b/README.md
@@ -17,7 +17,7 @@ pip install monite
## Reference
-A full reference for this library is available [here](./reference.md).
+A full reference for this library is available [here](https://github.com/team-monite/monite-python-client/blob/HEAD/./reference.md).
## Usage
@@ -25,8 +25,15 @@ Instantiate and use the client with the following:
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.products.create(name='name', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.products.create(
+ name="name",
+)
```
## Async Client
@@ -34,12 +41,25 @@ client.products.create(name='name', )
The SDK also exports an `async` client so that you can make non-blocking calls to our API.
```python
-from monite import AsyncMonite
import asyncio
-client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+from monite import AsyncMonite
+
+client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+
+
async def main() -> None:
- await client.products.create(name='name', )
-asyncio.run(main())```
+ await client.products.create(
+ name="name",
+ )
+
+
+asyncio.run(main())
+```
## Exception Handling
@@ -48,6 +68,7 @@ will be thrown.
```python
from monite.core.api_error import ApiError
+
try:
client.products.create(...)
except ApiError as e:
@@ -64,7 +85,10 @@ The `.with_raw_response` property returns a "raw" client that can be used to acc
```python
from monite import Monite
-client = Monite(..., )
+
+client = Monite(
+ ...,
+)
response = client.products.with_raw_response.create(...)
print(response.headers) # access the response headers
print(response.data) # access the underlying object
@@ -97,7 +121,12 @@ The SDK defaults to a 60 second timeout. You can configure this with a timeout o
```python
from monite import Monite
-client = Monite(..., timeout=20.0, )
+
+client = Monite(
+ ...,
+ timeout=20.0,
+)
+
# Override timeout for a specific method
client.products.create(..., request_options={
@@ -111,9 +140,17 @@ You can override the `httpx` client to customize it for your use-case. Some comm
and transports.
```python
-from monite import Monite
import httpx
-client = Monite(..., httpx_client=httpx.Client(proxies="http://my.test.proxy.example.com", transport=httpx.HTTPTransport(local_address="0.0.0.0"), ))```
+from monite import Monite
+
+client = Monite(
+ ...,
+ httpx_client=httpx.Client(
+ proxies="http://my.test.proxy.example.com",
+ transport=httpx.HTTPTransport(local_address="0.0.0.0"),
+ ),
+)
+```
## Contributing
diff --git a/poetry.lock b/poetry.lock
index 98ff907..3ddef64 100644
--- a/poetry.lock
+++ b/poetry.lock
@@ -38,13 +38,13 @@ trio = ["trio (>=0.26.1)"]
[[package]]
name = "certifi"
-version = "2025.4.26"
+version = "2025.6.15"
description = "Python package for providing Mozilla's CA Bundle."
optional = false
-python-versions = ">=3.6"
+python-versions = ">=3.7"
files = [
- {file = "certifi-2025.4.26-py3-none-any.whl", hash = "sha256:30350364dfe371162649852c63336a15c70c6510c2ad5015b21c2345311805f3"},
- {file = "certifi-2025.4.26.tar.gz", hash = "sha256:0a816057ea3cdefcef70270d2c515e4506bbc954f417fa5ade2021213bb8f0c6"},
+ {file = "certifi-2025.6.15-py3-none-any.whl", hash = "sha256:2e0c7ce7cb5d8f8634ca55d2ba7e6ec2689a2fd6537d8dec1296a477a4910057"},
+ {file = "certifi-2025.6.15.tar.gz", hash = "sha256:d747aa5a8b9bbbb1bb8c22bb13e22bd1f18e9796defa16bab421f7f7a317323b"},
]
[[package]]
@@ -60,15 +60,18 @@ files = [
[[package]]
name = "exceptiongroup"
-version = "1.2.2"
+version = "1.3.0"
description = "Backport of PEP 654 (exception groups)"
optional = false
python-versions = ">=3.7"
files = [
- {file = "exceptiongroup-1.2.2-py3-none-any.whl", hash = "sha256:3111b9d131c238bec2f8f516e123e14ba243563fb135d3fe885990585aa7795b"},
- {file = "exceptiongroup-1.2.2.tar.gz", hash = "sha256:47c2edf7c6738fafb49fd34290706d1a1a2f4d1c6df275526b62cbb4aa5393cc"},
+ {file = "exceptiongroup-1.3.0-py3-none-any.whl", hash = "sha256:4d111e6e0c13d0644cad6ddaa7ed0261a0b36971f6d23e7ec9b4b9097da78a10"},
+ {file = "exceptiongroup-1.3.0.tar.gz", hash = "sha256:b241f5885f560bc56a59ee63ca4c6a8bfa46ae4ad651af316d4e81817bb9fd88"},
]
+[package.dependencies]
+typing-extensions = {version = ">=4.6.0", markers = "python_version < \"3.13\""}
+
[package.extras]
test = ["pytest (>=6)"]
@@ -544,4 +547,4 @@ files = [
[metadata]
lock-version = "2.0"
python-versions = "^3.8"
-content-hash = "9c462a453d491f6c13e77f216c114935f5785c9e0c2288839fb0862ea2551003"
+content-hash = "8551b871abee465e23fb0966d51f2c155fd257b55bdcb0c02d095de19f92f358"
diff --git a/pyproject.toml b/pyproject.toml
index 6a8973a..1e6b471 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -3,7 +3,7 @@ name = "monite"
[tool.poetry]
name = "monite"
-version = "0.5.2"
+version = "0.5.3"
description = ""
readme = "README.md"
authors = []
@@ -38,7 +38,7 @@ Repository = 'https://github.com/team-monite/monite-python-client'
python = "^3.8"
httpx = ">=0.21.2"
pydantic = ">= 1.9.2"
-pydantic-core = "^2.18.2"
+pydantic-core = ">=2.18.2"
typing_extensions = ">= 4.0.0"
[tool.poetry.group.dev.dependencies]
diff --git a/reference.md b/reference.md
index 96719df..0d0d6e4 100644
--- a/reference.md
+++ b/reference.md
@@ -28,8 +28,16 @@ Retrieve aggregated statistics for payables with different breakdowns.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.analytics.get_analytics_credit_notes(metric="id", aggregation_function="count", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.analytics.get_analytics_credit_notes(
+ metric="id",
+ aggregation_function="count",
+)
```
@@ -293,7 +301,11 @@ client.analytics.get_analytics_credit_notes(metric="id", aggregation_function="c
-
-**status_in:** `typing.Optional[typing.Union[PayableCreditNoteStateEnum, typing.Sequence[PayableCreditNoteStateEnum]]]`
+**status_in:** `typing.Optional[
+ typing.Union[
+ PayableCreditNoteStateEnum, typing.Sequence[PayableCreditNoteStateEnum]
+ ]
+]`
@@ -301,7 +313,11 @@ client.analytics.get_analytics_credit_notes(metric="id", aggregation_function="c
-
-**status_not_in:** `typing.Optional[typing.Union[PayableCreditNoteStateEnum, typing.Sequence[PayableCreditNoteStateEnum]]]`
+**status_not_in:** `typing.Optional[
+ typing.Union[
+ PayableCreditNoteStateEnum, typing.Sequence[PayableCreditNoteStateEnum]
+ ]
+]`
@@ -381,8 +397,16 @@ Retrieve aggregated statistics for payables with different breakdowns.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.analytics.get_analytics_payables(metric="id", aggregation_function="count", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.analytics.get_analytics_payables(
+ metric="id",
+ aggregation_function="count",
+)
```
@@ -482,7 +506,9 @@ To query multiple statuses at once, use the `status__in` parameter instead.
-
-**status_in:** `typing.Optional[typing.Union[PayableStateEnum, typing.Sequence[PayableStateEnum]]]`
+**status_in:** `typing.Optional[
+ typing.Union[PayableStateEnum, typing.Sequence[PayableStateEnum]]
+]`
Return only payables that have the specified [statuses](https://docs.monite.com/accounts-payable/payables/index).
@@ -828,6 +854,14 @@ Valid but nonexistent project IDs do not raise errors but return no results.
-
+**has_tags:** `typing.Optional[bool]` — Filter objects based on whether they have tags. If true, only objects with tags are returned. If false, only objects without tags are returned.
+
+
+
+
+
+-
+
**origin:** `typing.Optional[PayableOriginEnum]` — Return only payables from a given origin ['einvoice', 'upload', 'email']
@@ -884,8 +918,16 @@ Retrieve aggregated statistics for receivables with different breakdowns.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.analytics.get_analytics_receivables(metric="id", aggregation_function="count", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.analytics.get_analytics_receivables(
+ metric="id",
+ aggregation_function="count",
+)
```
@@ -978,7 +1020,12 @@ To specify multiple IDs, repeat this parameter for each value:
-
-**status_in:** `typing.Optional[typing.Union[GetAnalyticsReceivablesRequestStatusInItem, typing.Sequence[GetAnalyticsReceivablesRequestStatusInItem]]]`
+**status_in:** `typing.Optional[
+ typing.Union[
+ GetAnalyticsReceivablesRequestStatusInItem,
+ typing.Sequence[GetAnalyticsReceivablesRequestStatusInItem],
+ ]
+]`
Return only receivables that have the specified statuses. See the applicable [invoice statuses](https://docs.monite.com/accounts-receivable/invoices/index), [quote statuses](https://docs.monite.com/accounts-receivable/quotes/index), and [credit note statuses](https://docs.monite.com/accounts-receivable/credit-notes#credit-note-lifecycle).
@@ -1278,6 +1325,46 @@ For example, given receivables with the following product IDs:
-
+**discounted_subtotal:** `typing.Optional[int]`
+
+
+
+
+
+-
+
+**discounted_subtotal_gt:** `typing.Optional[int]`
+
+
+
+
+
+-
+
+**discounted_subtotal_lt:** `typing.Optional[int]`
+
+
+
+
+
+-
+
+**discounted_subtotal_gte:** `typing.Optional[int]`
+
+
+
+
+
+-
+
+**discounted_subtotal_lte:** `typing.Optional[int]`
+
+
+
+
+
+-
+
**status:** `typing.Optional[GetAnalyticsReceivablesRequestStatus]`
@@ -1383,7 +1470,12 @@ Retrieve a list of all approval policies with pagination.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.approval_policies.get()
```
@@ -1460,7 +1552,12 @@ If not specified, the first page of results will be returned.
-
-**status_in:** `typing.Optional[typing.Union[ApprovalPoliciesGetRequestStatusInItem, typing.Sequence[ApprovalPoliciesGetRequestStatusInItem]]]`
+**status_in:** `typing.Optional[
+ typing.Union[
+ ApprovalPoliciesGetRequestStatusInItem,
+ typing.Sequence[ApprovalPoliciesGetRequestStatusInItem],
+ ]
+]`
@@ -1604,8 +1701,16 @@ Create a new approval policy.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.approval_policies.create(name='name', script=[True], )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.approval_policies.create(
+ name="name",
+ script=[True],
+)
```
@@ -1709,8 +1814,15 @@ Retrieve a specific approval policy.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.approval_policies.get_by_id(approval_policy_id='approval_policy_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.approval_policies.get_by_id(
+ approval_policy_id="approval_policy_id",
+)
```
@@ -1774,8 +1886,15 @@ Delete an existing approval policy.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.approval_policies.delete_by_id(approval_policy_id='approval_policy_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.approval_policies.delete_by_id(
+ approval_policy_id="approval_policy_id",
+)
```
@@ -1839,8 +1958,15 @@ Update an existing approval policy.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.approval_policies.update_by_id(approval_policy_id='approval_policy_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.approval_policies.update_by_id(
+ approval_policy_id="approval_policy_id",
+)
```
@@ -1947,7 +2073,12 @@ client.approval_policies.update_by_id(approval_policy_id='approval_policy_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.approval_requests.get()
```
@@ -2084,7 +2215,9 @@ client.approval_requests.get()
-
-**status_in:** `typing.Optional[typing.Union[ApprovalRequestStatus, typing.Sequence[ApprovalRequestStatus]]]`
+**status_in:** `typing.Optional[
+ typing.Union[ApprovalRequestStatus, typing.Sequence[ApprovalRequestStatus]]
+]`
@@ -2157,10 +2290,21 @@ client.approval_requests.get()
-
```python
-from monite import Monite
-from monite import ApprovalRequestCreateByRoleRequest
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.approval_requests.create(request=ApprovalRequestCreateByRoleRequest(object_id='object_id', object_type="account", required_approval_count=1, role_ids=['role_ids'], ), )
+from monite import ApprovalRequestCreateByRoleRequest, Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.approval_requests.create(
+ request=ApprovalRequestCreateByRoleRequest(
+ object_id="object_id",
+ object_type="account",
+ required_approval_count=1,
+ role_ids=["role_ids"],
+ ),
+)
```
@@ -2210,8 +2354,15 @@ client.approval_requests.create(request=ApprovalRequestCreateByRoleRequest(objec
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.approval_requests.get_by_id(approval_request_id='approval_request_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.approval_requests.get_by_id(
+ approval_request_id="approval_request_id",
+)
```
@@ -2261,8 +2412,15 @@ client.approval_requests.get_by_id(approval_request_id='approval_request_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.approval_requests.approve_by_id(approval_request_id='approval_request_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.approval_requests.approve_by_id(
+ approval_request_id="approval_request_id",
+)
```
@@ -2312,8 +2470,15 @@ client.approval_requests.approve_by_id(approval_request_id='approval_request_id'
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.approval_requests.cancel_by_id(approval_request_id='approval_request_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.approval_requests.cancel_by_id(
+ approval_request_id="approval_request_id",
+)
```
@@ -2363,8 +2528,15 @@ client.approval_requests.cancel_by_id(approval_request_id='approval_request_id',
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.approval_requests.reject_by_id(approval_request_id='approval_request_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.approval_requests.reject_by_id(
+ approval_request_id="approval_request_id",
+)
```
@@ -2429,8 +2601,17 @@ Revoke an existing token immediately.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.access_tokens.revoke(client_id='client_id', client_secret='client_secret', token='token', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.access_tokens.revoke(
+ client_id="client_id",
+ client_secret="client_secret",
+ token="token",
+)
```
@@ -2510,8 +2691,17 @@ Create a new access token based on client ID and client secret.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.access_tokens.create(client_id='client_id', client_secret='client_secret', grant_type="client_credentials", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.access_tokens.create(
+ client_id="client_id",
+ client_secret="client_secret",
+ grant_type="client_credentials",
+)
```
@@ -2600,8 +2790,15 @@ Get comments
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.comments.get(object_id='object_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.comments.get(
+ object_id="object_id",
+)
```
@@ -2729,8 +2926,17 @@ Create new comment
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.comments.create(object_id='object_id', object_type='object_type', text='text', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.comments.create(
+ object_id="object_id",
+ object_type="object_type",
+ text="text",
+)
```
@@ -2818,8 +3024,15 @@ Get comment
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.comments.get_by_id(comment_id='comment_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.comments.get_by_id(
+ comment_id="comment_id",
+)
```
@@ -2883,8 +3096,15 @@ Delete comment
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.comments.delete_by_id(comment_id='comment_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.comments.delete_by_id(
+ comment_id="comment_id",
+)
```
@@ -2948,8 +3168,15 @@ Update comment
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.comments.update_by_id(comment_id='comment_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.comments.update_by_id(
+ comment_id="comment_id",
+)
```
@@ -3016,8 +3243,15 @@ client.comments.update_by_id(comment_id='comment_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.get(sort_code='123456', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.get(
+ sort_code="123456",
+)
```
@@ -3310,12 +3544,33 @@ If not specified, the first page of results will be returned.
-
```python
-from monite import Monite
-from monite import CounterpartCreatePayload_Organization
-from monite import CounterpartOrganizationCreatePayload
-from monite import CounterpartAddress
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.create(request=CounterpartCreatePayload_Organization(organization=CounterpartOrganizationCreatePayload(address=CounterpartAddress(city='Berlin', country="AF", line1='Flughafenstrasse 52', postal_code='10115', ), is_customer=True, is_vendor=True, legal_name='Acme Inc.', ), ), )
+from monite import (
+ CounterpartAddress,
+ CounterpartCreatePayload_Organization,
+ CounterpartOrganizationCreatePayload,
+ Monite,
+)
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.create(
+ request=CounterpartCreatePayload_Organization(
+ organization=CounterpartOrganizationCreatePayload(
+ address=CounterpartAddress(
+ city="Berlin",
+ country="AF",
+ line1="Flughafenstrasse 52",
+ postal_code="10115",
+ ),
+ is_customer=True,
+ is_vendor=True,
+ legal_name="Acme Inc.",
+ ),
+ ),
+)
```
@@ -3365,8 +3620,15 @@ client.counterparts.create(request=CounterpartCreatePayload_Organization(organiz
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.get_by_id(counterpart_id='counterpart_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.get_by_id(
+ counterpart_id="counterpart_id",
+)
```
@@ -3416,8 +3678,15 @@ client.counterparts.get_by_id(counterpart_id='counterpart_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.delete_by_id(counterpart_id='counterpart_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.delete_by_id(
+ counterpart_id="counterpart_id",
+)
```
@@ -3466,11 +3735,23 @@ client.counterparts.delete_by_id(counterpart_id='counterpart_id', )
-
```python
-from monite import Monite
-from monite import CounterpartIndividualRootUpdatePayload
-from monite import CounterpartIndividualUpdatePayload
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.update_by_id(counterpart_id='counterpart_id', request=CounterpartIndividualRootUpdatePayload(individual=CounterpartIndividualUpdatePayload(), ), )
+from monite import (
+ CounterpartIndividualRootUpdatePayload,
+ CounterpartIndividualUpdatePayload,
+ Monite,
+)
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.update_by_id(
+ counterpart_id="counterpart_id",
+ request=CounterpartIndividualRootUpdatePayload(
+ individual=CounterpartIndividualUpdatePayload(),
+ ),
+)
```
@@ -3528,8 +3809,15 @@ client.counterparts.update_by_id(counterpart_id='counterpart_id', request=Counte
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.get_partner_metadata_by_id(counterpart_id='counterpart_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.get_partner_metadata_by_id(
+ counterpart_id="counterpart_id",
+)
```
@@ -3579,9 +3867,16 @@ client.counterparts.get_partner_metadata_by_id(counterpart_id='counterpart_id',
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.update_partner_metadata_by_id(counterpart_id='counterpart_id', metadata={'key': 'value'
-}, )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.update_partner_metadata_by_id(
+ counterpart_id="counterpart_id",
+ metadata={"key": "value"},
+)
```
@@ -3640,8 +3935,15 @@ client.counterparts.update_partner_metadata_by_id(counterpart_id='counterpart_id
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterpart_e_invoicing_credentials.get_counterparts_id_einvoicing_credentials(counterpart_id='counterpart_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterpart_e_invoicing_credentials.get_counterparts_id_einvoicing_credentials(
+ counterpart_id="counterpart_id",
+)
```
@@ -3690,10 +3992,19 @@ client.counterpart_e_invoicing_credentials.get_counterparts_id_einvoicing_creden
-
```python
-from monite import Monite
-from monite import CreateCounterpartEinvoicingCredentialCounterpartVatId
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterpart_e_invoicing_credentials.post_counterparts_id_einvoicing_credentials(counterpart_id='counterpart_id', request=CreateCounterpartEinvoicingCredentialCounterpartVatId(counterpart_vat_id_id='counterpart_vat_id_id', ), )
+from monite import CreateCounterpartEinvoicingCredentialCounterpartVatId, Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterpart_e_invoicing_credentials.post_counterparts_id_einvoicing_credentials(
+ counterpart_id="counterpart_id",
+ request=CreateCounterpartEinvoicingCredentialCounterpartVatId(
+ counterpart_vat_id_id="counterpart_vat_id_id",
+ ),
+)
```
@@ -3751,8 +4062,16 @@ client.counterpart_e_invoicing_credentials.post_counterparts_id_einvoicing_crede
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterpart_e_invoicing_credentials.get_counterparts_id_einvoicing_credentials_id(credential_id='credential_id', counterpart_id='counterpart_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterpart_e_invoicing_credentials.get_counterparts_id_einvoicing_credentials_id(
+ credential_id="credential_id",
+ counterpart_id="counterpart_id",
+)
```
@@ -3810,8 +4129,16 @@ client.counterpart_e_invoicing_credentials.get_counterparts_id_einvoicing_creden
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterpart_e_invoicing_credentials.delete_counterparts_id_einvoicing_credentials_id(credential_id='credential_id', counterpart_id='counterpart_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterpart_e_invoicing_credentials.delete_counterparts_id_einvoicing_credentials_id(
+ credential_id="credential_id",
+ counterpart_id="counterpart_id",
+)
```
@@ -3869,8 +4196,16 @@ client.counterpart_e_invoicing_credentials.delete_counterparts_id_einvoicing_cre
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterpart_e_invoicing_credentials.patch_counterparts_id_einvoicing_credentials_id(credential_id='credential_id', counterpart_id='counterpart_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterpart_e_invoicing_credentials.patch_counterparts_id_einvoicing_credentials_id(
+ credential_id="credential_id",
+ counterpart_id="counterpart_id",
+)
```
@@ -3930,8 +4265,8 @@ client.counterpart_e_invoicing_credentials.patch_counterparts_id_einvoicing_cred
-## DataExports
-client.data_exports.get(...)
+## Custom VAT rates
+client.custom_vat_rates.get_custom_vat_rates()
-
@@ -3945,8 +4280,13 @@ client.counterpart_e_invoicing_credentials.patch_counterparts_id_einvoicing_cred
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.data_exports.get()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.custom_vat_rates.get_custom_vat_rates()
```
@@ -3962,63 +4302,63 @@ client.data_exports.get()
-
-**order:** `typing.Optional[OrderEnum]` — Order by
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
-
-
--
-
-**limit:** `typing.Optional[int]` — Max is 100
-
-
--
-**pagination_token:** `typing.Optional[str]` — A token, obtained from previous page. Prior over other filters
-
+
+client.custom_vat_rates.post_custom_vat_rates(...)
-
-**sort:** `typing.Optional[DataExportCursorFields]` — Allowed sort fields
-
-
-
+#### 🔌 Usage
-
-**created_at_gt:** `typing.Optional[dt.datetime]`
-
-
-
-
-
-**created_at_lt:** `typing.Optional[dt.datetime]`
-
+```python
+from monite import Monite, VatRateComponent
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.custom_vat_rates.post_custom_vat_rates(
+ components=[
+ VatRateComponent(
+ name="name",
+ value=1.1,
+ )
+ ],
+ name="name",
+)
+
+```
+
+
+
+#### ⚙️ Parameters
-
-**created_at_gte:** `typing.Optional[dt.datetime]`
-
-
-
-
-
-**created_at_lte:** `typing.Optional[dt.datetime]`
+**components:** `typing.Sequence[VatRateComponent]` — Sub-taxes included in the Custom VAT.
@@ -4026,7 +4366,7 @@ client.data_exports.get()
-
-**created_by_entity_user_id:** `typing.Optional[str]`
+**name:** `str` — Display name of the Custom VAT.
@@ -4046,24 +4386,10 @@ client.data_exports.get()
-client.data_exports.create(...)
-
--
-
-#### 📝 Description
-
-
--
-
+
client.custom_vat_rates.get_custom_vat_rates_id(...)
-
-Request the export of payable and receivable documents with the specified statuses.
-
-
-
-
-
#### 🔌 Usage
@@ -4074,9 +4400,15 @@ Request the export of payable and receivable documents with the specified status
```python
from monite import Monite
-from monite import ExportObjectSchema_Payable
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.data_exports.create(date_from='date_from', date_to='date_to', format="csv", objects=[ExportObjectSchema_Payable(statuses=["draft"], )], )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.custom_vat_rates.get_custom_vat_rates_id(
+ custom_vat_rate_id="custom_vat_rate_id",
+)
```
@@ -4092,31 +4424,7 @@ client.data_exports.create(date_from='date_from', date_to='date_to', format="csv
-
-**date_from:** `str`
-
-
-
-
-
--
-
-**date_to:** `str`
-
-
-
-
-
--
-
-**format:** `ExportFormat`
-
-
-
-
-
--
-
-**objects:** `typing.Sequence[ExportObjectSchema]`
+**custom_vat_rate_id:** `str`
@@ -4136,7 +4444,7 @@ client.data_exports.create(date_from='date_from', date_to='date_to', format="csv
-client.data_exports.get_supported_formats()
+client.custom_vat_rates.delete_custom_vat_rates_id(...)
-
@@ -4150,8 +4458,15 @@ client.data_exports.create(date_from='date_from', date_to='date_to', format="csv
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.data_exports.get_supported_formats()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.custom_vat_rates.delete_custom_vat_rates_id(
+ custom_vat_rate_id="custom_vat_rate_id",
+)
```
@@ -4167,6 +4482,14 @@ client.data_exports.get_supported_formats()
-
+**custom_vat_rate_id:** `str`
+
+
+
+
+
+-
+
**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -4179,7 +4502,7 @@ client.data_exports.get_supported_formats()
-client.data_exports.get_by_id(...)
+client.custom_vat_rates.patch_custom_vat_rates_id(...)
-
@@ -4193,8 +4516,15 @@ client.data_exports.get_supported_formats()
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.data_exports.get_by_id(document_export_id='document_export_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.custom_vat_rates.patch_custom_vat_rates_id(
+ custom_vat_rate_id="custom_vat_rate_id",
+)
```
@@ -4210,7 +4540,7 @@ client.data_exports.get_by_id(document_export_id='document_export_id', )
-
-**document_export_id:** `str`
+**custom_vat_rate_id:** `str`
@@ -4218,36 +4548,38 @@ client.data_exports.get_by_id(document_export_id='document_export_id', )
-
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+**components:** `typing.Optional[typing.Sequence[VatRateComponent]]` — Sub-taxes included in the Custom VAT.
-
-
-
-
-
-
-
-## Delivery notes
-client.delivery_notes.get_delivery_notes(...)
-
-#### 📝 Description
-
-
--
+**name:** `typing.Optional[str]` — Display name of the Custom VAT.
+
+
+
-
-Get all delivery notes with filtering and pagination.
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
+
+
+
+
+
+## DataExports
+client.data_exports.get(...)
+
+-
#### 🔌 Usage
@@ -4259,8 +4591,13 @@ Get all delivery notes with filtering and pagination.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.delivery_notes.get_delivery_notes()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.data_exports.get()
```
@@ -4276,7 +4613,7 @@ client.delivery_notes.get_delivery_notes()
-
-**order:** `typing.Optional[OrderEnum]` — Sort order (ascending by default). Typically used together with the `sort` parameter.
+**order:** `typing.Optional[OrderEnum]` — Order by
@@ -4284,7 +4621,7 @@ client.delivery_notes.get_delivery_notes()
-
-**limit:** `typing.Optional[int]` — The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+**limit:** `typing.Optional[int]` — Max is 100
@@ -4292,11 +4629,7 @@ client.delivery_notes.get_delivery_notes()
-
-**pagination_token:** `typing.Optional[str]`
-
-A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
-
-If not specified, the first page of results will be returned.
+**pagination_token:** `typing.Optional[str]` — A token, obtained from previous page. Prior over other filters
@@ -4304,7 +4637,7 @@ If not specified, the first page of results will be returned.
-
-**sort:** `typing.Optional[DeliveryNoteCursorFields]` — The field to sort the results by. Typically used together with the `order` parameter.
+**sort:** `typing.Optional[DataExportCursorFields]` — Allowed sort fields
@@ -4312,7 +4645,7 @@ If not specified, the first page of results will be returned.
-
-**id_in:** `typing.Optional[typing.Union[str, typing.Sequence[str]]]`
+**created_at_gt:** `typing.Optional[dt.datetime]`
@@ -4320,7 +4653,7 @@ If not specified, the first page of results will be returned.
-
-**status:** `typing.Optional[DeliveryNoteStatusEnum]`
+**created_at_lt:** `typing.Optional[dt.datetime]`
@@ -4328,7 +4661,7 @@ If not specified, the first page of results will be returned.
-
-**status_in:** `typing.Optional[typing.Union[DeliveryNoteStatusEnum, typing.Sequence[DeliveryNoteStatusEnum]]]`
+**created_at_gte:** `typing.Optional[dt.datetime]`
@@ -4336,7 +4669,7 @@ If not specified, the first page of results will be returned.
-
-**document_id:** `typing.Optional[str]`
+**created_at_lte:** `typing.Optional[dt.datetime]`
@@ -4344,7 +4677,7 @@ If not specified, the first page of results will be returned.
-
-**document_id_contains:** `typing.Optional[str]`
+**created_by_entity_user_id:** `typing.Optional[str]`
@@ -4352,95 +4685,78 @@ If not specified, the first page of results will be returned.
-
-**document_id_icontains:** `typing.Optional[str]`
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
-
--
-**created_by_entity_user_id:** `typing.Optional[str]`
-
+
+client.data_exports.create(...)
-
-**counterpart_id:** `typing.Optional[str]`
-
-
-
+#### 📝 Description
-
-**based_on:** `typing.Optional[str]`
-
-
-
-
-
-**based_on_document_id:** `typing.Optional[str]`
-
+Request the export of payable and receivable documents with the specified statuses.
+
+
-
--
-
-**based_on_document_id_contains:** `typing.Optional[str]`
-
-
-
+#### 🔌 Usage
-
-**based_on_document_id_icontains:** `typing.Optional[str]`
-
-
-
-
-
-**created_at_gt:** `typing.Optional[dt.datetime]`
-
-
-
+```python
+from monite import ExportObjectSchema_Payable, Monite
-
--
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.data_exports.create(
+ date_from="date_from",
+ date_to="date_to",
+ format="csv",
+ objects=[
+ ExportObjectSchema_Payable(
+ statuses=["draft"],
+ )
+ ],
+)
-**created_at_lt:** `typing.Optional[dt.datetime]`
-
+```
-
-
--
-
-**created_at_gte:** `typing.Optional[dt.datetime]`
-
+#### ⚙️ Parameters
+
-
-**created_at_lte:** `typing.Optional[dt.datetime]`
-
-
-
-
-
-**delivery_date_gt:** `typing.Optional[str]`
+**date_from:** `str`
@@ -4448,7 +4764,7 @@ If not specified, the first page of results will be returned.
-
-**delivery_date_lt:** `typing.Optional[str]`
+**date_to:** `str`
@@ -4456,7 +4772,7 @@ If not specified, the first page of results will be returned.
-
-**delivery_date_gte:** `typing.Optional[str]`
+**format:** `ExportFormat`
@@ -4464,7 +4780,7 @@ If not specified, the first page of results will be returned.
-
-**delivery_date_lte:** `typing.Optional[str]`
+**objects:** `typing.Sequence[ExportObjectSchema]`
@@ -4484,7 +4800,7 @@ If not specified, the first page of results will be returned.
-client.delivery_notes.post_delivery_notes(...)
+client.data_exports.get_supported_formats()
-
@@ -4498,12 +4814,13 @@ If not specified, the first page of results will be returned.
```python
from monite import Monite
-from monite import DeliveryNoteCreateRequest
-from monite import DeliveryNoteCreateLineItem
-from monite import DeliveryNoteLineItemProduct
-from monite import UnitRequest
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.delivery_notes.post_delivery_notes(request=DeliveryNoteCreateRequest(counterpart_address_id='a1b2c3d4-e5f6-g7h8-i9j0-k1l2m3n4o5p6', counterpart_id='a1b2c3d4-e5f6-g7h8-i9j0-k1l2m3n4o5p6', delivery_date='2025-01-01', delivery_number='102-2025-0987', display_signature_placeholder=True, line_items=[DeliveryNoteCreateLineItem(product_id='a1b2c3d4-e5f6-g7h8-i9j0-k1l2m3n4o5p6', quantity=10.0, ), DeliveryNoteCreateLineItem(product=DeliveryNoteLineItemProduct(description='Description of product 2', measure_unit=UnitRequest(description='pieces', name='pcs', ), name='Product 2', ), quantity=20.0, )], memo='This is a memo', ), )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.data_exports.get_supported_formats()
```
@@ -4519,14 +4836,6 @@ client.delivery_notes.post_delivery_notes(request=DeliveryNoteCreateRequest(coun
-
-**request:** `Payload`
-
-
-
-
-
--
-
**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -4539,7 +4848,7 @@ client.delivery_notes.post_delivery_notes(request=DeliveryNoteCreateRequest(coun
-client.delivery_notes.get_delivery_notes_id(...)
+client.data_exports.get_by_id(...)
-
@@ -4553,8 +4862,15 @@ client.delivery_notes.post_delivery_notes(request=DeliveryNoteCreateRequest(coun
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.delivery_notes.get_delivery_notes_id(delivery_note_id='delivery_note_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.data_exports.get_by_id(
+ document_export_id="document_export_id",
+)
```
@@ -4570,7 +4886,7 @@ client.delivery_notes.get_delivery_notes_id(delivery_note_id='delivery_note_id',
-
-**delivery_note_id:** `str`
+**document_export_id:** `str`
@@ -4590,10 +4906,25 @@ client.delivery_notes.get_delivery_notes_id(delivery_note_id='delivery_note_id',
-client.delivery_notes.delete_delivery_notes_id(...)
+## Delivery notes
+client.delivery_notes.get_delivery_notes(...)
-
+#### 📝 Description
+
+
+-
+
+
+-
+
+Get all delivery notes with filtering and pagination.
+
+
+
+
+
#### 🔌 Usage
@@ -4604,8 +4935,13 @@ client.delivery_notes.get_delivery_notes_id(delivery_note_id='delivery_note_id',
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.delivery_notes.delete_delivery_notes_id(delivery_note_id='delivery_note_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.delivery_notes.get_delivery_notes()
```
@@ -4621,7 +4957,7 @@ client.delivery_notes.delete_delivery_notes_id(delivery_note_id='delivery_note_i
-
-**delivery_note_id:** `str`
+**order:** `typing.Optional[OrderEnum]` — Sort order (ascending by default). Typically used together with the `sort` parameter.
@@ -4629,50 +4965,63 @@ client.delivery_notes.delete_delivery_notes_id(delivery_note_id='delivery_note_i
-
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+**limit:** `typing.Optional[int]` — The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
-
-
+
+-
+
+**pagination_token:** `typing.Optional[str]`
+
+A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+If not specified, the first page of results will be returned.
+
-
-client.delivery_notes.patch_delivery_notes_id(...)
-
-#### 🔌 Usage
+**sort:** `typing.Optional[DeliveryNoteCursorFields]` — The field to sort the results by. Typically used together with the `order` parameter.
+
+
+
-
+**id_in:** `typing.Optional[typing.Union[str, typing.Sequence[str]]]`
+
+
+
+
-
-```python
-from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.delivery_notes.patch_delivery_notes_id(delivery_note_id='delivery_note_id', )
-
-```
-
-
+**status:** `typing.Optional[DeliveryNoteStatusEnum]`
+
-#### ⚙️ Parameters
-
-
+**status_in:** `typing.Optional[
+ typing.Union[
+ DeliveryNoteStatusEnum, typing.Sequence[DeliveryNoteStatusEnum]
+ ]
+]`
+
+
+
+
-
-**delivery_note_id:** `str`
+**document_id:** `typing.Optional[str]`
@@ -4680,7 +5029,7 @@ client.delivery_notes.patch_delivery_notes_id(delivery_note_id='delivery_note_id
-
-**counterpart_address_id:** `typing.Optional[str]` — ID of the counterpart address selected for the delivery note
+**document_id_contains:** `typing.Optional[str]`
@@ -4688,7 +5037,7 @@ client.delivery_notes.patch_delivery_notes_id(delivery_note_id='delivery_note_id
-
-**counterpart_id:** `typing.Optional[str]` — ID of the counterpart
+**document_id_icontains:** `typing.Optional[str]`
@@ -4696,7 +5045,7 @@ client.delivery_notes.patch_delivery_notes_id(delivery_note_id='delivery_note_id
-
-**delivery_date:** `typing.Optional[str]` — Date of delivery
+**created_by_entity_user_id:** `typing.Optional[str]`
@@ -4704,7 +5053,7 @@ client.delivery_notes.patch_delivery_notes_id(delivery_note_id='delivery_note_id
-
-**delivery_number:** `typing.Optional[str]` — Delivery number
+**counterpart_id:** `typing.Optional[str]`
@@ -4712,7 +5061,7 @@ client.delivery_notes.patch_delivery_notes_id(delivery_note_id='delivery_note_id
-
-**display_signature_placeholder:** `typing.Optional[bool]` — Whether to display a signature placeholder in the generated PDF
+**based_on:** `typing.Optional[str]`
@@ -4720,7 +5069,7 @@ client.delivery_notes.patch_delivery_notes_id(delivery_note_id='delivery_note_id
-
-**line_items:** `typing.Optional[typing.Sequence[DeliveryNoteCreateLineItem]]` — List of line items in the delivery note
+**based_on_document_id:** `typing.Optional[str]`
@@ -4728,7 +5077,7 @@ client.delivery_notes.patch_delivery_notes_id(delivery_note_id='delivery_note_id
-
-**memo:** `typing.Optional[str]` — Additional information regarding the delivery note
+**based_on_document_id_contains:** `typing.Optional[str]`
@@ -4736,50 +5085,71 @@ client.delivery_notes.patch_delivery_notes_id(delivery_note_id='delivery_note_id
-
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+**based_on_document_id_icontains:** `typing.Optional[str]`
+
+
+-
+
+**created_at_gt:** `typing.Optional[dt.datetime]`
+
+
+-
+**created_at_lt:** `typing.Optional[dt.datetime]`
+
-
-client.delivery_notes.post_delivery_notes_id_cancel(...)
-
-#### 🔌 Usage
+**created_at_gte:** `typing.Optional[dt.datetime]`
+
+
+
-
+**created_at_lte:** `typing.Optional[dt.datetime]`
+
+
+
+
-
-```python
-from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.delivery_notes.post_delivery_notes_id_cancel(delivery_note_id='delivery_note_id', )
-
-```
+**delivery_date_gt:** `typing.Optional[str]`
+
+
+
+-
+
+**delivery_date_lt:** `typing.Optional[str]`
+
-#### ⚙️ Parameters
-
-
+**delivery_date_gte:** `typing.Optional[str]`
+
+
+
+
-
-**delivery_note_id:** `str`
+**delivery_date_lte:** `typing.Optional[str]`
@@ -4799,7 +5169,7 @@ client.delivery_notes.post_delivery_notes_id_cancel(delivery_note_id='delivery_n
-client.delivery_notes.post_delivery_notes_id_mark_as_delivered(...)
+client.delivery_notes.post_delivery_notes(...)
-
@@ -4812,9 +5182,46 @@ client.delivery_notes.post_delivery_notes_id_cancel(delivery_note_id='delivery_n
-
```python
-from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.delivery_notes.post_delivery_notes_id_mark_as_delivered(delivery_note_id='delivery_note_id', )
+from monite import (
+ DeliveryNoteCreateLineItem,
+ DeliveryNoteCreateRequest,
+ DeliveryNoteLineItemProduct,
+ Monite,
+ UnitRequest,
+)
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.delivery_notes.post_delivery_notes(
+ request=DeliveryNoteCreateRequest(
+ counterpart_address_id="a1b2c3d4-e5f6-g7h8-i9j0-k1l2m3n4o5p6",
+ counterpart_id="a1b2c3d4-e5f6-g7h8-i9j0-k1l2m3n4o5p6",
+ delivery_date="2025-01-01",
+ delivery_number="102-2025-0987",
+ display_signature_placeholder=True,
+ line_items=[
+ DeliveryNoteCreateLineItem(
+ product_id="a1b2c3d4-e5f6-g7h8-i9j0-k1l2m3n4o5p6",
+ quantity=10.0,
+ ),
+ DeliveryNoteCreateLineItem(
+ product=DeliveryNoteLineItemProduct(
+ description="Description of product 2",
+ measure_unit=UnitRequest(
+ description="pieces",
+ name="pcs",
+ ),
+ name="Product 2",
+ ),
+ quantity=20.0,
+ ),
+ ],
+ memo="This is a memo",
+ ),
+)
```
@@ -4830,7 +5237,7 @@ client.delivery_notes.post_delivery_notes_id_mark_as_delivered(delivery_note_id=
-
-**delivery_note_id:** `str`
+**request:** `Payload`
@@ -4850,25 +5257,10 @@ client.delivery_notes.post_delivery_notes_id_mark_as_delivered(delivery_note_id=
-## PDF templates
-client.pdf_templates.get()
-
--
-
-#### 📝 Description
-
-
--
-
+
client.delivery_notes.get_delivery_notes_id(...)
-
-This API call returns all supported templates with language codes.
-
-
-
-
-
#### 🔌 Usage
@@ -4879,8 +5271,15 @@ This API call returns all supported templates with language codes.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.pdf_templates.get()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.delivery_notes.get_delivery_notes_id(
+ delivery_note_id="delivery_note_id",
+)
```
@@ -4896,6 +5295,14 @@ client.pdf_templates.get()
-
+**delivery_note_id:** `str`
+
+
+
+
+
+-
+
**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -4908,24 +5315,10 @@ client.pdf_templates.get()
-client.pdf_templates.get_system()
-
--
-
-#### 📝 Description
-
-
--
-
+
client.delivery_notes.delete_delivery_notes_id(...)
-
-This API call returns all supported system templates with language codes.
-
-
-
-
-
#### 🔌 Usage
@@ -4936,8 +5329,15 @@ This API call returns all supported system templates with language codes.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.pdf_templates.get_system()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.delivery_notes.delete_delivery_notes_id(
+ delivery_note_id="delivery_note_id",
+)
```
@@ -4953,6 +5353,14 @@ client.pdf_templates.get_system()
-
+**delivery_note_id:** `str`
+
+
+
+
+
+-
+
**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -4965,7 +5373,7 @@ client.pdf_templates.get_system()
-client.pdf_templates.get_by_id(...)
+client.delivery_notes.patch_delivery_notes_id(...)
-
@@ -4979,8 +5387,15 @@ client.pdf_templates.get_system()
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.pdf_templates.get_by_id(document_template_id='document_template_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.delivery_notes.patch_delivery_notes_id(
+ delivery_note_id="delivery_note_id",
+)
```
@@ -4996,7 +5411,7 @@ client.pdf_templates.get_by_id(document_template_id='document_template_id', )
-
-**document_template_id:** `str`
+**delivery_note_id:** `str`
@@ -5004,50 +5419,55 @@ client.pdf_templates.get_by_id(document_template_id='document_template_id', )
-
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+**counterpart_address_id:** `typing.Optional[str]` — ID of the counterpart address selected for the delivery note
-
-
+
+-
+**counterpart_id:** `typing.Optional[str]` — ID of the counterpart
+
-
-client.pdf_templates.make_default_by_id(...)
-
-#### 🔌 Usage
+**delivery_date:** `typing.Optional[str]` — Date of delivery
+
+
+
-
+**delivery_number:** `typing.Optional[str]` — Delivery number
+
+
+
+
-
-```python
-from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.pdf_templates.make_default_by_id(document_template_id='document_template_id', )
-
-```
-
-
+**display_signature_placeholder:** `typing.Optional[bool]` — Whether to display a signature placeholder in the generated PDF
+
-#### ⚙️ Parameters
-
-
+**line_items:** `typing.Optional[typing.Sequence[DeliveryNoteCreateLineItem]]` — List of line items in the delivery note
+
+
+
+
-
-**document_template_id:** `str`
+**memo:** `typing.Optional[str]` — Additional information regarding the delivery note
@@ -5067,8 +5487,7 @@ client.pdf_templates.make_default_by_id(document_template_id='document_template_
-## E-invoicing connections
-client.e_invoicing_connections.get_einvoicing_connections()
+client.delivery_notes.post_delivery_notes_id_cancel(...)
-
@@ -5082,8 +5501,15 @@ client.pdf_templates.make_default_by_id(document_template_id='document_template_
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.e_invoicing_connections.get_einvoicing_connections()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.delivery_notes.post_delivery_notes_id_cancel(
+ delivery_note_id="delivery_note_id",
+)
```
@@ -5099,6 +5525,14 @@ client.e_invoicing_connections.get_einvoicing_connections()
-
+**delivery_note_id:** `str`
+
+
+
+
+
+-
+
**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -5111,7 +5545,7 @@ client.e_invoicing_connections.get_einvoicing_connections()
-client.e_invoicing_connections.post_einvoicing_connections(...)
+client.delivery_notes.post_delivery_notes_id_mark_as_delivered(...)
-
@@ -5125,9 +5559,15 @@ client.e_invoicing_connections.get_einvoicing_connections()
```python
from monite import Monite
-from monite import EinvoicingAddress
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.e_invoicing_connections.post_einvoicing_connections(address=EinvoicingAddress(address_line1='address_line1', city='city', country="DE", postal_code='postal_code', ), )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.delivery_notes.post_delivery_notes_id_mark_as_delivered(
+ delivery_note_id="delivery_note_id",
+)
```
@@ -5143,15 +5583,7 @@ client.e_invoicing_connections.post_einvoicing_connections(address=EinvoicingAdd
-
-**address:** `EinvoicingAddress` — Integration Address
-
-
-
-
-
--
-
-**entity_vat_id_id:** `typing.Optional[str]` — Entity VAT ID identifier for the integration
+**delivery_note_id:** `str`
@@ -5171,11 +5603,12 @@ client.e_invoicing_connections.post_einvoicing_connections(address=EinvoicingAdd
-client.e_invoicing_connections.get_einvoicing_connections_id(...)
+## PDF templates
+client.pdf_templates.get()
-
-#### 🔌 Usage
+#### 📝 Description
-
@@ -5183,18 +5616,13 @@ client.e_invoicing_connections.post_einvoicing_connections(address=EinvoicingAdd
-
-```python
-from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.e_invoicing_connections.get_einvoicing_connections_id(einvoicing_connection_id='einvoicing_connection_id', )
-
-```
+This API call returns all supported templates with language codes.
-#### ⚙️ Parameters
+#### 🔌 Usage
-
@@ -5202,10 +5630,26 @@ client.e_invoicing_connections.get_einvoicing_connections_id(einvoicing_connecti
-
-**einvoicing_connection_id:** `str`
-
+```python
+from monite import Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.pdf_templates.get()
+
+```
+
+
+
+#### ⚙️ Parameters
+
+
+-
-
@@ -5222,11 +5666,11 @@ client.e_invoicing_connections.get_einvoicing_connections_id(einvoicing_connecti
-client.e_invoicing_connections.delete_einvoicing_connections_id(...)
+client.pdf_templates.get_system()
-
-#### 🔌 Usage
+#### 📝 Description
-
@@ -5234,18 +5678,13 @@ client.e_invoicing_connections.get_einvoicing_connections_id(einvoicing_connecti
-
-```python
-from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.e_invoicing_connections.delete_einvoicing_connections_id(einvoicing_connection_id='einvoicing_connection_id', )
-
-```
+This API call returns all supported system templates with language codes.
-#### ⚙️ Parameters
+#### 🔌 Usage
-
@@ -5253,11 +5692,27 @@ client.e_invoicing_connections.delete_einvoicing_connections_id(einvoicing_conne
-
-**einvoicing_connection_id:** `str`
-
+```python
+from monite import Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.pdf_templates.get_system()
+
+```
+
+
+#### ⚙️ Parameters
+
+
+-
+
-
@@ -5273,7 +5728,7 @@ client.e_invoicing_connections.delete_einvoicing_connections_id(einvoicing_conne
-client.e_invoicing_connections.post_einvoicing_connections_id_network_credentials(...)
+client.pdf_templates.get_by_id(...)
-
@@ -5287,8 +5742,15 @@ client.e_invoicing_connections.delete_einvoicing_connections_id(einvoicing_conne
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.e_invoicing_connections.post_einvoicing_connections_id_network_credentials(einvoicing_connection_id='einvoicing_connection_id', network_credentials_identifier='12345678', network_credentials_schema="DE:VAT", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.pdf_templates.get_by_id(
+ document_template_id="document_template_id",
+)
```
@@ -5304,23 +5766,7 @@ client.e_invoicing_connections.post_einvoicing_connections_id_network_credential
-
-**einvoicing_connection_id:** `str`
-
-
-
-
-
--
-
-**network_credentials_identifier:** `str` — Network participant identifier
-
-
-
-
-
--
-
-**network_credentials_schema:** `EinvoiceSchemaTypeEnum` — Network scheme identifier
+**document_template_id:** `str`
@@ -5340,25 +5786,10 @@ client.e_invoicing_connections.post_einvoicing_connections_id_network_credential
-## Entities
-client.entities.get(...)
-
--
-
-#### 📝 Description
-
-
--
-
+
client.pdf_templates.make_default_by_id(...)
-
-Retrieve a list of all entities.
-
-
-
-
-
#### 🔌 Usage
@@ -5369,8 +5800,15 @@ Retrieve a list of all entities.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.get()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.pdf_templates.make_default_by_id(
+ document_template_id="document_template_id",
+)
```
@@ -5386,7 +5824,7 @@ client.entities.get()
-
-**order:** `typing.Optional[OrderEnum]` — Sort order (ascending by default). Typically used together with the `sort` parameter.
+**document_template_id:** `str`
@@ -5394,91 +5832,111 @@ client.entities.get()
-
-**limit:** `typing.Optional[int]` — The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
-
--
-
-**pagination_token:** `typing.Optional[str]`
-
-A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
-If not specified, the first page of results will be returned.
-
+
+## E-invoicing connections
+client.e_invoicing_connections.get_einvoicing_connections()
-
-**sort:** `typing.Optional[EntityCursorFields]` — The field to sort the results by. Typically used together with the `order` parameter.
-
-
-
+#### 🔌 Usage
-
-**type:** `typing.Optional[EntityTypeEnum]`
-
-
-
-
-
-**created_at_gt:** `typing.Optional[dt.datetime]`
-
+```python
+from monite import Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.e_invoicing_connections.get_einvoicing_connections()
+
+```
+
+
+
+#### ⚙️ Parameters
-
-**created_at_lt:** `typing.Optional[dt.datetime]`
-
-
-
-
-
-**created_at_gte:** `typing.Optional[dt.datetime]`
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
-
--
-**created_at_lte:** `typing.Optional[dt.datetime]`
-
+
+client.e_invoicing_connections.post_einvoicing_connections(...)
-
-**id_in:** `typing.Optional[typing.Union[str, typing.Sequence[str]]]`
-
-
-
+#### 🔌 Usage
-
-**id_not_in:** `typing.Optional[typing.Union[str, typing.Sequence[str]]]`
-
+
+-
+
+```python
+from monite import EinvoicingAddress, Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.e_invoicing_connections.post_einvoicing_connections(
+ address=EinvoicingAddress(
+ address_line1="address_line1",
+ city="city",
+ country="DE",
+ postal_code="postal_code",
+ ),
+)
+
+```
+
+
+#### ⚙️ Parameters
+
-
-**email:** `typing.Optional[str]`
+
+-
+
+**address:** `EinvoicingAddress` — Integration Address
@@ -5486,7 +5944,7 @@ If not specified, the first page of results will be returned.
-
-**email_in:** `typing.Optional[typing.Union[str, typing.Sequence[str]]]`
+**entity_vat_id_id:** `typing.Optional[str]` — Entity VAT ID identifier for the integration
@@ -5494,7 +5952,7 @@ If not specified, the first page of results will be returned.
-
-**email_not_in:** `typing.Optional[typing.Union[str, typing.Sequence[str]]]`
+**is_receiver:** `typing.Optional[bool]` — Set to `true` if the entity needs to receive e-invoices.
@@ -5502,7 +5960,7 @@ If not specified, the first page of results will be returned.
-
-**status:** `typing.Optional[EntityStatusEnum]`
+**is_sender:** `typing.Optional[bool]` — Set to `true` if the entity needs to send e-invoices. Either `is_sender` or `is_receiver` or both must be `true`.
@@ -5522,24 +5980,10 @@ If not specified, the first page of results will be returned.
-client.entities.create(...)
-
--
-
-#### 📝 Description
-
-
--
-
+
client.e_invoicing_connections.get_einvoicing_connections_id(...)
-
-Create a new entity from the specified values.
-
-
-
-
-
#### 🔌 Usage
@@ -5550,9 +5994,15 @@ Create a new entity from the specified values.
```python
from monite import Monite
-from monite import EntityAddressSchema
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.create(address=EntityAddressSchema(city='city', country="AF", line1='line1', postal_code='postal_code', ), email='email', type="individual", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.e_invoicing_connections.get_einvoicing_connections_id(
+ einvoicing_connection_id="einvoicing_connection_id",
+)
```
@@ -5568,7 +6018,7 @@ client.entities.create(address=EntityAddressSchema(city='city', country="AF", li
-
-**address:** `EntityAddressSchema` — An address description of the entity
+**einvoicing_connection_id:** `str`
@@ -5576,31 +6026,57 @@ client.entities.create(address=EntityAddressSchema(city='city', country="AF", li
-
-**email:** `str` — An official email address of the entity
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
-
--
-**type:** `EntityTypeEnum` — A type for an entity
-
+
+client.e_invoicing_connections.delete_einvoicing_connections_id(...)
-
-**phone:** `typing.Optional[str]` — The contact phone number of the entity. Required for US organizations to use payments.
-
+#### 🔌 Usage
+
+
+-
+
+
+-
+
+```python
+from monite import Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.e_invoicing_connections.delete_einvoicing_connections_id(
+ einvoicing_connection_id="einvoicing_connection_id",
+)
+
+```
+
+
+#### ⚙️ Parameters
+
-
-**website:** `typing.Optional[str]` — A website of the entity
+
+-
+
+**einvoicing_connection_id:** `str`
@@ -5608,15 +6084,57 @@ client.entities.create(address=EntityAddressSchema(city='city', country="AF", li
-
-**organization:** `typing.Optional[OrganizationSchema]` — A set of meta data describing the organization
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
+
+
+
+
+
+
+client.e_invoicing_connections.patch_einvoicing_connections_id(...)
+
+-
+
+#### 🔌 Usage
+
+
+-
+
+
+-
+
+```python
+from monite import Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.e_invoicing_connections.patch_einvoicing_connections_id(
+ einvoicing_connection_id="einvoicing_connection_id",
+)
+
+```
+
+
+
+
+
+#### ⚙️ Parameters
-
-**individual:** `typing.Optional[IndividualSchema]` — A set of meta data describing the individual
+
+-
+
+**einvoicing_connection_id:** `str`
@@ -5624,7 +6142,7 @@ client.entities.create(address=EntityAddressSchema(city='city', country="AF", li
-
-**tax_id:** `typing.Optional[str]` — The entity's taxpayer identification number or tax ID. This field is required for entities that are non-VAT registered.
+**address:** `typing.Optional[UpdateEinvoicingAddress]` — Integration Address
@@ -5632,7 +6150,7 @@ client.entities.create(address=EntityAddressSchema(city='city', country="AF", li
-
-**registration_number:** `typing.Optional[str]` — (Germany only) The entity's commercial register number (_Handelsregisternummer_) in the German Commercial Register, if available.
+**is_receiver:** `typing.Optional[bool]` — Set to `true` if the entity needs to receive e-invoices.
@@ -5640,7 +6158,7 @@ client.entities.create(address=EntityAddressSchema(city='city', country="AF", li
-
-**registration_authority:** `typing.Optional[str]` — (Germany only) The name of the local district court (_Amtsgericht_) where the entity is registered. Required if `registration_number` is provided.
+**is_sender:** `typing.Optional[bool]` — Set to `true` if the entity needs to send e-invoices. Either `is_sender` or `is_receiver` or both must be `true`.
@@ -5660,11 +6178,11 @@ client.entities.create(address=EntityAddressSchema(city='city', country="AF", li
-client.entities.get_entities_me()
+client.e_invoicing_connections.post_einvoicing_connections_id_network_credentials(...)
-
-#### 📝 Description
+#### 🔌 Usage
-
@@ -5672,13 +6190,27 @@ client.entities.create(address=EntityAddressSchema(city='city', country="AF", li
-
-Deprecated. Use `GET /entity_users/my_entity` instead.
+```python
+from monite import Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.e_invoicing_connections.post_einvoicing_connections_id_network_credentials(
+ einvoicing_connection_id="einvoicing_connection_id",
+ network_credentials_identifier="12345678",
+ network_credentials_schema="DE:VAT",
+)
+
+```
-#### 🔌 Usage
+#### ⚙️ Parameters
-
@@ -5686,22 +6218,27 @@ Deprecated. Use `GET /entity_users/my_entity` instead.
-
-```python
-from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.get_entities_me()
-
-```
+**einvoicing_connection_id:** `str`
+
+
+
+-
+
+**network_credentials_identifier:** `str` — Network participant identifier
+
-#### ⚙️ Parameters
-
-
+**network_credentials_schema:** `EinvoiceSchemaTypeEnum` — Network scheme identifier
+
+
+
+
-
@@ -5717,7 +6254,8 @@ client.entities.get_entities_me()
-client.entities.patch_entities_me(...)
+## Entities
+client.entities.get(...)
-
@@ -5729,7 +6267,7 @@ client.entities.get_entities_me()
-
-Deprecated. Use `PATCH /entity_users/my_entity` instead.
+Retrieve a list of all entities.
@@ -5745,8 +6283,13 @@ Deprecated. Use `PATCH /entity_users/my_entity` instead.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.patch_entities_me()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.get()
```
@@ -5762,7 +6305,7 @@ client.entities.patch_entities_me()
-
-**address:** `typing.Optional[UpdateEntityAddressSchema]` — An address description of the entity
+**order:** `typing.Optional[OrderEnum]` — Sort order (ascending by default). Typically used together with the `sort` parameter.
@@ -5770,7 +6313,7 @@ client.entities.patch_entities_me()
-
-**email:** `typing.Optional[str]` — An official email address of the entity
+**limit:** `typing.Optional[int]` — The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
@@ -5778,7 +6321,11 @@ client.entities.patch_entities_me()
-
-**phone:** `typing.Optional[str]` — The contact phone number of the entity. Required for US organizations to use payments.
+**pagination_token:** `typing.Optional[str]`
+
+A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+
+If not specified, the first page of results will be returned.
@@ -5786,7 +6333,7 @@ client.entities.patch_entities_me()
-
-**website:** `typing.Optional[str]` — A website of the entity
+**sort:** `typing.Optional[EntityCursorFields]` — The field to sort the results by. Typically used together with the `order` parameter.
@@ -5794,7 +6341,7 @@ client.entities.patch_entities_me()
-
-**tax_id:** `typing.Optional[str]` — The entity's taxpayer identification number or tax ID. This field is required for entities that are non-VAT registered.
+**type:** `typing.Optional[EntityTypeEnum]`
@@ -5802,7 +6349,7 @@ client.entities.patch_entities_me()
-
-**registration_number:** `typing.Optional[str]` — (Germany only) The entity's commercial register number (_Handelsregisternummer_) in the German Commercial Register, if available.
+**created_at_gt:** `typing.Optional[dt.datetime]`
@@ -5810,7 +6357,7 @@ client.entities.patch_entities_me()
-
-**registration_authority:** `typing.Optional[str]` — (Germany only) The name of the local district court (_Amtsgericht_) where the entity is registered. Required if `registration_number` is provided.
+**created_at_lt:** `typing.Optional[dt.datetime]`
@@ -5818,7 +6365,7 @@ client.entities.patch_entities_me()
-
-**organization:** `typing.Optional[OptionalOrganizationSchema]` — A set of meta data describing the organization
+**created_at_gte:** `typing.Optional[dt.datetime]`
@@ -5826,7 +6373,7 @@ client.entities.patch_entities_me()
-
-**individual:** `typing.Optional[OptionalIndividualSchema]` — A set of meta data describing the individual
+**created_at_lte:** `typing.Optional[dt.datetime]`
@@ -5834,64 +6381,47 @@ client.entities.patch_entities_me()
-
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+**id_in:** `typing.Optional[typing.Union[str, typing.Sequence[str]]]`
-
-
+
+-
+**id_not_in:** `typing.Optional[typing.Union[str, typing.Sequence[str]]]`
+
-
-client.entities.get_by_id(...)
-
-#### 📝 Description
-
-
--
+**email:** `typing.Optional[str]`
+
+
+
-
-Retrieve an entity by its ID.
-
-
+**email_in:** `typing.Optional[typing.Union[str, typing.Sequence[str]]]`
+
-#### 🔌 Usage
-
-
--
-
-
-```python
-from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.get_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
-
-```
-
-
+**email_not_in:** `typing.Optional[typing.Union[str, typing.Sequence[str]]]`
+
-#### ⚙️ Parameters
-
-
--
-
-
-**entity_id:** `str` — A unique ID to specify the entity.
+**status:** `typing.Optional[EntityStatusEnum]`
@@ -5911,7 +6441,7 @@ client.entities.get_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
-client.entities.update_by_id(...)
+client.entities.create(...)
-
@@ -5923,7 +6453,7 @@ client.entities.get_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
-
-Change the specified fields with the provided values.
+Create a new entity from the specified values.
@@ -5938,9 +6468,23 @@ Change the specified fields with the provided values.
-
```python
-from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.update_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
+from monite import EntityAddressSchema, Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.create(
+ address=EntityAddressSchema(
+ city="city",
+ country="AF",
+ line1="line1",
+ postal_code="postal_code",
+ ),
+ email="email",
+ type="individual",
+)
```
@@ -5956,7 +6500,7 @@ client.entities.update_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
-
-**entity_id:** `str` — A unique ID to specify the entity.
+**address:** `EntityAddressSchema` — An address description of the entity
@@ -5964,7 +6508,7 @@ client.entities.update_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
-
-**address:** `typing.Optional[UpdateEntityAddressSchema]` — An address description of the entity
+**email:** `str` — An official email address of the entity
@@ -5972,7 +6516,7 @@ client.entities.update_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
-
-**email:** `typing.Optional[str]` — An official email address of the entity
+**type:** `EntityTypeEnum` — A type for an entity
@@ -5996,7 +6540,7 @@ client.entities.update_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
-
-**tax_id:** `typing.Optional[str]` — The entity's taxpayer identification number or tax ID. This field is required for entities that are non-VAT registered.
+**organization:** `typing.Optional[OrganizationSchema]` — A set of meta data describing the organization
@@ -6004,7 +6548,7 @@ client.entities.update_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
-
-**registration_number:** `typing.Optional[str]` — (Germany only) The entity's commercial register number (_Handelsregisternummer_) in the German Commercial Register, if available.
+**individual:** `typing.Optional[IndividualSchema]` — A set of meta data describing the individual
@@ -6012,7 +6556,7 @@ client.entities.update_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
-
-**registration_authority:** `typing.Optional[str]` — (Germany only) The name of the local district court (_Amtsgericht_) where the entity is registered. Required if `registration_number` is provided.
+**tax_id:** `typing.Optional[str]` — The entity's taxpayer identification number or tax ID. This field is required for entities that are non-VAT registered.
@@ -6020,7 +6564,7 @@ client.entities.update_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
-
-**organization:** `typing.Optional[OptionalOrganizationSchema]` — A set of meta data describing the organization
+**registration_number:** `typing.Optional[str]` — (Germany only) The entity's commercial register number (_Handelsregisternummer_) in the German Commercial Register, if available.
@@ -6028,7 +6572,7 @@ client.entities.update_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
-
-**individual:** `typing.Optional[OptionalIndividualSchema]` — A set of meta data describing the individual
+**registration_authority:** `typing.Optional[str]` — (Germany only) The name of the local district court (_Amtsgericht_) where the entity is registered. Required if `registration_number` is provided.
@@ -6048,7 +6592,7 @@ client.entities.update_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
-client.entities.post_entities_id_activate(...)
+client.entities.get_entities_me()
-
@@ -6060,7 +6604,7 @@ client.entities.update_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
-
-Activate an entity to allow it to perform any operations.
+Deprecated. Use `GET /entity_users/my_entity` instead.
@@ -6076,8 +6620,13 @@ Activate an entity to allow it to perform any operations.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.post_entities_id_activate(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.get_entities_me()
```
@@ -6093,14 +6642,6 @@ client.entities.post_entities_id_activate(entity_id='ea837e28-509b-4b6a-a600-d54
-
-**entity_id:** `str` — A unique ID to specify the entity.
-
-
-
-
-
--
-
**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -6113,7 +6654,7 @@ client.entities.post_entities_id_activate(entity_id='ea837e28-509b-4b6a-a600-d54
-client.entities.post_entities_id_deactivate(...)
+client.entities.patch_entities_me(...)
-
@@ -6125,7 +6666,7 @@ client.entities.post_entities_id_activate(entity_id='ea837e28-509b-4b6a-a600-d54
-
-Deactivate an entity to stop it from performing any operations.
+Deprecated. Use `PATCH /entity_users/my_entity` instead.
@@ -6141,8 +6682,13 @@ Deactivate an entity to stop it from performing any operations.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.post_entities_id_deactivate(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.patch_entities_me()
```
@@ -6158,7 +6704,7 @@ client.entities.post_entities_id_deactivate(entity_id='ea837e28-509b-4b6a-a600-d
-
-**entity_id:** `str` — A unique ID to specify the entity.
+**address:** `typing.Optional[UpdateEntityAddressSchema]` — An address description of the entity
@@ -6166,64 +6712,47 @@ client.entities.post_entities_id_deactivate(entity_id='ea837e28-509b-4b6a-a600-d
-
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+**email:** `typing.Optional[str]` — An official email address of the entity
-
-
+
+-
+**phone:** `typing.Optional[str]` — The contact phone number of the entity. Required for US organizations to use payments.
+
-
-client.entities.upload_logo_by_id(...)
-
-#### 📝 Description
-
-
--
+**website:** `typing.Optional[str]` — A website of the entity
+
+
+
-
-Entity logo can be PNG, JPG, or GIF, up to 10 MB in size. The logo is used, for example, in PDF documents created by this entity.
-
-
+**tax_id:** `typing.Optional[str]` — The entity's taxpayer identification number or tax ID. This field is required for entities that are non-VAT registered.
+
-#### 🔌 Usage
-
-
--
-
-
-```python
-from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.upload_logo_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
-
-```
-
-
+**registration_number:** `typing.Optional[str]` — (Germany only) The entity's commercial register number (_Handelsregisternummer_) in the German Commercial Register, if available.
+
-#### ⚙️ Parameters
-
-
--
-
-
-**entity_id:** `str` — A unique ID to specify the entity.
+**registration_authority:** `typing.Optional[str]` — (Germany only) The name of the local district court (_Amtsgericht_) where the entity is registered. Required if `registration_number` is provided.
@@ -6231,8 +6760,15 @@ client.entities.upload_logo_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f
-
-**file:** `from __future__ import annotations
-core.File` — See core.File for more documentation
+**organization:** `typing.Optional[OptionalOrganizationSchema]` — A set of meta data describing the organization
+
+
+
+
+
+-
+
+**individual:** `typing.Optional[OptionalIndividualSchema]` — A set of meta data describing the individual
@@ -6252,10 +6788,24 @@ core.File` — See core.File for more documentation
-client.entities.delete_logo_by_id(...)
+client.entities.get_by_id(...)
+
+-
+
+#### 📝 Description
+
+
+-
+
-
+Retrieve an entity by its ID.
+
+
+
+
+
#### 🔌 Usage
@@ -6266,8 +6816,15 @@ core.File` — See core.File for more documentation
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.delete_logo_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.get_by_id(
+ entity_id="ea837e28-509b-4b6a-a600-d54b6aa0b1f5",
+)
```
@@ -6303,7 +6860,7 @@ client.entities.delete_logo_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f
-client.entities.get_partner_metadata_by_id(...)
+client.entities.update_by_id(...)
-
@@ -6315,7 +6872,7 @@ client.entities.delete_logo_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f
-
-Retrieve a metadata object associated with this entity, usually in a JSON format.
+Change the specified fields with the provided values.
@@ -6331,8 +6888,15 @@ Retrieve a metadata object associated with this entity, usually in a JSON format
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.get_partner_metadata_by_id(entity_id='entity_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.update_by_id(
+ entity_id="ea837e28-509b-4b6a-a600-d54b6aa0b1f5",
+)
```
@@ -6348,7 +6912,7 @@ client.entities.get_partner_metadata_by_id(entity_id='entity_id', )
-
-**entity_id:** `str`
+**entity_id:** `str` — A unique ID to specify the entity.
@@ -6356,65 +6920,63 @@ client.entities.get_partner_metadata_by_id(entity_id='entity_id', )
-
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+**address:** `typing.Optional[UpdateEntityAddressSchema]` — An address description of the entity
-
-
+
+-
+**email:** `typing.Optional[str]` — An official email address of the entity
+
-
-client.entities.update_partner_metadata_by_id(...)
-
-#### 📝 Description
-
-
--
+**phone:** `typing.Optional[str]` — The contact phone number of the entity. Required for US organizations to use payments.
+
+
+
-
-Fully replace the current metadata object with the specified instance.
-
-
+**website:** `typing.Optional[str]` — A website of the entity
+
-#### 🔌 Usage
-
-
+**tax_id:** `typing.Optional[str]` — The entity's taxpayer identification number or tax ID. This field is required for entities that are non-VAT registered.
+
+
+
+
-
-```python
-from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.update_partner_metadata_by_id(entity_id='entity_id', metadata={'key': 'value'
-}, )
-
-```
-
-
+**registration_number:** `typing.Optional[str]` — (Germany only) The entity's commercial register number (_Handelsregisternummer_) in the German Commercial Register, if available.
+
-#### ⚙️ Parameters
-
-
+**registration_authority:** `typing.Optional[str]` — (Germany only) The name of the local district court (_Amtsgericht_) where the entity is registered. Required if `registration_number` is provided.
+
+
+
+
-
-**entity_id:** `str`
+**organization:** `typing.Optional[OptionalOrganizationSchema]` — A set of meta data describing the organization
@@ -6422,7 +6984,7 @@ client.entities.update_partner_metadata_by_id(entity_id='entity_id', metadata={'
-
-**metadata:** `typing.Dict[str, typing.Optional[typing.Any]]` — Metadata for partner needs
+**individual:** `typing.Optional[OptionalIndividualSchema]` — A set of meta data describing the individual
@@ -6442,7 +7004,7 @@ client.entities.update_partner_metadata_by_id(entity_id='entity_id', metadata={'
-client.entities.get_settings_by_id(...)
+client.entities.post_entities_id_activate(...)
-
@@ -6454,7 +7016,7 @@ client.entities.update_partner_metadata_by_id(entity_id='entity_id', metadata={'
-
-Retrieve all settings for this entity.
+Activate an entity to allow it to perform any operations.
@@ -6470,8 +7032,15 @@ Retrieve all settings for this entity.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.get_settings_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.post_entities_id_activate(
+ entity_id="ea837e28-509b-4b6a-a600-d54b6aa0b1f5",
+)
```
@@ -6507,7 +7076,7 @@ client.entities.get_settings_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1
-client.entities.update_settings_by_id(...)
+client.entities.post_entities_id_deactivate(...)
-
@@ -6519,7 +7088,7 @@ client.entities.get_settings_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1
-
-Change the specified fields with the provided values.
+Deactivate an entity to stop it from performing any operations.
@@ -6535,8 +7104,15 @@ Change the specified fields with the provided values.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.update_settings_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.post_entities_id_deactivate(
+ entity_id="ea837e28-509b-4b6a-a600-d54b6aa0b1f5",
+)
```
@@ -6560,55 +7136,71 @@ client.entities.update_settings_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa
-
-**language:** `typing.Optional[LanguageCodeEnum]`
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
-
--
-**currency:** `typing.Optional[CurrencySettingsInput]`
-
+
+client.entities.upload_logo_by_id(...)
-
-**reminder:** `typing.Optional[RemindersSettings]`
-
-
-
+#### 📝 Description
-
-**vat_mode:** `typing.Optional[VatModeEnum]` — Defines whether the prices of products in receivables will already include VAT or not.
-
-
-
-
-
-**vat_inclusive_discount_mode:** `typing.Optional[VatModeEnum]` — Defines whether the amount discounts (for percentage discounts it does not matter) on VAT inclusive invoices will be applied on amounts including VAT or excluding VAT.
-
+Entity logo can be PNG, JPG, or GIF, up to 10 MB in size. The logo is used, for example, in PDF documents created by this entity.
+
+
+
+#### 🔌 Usage
-
-**payment_priority:** `typing.Optional[PaymentPriorityEnum]` — Payment preferences for entity to automate calculating suggested payment date based on payment terms and entity preferences.
-
+
+-
+
+```python
+from monite import Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.upload_logo_by_id(
+ entity_id="ea837e28-509b-4b6a-a600-d54b6aa0b1f5",
+)
+
+```
+
+
+#### ⚙️ Parameters
+
-
-**allow_purchase_order_autolinking:** `typing.Optional[bool]` — Automatically attempt to find a corresponding purchase order for all incoming payables.
+
+-
+
+**entity_id:** `str` — A unique ID to specify the entity.
@@ -6616,7 +7208,9 @@ client.entities.update_settings_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa
-
-**receivable_edit_flow:** `typing.Optional[ReceivableEditFlow]`
+**file:** `from __future__ import annotations
+
+core.File` — See core.File for more documentation
@@ -6624,61 +7218,57 @@ client.entities.update_settings_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa
-
-**document_ids:** `typing.Optional[DocumentIDsSettingsRequest]`
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
-
--
-**payables_ocr_auto_tagging:** `typing.Optional[typing.Sequence[OcrAutoTaggingSettingsRequest]]` — Auto tagging settings for all incoming OCR payable documents.
-
+
+client.entities.delete_logo_by_id(...)
-
-**quote_signature_required:** `typing.Optional[bool]` — Sets the default behavior of whether a signature is required to accept quotes.
-
-
-
+#### 🔌 Usage
-
-**generate_paid_invoice_pdf:** `typing.Optional[bool]`
+
+-
-This setting affects how PDF is generated for paid accounts receivable invoices. If set to `true`, once an invoice is fully paid its PDF version is updated to display the amount paid and the payment-related features are removed.
+```python
+from monite import Monite
-The PDF file gets regenerated at the moment when an invoice becomes paid. It is not issued as a separate document, and the original PDF invoice is no longer available.
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.delete_logo_by_id(
+ entity_id="ea837e28-509b-4b6a-a600-d54b6aa0b1f5",
+)
-This field is deprecated and will be replaced by `document_rendering.invoice.generate_paid_invoice_pdf`.
-
+```
-
-
--
-
-**accounting:** `typing.Optional[AccountingSettings]`
-
+#### ⚙️ Parameters
+
-
-**payables_skip_approval_flow:** `typing.Optional[bool]` — If enabled, the approval policy will be skipped and the payable will be moved to `waiting_to_be_paid` status.
-
-
-
-
-
-**document_rendering:** `typing.Optional[DocumentRenderingSettings]` — Settings for rendering documents in PDF format.
+**entity_id:** `str` — A unique ID to specify the entity.
@@ -6698,7 +7288,7 @@ This field is deprecated and will be replaced by `document_rendering.invoice.gen
-client.entities.upload_onboarding_documents(...)
+client.entities.get_partner_metadata_by_id(...)
-
@@ -6710,7 +7300,7 @@ This field is deprecated and will be replaced by `document_rendering.invoice.gen
-
-Provide files for entity onboarding verification
+Retrieve a metadata object associated with this entity, usually in a JSON format.
@@ -6726,8 +7316,15 @@ Provide files for entity onboarding verification
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.upload_onboarding_documents()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.get_partner_metadata_by_id(
+ entity_id="entity_id",
+)
```
@@ -6743,7 +7340,7 @@ client.entities.upload_onboarding_documents()
-
-**additional_verification_document_back:** `typing.Optional[str]`
+**entity_id:** `str`
@@ -6751,71 +7348,72 @@ client.entities.upload_onboarding_documents()
-
-**additional_verification_document_front:** `typing.Optional[str]`
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
-
--
-**bank_account_ownership_verification:** `typing.Optional[typing.Sequence[str]]`
-
+
+client.entities.update_partner_metadata_by_id(...)
-
-**company_license:** `typing.Optional[typing.Sequence[str]]`
-
-
-
+#### 📝 Description
-
-**company_memorandum_of_association:** `typing.Optional[typing.Sequence[str]]`
-
-
-
-
-
-**company_ministerial_decree:** `typing.Optional[typing.Sequence[str]]`
-
+Fully replace the current metadata object with the specified instance.
+
+
+#### 🔌 Usage
+
-
-**company_registration_verification:** `typing.Optional[typing.Sequence[str]]`
-
-
-
-
-
-**company_tax_id_verification:** `typing.Optional[typing.Sequence[str]]`
-
+```python
+from monite import Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.update_partner_metadata_by_id(
+ entity_id="entity_id",
+ metadata={"key": "value"},
+)
+
+```
+
+
+#### ⚙️ Parameters
+
-
-**proof_of_registration:** `typing.Optional[typing.Sequence[str]]`
-
-
-
-
-
-**verification_document_back:** `typing.Optional[str]`
+**entity_id:** `str`
@@ -6823,7 +7421,7 @@ client.entities.upload_onboarding_documents()
-
-**verification_document_front:** `typing.Optional[str]`
+**metadata:** `typing.Dict[str, typing.Optional[typing.Any]]` — Metadata for partner needs
@@ -6843,7 +7441,7 @@ client.entities.upload_onboarding_documents()
-client.entities.get_onboarding_requirements()
+client.entities.get_settings_by_id(...)
-
@@ -6855,7 +7453,7 @@ client.entities.upload_onboarding_documents()
-
-Get onboarding requirements for the entity
+Retrieve all settings for this entity.
@@ -6871,8 +7469,15 @@ Get onboarding requirements for the entity
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.get_onboarding_requirements()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.get_settings_by_id(
+ entity_id="ea837e28-509b-4b6a-a600-d54b6aa0b1f5",
+)
```
@@ -6888,20 +7493,27 @@ client.entities.get_onboarding_requirements()
-
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+**entity_id:** `str` — A unique ID to specify the entity.
-
-
+
+-
-
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
+
+
+
+
+
+
-## Entity users
-client.entity_users.get(...)
+client.entities.update_settings_by_id(...)
-
@@ -6913,7 +7525,7 @@ client.entities.get_onboarding_requirements()
-
-Retrieve a list of all entity users.
+Change the specified fields with the provided values.
@@ -6929,8 +7541,15 @@ Retrieve a list of all entity users.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entity_users.get()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.update_settings_by_id(
+ entity_id="ea837e28-509b-4b6a-a600-d54b6aa0b1f5",
+)
```
@@ -6946,7 +7565,7 @@ client.entity_users.get()
-
-**order:** `typing.Optional[OrderEnum]` — Sort order (ascending by default). Typically used together with the `sort` parameter.
+**entity_id:** `str` — A unique ID to specify the entity.
@@ -6954,7 +7573,7 @@ client.entity_users.get()
-
-**limit:** `typing.Optional[int]` — The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+**language:** `typing.Optional[LanguageCodeEnum]`
@@ -6962,11 +7581,7 @@ client.entity_users.get()
-
-**pagination_token:** `typing.Optional[str]`
-
-A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
-
-If not specified, the first page of results will be returned.
+**currency:** `typing.Optional[CurrencySettingsInput]`
@@ -6974,7 +7589,7 @@ If not specified, the first page of results will be returned.
-
-**sort:** `typing.Optional[EntityUserCursorFields]` — The field to sort the results by. Typically used together with the `order` parameter.
+**reminder:** `typing.Optional[RemindersSettings]`
@@ -6982,7 +7597,7 @@ If not specified, the first page of results will be returned.
-
-**id_in:** `typing.Optional[typing.Union[str, typing.Sequence[str]]]`
+**vat_mode:** `typing.Optional[VatModeEnum]` — Defines whether the prices of products in receivables will already include VAT or not.
@@ -6990,7 +7605,7 @@ If not specified, the first page of results will be returned.
-
-**id_not_in:** `typing.Optional[typing.Union[str, typing.Sequence[str]]]`
+**vat_inclusive_discount_mode:** `typing.Optional[VatModeEnum]` — Defines whether the amount discounts (for percentage discounts it does not matter) on VAT inclusive invoices will be applied on amounts including VAT or excluding VAT.
@@ -6998,7 +7613,7 @@ If not specified, the first page of results will be returned.
-
-**role_id:** `typing.Optional[str]`
+**payment_priority:** `typing.Optional[PaymentPriorityEnum]` — Payment preferences for entity to automate calculating suggested payment date based on payment terms and entity preferences.
@@ -7006,7 +7621,7 @@ If not specified, the first page of results will be returned.
-
-**role_id_in:** `typing.Optional[typing.Union[str, typing.Sequence[str]]]`
+**allow_purchase_order_autolinking:** `typing.Optional[bool]` — Automatically attempt to find a corresponding purchase order for all incoming payables.
@@ -7014,7 +7629,7 @@ If not specified, the first page of results will be returned.
-
-**login:** `typing.Optional[str]`
+**receivable_edit_flow:** `typing.Optional[ReceivableEditFlow]`
@@ -7022,7 +7637,7 @@ If not specified, the first page of results will be returned.
-
-**status:** `typing.Optional[str]`
+**document_ids:** `typing.Optional[DocumentIDsSettingsRequest]`
@@ -7030,7 +7645,7 @@ If not specified, the first page of results will be returned.
-
-**first_name:** `typing.Optional[str]`
+**payables_ocr_auto_tagging:** `typing.Optional[typing.Sequence[OcrAutoTaggingSettingsRequest]]` — Auto tagging settings for all incoming OCR payable documents.
@@ -7038,7 +7653,7 @@ If not specified, the first page of results will be returned.
-
-**name_istartswith:** `typing.Optional[str]`
+**quote_signature_required:** `typing.Optional[bool]` — Sets the default behavior of whether a signature is required to accept quotes.
@@ -7046,7 +7661,13 @@ If not specified, the first page of results will be returned.
-
-**created_at_gt:** `typing.Optional[dt.datetime]`
+**generate_paid_invoice_pdf:** `typing.Optional[bool]`
+
+This setting affects how PDF is generated for paid accounts receivable invoices. If set to `true`, once an invoice is fully paid its PDF version is updated to display the amount paid and the payment-related features are removed.
+
+The PDF file gets regenerated at the moment when an invoice becomes paid. It is not issued as a separate document, and the original PDF invoice is no longer available.
+
+This field is deprecated and will be replaced by `document_rendering.invoice.generate_paid_invoice_pdf`.
@@ -7054,7 +7675,7 @@ If not specified, the first page of results will be returned.
-
-**created_at_lt:** `typing.Optional[dt.datetime]`
+**accounting:** `typing.Optional[AccountingSettings]`
@@ -7062,7 +7683,7 @@ If not specified, the first page of results will be returned.
-
-**created_at_gte:** `typing.Optional[dt.datetime]`
+**payables_skip_approval_flow:** `typing.Optional[bool]` — If enabled, the approval policy will be skipped and the payable will be moved to `waiting_to_be_paid` status.
@@ -7070,7 +7691,7 @@ If not specified, the first page of results will be returned.
-
-**created_at_lte:** `typing.Optional[dt.datetime]`
+**document_rendering:** `typing.Optional[DocumentRenderingSettings]` — Settings for rendering documents in PDF format.
@@ -7090,7 +7711,7 @@ If not specified, the first page of results will be returned.
-client.entity_users.create(...)
+client.entities.upload_onboarding_documents(...)
-
@@ -7102,7 +7723,7 @@ If not specified, the first page of results will be returned.
-
-Create a new entity user from the specified values.
+Provide files for entity onboarding verification
@@ -7118,8 +7739,13 @@ Create a new entity user from the specified values.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entity_users.create(first_name='Casey', login='login', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.upload_onboarding_documents()
```
@@ -7135,7 +7761,7 @@ client.entity_users.create(first_name='Casey', login='login', )
-
-**first_name:** `str` — First name
+**additional_verification_document_back:** `typing.Optional[str]`
@@ -7143,7 +7769,7 @@ client.entity_users.create(first_name='Casey', login='login', )
-
-**login:** `str`
+**additional_verification_document_front:** `typing.Optional[str]`
@@ -7151,7 +7777,7 @@ client.entity_users.create(first_name='Casey', login='login', )
-
-**email:** `typing.Optional[str]` — An entity user business email
+**bank_account_ownership_verification:** `typing.Optional[typing.Sequence[str]]`
@@ -7159,7 +7785,7 @@ client.entity_users.create(first_name='Casey', login='login', )
-
-**last_name:** `typing.Optional[str]` — Last name
+**company_license:** `typing.Optional[typing.Sequence[str]]`
@@ -7167,7 +7793,7 @@ client.entity_users.create(first_name='Casey', login='login', )
-
-**phone:** `typing.Optional[str]` — An entity user phone number in the international format
+**company_memorandum_of_association:** `typing.Optional[typing.Sequence[str]]`
@@ -7175,7 +7801,7 @@ client.entity_users.create(first_name='Casey', login='login', )
-
-**role_id:** `typing.Optional[str]` — UUID of the role assigned to this entity user
+**company_ministerial_decree:** `typing.Optional[typing.Sequence[str]]`
@@ -7183,7 +7809,39 @@ client.entity_users.create(first_name='Casey', login='login', )
-
-**title:** `typing.Optional[str]` — Title
+**company_registration_verification:** `typing.Optional[typing.Sequence[str]]`
+
+
+
+
+
+-
+
+**company_tax_id_verification:** `typing.Optional[typing.Sequence[str]]`
+
+
+
+
+
+-
+
+**proof_of_registration:** `typing.Optional[typing.Sequence[str]]`
+
+
+
+
+
+-
+
+**verification_document_back:** `typing.Optional[str]`
+
+
+
+
+
+-
+
+**verification_document_front:** `typing.Optional[str]`
@@ -7203,7 +7861,7 @@ client.entity_users.create(first_name='Casey', login='login', )
-client.entity_users.get_current()
+client.entities.get_onboarding_requirements()
-
@@ -7215,7 +7873,7 @@ client.entity_users.create(first_name='Casey', login='login', )
-
-Retrieve an entity user by its ID.
+Get onboarding requirements for the entity
@@ -7231,8 +7889,13 @@ Retrieve an entity user by its ID.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entity_users.get_current()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.get_onboarding_requirements()
```
@@ -7260,7 +7923,8 @@ client.entity_users.get_current()
-client.entity_users.update_current(...)
+## Entity users
+client.entity_users.get(...)
-
@@ -7272,7 +7936,7 @@ client.entity_users.get_current()
-
-Change the specified fields with provided values.
+Retrieve a list of all entity users.
@@ -7288,8 +7952,13 @@ Change the specified fields with provided values.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entity_users.update_current()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entity_users.get()
```
@@ -7305,7 +7974,7 @@ client.entity_users.update_current()
-
-**email:** `typing.Optional[str]` — An entity user business email
+**order:** `typing.Optional[OrderEnum]` — Sort order (ascending by default). Typically used together with the `sort` parameter.
@@ -7313,7 +7982,7 @@ client.entity_users.update_current()
-
-**first_name:** `typing.Optional[str]` — First name
+**limit:** `typing.Optional[int]` — The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
@@ -7321,7 +7990,11 @@ client.entity_users.update_current()
-
-**last_name:** `typing.Optional[str]` — Last name
+**pagination_token:** `typing.Optional[str]`
+
+A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+
+If not specified, the first page of results will be returned.
@@ -7329,7 +8002,7 @@ client.entity_users.update_current()
-
-**phone:** `typing.Optional[str]` — An entity user phone number in the international format
+**sort:** `typing.Optional[EntityUserCursorFields]` — The field to sort the results by. Typically used together with the `order` parameter.
@@ -7337,7 +8010,7 @@ client.entity_users.update_current()
-
-**title:** `typing.Optional[str]` — Title
+**id_in:** `typing.Optional[typing.Union[str, typing.Sequence[str]]]`
@@ -7345,60 +8018,91 @@ client.entity_users.update_current()
-
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+**id_not_in:** `typing.Optional[typing.Union[str, typing.Sequence[str]]]`
+
+
+-
+
+**role_id:** `typing.Optional[str]`
+
+
+-
+**role_id_in:** `typing.Optional[typing.Union[str, typing.Sequence[str]]]`
+
-
-client.entity_users.get_current_entity()
-
-#### 📝 Description
+**login:** `typing.Optional[str]`
+
+
+
-
+**status:** `typing.Optional[str]`
+
+
+
+
-
-Retrieves information of an entity, which this entity user belongs to.
+**first_name:** `typing.Optional[str]`
+
+
+
+-
+
+**name_istartswith:** `typing.Optional[str]`
+
-#### 🔌 Usage
-
-
+**created_at_gt:** `typing.Optional[dt.datetime]`
+
+
+
+
-
-```python
-from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entity_users.get_current_entity()
-
-```
+**created_at_lt:** `typing.Optional[dt.datetime]`
+
+
+
+-
+
+**created_at_gte:** `typing.Optional[dt.datetime]`
+
-#### ⚙️ Parameters
-
-
+**created_at_lte:** `typing.Optional[dt.datetime]`
+
+
+
+
-
@@ -7414,7 +8118,7 @@ client.entity_users.get_current_entity()
-client.entity_users.update_current_entity(...)
+client.entity_users.create(...)
-
@@ -7426,7 +8130,7 @@ client.entity_users.get_current_entity()
-
-Update information of an entity, which this entity user belongs to.
+Create a new entity user from the specified values.
@@ -7442,8 +8146,16 @@ Update information of an entity, which this entity user belongs to.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entity_users.update_current_entity()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entity_users.create(
+ first_name="Casey",
+ login="login",
+)
```
@@ -7459,23 +8171,7 @@ client.entity_users.update_current_entity()
-
-**address:** `typing.Optional[UpdateEntityAddressSchema]` — An address description of the entity
-
-
-
-
-
--
-
-**email:** `typing.Optional[str]` — An official email address of the entity
-
-
-
-
-
--
-
-**phone:** `typing.Optional[str]` — The contact phone number of the entity. Required for US organizations to use payments.
+**first_name:** `str` — First name
@@ -7483,7 +8179,7 @@ client.entity_users.update_current_entity()
-
-**website:** `typing.Optional[str]` — A website of the entity
+**login:** `str`
@@ -7491,7 +8187,7 @@ client.entity_users.update_current_entity()
-
-**tax_id:** `typing.Optional[str]` — The entity's taxpayer identification number or tax ID. This field is required for entities that are non-VAT registered.
+**email:** `typing.Optional[str]` — An entity user business email
@@ -7499,7 +8195,7 @@ client.entity_users.update_current_entity()
-
-**registration_number:** `typing.Optional[str]` — (Germany only) The entity's commercial register number (_Handelsregisternummer_) in the German Commercial Register, if available.
+**last_name:** `typing.Optional[str]` — Last name
@@ -7507,7 +8203,7 @@ client.entity_users.update_current_entity()
-
-**registration_authority:** `typing.Optional[str]` — (Germany only) The name of the local district court (_Amtsgericht_) where the entity is registered. Required if `registration_number` is provided.
+**phone:** `typing.Optional[str]` — An entity user phone number in the international format
@@ -7515,7 +8211,7 @@ client.entity_users.update_current_entity()
-
-**organization:** `typing.Optional[OptionalOrganizationSchema]` — A set of meta data describing the organization
+**role_id:** `typing.Optional[str]` — UUID of the role assigned to this entity user
@@ -7523,7 +8219,7 @@ client.entity_users.update_current_entity()
-
-**individual:** `typing.Optional[OptionalIndividualSchema]` — A set of meta data describing the individual
+**title:** `typing.Optional[str]` — Title
@@ -7543,7 +8239,7 @@ client.entity_users.update_current_entity()
-client.entity_users.get_current_role()
+client.entity_users.get_current()
-
@@ -7555,7 +8251,7 @@ client.entity_users.update_current_entity()
-
-Retrieves information of a role assigned to this entity user.
+Retrieve an entity user by its ID.
@@ -7571,8 +8267,13 @@ Retrieves information of a role assigned to this entity user.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entity_users.get_current_role()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entity_users.get_current()
```
@@ -7600,7 +8301,7 @@ client.entity_users.get_current_role()
-client.entity_users.get_by_id(...)
+client.entity_users.update_current(...)
-
@@ -7612,7 +8313,7 @@ client.entity_users.get_current_role()
-
-Retrieve an entity user by its ID.
+Change the specified fields with provided values.
@@ -7628,8 +8329,13 @@ Retrieve an entity user by its ID.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entity_users.get_by_id(entity_user_id='entity_user_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entity_users.update_current()
```
@@ -7645,7 +8351,7 @@ client.entity_users.get_by_id(entity_user_id='entity_user_id', )
-
-**entity_user_id:** `str`
+**email:** `typing.Optional[str]` — An entity user business email
@@ -7653,50 +8359,31 @@ client.entity_users.get_by_id(entity_user_id='entity_user_id', )
-
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+**first_name:** `typing.Optional[str]` — First name
-
-
+
+-
+**last_name:** `typing.Optional[str]` — Last name
+
-
-
-client.entity_users.delete_by_id(...)
-
--
-
-#### 🔌 Usage
-
-
--
-
-```python
-from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entity_users.delete_by_id(entity_user_id='entity_user_id', )
-
-```
-
-
+**phone:** `typing.Optional[str]` — An entity user phone number in the international format
+
-#### ⚙️ Parameters
-
-
--
-
-
-**entity_user_id:** `str`
+**title:** `typing.Optional[str]` — Title
@@ -7716,7 +8403,7 @@ client.entity_users.delete_by_id(entity_user_id='entity_user_id', )
-client.entity_users.update_by_id(...)
+client.entity_users.get_current_entity()
-
@@ -7728,7 +8415,7 @@ client.entity_users.delete_by_id(entity_user_id='entity_user_id', )
-
-Change the specified fields with provided values.
+Retrieves information of an entity, which this entity user belongs to.
@@ -7744,8 +8431,13 @@ Change the specified fields with provided values.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entity_users.update_by_id(entity_user_id='entity_user_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entity_users.get_current_entity()
```
@@ -7761,70 +8453,6 @@ client.entity_users.update_by_id(entity_user_id='entity_user_id', )
-
-**entity_user_id:** `str`
-
-
-
-
-
--
-
-**email:** `typing.Optional[str]` — An entity user business email
-
-
-
-
-
--
-
-**first_name:** `typing.Optional[str]` — First name
-
-
-
-
-
--
-
-**last_name:** `typing.Optional[str]` — Last name
-
-
-
-
-
--
-
-**login:** `typing.Optional[str]` — Login
-
-
-
-
-
--
-
-**phone:** `typing.Optional[str]` — An entity user phone number in the international format
-
-
-
-
-
--
-
-**role_id:** `typing.Optional[str]` — UUID of the role assigned to this entity user
-
-
-
-
-
--
-
-**title:** `typing.Optional[str]` — Title
-
-
-
-
-
--
-
**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -7837,8 +8465,7 @@ client.entity_users.update_by_id(entity_user_id='entity_user_id', )
-## Events
-client.events.get(...)
+client.entity_users.update_current_entity(...)
-
@@ -7850,11 +8477,7 @@ client.entity_users.update_by_id(entity_user_id='entity_user_id', )
-
-Returns all webhook events that were triggered for the specified entity based on your enabled webhook subscriptions. These are the same events that were sent to your configured webhook listener endpoints, aggregated into a single list. Results can be filtered by the related object type or time period.
-
-You can use this to get the missed events for the time periods when your webhook listener was temporarily unavailable.
-
-We guarantee access to event data only from the last three months. Earlier events may be unavailable.
+Update information of an entity, which this entity user belongs to.
@@ -7870,8 +8493,13 @@ We guarantee access to event data only from the last three months. Earlier event
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.events.get()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entity_users.update_current_entity()
```
@@ -7887,7 +8515,7 @@ client.events.get()
-
-**order:** `typing.Optional[OrderEnum]` — Sort order (ascending by default). Typically used together with the `sort` parameter.
+**address:** `typing.Optional[UpdateEntityAddressSchema]` — An address description of the entity
@@ -7895,7 +8523,7 @@ client.events.get()
-
-**limit:** `typing.Optional[int]` — The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+**email:** `typing.Optional[str]` — An official email address of the entity
@@ -7903,11 +8531,7 @@ client.events.get()
-
-**pagination_token:** `typing.Optional[str]`
-
-A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
-
-If not specified, the first page of results will be returned.
+**phone:** `typing.Optional[str]` — The contact phone number of the entity. Required for US organizations to use payments.
@@ -7915,7 +8539,7 @@ If not specified, the first page of results will be returned.
-
-**sort:** `typing.Optional[EventCursorFields]` — The field to sort the results by. Typically used together with the `order` parameter.
+**website:** `typing.Optional[str]` — A website of the entity
@@ -7923,7 +8547,7 @@ If not specified, the first page of results will be returned.
-
-**object_type:** `typing.Optional[WebhookObjectType]`
+**tax_id:** `typing.Optional[str]` — The entity's taxpayer identification number or tax ID. This field is required for entities that are non-VAT registered.
@@ -7931,7 +8555,7 @@ If not specified, the first page of results will be returned.
-
-**created_at_gt:** `typing.Optional[dt.datetime]`
+**registration_number:** `typing.Optional[str]` — (Germany only) The entity's commercial register number (_Handelsregisternummer_) in the German Commercial Register, if available.
@@ -7939,7 +8563,7 @@ If not specified, the first page of results will be returned.
-
-**created_at_lt:** `typing.Optional[dt.datetime]`
+**registration_authority:** `typing.Optional[str]` — (Germany only) The name of the local district court (_Amtsgericht_) where the entity is registered. Required if `registration_number` is provided.
@@ -7947,7 +8571,7 @@ If not specified, the first page of results will be returned.
-
-**created_at_gte:** `typing.Optional[dt.datetime]`
+**organization:** `typing.Optional[OptionalOrganizationSchema]` — A set of meta data describing the organization
@@ -7955,7 +8579,7 @@ If not specified, the first page of results will be returned.
-
-**created_at_lte:** `typing.Optional[dt.datetime]`
+**individual:** `typing.Optional[OptionalIndividualSchema]` — A set of meta data describing the individual
@@ -7975,7 +8599,7 @@ If not specified, the first page of results will be returned.
-client.events.get_by_id(...)
+client.entity_users.get_current_role()
-
@@ -7987,7 +8611,7 @@ If not specified, the first page of results will be returned.
-
-Get a webhook event by its ID. The data is the same as you might have previously received in a webhook sent by Monite to your server.
+Retrieves information of a role assigned to this entity user.
@@ -8003,8 +8627,13 @@ Get a webhook event by its ID. The data is the same as you might have previously
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.events.get_by_id(event_id='event_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entity_users.get_current_role()
```
@@ -8020,14 +8649,6 @@ client.events.get_by_id(event_id='event_id', )
-
-**event_id:** `str` — ID of the webhook event. This is the `id` value you might have received in a webhook or retrieved from `GET /events`.
-
-
-
-
-
--
-
**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -8040,11 +8661,24 @@ client.events.get_by_id(event_id='event_id', )
-## Files
-client.files.get(...)
+client.entity_users.get_by_id(...)
+
+-
+
+#### 📝 Description
+
+
+-
+
-
+Retrieve an entity user by its ID.
+
+
+
+
+
#### 🔌 Usage
@@ -8055,8 +8689,15 @@ client.events.get_by_id(event_id='event_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.files.get()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entity_users.get_by_id(
+ entity_user_id="entity_user_id",
+)
```
@@ -8072,7 +8713,7 @@ client.files.get()
-
-**id_in:** `typing.Optional[typing.Union[str, typing.Sequence[str]]]`
+**entity_user_id:** `str`
@@ -8092,7 +8733,7 @@ client.files.get()
-client.files.upload(...)
+client.entity_users.delete_by_id(...)
-
@@ -8106,8 +8747,15 @@ client.files.get()
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.files.upload(file_type="ocr_results", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entity_users.delete_by_id(
+ entity_user_id="entity_user_id",
+)
```
@@ -8123,16 +8771,7 @@ client.files.upload(file_type="ocr_results", )
-
-**file:** `from __future__ import annotations
-core.File` — See core.File for more documentation
-
-
-
-
-
--
-
-**file_type:** `AllowedFileTypes`
+**entity_user_id:** `str`
@@ -8152,10 +8791,24 @@ core.File` — See core.File for more documentation
-client.files.get_by_id(...)
+client.entity_users.update_by_id(...)
+
+-
+
+#### 📝 Description
+
+
+-
+
-
+Change the specified fields with provided values.
+
+
+
+
+
#### 🔌 Usage
@@ -8166,8 +8819,15 @@ core.File` — See core.File for more documentation
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.files.get_by_id(file_id='file_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entity_users.update_by_id(
+ entity_user_id="entity_user_id",
+)
```
@@ -8183,7 +8843,7 @@ client.files.get_by_id(file_id='file_id', )
-
-**file_id:** `str`
+**entity_user_id:** `str`
@@ -8191,50 +8851,55 @@ client.files.get_by_id(file_id='file_id', )
-
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+**email:** `typing.Optional[str]` — An entity user business email
-
-
+
+-
+**first_name:** `typing.Optional[str]` — First name
+
-
-client.files.delete(...)
-
-#### 🔌 Usage
+**last_name:** `typing.Optional[str]` — Last name
+
+
+
-
+**login:** `typing.Optional[str]` — Login
+
+
+
+
-
-```python
-from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.files.delete(file_id='file_id', )
-
-```
-
-
+**phone:** `typing.Optional[str]` — An entity user phone number in the international format
+
-#### ⚙️ Parameters
-
-
+**role_id:** `typing.Optional[str]` — UUID of the role assigned to this entity user
+
+
+
+
-
-**file_id:** `str`
+**title:** `typing.Optional[str]` — Title
@@ -8254,8 +8919,8 @@ client.files.delete(file_id='file_id', )
-## Financing
-client.financing.get_financing_invoices(...)
+## Events
+client.events.get(...)
-
@@ -8267,7 +8932,11 @@ client.files.delete(file_id='file_id', )
-
-Returns a list of invoices requested for financing
+Returns all webhook events that were triggered for the specified entity based on your enabled webhook subscriptions. These are the same events that were sent to your configured webhook listener endpoints, aggregated into a single list. Results can be filtered by the related object type or time period.
+
+You can use this to get the missed events for the time periods when your webhook listener was temporarily unavailable.
+
+We guarantee access to event data only from the last three months. Earlier events may be unavailable.
@@ -8283,8 +8952,13 @@ Returns a list of invoices requested for financing
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.financing.get_financing_invoices()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.events.get()
```
@@ -8300,7 +8974,7 @@ client.financing.get_financing_invoices()
-
-**order:** `typing.Optional[OrderEnum]` — Order by
+**order:** `typing.Optional[OrderEnum]` — Sort order (ascending by default). Typically used together with the `sort` parameter.
@@ -8308,7 +8982,7 @@ client.financing.get_financing_invoices()
-
-**limit:** `typing.Optional[int]` — Max is 100
+**limit:** `typing.Optional[int]` — The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
@@ -8316,15 +8990,11 @@ client.financing.get_financing_invoices()
-
-**pagination_token:** `typing.Optional[str]` — A token, obtained from previous page. Prior over other filters
-
-
-
+**pagination_token:** `typing.Optional[str]`
-
--
+A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
-**sort:** `typing.Optional[FinancingInvoiceCursorFields]` — Allowed sort fields
+If not specified, the first page of results will be returned.
@@ -8332,7 +9002,7 @@ client.financing.get_financing_invoices()
-
-**invoice_id:** `typing.Optional[str]` — ID of a payable or receivable invoice.
+**sort:** `typing.Optional[EventCursorFields]` — The field to sort the results by. Typically used together with the `order` parameter.
@@ -8340,7 +9010,7 @@ client.financing.get_financing_invoices()
-
-**invoice_id_in:** `typing.Optional[typing.Union[str, typing.Sequence[str]]]` — List of invoice IDs.
+**object_type:** `typing.Optional[WebhookObjectType]`
@@ -8348,7 +9018,7 @@ client.financing.get_financing_invoices()
-
-**status:** `typing.Optional[WcInvoiceStatus]` — Status of the invoice.
+**created_at_gt:** `typing.Optional[dt.datetime]`
@@ -8356,7 +9026,7 @@ client.financing.get_financing_invoices()
-
-**status_in:** `typing.Optional[typing.Union[WcInvoiceStatus, typing.Sequence[WcInvoiceStatus]]]` — List of invoice statuses.
+**created_at_lt:** `typing.Optional[dt.datetime]`
@@ -8364,7 +9034,7 @@ client.financing.get_financing_invoices()
-
-**type:** `typing.Optional[FinancingInvoiceType]` — Type of the invoice. payable or receivable.
+**created_at_gte:** `typing.Optional[dt.datetime]`
@@ -8372,7 +9042,7 @@ client.financing.get_financing_invoices()
-
-**type_in:** `typing.Optional[typing.Union[FinancingInvoiceType, typing.Sequence[FinancingInvoiceType]]]` — List of invoice types.
+**created_at_lte:** `typing.Optional[dt.datetime]`
@@ -8380,95 +9050,71 @@ client.financing.get_financing_invoices()
-
-**document_id:** `typing.Optional[str]` — Document ID of the invoice.
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
-
-
--
-
-**document_id_in:** `typing.Optional[typing.Union[str, typing.Sequence[str]]]` — List of document IDs.
-
-
--
-**issue_date_gt:** `typing.Optional[dt.datetime]` — Issue date greater than.
-
+
+client.events.get_by_id(...)
-
-**issue_date_lt:** `typing.Optional[dt.datetime]` — Issue date less than.
-
-
-
+#### 📝 Description
-
-**issue_date_gte:** `typing.Optional[dt.datetime]` — Issue date greater than or equal.
-
-
-
-
-
-**issue_date_lte:** `typing.Optional[dt.datetime]` — Issue date less than or equal.
-
+Get a webhook event by its ID. The data is the same as you might have previously received in a webhook sent by Monite to your server.
-
-
--
-
-**due_date_gt:** `typing.Optional[dt.datetime]` — Due date greater than.
-
+#### 🔌 Usage
+
-
-**due_date_lt:** `typing.Optional[dt.datetime]` — Due date less than.
-
-
-
-
-
-**due_date_gte:** `typing.Optional[dt.datetime]` — Due date greater than or equal.
-
-
-
+```python
+from monite import Monite
-
--
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.events.get_by_id(
+ event_id="event_id",
+)
-**due_date_lte:** `typing.Optional[dt.datetime]` — Due date less than or equal.
-
+```
+
+
+
+#### ⚙️ Parameters
-
-**created_at_gt:** `typing.Optional[dt.datetime]` — Created date greater than.
-
-
-
-
-
-**created_at_lt:** `typing.Optional[dt.datetime]` — Created date less than.
+**event_id:** `str` — ID of the webhook event. This is the `id` value you might have received in a webhook or retrieved from `GET /events`.
@@ -8476,55 +9122,56 @@ client.financing.get_financing_invoices()
-
-**created_at_gte:** `typing.Optional[dt.datetime]` — Created date greater than or equal.
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
-
--
-**created_at_lte:** `typing.Optional[dt.datetime]` — Created date less than or equal.
-
+
+## Files
+client.files.get(...)
-
-**total_amount:** `typing.Optional[int]` — Total amount of the invoice in minor units.
-
-
-
+#### 🔌 Usage
-
-**total_amount_gt:** `typing.Optional[int]` — Total amount greater than.
-
-
-
-
-
-**total_amount_lt:** `typing.Optional[int]` — Total amount less than.
-
+```python
+from monite import Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.files.get()
+
+```
+
+
+
+#### ⚙️ Parameters
-
-**total_amount_gte:** `typing.Optional[int]` — Total amount greater than or equal.
-
-
-
-
-
-**total_amount_lte:** `typing.Optional[int]` — Total amount less than or equal.
+**id_in:** `typing.Optional[typing.Union[str, typing.Sequence[str]]]`
@@ -8544,11 +9191,11 @@ client.financing.get_financing_invoices()
-client.financing.post_financing_invoices(...)
+client.files.upload(...)
-
-#### 📝 Description
+#### 🔌 Usage
-
@@ -8556,13 +9203,25 @@ client.financing.get_financing_invoices()
-
-Returns a session token and a connect token to open Kanmon SDK for confirming invoice details.
+```python
+from monite import Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.files.upload(
+ file_type="ocr_results",
+)
+
+```
-#### 🔌 Usage
+#### ⚙️ Parameters
-
@@ -8570,27 +9229,17 @@ Returns a session token and a connect token to open Kanmon SDK for confirming in
-
-```python
-from monite import Monite
-from monite import FinancingPushInvoicesRequestInvoice
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.financing.post_financing_invoices(invoices=[FinancingPushInvoicesRequestInvoice(id='id', type="payable", )], )
+**file:** `from __future__ import annotations
-```
-
-
+core.File` — See core.File for more documentation
+
-#### ⚙️ Parameters
-
-
--
-
-
-**invoices:** `typing.Sequence[FinancingPushInvoicesRequestInvoice]` — A list of invoices to request financing for.
+**file_type:** `AllowedFileTypes`
@@ -8610,24 +9259,10 @@ client.financing.post_financing_invoices(invoices=[FinancingPushInvoicesRequestI
-client.financing.get_financing_offers()
-
--
-
-#### 📝 Description
-
-
--
-
+
client.files.get_by_id(...)
-
-Returns a list of financing offers and the business's onboarding status
-
-
-
-
-
#### 🔌 Usage
@@ -8638,8 +9273,15 @@ Returns a list of financing offers and the business's onboarding status
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.financing.get_financing_offers()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.files.get_by_id(
+ file_id="file_id",
+)
```
@@ -8655,6 +9297,14 @@ client.financing.get_financing_offers()
-
+**file_id:** `str`
+
+
+
+
+
+-
+
**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -8667,24 +9317,10 @@ client.financing.get_financing_offers()
-client.financing.post_financing_tokens()
-
--
-
-#### 📝 Description
-
-
--
-
+
client.files.delete(...)
-
-Returns a token for Kanmon SDK. Creates a business and user on Kanmon if not already exist.
-
-
-
-
-
#### 🔌 Usage
@@ -8695,8 +9331,15 @@ Returns a token for Kanmon SDK. Creates a business and user on Kanmon if not alr
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.financing.post_financing_tokens()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.files.delete(
+ file_id="file_id",
+)
```
@@ -8712,6 +9355,14 @@ client.financing.post_financing_tokens()
-
+**file_id:** `str`
+
+
+
+
+
+-
+
**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -8724,8 +9375,8 @@ client.financing.post_financing_tokens()
-## Mail templates
-client.mail_templates.get(...)
+## Financing
+client.financing.get_financing_invoices(...)
-
@@ -8737,7 +9388,7 @@ client.financing.post_financing_tokens()
-
-Get all custom templates
+Returns a list of invoices requested for financing
@@ -8753,8 +9404,13 @@ Get all custom templates
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.mail_templates.get()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.financing.get_financing_invoices()
```
@@ -8770,7 +9426,7 @@ client.mail_templates.get()
-
-**order:** `typing.Optional[OrderEnum]` — Order by
+**order:** `typing.Optional[OrderEnum]` — Sort order (ascending by default). Typically used together with the `sort` parameter.
@@ -8778,7 +9434,7 @@ client.mail_templates.get()
-
-**limit:** `typing.Optional[int]` — Max is 100
+**limit:** `typing.Optional[int]` — The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
@@ -8786,7 +9442,11 @@ client.mail_templates.get()
-
-**pagination_token:** `typing.Optional[str]` — A token, obtained from previous page. Prior over other filters
+**pagination_token:** `typing.Optional[str]`
+
+A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+
+If not specified, the first page of results will be returned.
@@ -8794,7 +9454,7 @@ client.mail_templates.get()
-
-**sort:** `typing.Optional[CustomTemplatesCursorFields]` — Allowed sort fields
+**sort:** `typing.Optional[FinancingInvoiceCursorFields]` — The field to sort the results by. Typically used together with the `order` parameter.
@@ -8802,7 +9462,7 @@ client.mail_templates.get()
-
-**type:** `typing.Optional[DocumentObjectTypeRequestEnum]`
+**invoice_id:** `typing.Optional[str]` — ID of a payable or receivable invoice.
@@ -8810,7 +9470,7 @@ client.mail_templates.get()
-
-**type_in:** `typing.Optional[typing.Union[DocumentObjectTypeRequestEnum, typing.Sequence[DocumentObjectTypeRequestEnum]]]`
+**invoice_id_in:** `typing.Optional[typing.Union[str, typing.Sequence[str]]]` — List of invoice IDs.
@@ -8818,7 +9478,7 @@ client.mail_templates.get()
-
-**type_not_in:** `typing.Optional[typing.Union[DocumentObjectTypeRequestEnum, typing.Sequence[DocumentObjectTypeRequestEnum]]]`
+**status:** `typing.Optional[WcInvoiceStatus]` — Status of the invoice.
@@ -8826,7 +9486,7 @@ client.mail_templates.get()
-
-**is_default:** `typing.Optional[bool]`
+**status_in:** `typing.Optional[typing.Union[WcInvoiceStatus, typing.Sequence[WcInvoiceStatus]]]` — List of invoice statuses.
@@ -8834,7 +9494,7 @@ client.mail_templates.get()
-
-**name:** `typing.Optional[str]`
+**type:** `typing.Optional[FinancingInvoiceType]` — Type of the invoice. payable or receivable.
@@ -8842,7 +9502,9 @@ client.mail_templates.get()
-
-**name_iexact:** `typing.Optional[str]`
+**type_in:** `typing.Optional[
+ typing.Union[FinancingInvoiceType, typing.Sequence[FinancingInvoiceType]]
+]` — List of invoice types.
@@ -8850,7 +9512,7 @@ client.mail_templates.get()
-
-**name_contains:** `typing.Optional[str]`
+**document_id:** `typing.Optional[str]` — Document ID of the invoice.
@@ -8858,7 +9520,7 @@ client.mail_templates.get()
-
-**name_icontains:** `typing.Optional[str]`
+**document_id_in:** `typing.Optional[typing.Union[str, typing.Sequence[str]]]` — List of document IDs.
@@ -8866,64 +9528,95 @@ client.mail_templates.get()
-
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+**issue_date_gt:** `typing.Optional[dt.datetime]` — Issue date greater than.
-
-
+
+-
+**issue_date_lt:** `typing.Optional[dt.datetime]` — Issue date less than.
+
-
-client.mail_templates.create(...)
-
-#### 📝 Description
-
-
--
+**issue_date_gte:** `typing.Optional[dt.datetime]` — Issue date greater than or equal.
+
+
+
-
-Create custom template
-
-
+**issue_date_lte:** `typing.Optional[dt.datetime]` — Issue date less than or equal.
+
-#### 🔌 Usage
-
-
+**due_date_gt:** `typing.Optional[dt.datetime]` — Due date greater than.
+
+
+
+
-
-```python
-from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.mail_templates.create(body_template='body_template', name='name', subject_template='subject_template', type="receivables_quote", )
+**due_date_lt:** `typing.Optional[dt.datetime]` — Due date less than.
+
+
+
-```
+
+-
+
+**due_date_gte:** `typing.Optional[dt.datetime]` — Due date greater than or equal.
+
+
+
+-
+
+**due_date_lte:** `typing.Optional[dt.datetime]` — Due date less than or equal.
+
-#### ⚙️ Parameters
+
+-
+
+**created_at_gt:** `typing.Optional[dt.datetime]` — Created date greater than.
+
+
+
+
+
+-
+
+**created_at_lt:** `typing.Optional[dt.datetime]` — Created date less than.
+
+
+
-
+**created_at_gte:** `typing.Optional[dt.datetime]` — Created date greater than or equal.
+
+
+
+
-
-**body_template:** `str` — Jinja2 compatible string with email body
+**created_at_lte:** `typing.Optional[dt.datetime]` — Created date less than or equal.
@@ -8931,7 +9624,7 @@ client.mail_templates.create(body_template='body_template', name='name', subject
-
-**name:** `str` — Custom template name
+**total_amount:** `typing.Optional[int]` — Total amount of the invoice in minor units.
@@ -8939,7 +9632,7 @@ client.mail_templates.create(body_template='body_template', name='name', subject
-
-**subject_template:** `str` — Jinja2 compatible string with email subject
+**total_amount_gt:** `typing.Optional[int]` — Total amount greater than.
@@ -8947,7 +9640,7 @@ client.mail_templates.create(body_template='body_template', name='name', subject
-
-**type:** `DocumentObjectTypeRequestEnum` — Document type of content
+**total_amount_lt:** `typing.Optional[int]` — Total amount less than.
@@ -8955,7 +9648,7 @@ client.mail_templates.create(body_template='body_template', name='name', subject
-
-**is_default:** `typing.Optional[bool]` — Is default template
+**total_amount_gte:** `typing.Optional[int]` — Total amount greater than or equal.
@@ -8963,7 +9656,7 @@ client.mail_templates.create(body_template='body_template', name='name', subject
-
-**language:** `typing.Optional[LanguageCodeEnum]` — Lowercase ISO code of language
+**total_amount_lte:** `typing.Optional[int]` — Total amount less than or equal.
@@ -8983,7 +9676,7 @@ client.mail_templates.create(body_template='body_template', name='name', subject
-client.mail_templates.preview(...)
+client.financing.post_financing_invoices(...)
-
@@ -8995,7 +9688,7 @@ client.mail_templates.create(body_template='body_template', name='name', subject
-
-Preview rendered template
+Returns a session token and a connect token to open Kanmon SDK for confirming invoice details.
@@ -9010,9 +9703,21 @@ Preview rendered template
-
```python
-from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.mail_templates.preview(body='body', document_type="receivables_quote", language_code="ab", subject='subject', )
+from monite import FinancingPushInvoicesRequestInvoice, Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.financing.post_financing_invoices(
+ invoices=[
+ FinancingPushInvoicesRequestInvoice(
+ id="id",
+ type="payable",
+ )
+ ],
+)
```
@@ -9028,7 +9733,7 @@ client.mail_templates.preview(body='body', document_type="receivables_quote", la
-
-**body:** `str` — Body text of the template
+**invoices:** `typing.Sequence[FinancingPushInvoicesRequestInvoice]` — A list of invoices to request financing for.
@@ -9036,26 +9741,64 @@ client.mail_templates.preview(body='body', document_type="receivables_quote", la
-
-**document_type:** `DocumentObjectTypeRequestEnum` — Document type of content
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
+
+
+
+
+
+client.financing.get_financing_offers()
-
-**language_code:** `LanguageCodeEnum` — Lowercase ISO code of language
-
+#### 📝 Description
+
+
+-
+
+
+-
+
+Returns a list of financing offers and the business's onboarding status
+
+
+#### 🔌 Usage
+
-
-**subject:** `str` — Subject text of the template
-
+
+-
+
+```python
+from monite import Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.financing.get_financing_offers()
+
+```
+
+
+
+#### ⚙️ Parameters
+
+
+-
-
@@ -9072,7 +9815,7 @@ client.mail_templates.preview(body='body', document_type="receivables_quote", la
-client.mail_templates.get_system()
+client.financing.post_financing_tokens()
-
@@ -9084,7 +9827,7 @@ client.mail_templates.preview(body='body', document_type="receivables_quote", la
-
-Get all system templates
+Returns a token for Kanmon SDK. Creates a business and user on Kanmon if not already exist.
@@ -9100,8 +9843,13 @@ Get all system templates
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.mail_templates.get_system()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.financing.post_financing_tokens()
```
@@ -9129,7 +9877,8 @@ client.mail_templates.get_system()
-client.mail_templates.get_by_id(...)
+## Mail templates
+client.mail_templates.get(...)
-
@@ -9141,7 +9890,7 @@ client.mail_templates.get_system()
-
-Get custom template by ID
+Get all custom templates
@@ -9157,8 +9906,13 @@ Get custom template by ID
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.mail_templates.get_by_id(template_id='template_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.mail_templates.get()
```
@@ -9174,7 +9928,7 @@ client.mail_templates.get_by_id(template_id='template_id', )
-
-**template_id:** `str`
+**order:** `typing.Optional[OrderEnum]` — Order by
@@ -9182,64 +9936,97 @@ client.mail_templates.get_by_id(template_id='template_id', )
-
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+**limit:** `typing.Optional[int]` — Max is 100
-
-
+
+-
+**pagination_token:** `typing.Optional[str]` — A token, obtained from previous page. Prior over other filters
+
-
-client.mail_templates.delete_by_id(...)
-
-#### 📝 Description
+**sort:** `typing.Optional[CustomTemplatesCursorFields]` — Allowed sort fields
+
+
+
-
+**type:** `typing.Optional[DocumentObjectTypeRequestEnum]`
+
+
+
+
-
-Delete custom template bt ID
+**type_in:** `typing.Optional[
+ typing.Union[
+ DocumentObjectTypeRequestEnum,
+ typing.Sequence[DocumentObjectTypeRequestEnum],
+ ]
+]`
+
+
+
+-
+
+**type_not_in:** `typing.Optional[
+ typing.Union[
+ DocumentObjectTypeRequestEnum,
+ typing.Sequence[DocumentObjectTypeRequestEnum],
+ ]
+]`
+
-#### 🔌 Usage
-
-
+**is_default:** `typing.Optional[bool]`
+
+
+
+
-
-```python
-from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.mail_templates.delete_by_id(template_id='template_id', )
-
-```
+**name:** `typing.Optional[str]`
+
+
+
+-
+
+**name_iexact:** `typing.Optional[str]`
+
-#### ⚙️ Parameters
-
-
+**name_contains:** `typing.Optional[str]`
+
+
+
+
-
-**template_id:** `str`
+**name_icontains:** `typing.Optional[str]`
@@ -9259,7 +10046,7 @@ client.mail_templates.delete_by_id(template_id='template_id', )
-client.mail_templates.update_by_id(...)
+client.mail_templates.create(...)
-
@@ -9271,7 +10058,7 @@ client.mail_templates.delete_by_id(template_id='template_id', )
-
-Update custom template by ID
+Create custom template
@@ -9287,8 +10074,18 @@ Update custom template by ID
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.mail_templates.update_by_id(template_id='template_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.mail_templates.create(
+ body_template="body_template",
+ name="name",
+ subject_template="subject_template",
+ type="receivables_quote",
+)
```
@@ -9304,7 +10101,7 @@ client.mail_templates.update_by_id(template_id='template_id', )
-
-**template_id:** `str`
+**body_template:** `str` — Jinja2 compatible string with email body
@@ -9312,7 +10109,7 @@ client.mail_templates.update_by_id(template_id='template_id', )
-
-**body_template:** `typing.Optional[str]` — Jinja2 compatible string with email body
+**name:** `str` — Custom template name
@@ -9320,7 +10117,7 @@ client.mail_templates.update_by_id(template_id='template_id', )
-
-**language:** `typing.Optional[LanguageCodeEnum]` — Lowercase ISO code of language
+**subject_template:** `str` — Jinja2 compatible string with email subject
@@ -9328,7 +10125,7 @@ client.mail_templates.update_by_id(template_id='template_id', )
-
-**name:** `typing.Optional[str]` — Custom template name
+**type:** `DocumentObjectTypeRequestEnum` — Document type of content
@@ -9336,7 +10133,15 @@ client.mail_templates.update_by_id(template_id='template_id', )
-
-**subject_template:** `typing.Optional[str]` — Jinja2 compatible string with email subject
+**is_default:** `typing.Optional[bool]` — Is default template
+
+
+
+
+
+-
+
+**language:** `typing.Optional[LanguageCodeEnum]` — Lowercase ISO code of language
@@ -9356,7 +10161,7 @@ client.mail_templates.update_by_id(template_id='template_id', )
-client.mail_templates.make_default_by_id(...)
+client.mail_templates.preview(...)
-
@@ -9368,7 +10173,7 @@ client.mail_templates.update_by_id(template_id='template_id', )
-
-Make template default
+Preview rendered template
@@ -9384,8 +10189,18 @@ Make template default
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.mail_templates.make_default_by_id(template_id='template_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.mail_templates.preview(
+ body="body",
+ document_type="receivables_quote",
+ language_code="ab",
+ subject="subject",
+)
```
@@ -9401,7 +10216,31 @@ client.mail_templates.make_default_by_id(template_id='template_id', )
-
-**template_id:** `str`
+**body:** `str` — Body text of the template
+
+
+
+
+
+-
+
+**document_type:** `DocumentObjectTypeRequestEnum` — Document type of content
+
+
+
+
+
+-
+
+**language_code:** `LanguageCodeEnum` — Lowercase ISO code of language
+
+
+
+
+
+-
+
+**subject:** `str` — Subject text of the template
@@ -9421,8 +10260,7 @@ client.mail_templates.make_default_by_id(template_id='template_id', )
-## Mailbox domains
-client.mailbox_domains.get()
+client.mail_templates.get_system()
-
@@ -9434,7 +10272,7 @@ client.mail_templates.make_default_by_id(template_id='template_id', )
-
-Get all domains owned by partner_id
+Get all system templates
@@ -9450,8 +10288,13 @@ Get all domains owned by partner_id
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.mailbox_domains.get()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.mail_templates.get_system()
```
@@ -9479,7 +10322,7 @@ client.mailbox_domains.get()
-client.mailbox_domains.create(...)
+client.mail_templates.get_by_id(...)
-
@@ -9491,7 +10334,7 @@ client.mailbox_domains.get()
-
-Create domain for the partner_id
+Get custom template by ID
@@ -9507,8 +10350,15 @@ Create domain for the partner_id
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.mailbox_domains.create(domain='domain', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.mail_templates.get_by_id(
+ template_id="template_id",
+)
```
@@ -9524,7 +10374,7 @@ client.mailbox_domains.create(domain='domain', )
-
-**domain:** `str` — The domain name, such as `mail.mycompany.com`. Can contain only alphanumeric characters (A..Z a..z 0..9), dots (.), and hyphens (-). Each segment of the domain name must start and end with either a letter or a digit.
+**template_id:** `str`
@@ -9544,7 +10394,7 @@ client.mailbox_domains.create(domain='domain', )
-client.mailbox_domains.delete_by_id(...)
+client.mail_templates.delete_by_id(...)
-
@@ -9556,7 +10406,7 @@ client.mailbox_domains.create(domain='domain', )
-
-Delete domain for the partner_id
+Delete custom template bt ID
@@ -9572,8 +10422,15 @@ Delete domain for the partner_id
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.mailbox_domains.delete_by_id(domain_id='domain_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.mail_templates.delete_by_id(
+ template_id="template_id",
+)
```
@@ -9589,7 +10446,7 @@ client.mailbox_domains.delete_by_id(domain_id='domain_id', )
-
-**domain_id:** `str`
+**template_id:** `str`
@@ -9609,7 +10466,7 @@ client.mailbox_domains.delete_by_id(domain_id='domain_id', )
-client.mailbox_domains.verify_by_id(...)
+client.mail_templates.update_by_id(...)
-
@@ -9621,7 +10478,7 @@ client.mailbox_domains.delete_by_id(domain_id='domain_id', )
-
-Verify domain for the partner_id
+Update custom template by ID
@@ -9637,8 +10494,15 @@ Verify domain for the partner_id
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.mailbox_domains.verify_by_id(domain_id='domain_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.mail_templates.update_by_id(
+ template_id="template_id",
+)
```
@@ -9654,7 +10518,39 @@ client.mailbox_domains.verify_by_id(domain_id='domain_id', )
-
-**domain_id:** `str`
+**template_id:** `str`
+
+
+
+
+
+-
+
+**body_template:** `typing.Optional[str]` — Jinja2 compatible string with email body
+
+
+
+
+
+-
+
+**language:** `typing.Optional[LanguageCodeEnum]` — Lowercase ISO code of language
+
+
+
+
+
+-
+
+**name:** `typing.Optional[str]` — Custom template name
+
+
+
+
+
+-
+
+**subject_template:** `typing.Optional[str]` — Jinja2 compatible string with email subject
@@ -9674,8 +10570,7 @@ client.mailbox_domains.verify_by_id(domain_id='domain_id', )
-## Mailboxes
-client.mailboxes.get()
+client.mail_templates.make_default_by_id(...)
-
@@ -9687,7 +10582,7 @@ client.mailbox_domains.verify_by_id(domain_id='domain_id', )
-
-Get all mailboxes owned by Entity
+Make template default
@@ -9703,8 +10598,15 @@ Get all mailboxes owned by Entity
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.mailboxes.get()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.mail_templates.make_default_by_id(
+ template_id="template_id",
+)
```
@@ -9720,6 +10622,14 @@ client.mailboxes.get()
-
+**template_id:** `str`
+
+
+
+
+
+-
+
**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -9732,7 +10642,8 @@ client.mailboxes.get()
-client.mailboxes.create(...)
+## Mailbox domains
+client.mailbox_domains.get()
-
@@ -9744,7 +10655,7 @@ client.mailboxes.get()
-
-Create a new mailbox
+Get all domains owned by partner_id
@@ -9760,8 +10671,13 @@ Create a new mailbox
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.mailboxes.create(mailbox_domain_id='mailbox_domain_id', mailbox_name='mailbox_name', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.mailbox_domains.get()
```
@@ -9777,15 +10693,71 @@ client.mailboxes.create(mailbox_domain_id='mailbox_domain_id', mailbox_name='mai
-
-**mailbox_domain_id:** `str`
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
+
+
+
+
+
+client.mailbox_domains.create(...)
-
-**mailbox_name:** `str`
+#### 📝 Description
+
+
+-
+
+
+-
+
+Create domain for the partner_id
+
+
+
+
+
+#### 🔌 Usage
+
+
+-
+
+
+-
+
+```python
+from monite import Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.mailbox_domains.create(
+ domain="domain",
+)
+
+```
+
+
+
+
+
+#### ⚙️ Parameters
+
+
+-
+
+
+-
+
+**domain:** `str` — The domain name, such as `mail.mycompany.com`. Can contain only alphanumeric characters (A..Z a..z 0..9), dots (.), and hyphens (-). Each segment of the domain name must start and end with either a letter or a digit.
@@ -9805,7 +10777,7 @@ client.mailboxes.create(mailbox_domain_id='mailbox_domain_id', mailbox_name='mai
-client.mailboxes.search(...)
+client.mailbox_domains.delete_by_id(...)
-
@@ -9817,7 +10789,7 @@ client.mailboxes.create(mailbox_domain_id='mailbox_domain_id', mailbox_name='mai
-
-Get all mailboxes owned by Entity
+Delete domain for the partner_id
@@ -9833,8 +10805,15 @@ Get all mailboxes owned by Entity
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.mailboxes.search(entity_ids=['entity_ids'], )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.mailbox_domains.delete_by_id(
+ domain_id="domain_id",
+)
```
@@ -9850,7 +10829,7 @@ client.mailboxes.search(entity_ids=['entity_ids'], )
-
-**entity_ids:** `typing.Sequence[str]`
+**domain_id:** `str`
@@ -9870,7 +10849,7 @@ client.mailboxes.search(entity_ids=['entity_ids'], )
-client.mailboxes.delete_by_id(...)
+client.mailbox_domains.verify_by_id(...)
-
@@ -9882,7 +10861,7 @@ client.mailboxes.search(entity_ids=['entity_ids'], )
-
-Delete mailbox
+Verify domain for the partner_id
@@ -9898,8 +10877,15 @@ Delete mailbox
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.mailboxes.delete_by_id(mailbox_id='mailbox_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.mailbox_domains.verify_by_id(
+ domain_id="domain_id",
+)
```
@@ -9915,7 +10901,7 @@ client.mailboxes.delete_by_id(mailbox_id='mailbox_id', )
-
-**mailbox_id:** `str`
+**domain_id:** `str`
@@ -9935,11 +10921,25 @@ client.mailboxes.delete_by_id(mailbox_id='mailbox_id', )
-## Measure units
-client.measure_units.get()
+## Mailboxes
+client.mailboxes.get()
+
+-
+
+#### 📝 Description
+
+
+-
+
-
+Get all mailboxes owned by Entity
+
+
+
+
+
#### 🔌 Usage
@@ -9950,8 +10950,13 @@ client.mailboxes.delete_by_id(mailbox_id='mailbox_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.measure_units.get()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.mailboxes.get()
```
@@ -9979,10 +10984,24 @@ client.measure_units.get()
-client.measure_units.create(...)
+client.mailboxes.create(...)
+
+-
+
+#### 📝 Description
+
+
+-
+
-
+Create a new mailbox
+
+
+
+
+
#### 🔌 Usage
@@ -9993,8 +11012,16 @@ client.measure_units.get()
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.measure_units.create(name='name', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.mailboxes.create(
+ mailbox_domain_id="mailbox_domain_id",
+ mailbox_name="mailbox_name",
+)
```
@@ -10010,7 +11037,7 @@ client.measure_units.create(name='name', )
-
-**name:** `str`
+**mailbox_domain_id:** `str`
@@ -10018,7 +11045,7 @@ client.measure_units.create(name='name', )
-
-**description:** `typing.Optional[str]`
+**mailbox_name:** `str`
@@ -10038,10 +11065,24 @@ client.measure_units.create(name='name', )
-client.measure_units.get_by_id(...)
+client.mailboxes.search(...)
+
+-
+
+#### 📝 Description
+
+
+-
+
-
+Get all mailboxes owned by Entity
+
+
+
+
+
#### 🔌 Usage
@@ -10052,8 +11093,15 @@ client.measure_units.create(name='name', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.measure_units.get_by_id(unit_id='unit_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.mailboxes.search(
+ entity_ids=["entity_ids"],
+)
```
@@ -10069,7 +11117,7 @@ client.measure_units.get_by_id(unit_id='unit_id', )
-
-**unit_id:** `str`
+**entity_ids:** `typing.Sequence[str]`
@@ -10089,10 +11137,24 @@ client.measure_units.get_by_id(unit_id='unit_id', )
-client.measure_units.delete_by_id(...)
+client.mailboxes.delete_by_id(...)
+
+-
+
+#### 📝 Description
+
+
+-
+
-
+Delete mailbox
+
+
+
+
+
#### 🔌 Usage
@@ -10103,8 +11165,15 @@ client.measure_units.get_by_id(unit_id='unit_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.measure_units.delete_by_id(unit_id='unit_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.mailboxes.delete_by_id(
+ mailbox_id="mailbox_id",
+)
```
@@ -10120,7 +11189,7 @@ client.measure_units.delete_by_id(unit_id='unit_id', )
-
-**unit_id:** `str`
+**mailbox_id:** `str`
@@ -10140,7 +11209,8 @@ client.measure_units.delete_by_id(unit_id='unit_id', )
-client.measure_units.update_by_id(...)
+## Measure units
+client.measure_units.get()
-
@@ -10154,8 +11224,13 @@ client.measure_units.delete_by_id(unit_id='unit_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.measure_units.update_by_id(unit_id='unit_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.measure_units.get()
```
@@ -10171,30 +11246,6 @@ client.measure_units.update_by_id(unit_id='unit_id', )
-
-**unit_id:** `str`
-
-
-
-
-
--
-
-**description:** `typing.Optional[str]`
-
-
-
-
-
--
-
-**name:** `typing.Optional[str]`
-
-
-
-
-
--
-
**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -10207,8 +11258,7 @@ client.measure_units.update_by_id(unit_id='unit_id', )
-## OCR
-client.ocr.get_ocr_tasks(...)
+client.measure_units.create(...)
-
@@ -10222,8 +11272,15 @@ client.measure_units.update_by_id(unit_id='unit_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.ocr.get_ocr_tasks()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.measure_units.create(
+ name="name",
+)
```
@@ -10239,7 +11296,7 @@ client.ocr.get_ocr_tasks()
-
-**order:** `typing.Optional[OrderEnum]` — Sort order (ascending by default). Typically used together with the `sort` parameter.
+**name:** `str`
@@ -10247,7 +11304,7 @@ client.ocr.get_ocr_tasks()
-
-**limit:** `typing.Optional[int]` — The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+**description:** `typing.Optional[str]`
@@ -10255,20 +11312,275 @@ client.ocr.get_ocr_tasks()
-
-**pagination_token:** `typing.Optional[str]`
-
-A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
-
-If not specified, the first page of results will be returned.
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
-
--
-**sort:** `typing.Optional[CursorFields]` — The field to sort the results by. Typically used together with the `order` parameter.
-
+
+
+
+
+client.measure_units.get_by_id(...)
+
+-
+
+#### 🔌 Usage
+
+
+-
+
+
+-
+
+```python
+from monite import Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.measure_units.get_by_id(
+ unit_id="unit_id",
+)
+
+```
+
+
+
+
+
+#### ⚙️ Parameters
+
+
+-
+
+
+-
+
+**unit_id:** `str`
+
+
+
+
+
+-
+
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
+
+
+
+
+
+
+
+
+
+client.measure_units.delete_by_id(...)
+
+-
+
+#### 🔌 Usage
+
+
+-
+
+
+-
+
+```python
+from monite import Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.measure_units.delete_by_id(
+ unit_id="unit_id",
+)
+
+```
+
+
+
+
+
+#### ⚙️ Parameters
+
+
+-
+
+
+-
+
+**unit_id:** `str`
+
+
+
+
+
+-
+
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
+
+
+
+
+
+
+
+
+
+client.measure_units.update_by_id(...)
+
+-
+
+#### 🔌 Usage
+
+
+-
+
+
+-
+
+```python
+from monite import Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.measure_units.update_by_id(
+ unit_id="unit_id",
+)
+
+```
+
+
+
+
+
+#### ⚙️ Parameters
+
+
+-
+
+
+-
+
+**unit_id:** `str`
+
+
+
+
+
+-
+
+**description:** `typing.Optional[str]`
+
+
+
+
+
+-
+
+**name:** `typing.Optional[str]`
+
+
+
+
+
+-
+
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
+
+
+
+
+
+
+
+
+
+## OCR
+client.ocr.get_ocr_tasks(...)
+
+-
+
+#### 🔌 Usage
+
+
+-
+
+
+-
+
+```python
+from monite import Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.ocr.get_ocr_tasks()
+
+```
+
+
+
+
+
+#### ⚙️ Parameters
+
+
+-
+
+
+-
+
+**order:** `typing.Optional[OrderEnum]` — Sort order (ascending by default). Typically used together with the `sort` parameter.
+
+
+
+
+
+-
+
+**limit:** `typing.Optional[int]` — The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+
+
+
+
+
+-
+
+**pagination_token:** `typing.Optional[str]`
+
+A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+
+If not specified, the first page of results will be returned.
+
+
+
+
+
+-
+
+**sort:** `typing.Optional[CursorFields]` — The field to sort the results by. Typically used together with the `order` parameter.
+
@@ -10361,8 +11673,15 @@ To specify multiple IDs, repeat this parameter for each value: `id__in=&id_
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.ocr.post_ocr_tasks(file_url='file_url', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.ocr.post_ocr_tasks(
+ file_url="file_url",
+)
```
@@ -10420,7 +11739,12 @@ client.ocr.post_ocr_tasks(file_url='file_url', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.ocr.post_ocr_tasks_upload_from_file()
```
@@ -10438,6 +11762,7 @@ client.ocr.post_ocr_tasks_upload_from_file()
-
**file:** `from __future__ import annotations
+
core.File` — See core.File for more documentation
@@ -10480,8 +11805,15 @@ core.File` — See core.File for more documentation
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.ocr.get_ocr_tasks_id(task_id='task_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.ocr.get_ocr_tasks_id(
+ task_id="task_id",
+)
```
@@ -10532,7 +11864,12 @@ client.ocr.get_ocr_tasks_id(task_id='task_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.overdue_reminders.get()
```
@@ -10575,8 +11912,15 @@ client.overdue_reminders.get()
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.overdue_reminders.create(name='name', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.overdue_reminders.create(
+ name="name",
+)
```
@@ -10642,8 +11986,15 @@ client.overdue_reminders.create(name='name', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.overdue_reminders.get_by_id(overdue_reminder_id='overdue_reminder_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.overdue_reminders.get_by_id(
+ overdue_reminder_id="overdue_reminder_id",
+)
```
@@ -10693,8 +12044,15 @@ client.overdue_reminders.get_by_id(overdue_reminder_id='overdue_reminder_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.overdue_reminders.delete_by_id(overdue_reminder_id='overdue_reminder_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.overdue_reminders.delete_by_id(
+ overdue_reminder_id="overdue_reminder_id",
+)
```
@@ -10744,8 +12102,15 @@ client.overdue_reminders.delete_by_id(overdue_reminder_id='overdue_reminder_id',
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.overdue_reminders.update_by_id(overdue_reminder_id='overdue_reminder_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.overdue_reminders.update_by_id(
+ overdue_reminder_id="overdue_reminder_id",
+)
```
@@ -10820,7 +12185,12 @@ client.overdue_reminders.update_by_id(overdue_reminder_id='overdue_reminder_id',
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.credit_notes.get_payable_credit_notes()
```
@@ -11081,7 +12451,11 @@ If not specified, the first page of results will be returned.
-
-**status_in:** `typing.Optional[typing.Union[PayableCreditNoteStateEnum, typing.Sequence[PayableCreditNoteStateEnum]]]`
+**status_in:** `typing.Optional[
+ typing.Union[
+ PayableCreditNoteStateEnum, typing.Sequence[PayableCreditNoteStateEnum]
+ ]
+]`
@@ -11089,7 +12463,11 @@ If not specified, the first page of results will be returned.
-
-**status_not_in:** `typing.Optional[typing.Union[PayableCreditNoteStateEnum, typing.Sequence[PayableCreditNoteStateEnum]]]`
+**status_not_in:** `typing.Optional[
+ typing.Union[
+ PayableCreditNoteStateEnum, typing.Sequence[PayableCreditNoteStateEnum]
+ ]
+]`
@@ -11155,8 +12533,16 @@ If not specified, the first page of results will be returned.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.credit_notes.post_payable_credit_notes(document_id='CN-2287', issued_at='2024-01-15', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.credit_notes.post_payable_credit_notes(
+ document_id="CN-2287",
+ issued_at="2024-01-15",
+)
```
@@ -11332,7 +12718,7 @@ client.credit_notes.post_payable_credit_notes(document_id='CN-2287', issued_at='
-
-Upload an incoming credit note (payable) in PDF, PNG, JPEG, or TIFF format and scan its contents. The maximum file size is 10MB.
+Upload an incoming credit note (payable) in PDF, PNG, or JPEG format and scan its contents. The maximum file size is 20MB.
@@ -11348,7 +12734,12 @@ Upload an incoming credit note (payable) in PDF, PNG, JPEG, or TIFF format and s
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.credit_notes.post_payable_credit_notes_upload_from_file()
```
@@ -11366,6 +12757,7 @@ client.credit_notes.post_payable_credit_notes_upload_from_file()
-
**file:** `from __future__ import annotations
+
core.File` — See core.File for more documentation
@@ -11414,7 +12806,12 @@ Get credit notes validations.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.credit_notes.get_payable_credit_notes_validations()
```
@@ -11471,8 +12868,15 @@ Update credit notes validations.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.credit_notes.put_payable_credit_notes_validations(required_fields=["currency"], )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.credit_notes.put_payable_credit_notes_validations(
+ required_fields=["currency"],
+)
```
@@ -11536,7 +12940,12 @@ Reset credit notes validations.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.credit_notes.post_payable_credit_notes_validations_reset()
```
@@ -11579,8 +12988,15 @@ client.credit_notes.post_payable_credit_notes_validations_reset()
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.credit_notes.get_payable_credit_notes_id(credit_note_id='credit_note_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.credit_notes.get_payable_credit_notes_id(
+ credit_note_id="credit_note_id",
+)
```
@@ -11630,8 +13046,15 @@ client.credit_notes.get_payable_credit_notes_id(credit_note_id='credit_note_id',
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.credit_notes.delete_payable_credit_notes_id(credit_note_id='credit_note_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.credit_notes.delete_payable_credit_notes_id(
+ credit_note_id="credit_note_id",
+)
```
@@ -11681,8 +13104,15 @@ client.credit_notes.delete_payable_credit_notes_id(credit_note_id='credit_note_i
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.credit_notes.patch_payable_credit_notes_id(credit_note_id='credit_note_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.credit_notes.patch_payable_credit_notes_id(
+ credit_note_id="credit_note_id",
+)
```
@@ -11882,8 +13312,15 @@ Approve the credit note for appliance.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.credit_notes.post_payable_credit_notes_id_approve(credit_note_id='credit_note_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.credit_notes.post_payable_credit_notes_id_approve(
+ credit_note_id="credit_note_id",
+)
```
@@ -11947,8 +13384,15 @@ Cancel the credit note that was not confirmed during the review.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.credit_notes.post_payable_credit_notes_id_cancel(credit_note_id='credit_note_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.credit_notes.post_payable_credit_notes_id_cancel(
+ credit_note_id="credit_note_id",
+)
```
@@ -12012,8 +13456,15 @@ Request to cancel the OCR processing of the specified credit note.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.credit_notes.post_payable_credit_notes_id_cancel_ocr(credit_note_id='credit_note_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.credit_notes.post_payable_credit_notes_id_cancel_ocr(
+ credit_note_id="credit_note_id",
+)
```
@@ -12063,8 +13514,15 @@ client.credit_notes.post_payable_credit_notes_id_cancel_ocr(credit_note_id='cred
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.credit_notes.get_payable_credit_notes_id_line_items(credit_note_id='credit_note_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.credit_notes.get_payable_credit_notes_id_line_items(
+ credit_note_id="credit_note_id",
+)
```
@@ -12470,8 +13928,15 @@ If not specified, the first page of results will be returned.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.credit_notes.post_payable_credit_notes_id_line_items(credit_note_id='credit_note_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.credit_notes.post_payable_credit_notes_id_line_items(
+ credit_note_id="credit_note_id",
+)
```
@@ -12568,10 +14033,17 @@ client.credit_notes.post_payable_credit_notes_id_line_items(credit_note_id='cred
-
```python
-from monite import Monite
-from monite import CreditNoteLineItemCreateRequest
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.credit_notes.put_payable_credit_notes_id_line_items(credit_note_id='credit_note_id', data=[CreditNoteLineItemCreateRequest()], )
+from monite import CreditNoteLineItemCreateRequest, Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.credit_notes.put_payable_credit_notes_id_line_items(
+ credit_note_id="credit_note_id",
+ data=[CreditNoteLineItemCreateRequest()],
+)
```
@@ -12629,8 +14101,16 @@ client.credit_notes.put_payable_credit_notes_id_line_items(credit_note_id='credi
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.credit_notes.get_payable_credit_notes_id_line_items_id(credit_note_id='credit_note_id', line_item_id='line_item_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.credit_notes.get_payable_credit_notes_id_line_items_id(
+ credit_note_id="credit_note_id",
+ line_item_id="line_item_id",
+)
```
@@ -12688,8 +14168,16 @@ client.credit_notes.get_payable_credit_notes_id_line_items_id(credit_note_id='cr
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.credit_notes.delete_payable_credit_notes_id_line_items_id(credit_note_id='credit_note_id', line_item_id='line_item_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.credit_notes.delete_payable_credit_notes_id_line_items_id(
+ credit_note_id="credit_note_id",
+ line_item_id="line_item_id",
+)
```
@@ -12747,8 +14235,16 @@ client.credit_notes.delete_payable_credit_notes_id_line_items_id(credit_note_id=
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.credit_notes.patch_payable_credit_notes_id_line_items_id(credit_note_id='credit_note_id', line_item_id='line_item_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.credit_notes.patch_payable_credit_notes_id_line_items_id(
+ credit_note_id="credit_note_id",
+ line_item_id="line_item_id",
+)
```
@@ -12868,8 +14364,15 @@ Decline the credit note when an approver finds any mismatch or discrepancies.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.credit_notes.post_payable_credit_notes_id_reject(credit_note_id='credit_note_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.credit_notes.post_payable_credit_notes_id_reject(
+ credit_note_id="credit_note_id",
+)
```
@@ -12933,8 +14436,15 @@ Start the approval process once the uploaded credit note is validated.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.credit_notes.post_payable_credit_notes_id_submit_for_approval(credit_note_id='credit_note_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.credit_notes.post_payable_credit_notes_id_submit_for_approval(
+ credit_note_id="credit_note_id",
+)
```
@@ -12984,8 +14494,15 @@ client.credit_notes.post_payable_credit_notes_id_submit_for_approval(credit_note
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.credit_notes.get_payable_credit_notes_id_validate(credit_note_id='credit_note_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.credit_notes.get_payable_credit_notes_id_validate(
+ credit_note_id="credit_note_id",
+)
```
@@ -13036,7 +14553,12 @@ client.credit_notes.get_payable_credit_notes_id_validate(credit_note_id='credit_
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.purchase_orders.get()
```
@@ -13290,10 +14812,29 @@ If not specified, the first page of results will be returned.
-
```python
-from monite import Monite
-from monite import PurchaseOrderItem
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.purchase_orders.create(counterpart_id='counterpart_id', currency="AED", items=[PurchaseOrderItem(currency="AED", name='name', price=1, quantity=1, unit='unit', vat_rate=1, )], message='message', valid_for_days=1, )
+from monite import Monite, PurchaseOrderItem
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.purchase_orders.create(
+ counterpart_id="counterpart_id",
+ currency="AED",
+ items=[
+ PurchaseOrderItem(
+ currency="AED",
+ name="name",
+ price=1,
+ quantity=1,
+ unit="unit",
+ vat_rate=1,
+ )
+ ],
+ message="message",
+ valid_for_days=1,
+)
```
@@ -13413,7 +14954,12 @@ Get a list of placeholders allowed to insert into an email template for customiz
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.purchase_orders.get_variables()
```
@@ -13456,8 +15002,15 @@ client.purchase_orders.get_variables()
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.purchase_orders.get_by_id(purchase_order_id='purchase_order_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.purchase_orders.get_by_id(
+ purchase_order_id="purchase_order_id",
+)
```
@@ -13507,8 +15060,15 @@ client.purchase_orders.get_by_id(purchase_order_id='purchase_order_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.purchase_orders.delete_by_id(purchase_order_id='purchase_order_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.purchase_orders.delete_by_id(
+ purchase_order_id="purchase_order_id",
+)
```
@@ -13558,8 +15118,15 @@ client.purchase_orders.delete_by_id(purchase_order_id='purchase_order_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.purchase_orders.update_by_id(purchase_order_id='purchase_order_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.purchase_orders.update_by_id(
+ purchase_order_id="purchase_order_id",
+)
```
@@ -13665,8 +15232,17 @@ client.purchase_orders.update_by_id(purchase_order_id='purchase_order_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.purchase_orders.preview_by_id(purchase_order_id='purchase_order_id', body_text='body_text', subject_text='subject_text', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.purchase_orders.preview_by_id(
+ purchase_order_id="purchase_order_id",
+ body_text="body_text",
+ subject_text="subject_text",
+)
```
@@ -13732,8 +15308,17 @@ client.purchase_orders.preview_by_id(purchase_order_id='purchase_order_id', body
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.purchase_orders.send_by_id(purchase_order_id='purchase_order_id', body_text='body_text', subject_text='subject_text', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.purchase_orders.send_by_id(
+ purchase_order_id="purchase_order_id",
+ body_text="body_text",
+ subject_text="subject_text",
+)
```
@@ -13845,7 +15430,12 @@ See also:
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.payables.get()
```
@@ -13942,7 +15532,9 @@ To query multiple statuses at once, use the `status__in` parameter instead.
-
-**status_in:** `typing.Optional[typing.Union[PayableStateEnum, typing.Sequence[PayableStateEnum]]]`
+**status_in:** `typing.Optional[
+ typing.Union[PayableStateEnum, typing.Sequence[PayableStateEnum]]
+]`
Return only payables that have the specified [statuses](https://docs.monite.com/accounts-payable/payables/index).
@@ -14288,6 +15880,14 @@ Valid but nonexistent project IDs do not raise errors but return no results.
-
+**has_tags:** `typing.Optional[bool]` — Filter objects based on whether they have tags. If true, only objects with tags are returned. If false, only objects without tags are returned.
+
+
+
+
+
+-
+
**origin:** `typing.Optional[PayableOriginEnum]` — Return only payables from a given origin ['einvoice', 'upload', 'email']
@@ -14350,7 +15950,12 @@ A newly created payable has the the `draft` [status](https://docs.monite.com/acc
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.payables.create()
```
@@ -14597,7 +16202,12 @@ For more flexible configuration and retrieval of other data types, use `GET /ana
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.payables.get_analytics()
```
@@ -14658,7 +16268,9 @@ To query multiple statuses at once, use the `status__in` parameter instead.
-
-**status_in:** `typing.Optional[typing.Union[PayableStateEnum, typing.Sequence[PayableStateEnum]]]`
+**status_in:** `typing.Optional[
+ typing.Union[PayableStateEnum, typing.Sequence[PayableStateEnum]]
+]`
Return only payables that have the specified [statuses](https://docs.monite.com/accounts-payable/payables/index).
@@ -15004,6 +16616,14 @@ Valid but nonexistent project IDs do not raise errors but return no results.
-
+**has_tags:** `typing.Optional[bool]` — Filter objects based on whether they have tags. If true, only objects with tags are returned. If false, only objects without tags are returned.
+
+
+
+
+
+-
+
**origin:** `typing.Optional[PayableOriginEnum]` — Return only payables from a given origin ['einvoice', 'upload', 'email']
@@ -15044,7 +16664,7 @@ Valid but nonexistent project IDs do not raise errors but return no results.
-
-Upload an incoming invoice (payable) in PDF, PNG, JPEG, or TIFF format and scan its contents. The maximum file size is 10MB.
+Upload an incoming invoice (payable) in PDF, PNG, or JPEG format and scan its contents. The maximum file size is 20MB.
@@ -15060,7 +16680,12 @@ Upload an incoming invoice (payable) in PDF, PNG, JPEG, or TIFF format and scan
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.payables.upload_from_file()
```
@@ -15078,6 +16703,7 @@ client.payables.upload_from_file()
-
**file:** `from __future__ import annotations
+
core.File` — See core.File for more documentation
@@ -15126,7 +16752,12 @@ Get payable validations.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.payables.get_validations()
```
@@ -15183,8 +16814,15 @@ Update payable validations.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payables.update_validations(required_fields=["currency"], )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payables.update_validations(
+ required_fields=["currency"],
+)
```
@@ -15248,7 +16886,12 @@ Reset payable validations to default ones.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.payables.reset_validations()
```
@@ -15305,7 +16948,12 @@ Get a list of placeholders allowed to insert into an email template for customiz
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.payables.get_variables()
```
@@ -15362,8 +17010,15 @@ Retrieves information about a specific payable with the given ID.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payables.get_by_id(payable_id='payable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payables.get_by_id(
+ payable_id="payable_id",
+)
```
@@ -15427,8 +17082,15 @@ Deletes a specific payable.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payables.delete_by_id(payable_id='payable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payables.delete_by_id(
+ payable_id="payable_id",
+)
```
@@ -15492,8 +17154,15 @@ Updates the information about a specific payable.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payables.update_by_id(payable_id='payable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payables.update_by_id(
+ payable_id="payable_id",
+)
```
@@ -15733,8 +17402,15 @@ Confirms that the payable is ready to be paid.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payables.approve_payment_by_id(payable_id='payable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payables.approve_payment_by_id(
+ payable_id="payable_id",
+)
```
@@ -15798,8 +17474,15 @@ Attach file to payable without existing attachment.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payables.attach_file_by_id(payable_id='payable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payables.attach_file_by_id(
+ payable_id="payable_id",
+)
```
@@ -15824,6 +17507,7 @@ client.payables.attach_file_by_id(payable_id='payable_id', )
-
**file:** `from __future__ import annotations
+
core.File` — See core.File for more documentation
@@ -15872,8 +17556,15 @@ Cancels the payable that was not confirmed during the review.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payables.cancel_by_id(payable_id='payable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payables.cancel_by_id(
+ payable_id="payable_id",
+)
```
@@ -15937,8 +17628,73 @@ Request to cancel the OCR processing of the specified payable.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payables.post_payables_id_cancel_ocr(payable_id='payable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payables.post_payables_id_cancel_ocr(
+ payable_id="payable_id",
+)
+
+```
+
+
+
+
+
+#### ⚙️ Parameters
+
+
+-
+
+
+-
+
+**payable_id:** `str`
+
+
+
+
+
+-
+
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
+
+
+
+
+
+
+
+
+
+client.payables.get_payables_id_history(...)
+
+-
+
+#### 🔌 Usage
+
+
+-
+
+
+-
+
+```python
+from monite import Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payables.get_payables_id_history(
+ payable_id="payable_id",
+)
```
@@ -15962,6 +17718,98 @@ client.payables.post_payables_id_cancel_ocr(payable_id='payable_id', )
-
+**order:** `typing.Optional[OrderEnum]` — Sort order (ascending by default). Typically used together with the `sort` parameter.
+
+
+
+
+
+-
+
+**limit:** `typing.Optional[int]` — The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+
+
+
+
+
+-
+
+**pagination_token:** `typing.Optional[str]`
+
+A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+
+If not specified, the first page of results will be returned.
+
+
+
+
+
+-
+
+**sort:** `typing.Optional[PayableHistoryCursorFields]` — The field to sort the results by. Typically used together with the `order` parameter.
+
+
+
+
+
+-
+
+**event_type_in:** `typing.Optional[
+ typing.Union[
+ PayableHistoryEventTypeEnum,
+ typing.Sequence[PayableHistoryEventTypeEnum],
+ ]
+]` — Return only the specified event types
+
+
+
+
+
+-
+
+**entity_user_id_in:** `typing.Optional[typing.Union[str, typing.Sequence[str]]]`
+
+Return only events caused by the entity users with the specified IDs. To specify multiple user IDs, repeat this parameter for each ID:
+`entity_user_id__in=&entity_user_id__in=`
+
+
+
+
+
+-
+
+**timestamp_gt:** `typing.Optional[dt.datetime]` — Return only events that occurred after the specified date and time. The value must be in the ISO 8601 format `YYYY-MM-DDThh:mm[:ss[.ffffff]][Z|±hh:mm]`.
+
+
+
+
+
+-
+
+**timestamp_lt:** `typing.Optional[dt.datetime]` — Return only events that occurred before the specified date and time.
+
+
+
+
+
+-
+
+**timestamp_gte:** `typing.Optional[dt.datetime]` — Return only events that occurred on or after the specified date and time.
+
+
+
+
+
+-
+
+**timestamp_lte:** `typing.Optional[dt.datetime]` — Return only events that occurred before or on the specified date and time.
+
+
+
+
+
+-
+
**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -16023,8 +17871,15 @@ See also:
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payables.mark_as_paid_by_id(payable_id='payable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payables.mark_as_paid_by_id(
+ payable_id="payable_id",
+)
```
@@ -16119,8 +17974,16 @@ See also:
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payables.mark_as_partially_paid_by_id(payable_id='payable_id', amount_paid=1, )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payables.mark_as_partially_paid_by_id(
+ payable_id="payable_id",
+ amount_paid=1,
+)
```
@@ -16192,8 +18055,15 @@ Declines the payable when an approver finds any mismatch or discrepancies.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payables.reject_by_id(payable_id='payable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payables.reject_by_id(
+ payable_id="payable_id",
+)
```
@@ -16257,8 +18127,15 @@ Reset payable state from rejected to new.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payables.reopen_by_id(payable_id='payable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payables.reopen_by_id(
+ payable_id="payable_id",
+)
```
@@ -16322,8 +18199,15 @@ Starts the approval process once the uploaded payable is validated.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payables.submit_for_approval_by_id(payable_id='payable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payables.submit_for_approval_by_id(
+ payable_id="payable_id",
+)
```
@@ -16387,8 +18271,15 @@ Check the invoice for compliance with the requirements for movement from draft t
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payables.validate_by_id(payable_id='payable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payables.validate_by_id(
+ payable_id="payable_id",
+)
```
@@ -16439,7 +18330,12 @@ client.payables.validate_by_id(payable_id='payable_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.payment_intents.get()
```
@@ -16456,7 +18352,7 @@ client.payment_intents.get()
-
-**order:** `typing.Optional[OrderEnum]` — Order by
+**order:** `typing.Optional[OrderEnum]` — Sort order (ascending by default). Typically used together with the `sort` parameter.
@@ -16464,7 +18360,7 @@ client.payment_intents.get()
-
-**limit:** `typing.Optional[int]` — Max is 100
+**limit:** `typing.Optional[int]` — The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
@@ -16472,7 +18368,11 @@ client.payment_intents.get()
-
-**pagination_token:** `typing.Optional[str]` — A token, obtained from previous page. Prior over other filters
+**pagination_token:** `typing.Optional[str]`
+
+A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+
+If not specified, the first page of results will be returned.
@@ -16480,7 +18380,7 @@ client.payment_intents.get()
-
-**sort:** `typing.Optional[PaymentIntentCursorFields]` — Allowed sort fields
+**sort:** `typing.Optional[PaymentIntentCursorFields]` — The field to sort the results by. Typically used together with the `order` parameter.
@@ -16530,8 +18430,15 @@ client.payment_intents.get()
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payment_intents.get_by_id(payment_intent_id='payment_intent_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payment_intents.get_by_id(
+ payment_intent_id="payment_intent_id",
+)
```
@@ -16581,8 +18488,16 @@ client.payment_intents.get_by_id(payment_intent_id='payment_intent_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payment_intents.update_by_id(payment_intent_id='payment_intent_id', amount=1, )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payment_intents.update_by_id(
+ payment_intent_id="payment_intent_id",
+ amount=1,
+)
```
@@ -16640,8 +18555,15 @@ client.payment_intents.update_by_id(payment_intent_id='payment_intent_id', amoun
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payment_intents.get_history_by_id(payment_intent_id='payment_intent_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payment_intents.get_history_by_id(
+ payment_intent_id="payment_intent_id",
+)
```
@@ -16691,10 +18613,20 @@ client.payment_intents.get_history_by_id(payment_intent_id='payment_intent_id',
-
```python
-from monite import Monite
-from monite import PaymentAccountObject
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payment_links.create(payment_methods=["sepa_credit"], recipient=PaymentAccountObject(id='id', type="entity", ), )
+from monite import Monite, PaymentAccountObject
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payment_links.create(
+ payment_methods=["sepa_credit"],
+ recipient=PaymentAccountObject(
+ id="id",
+ type="entity",
+ ),
+)
```
@@ -16808,8 +18740,15 @@ client.payment_links.create(payment_methods=["sepa_credit"], recipient=PaymentAc
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payment_links.get_by_id(payment_link_id='payment_link_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payment_links.get_by_id(
+ payment_link_id="payment_link_id",
+)
```
@@ -16859,8 +18798,15 @@ client.payment_links.get_by_id(payment_link_id='payment_link_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payment_links.expire_by_id(payment_link_id='payment_link_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payment_links.expire_by_id(
+ payment_link_id="payment_link_id",
+)
```
@@ -16911,7 +18857,12 @@ client.payment_links.expire_by_id(payment_link_id='payment_link_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.payment_records.get()
```
@@ -16976,6 +18927,14 @@ client.payment_records.get()
-
+**object_id_in:** `typing.Optional[typing.Union[str, typing.Sequence[str]]]` — List of IDs of the objects, that are connected to payments
+
+
+
+
+
+-
+
**object_type:** `typing.Optional[ObjectTypeEnum]` — Type of an object, which is connected with payment
@@ -17121,10 +19080,22 @@ client.payment_records.get()
-
```python
-from monite import Monite
-from monite import PaymentRecordObjectRequest
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payment_records.create(amount=1, currency="AED", object=PaymentRecordObjectRequest(id='id', type="receivable", ), payment_intent_id='payment_intent_id', )
+from monite import Monite, PaymentRecordObjectRequest
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payment_records.create(
+ amount=1,
+ currency="AED",
+ object=PaymentRecordObjectRequest(
+ id="id",
+ type="receivable",
+ ),
+ payment_intent_id="payment_intent_id",
+)
```
@@ -17246,8 +19217,15 @@ client.payment_records.create(amount=1, currency="AED", object=PaymentRecordObje
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payment_records.get_by_id(payment_record_id='payment_record_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payment_records.get_by_id(
+ payment_record_id="payment_record_id",
+)
```
@@ -17297,8 +19275,15 @@ client.payment_records.get_by_id(payment_record_id='payment_record_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payment_records.patch_payment_records_id(payment_record_id='payment_record_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payment_records.patch_payment_records_id(
+ payment_record_id="payment_record_id",
+)
```
@@ -17420,8 +19405,15 @@ client.payment_records.patch_payment_records_id(payment_record_id='payment_recor
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payment_records.post_payment_records_id_cancel(payment_record_id='payment_record_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payment_records.post_payment_records_id_cancel(
+ payment_record_id="payment_record_id",
+)
```
@@ -17478,10 +19470,21 @@ client.payment_records.post_payment_records_id_cancel(payment_record_id='payment
-
```python
-from monite import Monite
import datetime
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payment_records.post_payment_records_id_mark_as_succeeded(payment_record_id='payment_record_id', paid_at=datetime.datetime.fromisoformat("2024-01-15 09:30:00+00:00", ), )
+
+from monite import Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payment_records.post_payment_records_id_mark_as_succeeded(
+ payment_record_id="payment_record_id",
+ paid_at=datetime.datetime.fromisoformat(
+ "2024-01-15 09:30:00+00:00",
+ ),
+)
```
@@ -17547,8 +19550,15 @@ client.payment_records.post_payment_records_id_mark_as_succeeded(payment_record_
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payment_records.post_payment_records_id_start_processing(payment_record_id='payment_record_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payment_records.post_payment_records_id_start_processing(
+ payment_record_id="payment_record_id",
+)
```
@@ -17607,7 +19617,12 @@ client.payment_records.post_payment_records_id_start_processing(payment_record_i
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.payment_reminders.get()
```
@@ -17650,8 +19665,15 @@ client.payment_reminders.get()
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payment_reminders.create(name='name', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payment_reminders.create(
+ name="name",
+)
```
@@ -17733,8 +19755,15 @@ client.payment_reminders.create(name='name', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payment_reminders.get_by_id(payment_reminder_id='payment_reminder_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payment_reminders.get_by_id(
+ payment_reminder_id="payment_reminder_id",
+)
```
@@ -17784,8 +19813,15 @@ client.payment_reminders.get_by_id(payment_reminder_id='payment_reminder_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payment_reminders.delete_by_id(payment_reminder_id='payment_reminder_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payment_reminders.delete_by_id(
+ payment_reminder_id="payment_reminder_id",
+)
```
@@ -17835,8 +19871,15 @@ client.payment_reminders.delete_by_id(payment_reminder_id='payment_reminder_id',
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payment_reminders.update_by_id(payment_reminder_id='payment_reminder_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payment_reminders.update_by_id(
+ payment_reminder_id="payment_reminder_id",
+)
```
@@ -17927,7 +19970,12 @@ client.payment_reminders.update_by_id(payment_reminder_id='payment_reminder_id',
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.payment_terms.get()
```
@@ -17969,10 +20017,19 @@ client.payment_terms.get()
-
```python
-from monite import Monite
-from monite import PaymentTerm
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payment_terms.create(name='name', term_final=PaymentTerm(number_of_days=1, ), )
+from monite import Monite, TermFinalDays
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payment_terms.create(
+ name="name",
+ term_final=TermFinalDays(
+ number_of_days=1,
+ ),
+)
```
@@ -17996,7 +20053,7 @@ client.payment_terms.create(name='name', term_final=PaymentTerm(number_of_days=1
-
-**term_final:** `PaymentTerm` — The final tier of the payment term. Defines the invoice due date.
+**term_final:** `TermFinalDays` — The final tier of the payment term. Defines the invoice due date.
@@ -18012,7 +20069,7 @@ client.payment_terms.create(name='name', term_final=PaymentTerm(number_of_days=1
-
-**term1:** `typing.Optional[PaymentTermDiscount]` — The first tier of the payment term. Represents the terms of the first early discount.
+**term1:** `typing.Optional[TermDiscountDays]` — The first tier of the payment term. Represents the terms of the first early discount.
@@ -18020,7 +20077,7 @@ client.payment_terms.create(name='name', term_final=PaymentTerm(number_of_days=1
-
-**term2:** `typing.Optional[PaymentTermDiscount]` — The second tier of the payment term. Defines the terms of the second early discount.
+**term2:** `typing.Optional[TermDiscountDays]` — The second tier of the payment term. Defines the terms of the second early discount.
@@ -18054,8 +20111,15 @@ client.payment_terms.create(name='name', term_final=PaymentTerm(number_of_days=1
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payment_terms.get_by_id(payment_terms_id='payment_terms_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payment_terms.get_by_id(
+ payment_terms_id="payment_terms_id",
+)
```
@@ -18105,8 +20169,15 @@ client.payment_terms.get_by_id(payment_terms_id='payment_terms_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payment_terms.delete_by_id(payment_terms_id='payment_terms_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payment_terms.delete_by_id(
+ payment_terms_id="payment_terms_id",
+)
```
@@ -18156,8 +20227,15 @@ client.payment_terms.delete_by_id(payment_terms_id='payment_terms_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payment_terms.update_by_id(payment_terms_id='payment_terms_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payment_terms.update_by_id(
+ payment_terms_id="payment_terms_id",
+)
```
@@ -18197,7 +20275,7 @@ client.payment_terms.update_by_id(payment_terms_id='payment_terms_id', )
-
-**term1:** `typing.Optional[PaymentTermDiscount]` — The first tier of the payment term. Represents the terms of the first early discount.
+**term1:** `typing.Optional[TermDiscountDays]` — The first tier of the payment term. Represents the terms of the first early discount.
@@ -18205,7 +20283,7 @@ client.payment_terms.update_by_id(payment_terms_id='payment_terms_id', )
-
-**term2:** `typing.Optional[PaymentTermDiscount]` — The second tier of the payment term. Defines the terms of the second early discount.
+**term2:** `typing.Optional[TermDiscountDays]` — The second tier of the payment term. Defines the terms of the second early discount.
@@ -18213,7 +20291,7 @@ client.payment_terms.update_by_id(payment_terms_id='payment_terms_id', )
-
-**term_final:** `typing.Optional[PaymentTerm]` — The final tier of the payment term. Defines the invoice due date.
+**term_final:** `typing.Optional[TermFinalDays]` — The final tier of the payment term. Defines the invoice due date.
@@ -18248,7 +20326,12 @@ client.payment_terms.update_by_id(payment_terms_id='payment_terms_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.products.get()
```
@@ -18463,8 +20546,15 @@ If not specified, the first page of results will be returned.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.products.create(name='name', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.products.create(
+ name="name",
+)
```
@@ -18496,6 +20586,14 @@ client.products.create(name='name', )
-
+**external_reference:** `typing.Optional[str]` — A user-defined identifier of the product. For example, an internal product code or SKU (stock keeping unit). Client applications can use this field to map the products in Monite to an external product catalog.
+
+
+
+
+
+-
+
**ledger_account_id:** `typing.Optional[str]`
@@ -18562,8 +20660,15 @@ client.products.create(name='name', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.products.get_by_id(product_id='product_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.products.get_by_id(
+ product_id="product_id",
+)
```
@@ -18613,8 +20718,15 @@ client.products.get_by_id(product_id='product_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.products.delete_by_id(product_id='product_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.products.delete_by_id(
+ product_id="product_id",
+)
```
@@ -18664,8 +20776,15 @@ client.products.delete_by_id(product_id='product_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.products.update_by_id(product_id='product_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.products.update_by_id(
+ product_id="product_id",
+)
```
@@ -18697,6 +20816,14 @@ client.products.update_by_id(product_id='product_id', )
-
+**external_reference:** `typing.Optional[str]` — A user-defined identifier of the product. For example, an internal product code or SKU (stock keeping unit). Client applications can use this field to map the products in Monite to an external product catalog.
+
+
+
+
+
+-
+
**ledger_account_id:** `typing.Optional[str]`
@@ -18786,7 +20913,12 @@ Get all projects for an entity
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.projects.get()
```
@@ -19039,8 +21171,15 @@ Create a new project.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.projects.create(name='Marketing', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.projects.create(
+ name="Marketing",
+)
```
@@ -19168,8 +21307,15 @@ Get a project with the given ID.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.projects.get_by_id(project_id='project_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.projects.get_by_id(
+ project_id="project_id",
+)
```
@@ -19233,8 +21379,15 @@ Delete a project.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.projects.delete_by_id(project_id='project_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.projects.delete_by_id(
+ project_id="project_id",
+)
```
@@ -19298,8 +21451,15 @@ Update a project.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.projects.update_by_id(project_id='project_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.projects.update_by_id(
+ project_id="project_id",
+)
```
@@ -19501,7 +21661,12 @@ This endpoint supports [pagination](https://docs.monite.com/api/concepts/paginat
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.receivables.get()
```
@@ -19563,7 +21728,12 @@ To specify multiple IDs, repeat this parameter for each value:
-
-**status_in:** `typing.Optional[typing.Union[ReceivablesGetRequestStatusInItem, typing.Sequence[ReceivablesGetRequestStatusInItem]]]`
+**status_in:** `typing.Optional[
+ typing.Union[
+ ReceivablesGetRequestStatusInItem,
+ typing.Sequence[ReceivablesGetRequestStatusInItem],
+ ]
+]`
Return only receivables that have the specified statuses. See the applicable [invoice statuses](https://docs.monite.com/accounts-receivable/invoices/index), [quote statuses](https://docs.monite.com/accounts-receivable/quotes/index), and [credit note statuses](https://docs.monite.com/accounts-receivable/credit-notes#credit-note-lifecycle).
@@ -19863,6 +22033,46 @@ For example, given receivables with the following product IDs:
-
+**discounted_subtotal:** `typing.Optional[int]`
+
+
+
+
+
+-
+
+**discounted_subtotal_gt:** `typing.Optional[int]`
+
+
+
+
+
+-
+
+**discounted_subtotal_lt:** `typing.Optional[int]`
+
+
+
+
+
+-
+
+**discounted_subtotal_gte:** `typing.Optional[int]`
+
+
+
+
+
+-
+
+**discounted_subtotal_lte:** `typing.Optional[int]`
+
+
+
+
+
+-
+
**status:** `typing.Optional[ReceivablesGetRequestStatus]`
@@ -19951,12 +22161,96 @@ For example, given receivables with the following product IDs:
-
+```python
+from monite import LineItem, Monite, ReceivableFacadeCreateQuotePayload
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.receivables.create(
+ request=ReceivableFacadeCreateQuotePayload(
+ counterpart_billing_address_id="counterpart_billing_address_id",
+ counterpart_id="counterpart_id",
+ currency="AED",
+ line_items=[
+ LineItem(
+ quantity=1.1,
+ )
+ ],
+ ),
+)
+
+```
+
+
+
+
+
+#### ⚙️ Parameters
+
+
+-
+
+
+-
+
+**request:** `ReceivableFacadeCreatePayload`
+
+
+
+
+
+-
+
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
+
+
+
+
+
+
+
+
+
+client.receivables.get_receivables_required_fields(...)
+
+-
+
+#### 📝 Description
+
+
+-
+
+
+-
+
+Get field requirements for invoice creation given the entity and counterpart details.
+
+
+
+
+
+#### 🔌 Usage
+
+
+-
+
+
+-
+
```python
from monite import Monite
-from monite import ReceivableFacadeCreateQuotePayload
-from monite import LineItem
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.receivables.create(request=ReceivableFacadeCreateQuotePayload(counterpart_billing_address_id='counterpart_billing_address_id', counterpart_id='counterpart_id', currency="AED", line_items=[LineItem(quantity=1.1, )], ), )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.receivables.get_receivables_required_fields()
```
@@ -19972,7 +22266,384 @@ client.receivables.create(request=ReceivableFacadeCreateQuotePayload(counterpart
-
-**request:** `ReceivableFacadeCreatePayload`
+**counterpart_id:** `typing.Optional[str]`
+
+
+
+
+
+-
+
+**counterpart_billing_address_id:** `typing.Optional[str]`
+
+
+
+
+
+-
+
+**counterpart_country:** `typing.Optional[AllowedCountries]`
+
+
+
+
+
+-
+
+**counterpart_type:** `typing.Optional[CounterpartType]`
+
+
+
+
+
+-
+
+**entity_vat_id_id:** `typing.Optional[str]`
+
+
+
+
+
+-
+
+**counterpart_vat_id_id:** `typing.Optional[str]`
+
+
+
+
+
+-
+
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
+
+
+
+
+
+
+
+
+
+client.receivables.post_receivables_search(...)
+
+-
+
+#### 📝 Description
+
+
+-
+
+
+-
+
+This is a POST version of the `GET /receivables` endpoint. Use it to send search and filter parameters in the request body instead of the URL query string in case the query is too long and exceeds the URL length limit of your HTTP client.
+
+
+
+
+
+#### 🔌 Usage
+
+
+-
+
+
+-
+
+```python
+from monite import Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.receivables.post_receivables_search()
+
+```
+
+
+
+
+
+#### ⚙️ Parameters
+
+
+-
+
+
+-
+
+**discounted_subtotal:** `typing.Optional[int]` — Return only receivables with the exact specified discounted subtotal. The amount must be specified in the [minor units](https://docs.monite.com/references/currencies#minor-units) of currency. For example, $12.5 is represented as 1250.
+
+
+
+
+
+-
+
+**discounted_subtotal_gt:** `typing.Optional[int]` — Return only receivables whose discounted subtotal (in minor units) is greater than the specified value.
+
+
+
+
+
+-
+
+**discounted_subtotal_gte:** `typing.Optional[int]` — Return only receivables whose discounted subtotal (in minor units) is greater than or equal to the specified value.
+
+
+
+
+
+-
+
+**discounted_subtotal_lt:** `typing.Optional[int]` — Return only receivables whose discounted subtotal (in minor units) is less than the specified value.
+
+
+
+
+
+-
+
+**discounted_subtotal_lte:** `typing.Optional[int]` — Return only receivables whose discounted subtotal (in minor units) is less than or equal to the specified value.
+
+
+
+
+
+-
+
+**based_on:** `typing.Optional[str]`
+
+This parameter accepts a quote ID or an invoice ID.
+
+* Specify a quote ID to find invoices created from this quote.
+* Specify an invoice ID to find credit notes created for this invoice.
+
+Valid but nonexistent IDs do not raise errors but produce no results.
+
+
+
+
+
+-
+
+**counterpart_id:** `typing.Optional[str]`
+
+Return only receivables created for the counterpart with the specified ID.
+
+Counterparts that have been deleted but have associated receivables will still return results here because the receivables contain a frozen copy of the counterpart data.
+
+If the specified counterpart ID does not exist and never existed, no results are returned.
+
+
+
+
+
+-
+
+**counterpart_name:** `typing.Optional[str]` — Return only receivables created for counterparts with the specified name (exact match, case-sensitive). For counterparts of `type` = `individual`, the full name is formatted as `first_name last_name`.
+
+
+
+
+
+-
+
+**counterpart_name_contains:** `typing.Optional[str]` — Return only receivables created for counterparts whose name contains the specified string (case-sensitive).
+
+
+
+
+
+-
+
+**counterpart_name_icontains:** `typing.Optional[str]` — Return only receivables created for counterparts whose name contains the specified string (case-insensitive).
+
+
+
+
+
+-
+
+**created_at_gt:** `typing.Optional[dt.datetime]` — Return only receivables created after the specified date and time. The value must be in the ISO 8601 format `YYYY-MM-DDThh:mm[:ss[.ffffff]][Z|±hh:mm]`.
+
+
+
+
+
+-
+
+**created_at_gte:** `typing.Optional[dt.datetime]` — Return only receivables created on or after the specified date and time.
+
+
+
+
+
+-
+
+**created_at_lt:** `typing.Optional[dt.datetime]` — Return only receivables created before the specified date and time.
+
+
+
+
+
+-
+
+**created_at_lte:** `typing.Optional[dt.datetime]` — Return only receivables created before or on the specified date and time.
+
+
+
+
+
+-
+
+**document_id:** `typing.Optional[str]` — Return a receivable with the exact specified document number (case-sensitive). The `document_id` is the user-facing document number such as INV-00042, not to be confused with Monite resource IDs (`id`).
+
+
+
+
+
+-
+
+**document_id_contains:** `typing.Optional[str]` — Return only receivables whose document number (`document_id`) contains the specified string (case-sensitive).
+
+
+
+
+
+-
+
+**document_id_icontains:** `typing.Optional[str]` — Return only receivables whose document number (`document_id`) contains the specified string (case-insensitive).
+
+
+
+
+
+-
+
+**due_date_gt:** `typing.Optional[str]`
+
+Return invoices that are due after the specified date (exclusive, `YYYY-MM-DD`).
+
+This filter excludes quotes, credit notes, and draft invoices.
+
+
+
+
+
+-
+
+**due_date_gte:** `typing.Optional[str]`
+
+Return invoices that are due on or after the specified date (`YYYY-MM-DD`).
+
+This filter excludes quotes, credit notes, and draft invoices.
+
+
+
+
+
+-
+
+**due_date_lt:** `typing.Optional[str]`
+
+Return invoices that are due before the specified date (exclusive, `YYYY-MM-DD`).
+
+This filter excludes quotes, credit notes, and draft invoices.
+
+
+
+
+
+-
+
+**due_date_lte:** `typing.Optional[str]`
+
+Return invoices that are due before or on the specified date (`YYYY-MM-DD`).
+
+This filter excludes quotes, credit notes, and draft invoices.
+
+
+
+
+
+-
+
+**entity_user_id:** `typing.Optional[str]`
+
+Return only receivables created by the entity user with the specified ID. To query receivables by multiple user IDs at once, use the `entity_user_id__in` parameter instead.
+
+If the request is authenticated using an entity user token, this user must have the `receivable.read.allowed` (rather than `allowed_for_own`) permission to be able to query receivables created by other users.
+
+IDs of deleted users will still produce results here if those users had associated receivables. Valid but nonexistent user IDs do not raise errors but produce no results.
+
+
+
+
+
+-
+
+**entity_user_id_in:** `typing.Optional[typing.Sequence[str]]`
+
+
+
+
+
+-
+
+**id_in:** `typing.Optional[typing.Sequence[str]]`
+
+
+
+
+
+-
+
+**issue_date_gt:** `typing.Optional[dt.datetime]` — Return only non-draft receivables that were issued after the specified date and time. The value must be in the ISO 8601 format `YYYY-MM-DDThh:mm[:ss[.ffffff]][Z|±hh:mm]`.
+
+
+
+
+
+-
+
+**issue_date_gte:** `typing.Optional[dt.datetime]` — Return only non-draft receivables that were issued on or after the specified date and time.
+
+
+
+
+
+-
+
+**issue_date_lt:** `typing.Optional[dt.datetime]` — Return only non-draft receivables that were issued before the specified date and time.
+
+
+
+
+
+-
+
+**issue_date_lte:** `typing.Optional[dt.datetime]` — Return only non-draft receivables that were issued before or on the specified date and time.
+
+
+
+
+
+-
+
+**limit:** `typing.Optional[int]`
+
+
+
+
+
+-
+
+**order:** `typing.Optional[OrderEnum]`
@@ -19980,64 +22651,91 @@ client.receivables.create(request=ReceivableFacadeCreateQuotePayload(counterpart
-
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+**pagination_token:** `typing.Optional[str]`
-
-
+
+-
+**product_ids:** `typing.Optional[typing.Sequence[str]]`
+
-
-client.receivables.get_receivables_required_fields(...)
-
-#### 📝 Description
+**product_ids_in:** `typing.Optional[typing.Sequence[str]]`
+
+
+
-
+**project_id:** `typing.Optional[str]` — Return only receivables assigned to the project with the specified ID. Valid but nonexistent project IDs do not raise errors but return no results.
+
+
+
+
-
-Get field requirements for invoice creation given the entity and counterpart details.
-
-
+**project_id_in:** `typing.Optional[typing.Sequence[str]]`
+
-#### 🔌 Usage
-
-
+**sort:** `typing.Optional[ReceivableCursorFields2]`
+
+
+
+
-
-```python
-from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.receivables.get_receivables_required_fields()
+**status:** `typing.Optional[ReceivablesSearchRequestStatus]`
-```
+Return only receivables that have the specified status. See the applicable [invoice statuses](https://docs.monite.com/accounts-receivable/invoices/index), [quote statuses](https://docs.monite.com/accounts-receivable/quotes/index), and [credit note statuses](https://docs.monite.com/accounts-receivable/credit-notes#credit-note-lifecycle).
+
+To query multiple statuses at once, use the `status__in` parameter instead.
+
+
+
+-
+
+**status_in:** `typing.Optional[typing.Sequence[str]]`
+
-#### ⚙️ Parameters
+
+-
+
+**tag_ids:** `typing.Optional[typing.Sequence[str]]`
+
+
+
-
+**tag_ids_in:** `typing.Optional[typing.Sequence[str]]`
+
+
+
+
-
-**counterpart_id:** `typing.Optional[str]`
+**total_amount:** `typing.Optional[int]` — Return only receivables with the exact specified total amount. The amount must be specified in the [minor units](https://docs.monite.com/references/currencies#minor-units) of currency. For example, $12.5 is represented as 1250.
@@ -20045,7 +22743,7 @@ client.receivables.get_receivables_required_fields()
-
-**counterpart_billing_address_id:** `typing.Optional[str]`
+**total_amount_gt:** `typing.Optional[int]` — Return only receivables whose total amount (in minor units) exceeds the specified value.
@@ -20053,7 +22751,7 @@ client.receivables.get_receivables_required_fields()
-
-**counterpart_country:** `typing.Optional[AllowedCountries]`
+**total_amount_gte:** `typing.Optional[int]` — Return only receivables whose total amount (in minor units) is greater than or equal to the specified value.
@@ -20061,7 +22759,7 @@ client.receivables.get_receivables_required_fields()
-
-**counterpart_type:** `typing.Optional[CounterpartType]`
+**total_amount_lt:** `typing.Optional[int]` — Return only receivables whose total amount (in minor units) is less than the specified value.
@@ -20069,7 +22767,7 @@ client.receivables.get_receivables_required_fields()
-
-**entity_vat_id_id:** `typing.Optional[str]`
+**total_amount_lte:** `typing.Optional[int]` — Return only receivables whose total amount (in minor units) is less than or equal to the specified value.
@@ -20077,7 +22775,7 @@ client.receivables.get_receivables_required_fields()
-
-**counterpart_vat_id_id:** `typing.Optional[str]`
+**type:** `typing.Optional[ReceivableType]` — Return only receivables of the specified type. Use this parameter to get only invoices, or only quotes, or only credit notes.
@@ -20125,7 +22823,12 @@ Get a list of placeholders that can be used in email templates for customization
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.receivables.get_variables()
```
@@ -20168,8 +22871,15 @@ client.receivables.get_variables()
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.receivables.get_by_id(receivable_id='receivable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.receivables.get_by_id(
+ receivable_id="receivable_id",
+)
```
@@ -20219,8 +22929,15 @@ client.receivables.get_by_id(receivable_id='receivable_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.receivables.delete_by_id(receivable_id='receivable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.receivables.delete_by_id(
+ receivable_id="receivable_id",
+)
```
@@ -20269,11 +22986,19 @@ client.receivables.delete_by_id(receivable_id='receivable_id', )
```python
-from monite import Monite
-from monite import UpdateQuotePayload
-from monite import UpdateQuote
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.receivables.update_by_id(receivable_id='receivable_id', request=UpdateQuotePayload(quote=UpdateQuote(), ), )
+from monite import Monite, UpdateQuote, UpdateQuotePayload
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.receivables.update_by_id(
+ receivable_id="receivable_id",
+ request=UpdateQuotePayload(
+ quote=UpdateQuote(),
+ ),
+)
```
@@ -20331,8 +23056,15 @@ client.receivables.update_by_id(receivable_id='receivable_id', request=UpdateQuo
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.receivables.accept_by_id(receivable_id='receivable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.receivables.accept_by_id(
+ receivable_id="receivable_id",
+)
```
@@ -20390,8 +23122,15 @@ client.receivables.accept_by_id(receivable_id='receivable_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.receivables.cancel_by_id(receivable_id='receivable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.receivables.cancel_by_id(
+ receivable_id="receivable_id",
+)
```
@@ -20441,8 +23180,15 @@ client.receivables.cancel_by_id(receivable_id='receivable_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.receivables.clone_by_id(receivable_id='receivable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.receivables.clone_by_id(
+ receivable_id="receivable_id",
+)
```
@@ -20492,8 +23238,15 @@ client.receivables.clone_by_id(receivable_id='receivable_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.receivables.decline_by_id(receivable_id='receivable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.receivables.decline_by_id(
+ receivable_id="receivable_id",
+)
```
@@ -20567,8 +23320,15 @@ You can filter the history by the date range and event type. Events are sorted f
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.receivables.get_history(receivable_id='receivable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.receivables.get_history(
+ receivable_id="receivable_id",
+)
```
@@ -20628,7 +23388,12 @@ If not specified, the first page of results will be returned.
-
-**event_type_in:** `typing.Optional[typing.Union[ReceivableHistoryEventTypeEnum, typing.Sequence[ReceivableHistoryEventTypeEnum]]]`
+**event_type_in:** `typing.Optional[
+ typing.Union[
+ ReceivableHistoryEventTypeEnum,
+ typing.Sequence[ReceivableHistoryEventTypeEnum],
+ ]
+]`
Return only the specified [event types](https://docs.monite.com/accounts-receivable/document-history#event-types). To include multiple types, repeat this parameter for each value:
`event_type__in=receivable_updated&event_type__in=status_changed`
@@ -20722,8 +23487,16 @@ Returns a single record from the change history of the specified accounts receiv
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.receivables.get_history_by_id(receivable_history_id='receivable_history_id', receivable_id='receivable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.receivables.get_history_by_id(
+ receivable_history_id="receivable_history_id",
+ receivable_id="receivable_id",
+)
```
@@ -20781,8 +23554,15 @@ client.receivables.get_history_by_id(receivable_history_id='receivable_history_i
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.receivables.issue_by_id(receivable_id='receivable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.receivables.issue_by_id(
+ receivable_id="receivable_id",
+)
```
@@ -20844,11 +23624,235 @@ Replace all line items of an existing invoice or quote with a new list of line i
-
+```python
+from monite import LineItem, Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.receivables.update_line_items_by_id(
+ receivable_id="receivable_id",
+ data=[
+ LineItem(
+ quantity=1.1,
+ )
+ ],
+)
+
+```
+
+
+
+
+
+#### ⚙️ Parameters
+
+
+-
+
+
+-
+
+**receivable_id:** `str`
+
+
+
+
+
+-
+
+**data:** `typing.Sequence[LineItem]`
+
+
+
+
+
+-
+
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
+
+
+
+
+
+
+
+
+
+client.receivables.get_mails(...)
+
+-
+
+#### 🔌 Usage
+
+
+-
+
+
+-
+
+```python
+from monite import Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.receivables.get_mails(
+ receivable_id="receivable_id",
+)
+
+```
+
+
+
+
+
+#### ⚙️ Parameters
+
+
+-
+
+
+-
+
+**receivable_id:** `str`
+
+
+
+
+
+-
+
+**order:** `typing.Optional[OrderEnum]` — Sort order (ascending by default). Typically used together with the `sort` parameter.
+
+
+
+
+
+-
+
+**limit:** `typing.Optional[int]` — The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+
+
+
+
+
+-
+
+**pagination_token:** `typing.Optional[str]`
+
+A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+
+If not specified, the first page of results will be returned.
+
+
+
+
+
+-
+
+**sort:** `typing.Optional[ReceivableMailCursorFields]` — The field to sort the results by. Typically used together with the `order` parameter.
+
+
+
+
+
+-
+
+**status:** `typing.Optional[ReceivableMailStatusEnum]`
+
+
+
+
+
+-
+
+**status_in:** `typing.Optional[
+ typing.Union[
+ ReceivableMailStatusEnum, typing.Sequence[ReceivableMailStatusEnum]
+ ]
+]`
+
+
+
+
+
+-
+
+**created_at_gt:** `typing.Optional[dt.datetime]`
+
+
+
+
+
+-
+
+**created_at_lt:** `typing.Optional[dt.datetime]`
+
+
+
+
+
+-
+
+**created_at_gte:** `typing.Optional[dt.datetime]`
+
+
+
+
+
+-
+
+**created_at_lte:** `typing.Optional[dt.datetime]`
+
+
+
+
+
+-
+
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
+
+
+
+
+
+
+
+
+
+client.receivables.get_mail_by_id(...)
+
+-
+
+#### 🔌 Usage
+
+
+-
+
+
+-
+
```python
from monite import Monite
-from monite import LineItem
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.receivables.update_line_items_by_id(receivable_id='receivable_id', data=[LineItem(quantity=1.1, )], )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.receivables.get_mail_by_id(
+ receivable_id="receivable_id",
+ mail_id="mail_id",
+)
```
@@ -20872,7 +23876,7 @@ client.receivables.update_line_items_by_id(receivable_id='receivable_id', data=[
-
-**data:** `typing.Sequence[LineItem]`
+**mail_id:** `str`
@@ -20892,7 +23896,7 @@ client.receivables.update_line_items_by_id(receivable_id='receivable_id', data=[
-client.receivables.get_mails(...)
+client.receivables.mark_as_paid_by_id(...)
-
@@ -20906,8 +23910,15 @@ client.receivables.update_line_items_by_id(receivable_id='receivable_id', data=[
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.receivables.get_mails(receivable_id='receivable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.receivables.mark_as_paid_by_id(
+ receivable_id="receivable_id",
+)
```
@@ -20931,7 +23942,7 @@ client.receivables.get_mails(receivable_id='receivable_id', )
-
-**order:** `typing.Optional[OrderEnum]` — Sort order (ascending by default). Typically used together with the `sort` parameter.
+**comment:** `typing.Optional[str]` — Optional comment explaining how the payment was made.
@@ -20939,7 +23950,7 @@ client.receivables.get_mails(receivable_id='receivable_id', )
-
-**limit:** `typing.Optional[int]` — The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+**paid_at:** `typing.Optional[dt.datetime]` — Date and time when the invoice was paid.
@@ -20947,51 +23958,72 @@ client.receivables.get_mails(receivable_id='receivable_id', )
-
-**pagination_token:** `typing.Optional[str]`
-
-A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
-
-If not specified, the first page of results will be returned.
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
-
--
-**sort:** `typing.Optional[ReceivableMailCursorFields]` — The field to sort the results by. Typically used together with the `order` parameter.
-
+
+client.receivables.mark_as_partially_paid_by_id(...)
-
-**status:** `typing.Optional[ReceivableMailStatusEnum]`
-
-
-
+#### 📝 Description
-
-**status_in:** `typing.Optional[typing.Union[ReceivableMailStatusEnum, typing.Sequence[ReceivableMailStatusEnum]]]`
-
+
+-
+
+Deprecated. Use `POST /payment_records` to record an invoice payment.
+
+
+#### 🔌 Usage
+
-
-**created_at_gt:** `typing.Optional[dt.datetime]`
-
+
+-
+
+```python
+from monite import Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.receivables.mark_as_partially_paid_by_id(
+ receivable_id="receivable_id",
+ amount_paid=1,
+)
+
+```
+
+
+#### ⚙️ Parameters
+
-
-**created_at_lt:** `typing.Optional[dt.datetime]`
+
+-
+
+**receivable_id:** `str`
@@ -20999,7 +24031,7 @@ If not specified, the first page of results will be returned.
-
-**created_at_gte:** `typing.Optional[dt.datetime]`
+**amount_paid:** `int` — How much has been paid on the invoice (in minor units).
@@ -21007,7 +24039,7 @@ If not specified, the first page of results will be returned.
-
-**created_at_lte:** `typing.Optional[dt.datetime]`
+**comment:** `typing.Optional[str]` — Optional comment explaining how the payment was made.
@@ -21027,7 +24059,7 @@ If not specified, the first page of results will be returned.
-client.receivables.get_mail_by_id(...)
+client.receivables.mark_as_uncollectible_by_id(...)
-
@@ -21041,8 +24073,15 @@ If not specified, the first page of results will be returned.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.receivables.get_mail_by_id(receivable_id='receivable_id', mail_id='mail_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.receivables.mark_as_uncollectible_by_id(
+ receivable_id="receivable_id",
+)
```
@@ -21066,7 +24105,7 @@ client.receivables.get_mail_by_id(receivable_id='receivable_id', mail_id='mail_i
-
-**mail_id:** `str`
+**comment:** `typing.Optional[str]` — Optional comment explains why the Invoice goes uncollectible.
@@ -21086,7 +24125,7 @@ client.receivables.get_mail_by_id(receivable_id='receivable_id', mail_id='mail_i
-client.receivables.mark_as_paid_by_id(...)
+client.receivables.get_pdf_link_by_id(...)
-
@@ -21100,8 +24139,15 @@ client.receivables.get_mail_by_id(receivable_id='receivable_id', mail_id='mail_i
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.receivables.mark_as_paid_by_id(receivable_id='receivable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.receivables.get_pdf_link_by_id(
+ receivable_id="receivable_id",
+)
```
@@ -21125,22 +24171,6 @@ client.receivables.mark_as_paid_by_id(receivable_id='receivable_id', )
-
-**comment:** `typing.Optional[str]` — Optional comment explaining how the payment was made.
-
-
-
-
-
--
-
-**paid_at:** `typing.Optional[dt.datetime]` — Date and time when the invoice was paid.
-
-
-
-
-
--
-
**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -21153,11 +24183,11 @@ client.receivables.mark_as_paid_by_id(receivable_id='receivable_id', )
-client.receivables.mark_as_partially_paid_by_id(...)
+client.receivables.preview_by_id(...)
-
-#### 📝 Description
+#### 🔌 Usage
-
@@ -21165,13 +24195,27 @@ client.receivables.mark_as_paid_by_id(receivable_id='receivable_id', )
-
-Deprecated. Use `POST /payment_records` to record an invoice payment.
+```python
+from monite import Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.receivables.preview_by_id(
+ receivable_id="receivable_id",
+ body_text="body_text",
+ subject_text="subject_text",
+)
+
+```
-#### 🔌 Usage
+#### ⚙️ Parameters
-
@@ -21179,26 +24223,23 @@ Deprecated. Use `POST /payment_records` to record an invoice payment.
-
-```python
-from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.receivables.mark_as_partially_paid_by_id(receivable_id='receivable_id', amount_paid=1, )
-
-```
-
-
+**receivable_id:** `str`
+
-#### ⚙️ Parameters
-
-
+**body_text:** `str` — Body text of the content
+
+
+
+
-
-**receivable_id:** `str`
+**subject_text:** `str` — Subject text of the content
@@ -21206,7 +24247,7 @@ client.receivables.mark_as_partially_paid_by_id(receivable_id='receivable_id', a
-
-**amount_paid:** `int` — How much has been paid on the invoice (in minor units).
+**language:** `typing.Optional[LanguageCodeEnum]` — Language code for localization purposes
@@ -21214,7 +24255,7 @@ client.receivables.mark_as_partially_paid_by_id(receivable_id='receivable_id', a
-
-**comment:** `typing.Optional[str]` — Optional comment explaining how the payment was made.
+**type:** `typing.Optional[ReceivablesPreviewTypeEnum]` — The type of the preview document.
@@ -21234,7 +24275,7 @@ client.receivables.mark_as_partially_paid_by_id(receivable_id='receivable_id', a
-client.receivables.mark_as_uncollectible_by_id(...)
+client.receivables.send_by_id(...)
-
@@ -21248,8 +24289,17 @@ client.receivables.mark_as_partially_paid_by_id(receivable_id='receivable_id', a
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.receivables.mark_as_uncollectible_by_id(receivable_id='receivable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.receivables.send_by_id(
+ receivable_id="receivable_id",
+ body_text="body_text",
+ subject_text="subject_text",
+)
```
@@ -21273,7 +24323,23 @@ client.receivables.mark_as_uncollectible_by_id(receivable_id='receivable_id', )
-
-**comment:** `typing.Optional[str]` — Optional comment explains why the Invoice goes uncollectible.
+**body_text:** `str` — Body text of the content
+
+
+
+
+
+-
+
+**subject_text:** `str` — Subject text of the content
+
+
+
+
+
+-
+
+**recipients:** `typing.Optional[Recipients]`
@@ -21293,7 +24359,7 @@ client.receivables.mark_as_uncollectible_by_id(receivable_id='receivable_id', )
-client.receivables.get_pdf_link_by_id(...)
+client.receivables.send_test_reminder_by_id(...)
-
@@ -21307,8 +24373,16 @@ client.receivables.mark_as_uncollectible_by_id(receivable_id='receivable_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.receivables.get_pdf_link_by_id(receivable_id='receivable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.receivables.send_test_reminder_by_id(
+ receivable_id="receivable_id",
+ reminder_type="term_1",
+)
```
@@ -21332,6 +24406,22 @@ client.receivables.get_pdf_link_by_id(receivable_id='receivable_id', )
-
+**reminder_type:** `ReminderTypeEnum` — The type of the reminder to be sent.
+
+
+
+
+
+-
+
+**recipients:** `typing.Optional[Recipients]`
+
+
+
+
+
+-
+
**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -21344,7 +24434,7 @@ client.receivables.get_pdf_link_by_id(receivable_id='receivable_id', )
-client.receivables.preview_by_id(...)
+client.receivables.verify_by_id(...)
-
@@ -21358,8 +24448,15 @@ client.receivables.get_pdf_link_by_id(receivable_id='receivable_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.receivables.preview_by_id(receivable_id='receivable_id', body_text='body_text', subject_text='subject_text', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.receivables.verify_by_id(
+ receivable_id="receivable_id",
+)
```
@@ -21383,35 +24480,52 @@ client.receivables.preview_by_id(receivable_id='receivable_id', body_text='body_
-
-**body_text:** `str` — Body text of the content
+**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
-
--
-**subject_text:** `str` — Subject text of the content
-
+
+## Recurrences
+client.recurrences.get()
-
-**language:** `typing.Optional[LanguageCodeEnum]` — Language code for localization purposes
-
-
-
+#### 🔌 Usage
-
-**type:** `typing.Optional[ReceivablesPreviewTypeEnum]` — The type of the preview document.
-
+
+-
+
+```python
+from monite import Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.recurrences.get()
+
+```
+
+
+#### ⚙️ Parameters
+
+
+-
+
-
@@ -21427,7 +24541,7 @@ client.receivables.preview_by_id(receivable_id='receivable_id', body_text='body_
-client.receivables.send_by_id(...)
+client.recurrences.create(...)
-
@@ -21441,8 +24555,15 @@ client.receivables.preview_by_id(receivable_id='receivable_id', body_text='body_
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.receivables.send_by_id(receivable_id='receivable_id', body_text='body_text', subject_text='subject_text', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.recurrences.create(
+ invoice_id="invoice_id",
+)
```
@@ -21458,7 +24579,7 @@ client.receivables.send_by_id(receivable_id='receivable_id', body_text='body_tex
-
-**receivable_id:** `str`
+**invoice_id:** `str` — ID of the base invoice that will be used as a template for creating recurring invoices.
@@ -21466,7 +24587,16 @@ client.receivables.send_by_id(receivable_id='receivable_id', body_text='body_tex
-
-**body_text:** `str` — Body text of the content
+**automation_level:** `typing.Optional[AutomationLevel]`
+
+Controls how invoices are processed when generated:
+- "draft": Creates invoices in draft status, requiring manual review, issuing, and sending
+- "issue": Automatically issues invoices but requires manual sending
+- "issue_and_send": Fully automates the process (creates, issues, and sends invoices)
+
+Default: "issue" (or "issue_and_send" if subject_text and body_text are provided)
+
+Note: When using "issue_and_send", both subject_text and body_text must be provided.
@@ -21474,7 +24604,7 @@ client.receivables.send_by_id(receivable_id='receivable_id', body_text='body_tex
-
-**subject_text:** `str` — Subject text of the content
+**body_text:** `typing.Optional[str]` — The body text for the email that will be sent with the recurring invoice.
@@ -21482,7 +24612,7 @@ client.receivables.send_by_id(receivable_id='receivable_id', body_text='body_tex
-
-**recipients:** `typing.Optional[Recipients]`
+**day_of_month:** `typing.Optional[DayOfMonth]` — Deprecated, use `start_date` instead
@@ -21490,50 +24620,71 @@ client.receivables.send_by_id(receivable_id='receivable_id', body_text='body_tex
-
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+**end_date:** `typing.Optional[str]` — The end date of the recurring invoice, in the `yyyy-mm-dd` format. The end date is inclusive, that is, the last invoice will be created on this date if the last occurrence falls on this date. `end_date` is mutually exclusive with `max_occurrences`. Either `end_date` or `max_occurrences` must be specified.
+
+
+-
+
+**end_month:** `typing.Optional[int]` — Deprecated, use `end_date` instead
+
+
+-
+**end_year:** `typing.Optional[int]` — Deprecated, use `end_date` instead
+
-
-client.receivables.send_test_reminder_by_id(...)
-
-#### 🔌 Usage
+**frequency:** `typing.Optional[RecurrenceFrequency]` — How often the invoice will be created.
+
+
+
-
+**interval:** `typing.Optional[int]` — The interval between each occurrence of the invoice. For example, when using monthly frequency, an interval of 1 means invoices will be created every month, an interval of 2 means invoices will be created every 2 months.
+
+
+
+
-
-```python
-from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.receivables.send_test_reminder_by_id(receivable_id='receivable_id', reminder_type="term_1", )
-
-```
+**max_occurrences:** `typing.Optional[int]` — How many times the recurring invoice will be created. The recurrence will stop after this number is reached. `max_occurrences` is mutually exclusive with `end_date`. Either `max_occurrences` or `end_date` must be specified.
+
+
+
+-
+
+**recipients:** `typing.Optional[Recipients]` — An object containing the recipients (To, CC, BCC) of the recurring invoices. Can be omitted if the base invoice has the counterpart contact email specified in the `counterpart_contact.email` field.
+
-#### ⚙️ Parameters
-
-
+**start_date:** `typing.Optional[str]` — The date when the first invoice will be created, in the `yyyy-mm-dd` format. Cannot be a past date. Subsequent invoice dates will be calculated based on `start_date`, `frequency`, and `interval`.
+
+
+
+
-
-**receivable_id:** `str`
+**start_month:** `typing.Optional[int]` — Deprecated, use `start_date` instead
@@ -21541,7 +24692,7 @@ client.receivables.send_test_reminder_by_id(receivable_id='receivable_id', remin
-
-**reminder_type:** `ReminderTypeEnum` — The type of the reminder to be sent.
+**start_year:** `typing.Optional[int]` — Deprecated, use `start_date` instead
@@ -21549,7 +24700,7 @@ client.receivables.send_test_reminder_by_id(receivable_id='receivable_id', remin
-
-**recipients:** `typing.Optional[Recipients]`
+**subject_text:** `typing.Optional[str]` — The subject for the email that will be sent with the recurring invoice.
@@ -21569,7 +24720,7 @@ client.receivables.send_test_reminder_by_id(receivable_id='receivable_id', remin
-client.receivables.verify_by_id(...)
+client.recurrences.get_by_id(...)
-
@@ -21583,8 +24734,15 @@ client.receivables.send_test_reminder_by_id(receivable_id='receivable_id', remin
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.receivables.verify_by_id(receivable_id='receivable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.recurrences.get_by_id(
+ recurrence_id="recurrence_id",
+)
```
@@ -21600,7 +24758,7 @@ client.receivables.verify_by_id(receivable_id='receivable_id', )
-
-**receivable_id:** `str`
+**recurrence_id:** `str`
@@ -21620,8 +24778,7 @@ client.receivables.verify_by_id(receivable_id='receivable_id', )
-## Recurrences
-client.recurrences.get()
+client.recurrences.update_by_id(...)
-
@@ -21635,8 +24792,15 @@ client.receivables.verify_by_id(receivable_id='receivable_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.recurrences.get()
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.recurrences.update_by_id(
+ recurrence_id="recurrence_id",
+)
```
@@ -21652,50 +24816,40 @@ client.recurrences.get()
-
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+**recurrence_id:** `str`
-
-
-
-
-
-
-
-client.recurrences.create(...)
-
-#### 🔌 Usage
-
-
--
+**automation_level:** `typing.Optional[AutomationLevel]`
-
--
+Controls how invoices are processed when generated:
+- "draft": Creates invoices in draft status, requiring manual review, issuing, and sending
+- "issue": Automatically issues invoices but requires manual sending
+- "issue_and_send": Fully automates the process (creates, issues, and sends invoices)
-```python
-from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.recurrences.create(day_of_month="first_day", end_month=1, end_year=1, invoice_id='invoice_id', start_month=1, start_year=1, )
+Default: "issue" (or "issue_and_send" if subject_text and body_text are provided)
-```
-
-
+Note: When using "issue_and_send", both subject_text and body_text must be provided.
+
-#### ⚙️ Parameters
-
-
+**body_text:** `typing.Optional[str]` — The body text for the email that will be sent with the recurring invoice.
+
+
+
+
-
-**day_of_month:** `DayOfMonth`
+**day_of_month:** `typing.Optional[DayOfMonth]` — Deprecated, use `start_date` instead
@@ -21703,7 +24857,7 @@ client.recurrences.create(day_of_month="first_day", end_month=1, end_year=1, inv
-
-**end_month:** `int`
+**end_date:** `typing.Optional[str]` — The end date of the recurring invoice, in the `yyyy-mm-dd` format. The end date is inclusive, that is, the last invoice will be created on this date if the last occurrence falls on this date. `end_date` is mutually exclusive with `max_occurrences`. Either `end_date` or `max_occurrences` must be specified.
@@ -21711,7 +24865,7 @@ client.recurrences.create(day_of_month="first_day", end_month=1, end_year=1, inv
-
-**end_year:** `int`
+**end_month:** `typing.Optional[int]` — Deprecated, use `end_date` instead
@@ -21719,7 +24873,7 @@ client.recurrences.create(day_of_month="first_day", end_month=1, end_year=1, inv
-
-**invoice_id:** `str`
+**end_year:** `typing.Optional[int]` — Deprecated, use `end_date` instead
@@ -21727,7 +24881,7 @@ client.recurrences.create(day_of_month="first_day", end_month=1, end_year=1, inv
-
-**start_month:** `int`
+**frequency:** `typing.Optional[RecurrenceFrequency]` — How often the invoice will be created.
@@ -21735,7 +24889,7 @@ client.recurrences.create(day_of_month="first_day", end_month=1, end_year=1, inv
-
-**start_year:** `int`
+**interval:** `typing.Optional[int]` — The interval between each occurrence of the invoice. For example, when using monthly frequency, an interval of 1 means invoices will be created every month, an interval of 2 means invoices will be created every 2 months.
@@ -21743,16 +24897,7 @@ client.recurrences.create(day_of_month="first_day", end_month=1, end_year=1, inv
-
-**automation_level:** `typing.Optional[AutomationLevel]`
-
-Controls how invoices are processed when generated:
-- "draft": Creates invoices in draft status, requiring manual review, issuing, and sending
-- "issue": Automatically issues invoices but requires manual sending
-- "issue_and_send": Fully automates the process (creates, issues, and sends invoices)
-
-Default: "issue" (or "issue_and_send" if subject_text and body_text are provided)
-
-Note: When using "issue_and_send", both subject_text and body_text must be provided.
+**max_occurrences:** `typing.Optional[int]` — How many times the recurring invoice will be created. The recurrence will stop after this number is reached. `max_occurrences` is mutually exclusive with `end_date`. Either `max_occurrences` or `end_date` must be specified.
@@ -21760,7 +24905,7 @@ Note: When using "issue_and_send", both subject_text and body_text must be provi
-
-**body_text:** `typing.Optional[str]`
+**recipients:** `typing.Optional[Recipients]` — An object containing the recipients (To, CC, BCC) of the recurring invoices. Can be omitted if the base invoice has the counterpart contact email specified in the `counterpart_contact.email` field.
@@ -21768,7 +24913,7 @@ Note: When using "issue_and_send", both subject_text and body_text must be provi
-
-**recipients:** `typing.Optional[Recipients]`
+**start_date:** `typing.Optional[str]` — The date when the first invoice will be created, in the `yyyy-mm-dd` format. Cannot be a past date. Subsequent invoice dates will be calculated based on `start_date`, `frequency`, and `interval`.
@@ -21776,7 +24921,7 @@ Note: When using "issue_and_send", both subject_text and body_text must be provi
-
-**subject_text:** `typing.Optional[str]`
+**subject_text:** `typing.Optional[str]` — The subject for the email that will be sent with the recurring invoice.
@@ -21796,7 +24941,7 @@ Note: When using "issue_and_send", both subject_text and body_text must be provi
-client.recurrences.get_by_id(...)
+client.recurrences.cancel_by_id(...)
-
@@ -21810,8 +24955,15 @@ Note: When using "issue_and_send", both subject_text and body_text must be provi
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.recurrences.get_by_id(recurrence_id='recurrence_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.recurrences.cancel_by_id(
+ recurrence_id="recurrence_id",
+)
```
@@ -21847,7 +24999,7 @@ client.recurrences.get_by_id(recurrence_id='recurrence_id', )
-client.recurrences.update_by_id(...)
+client.recurrences.post_recurrences_id_pause(...)
-
@@ -21861,8 +25013,15 @@ client.recurrences.get_by_id(recurrence_id='recurrence_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.recurrences.update_by_id(recurrence_id='recurrence_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.recurrences.post_recurrences_id_pause(
+ recurrence_id="recurrence_id",
+)
```
@@ -21886,71 +25045,6 @@ client.recurrences.update_by_id(recurrence_id='recurrence_id', )
-
-**automation_level:** `typing.Optional[AutomationLevel]`
-
-Controls how invoices are processed when generated:
-- "draft": Creates invoices in draft status, requiring manual review, issuing, and sending
-- "issue": Automatically issues invoices but requires manual sending
-- "issue_and_send": Fully automates the process (creates, issues, and sends invoices)
-
-Default: "issue" (or "issue_and_send" if subject_text and body_text are provided)
-
-Note: When using "issue_and_send", both subject_text and body_text must be provided.
-
-
-
-
-
--
-
-**body_text:** `typing.Optional[str]`
-
-
-
-
-
--
-
-**day_of_month:** `typing.Optional[DayOfMonth]`
-
-
-
-
-
--
-
-**end_month:** `typing.Optional[int]`
-
-
-
-
-
--
-
-**end_year:** `typing.Optional[int]`
-
-
-
-
-
--
-
-**recipients:** `typing.Optional[Recipients]`
-
-
-
-
-
--
-
-**subject_text:** `typing.Optional[str]`
-
-
-
-
-
--
-
**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -21963,7 +25057,7 @@ Note: When using "issue_and_send", both subject_text and body_text must be provi
-client.recurrences.cancel_by_id(...)
+client.recurrences.post_recurrences_id_resume(...)
-
@@ -21977,8 +25071,15 @@ Note: When using "issue_and_send", both subject_text and body_text must be provi
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.recurrences.cancel_by_id(recurrence_id='recurrence_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.recurrences.post_recurrences_id_resume(
+ recurrence_id="recurrence_id",
+)
```
@@ -22043,7 +25144,12 @@ Find all roles that match the search criteria.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.roles.get()
```
@@ -22191,10 +25297,17 @@ Create a new role from the specified values.
-
```python
-from monite import Monite
-from monite import BizObjectsSchemaInput
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.roles.create(name='name', permissions=BizObjectsSchemaInput(), )
+from monite import BizObjectsSchemaInput, Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.roles.create(
+ name="name",
+ permissions=BizObjectsSchemaInput(),
+)
```
@@ -22252,8 +25365,15 @@ client.roles.create(name='name', permissions=BizObjectsSchemaInput(), )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.roles.get_by_id(role_id='role_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.roles.get_by_id(
+ role_id="role_id",
+)
```
@@ -22317,8 +25437,15 @@ Delete a role with the specified ID. The role being deleted must not be in use b
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.roles.delete_roles_id(role_id='role_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.roles.delete_roles_id(
+ role_id="role_id",
+)
```
@@ -22382,8 +25509,15 @@ Change the specified fields with the provided values.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.roles.update_by_id(role_id='role_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.roles.update_by_id(
+ role_id="role_id",
+)
```
@@ -22464,7 +25598,12 @@ Retrieve all settings for this partner.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.partner_settings.get()
```
@@ -22521,7 +25660,12 @@ Change the specified fields with the provided values.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.partner_settings.update()
```
@@ -22660,7 +25804,12 @@ Get a list of all tags. Tags can be assigned to resources to assist with searchi
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.tags.get()
```
@@ -22782,8 +25931,15 @@ To assign this tag to a resource, send the tag ID in the `tag_ids` list when cre
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.tags.create(name='Marketing', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.tags.create(
+ name="Marketing",
+)
```
@@ -22863,8 +26019,15 @@ Get information about a tag with the given ID.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.tags.get_by_id(tag_id='tag_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.tags.get_by_id(
+ tag_id="tag_id",
+)
```
@@ -22928,8 +26091,15 @@ Delete a tag with the given ID. This tag will be automatically deleted from all
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.tags.delete_by_id(tag_id='tag_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.tags.delete_by_id(
+ tag_id="tag_id",
+)
```
@@ -22994,8 +26164,15 @@ Change the tag name. The new name must be unique among existing tags.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.tags.update_by_id(tag_id='tag_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.tags.update_by_id(
+ tag_id="tag_id",
+)
```
@@ -23084,7 +26261,12 @@ Get text templates
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.text_templates.get()
```
@@ -23165,8 +26347,18 @@ Create a text template
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.text_templates.create(document_type="quote", name='name', template='template', type="email_header", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.text_templates.create(
+ document_type="quote",
+ name="name",
+ template="template",
+ type="email_header",
+)
```
@@ -23254,8 +26446,15 @@ Get all custom contents
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.text_templates.get_by_id(text_template_id='text_template_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.text_templates.get_by_id(
+ text_template_id="text_template_id",
+)
```
@@ -23319,8 +26518,15 @@ Delete custom content by ID
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.text_templates.delete_by_id(text_template_id='text_template_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.text_templates.delete_by_id(
+ text_template_id="text_template_id",
+)
```
@@ -23384,8 +26590,15 @@ Update custom content by ID
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.text_templates.update_by_id(text_template_id='text_template_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.text_templates.update_by_id(
+ text_template_id="text_template_id",
+)
```
@@ -23465,8 +26678,15 @@ Make text template default
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.text_templates.make_default_by_id(text_template_id='text_template_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.text_templates.make_default_by_id(
+ text_template_id="text_template_id",
+)
```
@@ -23517,7 +26737,12 @@ client.text_templates.make_default_by_id(text_template_id='text_template_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.vat_rates.get()
```
@@ -23619,7 +26844,12 @@ Note that if the same event type is included in multiple webhook subscriptions,
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.webhook_deliveries.get()
```
@@ -23755,7 +26985,12 @@ If not specified, the first page of results will be returned.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.webhook_subscriptions.get()
```
@@ -23874,8 +27109,16 @@ If not specified, the first page of results will be returned.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.webhook_subscriptions.create(object_type="account", url='url', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.webhook_subscriptions.create(
+ object_type="account",
+ url="url",
+)
```
@@ -23941,8 +27184,15 @@ client.webhook_subscriptions.create(object_type="account", url='url', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.webhook_subscriptions.get_by_id(webhook_subscription_id='webhook_subscription_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.webhook_subscriptions.get_by_id(
+ webhook_subscription_id="webhook_subscription_id",
+)
```
@@ -23992,8 +27242,15 @@ client.webhook_subscriptions.get_by_id(webhook_subscription_id='webhook_subscrip
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.webhook_subscriptions.delete_by_id(webhook_subscription_id='webhook_subscription_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.webhook_subscriptions.delete_by_id(
+ webhook_subscription_id="webhook_subscription_id",
+)
```
@@ -24043,8 +27300,15 @@ client.webhook_subscriptions.delete_by_id(webhook_subscription_id='webhook_subsc
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.webhook_subscriptions.update_by_id(webhook_subscription_id='webhook_subscription_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.webhook_subscriptions.update_by_id(
+ webhook_subscription_id="webhook_subscription_id",
+)
```
@@ -24118,8 +27382,15 @@ client.webhook_subscriptions.update_by_id(webhook_subscription_id='webhook_subsc
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.webhook_subscriptions.disable_by_id(webhook_subscription_id='webhook_subscription_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.webhook_subscriptions.disable_by_id(
+ webhook_subscription_id="webhook_subscription_id",
+)
```
@@ -24169,8 +27440,15 @@ client.webhook_subscriptions.disable_by_id(webhook_subscription_id='webhook_subs
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.webhook_subscriptions.enable_by_id(webhook_subscription_id='webhook_subscription_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.webhook_subscriptions.enable_by_id(
+ webhook_subscription_id="webhook_subscription_id",
+)
```
@@ -24220,8 +27498,15 @@ client.webhook_subscriptions.enable_by_id(webhook_subscription_id='webhook_subsc
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.webhook_subscriptions.regenerate_secret_by_id(webhook_subscription_id='webhook_subscription_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.webhook_subscriptions.regenerate_secret_by_id(
+ webhook_subscription_id="webhook_subscription_id",
+)
```
@@ -24290,7 +27575,12 @@ Data is actual as of the date and time of the last accounting synchronization, w
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.accounting.payables.get()
```
@@ -24363,8 +27653,15 @@ Returns information about an individual payable invoice (bill) that exists in th
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.accounting.payables.get_by_id(payable_id='payable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.accounting.payables.get_by_id(
+ payable_id="payable_id",
+)
```
@@ -24433,7 +27730,12 @@ Data is actual as of the date and time of the last accounting synchronization, w
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.accounting.receivables.get()
```
@@ -24506,8 +27808,15 @@ Returns information about an individual invoice that exists in the entity's acco
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.accounting.receivables.get_by_id(invoice_id='invoice_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.accounting.receivables.get_by_id(
+ invoice_id="invoice_id",
+)
```
@@ -24572,7 +27881,12 @@ Get all connections
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.accounting.connections.get()
```
@@ -24629,7 +27943,12 @@ Create new connection
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.accounting.connections.create()
```
@@ -24686,8 +28005,15 @@ Get connection by id
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.accounting.connections.get_by_id(connection_id='connection_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.accounting.connections.get_by_id(
+ connection_id="connection_id",
+)
```
@@ -24751,8 +28077,15 @@ Disconnect
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.accounting.connections.disconnect_by_id(connection_id='connection_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.accounting.connections.disconnect_by_id(
+ connection_id="connection_id",
+)
```
@@ -24802,8 +28135,15 @@ client.accounting.connections.disconnect_by_id(connection_id='connection_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.accounting.connections.sync_by_id(connection_id='connection_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.accounting.connections.sync_by_id(
+ connection_id="connection_id",
+)
```
@@ -24868,8 +28208,15 @@ Get synchronized records
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.accounting.synced_records.get(object_type="product", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.accounting.synced_records.get(
+ object_type="product",
+)
```
@@ -24901,7 +28248,11 @@ client.accounting.synced_records.get(object_type="product", )
-
-**limit:** `typing.Optional[int]` — The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+**limit:** `typing.Optional[int]`
+
+The number of items (0 .. 250) to return in a single page of the response. Default is 100. The response may contain fewer items if it is the last or only page.
+
+When using pagination with a non-default `limit`, you must provide the `limit` value alongside `pagination_token` in all subsequent pagination requests. Unlike other query parameters, `limit` is not inferred from `pagination_token`.
@@ -24911,7 +28262,7 @@ client.accounting.synced_records.get(object_type="product", )
**pagination_token:** `typing.Optional[str]`
-A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters except `limit` are ignored and inferred from the initial query.
If not specified, the first page of results will be returned.
@@ -25049,8 +28400,15 @@ Get synchronized record by id
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.accounting.synced_records.get_by_id(synced_record_id='synced_record_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.accounting.synced_records.get_by_id(
+ synced_record_id="synced_record_id",
+)
```
@@ -25114,8 +28472,15 @@ Push object to the accounting system manually
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.accounting.synced_records.push_by_id(synced_record_id='synced_record_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.accounting.synced_records.push_by_id(
+ synced_record_id="synced_record_id",
+)
```
@@ -25180,7 +28545,12 @@ Get all tax rate accounts
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.accounting.tax_rates.get()
```
@@ -25205,7 +28575,11 @@ client.accounting.tax_rates.get()
-
-**limit:** `typing.Optional[int]` — The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+**limit:** `typing.Optional[int]`
+
+The number of items (0 .. 250) to return in a single page of the response. Default is 100. The response may contain fewer items if it is the last or only page.
+
+When using pagination with a non-default `limit`, you must provide the `limit` value alongside `pagination_token` in all subsequent pagination requests. Unlike other query parameters, `limit` is not inferred from `pagination_token`.
@@ -25215,7 +28589,7 @@ client.accounting.tax_rates.get()
**pagination_token:** `typing.Optional[str]`
-A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters except `limit` are ignored and inferred from the initial query.
If not specified, the first page of results will be returned.
@@ -25273,8 +28647,15 @@ Get tax rate account by id
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.accounting.tax_rates.get_by_id(tax_rate_id='tax_rate_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.accounting.tax_rates.get_by_id(
+ tax_rate_id="tax_rate_id",
+)
```
@@ -25339,7 +28720,12 @@ Get all ledger accounts
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.accounting.ledger_accounts.get()
```
@@ -25364,7 +28750,11 @@ client.accounting.ledger_accounts.get()
-
-**limit:** `typing.Optional[int]` — The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+**limit:** `typing.Optional[int]`
+
+The number of items (0 .. 250) to return in a single page of the response. Default is 100. The response may contain fewer items if it is the last or only page.
+
+When using pagination with a non-default `limit`, you must provide the `limit` value alongside `pagination_token` in all subsequent pagination requests. Unlike other query parameters, `limit` is not inferred from `pagination_token`.
@@ -25374,7 +28764,7 @@ client.accounting.ledger_accounts.get()
**pagination_token:** `typing.Optional[str]`
-A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters except `limit` are ignored and inferred from the initial query.
If not specified, the first page of results will be returned.
@@ -25432,8 +28822,15 @@ Get ledger account by id
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.accounting.ledger_accounts.get_by_id(ledger_account_id='ledger_account_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.accounting.ledger_accounts.get_by_id(
+ ledger_account_id="ledger_account_id",
+)
```
@@ -25498,8 +28895,15 @@ Retrieve a list of all approval policy processes.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.approval_policies.processes.get(approval_policy_id='approval_policy_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.approval_policies.processes.get(
+ approval_policy_id="approval_policy_id",
+)
```
@@ -25563,8 +28967,16 @@ Retrieve a specific approval policy process.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.approval_policies.processes.get_by_id(approval_policy_id='approval_policy_id', process_id='process_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.approval_policies.processes.get_by_id(
+ approval_policy_id="approval_policy_id",
+ process_id="process_id",
+)
```
@@ -25636,8 +29048,16 @@ Cancel an ongoing approval process for a specific approval policy.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.approval_policies.processes.cancel_by_id(approval_policy_id='approval_policy_id', process_id='process_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.approval_policies.processes.cancel_by_id(
+ approval_policy_id="approval_policy_id",
+ process_id="process_id",
+)
```
@@ -25709,8 +29129,16 @@ Retrieve a list of approval policy process steps.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.approval_policies.processes.get_steps(approval_policy_id='approval_policy_id', process_id='process_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.approval_policies.processes.get_steps(
+ approval_policy_id="approval_policy_id",
+ process_id="process_id",
+)
```
@@ -25769,8 +29197,15 @@ client.approval_policies.processes.get_steps(approval_policy_id='approval_policy
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.addresses.get(counterpart_id='counterpart_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.addresses.get(
+ counterpart_id="counterpart_id",
+)
```
@@ -25820,8 +29255,19 @@ client.counterparts.addresses.get(counterpart_id='counterpart_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.addresses.create(counterpart_id='counterpart_id', city='Berlin', country="AF", line1='Flughafenstrasse 52', postal_code='10115', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.addresses.create(
+ counterpart_id="counterpart_id",
+ city="Berlin",
+ country="AF",
+ line1="Flughafenstrasse 52",
+ postal_code="10115",
+)
```
@@ -25919,8 +29365,16 @@ client.counterparts.addresses.create(counterpart_id='counterpart_id', city='Berl
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.addresses.get_by_id(address_id='address_id', counterpart_id='counterpart_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.addresses.get_by_id(
+ address_id="address_id",
+ counterpart_id="counterpart_id",
+)
```
@@ -25978,8 +29432,16 @@ client.counterparts.addresses.get_by_id(address_id='address_id', counterpart_id=
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.addresses.delete_by_id(address_id='address_id', counterpart_id='counterpart_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.addresses.delete_by_id(
+ address_id="address_id",
+ counterpart_id="counterpart_id",
+)
```
@@ -26037,8 +29499,16 @@ client.counterparts.addresses.delete_by_id(address_id='address_id', counterpart_
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.addresses.update_by_id(address_id='address_id', counterpart_id='counterpart_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.addresses.update_by_id(
+ address_id="address_id",
+ counterpart_id="counterpart_id",
+)
```
@@ -26145,8 +29615,15 @@ client.counterparts.addresses.update_by_id(address_id='address_id', counterpart_
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.bank_accounts.get(counterpart_id='counterpart_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.bank_accounts.get(
+ counterpart_id="counterpart_id",
+)
```
@@ -26196,8 +29673,17 @@ client.counterparts.bank_accounts.get(counterpart_id='counterpart_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.bank_accounts.create(counterpart_id='counterpart_id', country="AF", currency="AED", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.bank_accounts.create(
+ counterpart_id="counterpart_id",
+ country="AF",
+ currency="AED",
+)
```
@@ -26335,8 +29821,16 @@ client.counterparts.bank_accounts.create(counterpart_id='counterpart_id', countr
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.bank_accounts.get_by_id(bank_account_id='bank_account_id', counterpart_id='counterpart_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.bank_accounts.get_by_id(
+ bank_account_id="bank_account_id",
+ counterpart_id="counterpart_id",
+)
```
@@ -26394,8 +29888,16 @@ client.counterparts.bank_accounts.get_by_id(bank_account_id='bank_account_id', c
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.bank_accounts.delete_by_id(bank_account_id='bank_account_id', counterpart_id='counterpart_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.bank_accounts.delete_by_id(
+ bank_account_id="bank_account_id",
+ counterpart_id="counterpart_id",
+)
```
@@ -26453,8 +29955,16 @@ client.counterparts.bank_accounts.delete_by_id(bank_account_id='bank_account_id'
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.bank_accounts.update_by_id(bank_account_id='bank_account_id', counterpart_id='counterpart_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.bank_accounts.update_by_id(
+ bank_account_id="bank_account_id",
+ counterpart_id="counterpart_id",
+)
```
@@ -26592,8 +30102,16 @@ client.counterparts.bank_accounts.update_by_id(bank_account_id='bank_account_id'
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.bank_accounts.make_default_by_id(bank_account_id='bank_account_id', counterpart_id='counterpart_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.bank_accounts.make_default_by_id(
+ bank_account_id="bank_account_id",
+ counterpart_id="counterpart_id",
+)
```
@@ -26652,8 +30170,15 @@ client.counterparts.bank_accounts.make_default_by_id(bank_account_id='bank_accou
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.contacts.get(counterpart_id='counterpart_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.contacts.get(
+ counterpart_id="counterpart_id",
+)
```
@@ -26702,10 +30227,24 @@ client.counterparts.contacts.get(counterpart_id='counterpart_id', )
-
```python
-from monite import Monite
-from monite import CounterpartAddress
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.contacts.create(counterpart_id='counterpart_id', address=CounterpartAddress(city='Berlin', country="AF", line1='Flughafenstrasse 52', postal_code='10115', ), first_name='Mary', last_name="O'Brien", )
+from monite import CounterpartAddress, Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.contacts.create(
+ counterpart_id="counterpart_id",
+ address=CounterpartAddress(
+ city="Berlin",
+ country="AF",
+ line1="Flughafenstrasse 52",
+ postal_code="10115",
+ ),
+ first_name="Mary",
+ last_name="O'Brien",
+)
```
@@ -26803,8 +30342,16 @@ client.counterparts.contacts.create(counterpart_id='counterpart_id', address=Cou
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.contacts.get_by_id(contact_id='contact_id', counterpart_id='counterpart_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.contacts.get_by_id(
+ contact_id="contact_id",
+ counterpart_id="counterpart_id",
+)
```
@@ -26862,8 +30409,16 @@ client.counterparts.contacts.get_by_id(contact_id='contact_id', counterpart_id='
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.contacts.delete_by_id(contact_id='contact_id', counterpart_id='counterpart_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.contacts.delete_by_id(
+ contact_id="contact_id",
+ counterpart_id="counterpart_id",
+)
```
@@ -26921,8 +30476,16 @@ client.counterparts.contacts.delete_by_id(contact_id='contact_id', counterpart_i
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.contacts.update_by_id(contact_id='contact_id', counterpart_id='counterpart_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.contacts.update_by_id(
+ contact_id="contact_id",
+ counterpart_id="counterpart_id",
+)
```
@@ -27028,8 +30591,16 @@ client.counterparts.contacts.update_by_id(contact_id='contact_id', counterpart_i
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.contacts.make_default_by_id(contact_id='contact_id', counterpart_id='counterpart_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.contacts.make_default_by_id(
+ contact_id="contact_id",
+ counterpart_id="counterpart_id",
+)
```
@@ -27088,8 +30659,15 @@ client.counterparts.contacts.make_default_by_id(contact_id='contact_id', counter
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.vat_ids.get(counterpart_id='counterpart_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.vat_ids.get(
+ counterpart_id="counterpart_id",
+)
```
@@ -27139,8 +30717,16 @@ client.counterparts.vat_ids.get(counterpart_id='counterpart_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.vat_ids.create(counterpart_id='counterpart_id', value='123456789', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.vat_ids.create(
+ counterpart_id="counterpart_id",
+ value="123456789",
+)
```
@@ -27214,8 +30800,16 @@ client.counterparts.vat_ids.create(counterpart_id='counterpart_id', value='12345
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.vat_ids.get_by_id(vat_id='vat_id', counterpart_id='counterpart_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.vat_ids.get_by_id(
+ vat_id="vat_id",
+ counterpart_id="counterpart_id",
+)
```
@@ -27273,8 +30867,16 @@ client.counterparts.vat_ids.get_by_id(vat_id='vat_id', counterpart_id='counterpa
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.vat_ids.delete_by_id(vat_id='vat_id', counterpart_id='counterpart_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.vat_ids.delete_by_id(
+ vat_id="vat_id",
+ counterpart_id="counterpart_id",
+)
```
@@ -27332,8 +30934,16 @@ client.counterparts.vat_ids.delete_by_id(vat_id='vat_id', counterpart_id='counte
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.counterparts.vat_ids.update_by_id(vat_id='vat_id', counterpart_id='counterpart_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.counterparts.vat_ids.update_by_id(
+ vat_id="vat_id",
+ counterpart_id="counterpart_id",
+)
```
@@ -27416,7 +31026,12 @@ client.counterparts.vat_ids.update_by_id(vat_id='vat_id', counterpart_id='counte
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.data_exports.extra_data.get()
```
@@ -27579,8 +31194,17 @@ client.data_exports.extra_data.get()
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.data_exports.extra_data.create(field_name="default_account_code", field_value='field_value', object_id='object_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.data_exports.extra_data.create(
+ field_name="default_account_code",
+ field_value="field_value",
+ object_id="object_id",
+)
```
@@ -27646,8 +31270,15 @@ client.data_exports.extra_data.create(field_name="default_account_code", field_v
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.data_exports.extra_data.get_by_id(extra_data_id='extra_data_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.data_exports.extra_data.get_by_id(
+ extra_data_id="extra_data_id",
+)
```
@@ -27697,8 +31328,15 @@ client.data_exports.extra_data.get_by_id(extra_data_id='extra_data_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.data_exports.extra_data.delete_by_id(extra_data_id='extra_data_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.data_exports.extra_data.delete_by_id(
+ extra_data_id="extra_data_id",
+)
```
@@ -27748,8 +31386,15 @@ client.data_exports.extra_data.delete_by_id(extra_data_id='extra_data_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.data_exports.extra_data.update_by_id(extra_data_id='extra_data_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.data_exports.extra_data.update_by_id(
+ extra_data_id="extra_data_id",
+)
```
@@ -27846,7 +31491,12 @@ Get all bank accounts of this entity.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.entities.bank_accounts.get()
```
@@ -27916,8 +31566,16 @@ For other countries:
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.bank_accounts.create(country="AF", currency="AED", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.bank_accounts.create(
+ country="AF",
+ currency="AED",
+)
```
@@ -28069,8 +31727,15 @@ Retrieve a bank account by its ID.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.bank_accounts.get_by_id(bank_account_id='bank_account_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.bank_accounts.get_by_id(
+ bank_account_id="bank_account_id",
+)
```
@@ -28134,8 +31799,15 @@ Delete the bank account specified by its ID.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.bank_accounts.delete_by_id(bank_account_id='bank_account_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.bank_accounts.delete_by_id(
+ bank_account_id="bank_account_id",
+)
```
@@ -28199,8 +31871,15 @@ Change the specified fields with the provided values.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.bank_accounts.update_by_id(bank_account_id='bank_account_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.bank_accounts.update_by_id(
+ bank_account_id="bank_account_id",
+)
```
@@ -28280,8 +31959,15 @@ Set a bank account as the default for this entity per currency.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.bank_accounts.make_default_by_id(bank_account_id='bank_account_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.bank_accounts.make_default_by_id(
+ bank_account_id="bank_account_id",
+)
```
@@ -28332,8 +32018,15 @@ client.entities.bank_accounts.make_default_by_id(bank_account_id='bank_account_i
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.onboarding_data.get(entity_id='entity_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.onboarding_data.get(
+ entity_id="entity_id",
+)
```
@@ -28383,8 +32076,15 @@ client.entities.onboarding_data.get(entity_id='entity_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.onboarding_data.update(entity_id='entity_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.onboarding_data.update(
+ entity_id="entity_id",
+)
```
@@ -28473,8 +32173,15 @@ Get all enabled payment methods.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.payment_methods.get(entity_id='entity_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.payment_methods.get(
+ entity_id="entity_id",
+)
```
@@ -28538,8 +32245,15 @@ Set which payment methods should be enabled.
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.payment_methods.set(entity_id='entity_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.payment_methods.set(
+ entity_id="entity_id",
+)
```
@@ -28614,8 +32328,15 @@ client.entities.payment_methods.set(entity_id='entity_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.vat_ids.get(entity_id='entity_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.vat_ids.get(
+ entity_id="entity_id",
+)
```
@@ -28665,8 +32386,17 @@ client.entities.vat_ids.get(entity_id='entity_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.vat_ids.create(entity_id='entity_id', country="AF", value='123456789', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.vat_ids.create(
+ entity_id="entity_id",
+ country="AF",
+ value="123456789",
+)
```
@@ -28740,8 +32470,16 @@ client.entities.vat_ids.create(entity_id='entity_id', country="AF", value='12345
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.vat_ids.get_by_id(id='id', entity_id='entity_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.vat_ids.get_by_id(
+ id="id",
+ entity_id="entity_id",
+)
```
@@ -28799,8 +32537,16 @@ client.entities.vat_ids.get_by_id(id='id', entity_id='entity_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.vat_ids.delete_by_id(id='id', entity_id='entity_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.vat_ids.delete_by_id(
+ id="id",
+ entity_id="entity_id",
+)
```
@@ -28858,8 +32604,16 @@ client.entities.vat_ids.delete_by_id(id='id', entity_id='entity_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.vat_ids.update_by_id(id='id', entity_id='entity_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.vat_ids.update_by_id(
+ id="id",
+ entity_id="entity_id",
+)
```
@@ -28942,7 +32696,12 @@ client.entities.vat_ids.update_by_id(id='id', entity_id='entity_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
client.entities.persons.get()
```
@@ -28984,10 +32743,19 @@ client.entities.persons.get()
-
```python
-from monite import Monite
-from monite import PersonRelationshipRequest
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.persons.create(email='email', first_name='first_name', last_name='last_name', relationship=PersonRelationshipRequest(), )
+from monite import Monite, PersonRelationshipRequest
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.persons.create(
+ email="email",
+ first_name="first_name",
+ last_name="last_name",
+ relationship=PersonRelationshipRequest(),
+)
```
@@ -29109,8 +32877,15 @@ client.entities.persons.create(email='email', first_name='first_name', last_name
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.persons.get_by_id(person_id='person_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.persons.get_by_id(
+ person_id="person_id",
+)
```
@@ -29160,8 +32935,15 @@ client.entities.persons.get_by_id(person_id='person_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.persons.delete_by_id(person_id='person_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.persons.delete_by_id(
+ person_id="person_id",
+)
```
@@ -29211,8 +32993,15 @@ client.entities.persons.delete_by_id(person_id='person_id', )
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.persons.update_by_id(person_id='person_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.persons.update_by_id(
+ person_id="person_id",
+)
```
@@ -29356,8 +33145,15 @@ Provide files for person onboarding verification
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.entities.persons.upload_onboarding_documents(person_id='person_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.entities.persons.upload_onboarding_documents(
+ person_id="person_id",
+)
```
@@ -29461,8 +33257,15 @@ See also:
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payables.line_items.get(payable_id='payable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payables.line_items.get(
+ payable_id="payable_id",
+)
```
@@ -29582,8 +33385,15 @@ See also:
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payables.line_items.create(payable_id='payable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payables.line_items.create(
+ payable_id="payable_id",
+)
```
@@ -29718,10 +33528,17 @@ See also:
-
```python
-from monite import Monite
-from monite import LineItemInternalRequest
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payables.line_items.replace(payable_id='payable_id', data=[LineItemInternalRequest()], )
+from monite import LineItemInternalRequest, Monite
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payables.line_items.replace(
+ payable_id="payable_id",
+ data=[LineItemInternalRequest()],
+)
```
@@ -29801,8 +33618,16 @@ See also:
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payables.line_items.get_by_id(line_item_id='line_item_id', payable_id='payable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payables.line_items.get_by_id(
+ line_item_id="line_item_id",
+ payable_id="payable_id",
+)
```
@@ -29882,8 +33707,16 @@ See also:
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payables.line_items.delete_by_id(line_item_id='line_item_id', payable_id='payable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payables.line_items.delete_by_id(
+ line_item_id="line_item_id",
+ payable_id="payable_id",
+)
```
@@ -29963,8 +33796,16 @@ See also:
```python
from monite import Monite
-client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
-client.payables.line_items.update_by_id(line_item_id='line_item_id', payable_id='payable_id', )
+
+client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+)
+client.payables.line_items.update_by_id(
+ line_item_id="line_item_id",
+ payable_id="payable_id",
+)
```
diff --git a/requirements.txt b/requirements.txt
index f502f1b..e80f640 100644
--- a/requirements.txt
+++ b/requirements.txt
@@ -1,4 +1,4 @@
httpx>=0.21.2
pydantic>= 1.9.2
-pydantic-core==^2.18.2
+pydantic-core>=2.18.2
typing_extensions>= 4.0.0
diff --git a/src/monite/__init__.py b/src/monite/__init__.py
index fbd0cbc..28e4d8b 100644
--- a/src/monite/__init__.py
+++ b/src/monite/__init__.py
@@ -118,7 +118,6 @@
CounterpartRawVatId,
CounterpartRawVatIdUpdateRequest,
CounterpartResponse,
- CounterpartTagCategory,
CounterpartTagSchema,
CounterpartType,
CounterpartUpdatePayload,
@@ -155,6 +154,8 @@
CustomTemplateDataSchema,
CustomTemplatesCursorFields,
CustomTemplatesPaginationResponse,
+ CustomVatRateResponse,
+ CustomVatRateResponseList,
DataExportCursorFields,
DateDimensionBreakdownEnum,
DayOfMonth,
@@ -174,6 +175,7 @@
DeliveryNoteResourceList,
DeliveryNoteStatusEnum,
Discount,
+ DiscountResponse,
DiscountType,
DnsRecord,
DnsRecordPurpose,
@@ -239,6 +241,7 @@
ExtraDataResource,
ExtraDataResourceList,
FieldSchema,
+ FileAttachedEventData,
FileResponse,
FileSchema,
FileSchema2,
@@ -254,12 +257,14 @@
FinancingPushInvoicesResponse,
FinancingTokenResponse,
GetAllPaymentReminders,
- GetAllRecurrences,
GetOnboardingRequirementsResponse,
GrantType,
HttpValidationError,
IndividualResponseSchema,
IndividualSchema,
+ InlinePaymentTermsRequestPayload,
+ InlineTermDiscount,
+ InlineTermFinal,
Invoice,
InvoiceFile,
InvoiceRenderingSettings,
@@ -355,13 +360,21 @@
PayableAggregatedDataResponse,
PayableAggregatedItem,
PayableAnalyticsResponse,
+ PayableCreatedEventData,
PayableCreditNoteData,
+ PayableCreditNoteLinkedEventData,
PayableCreditNoteStateEnum,
+ PayableCreditNoteUnlinkedEventData,
PayableCursorFields,
PayableDimensionEnum,
PayableEntityAddressSchema,
PayableEntityIndividualResponse,
PayableEntityOrganizationResponse,
+ PayableHistoryCursorFields,
+ PayableHistoryEventTypeEnum,
+ PayableHistoryPaginationResponse,
+ PayableHistoryResponse,
+ PayableHistoryResponseEventData,
PayableIndividualSchema,
PayableMetricEnum,
PayableOrganizationSchema,
@@ -376,9 +389,11 @@
PayableSchemaOutput,
PayableSettings,
PayableStateEnum,
+ PayableStatusChangedEventData,
PayableTemplatesVariable,
PayableTemplatesVariablesObject,
PayableTemplatesVariablesObjectList,
+ PayableUpdatedEventData,
PayableValidationResponse,
PayableValidationsResource,
PayablesFieldsAllowedForValidate,
@@ -405,6 +420,7 @@
PaymentPriorityEnum,
PaymentReceivedEventData,
PaymentRecordCursorFields,
+ PaymentRecordHistoryResponse,
PaymentRecordObjectRequest,
PaymentRecordObjectResponse,
PaymentRecordResponse,
@@ -413,9 +429,6 @@
PaymentRecordStatusUpdateRequest,
PaymentReminderResponse,
PaymentRequirements,
- PaymentTerm,
- PaymentTermDiscount,
- PaymentTermDiscountWithDate,
PaymentTerms,
PaymentTermsListResponse,
PaymentTermsResponse,
@@ -472,11 +485,11 @@
QuoteResponsePayloadEntity_Organization,
QuoteStateEnum,
ReceivableCounterpartContact,
- ReceivableCounterpartType,
ReceivableCounterpartVatIdResponse,
ReceivableCreateBasedOnPayload,
ReceivableCreatedEventData,
ReceivableCursorFields,
+ ReceivableCursorFields2,
ReceivableDimensionEnum,
ReceivableEditFlow,
ReceivableEntityAddressSchema,
@@ -511,7 +524,6 @@
ReceivableResponse_Quote,
ReceivableSendResponse,
ReceivableSettings,
- ReceivableTagCategory,
ReceivableTemplatesVariable,
ReceivableTemplatesVariablesObject,
ReceivableTemplatesVariablesObjectList,
@@ -532,8 +544,10 @@
RecipientAccountResponse,
RecipientType,
Recipients,
- Recurrence,
+ RecurrenceFrequency,
RecurrenceIteration,
+ RecurrenceResponse,
+ RecurrenceResponseList,
RecurrenceStatus,
RelatedDocuments,
Reminder,
@@ -638,7 +652,8 @@
TemplateListResponse,
TemplateReceivableResponse,
TemplateTypeEnum,
- TermFinalWithDate,
+ TermDiscountDays,
+ TermFinalDays,
TermsOfServiceAcceptanceInput,
TermsOfServiceAcceptanceOutput,
TextTemplateDocumentTypeEnum,
@@ -646,12 +661,14 @@
TextTemplateResponseList,
TextTemplateType,
TotalVatAmountItem,
+ TotalVatAmountItemComponent,
Unit,
UnitListResponse,
UnitRequest,
UnitResponse,
UpdateCreditNote,
UpdateCreditNotePayload,
+ UpdateEinvoicingAddress,
UpdateEntityAddressSchema,
UpdateEntityRequest,
UpdateInvoice,
@@ -673,6 +690,7 @@
VariablesType,
VatIdTypeEnum,
VatModeEnum,
+ VatRateComponent,
VatRateCreator,
VatRateListResponse,
VatRateResponse,
@@ -722,6 +740,7 @@
counterpart_e_invoicing_credentials,
counterparts,
credit_notes,
+ custom_vat_rates,
data_exports,
delivery_notes,
e_invoicing_connections,
@@ -769,7 +788,7 @@
from .delivery_notes import Payload
from .environment import MoniteEnvironment
from .payment_records import PaymentRecordRequestStatus
-from .receivables import ReceivablesGetRequestStatus, ReceivablesGetRequestStatusInItem
+from .receivables import ReceivablesGetRequestStatus, ReceivablesGetRequestStatusInItem, ReceivablesSearchRequestStatus
from .version import __version__
__all__ = [
@@ -898,7 +917,6 @@
"CounterpartRawVatId",
"CounterpartRawVatIdUpdateRequest",
"CounterpartResponse",
- "CounterpartTagCategory",
"CounterpartTagSchema",
"CounterpartType",
"CounterpartUpdatePayload",
@@ -935,6 +953,8 @@
"CustomTemplateDataSchema",
"CustomTemplatesCursorFields",
"CustomTemplatesPaginationResponse",
+ "CustomVatRateResponse",
+ "CustomVatRateResponseList",
"DataExportCursorFields",
"DateDimensionBreakdownEnum",
"DayOfMonth",
@@ -954,6 +974,7 @@
"DeliveryNoteResourceList",
"DeliveryNoteStatusEnum",
"Discount",
+ "DiscountResponse",
"DiscountType",
"DnsRecord",
"DnsRecordPurpose",
@@ -1020,6 +1041,7 @@
"ExtraDataResourceList",
"FailedDependencyError",
"FieldSchema",
+ "FileAttachedEventData",
"FileResponse",
"FileSchema",
"FileSchema2",
@@ -1036,7 +1058,6 @@
"FinancingTokenResponse",
"ForbiddenError",
"GetAllPaymentReminders",
- "GetAllRecurrences",
"GetAnalyticsReceivablesRequestStatus",
"GetAnalyticsReceivablesRequestStatusInItem",
"GetOnboardingRequirementsResponse",
@@ -1044,6 +1065,9 @@
"HttpValidationError",
"IndividualResponseSchema",
"IndividualSchema",
+ "InlinePaymentTermsRequestPayload",
+ "InlineTermDiscount",
+ "InlineTermFinal",
"InternalServerError",
"Invoice",
"InvoiceFile",
@@ -1145,13 +1169,21 @@
"PayableAggregatedDataResponse",
"PayableAggregatedItem",
"PayableAnalyticsResponse",
+ "PayableCreatedEventData",
"PayableCreditNoteData",
+ "PayableCreditNoteLinkedEventData",
"PayableCreditNoteStateEnum",
+ "PayableCreditNoteUnlinkedEventData",
"PayableCursorFields",
"PayableDimensionEnum",
"PayableEntityAddressSchema",
"PayableEntityIndividualResponse",
"PayableEntityOrganizationResponse",
+ "PayableHistoryCursorFields",
+ "PayableHistoryEventTypeEnum",
+ "PayableHistoryPaginationResponse",
+ "PayableHistoryResponse",
+ "PayableHistoryResponseEventData",
"PayableIndividualSchema",
"PayableMetricEnum",
"PayableOrganizationSchema",
@@ -1166,9 +1198,11 @@
"PayableSchemaOutput",
"PayableSettings",
"PayableStateEnum",
+ "PayableStatusChangedEventData",
"PayableTemplatesVariable",
"PayableTemplatesVariablesObject",
"PayableTemplatesVariablesObjectList",
+ "PayableUpdatedEventData",
"PayableValidationResponse",
"PayableValidationsResource",
"PayablesFieldsAllowedForValidate",
@@ -1196,6 +1230,7 @@
"PaymentPriorityEnum",
"PaymentReceivedEventData",
"PaymentRecordCursorFields",
+ "PaymentRecordHistoryResponse",
"PaymentRecordObjectRequest",
"PaymentRecordObjectResponse",
"PaymentRecordRequestStatus",
@@ -1205,9 +1240,6 @@
"PaymentRecordStatusUpdateRequest",
"PaymentReminderResponse",
"PaymentRequirements",
- "PaymentTerm",
- "PaymentTermDiscount",
- "PaymentTermDiscountWithDate",
"PaymentTerms",
"PaymentTermsListResponse",
"PaymentTermsResponse",
@@ -1264,11 +1296,11 @@
"QuoteResponsePayloadEntity_Organization",
"QuoteStateEnum",
"ReceivableCounterpartContact",
- "ReceivableCounterpartType",
"ReceivableCounterpartVatIdResponse",
"ReceivableCreateBasedOnPayload",
"ReceivableCreatedEventData",
"ReceivableCursorFields",
+ "ReceivableCursorFields2",
"ReceivableDimensionEnum",
"ReceivableEditFlow",
"ReceivableEntityAddressSchema",
@@ -1303,7 +1335,6 @@
"ReceivableResponse_Quote",
"ReceivableSendResponse",
"ReceivableSettings",
- "ReceivableTagCategory",
"ReceivableTemplatesVariable",
"ReceivableTemplatesVariablesObject",
"ReceivableTemplatesVariablesObjectList",
@@ -1319,6 +1350,7 @@
"ReceivablesRemindersWarningMessage",
"ReceivablesRepresentationOfCounterpartAddress",
"ReceivablesRepresentationOfEntityBankAccount",
+ "ReceivablesSearchRequestStatus",
"ReceivablesSendResponse",
"ReceivablesStatusEnum",
"ReceivablesVerifyResponse",
@@ -1326,8 +1358,10 @@
"RecipientAccountResponse",
"RecipientType",
"Recipients",
- "Recurrence",
+ "RecurrenceFrequency",
"RecurrenceIteration",
+ "RecurrenceResponse",
+ "RecurrenceResponseList",
"RecurrenceStatus",
"RelatedDocuments",
"Reminder",
@@ -1432,7 +1466,8 @@
"TemplateListResponse",
"TemplateReceivableResponse",
"TemplateTypeEnum",
- "TermFinalWithDate",
+ "TermDiscountDays",
+ "TermFinalDays",
"TermsOfServiceAcceptanceInput",
"TermsOfServiceAcceptanceOutput",
"TextTemplateDocumentTypeEnum",
@@ -1440,6 +1475,7 @@
"TextTemplateResponseList",
"TextTemplateType",
"TotalVatAmountItem",
+ "TotalVatAmountItemComponent",
"UnauthorizedError",
"Unit",
"UnitListResponse",
@@ -1449,6 +1485,7 @@
"UnsupportedMediaTypeError",
"UpdateCreditNote",
"UpdateCreditNotePayload",
+ "UpdateEinvoicingAddress",
"UpdateEntityAddressSchema",
"UpdateEntityRequest",
"UpdateInvoice",
@@ -1470,6 +1507,7 @@
"VariablesType",
"VatIdTypeEnum",
"VatModeEnum",
+ "VatRateComponent",
"VatRateCreator",
"VatRateListResponse",
"VatRateResponse",
@@ -1504,6 +1542,7 @@
"counterpart_e_invoicing_credentials",
"counterparts",
"credit_notes",
+ "custom_vat_rates",
"data_exports",
"delivery_notes",
"e_invoicing_connections",
diff --git a/src/monite/access_tokens/client.py b/src/monite/access_tokens/client.py
index 5b11aba..fb796a6 100644
--- a/src/monite/access_tokens/client.py
+++ b/src/monite/access_tokens/client.py
@@ -53,8 +53,17 @@ def revoke(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.access_tokens.revoke(client_id='client_id', client_secret='client_secret', token='token', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.access_tokens.revoke(
+ client_id="client_id",
+ client_secret="client_secret",
+ token="token",
+ )
"""
_response = self._raw_client.revoke(
client_id=client_id, client_secret=client_secret, token=token, request_options=request_options
@@ -94,8 +103,17 @@ def create(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.access_tokens.create(client_id='client_id', client_secret='client_secret', grant_type="client_credentials", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.access_tokens.create(
+ client_id="client_id",
+ client_secret="client_secret",
+ grant_type="client_credentials",
+ )
"""
_response = self._raw_client.create(
client_id=client_id,
@@ -146,11 +164,25 @@ async def revoke(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.access_tokens.revoke(client_id='client_id', client_secret='client_secret', token='token', )
+ await client.access_tokens.revoke(
+ client_id="client_id",
+ client_secret="client_secret",
+ token="token",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.revoke(
@@ -190,11 +222,25 @@ async def create(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.access_tokens.create(client_id='client_id', client_secret='client_secret', grant_type="client_credentials", )
+ await client.access_tokens.create(
+ client_id="client_id",
+ client_secret="client_secret",
+ grant_type="client_credentials",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
diff --git a/src/monite/accounting/connections/client.py b/src/monite/accounting/connections/client.py
index fca8c52..e7e39a1 100644
--- a/src/monite/accounting/connections/client.py
+++ b/src/monite/accounting/connections/client.py
@@ -42,7 +42,12 @@ def get(self, *, request_options: typing.Optional[RequestOptions] = None) -> Acc
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.accounting.connections.get()
"""
_response = self._raw_client.get(request_options=request_options)
@@ -65,7 +70,12 @@ def create(self, *, request_options: typing.Optional[RequestOptions] = None) ->
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.accounting.connections.create()
"""
_response = self._raw_client.create(request_options=request_options)
@@ -92,8 +102,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.accounting.connections.get_by_id(connection_id='connection_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.accounting.connections.get_by_id(
+ connection_id="connection_id",
+ )
"""
_response = self._raw_client.get_by_id(connection_id, request_options=request_options)
return _response.data
@@ -119,8 +136,15 @@ def disconnect_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.accounting.connections.disconnect_by_id(connection_id='connection_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.accounting.connections.disconnect_by_id(
+ connection_id="connection_id",
+ )
"""
_response = self._raw_client.disconnect_by_id(connection_id, request_options=request_options)
return _response.data
@@ -144,8 +168,15 @@ def sync_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.accounting.connections.sync_by_id(connection_id='connection_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.accounting.connections.sync_by_id(
+ connection_id="connection_id",
+ )
"""
_response = self._raw_client.sync_by_id(connection_id, request_options=request_options)
return _response.data
@@ -182,11 +213,21 @@ async def get(self, *, request_options: typing.Optional[RequestOptions] = None)
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.accounting.connections.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(request_options=request_options)
@@ -208,11 +249,21 @@ async def create(self, *, request_options: typing.Optional[RequestOptions] = Non
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.accounting.connections.create()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(request_options=request_options)
@@ -238,11 +289,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.accounting.connections.get_by_id(connection_id='connection_id', )
+ await client.accounting.connections.get_by_id(
+ connection_id="connection_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(connection_id, request_options=request_options)
@@ -268,11 +331,23 @@ async def disconnect_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.accounting.connections.disconnect_by_id(connection_id='connection_id', )
+ await client.accounting.connections.disconnect_by_id(
+ connection_id="connection_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.disconnect_by_id(connection_id, request_options=request_options)
@@ -296,11 +371,23 @@ async def sync_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.accounting.connections.sync_by_id(connection_id='connection_id', )
+ await client.accounting.connections.sync_by_id(
+ connection_id="connection_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.sync_by_id(connection_id, request_options=request_options)
diff --git a/src/monite/accounting/ledger_accounts/client.py b/src/monite/accounting/ledger_accounts/client.py
index 1b74aa4..12bd8be 100644
--- a/src/monite/accounting/ledger_accounts/client.py
+++ b/src/monite/accounting/ledger_accounts/client.py
@@ -44,10 +44,12 @@ def get(
Sort order (ascending by default). Typically used together with the `sort` parameter.
limit : typing.Optional[int]
- The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+ The number of items (0 .. 250) to return in a single page of the response. Default is 100. The response may contain fewer items if it is the last or only page.
+
+ When using pagination with a non-default `limit`, you must provide the `limit` value alongside `pagination_token` in all subsequent pagination requests. Unlike other query parameters, `limit` is not inferred from `pagination_token`.
pagination_token : typing.Optional[str]
- A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+ A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters except `limit` are ignored and inferred from the initial query.
If not specified, the first page of results will be returned.
@@ -65,7 +67,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.accounting.ledger_accounts.get()
"""
_response = self._raw_client.get(
@@ -94,8 +101,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.accounting.ledger_accounts.get_by_id(ledger_account_id='ledger_account_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.accounting.ledger_accounts.get_by_id(
+ ledger_account_id="ledger_account_id",
+ )
"""
_response = self._raw_client.get_by_id(ledger_account_id, request_options=request_options)
return _response.data
@@ -134,10 +148,12 @@ async def get(
Sort order (ascending by default). Typically used together with the `sort` parameter.
limit : typing.Optional[int]
- The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+ The number of items (0 .. 250) to return in a single page of the response. Default is 100. The response may contain fewer items if it is the last or only page.
+
+ When using pagination with a non-default `limit`, you must provide the `limit` value alongside `pagination_token` in all subsequent pagination requests. Unlike other query parameters, `limit` is not inferred from `pagination_token`.
pagination_token : typing.Optional[str]
- A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+ A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters except `limit` are ignored and inferred from the initial query.
If not specified, the first page of results will be returned.
@@ -154,11 +170,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.accounting.ledger_accounts.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
@@ -186,11 +212,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.accounting.ledger_accounts.get_by_id(ledger_account_id='ledger_account_id', )
+ await client.accounting.ledger_accounts.get_by_id(
+ ledger_account_id="ledger_account_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(ledger_account_id, request_options=request_options)
diff --git a/src/monite/accounting/ledger_accounts/raw_client.py b/src/monite/accounting/ledger_accounts/raw_client.py
index 68bf733..fe446f3 100644
--- a/src/monite/accounting/ledger_accounts/raw_client.py
+++ b/src/monite/accounting/ledger_accounts/raw_client.py
@@ -39,10 +39,12 @@ def get(
Sort order (ascending by default). Typically used together with the `sort` parameter.
limit : typing.Optional[int]
- The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+ The number of items (0 .. 250) to return in a single page of the response. Default is 100. The response may contain fewer items if it is the last or only page.
+
+ When using pagination with a non-default `limit`, you must provide the `limit` value alongside `pagination_token` in all subsequent pagination requests. Unlike other query parameters, `limit` is not inferred from `pagination_token`.
pagination_token : typing.Optional[str]
- A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+ A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters except `limit` are ignored and inferred from the initial query.
If not specified, the first page of results will be returned.
@@ -188,10 +190,12 @@ async def get(
Sort order (ascending by default). Typically used together with the `sort` parameter.
limit : typing.Optional[int]
- The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+ The number of items (0 .. 250) to return in a single page of the response. Default is 100. The response may contain fewer items if it is the last or only page.
+
+ When using pagination with a non-default `limit`, you must provide the `limit` value alongside `pagination_token` in all subsequent pagination requests. Unlike other query parameters, `limit` is not inferred from `pagination_token`.
pagination_token : typing.Optional[str]
- A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+ A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters except `limit` are ignored and inferred from the initial query.
If not specified, the first page of results will be returned.
diff --git a/src/monite/accounting/payables/client.py b/src/monite/accounting/payables/client.py
index 62467db..f491595 100644
--- a/src/monite/accounting/payables/client.py
+++ b/src/monite/accounting/payables/client.py
@@ -57,7 +57,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.accounting.payables.get()
"""
_response = self._raw_client.get(limit=limit, offset=offset, request_options=request_options)
@@ -85,8 +90,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.accounting.payables.get_by_id(payable_id='payable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.accounting.payables.get_by_id(
+ payable_id="payable_id",
+ )
"""
_response = self._raw_client.get_by_id(payable_id, request_options=request_options)
return _response.data
@@ -139,11 +151,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.accounting.payables.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(limit=limit, offset=offset, request_options=request_options)
@@ -170,11 +192,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.accounting.payables.get_by_id(payable_id='payable_id', )
+ await client.accounting.payables.get_by_id(
+ payable_id="payable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(payable_id, request_options=request_options)
diff --git a/src/monite/accounting/receivables/client.py b/src/monite/accounting/receivables/client.py
index 8e3e355..4465173 100644
--- a/src/monite/accounting/receivables/client.py
+++ b/src/monite/accounting/receivables/client.py
@@ -57,7 +57,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.accounting.receivables.get()
"""
_response = self._raw_client.get(limit=limit, offset=offset, request_options=request_options)
@@ -85,8 +90,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.accounting.receivables.get_by_id(invoice_id='invoice_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.accounting.receivables.get_by_id(
+ invoice_id="invoice_id",
+ )
"""
_response = self._raw_client.get_by_id(invoice_id, request_options=request_options)
return _response.data
@@ -139,11 +151,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.accounting.receivables.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(limit=limit, offset=offset, request_options=request_options)
@@ -170,11 +192,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.accounting.receivables.get_by_id(invoice_id='invoice_id', )
+ await client.accounting.receivables.get_by_id(
+ invoice_id="invoice_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(invoice_id, request_options=request_options)
diff --git a/src/monite/accounting/synced_records/client.py b/src/monite/accounting/synced_records/client.py
index e19a28f..b149466 100644
--- a/src/monite/accounting/synced_records/client.py
+++ b/src/monite/accounting/synced_records/client.py
@@ -59,10 +59,12 @@ def get(
Sort order (ascending by default). Typically used together with the `sort` parameter.
limit : typing.Optional[int]
- The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+ The number of items (0 .. 250) to return in a single page of the response. Default is 100. The response may contain fewer items if it is the last or only page.
+
+ When using pagination with a non-default `limit`, you must provide the `limit` value alongside `pagination_token` in all subsequent pagination requests. Unlike other query parameters, `limit` is not inferred from `pagination_token`.
pagination_token : typing.Optional[str]
- A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+ A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters except `limit` are ignored and inferred from the initial query.
If not specified, the first page of results will be returned.
@@ -100,8 +102,15 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.accounting.synced_records.get(object_type="product", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.accounting.synced_records.get(
+ object_type="product",
+ )
"""
_response = self._raw_client.get(
object_type=object_type,
@@ -144,8 +153,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.accounting.synced_records.get_by_id(synced_record_id='synced_record_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.accounting.synced_records.get_by_id(
+ synced_record_id="synced_record_id",
+ )
"""
_response = self._raw_client.get_by_id(synced_record_id, request_options=request_options)
return _response.data
@@ -171,8 +187,15 @@ def push_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.accounting.synced_records.push_by_id(synced_record_id='synced_record_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.accounting.synced_records.push_by_id(
+ synced_record_id="synced_record_id",
+ )
"""
_response = self._raw_client.push_by_id(synced_record_id, request_options=request_options)
return _response.data
@@ -224,10 +247,12 @@ async def get(
Sort order (ascending by default). Typically used together with the `sort` parameter.
limit : typing.Optional[int]
- The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+ The number of items (0 .. 250) to return in a single page of the response. Default is 100. The response may contain fewer items if it is the last or only page.
+
+ When using pagination with a non-default `limit`, you must provide the `limit` value alongside `pagination_token` in all subsequent pagination requests. Unlike other query parameters, `limit` is not inferred from `pagination_token`.
pagination_token : typing.Optional[str]
- A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+ A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters except `limit` are ignored and inferred from the initial query.
If not specified, the first page of results will be returned.
@@ -264,11 +289,23 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.accounting.synced_records.get(object_type="product", )
+ await client.accounting.synced_records.get(
+ object_type="product",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
@@ -311,11 +348,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.accounting.synced_records.get_by_id(synced_record_id='synced_record_id', )
+ await client.accounting.synced_records.get_by_id(
+ synced_record_id="synced_record_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(synced_record_id, request_options=request_options)
@@ -341,11 +390,23 @@ async def push_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.accounting.synced_records.push_by_id(synced_record_id='synced_record_id', )
+ await client.accounting.synced_records.push_by_id(
+ synced_record_id="synced_record_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.push_by_id(synced_record_id, request_options=request_options)
diff --git a/src/monite/accounting/synced_records/raw_client.py b/src/monite/accounting/synced_records/raw_client.py
index d3392f9..6ace964 100644
--- a/src/monite/accounting/synced_records/raw_client.py
+++ b/src/monite/accounting/synced_records/raw_client.py
@@ -55,10 +55,12 @@ def get(
Sort order (ascending by default). Typically used together with the `sort` parameter.
limit : typing.Optional[int]
- The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+ The number of items (0 .. 250) to return in a single page of the response. Default is 100. The response may contain fewer items if it is the last or only page.
+
+ When using pagination with a non-default `limit`, you must provide the `limit` value alongside `pagination_token` in all subsequent pagination requests. Unlike other query parameters, `limit` is not inferred from `pagination_token`.
pagination_token : typing.Optional[str]
- A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+ A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters except `limit` are ignored and inferred from the initial query.
If not specified, the first page of results will be returned.
@@ -308,10 +310,12 @@ async def get(
Sort order (ascending by default). Typically used together with the `sort` parameter.
limit : typing.Optional[int]
- The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+ The number of items (0 .. 250) to return in a single page of the response. Default is 100. The response may contain fewer items if it is the last or only page.
+
+ When using pagination with a non-default `limit`, you must provide the `limit` value alongside `pagination_token` in all subsequent pagination requests. Unlike other query parameters, `limit` is not inferred from `pagination_token`.
pagination_token : typing.Optional[str]
- A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+ A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters except `limit` are ignored and inferred from the initial query.
If not specified, the first page of results will be returned.
diff --git a/src/monite/accounting/tax_rates/client.py b/src/monite/accounting/tax_rates/client.py
index 2a58be3..fd5daaf 100644
--- a/src/monite/accounting/tax_rates/client.py
+++ b/src/monite/accounting/tax_rates/client.py
@@ -44,10 +44,12 @@ def get(
Sort order (ascending by default). Typically used together with the `sort` parameter.
limit : typing.Optional[int]
- The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+ The number of items (0 .. 250) to return in a single page of the response. Default is 100. The response may contain fewer items if it is the last or only page.
+
+ When using pagination with a non-default `limit`, you must provide the `limit` value alongside `pagination_token` in all subsequent pagination requests. Unlike other query parameters, `limit` is not inferred from `pagination_token`.
pagination_token : typing.Optional[str]
- A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+ A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters except `limit` are ignored and inferred from the initial query.
If not specified, the first page of results will be returned.
@@ -65,7 +67,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.accounting.tax_rates.get()
"""
_response = self._raw_client.get(
@@ -94,8 +101,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.accounting.tax_rates.get_by_id(tax_rate_id='tax_rate_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.accounting.tax_rates.get_by_id(
+ tax_rate_id="tax_rate_id",
+ )
"""
_response = self._raw_client.get_by_id(tax_rate_id, request_options=request_options)
return _response.data
@@ -134,10 +148,12 @@ async def get(
Sort order (ascending by default). Typically used together with the `sort` parameter.
limit : typing.Optional[int]
- The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+ The number of items (0 .. 250) to return in a single page of the response. Default is 100. The response may contain fewer items if it is the last or only page.
+
+ When using pagination with a non-default `limit`, you must provide the `limit` value alongside `pagination_token` in all subsequent pagination requests. Unlike other query parameters, `limit` is not inferred from `pagination_token`.
pagination_token : typing.Optional[str]
- A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+ A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters except `limit` are ignored and inferred from the initial query.
If not specified, the first page of results will be returned.
@@ -154,11 +170,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.accounting.tax_rates.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
@@ -186,11 +212,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.accounting.tax_rates.get_by_id(tax_rate_id='tax_rate_id', )
+ await client.accounting.tax_rates.get_by_id(
+ tax_rate_id="tax_rate_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(tax_rate_id, request_options=request_options)
diff --git a/src/monite/accounting/tax_rates/raw_client.py b/src/monite/accounting/tax_rates/raw_client.py
index d2ff579..15f38fc 100644
--- a/src/monite/accounting/tax_rates/raw_client.py
+++ b/src/monite/accounting/tax_rates/raw_client.py
@@ -39,10 +39,12 @@ def get(
Sort order (ascending by default). Typically used together with the `sort` parameter.
limit : typing.Optional[int]
- The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+ The number of items (0 .. 250) to return in a single page of the response. Default is 100. The response may contain fewer items if it is the last or only page.
+
+ When using pagination with a non-default `limit`, you must provide the `limit` value alongside `pagination_token` in all subsequent pagination requests. Unlike other query parameters, `limit` is not inferred from `pagination_token`.
pagination_token : typing.Optional[str]
- A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+ A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters except `limit` are ignored and inferred from the initial query.
If not specified, the first page of results will be returned.
@@ -188,10 +190,12 @@ async def get(
Sort order (ascending by default). Typically used together with the `sort` parameter.
limit : typing.Optional[int]
- The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+ The number of items (0 .. 250) to return in a single page of the response. Default is 100. The response may contain fewer items if it is the last or only page.
+
+ When using pagination with a non-default `limit`, you must provide the `limit` value alongside `pagination_token` in all subsequent pagination requests. Unlike other query parameters, `limit` is not inferred from `pagination_token`.
pagination_token : typing.Optional[str]
- A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+ A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters except `limit` are ignored and inferred from the initial query.
If not specified, the first page of results will be returned.
diff --git a/src/monite/analytics/client.py b/src/monite/analytics/client.py
index f922e2a..29b3d37 100644
--- a/src/monite/analytics/client.py
+++ b/src/monite/analytics/client.py
@@ -182,8 +182,16 @@ def get_analytics_credit_notes(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.analytics.get_analytics_credit_notes(metric="id", aggregation_function="count", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.analytics.get_analytics_credit_notes(
+ metric="id",
+ aggregation_function="count",
+ )
"""
_response = self._raw_client.get_analytics_credit_notes(
metric=metric,
@@ -280,6 +288,7 @@ def get_analytics_payables(
project_id_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
tag_ids: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
tag_ids_not_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
+ has_tags: typing.Optional[bool] = None,
origin: typing.Optional[PayableOriginEnum] = None,
has_file: typing.Optional[bool] = None,
request_options: typing.Optional[RequestOptions] = None,
@@ -451,6 +460,9 @@ def get_analytics_payables(
tag_ids_not_in : typing.Optional[typing.Union[str, typing.Sequence[str]]]
Return only payables whose `tags` do not include any of the tags with the specified IDs. Valid but nonexistent tag IDs do not raise errors but produce the results.
+ has_tags : typing.Optional[bool]
+ Filter objects based on whether they have tags. If true, only objects with tags are returned. If false, only objects without tags are returned.
+
origin : typing.Optional[PayableOriginEnum]
Return only payables from a given origin ['einvoice', 'upload', 'email']
@@ -468,8 +480,16 @@ def get_analytics_payables(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.analytics.get_analytics_payables(metric="id", aggregation_function="count", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.analytics.get_analytics_payables(
+ metric="id",
+ aggregation_function="count",
+ )
"""
_response = self._raw_client.get_analytics_payables(
metric=metric,
@@ -522,6 +542,7 @@ def get_analytics_payables(
project_id_in=project_id_in,
tag_ids=tag_ids,
tag_ids_not_in=tag_ids_not_in,
+ has_tags=has_tags,
origin=origin,
has_file=has_file,
request_options=request_options,
@@ -572,6 +593,11 @@ def get_analytics_receivables(
total_amount_lt: typing.Optional[int] = None,
total_amount_gte: typing.Optional[int] = None,
total_amount_lte: typing.Optional[int] = None,
+ discounted_subtotal: typing.Optional[int] = None,
+ discounted_subtotal_gt: typing.Optional[int] = None,
+ discounted_subtotal_lt: typing.Optional[int] = None,
+ discounted_subtotal_gte: typing.Optional[int] = None,
+ discounted_subtotal_lte: typing.Optional[int] = None,
status: typing.Optional[GetAnalyticsReceivablesRequestStatus] = None,
entity_user_id: typing.Optional[str] = None,
based_on: typing.Optional[str] = None,
@@ -736,6 +762,16 @@ def get_analytics_receivables(
total_amount_lte : typing.Optional[int]
+ discounted_subtotal : typing.Optional[int]
+
+ discounted_subtotal_gt : typing.Optional[int]
+
+ discounted_subtotal_lt : typing.Optional[int]
+
+ discounted_subtotal_gte : typing.Optional[int]
+
+ discounted_subtotal_lte : typing.Optional[int]
+
status : typing.Optional[GetAnalyticsReceivablesRequestStatus]
entity_user_id : typing.Optional[str]
@@ -763,8 +799,16 @@ def get_analytics_receivables(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.analytics.get_analytics_receivables(metric="id", aggregation_function="count", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.analytics.get_analytics_receivables(
+ metric="id",
+ aggregation_function="count",
+ )
"""
_response = self._raw_client.get_analytics_receivables(
metric=metric,
@@ -804,6 +848,11 @@ def get_analytics_receivables(
total_amount_lt=total_amount_lt,
total_amount_gte=total_amount_gte,
total_amount_lte=total_amount_lte,
+ discounted_subtotal=discounted_subtotal,
+ discounted_subtotal_gt=discounted_subtotal_gt,
+ discounted_subtotal_lt=discounted_subtotal_lt,
+ discounted_subtotal_gte=discounted_subtotal_gte,
+ discounted_subtotal_lte=discounted_subtotal_lte,
status=status,
entity_user_id=entity_user_id,
based_on=based_on,
@@ -968,11 +1017,24 @@ async def get_analytics_credit_notes(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.analytics.get_analytics_credit_notes(metric="id", aggregation_function="count", )
+ await client.analytics.get_analytics_credit_notes(
+ metric="id",
+ aggregation_function="count",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_analytics_credit_notes(
@@ -1070,6 +1132,7 @@ async def get_analytics_payables(
project_id_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
tag_ids: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
tag_ids_not_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
+ has_tags: typing.Optional[bool] = None,
origin: typing.Optional[PayableOriginEnum] = None,
has_file: typing.Optional[bool] = None,
request_options: typing.Optional[RequestOptions] = None,
@@ -1241,6 +1304,9 @@ async def get_analytics_payables(
tag_ids_not_in : typing.Optional[typing.Union[str, typing.Sequence[str]]]
Return only payables whose `tags` do not include any of the tags with the specified IDs. Valid but nonexistent tag IDs do not raise errors but produce the results.
+ has_tags : typing.Optional[bool]
+ Filter objects based on whether they have tags. If true, only objects with tags are returned. If false, only objects without tags are returned.
+
origin : typing.Optional[PayableOriginEnum]
Return only payables from a given origin ['einvoice', 'upload', 'email']
@@ -1257,11 +1323,24 @@ async def get_analytics_payables(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.analytics.get_analytics_payables(metric="id", aggregation_function="count", )
+ await client.analytics.get_analytics_payables(
+ metric="id",
+ aggregation_function="count",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_analytics_payables(
@@ -1315,6 +1394,7 @@ async def main() -> None:
project_id_in=project_id_in,
tag_ids=tag_ids,
tag_ids_not_in=tag_ids_not_in,
+ has_tags=has_tags,
origin=origin,
has_file=has_file,
request_options=request_options,
@@ -1365,6 +1445,11 @@ async def get_analytics_receivables(
total_amount_lt: typing.Optional[int] = None,
total_amount_gte: typing.Optional[int] = None,
total_amount_lte: typing.Optional[int] = None,
+ discounted_subtotal: typing.Optional[int] = None,
+ discounted_subtotal_gt: typing.Optional[int] = None,
+ discounted_subtotal_lt: typing.Optional[int] = None,
+ discounted_subtotal_gte: typing.Optional[int] = None,
+ discounted_subtotal_lte: typing.Optional[int] = None,
status: typing.Optional[GetAnalyticsReceivablesRequestStatus] = None,
entity_user_id: typing.Optional[str] = None,
based_on: typing.Optional[str] = None,
@@ -1529,6 +1614,16 @@ async def get_analytics_receivables(
total_amount_lte : typing.Optional[int]
+ discounted_subtotal : typing.Optional[int]
+
+ discounted_subtotal_gt : typing.Optional[int]
+
+ discounted_subtotal_lt : typing.Optional[int]
+
+ discounted_subtotal_gte : typing.Optional[int]
+
+ discounted_subtotal_lte : typing.Optional[int]
+
status : typing.Optional[GetAnalyticsReceivablesRequestStatus]
entity_user_id : typing.Optional[str]
@@ -1555,11 +1650,24 @@ async def get_analytics_receivables(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.analytics.get_analytics_receivables(metric="id", aggregation_function="count", )
+ await client.analytics.get_analytics_receivables(
+ metric="id",
+ aggregation_function="count",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_analytics_receivables(
@@ -1600,6 +1708,11 @@ async def main() -> None:
total_amount_lt=total_amount_lt,
total_amount_gte=total_amount_gte,
total_amount_lte=total_amount_lte,
+ discounted_subtotal=discounted_subtotal,
+ discounted_subtotal_gt=discounted_subtotal_gt,
+ discounted_subtotal_lt=discounted_subtotal_lt,
+ discounted_subtotal_gte=discounted_subtotal_gte,
+ discounted_subtotal_lte=discounted_subtotal_lte,
status=status,
entity_user_id=entity_user_id,
based_on=based_on,
diff --git a/src/monite/analytics/raw_client.py b/src/monite/analytics/raw_client.py
index 856245a..5082b2d 100644
--- a/src/monite/analytics/raw_client.py
+++ b/src/monite/analytics/raw_client.py
@@ -333,6 +333,7 @@ def get_analytics_payables(
project_id_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
tag_ids: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
tag_ids_not_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
+ has_tags: typing.Optional[bool] = None,
origin: typing.Optional[PayableOriginEnum] = None,
has_file: typing.Optional[bool] = None,
request_options: typing.Optional[RequestOptions] = None,
@@ -504,6 +505,9 @@ def get_analytics_payables(
tag_ids_not_in : typing.Optional[typing.Union[str, typing.Sequence[str]]]
Return only payables whose `tags` do not include any of the tags with the specified IDs. Valid but nonexistent tag IDs do not raise errors but produce the results.
+ has_tags : typing.Optional[bool]
+ Filter objects based on whether they have tags. If true, only objects with tags are returned. If false, only objects without tags are returned.
+
origin : typing.Optional[PayableOriginEnum]
Return only payables from a given origin ['einvoice', 'upload', 'email']
@@ -572,6 +576,7 @@ def get_analytics_payables(
"project_id__in": project_id_in,
"tag_ids": tag_ids,
"tag_ids__not_in": tag_ids_not_in,
+ "has_tags": has_tags,
"origin": origin,
"has_file": has_file,
},
@@ -680,6 +685,11 @@ def get_analytics_receivables(
total_amount_lt: typing.Optional[int] = None,
total_amount_gte: typing.Optional[int] = None,
total_amount_lte: typing.Optional[int] = None,
+ discounted_subtotal: typing.Optional[int] = None,
+ discounted_subtotal_gt: typing.Optional[int] = None,
+ discounted_subtotal_lt: typing.Optional[int] = None,
+ discounted_subtotal_gte: typing.Optional[int] = None,
+ discounted_subtotal_lte: typing.Optional[int] = None,
status: typing.Optional[GetAnalyticsReceivablesRequestStatus] = None,
entity_user_id: typing.Optional[str] = None,
based_on: typing.Optional[str] = None,
@@ -844,6 +854,16 @@ def get_analytics_receivables(
total_amount_lte : typing.Optional[int]
+ discounted_subtotal : typing.Optional[int]
+
+ discounted_subtotal_gt : typing.Optional[int]
+
+ discounted_subtotal_lt : typing.Optional[int]
+
+ discounted_subtotal_gte : typing.Optional[int]
+
+ discounted_subtotal_lte : typing.Optional[int]
+
status : typing.Optional[GetAnalyticsReceivablesRequestStatus]
entity_user_id : typing.Optional[str]
@@ -909,6 +929,11 @@ def get_analytics_receivables(
"total_amount__lt": total_amount_lt,
"total_amount__gte": total_amount_gte,
"total_amount__lte": total_amount_lte,
+ "discounted_subtotal": discounted_subtotal,
+ "discounted_subtotal__gt": discounted_subtotal_gt,
+ "discounted_subtotal__lt": discounted_subtotal_lt,
+ "discounted_subtotal__gte": discounted_subtotal_gte,
+ "discounted_subtotal__lte": discounted_subtotal_lte,
"status": status,
"entity_user_id": entity_user_id,
"based_on": based_on,
@@ -1285,6 +1310,7 @@ async def get_analytics_payables(
project_id_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
tag_ids: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
tag_ids_not_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
+ has_tags: typing.Optional[bool] = None,
origin: typing.Optional[PayableOriginEnum] = None,
has_file: typing.Optional[bool] = None,
request_options: typing.Optional[RequestOptions] = None,
@@ -1456,6 +1482,9 @@ async def get_analytics_payables(
tag_ids_not_in : typing.Optional[typing.Union[str, typing.Sequence[str]]]
Return only payables whose `tags` do not include any of the tags with the specified IDs. Valid but nonexistent tag IDs do not raise errors but produce the results.
+ has_tags : typing.Optional[bool]
+ Filter objects based on whether they have tags. If true, only objects with tags are returned. If false, only objects without tags are returned.
+
origin : typing.Optional[PayableOriginEnum]
Return only payables from a given origin ['einvoice', 'upload', 'email']
@@ -1524,6 +1553,7 @@ async def get_analytics_payables(
"project_id__in": project_id_in,
"tag_ids": tag_ids,
"tag_ids__not_in": tag_ids_not_in,
+ "has_tags": has_tags,
"origin": origin,
"has_file": has_file,
},
@@ -1632,6 +1662,11 @@ async def get_analytics_receivables(
total_amount_lt: typing.Optional[int] = None,
total_amount_gte: typing.Optional[int] = None,
total_amount_lte: typing.Optional[int] = None,
+ discounted_subtotal: typing.Optional[int] = None,
+ discounted_subtotal_gt: typing.Optional[int] = None,
+ discounted_subtotal_lt: typing.Optional[int] = None,
+ discounted_subtotal_gte: typing.Optional[int] = None,
+ discounted_subtotal_lte: typing.Optional[int] = None,
status: typing.Optional[GetAnalyticsReceivablesRequestStatus] = None,
entity_user_id: typing.Optional[str] = None,
based_on: typing.Optional[str] = None,
@@ -1796,6 +1831,16 @@ async def get_analytics_receivables(
total_amount_lte : typing.Optional[int]
+ discounted_subtotal : typing.Optional[int]
+
+ discounted_subtotal_gt : typing.Optional[int]
+
+ discounted_subtotal_lt : typing.Optional[int]
+
+ discounted_subtotal_gte : typing.Optional[int]
+
+ discounted_subtotal_lte : typing.Optional[int]
+
status : typing.Optional[GetAnalyticsReceivablesRequestStatus]
entity_user_id : typing.Optional[str]
@@ -1861,6 +1906,11 @@ async def get_analytics_receivables(
"total_amount__lt": total_amount_lt,
"total_amount__gte": total_amount_gte,
"total_amount__lte": total_amount_lte,
+ "discounted_subtotal": discounted_subtotal,
+ "discounted_subtotal__gt": discounted_subtotal_gt,
+ "discounted_subtotal__lt": discounted_subtotal_lt,
+ "discounted_subtotal__gte": discounted_subtotal_gte,
+ "discounted_subtotal__lte": discounted_subtotal_lte,
"status": status,
"entity_user_id": entity_user_id,
"based_on": based_on,
diff --git a/src/monite/approval_policies/client.py b/src/monite/approval_policies/client.py
index ef0c520..8de4974 100644
--- a/src/monite/approval_policies/client.py
+++ b/src/monite/approval_policies/client.py
@@ -130,7 +130,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.approval_policies.get()
"""
_response = self._raw_client.get(
@@ -203,8 +208,16 @@ def create(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.approval_policies.create(name='name', script=[True], )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.approval_policies.create(
+ name="name",
+ script=[True],
+ )
"""
_response = self._raw_client.create(
name=name,
@@ -238,8 +251,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.approval_policies.get_by_id(approval_policy_id='approval_policy_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.approval_policies.get_by_id(
+ approval_policy_id="approval_policy_id",
+ )
"""
_response = self._raw_client.get_by_id(approval_policy_id, request_options=request_options)
return _response.data
@@ -262,8 +282,15 @@ def delete_by_id(self, approval_policy_id: str, *, request_options: typing.Optio
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.approval_policies.delete_by_id(approval_policy_id='approval_policy_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.approval_policies.delete_by_id(
+ approval_policy_id="approval_policy_id",
+ )
"""
_response = self._raw_client.delete_by_id(approval_policy_id, request_options=request_options)
return _response.data
@@ -320,8 +347,15 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.approval_policies.update_by_id(approval_policy_id='approval_policy_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.approval_policies.update_by_id(
+ approval_policy_id="approval_policy_id",
+ )
"""
_response = self._raw_client.update_by_id(
approval_policy_id,
@@ -443,11 +477,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.approval_policies.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
@@ -519,11 +563,24 @@ async def create(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.approval_policies.create(name='name', script=[True], )
+ await client.approval_policies.create(
+ name="name",
+ script=[True],
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -557,11 +614,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.approval_policies.get_by_id(approval_policy_id='approval_policy_id', )
+ await client.approval_policies.get_by_id(
+ approval_policy_id="approval_policy_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(approval_policy_id, request_options=request_options)
@@ -586,11 +655,23 @@ async def delete_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.approval_policies.delete_by_id(approval_policy_id='approval_policy_id', )
+ await client.approval_policies.delete_by_id(
+ approval_policy_id="approval_policy_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(approval_policy_id, request_options=request_options)
@@ -647,11 +728,23 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.approval_policies.update_by_id(approval_policy_id='approval_policy_id', )
+ await client.approval_policies.update_by_id(
+ approval_policy_id="approval_policy_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
diff --git a/src/monite/approval_policies/processes/client.py b/src/monite/approval_policies/processes/client.py
index c95b17e..a131b65 100644
--- a/src/monite/approval_policies/processes/client.py
+++ b/src/monite/approval_policies/processes/client.py
@@ -46,8 +46,15 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.approval_policies.processes.get(approval_policy_id='approval_policy_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.approval_policies.processes.get(
+ approval_policy_id="approval_policy_id",
+ )
"""
_response = self._raw_client.get(approval_policy_id, request_options=request_options)
return _response.data
@@ -75,8 +82,16 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.approval_policies.processes.get_by_id(approval_policy_id='approval_policy_id', process_id='process_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.approval_policies.processes.get_by_id(
+ approval_policy_id="approval_policy_id",
+ process_id="process_id",
+ )
"""
_response = self._raw_client.get_by_id(approval_policy_id, process_id, request_options=request_options)
return _response.data
@@ -104,8 +119,16 @@ def cancel_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.approval_policies.processes.cancel_by_id(approval_policy_id='approval_policy_id', process_id='process_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.approval_policies.processes.cancel_by_id(
+ approval_policy_id="approval_policy_id",
+ process_id="process_id",
+ )
"""
_response = self._raw_client.cancel_by_id(approval_policy_id, process_id, request_options=request_options)
return _response.data
@@ -133,8 +156,16 @@ def get_steps(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.approval_policies.processes.get_steps(approval_policy_id='approval_policy_id', process_id='process_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.approval_policies.processes.get_steps(
+ approval_policy_id="approval_policy_id",
+ process_id="process_id",
+ )
"""
_response = self._raw_client.get_steps(approval_policy_id, process_id, request_options=request_options)
return _response.data
@@ -175,11 +206,23 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.approval_policies.processes.get(approval_policy_id='approval_policy_id', )
+ await client.approval_policies.processes.get(
+ approval_policy_id="approval_policy_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(approval_policy_id, request_options=request_options)
@@ -207,11 +250,24 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.approval_policies.processes.get_by_id(approval_policy_id='approval_policy_id', process_id='process_id', )
+ await client.approval_policies.processes.get_by_id(
+ approval_policy_id="approval_policy_id",
+ process_id="process_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(approval_policy_id, process_id, request_options=request_options)
@@ -239,11 +295,24 @@ async def cancel_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.approval_policies.processes.cancel_by_id(approval_policy_id='approval_policy_id', process_id='process_id', )
+ await client.approval_policies.processes.cancel_by_id(
+ approval_policy_id="approval_policy_id",
+ process_id="process_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.cancel_by_id(approval_policy_id, process_id, request_options=request_options)
@@ -271,11 +340,24 @@ async def get_steps(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.approval_policies.processes.get_steps(approval_policy_id='approval_policy_id', process_id='process_id', )
+ await client.approval_policies.processes.get_steps(
+ approval_policy_id="approval_policy_id",
+ process_id="process_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_steps(approval_policy_id, process_id, request_options=request_options)
diff --git a/src/monite/approval_requests/client.py b/src/monite/approval_requests/client.py
index 3f973d4..8c964bb 100644
--- a/src/monite/approval_requests/client.py
+++ b/src/monite/approval_requests/client.py
@@ -119,7 +119,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.approval_requests.get()
"""
_response = self._raw_client.get(
@@ -166,10 +171,21 @@ def create(
Examples
--------
- from monite import Monite
- from monite import ApprovalRequestCreateByRoleRequest
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.approval_requests.create(request=ApprovalRequestCreateByRoleRequest(object_id='object_id', object_type="account", required_approval_count=1, role_ids=['role_ids'], ), )
+ from monite import ApprovalRequestCreateByRoleRequest, Monite
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.approval_requests.create(
+ request=ApprovalRequestCreateByRoleRequest(
+ object_id="object_id",
+ object_type="account",
+ required_approval_count=1,
+ role_ids=["role_ids"],
+ ),
+ )
"""
_response = self._raw_client.create(request=request, request_options=request_options)
return _response.data
@@ -193,8 +209,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.approval_requests.get_by_id(approval_request_id='approval_request_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.approval_requests.get_by_id(
+ approval_request_id="approval_request_id",
+ )
"""
_response = self._raw_client.get_by_id(approval_request_id, request_options=request_options)
return _response.data
@@ -218,8 +241,15 @@ def approve_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.approval_requests.approve_by_id(approval_request_id='approval_request_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.approval_requests.approve_by_id(
+ approval_request_id="approval_request_id",
+ )
"""
_response = self._raw_client.approve_by_id(approval_request_id, request_options=request_options)
return _response.data
@@ -243,8 +273,15 @@ def cancel_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.approval_requests.cancel_by_id(approval_request_id='approval_request_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.approval_requests.cancel_by_id(
+ approval_request_id="approval_request_id",
+ )
"""
_response = self._raw_client.cancel_by_id(approval_request_id, request_options=request_options)
return _response.data
@@ -268,8 +305,15 @@ def reject_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.approval_requests.reject_by_id(approval_request_id='approval_request_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.approval_requests.reject_by_id(
+ approval_request_id="approval_request_id",
+ )
"""
_response = self._raw_client.reject_by_id(approval_request_id, request_options=request_options)
return _response.data
@@ -375,11 +419,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.approval_requests.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
@@ -426,12 +480,28 @@ async def create(
Examples
--------
- from monite import AsyncMonite
- from monite import ApprovalRequestCreateByRoleRequest
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import ApprovalRequestCreateByRoleRequest, AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.approval_requests.create(request=ApprovalRequestCreateByRoleRequest(object_id='object_id', object_type="account", required_approval_count=1, role_ids=['role_ids'], ), )
+ await client.approval_requests.create(
+ request=ApprovalRequestCreateByRoleRequest(
+ object_id="object_id",
+ object_type="account",
+ required_approval_count=1,
+ role_ids=["role_ids"],
+ ),
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(request=request, request_options=request_options)
@@ -455,11 +525,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.approval_requests.get_by_id(approval_request_id='approval_request_id', )
+ await client.approval_requests.get_by_id(
+ approval_request_id="approval_request_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(approval_request_id, request_options=request_options)
@@ -483,11 +565,23 @@ async def approve_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.approval_requests.approve_by_id(approval_request_id='approval_request_id', )
+ await client.approval_requests.approve_by_id(
+ approval_request_id="approval_request_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.approve_by_id(approval_request_id, request_options=request_options)
@@ -511,11 +605,23 @@ async def cancel_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.approval_requests.cancel_by_id(approval_request_id='approval_request_id', )
+ await client.approval_requests.cancel_by_id(
+ approval_request_id="approval_request_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.cancel_by_id(approval_request_id, request_options=request_options)
@@ -539,11 +645,23 @@ async def reject_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.approval_requests.reject_by_id(approval_request_id='approval_request_id', )
+ await client.approval_requests.reject_by_id(
+ approval_request_id="approval_request_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.reject_by_id(approval_request_id, request_options=request_options)
diff --git a/src/monite/client.py b/src/monite/client.py
index 802d895..7edd723 100644
--- a/src/monite/client.py
+++ b/src/monite/client.py
@@ -16,6 +16,7 @@
)
from .counterparts.client import AsyncCounterpartsClient, CounterpartsClient
from .credit_notes.client import AsyncCreditNotesClient, CreditNotesClient
+from .custom_vat_rates.client import AsyncCustomVatRatesClient, CustomVatRatesClient
from .data_exports.client import AsyncDataExportsClient, DataExportsClient
from .delivery_notes.client import AsyncDeliveryNotesClient, DeliveryNotesClient
from .e_invoicing_connections.client import AsyncEInvoicingConnectionsClient, EInvoicingConnectionsClient
@@ -64,6 +65,8 @@ class Monite:
environment : MoniteEnvironment
The environment to use for requests from the client. from .environment import MoniteEnvironment
+
+
Defaults to MoniteEnvironment.SANDBOX
@@ -71,6 +74,9 @@ class Monite:
monite_version : str
monite_entity_id : typing.Optional[str]
token : typing.Optional[typing.Union[str, typing.Callable[[], str]]]
+ headers : typing.Optional[typing.Dict[str, str]]
+ Additional headers to send with every request.
+
timeout : typing.Optional[float]
The timeout to be used, in seconds, for requests. By default the timeout is 60 seconds, unless a custom httpx client is used, in which case this default is not enforced.
@@ -83,7 +89,12 @@ class Monite:
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
"""
def __init__(
@@ -94,6 +105,7 @@ def __init__(
monite_version: str,
monite_entity_id: typing.Optional[str] = None,
token: typing.Optional[typing.Union[str, typing.Callable[[], str]]] = None,
+ headers: typing.Optional[typing.Dict[str, str]] = None,
timeout: typing.Optional[float] = None,
follow_redirects: typing.Optional[bool] = True,
httpx_client: typing.Optional[httpx.Client] = None,
@@ -106,6 +118,7 @@ def __init__(
monite_version=monite_version,
monite_entity_id=monite_entity_id,
token=token,
+ headers=headers,
httpx_client=httpx_client
if httpx_client is not None
else httpx.Client(timeout=_defaulted_timeout, follow_redirects=follow_redirects)
@@ -122,6 +135,7 @@ def __init__(
self.counterpart_e_invoicing_credentials = CounterpartEInvoicingCredentialsClient(
client_wrapper=self._client_wrapper
)
+ self.custom_vat_rates = CustomVatRatesClient(client_wrapper=self._client_wrapper)
self.data_exports = DataExportsClient(client_wrapper=self._client_wrapper)
self.delivery_notes = DeliveryNotesClient(client_wrapper=self._client_wrapper)
self.pdf_templates = PdfTemplatesClient(client_wrapper=self._client_wrapper)
@@ -171,6 +185,8 @@ class AsyncMonite:
environment : MoniteEnvironment
The environment to use for requests from the client. from .environment import MoniteEnvironment
+
+
Defaults to MoniteEnvironment.SANDBOX
@@ -178,6 +194,9 @@ class AsyncMonite:
monite_version : str
monite_entity_id : typing.Optional[str]
token : typing.Optional[typing.Union[str, typing.Callable[[], str]]]
+ headers : typing.Optional[typing.Dict[str, str]]
+ Additional headers to send with every request.
+
timeout : typing.Optional[float]
The timeout to be used, in seconds, for requests. By default the timeout is 60 seconds, unless a custom httpx client is used, in which case this default is not enforced.
@@ -190,7 +209,12 @@ class AsyncMonite:
Examples
--------
from monite import AsyncMonite
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
"""
def __init__(
@@ -201,6 +225,7 @@ def __init__(
monite_version: str,
monite_entity_id: typing.Optional[str] = None,
token: typing.Optional[typing.Union[str, typing.Callable[[], str]]] = None,
+ headers: typing.Optional[typing.Dict[str, str]] = None,
timeout: typing.Optional[float] = None,
follow_redirects: typing.Optional[bool] = True,
httpx_client: typing.Optional[httpx.AsyncClient] = None,
@@ -213,6 +238,7 @@ def __init__(
monite_version=monite_version,
monite_entity_id=monite_entity_id,
token=token,
+ headers=headers,
httpx_client=httpx_client
if httpx_client is not None
else httpx.AsyncClient(timeout=_defaulted_timeout, follow_redirects=follow_redirects)
@@ -229,6 +255,7 @@ def __init__(
self.counterpart_e_invoicing_credentials = AsyncCounterpartEInvoicingCredentialsClient(
client_wrapper=self._client_wrapper
)
+ self.custom_vat_rates = AsyncCustomVatRatesClient(client_wrapper=self._client_wrapper)
self.data_exports = AsyncDataExportsClient(client_wrapper=self._client_wrapper)
self.delivery_notes = AsyncDeliveryNotesClient(client_wrapper=self._client_wrapper)
self.pdf_templates = AsyncPdfTemplatesClient(client_wrapper=self._client_wrapper)
diff --git a/src/monite/comments/client.py b/src/monite/comments/client.py
index 3da5b72..10390da 100644
--- a/src/monite/comments/client.py
+++ b/src/monite/comments/client.py
@@ -82,8 +82,15 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.comments.get(object_id='object_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.comments.get(
+ object_id="object_id",
+ )
"""
_response = self._raw_client.get(
object_id=object_id,
@@ -132,8 +139,17 @@ def create(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.comments.create(object_id='object_id', object_type='object_type', text='text', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.comments.create(
+ object_id="object_id",
+ object_type="object_type",
+ text="text",
+ )
"""
_response = self._raw_client.create(
object_id=object_id,
@@ -163,8 +179,15 @@ def get_by_id(self, comment_id: str, *, request_options: typing.Optional[Request
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.comments.get_by_id(comment_id='comment_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.comments.get_by_id(
+ comment_id="comment_id",
+ )
"""
_response = self._raw_client.get_by_id(comment_id, request_options=request_options)
return _response.data
@@ -187,8 +210,15 @@ def delete_by_id(self, comment_id: str, *, request_options: typing.Optional[Requ
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.comments.delete_by_id(comment_id='comment_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.comments.delete_by_id(
+ comment_id="comment_id",
+ )
"""
_response = self._raw_client.delete_by_id(comment_id, request_options=request_options)
return _response.data
@@ -223,8 +253,15 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.comments.update_by_id(comment_id='comment_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.comments.update_by_id(
+ comment_id="comment_id",
+ )
"""
_response = self._raw_client.update_by_id(
comment_id, reply_to_entity_user_id=reply_to_entity_user_id, text=text, request_options=request_options
@@ -298,11 +335,23 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.comments.get(object_id='object_id', )
+ await client.comments.get(
+ object_id="object_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
@@ -351,11 +400,25 @@ async def create(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.comments.create(object_id='object_id', object_type='object_type', text='text', )
+ await client.comments.create(
+ object_id="object_id",
+ object_type="object_type",
+ text="text",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -387,11 +450,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.comments.get_by_id(comment_id='comment_id', )
+ await client.comments.get_by_id(
+ comment_id="comment_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(comment_id, request_options=request_options)
@@ -414,11 +489,23 @@ async def delete_by_id(self, comment_id: str, *, request_options: typing.Optiona
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.comments.delete_by_id(comment_id='comment_id', )
+ await client.comments.delete_by_id(
+ comment_id="comment_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(comment_id, request_options=request_options)
@@ -453,11 +540,23 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.comments.update_by_id(comment_id='comment_id', )
+ await client.comments.update_by_id(
+ comment_id="comment_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
diff --git a/src/monite/core/client_wrapper.py b/src/monite/core/client_wrapper.py
index c97465d..bf8e2ed 100644
--- a/src/monite/core/client_wrapper.py
+++ b/src/monite/core/client_wrapper.py
@@ -13,21 +13,24 @@ def __init__(
monite_version: str,
monite_entity_id: typing.Optional[str] = None,
token: typing.Optional[typing.Union[str, typing.Callable[[], str]]] = None,
+ headers: typing.Optional[typing.Dict[str, str]] = None,
base_url: str,
timeout: typing.Optional[float] = None,
):
self._monite_version = monite_version
self._monite_entity_id = monite_entity_id
self._token = token
+ self._headers = headers
self._base_url = base_url
self._timeout = timeout
def get_headers(self) -> typing.Dict[str, str]:
headers: typing.Dict[str, str] = {
- "User-Agent": "monite/0.5.2",
+ "User-Agent": "monite/0.5.3",
"X-Fern-Language": "Python",
"X-Fern-SDK-Name": "monite",
- "X-Fern-SDK-Version": "0.5.2",
+ "X-Fern-SDK-Version": "0.5.3",
+ **(self.get_custom_headers() or {}),
}
headers["x-monite-version"] = self._monite_version
if self._monite_entity_id is not None:
@@ -43,6 +46,9 @@ def _get_token(self) -> typing.Optional[str]:
else:
return self._token()
+ def get_custom_headers(self) -> typing.Optional[typing.Dict[str, str]]:
+ return self._headers
+
def get_base_url(self) -> str:
return self._base_url
@@ -57,6 +63,7 @@ def __init__(
monite_version: str,
monite_entity_id: typing.Optional[str] = None,
token: typing.Optional[typing.Union[str, typing.Callable[[], str]]] = None,
+ headers: typing.Optional[typing.Dict[str, str]] = None,
base_url: str,
timeout: typing.Optional[float] = None,
httpx_client: httpx.Client,
@@ -65,6 +72,7 @@ def __init__(
monite_version=monite_version,
monite_entity_id=monite_entity_id,
token=token,
+ headers=headers,
base_url=base_url,
timeout=timeout,
)
@@ -83,6 +91,7 @@ def __init__(
monite_version: str,
monite_entity_id: typing.Optional[str] = None,
token: typing.Optional[typing.Union[str, typing.Callable[[], str]]] = None,
+ headers: typing.Optional[typing.Dict[str, str]] = None,
base_url: str,
timeout: typing.Optional[float] = None,
httpx_client: httpx.AsyncClient,
@@ -91,6 +100,7 @@ def __init__(
monite_version=monite_version,
monite_entity_id=monite_entity_id,
token=token,
+ headers=headers,
base_url=base_url,
timeout=timeout,
)
diff --git a/src/monite/core/force_multipart.py b/src/monite/core/force_multipart.py
new file mode 100644
index 0000000..ae24ccf
--- /dev/null
+++ b/src/monite/core/force_multipart.py
@@ -0,0 +1,16 @@
+# This file was auto-generated by Fern from our API Definition.
+
+
+class ForceMultipartDict(dict):
+ """
+ A dictionary subclass that always evaluates to True in boolean contexts.
+
+ This is used to force multipart/form-data encoding in HTTP requests even when
+ the dictionary is empty, which would normally evaluate to False.
+ """
+
+ def __bool__(self):
+ return True
+
+
+FORCE_MULTIPART = ForceMultipartDict()
diff --git a/src/monite/core/http_client.py b/src/monite/core/http_client.py
index e7bd4f7..e4173f9 100644
--- a/src/monite/core/http_client.py
+++ b/src/monite/core/http_client.py
@@ -11,10 +11,12 @@
import httpx
from .file import File, convert_file_dict_to_httpx_tuples
+from .force_multipart import FORCE_MULTIPART
from .jsonable_encoder import jsonable_encoder
from .query_encoder import encode_query
from .remove_none_from_dict import remove_none_from_dict
from .request_options import RequestOptions
+from httpx._types import RequestFiles
INITIAL_RETRY_DELAY_SECONDS = 0.5
MAX_RETRY_DELAY_SECONDS = 10
@@ -178,11 +180,17 @@ def request(
json: typing.Optional[typing.Any] = None,
data: typing.Optional[typing.Any] = None,
content: typing.Optional[typing.Union[bytes, typing.Iterator[bytes], typing.AsyncIterator[bytes]]] = None,
- files: typing.Optional[typing.Dict[str, typing.Optional[typing.Union[File, typing.List[File]]]]] = None,
+ files: typing.Optional[
+ typing.Union[
+ typing.Dict[str, typing.Optional[typing.Union[File, typing.List[File]]]],
+ typing.List[typing.Tuple[str, File]],
+ ]
+ ] = None,
headers: typing.Optional[typing.Dict[str, typing.Any]] = None,
request_options: typing.Optional[RequestOptions] = None,
retries: int = 2,
omit: typing.Optional[typing.Any] = None,
+ force_multipart: typing.Optional[bool] = None,
) -> httpx.Response:
base_url = self.get_base_url(base_url)
timeout = (
@@ -193,6 +201,15 @@ def request(
json_body, data_body = get_request_body(json=json, data=data, request_options=request_options, omit=omit)
+ request_files: typing.Optional[RequestFiles] = (
+ convert_file_dict_to_httpx_tuples(remove_omit_from_dict(remove_none_from_dict(files), omit))
+ if (files is not None and files is not omit and isinstance(files, dict))
+ else None
+ )
+
+ if (request_files is None or len(request_files) == 0) and force_multipart:
+ request_files = FORCE_MULTIPART
+
response = self.httpx_client.request(
method=method,
url=urllib.parse.urljoin(f"{base_url}/", path),
@@ -225,11 +242,7 @@ def request(
json=json_body,
data=data_body,
content=content,
- files=(
- convert_file_dict_to_httpx_tuples(remove_omit_from_dict(remove_none_from_dict(files), omit))
- if (files is not None and files is not omit)
- else None
- ),
+ files=request_files,
timeout=timeout,
)
@@ -264,11 +277,17 @@ def stream(
json: typing.Optional[typing.Any] = None,
data: typing.Optional[typing.Any] = None,
content: typing.Optional[typing.Union[bytes, typing.Iterator[bytes], typing.AsyncIterator[bytes]]] = None,
- files: typing.Optional[typing.Dict[str, typing.Optional[typing.Union[File, typing.List[File]]]]] = None,
+ files: typing.Optional[
+ typing.Union[
+ typing.Dict[str, typing.Optional[typing.Union[File, typing.List[File]]]],
+ typing.List[typing.Tuple[str, File]],
+ ]
+ ] = None,
headers: typing.Optional[typing.Dict[str, typing.Any]] = None,
request_options: typing.Optional[RequestOptions] = None,
retries: int = 2,
omit: typing.Optional[typing.Any] = None,
+ force_multipart: typing.Optional[bool] = None,
) -> typing.Iterator[httpx.Response]:
base_url = self.get_base_url(base_url)
timeout = (
@@ -277,6 +296,15 @@ def stream(
else self.base_timeout()
)
+ request_files: typing.Optional[RequestFiles] = (
+ convert_file_dict_to_httpx_tuples(remove_omit_from_dict(remove_none_from_dict(files), omit))
+ if (files is not None and files is not omit and isinstance(files, dict))
+ else None
+ )
+
+ if (request_files is None or len(request_files) == 0) and force_multipart:
+ request_files = FORCE_MULTIPART
+
json_body, data_body = get_request_body(json=json, data=data, request_options=request_options, omit=omit)
with self.httpx_client.stream(
@@ -311,11 +339,7 @@ def stream(
json=json_body,
data=data_body,
content=content,
- files=(
- convert_file_dict_to_httpx_tuples(remove_omit_from_dict(remove_none_from_dict(files), omit))
- if (files is not None and files is not omit)
- else None
- ),
+ files=request_files,
timeout=timeout,
) as stream:
yield stream
@@ -354,11 +378,17 @@ async def request(
json: typing.Optional[typing.Any] = None,
data: typing.Optional[typing.Any] = None,
content: typing.Optional[typing.Union[bytes, typing.Iterator[bytes], typing.AsyncIterator[bytes]]] = None,
- files: typing.Optional[typing.Dict[str, typing.Optional[typing.Union[File, typing.List[File]]]]] = None,
+ files: typing.Optional[
+ typing.Union[
+ typing.Dict[str, typing.Optional[typing.Union[File, typing.List[File]]]],
+ typing.List[typing.Tuple[str, File]],
+ ]
+ ] = None,
headers: typing.Optional[typing.Dict[str, typing.Any]] = None,
request_options: typing.Optional[RequestOptions] = None,
retries: int = 2,
omit: typing.Optional[typing.Any] = None,
+ force_multipart: typing.Optional[bool] = None,
) -> httpx.Response:
base_url = self.get_base_url(base_url)
timeout = (
@@ -367,6 +397,15 @@ async def request(
else self.base_timeout()
)
+ request_files: typing.Optional[RequestFiles] = (
+ convert_file_dict_to_httpx_tuples(remove_omit_from_dict(remove_none_from_dict(files), omit))
+ if (files is not None and files is not omit and isinstance(files, dict))
+ else None
+ )
+
+ if (request_files is None or len(request_files) == 0) and force_multipart:
+ request_files = FORCE_MULTIPART
+
json_body, data_body = get_request_body(json=json, data=data, request_options=request_options, omit=omit)
# Add the input to each of these and do None-safety checks
@@ -402,11 +441,7 @@ async def request(
json=json_body,
data=data_body,
content=content,
- files=(
- convert_file_dict_to_httpx_tuples(remove_omit_from_dict(remove_none_from_dict(files), omit))
- if files is not None
- else None
- ),
+ files=request_files,
timeout=timeout,
)
@@ -440,11 +475,17 @@ async def stream(
json: typing.Optional[typing.Any] = None,
data: typing.Optional[typing.Any] = None,
content: typing.Optional[typing.Union[bytes, typing.Iterator[bytes], typing.AsyncIterator[bytes]]] = None,
- files: typing.Optional[typing.Dict[str, typing.Optional[typing.Union[File, typing.List[File]]]]] = None,
+ files: typing.Optional[
+ typing.Union[
+ typing.Dict[str, typing.Optional[typing.Union[File, typing.List[File]]]],
+ typing.List[typing.Tuple[str, File]],
+ ]
+ ] = None,
headers: typing.Optional[typing.Dict[str, typing.Any]] = None,
request_options: typing.Optional[RequestOptions] = None,
retries: int = 2,
omit: typing.Optional[typing.Any] = None,
+ force_multipart: typing.Optional[bool] = None,
) -> typing.AsyncIterator[httpx.Response]:
base_url = self.get_base_url(base_url)
timeout = (
@@ -453,6 +494,15 @@ async def stream(
else self.base_timeout()
)
+ request_files: typing.Optional[RequestFiles] = (
+ convert_file_dict_to_httpx_tuples(remove_omit_from_dict(remove_none_from_dict(files), omit))
+ if (files is not None and files is not omit and isinstance(files, dict))
+ else None
+ )
+
+ if (request_files is None or len(request_files) == 0) and force_multipart:
+ request_files = FORCE_MULTIPART
+
json_body, data_body = get_request_body(json=json, data=data, request_options=request_options, omit=omit)
async with self.httpx_client.stream(
@@ -487,11 +537,7 @@ async def stream(
json=json_body,
data=data_body,
content=content,
- files=(
- convert_file_dict_to_httpx_tuples(remove_omit_from_dict(remove_none_from_dict(files), omit))
- if files is not None
- else None
- ),
+ files=request_files,
timeout=timeout,
) as stream:
yield stream
diff --git a/src/monite/core/pydantic_utilities.py b/src/monite/core/pydantic_utilities.py
index 60a2c71..7db2950 100644
--- a/src/monite/core/pydantic_utilities.py
+++ b/src/monite/core/pydantic_utilities.py
@@ -59,9 +59,9 @@ class UniversalBaseModel(pydantic.BaseModel):
protected_namespaces=(),
)
- @pydantic.model_serializer(mode="wrap", when_used="json") # type: ignore[attr-defined]
- def serialize_model(self, handler: pydantic.SerializerFunctionWrapHandler) -> Any: # type: ignore[name-defined]
- serialized = handler(self)
+ @pydantic.model_serializer(mode="plain", when_used="json") # type: ignore[attr-defined]
+ def serialize_model(self) -> Any: # type: ignore[name-defined]
+ serialized = self.model_dump()
data = {k: serialize_datetime(v) if isinstance(v, dt.datetime) else v for k, v in serialized.items()}
return data
@@ -181,7 +181,7 @@ def deep_union_pydantic_dicts(source: Dict[str, Any], destination: Dict[str, Any
if IS_PYDANTIC_V2:
- class V2RootModel(UniversalBaseModel, pydantic.RootModel): # type: ignore[name-defined, type-arg]
+ class V2RootModel(UniversalBaseModel, pydantic.RootModel): # type: ignore[misc, name-defined, type-arg]
pass
UniversalRootModel: TypeAlias = V2RootModel # type: ignore[misc]
diff --git a/src/monite/counterpart_e_invoicing_credentials/client.py b/src/monite/counterpart_e_invoicing_credentials/client.py
index 6aff758..7ae498c 100644
--- a/src/monite/counterpart_e_invoicing_credentials/client.py
+++ b/src/monite/counterpart_e_invoicing_credentials/client.py
@@ -48,8 +48,15 @@ def get_counterparts_id_einvoicing_credentials(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterpart_e_invoicing_credentials.get_counterparts_id_einvoicing_credentials(counterpart_id='counterpart_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterpart_e_invoicing_credentials.get_counterparts_id_einvoicing_credentials(
+ counterpart_id="counterpart_id",
+ )
"""
_response = self._raw_client.get_counterparts_id_einvoicing_credentials(
counterpart_id, request_options=request_options
@@ -80,10 +87,19 @@ def post_counterparts_id_einvoicing_credentials(
Examples
--------
- from monite import Monite
- from monite import CreateCounterpartEinvoicingCredentialCounterpartVatId
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterpart_e_invoicing_credentials.post_counterparts_id_einvoicing_credentials(counterpart_id='counterpart_id', request=CreateCounterpartEinvoicingCredentialCounterpartVatId(counterpart_vat_id_id='counterpart_vat_id_id', ), )
+ from monite import CreateCounterpartEinvoicingCredentialCounterpartVatId, Monite
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterpart_e_invoicing_credentials.post_counterparts_id_einvoicing_credentials(
+ counterpart_id="counterpart_id",
+ request=CreateCounterpartEinvoicingCredentialCounterpartVatId(
+ counterpart_vat_id_id="counterpart_vat_id_id",
+ ),
+ )
"""
_response = self._raw_client.post_counterparts_id_einvoicing_credentials(
counterpart_id, request=request, request_options=request_options
@@ -111,8 +127,16 @@ def get_counterparts_id_einvoicing_credentials_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterpart_e_invoicing_credentials.get_counterparts_id_einvoicing_credentials_id(credential_id='credential_id', counterpart_id='counterpart_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterpart_e_invoicing_credentials.get_counterparts_id_einvoicing_credentials_id(
+ credential_id="credential_id",
+ counterpart_id="counterpart_id",
+ )
"""
_response = self._raw_client.get_counterparts_id_einvoicing_credentials_id(
credential_id, counterpart_id, request_options=request_options
@@ -139,8 +163,16 @@ def delete_counterparts_id_einvoicing_credentials_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterpart_e_invoicing_credentials.delete_counterparts_id_einvoicing_credentials_id(credential_id='credential_id', counterpart_id='counterpart_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterpart_e_invoicing_credentials.delete_counterparts_id_einvoicing_credentials_id(
+ credential_id="credential_id",
+ counterpart_id="counterpart_id",
+ )
"""
_response = self._raw_client.delete_counterparts_id_einvoicing_credentials_id(
credential_id, counterpart_id, request_options=request_options
@@ -178,8 +210,16 @@ def patch_counterparts_id_einvoicing_credentials_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterpart_e_invoicing_credentials.patch_counterparts_id_einvoicing_credentials_id(credential_id='credential_id', counterpart_id='counterpart_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterpart_e_invoicing_credentials.patch_counterparts_id_einvoicing_credentials_id(
+ credential_id="credential_id",
+ counterpart_id="counterpart_id",
+ )
"""
_response = self._raw_client.patch_counterparts_id_einvoicing_credentials_id(
credential_id,
@@ -224,11 +264,23 @@ async def get_counterparts_id_einvoicing_credentials(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterpart_e_invoicing_credentials.get_counterparts_id_einvoicing_credentials(counterpart_id='counterpart_id', )
+ await client.counterpart_e_invoicing_credentials.get_counterparts_id_einvoicing_credentials(
+ counterpart_id="counterpart_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_counterparts_id_einvoicing_credentials(
@@ -260,12 +312,29 @@ async def post_counterparts_id_einvoicing_credentials(
Examples
--------
- from monite import AsyncMonite
- from monite import CreateCounterpartEinvoicingCredentialCounterpartVatId
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import (
+ AsyncMonite,
+ CreateCounterpartEinvoicingCredentialCounterpartVatId,
+ )
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterpart_e_invoicing_credentials.post_counterparts_id_einvoicing_credentials(counterpart_id='counterpart_id', request=CreateCounterpartEinvoicingCredentialCounterpartVatId(counterpart_vat_id_id='counterpart_vat_id_id', ), )
+ await client.counterpart_e_invoicing_credentials.post_counterparts_id_einvoicing_credentials(
+ counterpart_id="counterpart_id",
+ request=CreateCounterpartEinvoicingCredentialCounterpartVatId(
+ counterpart_vat_id_id="counterpart_vat_id_id",
+ ),
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.post_counterparts_id_einvoicing_credentials(
@@ -293,11 +362,24 @@ async def get_counterparts_id_einvoicing_credentials_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterpart_e_invoicing_credentials.get_counterparts_id_einvoicing_credentials_id(credential_id='credential_id', counterpart_id='counterpart_id', )
+ await client.counterpart_e_invoicing_credentials.get_counterparts_id_einvoicing_credentials_id(
+ credential_id="credential_id",
+ counterpart_id="counterpart_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_counterparts_id_einvoicing_credentials_id(
@@ -324,11 +406,24 @@ async def delete_counterparts_id_einvoicing_credentials_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterpart_e_invoicing_credentials.delete_counterparts_id_einvoicing_credentials_id(credential_id='credential_id', counterpart_id='counterpart_id', )
+ await client.counterpart_e_invoicing_credentials.delete_counterparts_id_einvoicing_credentials_id(
+ credential_id="credential_id",
+ counterpart_id="counterpart_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_counterparts_id_einvoicing_credentials_id(
@@ -366,11 +461,24 @@ async def patch_counterparts_id_einvoicing_credentials_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterpart_e_invoicing_credentials.patch_counterparts_id_einvoicing_credentials_id(credential_id='credential_id', counterpart_id='counterpart_id', )
+ await client.counterpart_e_invoicing_credentials.patch_counterparts_id_einvoicing_credentials_id(
+ credential_id="credential_id",
+ counterpart_id="counterpart_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.patch_counterparts_id_einvoicing_credentials_id(
diff --git a/src/monite/counterparts/addresses/client.py b/src/monite/counterparts/addresses/client.py
index 37fdc35..fb0ab97 100644
--- a/src/monite/counterparts/addresses/client.py
+++ b/src/monite/counterparts/addresses/client.py
@@ -47,8 +47,15 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.addresses.get(counterpart_id='counterpart_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.addresses.get(
+ counterpart_id="counterpart_id",
+ )
"""
_response = self._raw_client.get(counterpart_id, request_options=request_options)
return _response.data
@@ -99,8 +106,19 @@ def create(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.addresses.create(counterpart_id='counterpart_id', city='Berlin', country="AF", line1='Flughafenstrasse 52', postal_code='10115', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.addresses.create(
+ counterpart_id="counterpart_id",
+ city="Berlin",
+ country="AF",
+ line1="Flughafenstrasse 52",
+ postal_code="10115",
+ )
"""
_response = self._raw_client.create(
counterpart_id,
@@ -135,8 +153,16 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.addresses.get_by_id(address_id='address_id', counterpart_id='counterpart_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.addresses.get_by_id(
+ address_id="address_id",
+ counterpart_id="counterpart_id",
+ )
"""
_response = self._raw_client.get_by_id(address_id, counterpart_id, request_options=request_options)
return _response.data
@@ -161,8 +187,16 @@ def delete_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.addresses.delete_by_id(address_id='address_id', counterpart_id='counterpart_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.addresses.delete_by_id(
+ address_id="address_id",
+ counterpart_id="counterpart_id",
+ )
"""
_response = self._raw_client.delete_by_id(address_id, counterpart_id, request_options=request_options)
return _response.data
@@ -216,8 +250,16 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.addresses.update_by_id(address_id='address_id', counterpart_id='counterpart_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.addresses.update_by_id(
+ address_id="address_id",
+ counterpart_id="counterpart_id",
+ )
"""
_response = self._raw_client.update_by_id(
address_id,
@@ -266,11 +308,23 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.addresses.get(counterpart_id='counterpart_id', )
+ await client.counterparts.addresses.get(
+ counterpart_id="counterpart_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(counterpart_id, request_options=request_options)
@@ -321,11 +375,27 @@ async def create(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.addresses.create(counterpart_id='counterpart_id', city='Berlin', country="AF", line1='Flughafenstrasse 52', postal_code='10115', )
+ await client.counterparts.addresses.create(
+ counterpart_id="counterpart_id",
+ city="Berlin",
+ country="AF",
+ line1="Flughafenstrasse 52",
+ postal_code="10115",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -360,11 +430,24 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.addresses.get_by_id(address_id='address_id', counterpart_id='counterpart_id', )
+ await client.counterparts.addresses.get_by_id(
+ address_id="address_id",
+ counterpart_id="counterpart_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(address_id, counterpart_id, request_options=request_options)
@@ -389,11 +472,24 @@ async def delete_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.addresses.delete_by_id(address_id='address_id', counterpart_id='counterpart_id', )
+ await client.counterparts.addresses.delete_by_id(
+ address_id="address_id",
+ counterpart_id="counterpart_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(address_id, counterpart_id, request_options=request_options)
@@ -447,11 +543,24 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.addresses.update_by_id(address_id='address_id', counterpart_id='counterpart_id', )
+ await client.counterparts.addresses.update_by_id(
+ address_id="address_id",
+ counterpart_id="counterpart_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
diff --git a/src/monite/counterparts/bank_accounts/client.py b/src/monite/counterparts/bank_accounts/client.py
index ce42db5..bec8308 100644
--- a/src/monite/counterparts/bank_accounts/client.py
+++ b/src/monite/counterparts/bank_accounts/client.py
@@ -48,8 +48,15 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.bank_accounts.get(counterpart_id='counterpart_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.bank_accounts.get(
+ counterpart_id="counterpart_id",
+ )
"""
_response = self._raw_client.get(counterpart_id, request_options=request_options)
return _response.data
@@ -116,8 +123,17 @@ def create(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.bank_accounts.create(counterpart_id='counterpart_id', country="AF", currency="AED", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.bank_accounts.create(
+ counterpart_id="counterpart_id",
+ country="AF",
+ currency="AED",
+ )
"""
_response = self._raw_client.create(
counterpart_id,
@@ -157,8 +173,16 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.bank_accounts.get_by_id(bank_account_id='bank_account_id', counterpart_id='counterpart_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.bank_accounts.get_by_id(
+ bank_account_id="bank_account_id",
+ counterpart_id="counterpart_id",
+ )
"""
_response = self._raw_client.get_by_id(bank_account_id, counterpart_id, request_options=request_options)
return _response.data
@@ -183,8 +207,16 @@ def delete_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.bank_accounts.delete_by_id(bank_account_id='bank_account_id', counterpart_id='counterpart_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.bank_accounts.delete_by_id(
+ bank_account_id="bank_account_id",
+ counterpart_id="counterpart_id",
+ )
"""
_response = self._raw_client.delete_by_id(bank_account_id, counterpart_id, request_options=request_options)
return _response.data
@@ -251,8 +283,16 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.bank_accounts.update_by_id(bank_account_id='bank_account_id', counterpart_id='counterpart_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.bank_accounts.update_by_id(
+ bank_account_id="bank_account_id",
+ counterpart_id="counterpart_id",
+ )
"""
_response = self._raw_client.update_by_id(
bank_account_id,
@@ -292,8 +332,16 @@ def make_default_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.bank_accounts.make_default_by_id(bank_account_id='bank_account_id', counterpart_id='counterpart_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.bank_accounts.make_default_by_id(
+ bank_account_id="bank_account_id",
+ counterpart_id="counterpart_id",
+ )
"""
_response = self._raw_client.make_default_by_id(
bank_account_id, counterpart_id, request_options=request_options
@@ -334,11 +382,23 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.bank_accounts.get(counterpart_id='counterpart_id', )
+ await client.counterparts.bank_accounts.get(
+ counterpart_id="counterpart_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(counterpart_id, request_options=request_options)
@@ -405,11 +465,25 @@ async def create(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.bank_accounts.create(counterpart_id='counterpart_id', country="AF", currency="AED", )
+ await client.counterparts.bank_accounts.create(
+ counterpart_id="counterpart_id",
+ country="AF",
+ currency="AED",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -449,11 +523,24 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.bank_accounts.get_by_id(bank_account_id='bank_account_id', counterpart_id='counterpart_id', )
+ await client.counterparts.bank_accounts.get_by_id(
+ bank_account_id="bank_account_id",
+ counterpart_id="counterpart_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(bank_account_id, counterpart_id, request_options=request_options)
@@ -478,11 +565,24 @@ async def delete_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.bank_accounts.delete_by_id(bank_account_id='bank_account_id', counterpart_id='counterpart_id', )
+ await client.counterparts.bank_accounts.delete_by_id(
+ bank_account_id="bank_account_id",
+ counterpart_id="counterpart_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(
@@ -551,11 +651,24 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.bank_accounts.update_by_id(bank_account_id='bank_account_id', counterpart_id='counterpart_id', )
+ await client.counterparts.bank_accounts.update_by_id(
+ bank_account_id="bank_account_id",
+ counterpart_id="counterpart_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
@@ -595,11 +708,24 @@ async def make_default_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.bank_accounts.make_default_by_id(bank_account_id='bank_account_id', counterpart_id='counterpart_id', )
+ await client.counterparts.bank_accounts.make_default_by_id(
+ bank_account_id="bank_account_id",
+ counterpart_id="counterpart_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.make_default_by_id(
diff --git a/src/monite/counterparts/bank_accounts/raw_client.py b/src/monite/counterparts/bank_accounts/raw_client.py
index 4da0df4..2a6a9fa 100644
--- a/src/monite/counterparts/bank_accounts/raw_client.py
+++ b/src/monite/counterparts/bank_accounts/raw_client.py
@@ -498,6 +498,8 @@ def make_default_by_id(
request_options=request_options,
)
try:
+ if _response is None or not _response.text.strip():
+ return HttpResponse(response=_response, data=None)
if 200 <= _response.status_code < 300:
_data = typing.cast(
typing.Optional[typing.Any],
@@ -1012,6 +1014,8 @@ async def make_default_by_id(
request_options=request_options,
)
try:
+ if _response is None or not _response.text.strip():
+ return AsyncHttpResponse(response=_response, data=None)
if 200 <= _response.status_code < 300:
_data = typing.cast(
typing.Optional[typing.Any],
diff --git a/src/monite/counterparts/client.py b/src/monite/counterparts/client.py
index 9cfaaae..ade2ba9 100644
--- a/src/monite/counterparts/client.py
+++ b/src/monite/counterparts/client.py
@@ -169,8 +169,15 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.get(sort_code='123456', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.get(
+ sort_code="123456",
+ )
"""
_response = self._raw_client.get(
iban=iban,
@@ -226,12 +233,33 @@ def create(
Examples
--------
- from monite import Monite
- from monite import CounterpartCreatePayload_Organization
- from monite import CounterpartOrganizationCreatePayload
- from monite import CounterpartAddress
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.create(request=CounterpartCreatePayload_Organization(organization=CounterpartOrganizationCreatePayload(address=CounterpartAddress(city='Berlin', country="AF", line1='Flughafenstrasse 52', postal_code='10115', ), is_customer=True, is_vendor=True, legal_name='Acme Inc.', ), ), )
+ from monite import (
+ CounterpartAddress,
+ CounterpartCreatePayload_Organization,
+ CounterpartOrganizationCreatePayload,
+ Monite,
+ )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.create(
+ request=CounterpartCreatePayload_Organization(
+ organization=CounterpartOrganizationCreatePayload(
+ address=CounterpartAddress(
+ city="Berlin",
+ country="AF",
+ line1="Flughafenstrasse 52",
+ postal_code="10115",
+ ),
+ is_customer=True,
+ is_vendor=True,
+ legal_name="Acme Inc.",
+ ),
+ ),
+ )
"""
_response = self._raw_client.create(request=request, request_options=request_options)
return _response.data
@@ -255,8 +283,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.get_by_id(counterpart_id='counterpart_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.get_by_id(
+ counterpart_id="counterpart_id",
+ )
"""
_response = self._raw_client.get_by_id(counterpart_id, request_options=request_options)
return _response.data
@@ -277,8 +312,15 @@ def delete_by_id(self, counterpart_id: str, *, request_options: typing.Optional[
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.delete_by_id(counterpart_id='counterpart_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.delete_by_id(
+ counterpart_id="counterpart_id",
+ )
"""
_response = self._raw_client.delete_by_id(counterpart_id, request_options=request_options)
return _response.data
@@ -307,11 +349,23 @@ def update_by_id(
Examples
--------
- from monite import Monite
- from monite import CounterpartIndividualRootUpdatePayload
- from monite import CounterpartIndividualUpdatePayload
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.update_by_id(counterpart_id='counterpart_id', request=CounterpartIndividualRootUpdatePayload(individual=CounterpartIndividualUpdatePayload(), ), )
+ from monite import (
+ CounterpartIndividualRootUpdatePayload,
+ CounterpartIndividualUpdatePayload,
+ Monite,
+ )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.update_by_id(
+ counterpart_id="counterpart_id",
+ request=CounterpartIndividualRootUpdatePayload(
+ individual=CounterpartIndividualUpdatePayload(),
+ ),
+ )
"""
_response = self._raw_client.update_by_id(counterpart_id, request=request, request_options=request_options)
return _response.data
@@ -335,8 +389,15 @@ def get_partner_metadata_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.get_partner_metadata_by_id(counterpart_id='counterpart_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.get_partner_metadata_by_id(
+ counterpart_id="counterpart_id",
+ )
"""
_response = self._raw_client.get_partner_metadata_by_id(counterpart_id, request_options=request_options)
return _response.data
@@ -367,9 +428,16 @@ def update_partner_metadata_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.update_partner_metadata_by_id(counterpart_id='counterpart_id', metadata={'key': 'value'
- }, )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.update_partner_metadata_by_id(
+ counterpart_id="counterpart_id",
+ metadata={"key": "value"},
+ )
"""
_response = self._raw_client.update_partner_metadata_by_id(
counterpart_id, metadata=metadata, request_options=request_options
@@ -522,11 +590,23 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.get(sort_code='123456', )
+ await client.counterparts.get(
+ sort_code="123456",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
@@ -583,14 +663,40 @@ async def create(
Examples
--------
- from monite import AsyncMonite
- from monite import CounterpartCreatePayload_Organization
- from monite import CounterpartOrganizationCreatePayload
- from monite import CounterpartAddress
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import (
+ AsyncMonite,
+ CounterpartAddress,
+ CounterpartCreatePayload_Organization,
+ CounterpartOrganizationCreatePayload,
+ )
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.create(request=CounterpartCreatePayload_Organization(organization=CounterpartOrganizationCreatePayload(address=CounterpartAddress(city='Berlin', country="AF", line1='Flughafenstrasse 52', postal_code='10115', ), is_customer=True, is_vendor=True, legal_name='Acme Inc.', ), ), )
+ await client.counterparts.create(
+ request=CounterpartCreatePayload_Organization(
+ organization=CounterpartOrganizationCreatePayload(
+ address=CounterpartAddress(
+ city="Berlin",
+ country="AF",
+ line1="Flughafenstrasse 52",
+ postal_code="10115",
+ ),
+ is_customer=True,
+ is_vendor=True,
+ legal_name="Acme Inc.",
+ ),
+ ),
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(request=request, request_options=request_options)
@@ -614,11 +720,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.get_by_id(counterpart_id='counterpart_id', )
+ await client.counterparts.get_by_id(
+ counterpart_id="counterpart_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(counterpart_id, request_options=request_options)
@@ -641,11 +759,23 @@ async def delete_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.delete_by_id(counterpart_id='counterpart_id', )
+ await client.counterparts.delete_by_id(
+ counterpart_id="counterpart_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(counterpart_id, request_options=request_options)
@@ -675,13 +805,30 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
- from monite import CounterpartIndividualRootUpdatePayload
- from monite import CounterpartIndividualUpdatePayload
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import (
+ AsyncMonite,
+ CounterpartIndividualRootUpdatePayload,
+ CounterpartIndividualUpdatePayload,
+ )
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.update_by_id(counterpart_id='counterpart_id', request=CounterpartIndividualRootUpdatePayload(individual=CounterpartIndividualUpdatePayload(), ), )
+ await client.counterparts.update_by_id(
+ counterpart_id="counterpart_id",
+ request=CounterpartIndividualRootUpdatePayload(
+ individual=CounterpartIndividualUpdatePayload(),
+ ),
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
@@ -707,11 +854,23 @@ async def get_partner_metadata_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.get_partner_metadata_by_id(counterpart_id='counterpart_id', )
+ await client.counterparts.get_partner_metadata_by_id(
+ counterpart_id="counterpart_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_partner_metadata_by_id(counterpart_id, request_options=request_options)
@@ -742,12 +901,24 @@ async def update_partner_metadata_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.update_partner_metadata_by_id(counterpart_id='counterpart_id', metadata={'key': 'value'
- }, )
+ await client.counterparts.update_partner_metadata_by_id(
+ counterpart_id="counterpart_id",
+ metadata={"key": "value"},
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_partner_metadata_by_id(
diff --git a/src/monite/counterparts/contacts/client.py b/src/monite/counterparts/contacts/client.py
index c806ad7..973f6cb 100644
--- a/src/monite/counterparts/contacts/client.py
+++ b/src/monite/counterparts/contacts/client.py
@@ -47,8 +47,15 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.contacts.get(counterpart_id='counterpart_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.contacts.get(
+ counterpart_id="counterpart_id",
+ )
"""
_response = self._raw_client.get(counterpart_id, request_options=request_options)
return _response.data
@@ -98,10 +105,24 @@ def create(
Examples
--------
- from monite import Monite
- from monite import CounterpartAddress
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.contacts.create(counterpart_id='counterpart_id', address=CounterpartAddress(city='Berlin', country="AF", line1='Flughafenstrasse 52', postal_code='10115', ), first_name='Mary', last_name="O'Brien", )
+ from monite import CounterpartAddress, Monite
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.contacts.create(
+ counterpart_id="counterpart_id",
+ address=CounterpartAddress(
+ city="Berlin",
+ country="AF",
+ line1="Flughafenstrasse 52",
+ postal_code="10115",
+ ),
+ first_name="Mary",
+ last_name="O'Brien",
+ )
"""
_response = self._raw_client.create(
counterpart_id,
@@ -136,8 +157,16 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.contacts.get_by_id(contact_id='contact_id', counterpart_id='counterpart_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.contacts.get_by_id(
+ contact_id="contact_id",
+ counterpart_id="counterpart_id",
+ )
"""
_response = self._raw_client.get_by_id(contact_id, counterpart_id, request_options=request_options)
return _response.data
@@ -162,8 +191,16 @@ def delete_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.contacts.delete_by_id(contact_id='contact_id', counterpart_id='counterpart_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.contacts.delete_by_id(
+ contact_id="contact_id",
+ counterpart_id="counterpart_id",
+ )
"""
_response = self._raw_client.delete_by_id(contact_id, counterpart_id, request_options=request_options)
return _response.data
@@ -217,8 +254,16 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.contacts.update_by_id(contact_id='contact_id', counterpart_id='counterpart_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.contacts.update_by_id(
+ contact_id="contact_id",
+ counterpart_id="counterpart_id",
+ )
"""
_response = self._raw_client.update_by_id(
contact_id,
@@ -254,8 +299,16 @@ def make_default_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.contacts.make_default_by_id(contact_id='contact_id', counterpart_id='counterpart_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.contacts.make_default_by_id(
+ contact_id="contact_id",
+ counterpart_id="counterpart_id",
+ )
"""
_response = self._raw_client.make_default_by_id(contact_id, counterpart_id, request_options=request_options)
return _response.data
@@ -294,11 +347,23 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.contacts.get(counterpart_id='counterpart_id', )
+ await client.counterparts.contacts.get(
+ counterpart_id="counterpart_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(counterpart_id, request_options=request_options)
@@ -349,12 +414,31 @@ async def create(
Examples
--------
- from monite import AsyncMonite
- from monite import CounterpartAddress
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite, CounterpartAddress
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.contacts.create(counterpart_id='counterpart_id', address=CounterpartAddress(city='Berlin', country="AF", line1='Flughafenstrasse 52', postal_code='10115', ), first_name='Mary', last_name="O'Brien", )
+ await client.counterparts.contacts.create(
+ counterpart_id="counterpart_id",
+ address=CounterpartAddress(
+ city="Berlin",
+ country="AF",
+ line1="Flughafenstrasse 52",
+ postal_code="10115",
+ ),
+ first_name="Mary",
+ last_name="O'Brien",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -389,11 +473,24 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.contacts.get_by_id(contact_id='contact_id', counterpart_id='counterpart_id', )
+ await client.counterparts.contacts.get_by_id(
+ contact_id="contact_id",
+ counterpart_id="counterpart_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(contact_id, counterpart_id, request_options=request_options)
@@ -418,11 +515,24 @@ async def delete_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.contacts.delete_by_id(contact_id='contact_id', counterpart_id='counterpart_id', )
+ await client.counterparts.contacts.delete_by_id(
+ contact_id="contact_id",
+ counterpart_id="counterpart_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(contact_id, counterpart_id, request_options=request_options)
@@ -476,11 +586,24 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.contacts.update_by_id(contact_id='contact_id', counterpart_id='counterpart_id', )
+ await client.counterparts.contacts.update_by_id(
+ contact_id="contact_id",
+ counterpart_id="counterpart_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
@@ -516,11 +639,24 @@ async def make_default_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.contacts.make_default_by_id(contact_id='contact_id', counterpart_id='counterpart_id', )
+ await client.counterparts.contacts.make_default_by_id(
+ contact_id="contact_id",
+ counterpart_id="counterpart_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.make_default_by_id(
diff --git a/src/monite/counterparts/vat_ids/client.py b/src/monite/counterparts/vat_ids/client.py
index 3c53ed3..165cbd6 100644
--- a/src/monite/counterparts/vat_ids/client.py
+++ b/src/monite/counterparts/vat_ids/client.py
@@ -48,8 +48,15 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.vat_ids.get(counterpart_id='counterpart_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.vat_ids.get(
+ counterpart_id="counterpart_id",
+ )
"""
_response = self._raw_client.get(counterpart_id, request_options=request_options)
return _response.data
@@ -85,8 +92,16 @@ def create(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.vat_ids.create(counterpart_id='counterpart_id', value='123456789', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.vat_ids.create(
+ counterpart_id="counterpart_id",
+ value="123456789",
+ )
"""
_response = self._raw_client.create(
counterpart_id, value=value, country=country, type=type, request_options=request_options
@@ -114,8 +129,16 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.vat_ids.get_by_id(vat_id='vat_id', counterpart_id='counterpart_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.vat_ids.get_by_id(
+ vat_id="vat_id",
+ counterpart_id="counterpart_id",
+ )
"""
_response = self._raw_client.get_by_id(vat_id, counterpart_id, request_options=request_options)
return _response.data
@@ -140,8 +163,16 @@ def delete_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.vat_ids.delete_by_id(vat_id='vat_id', counterpart_id='counterpart_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.vat_ids.delete_by_id(
+ vat_id="vat_id",
+ counterpart_id="counterpart_id",
+ )
"""
_response = self._raw_client.delete_by_id(vat_id, counterpart_id, request_options=request_options)
return _response.data
@@ -180,8 +211,16 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.counterparts.vat_ids.update_by_id(vat_id='vat_id', counterpart_id='counterpart_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.counterparts.vat_ids.update_by_id(
+ vat_id="vat_id",
+ counterpart_id="counterpart_id",
+ )
"""
_response = self._raw_client.update_by_id(
vat_id, counterpart_id, country=country, type=type, value=value, request_options=request_options
@@ -222,11 +261,23 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.vat_ids.get(counterpart_id='counterpart_id', )
+ await client.counterparts.vat_ids.get(
+ counterpart_id="counterpart_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(counterpart_id, request_options=request_options)
@@ -262,11 +313,24 @@ async def create(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.vat_ids.create(counterpart_id='counterpart_id', value='123456789', )
+ await client.counterparts.vat_ids.create(
+ counterpart_id="counterpart_id",
+ value="123456789",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -294,11 +358,24 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.vat_ids.get_by_id(vat_id='vat_id', counterpart_id='counterpart_id', )
+ await client.counterparts.vat_ids.get_by_id(
+ vat_id="vat_id",
+ counterpart_id="counterpart_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(vat_id, counterpart_id, request_options=request_options)
@@ -323,11 +400,24 @@ async def delete_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.vat_ids.delete_by_id(vat_id='vat_id', counterpart_id='counterpart_id', )
+ await client.counterparts.vat_ids.delete_by_id(
+ vat_id="vat_id",
+ counterpart_id="counterpart_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(vat_id, counterpart_id, request_options=request_options)
@@ -366,11 +456,24 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.counterparts.vat_ids.update_by_id(vat_id='vat_id', counterpart_id='counterpart_id', )
+ await client.counterparts.vat_ids.update_by_id(
+ vat_id="vat_id",
+ counterpart_id="counterpart_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
diff --git a/src/monite/credit_notes/client.py b/src/monite/credit_notes/client.py
index 13a2234..7969b52 100644
--- a/src/monite/credit_notes/client.py
+++ b/src/monite/credit_notes/client.py
@@ -178,7 +178,12 @@ def get_payable_credit_notes(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.credit_notes.get_payable_credit_notes()
"""
_response = self._raw_client.get_payable_credit_notes(
@@ -309,8 +314,16 @@ def post_payable_credit_notes(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.credit_notes.post_payable_credit_notes(document_id='CN-2287', issued_at='2024-01-15', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.credit_notes.post_payable_credit_notes(
+ document_id="CN-2287",
+ issued_at="2024-01-15",
+ )
"""
_response = self._raw_client.post_payable_credit_notes(
document_id=document_id,
@@ -338,7 +351,7 @@ def post_payable_credit_notes_upload_from_file(
self, *, file: core.File, request_options: typing.Optional[RequestOptions] = None
) -> CreditNoteResponse:
"""
- Upload an incoming credit note (payable) in PDF, PNG, JPEG, or TIFF format and scan its contents. The maximum file size is 10MB.
+ Upload an incoming credit note (payable) in PDF, PNG, or JPEG format and scan its contents. The maximum file size is 20MB.
Parameters
----------
@@ -356,7 +369,12 @@ def post_payable_credit_notes_upload_from_file(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.credit_notes.post_payable_credit_notes_upload_from_file()
"""
_response = self._raw_client.post_payable_credit_notes_upload_from_file(
@@ -383,7 +401,12 @@ def get_payable_credit_notes_validations(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.credit_notes.get_payable_credit_notes_validations()
"""
_response = self._raw_client.get_payable_credit_notes_validations(request_options=request_options)
@@ -413,8 +436,15 @@ def put_payable_credit_notes_validations(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.credit_notes.put_payable_credit_notes_validations(required_fields=["currency"], )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.credit_notes.put_payable_credit_notes_validations(
+ required_fields=["currency"],
+ )
"""
_response = self._raw_client.put_payable_credit_notes_validations(
required_fields=required_fields, request_options=request_options
@@ -440,7 +470,12 @@ def post_payable_credit_notes_validations_reset(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.credit_notes.post_payable_credit_notes_validations_reset()
"""
_response = self._raw_client.post_payable_credit_notes_validations_reset(request_options=request_options)
@@ -465,8 +500,15 @@ def get_payable_credit_notes_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.credit_notes.get_payable_credit_notes_id(credit_note_id='credit_note_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.credit_notes.get_payable_credit_notes_id(
+ credit_note_id="credit_note_id",
+ )
"""
_response = self._raw_client.get_payable_credit_notes_id(credit_note_id, request_options=request_options)
return _response.data
@@ -489,8 +531,15 @@ def delete_payable_credit_notes_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.credit_notes.delete_payable_credit_notes_id(credit_note_id='credit_note_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.credit_notes.delete_payable_credit_notes_id(
+ credit_note_id="credit_note_id",
+ )
"""
_response = self._raw_client.delete_payable_credit_notes_id(credit_note_id, request_options=request_options)
return _response.data
@@ -585,8 +634,15 @@ def patch_payable_credit_notes_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.credit_notes.patch_payable_credit_notes_id(credit_note_id='credit_note_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.credit_notes.patch_payable_credit_notes_id(
+ credit_note_id="credit_note_id",
+ )
"""
_response = self._raw_client.patch_payable_credit_notes_id(
credit_note_id,
@@ -632,8 +688,15 @@ def post_payable_credit_notes_id_approve(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.credit_notes.post_payable_credit_notes_id_approve(credit_note_id='credit_note_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.credit_notes.post_payable_credit_notes_id_approve(
+ credit_note_id="credit_note_id",
+ )
"""
_response = self._raw_client.post_payable_credit_notes_id_approve(
credit_note_id, request_options=request_options
@@ -661,8 +724,15 @@ def post_payable_credit_notes_id_cancel(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.credit_notes.post_payable_credit_notes_id_cancel(credit_note_id='credit_note_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.credit_notes.post_payable_credit_notes_id_cancel(
+ credit_note_id="credit_note_id",
+ )
"""
_response = self._raw_client.post_payable_credit_notes_id_cancel(
credit_note_id, request_options=request_options
@@ -690,8 +760,15 @@ def post_payable_credit_notes_id_cancel_ocr(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.credit_notes.post_payable_credit_notes_id_cancel_ocr(credit_note_id='credit_note_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.credit_notes.post_payable_credit_notes_id_cancel_ocr(
+ credit_note_id="credit_note_id",
+ )
"""
_response = self._raw_client.post_payable_credit_notes_id_cancel_ocr(
credit_note_id, request_options=request_options
@@ -858,8 +935,15 @@ def get_payable_credit_notes_id_line_items(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.credit_notes.get_payable_credit_notes_id_line_items(credit_note_id='credit_note_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.credit_notes.get_payable_credit_notes_id_line_items(
+ credit_note_id="credit_note_id",
+ )
"""
_response = self._raw_client.get_payable_credit_notes_id_line_items(
credit_note_id,
@@ -957,8 +1041,15 @@ def post_payable_credit_notes_id_line_items(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.credit_notes.post_payable_credit_notes_id_line_items(credit_note_id='credit_note_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.credit_notes.post_payable_credit_notes_id_line_items(
+ credit_note_id="credit_note_id",
+ )
"""
_response = self._raw_client.post_payable_credit_notes_id_line_items(
credit_note_id,
@@ -997,10 +1088,17 @@ def put_payable_credit_notes_id_line_items(
Examples
--------
- from monite import Monite
- from monite import CreditNoteLineItemCreateRequest
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.credit_notes.put_payable_credit_notes_id_line_items(credit_note_id='credit_note_id', data=[CreditNoteLineItemCreateRequest()], )
+ from monite import CreditNoteLineItemCreateRequest, Monite
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.credit_notes.put_payable_credit_notes_id_line_items(
+ credit_note_id="credit_note_id",
+ data=[CreditNoteLineItemCreateRequest()],
+ )
"""
_response = self._raw_client.put_payable_credit_notes_id_line_items(
credit_note_id, data=data, request_options=request_options
@@ -1028,8 +1126,16 @@ def get_payable_credit_notes_id_line_items_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.credit_notes.get_payable_credit_notes_id_line_items_id(credit_note_id='credit_note_id', line_item_id='line_item_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.credit_notes.get_payable_credit_notes_id_line_items_id(
+ credit_note_id="credit_note_id",
+ line_item_id="line_item_id",
+ )
"""
_response = self._raw_client.get_payable_credit_notes_id_line_items_id(
credit_note_id, line_item_id, request_options=request_options
@@ -1057,8 +1163,16 @@ def delete_payable_credit_notes_id_line_items_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.credit_notes.delete_payable_credit_notes_id_line_items_id(credit_note_id='credit_note_id', line_item_id='line_item_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.credit_notes.delete_payable_credit_notes_id_line_items_id(
+ credit_note_id="credit_note_id",
+ line_item_id="line_item_id",
+ )
"""
_response = self._raw_client.delete_payable_credit_notes_id_line_items_id(
credit_note_id, line_item_id, request_options=request_options
@@ -1114,8 +1228,16 @@ def patch_payable_credit_notes_id_line_items_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.credit_notes.patch_payable_credit_notes_id_line_items_id(credit_note_id='credit_note_id', line_item_id='line_item_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.credit_notes.patch_payable_credit_notes_id_line_items_id(
+ credit_note_id="credit_note_id",
+ line_item_id="line_item_id",
+ )
"""
_response = self._raw_client.patch_payable_credit_notes_id_line_items_id(
credit_note_id,
@@ -1151,8 +1273,15 @@ def post_payable_credit_notes_id_reject(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.credit_notes.post_payable_credit_notes_id_reject(credit_note_id='credit_note_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.credit_notes.post_payable_credit_notes_id_reject(
+ credit_note_id="credit_note_id",
+ )
"""
_response = self._raw_client.post_payable_credit_notes_id_reject(
credit_note_id, request_options=request_options
@@ -1180,8 +1309,15 @@ def post_payable_credit_notes_id_submit_for_approval(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.credit_notes.post_payable_credit_notes_id_submit_for_approval(credit_note_id='credit_note_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.credit_notes.post_payable_credit_notes_id_submit_for_approval(
+ credit_note_id="credit_note_id",
+ )
"""
_response = self._raw_client.post_payable_credit_notes_id_submit_for_approval(
credit_note_id, request_options=request_options
@@ -1207,8 +1343,15 @@ def get_payable_credit_notes_id_validate(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.credit_notes.get_payable_credit_notes_id_validate(credit_note_id='credit_note_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.credit_notes.get_payable_credit_notes_id_validate(
+ credit_note_id="credit_note_id",
+ )
"""
_response = self._raw_client.get_payable_credit_notes_id_validate(
credit_note_id, request_options=request_options
@@ -1367,11 +1510,21 @@ async def get_payable_credit_notes(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.credit_notes.get_payable_credit_notes()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_payable_credit_notes(
@@ -1501,11 +1654,24 @@ async def post_payable_credit_notes(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.credit_notes.post_payable_credit_notes(document_id='CN-2287', issued_at='2024-01-15', )
+ await client.credit_notes.post_payable_credit_notes(
+ document_id="CN-2287",
+ issued_at="2024-01-15",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.post_payable_credit_notes(
@@ -1534,7 +1700,7 @@ async def post_payable_credit_notes_upload_from_file(
self, *, file: core.File, request_options: typing.Optional[RequestOptions] = None
) -> CreditNoteResponse:
"""
- Upload an incoming credit note (payable) in PDF, PNG, JPEG, or TIFF format and scan its contents. The maximum file size is 10MB.
+ Upload an incoming credit note (payable) in PDF, PNG, or JPEG format and scan its contents. The maximum file size is 20MB.
Parameters
----------
@@ -1551,11 +1717,21 @@ async def post_payable_credit_notes_upload_from_file(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.credit_notes.post_payable_credit_notes_upload_from_file()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.post_payable_credit_notes_upload_from_file(
@@ -1581,11 +1757,21 @@ async def get_payable_credit_notes_validations(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.credit_notes.get_payable_credit_notes_validations()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_payable_credit_notes_validations(request_options=request_options)
@@ -1614,11 +1800,23 @@ async def put_payable_credit_notes_validations(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.credit_notes.put_payable_credit_notes_validations(required_fields=["currency"], )
+ await client.credit_notes.put_payable_credit_notes_validations(
+ required_fields=["currency"],
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.put_payable_credit_notes_validations(
@@ -1644,11 +1842,21 @@ async def post_payable_credit_notes_validations_reset(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.credit_notes.post_payable_credit_notes_validations_reset()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.post_payable_credit_notes_validations_reset(request_options=request_options)
@@ -1672,11 +1880,23 @@ async def get_payable_credit_notes_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.credit_notes.get_payable_credit_notes_id(credit_note_id='credit_note_id', )
+ await client.credit_notes.get_payable_credit_notes_id(
+ credit_note_id="credit_note_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_payable_credit_notes_id(credit_note_id, request_options=request_options)
@@ -1699,11 +1919,23 @@ async def delete_payable_credit_notes_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.credit_notes.delete_payable_credit_notes_id(credit_note_id='credit_note_id', )
+ await client.credit_notes.delete_payable_credit_notes_id(
+ credit_note_id="credit_note_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_payable_credit_notes_id(
@@ -1800,11 +2032,23 @@ async def patch_payable_credit_notes_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.credit_notes.patch_payable_credit_notes_id(credit_note_id='credit_note_id', )
+ await client.credit_notes.patch_payable_credit_notes_id(
+ credit_note_id="credit_note_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.patch_payable_credit_notes_id(
@@ -1850,11 +2094,23 @@ async def post_payable_credit_notes_id_approve(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.credit_notes.post_payable_credit_notes_id_approve(credit_note_id='credit_note_id', )
+ await client.credit_notes.post_payable_credit_notes_id_approve(
+ credit_note_id="credit_note_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.post_payable_credit_notes_id_approve(
@@ -1882,11 +2138,23 @@ async def post_payable_credit_notes_id_cancel(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.credit_notes.post_payable_credit_notes_id_cancel(credit_note_id='credit_note_id', )
+ await client.credit_notes.post_payable_credit_notes_id_cancel(
+ credit_note_id="credit_note_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.post_payable_credit_notes_id_cancel(
@@ -1914,11 +2182,23 @@ async def post_payable_credit_notes_id_cancel_ocr(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.credit_notes.post_payable_credit_notes_id_cancel_ocr(credit_note_id='credit_note_id', )
+ await client.credit_notes.post_payable_credit_notes_id_cancel_ocr(
+ credit_note_id="credit_note_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.post_payable_credit_notes_id_cancel_ocr(
@@ -2085,11 +2365,23 @@ async def get_payable_credit_notes_id_line_items(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.credit_notes.get_payable_credit_notes_id_line_items(credit_note_id='credit_note_id', )
+ await client.credit_notes.get_payable_credit_notes_id_line_items(
+ credit_note_id="credit_note_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_payable_credit_notes_id_line_items(
@@ -2187,11 +2479,23 @@ async def post_payable_credit_notes_id_line_items(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.credit_notes.post_payable_credit_notes_id_line_items(credit_note_id='credit_note_id', )
+ await client.credit_notes.post_payable_credit_notes_id_line_items(
+ credit_note_id="credit_note_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.post_payable_credit_notes_id_line_items(
@@ -2231,12 +2535,24 @@ async def put_payable_credit_notes_id_line_items(
Examples
--------
- from monite import AsyncMonite
- from monite import CreditNoteLineItemCreateRequest
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite, CreditNoteLineItemCreateRequest
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.credit_notes.put_payable_credit_notes_id_line_items(credit_note_id='credit_note_id', data=[CreditNoteLineItemCreateRequest()], )
+ await client.credit_notes.put_payable_credit_notes_id_line_items(
+ credit_note_id="credit_note_id",
+ data=[CreditNoteLineItemCreateRequest()],
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.put_payable_credit_notes_id_line_items(
@@ -2264,11 +2580,24 @@ async def get_payable_credit_notes_id_line_items_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.credit_notes.get_payable_credit_notes_id_line_items_id(credit_note_id='credit_note_id', line_item_id='line_item_id', )
+ await client.credit_notes.get_payable_credit_notes_id_line_items_id(
+ credit_note_id="credit_note_id",
+ line_item_id="line_item_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_payable_credit_notes_id_line_items_id(
@@ -2296,11 +2625,24 @@ async def delete_payable_credit_notes_id_line_items_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.credit_notes.delete_payable_credit_notes_id_line_items_id(credit_note_id='credit_note_id', line_item_id='line_item_id', )
+ await client.credit_notes.delete_payable_credit_notes_id_line_items_id(
+ credit_note_id="credit_note_id",
+ line_item_id="line_item_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_payable_credit_notes_id_line_items_id(
@@ -2356,11 +2698,24 @@ async def patch_payable_credit_notes_id_line_items_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.credit_notes.patch_payable_credit_notes_id_line_items_id(credit_note_id='credit_note_id', line_item_id='line_item_id', )
+ await client.credit_notes.patch_payable_credit_notes_id_line_items_id(
+ credit_note_id="credit_note_id",
+ line_item_id="line_item_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.patch_payable_credit_notes_id_line_items_id(
@@ -2396,11 +2751,23 @@ async def post_payable_credit_notes_id_reject(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.credit_notes.post_payable_credit_notes_id_reject(credit_note_id='credit_note_id', )
+ await client.credit_notes.post_payable_credit_notes_id_reject(
+ credit_note_id="credit_note_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.post_payable_credit_notes_id_reject(
@@ -2428,11 +2795,23 @@ async def post_payable_credit_notes_id_submit_for_approval(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.credit_notes.post_payable_credit_notes_id_submit_for_approval(credit_note_id='credit_note_id', )
+ await client.credit_notes.post_payable_credit_notes_id_submit_for_approval(
+ credit_note_id="credit_note_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.post_payable_credit_notes_id_submit_for_approval(
@@ -2458,11 +2837,23 @@ async def get_payable_credit_notes_id_validate(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.credit_notes.get_payable_credit_notes_id_validate(credit_note_id='credit_note_id', )
+ await client.credit_notes.get_payable_credit_notes_id_validate(
+ credit_note_id="credit_note_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_payable_credit_notes_id_validate(
diff --git a/src/monite/credit_notes/raw_client.py b/src/monite/credit_notes/raw_client.py
index 6952f04..8efcd4f 100644
--- a/src/monite/credit_notes/raw_client.py
+++ b/src/monite/credit_notes/raw_client.py
@@ -488,7 +488,7 @@ def post_payable_credit_notes_upload_from_file(
self, *, file: core.File, request_options: typing.Optional[RequestOptions] = None
) -> HttpResponse[CreditNoteResponse]:
"""
- Upload an incoming credit note (payable) in PDF, PNG, JPEG, or TIFF format and scan its contents. The maximum file size is 10MB.
+ Upload an incoming credit note (payable) in PDF, PNG, or JPEG format and scan its contents. The maximum file size is 20MB.
Parameters
----------
@@ -510,11 +510,9 @@ def post_payable_credit_notes_upload_from_file(
files={
"file": file,
},
- headers={
- "content-type": "multipart/form-data",
- },
request_options=request_options,
omit=OMIT,
+ force_multipart=True,
)
try:
if 200 <= _response.status_code < 300:
@@ -3157,7 +3155,7 @@ async def post_payable_credit_notes_upload_from_file(
self, *, file: core.File, request_options: typing.Optional[RequestOptions] = None
) -> AsyncHttpResponse[CreditNoteResponse]:
"""
- Upload an incoming credit note (payable) in PDF, PNG, JPEG, or TIFF format and scan its contents. The maximum file size is 10MB.
+ Upload an incoming credit note (payable) in PDF, PNG, or JPEG format and scan its contents. The maximum file size is 20MB.
Parameters
----------
@@ -3179,11 +3177,9 @@ async def post_payable_credit_notes_upload_from_file(
files={
"file": file,
},
- headers={
- "content-type": "multipart/form-data",
- },
request_options=request_options,
omit=OMIT,
+ force_multipart=True,
)
try:
if 200 <= _response.status_code < 300:
diff --git a/src/monite/custom_vat_rates/__init__.py b/src/monite/custom_vat_rates/__init__.py
new file mode 100644
index 0000000..5cde020
--- /dev/null
+++ b/src/monite/custom_vat_rates/__init__.py
@@ -0,0 +1,4 @@
+# This file was auto-generated by Fern from our API Definition.
+
+# isort: skip_file
+
diff --git a/src/monite/custom_vat_rates/client.py b/src/monite/custom_vat_rates/client.py
new file mode 100644
index 0000000..a2f2ec4
--- /dev/null
+++ b/src/monite/custom_vat_rates/client.py
@@ -0,0 +1,455 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+from ..core.client_wrapper import AsyncClientWrapper, SyncClientWrapper
+from ..core.request_options import RequestOptions
+from ..types.custom_vat_rate_response import CustomVatRateResponse
+from ..types.custom_vat_rate_response_list import CustomVatRateResponseList
+from ..types.vat_rate_component import VatRateComponent
+from .raw_client import AsyncRawCustomVatRatesClient, RawCustomVatRatesClient
+
+# this is used as the default value for optional parameters
+OMIT = typing.cast(typing.Any, ...)
+
+
+class CustomVatRatesClient:
+ def __init__(self, *, client_wrapper: SyncClientWrapper):
+ self._raw_client = RawCustomVatRatesClient(client_wrapper=client_wrapper)
+
+ @property
+ def with_raw_response(self) -> RawCustomVatRatesClient:
+ """
+ Retrieves a raw implementation of this client that returns raw responses.
+
+ Returns
+ -------
+ RawCustomVatRatesClient
+ """
+ return self._raw_client
+
+ def get_custom_vat_rates(
+ self, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> CustomVatRateResponseList:
+ """
+ Parameters
+ ----------
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ CustomVatRateResponseList
+ Successful Response
+
+ Examples
+ --------
+ from monite import Monite
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.custom_vat_rates.get_custom_vat_rates()
+ """
+ _response = self._raw_client.get_custom_vat_rates(request_options=request_options)
+ return _response.data
+
+ def post_custom_vat_rates(
+ self,
+ *,
+ components: typing.Sequence[VatRateComponent],
+ name: str,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> CustomVatRateResponse:
+ """
+ Parameters
+ ----------
+ components : typing.Sequence[VatRateComponent]
+ Sub-taxes included in the Custom VAT.
+
+ name : str
+ Display name of the Custom VAT.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ CustomVatRateResponse
+ Successful Response
+
+ Examples
+ --------
+ from monite import Monite, VatRateComponent
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.custom_vat_rates.post_custom_vat_rates(
+ components=[
+ VatRateComponent(
+ name="name",
+ value=1.1,
+ )
+ ],
+ name="name",
+ )
+ """
+ _response = self._raw_client.post_custom_vat_rates(
+ components=components, name=name, request_options=request_options
+ )
+ return _response.data
+
+ def get_custom_vat_rates_id(
+ self, custom_vat_rate_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> CustomVatRateResponse:
+ """
+ Parameters
+ ----------
+ custom_vat_rate_id : str
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ CustomVatRateResponse
+ Successful Response
+
+ Examples
+ --------
+ from monite import Monite
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.custom_vat_rates.get_custom_vat_rates_id(
+ custom_vat_rate_id="custom_vat_rate_id",
+ )
+ """
+ _response = self._raw_client.get_custom_vat_rates_id(custom_vat_rate_id, request_options=request_options)
+ return _response.data
+
+ def delete_custom_vat_rates_id(
+ self, custom_vat_rate_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> None:
+ """
+ Parameters
+ ----------
+ custom_vat_rate_id : str
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ None
+
+ Examples
+ --------
+ from monite import Monite
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.custom_vat_rates.delete_custom_vat_rates_id(
+ custom_vat_rate_id="custom_vat_rate_id",
+ )
+ """
+ _response = self._raw_client.delete_custom_vat_rates_id(custom_vat_rate_id, request_options=request_options)
+ return _response.data
+
+ def patch_custom_vat_rates_id(
+ self,
+ custom_vat_rate_id: str,
+ *,
+ components: typing.Optional[typing.Sequence[VatRateComponent]] = OMIT,
+ name: typing.Optional[str] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> CustomVatRateResponse:
+ """
+ Parameters
+ ----------
+ custom_vat_rate_id : str
+
+ components : typing.Optional[typing.Sequence[VatRateComponent]]
+ Sub-taxes included in the Custom VAT.
+
+ name : typing.Optional[str]
+ Display name of the Custom VAT.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ CustomVatRateResponse
+ Successful Response
+
+ Examples
+ --------
+ from monite import Monite
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.custom_vat_rates.patch_custom_vat_rates_id(
+ custom_vat_rate_id="custom_vat_rate_id",
+ )
+ """
+ _response = self._raw_client.patch_custom_vat_rates_id(
+ custom_vat_rate_id, components=components, name=name, request_options=request_options
+ )
+ return _response.data
+
+
+class AsyncCustomVatRatesClient:
+ def __init__(self, *, client_wrapper: AsyncClientWrapper):
+ self._raw_client = AsyncRawCustomVatRatesClient(client_wrapper=client_wrapper)
+
+ @property
+ def with_raw_response(self) -> AsyncRawCustomVatRatesClient:
+ """
+ Retrieves a raw implementation of this client that returns raw responses.
+
+ Returns
+ -------
+ AsyncRawCustomVatRatesClient
+ """
+ return self._raw_client
+
+ async def get_custom_vat_rates(
+ self, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> CustomVatRateResponseList:
+ """
+ Parameters
+ ----------
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ CustomVatRateResponseList
+ Successful Response
+
+ Examples
+ --------
+ import asyncio
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
+ async def main() -> None:
+ await client.custom_vat_rates.get_custom_vat_rates()
+
+
+ asyncio.run(main())
+ """
+ _response = await self._raw_client.get_custom_vat_rates(request_options=request_options)
+ return _response.data
+
+ async def post_custom_vat_rates(
+ self,
+ *,
+ components: typing.Sequence[VatRateComponent],
+ name: str,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> CustomVatRateResponse:
+ """
+ Parameters
+ ----------
+ components : typing.Sequence[VatRateComponent]
+ Sub-taxes included in the Custom VAT.
+
+ name : str
+ Display name of the Custom VAT.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ CustomVatRateResponse
+ Successful Response
+
+ Examples
+ --------
+ import asyncio
+
+ from monite import AsyncMonite, VatRateComponent
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
+ async def main() -> None:
+ await client.custom_vat_rates.post_custom_vat_rates(
+ components=[
+ VatRateComponent(
+ name="name",
+ value=1.1,
+ )
+ ],
+ name="name",
+ )
+
+
+ asyncio.run(main())
+ """
+ _response = await self._raw_client.post_custom_vat_rates(
+ components=components, name=name, request_options=request_options
+ )
+ return _response.data
+
+ async def get_custom_vat_rates_id(
+ self, custom_vat_rate_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> CustomVatRateResponse:
+ """
+ Parameters
+ ----------
+ custom_vat_rate_id : str
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ CustomVatRateResponse
+ Successful Response
+
+ Examples
+ --------
+ import asyncio
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
+ async def main() -> None:
+ await client.custom_vat_rates.get_custom_vat_rates_id(
+ custom_vat_rate_id="custom_vat_rate_id",
+ )
+
+
+ asyncio.run(main())
+ """
+ _response = await self._raw_client.get_custom_vat_rates_id(custom_vat_rate_id, request_options=request_options)
+ return _response.data
+
+ async def delete_custom_vat_rates_id(
+ self, custom_vat_rate_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> None:
+ """
+ Parameters
+ ----------
+ custom_vat_rate_id : str
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ None
+
+ Examples
+ --------
+ import asyncio
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
+ async def main() -> None:
+ await client.custom_vat_rates.delete_custom_vat_rates_id(
+ custom_vat_rate_id="custom_vat_rate_id",
+ )
+
+
+ asyncio.run(main())
+ """
+ _response = await self._raw_client.delete_custom_vat_rates_id(
+ custom_vat_rate_id, request_options=request_options
+ )
+ return _response.data
+
+ async def patch_custom_vat_rates_id(
+ self,
+ custom_vat_rate_id: str,
+ *,
+ components: typing.Optional[typing.Sequence[VatRateComponent]] = OMIT,
+ name: typing.Optional[str] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> CustomVatRateResponse:
+ """
+ Parameters
+ ----------
+ custom_vat_rate_id : str
+
+ components : typing.Optional[typing.Sequence[VatRateComponent]]
+ Sub-taxes included in the Custom VAT.
+
+ name : typing.Optional[str]
+ Display name of the Custom VAT.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ CustomVatRateResponse
+ Successful Response
+
+ Examples
+ --------
+ import asyncio
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
+ async def main() -> None:
+ await client.custom_vat_rates.patch_custom_vat_rates_id(
+ custom_vat_rate_id="custom_vat_rate_id",
+ )
+
+
+ asyncio.run(main())
+ """
+ _response = await self._raw_client.patch_custom_vat_rates_id(
+ custom_vat_rate_id, components=components, name=name, request_options=request_options
+ )
+ return _response.data
diff --git a/src/monite/custom_vat_rates/raw_client.py b/src/monite/custom_vat_rates/raw_client.py
new file mode 100644
index 0000000..3fdfeb5
--- /dev/null
+++ b/src/monite/custom_vat_rates/raw_client.py
@@ -0,0 +1,1068 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+from json.decoder import JSONDecodeError
+
+from ..core.api_error import ApiError
+from ..core.client_wrapper import AsyncClientWrapper, SyncClientWrapper
+from ..core.http_response import AsyncHttpResponse, HttpResponse
+from ..core.jsonable_encoder import jsonable_encoder
+from ..core.pydantic_utilities import parse_obj_as
+from ..core.request_options import RequestOptions
+from ..core.serialization import convert_and_respect_annotation_metadata
+from ..errors.bad_request_error import BadRequestError
+from ..errors.forbidden_error import ForbiddenError
+from ..errors.internal_server_error import InternalServerError
+from ..errors.not_found_error import NotFoundError
+from ..errors.unauthorized_error import UnauthorizedError
+from ..errors.unprocessable_entity_error import UnprocessableEntityError
+from ..types.custom_vat_rate_response import CustomVatRateResponse
+from ..types.custom_vat_rate_response_list import CustomVatRateResponseList
+from ..types.vat_rate_component import VatRateComponent
+
+# this is used as the default value for optional parameters
+OMIT = typing.cast(typing.Any, ...)
+
+
+class RawCustomVatRatesClient:
+ def __init__(self, *, client_wrapper: SyncClientWrapper):
+ self._client_wrapper = client_wrapper
+
+ def get_custom_vat_rates(
+ self, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[CustomVatRateResponseList]:
+ """
+ Parameters
+ ----------
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[CustomVatRateResponseList]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ "custom_vat_rates",
+ method="GET",
+ request_options=request_options,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ CustomVatRateResponseList,
+ parse_obj_as(
+ type_=CustomVatRateResponseList, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 400:
+ raise BadRequestError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 401:
+ raise UnauthorizedError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 500:
+ raise InternalServerError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ _response_json = _response.json()
+ except JSONDecodeError:
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def post_custom_vat_rates(
+ self,
+ *,
+ components: typing.Sequence[VatRateComponent],
+ name: str,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[CustomVatRateResponse]:
+ """
+ Parameters
+ ----------
+ components : typing.Sequence[VatRateComponent]
+ Sub-taxes included in the Custom VAT.
+
+ name : str
+ Display name of the Custom VAT.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[CustomVatRateResponse]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ "custom_vat_rates",
+ method="POST",
+ json={
+ "components": convert_and_respect_annotation_metadata(
+ object_=components, annotation=typing.Sequence[VatRateComponent], direction="write"
+ ),
+ "name": name,
+ },
+ headers={
+ "content-type": "application/json",
+ },
+ request_options=request_options,
+ omit=OMIT,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ CustomVatRateResponse,
+ parse_obj_as(
+ type_=CustomVatRateResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 400:
+ raise BadRequestError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 401:
+ raise UnauthorizedError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 500:
+ raise InternalServerError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ _response_json = _response.json()
+ except JSONDecodeError:
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def get_custom_vat_rates_id(
+ self, custom_vat_rate_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[CustomVatRateResponse]:
+ """
+ Parameters
+ ----------
+ custom_vat_rate_id : str
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[CustomVatRateResponse]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ f"custom_vat_rates/{jsonable_encoder(custom_vat_rate_id)}",
+ method="GET",
+ request_options=request_options,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ CustomVatRateResponse,
+ parse_obj_as(
+ type_=CustomVatRateResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 400:
+ raise BadRequestError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 401:
+ raise UnauthorizedError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 500:
+ raise InternalServerError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ _response_json = _response.json()
+ except JSONDecodeError:
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def delete_custom_vat_rates_id(
+ self, custom_vat_rate_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[None]:
+ """
+ Parameters
+ ----------
+ custom_vat_rate_id : str
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[None]
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ f"custom_vat_rates/{jsonable_encoder(custom_vat_rate_id)}",
+ method="DELETE",
+ request_options=request_options,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ return HttpResponse(response=_response, data=None)
+ if _response.status_code == 400:
+ raise BadRequestError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 401:
+ raise UnauthorizedError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 500:
+ raise InternalServerError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ _response_json = _response.json()
+ except JSONDecodeError:
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def patch_custom_vat_rates_id(
+ self,
+ custom_vat_rate_id: str,
+ *,
+ components: typing.Optional[typing.Sequence[VatRateComponent]] = OMIT,
+ name: typing.Optional[str] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[CustomVatRateResponse]:
+ """
+ Parameters
+ ----------
+ custom_vat_rate_id : str
+
+ components : typing.Optional[typing.Sequence[VatRateComponent]]
+ Sub-taxes included in the Custom VAT.
+
+ name : typing.Optional[str]
+ Display name of the Custom VAT.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[CustomVatRateResponse]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ f"custom_vat_rates/{jsonable_encoder(custom_vat_rate_id)}",
+ method="PATCH",
+ json={
+ "components": convert_and_respect_annotation_metadata(
+ object_=components, annotation=typing.Sequence[VatRateComponent], direction="write"
+ ),
+ "name": name,
+ },
+ headers={
+ "content-type": "application/json",
+ },
+ request_options=request_options,
+ omit=OMIT,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ CustomVatRateResponse,
+ parse_obj_as(
+ type_=CustomVatRateResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 400:
+ raise BadRequestError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 401:
+ raise UnauthorizedError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 500:
+ raise InternalServerError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ _response_json = _response.json()
+ except JSONDecodeError:
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+
+class AsyncRawCustomVatRatesClient:
+ def __init__(self, *, client_wrapper: AsyncClientWrapper):
+ self._client_wrapper = client_wrapper
+
+ async def get_custom_vat_rates(
+ self, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> AsyncHttpResponse[CustomVatRateResponseList]:
+ """
+ Parameters
+ ----------
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ AsyncHttpResponse[CustomVatRateResponseList]
+ Successful Response
+ """
+ _response = await self._client_wrapper.httpx_client.request(
+ "custom_vat_rates",
+ method="GET",
+ request_options=request_options,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ CustomVatRateResponseList,
+ parse_obj_as(
+ type_=CustomVatRateResponseList, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return AsyncHttpResponse(response=_response, data=_data)
+ if _response.status_code == 400:
+ raise BadRequestError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 401:
+ raise UnauthorizedError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 500:
+ raise InternalServerError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ _response_json = _response.json()
+ except JSONDecodeError:
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ async def post_custom_vat_rates(
+ self,
+ *,
+ components: typing.Sequence[VatRateComponent],
+ name: str,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> AsyncHttpResponse[CustomVatRateResponse]:
+ """
+ Parameters
+ ----------
+ components : typing.Sequence[VatRateComponent]
+ Sub-taxes included in the Custom VAT.
+
+ name : str
+ Display name of the Custom VAT.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ AsyncHttpResponse[CustomVatRateResponse]
+ Successful Response
+ """
+ _response = await self._client_wrapper.httpx_client.request(
+ "custom_vat_rates",
+ method="POST",
+ json={
+ "components": convert_and_respect_annotation_metadata(
+ object_=components, annotation=typing.Sequence[VatRateComponent], direction="write"
+ ),
+ "name": name,
+ },
+ headers={
+ "content-type": "application/json",
+ },
+ request_options=request_options,
+ omit=OMIT,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ CustomVatRateResponse,
+ parse_obj_as(
+ type_=CustomVatRateResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return AsyncHttpResponse(response=_response, data=_data)
+ if _response.status_code == 400:
+ raise BadRequestError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 401:
+ raise UnauthorizedError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 500:
+ raise InternalServerError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ _response_json = _response.json()
+ except JSONDecodeError:
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ async def get_custom_vat_rates_id(
+ self, custom_vat_rate_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> AsyncHttpResponse[CustomVatRateResponse]:
+ """
+ Parameters
+ ----------
+ custom_vat_rate_id : str
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ AsyncHttpResponse[CustomVatRateResponse]
+ Successful Response
+ """
+ _response = await self._client_wrapper.httpx_client.request(
+ f"custom_vat_rates/{jsonable_encoder(custom_vat_rate_id)}",
+ method="GET",
+ request_options=request_options,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ CustomVatRateResponse,
+ parse_obj_as(
+ type_=CustomVatRateResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return AsyncHttpResponse(response=_response, data=_data)
+ if _response.status_code == 400:
+ raise BadRequestError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 401:
+ raise UnauthorizedError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 500:
+ raise InternalServerError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ _response_json = _response.json()
+ except JSONDecodeError:
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ async def delete_custom_vat_rates_id(
+ self, custom_vat_rate_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> AsyncHttpResponse[None]:
+ """
+ Parameters
+ ----------
+ custom_vat_rate_id : str
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ AsyncHttpResponse[None]
+ """
+ _response = await self._client_wrapper.httpx_client.request(
+ f"custom_vat_rates/{jsonable_encoder(custom_vat_rate_id)}",
+ method="DELETE",
+ request_options=request_options,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ return AsyncHttpResponse(response=_response, data=None)
+ if _response.status_code == 400:
+ raise BadRequestError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 401:
+ raise UnauthorizedError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 500:
+ raise InternalServerError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ _response_json = _response.json()
+ except JSONDecodeError:
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ async def patch_custom_vat_rates_id(
+ self,
+ custom_vat_rate_id: str,
+ *,
+ components: typing.Optional[typing.Sequence[VatRateComponent]] = OMIT,
+ name: typing.Optional[str] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> AsyncHttpResponse[CustomVatRateResponse]:
+ """
+ Parameters
+ ----------
+ custom_vat_rate_id : str
+
+ components : typing.Optional[typing.Sequence[VatRateComponent]]
+ Sub-taxes included in the Custom VAT.
+
+ name : typing.Optional[str]
+ Display name of the Custom VAT.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ AsyncHttpResponse[CustomVatRateResponse]
+ Successful Response
+ """
+ _response = await self._client_wrapper.httpx_client.request(
+ f"custom_vat_rates/{jsonable_encoder(custom_vat_rate_id)}",
+ method="PATCH",
+ json={
+ "components": convert_and_respect_annotation_metadata(
+ object_=components, annotation=typing.Sequence[VatRateComponent], direction="write"
+ ),
+ "name": name,
+ },
+ headers={
+ "content-type": "application/json",
+ },
+ request_options=request_options,
+ omit=OMIT,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ CustomVatRateResponse,
+ parse_obj_as(
+ type_=CustomVatRateResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return AsyncHttpResponse(response=_response, data=_data)
+ if _response.status_code == 400:
+ raise BadRequestError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 401:
+ raise UnauthorizedError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 500:
+ raise InternalServerError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ _response_json = _response.json()
+ except JSONDecodeError:
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
diff --git a/src/monite/data_exports/client.py b/src/monite/data_exports/client.py
index 13900cd..17e8452 100644
--- a/src/monite/data_exports/client.py
+++ b/src/monite/data_exports/client.py
@@ -86,7 +86,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.data_exports.get()
"""
_response = self._raw_client.get(
@@ -135,10 +140,23 @@ def create(
Examples
--------
- from monite import Monite
- from monite import ExportObjectSchema_Payable
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.data_exports.create(date_from='date_from', date_to='date_to', format="csv", objects=[ExportObjectSchema_Payable(statuses=["draft"], )], )
+ from monite import ExportObjectSchema_Payable, Monite
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.data_exports.create(
+ date_from="date_from",
+ date_to="date_to",
+ format="csv",
+ objects=[
+ ExportObjectSchema_Payable(
+ statuses=["draft"],
+ )
+ ],
+ )
"""
_response = self._raw_client.create(
date_from=date_from, date_to=date_to, format=format, objects=objects, request_options=request_options
@@ -162,7 +180,12 @@ def get_supported_formats(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.data_exports.get_supported_formats()
"""
_response = self._raw_client.get_supported_formats(request_options=request_options)
@@ -187,8 +210,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.data_exports.get_by_id(document_export_id='document_export_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.data_exports.get_by_id(
+ document_export_id="document_export_id",
+ )
"""
_response = self._raw_client.get_by_id(document_export_id, request_options=request_options)
return _response.data
@@ -259,11 +289,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.data_exports.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
@@ -312,12 +352,30 @@ async def create(
Examples
--------
- from monite import AsyncMonite
- from monite import ExportObjectSchema_Payable
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite, ExportObjectSchema_Payable
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.data_exports.create(date_from='date_from', date_to='date_to', format="csv", objects=[ExportObjectSchema_Payable(statuses=["draft"], )], )
+ await client.data_exports.create(
+ date_from="date_from",
+ date_to="date_to",
+ format="csv",
+ objects=[
+ ExportObjectSchema_Payable(
+ statuses=["draft"],
+ )
+ ],
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -341,11 +399,21 @@ async def get_supported_formats(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.data_exports.get_supported_formats()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_supported_formats(request_options=request_options)
@@ -369,11 +437,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.data_exports.get_by_id(document_export_id='document_export_id', )
+ await client.data_exports.get_by_id(
+ document_export_id="document_export_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(document_export_id, request_options=request_options)
diff --git a/src/monite/data_exports/extra_data/client.py b/src/monite/data_exports/extra_data/client.py
index 8ae8c48..2888270 100644
--- a/src/monite/data_exports/extra_data/client.py
+++ b/src/monite/data_exports/extra_data/client.py
@@ -99,7 +99,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.data_exports.extra_data.get()
"""
_response = self._raw_client.get(
@@ -150,8 +155,17 @@ def create(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.data_exports.extra_data.create(field_name="default_account_code", field_value='field_value', object_id='object_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.data_exports.extra_data.create(
+ field_name="default_account_code",
+ field_value="field_value",
+ object_id="object_id",
+ )
"""
_response = self._raw_client.create(
field_name=field_name, field_value=field_value, object_id=object_id, request_options=request_options
@@ -177,8 +191,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.data_exports.extra_data.get_by_id(extra_data_id='extra_data_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.data_exports.extra_data.get_by_id(
+ extra_data_id="extra_data_id",
+ )
"""
_response = self._raw_client.get_by_id(extra_data_id, request_options=request_options)
return _response.data
@@ -202,8 +223,15 @@ def delete_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.data_exports.extra_data.delete_by_id(extra_data_id='extra_data_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.data_exports.extra_data.delete_by_id(
+ extra_data_id="extra_data_id",
+ )
"""
_response = self._raw_client.delete_by_id(extra_data_id, request_options=request_options)
return _response.data
@@ -242,8 +270,15 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.data_exports.extra_data.update_by_id(extra_data_id='extra_data_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.data_exports.extra_data.update_by_id(
+ extra_data_id="extra_data_id",
+ )
"""
_response = self._raw_client.update_by_id(
extra_data_id,
@@ -338,11 +373,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.data_exports.extra_data.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
@@ -392,11 +437,25 @@ async def create(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.data_exports.extra_data.create(field_name="default_account_code", field_value='field_value', object_id='object_id', )
+ await client.data_exports.extra_data.create(
+ field_name="default_account_code",
+ field_value="field_value",
+ object_id="object_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -422,11 +481,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.data_exports.extra_data.get_by_id(extra_data_id='extra_data_id', )
+ await client.data_exports.extra_data.get_by_id(
+ extra_data_id="extra_data_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(extra_data_id, request_options=request_options)
@@ -450,11 +521,23 @@ async def delete_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.data_exports.extra_data.delete_by_id(extra_data_id='extra_data_id', )
+ await client.data_exports.extra_data.delete_by_id(
+ extra_data_id="extra_data_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(extra_data_id, request_options=request_options)
@@ -493,11 +576,23 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.data_exports.extra_data.update_by_id(extra_data_id='extra_data_id', )
+ await client.data_exports.extra_data.update_by_id(
+ extra_data_id="extra_data_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
diff --git a/src/monite/delivery_notes/client.py b/src/monite/delivery_notes/client.py
index 4e0a33d..cecb696 100644
--- a/src/monite/delivery_notes/client.py
+++ b/src/monite/delivery_notes/client.py
@@ -134,7 +134,12 @@ def get_delivery_notes(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.delivery_notes.get_delivery_notes()
"""
_response = self._raw_client.get_delivery_notes(
@@ -184,13 +189,46 @@ def post_delivery_notes(
Examples
--------
- from monite import Monite
- from monite import DeliveryNoteCreateRequest
- from monite import DeliveryNoteCreateLineItem
- from monite import DeliveryNoteLineItemProduct
- from monite import UnitRequest
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.delivery_notes.post_delivery_notes(request=DeliveryNoteCreateRequest(counterpart_address_id='a1b2c3d4-e5f6-g7h8-i9j0-k1l2m3n4o5p6', counterpart_id='a1b2c3d4-e5f6-g7h8-i9j0-k1l2m3n4o5p6', delivery_date='2025-01-01', delivery_number='102-2025-0987', display_signature_placeholder=True, line_items=[DeliveryNoteCreateLineItem(product_id='a1b2c3d4-e5f6-g7h8-i9j0-k1l2m3n4o5p6', quantity=10.0, ), DeliveryNoteCreateLineItem(product=DeliveryNoteLineItemProduct(description='Description of product 2', measure_unit=UnitRequest(description='pieces', name='pcs', ), name='Product 2', ), quantity=20.0, )], memo='This is a memo', ), )
+ from monite import (
+ DeliveryNoteCreateLineItem,
+ DeliveryNoteCreateRequest,
+ DeliveryNoteLineItemProduct,
+ Monite,
+ UnitRequest,
+ )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.delivery_notes.post_delivery_notes(
+ request=DeliveryNoteCreateRequest(
+ counterpart_address_id="a1b2c3d4-e5f6-g7h8-i9j0-k1l2m3n4o5p6",
+ counterpart_id="a1b2c3d4-e5f6-g7h8-i9j0-k1l2m3n4o5p6",
+ delivery_date="2025-01-01",
+ delivery_number="102-2025-0987",
+ display_signature_placeholder=True,
+ line_items=[
+ DeliveryNoteCreateLineItem(
+ product_id="a1b2c3d4-e5f6-g7h8-i9j0-k1l2m3n4o5p6",
+ quantity=10.0,
+ ),
+ DeliveryNoteCreateLineItem(
+ product=DeliveryNoteLineItemProduct(
+ description="Description of product 2",
+ measure_unit=UnitRequest(
+ description="pieces",
+ name="pcs",
+ ),
+ name="Product 2",
+ ),
+ quantity=20.0,
+ ),
+ ],
+ memo="This is a memo",
+ ),
+ )
"""
_response = self._raw_client.post_delivery_notes(request=request, request_options=request_options)
return _response.data
@@ -214,8 +252,15 @@ def get_delivery_notes_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.delivery_notes.get_delivery_notes_id(delivery_note_id='delivery_note_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.delivery_notes.get_delivery_notes_id(
+ delivery_note_id="delivery_note_id",
+ )
"""
_response = self._raw_client.get_delivery_notes_id(delivery_note_id, request_options=request_options)
return _response.data
@@ -238,8 +283,15 @@ def delete_delivery_notes_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.delivery_notes.delete_delivery_notes_id(delivery_note_id='delivery_note_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.delivery_notes.delete_delivery_notes_id(
+ delivery_note_id="delivery_note_id",
+ )
"""
_response = self._raw_client.delete_delivery_notes_id(delivery_note_id, request_options=request_options)
return _response.data
@@ -294,8 +346,15 @@ def patch_delivery_notes_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.delivery_notes.patch_delivery_notes_id(delivery_note_id='delivery_note_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.delivery_notes.patch_delivery_notes_id(
+ delivery_note_id="delivery_note_id",
+ )
"""
_response = self._raw_client.patch_delivery_notes_id(
delivery_note_id,
@@ -329,8 +388,15 @@ def post_delivery_notes_id_cancel(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.delivery_notes.post_delivery_notes_id_cancel(delivery_note_id='delivery_note_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.delivery_notes.post_delivery_notes_id_cancel(
+ delivery_note_id="delivery_note_id",
+ )
"""
_response = self._raw_client.post_delivery_notes_id_cancel(delivery_note_id, request_options=request_options)
return _response.data
@@ -354,8 +420,15 @@ def post_delivery_notes_id_mark_as_delivered(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.delivery_notes.post_delivery_notes_id_mark_as_delivered(delivery_note_id='delivery_note_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.delivery_notes.post_delivery_notes_id_mark_as_delivered(
+ delivery_note_id="delivery_note_id",
+ )
"""
_response = self._raw_client.post_delivery_notes_id_mark_as_delivered(
delivery_note_id, request_options=request_options
@@ -478,11 +551,21 @@ async def get_delivery_notes(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.delivery_notes.get_delivery_notes()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_delivery_notes(
@@ -532,15 +615,53 @@ async def post_delivery_notes(
Examples
--------
- from monite import AsyncMonite
- from monite import DeliveryNoteCreateRequest
- from monite import DeliveryNoteCreateLineItem
- from monite import DeliveryNoteLineItemProduct
- from monite import UnitRequest
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import (
+ AsyncMonite,
+ DeliveryNoteCreateLineItem,
+ DeliveryNoteCreateRequest,
+ DeliveryNoteLineItemProduct,
+ UnitRequest,
+ )
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.delivery_notes.post_delivery_notes(request=DeliveryNoteCreateRequest(counterpart_address_id='a1b2c3d4-e5f6-g7h8-i9j0-k1l2m3n4o5p6', counterpart_id='a1b2c3d4-e5f6-g7h8-i9j0-k1l2m3n4o5p6', delivery_date='2025-01-01', delivery_number='102-2025-0987', display_signature_placeholder=True, line_items=[DeliveryNoteCreateLineItem(product_id='a1b2c3d4-e5f6-g7h8-i9j0-k1l2m3n4o5p6', quantity=10.0, ), DeliveryNoteCreateLineItem(product=DeliveryNoteLineItemProduct(description='Description of product 2', measure_unit=UnitRequest(description='pieces', name='pcs', ), name='Product 2', ), quantity=20.0, )], memo='This is a memo', ), )
+ await client.delivery_notes.post_delivery_notes(
+ request=DeliveryNoteCreateRequest(
+ counterpart_address_id="a1b2c3d4-e5f6-g7h8-i9j0-k1l2m3n4o5p6",
+ counterpart_id="a1b2c3d4-e5f6-g7h8-i9j0-k1l2m3n4o5p6",
+ delivery_date="2025-01-01",
+ delivery_number="102-2025-0987",
+ display_signature_placeholder=True,
+ line_items=[
+ DeliveryNoteCreateLineItem(
+ product_id="a1b2c3d4-e5f6-g7h8-i9j0-k1l2m3n4o5p6",
+ quantity=10.0,
+ ),
+ DeliveryNoteCreateLineItem(
+ product=DeliveryNoteLineItemProduct(
+ description="Description of product 2",
+ measure_unit=UnitRequest(
+ description="pieces",
+ name="pcs",
+ ),
+ name="Product 2",
+ ),
+ quantity=20.0,
+ ),
+ ],
+ memo="This is a memo",
+ ),
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.post_delivery_notes(request=request, request_options=request_options)
@@ -564,11 +685,23 @@ async def get_delivery_notes_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.delivery_notes.get_delivery_notes_id(delivery_note_id='delivery_note_id', )
+ await client.delivery_notes.get_delivery_notes_id(
+ delivery_note_id="delivery_note_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_delivery_notes_id(delivery_note_id, request_options=request_options)
@@ -591,11 +724,23 @@ async def delete_delivery_notes_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.delivery_notes.delete_delivery_notes_id(delivery_note_id='delivery_note_id', )
+ await client.delivery_notes.delete_delivery_notes_id(
+ delivery_note_id="delivery_note_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_delivery_notes_id(delivery_note_id, request_options=request_options)
@@ -650,11 +795,23 @@ async def patch_delivery_notes_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.delivery_notes.patch_delivery_notes_id(delivery_note_id='delivery_note_id', )
+ await client.delivery_notes.patch_delivery_notes_id(
+ delivery_note_id="delivery_note_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.patch_delivery_notes_id(
@@ -688,11 +845,23 @@ async def post_delivery_notes_id_cancel(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.delivery_notes.post_delivery_notes_id_cancel(delivery_note_id='delivery_note_id', )
+ await client.delivery_notes.post_delivery_notes_id_cancel(
+ delivery_note_id="delivery_note_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.post_delivery_notes_id_cancel(
@@ -718,11 +887,23 @@ async def post_delivery_notes_id_mark_as_delivered(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.delivery_notes.post_delivery_notes_id_mark_as_delivered(delivery_note_id='delivery_note_id', )
+ await client.delivery_notes.post_delivery_notes_id_mark_as_delivered(
+ delivery_note_id="delivery_note_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.post_delivery_notes_id_mark_as_delivered(
diff --git a/src/monite/e_invoicing_connections/client.py b/src/monite/e_invoicing_connections/client.py
index d9438cf..3bc773c 100644
--- a/src/monite/e_invoicing_connections/client.py
+++ b/src/monite/e_invoicing_connections/client.py
@@ -9,6 +9,7 @@
from ..types.einvoicing_address import EinvoicingAddress
from ..types.einvoicing_connection_response import EinvoicingConnectionResponse
from ..types.einvoicing_network_credentials_response import EinvoicingNetworkCredentialsResponse
+from ..types.update_einvoicing_address import UpdateEinvoicingAddress
from .raw_client import AsyncRawEInvoicingConnectionsClient, RawEInvoicingConnectionsClient
# this is used as the default value for optional parameters
@@ -47,7 +48,12 @@ def get_einvoicing_connections(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.e_invoicing_connections.get_einvoicing_connections()
"""
_response = self._raw_client.get_einvoicing_connections(request_options=request_options)
@@ -58,6 +64,8 @@ def post_einvoicing_connections(
*,
address: EinvoicingAddress,
entity_vat_id_id: typing.Optional[str] = OMIT,
+ is_receiver: typing.Optional[bool] = OMIT,
+ is_sender: typing.Optional[bool] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
) -> EinvoicingConnectionResponse:
"""
@@ -69,6 +77,12 @@ def post_einvoicing_connections(
entity_vat_id_id : typing.Optional[str]
Entity VAT ID identifier for the integration
+ is_receiver : typing.Optional[bool]
+ Set to `true` if the entity needs to receive e-invoices.
+
+ is_sender : typing.Optional[bool]
+ Set to `true` if the entity needs to send e-invoices. Either `is_sender` or `is_receiver` or both must be `true`.
+
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
@@ -79,13 +93,28 @@ def post_einvoicing_connections(
Examples
--------
- from monite import Monite
- from monite import EinvoicingAddress
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.e_invoicing_connections.post_einvoicing_connections(address=EinvoicingAddress(address_line1='address_line1', city='city', country="DE", postal_code='postal_code', ), )
+ from monite import EinvoicingAddress, Monite
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.e_invoicing_connections.post_einvoicing_connections(
+ address=EinvoicingAddress(
+ address_line1="address_line1",
+ city="city",
+ country="DE",
+ postal_code="postal_code",
+ ),
+ )
"""
_response = self._raw_client.post_einvoicing_connections(
- address=address, entity_vat_id_id=entity_vat_id_id, request_options=request_options
+ address=address,
+ entity_vat_id_id=entity_vat_id_id,
+ is_receiver=is_receiver,
+ is_sender=is_sender,
+ request_options=request_options,
)
return _response.data
@@ -108,8 +137,15 @@ def get_einvoicing_connections_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.e_invoicing_connections.get_einvoicing_connections_id(einvoicing_connection_id='einvoicing_connection_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.e_invoicing_connections.get_einvoicing_connections_id(
+ einvoicing_connection_id="einvoicing_connection_id",
+ )
"""
_response = self._raw_client.get_einvoicing_connections_id(
einvoicing_connection_id, request_options=request_options
@@ -134,14 +170,74 @@ def delete_einvoicing_connections_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.e_invoicing_connections.delete_einvoicing_connections_id(einvoicing_connection_id='einvoicing_connection_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.e_invoicing_connections.delete_einvoicing_connections_id(
+ einvoicing_connection_id="einvoicing_connection_id",
+ )
"""
_response = self._raw_client.delete_einvoicing_connections_id(
einvoicing_connection_id, request_options=request_options
)
return _response.data
+ def patch_einvoicing_connections_id(
+ self,
+ einvoicing_connection_id: str,
+ *,
+ address: typing.Optional[UpdateEinvoicingAddress] = OMIT,
+ is_receiver: typing.Optional[bool] = OMIT,
+ is_sender: typing.Optional[bool] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> EinvoicingConnectionResponse:
+ """
+ Parameters
+ ----------
+ einvoicing_connection_id : str
+
+ address : typing.Optional[UpdateEinvoicingAddress]
+ Integration Address
+
+ is_receiver : typing.Optional[bool]
+ Set to `true` if the entity needs to receive e-invoices.
+
+ is_sender : typing.Optional[bool]
+ Set to `true` if the entity needs to send e-invoices. Either `is_sender` or `is_receiver` or both must be `true`.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ EinvoicingConnectionResponse
+ Successful Response
+
+ Examples
+ --------
+ from monite import Monite
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.e_invoicing_connections.patch_einvoicing_connections_id(
+ einvoicing_connection_id="einvoicing_connection_id",
+ )
+ """
+ _response = self._raw_client.patch_einvoicing_connections_id(
+ einvoicing_connection_id,
+ address=address,
+ is_receiver=is_receiver,
+ is_sender=is_sender,
+ request_options=request_options,
+ )
+ return _response.data
+
def post_einvoicing_connections_id_network_credentials(
self,
einvoicing_connection_id: str,
@@ -172,8 +268,17 @@ def post_einvoicing_connections_id_network_credentials(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.e_invoicing_connections.post_einvoicing_connections_id_network_credentials(einvoicing_connection_id='einvoicing_connection_id', network_credentials_identifier='12345678', network_credentials_schema="DE:VAT", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.e_invoicing_connections.post_einvoicing_connections_id_network_credentials(
+ einvoicing_connection_id="einvoicing_connection_id",
+ network_credentials_identifier="12345678",
+ network_credentials_schema="DE:VAT",
+ )
"""
_response = self._raw_client.post_einvoicing_connections_id_network_credentials(
einvoicing_connection_id,
@@ -215,11 +320,21 @@ async def get_einvoicing_connections(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.e_invoicing_connections.get_einvoicing_connections()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_einvoicing_connections(request_options=request_options)
@@ -230,6 +345,8 @@ async def post_einvoicing_connections(
*,
address: EinvoicingAddress,
entity_vat_id_id: typing.Optional[str] = OMIT,
+ is_receiver: typing.Optional[bool] = OMIT,
+ is_sender: typing.Optional[bool] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
) -> EinvoicingConnectionResponse:
"""
@@ -241,6 +358,12 @@ async def post_einvoicing_connections(
entity_vat_id_id : typing.Optional[str]
Entity VAT ID identifier for the integration
+ is_receiver : typing.Optional[bool]
+ Set to `true` if the entity needs to receive e-invoices.
+
+ is_sender : typing.Optional[bool]
+ Set to `true` if the entity needs to send e-invoices. Either `is_sender` or `is_receiver` or both must be `true`.
+
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
@@ -251,16 +374,36 @@ async def post_einvoicing_connections(
Examples
--------
- from monite import AsyncMonite
- from monite import EinvoicingAddress
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite, EinvoicingAddress
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.e_invoicing_connections.post_einvoicing_connections(address=EinvoicingAddress(address_line1='address_line1', city='city', country="DE", postal_code='postal_code', ), )
+ await client.e_invoicing_connections.post_einvoicing_connections(
+ address=EinvoicingAddress(
+ address_line1="address_line1",
+ city="city",
+ country="DE",
+ postal_code="postal_code",
+ ),
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.post_einvoicing_connections(
- address=address, entity_vat_id_id=entity_vat_id_id, request_options=request_options
+ address=address,
+ entity_vat_id_id=entity_vat_id_id,
+ is_receiver=is_receiver,
+ is_sender=is_sender,
+ request_options=request_options,
)
return _response.data
@@ -282,11 +425,23 @@ async def get_einvoicing_connections_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.e_invoicing_connections.get_einvoicing_connections_id(einvoicing_connection_id='einvoicing_connection_id', )
+ await client.e_invoicing_connections.get_einvoicing_connections_id(
+ einvoicing_connection_id="einvoicing_connection_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_einvoicing_connections_id(
@@ -311,11 +466,23 @@ async def delete_einvoicing_connections_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.e_invoicing_connections.delete_einvoicing_connections_id(einvoicing_connection_id='einvoicing_connection_id', )
+ await client.e_invoicing_connections.delete_einvoicing_connections_id(
+ einvoicing_connection_id="einvoicing_connection_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_einvoicing_connections_id(
@@ -323,6 +490,67 @@ async def main() -> None:
)
return _response.data
+ async def patch_einvoicing_connections_id(
+ self,
+ einvoicing_connection_id: str,
+ *,
+ address: typing.Optional[UpdateEinvoicingAddress] = OMIT,
+ is_receiver: typing.Optional[bool] = OMIT,
+ is_sender: typing.Optional[bool] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> EinvoicingConnectionResponse:
+ """
+ Parameters
+ ----------
+ einvoicing_connection_id : str
+
+ address : typing.Optional[UpdateEinvoicingAddress]
+ Integration Address
+
+ is_receiver : typing.Optional[bool]
+ Set to `true` if the entity needs to receive e-invoices.
+
+ is_sender : typing.Optional[bool]
+ Set to `true` if the entity needs to send e-invoices. Either `is_sender` or `is_receiver` or both must be `true`.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ EinvoicingConnectionResponse
+ Successful Response
+
+ Examples
+ --------
+ import asyncio
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
+ async def main() -> None:
+ await client.e_invoicing_connections.patch_einvoicing_connections_id(
+ einvoicing_connection_id="einvoicing_connection_id",
+ )
+
+
+ asyncio.run(main())
+ """
+ _response = await self._raw_client.patch_einvoicing_connections_id(
+ einvoicing_connection_id,
+ address=address,
+ is_receiver=is_receiver,
+ is_sender=is_sender,
+ request_options=request_options,
+ )
+ return _response.data
+
async def post_einvoicing_connections_id_network_credentials(
self,
einvoicing_connection_id: str,
@@ -352,11 +580,25 @@ async def post_einvoicing_connections_id_network_credentials(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.e_invoicing_connections.post_einvoicing_connections_id_network_credentials(einvoicing_connection_id='einvoicing_connection_id', network_credentials_identifier='12345678', network_credentials_schema="DE:VAT", )
+ await client.e_invoicing_connections.post_einvoicing_connections_id_network_credentials(
+ einvoicing_connection_id="einvoicing_connection_id",
+ network_credentials_identifier="12345678",
+ network_credentials_schema="DE:VAT",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.post_einvoicing_connections_id_network_credentials(
diff --git a/src/monite/e_invoicing_connections/raw_client.py b/src/monite/e_invoicing_connections/raw_client.py
index 73ead8b..69e7a19 100644
--- a/src/monite/e_invoicing_connections/raw_client.py
+++ b/src/monite/e_invoicing_connections/raw_client.py
@@ -22,6 +22,7 @@
from ..types.einvoicing_address import EinvoicingAddress
from ..types.einvoicing_connection_response import EinvoicingConnectionResponse
from ..types.einvoicing_network_credentials_response import EinvoicingNetworkCredentialsResponse
+from ..types.update_einvoicing_address import UpdateEinvoicingAddress
# this is used as the default value for optional parameters
OMIT = typing.cast(typing.Any, ...)
@@ -125,6 +126,8 @@ def post_einvoicing_connections(
*,
address: EinvoicingAddress,
entity_vat_id_id: typing.Optional[str] = OMIT,
+ is_receiver: typing.Optional[bool] = OMIT,
+ is_sender: typing.Optional[bool] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
) -> HttpResponse[EinvoicingConnectionResponse]:
"""
@@ -136,6 +139,12 @@ def post_einvoicing_connections(
entity_vat_id_id : typing.Optional[str]
Entity VAT ID identifier for the integration
+ is_receiver : typing.Optional[bool]
+ Set to `true` if the entity needs to receive e-invoices.
+
+ is_sender : typing.Optional[bool]
+ Set to `true` if the entity needs to send e-invoices. Either `is_sender` or `is_receiver` or both must be `true`.
+
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
@@ -152,6 +161,8 @@ def post_einvoicing_connections(
object_=address, annotation=EinvoicingAddress, direction="write"
),
"entity_vat_id_id": entity_vat_id_id,
+ "is_receiver": is_receiver,
+ "is_sender": is_sender,
},
headers={
"content-type": "application/json",
@@ -436,6 +447,145 @@ def delete_einvoicing_connections_id(
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+ def patch_einvoicing_connections_id(
+ self,
+ einvoicing_connection_id: str,
+ *,
+ address: typing.Optional[UpdateEinvoicingAddress] = OMIT,
+ is_receiver: typing.Optional[bool] = OMIT,
+ is_sender: typing.Optional[bool] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[EinvoicingConnectionResponse]:
+ """
+ Parameters
+ ----------
+ einvoicing_connection_id : str
+
+ address : typing.Optional[UpdateEinvoicingAddress]
+ Integration Address
+
+ is_receiver : typing.Optional[bool]
+ Set to `true` if the entity needs to receive e-invoices.
+
+ is_sender : typing.Optional[bool]
+ Set to `true` if the entity needs to send e-invoices. Either `is_sender` or `is_receiver` or both must be `true`.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[EinvoicingConnectionResponse]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ f"einvoicing_connections/{jsonable_encoder(einvoicing_connection_id)}",
+ method="PATCH",
+ json={
+ "address": convert_and_respect_annotation_metadata(
+ object_=address, annotation=UpdateEinvoicingAddress, direction="write"
+ ),
+ "is_receiver": is_receiver,
+ "is_sender": is_sender,
+ },
+ headers={
+ "content-type": "application/json",
+ },
+ request_options=request_options,
+ omit=OMIT,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ EinvoicingConnectionResponse,
+ parse_obj_as(
+ type_=EinvoicingConnectionResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 400:
+ raise BadRequestError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 401:
+ raise UnauthorizedError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 409:
+ raise ConflictError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 500:
+ raise InternalServerError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ _response_json = _response.json()
+ except JSONDecodeError:
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
def post_einvoicing_connections_id_network_credentials(
self,
einvoicing_connection_id: str,
@@ -667,6 +817,8 @@ async def post_einvoicing_connections(
*,
address: EinvoicingAddress,
entity_vat_id_id: typing.Optional[str] = OMIT,
+ is_receiver: typing.Optional[bool] = OMIT,
+ is_sender: typing.Optional[bool] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
) -> AsyncHttpResponse[EinvoicingConnectionResponse]:
"""
@@ -678,6 +830,12 @@ async def post_einvoicing_connections(
entity_vat_id_id : typing.Optional[str]
Entity VAT ID identifier for the integration
+ is_receiver : typing.Optional[bool]
+ Set to `true` if the entity needs to receive e-invoices.
+
+ is_sender : typing.Optional[bool]
+ Set to `true` if the entity needs to send e-invoices. Either `is_sender` or `is_receiver` or both must be `true`.
+
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
@@ -694,6 +852,8 @@ async def post_einvoicing_connections(
object_=address, annotation=EinvoicingAddress, direction="write"
),
"entity_vat_id_id": entity_vat_id_id,
+ "is_receiver": is_receiver,
+ "is_sender": is_sender,
},
headers={
"content-type": "application/json",
@@ -978,6 +1138,145 @@ async def delete_einvoicing_connections_id(
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+ async def patch_einvoicing_connections_id(
+ self,
+ einvoicing_connection_id: str,
+ *,
+ address: typing.Optional[UpdateEinvoicingAddress] = OMIT,
+ is_receiver: typing.Optional[bool] = OMIT,
+ is_sender: typing.Optional[bool] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> AsyncHttpResponse[EinvoicingConnectionResponse]:
+ """
+ Parameters
+ ----------
+ einvoicing_connection_id : str
+
+ address : typing.Optional[UpdateEinvoicingAddress]
+ Integration Address
+
+ is_receiver : typing.Optional[bool]
+ Set to `true` if the entity needs to receive e-invoices.
+
+ is_sender : typing.Optional[bool]
+ Set to `true` if the entity needs to send e-invoices. Either `is_sender` or `is_receiver` or both must be `true`.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ AsyncHttpResponse[EinvoicingConnectionResponse]
+ Successful Response
+ """
+ _response = await self._client_wrapper.httpx_client.request(
+ f"einvoicing_connections/{jsonable_encoder(einvoicing_connection_id)}",
+ method="PATCH",
+ json={
+ "address": convert_and_respect_annotation_metadata(
+ object_=address, annotation=UpdateEinvoicingAddress, direction="write"
+ ),
+ "is_receiver": is_receiver,
+ "is_sender": is_sender,
+ },
+ headers={
+ "content-type": "application/json",
+ },
+ request_options=request_options,
+ omit=OMIT,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ EinvoicingConnectionResponse,
+ parse_obj_as(
+ type_=EinvoicingConnectionResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return AsyncHttpResponse(response=_response, data=_data)
+ if _response.status_code == 400:
+ raise BadRequestError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 401:
+ raise UnauthorizedError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 409:
+ raise ConflictError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 500:
+ raise InternalServerError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ _response_json = _response.json()
+ except JSONDecodeError:
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
async def post_einvoicing_connections_id_network_credentials(
self,
einvoicing_connection_id: str,
diff --git a/src/monite/entities/bank_accounts/client.py b/src/monite/entities/bank_accounts/client.py
index ac1f702..497199f 100644
--- a/src/monite/entities/bank_accounts/client.py
+++ b/src/monite/entities/bank_accounts/client.py
@@ -46,7 +46,12 @@ def get(self, *, request_options: typing.Optional[RequestOptions] = None) -> Ent
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.entities.bank_accounts.get()
"""
_response = self._raw_client.get(request_options=request_options)
@@ -134,8 +139,16 @@ def create(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.bank_accounts.create(country="AF", currency="AED", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.bank_accounts.create(
+ country="AF",
+ currency="AED",
+ )
"""
_response = self._raw_client.create(
country=country,
@@ -174,8 +187,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.bank_accounts.get_by_id(bank_account_id='bank_account_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.bank_accounts.get_by_id(
+ bank_account_id="bank_account_id",
+ )
"""
_response = self._raw_client.get_by_id(bank_account_id, request_options=request_options)
return _response.data
@@ -198,8 +218,15 @@ def delete_by_id(self, bank_account_id: str, *, request_options: typing.Optional
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.bank_accounts.delete_by_id(bank_account_id='bank_account_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.bank_accounts.delete_by_id(
+ bank_account_id="bank_account_id",
+ )
"""
_response = self._raw_client.delete_by_id(bank_account_id, request_options=request_options)
return _response.data
@@ -236,8 +263,15 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.bank_accounts.update_by_id(bank_account_id='bank_account_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.bank_accounts.update_by_id(
+ bank_account_id="bank_account_id",
+ )
"""
_response = self._raw_client.update_by_id(
bank_account_id,
@@ -268,8 +302,15 @@ def make_default_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.bank_accounts.make_default_by_id(bank_account_id='bank_account_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.bank_accounts.make_default_by_id(
+ bank_account_id="bank_account_id",
+ )
"""
_response = self._raw_client.make_default_by_id(bank_account_id, request_options=request_options)
return _response.data
@@ -308,11 +349,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.entities.bank_accounts.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(request_options=request_options)
@@ -399,11 +450,24 @@ async def create(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.bank_accounts.create(country="AF", currency="AED", )
+ await client.entities.bank_accounts.create(
+ country="AF",
+ currency="AED",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -442,11 +506,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.bank_accounts.get_by_id(bank_account_id='bank_account_id', )
+ await client.entities.bank_accounts.get_by_id(
+ bank_account_id="bank_account_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(bank_account_id, request_options=request_options)
@@ -471,11 +547,23 @@ async def delete_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.bank_accounts.delete_by_id(bank_account_id='bank_account_id', )
+ await client.entities.bank_accounts.delete_by_id(
+ bank_account_id="bank_account_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(bank_account_id, request_options=request_options)
@@ -512,11 +600,23 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.bank_accounts.update_by_id(bank_account_id='bank_account_id', )
+ await client.entities.bank_accounts.update_by_id(
+ bank_account_id="bank_account_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
@@ -547,11 +647,23 @@ async def make_default_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.bank_accounts.make_default_by_id(bank_account_id='bank_account_id', )
+ await client.entities.bank_accounts.make_default_by_id(
+ bank_account_id="bank_account_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.make_default_by_id(bank_account_id, request_options=request_options)
diff --git a/src/monite/entities/client.py b/src/monite/entities/client.py
index 801a207..102d318 100644
--- a/src/monite/entities/client.py
+++ b/src/monite/entities/client.py
@@ -139,7 +139,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.entities.get()
"""
_response = self._raw_client.get(
@@ -222,10 +227,23 @@ def create(
Examples
--------
- from monite import Monite
- from monite import EntityAddressSchema
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.create(address=EntityAddressSchema(city='city', country="AF", line1='line1', postal_code='postal_code', ), email='email', type="individual", )
+ from monite import EntityAddressSchema, Monite
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.create(
+ address=EntityAddressSchema(
+ city="city",
+ country="AF",
+ line1="line1",
+ postal_code="postal_code",
+ ),
+ email="email",
+ type="individual",
+ )
"""
_response = self._raw_client.create(
address=address,
@@ -259,7 +277,12 @@ def get_entities_me(self, *, request_options: typing.Optional[RequestOptions] =
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.entities.get_entities_me()
"""
_response = self._raw_client.get_entities_me(request_options=request_options)
@@ -322,7 +345,12 @@ def patch_entities_me(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.entities.patch_entities_me()
"""
_response = self._raw_client.patch_entities_me(
@@ -359,8 +387,15 @@ def get_by_id(self, entity_id: str, *, request_options: typing.Optional[RequestO
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.get_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.get_by_id(
+ entity_id="ea837e28-509b-4b6a-a600-d54b6aa0b1f5",
+ )
"""
_response = self._raw_client.get_by_id(entity_id, request_options=request_options)
return _response.data
@@ -426,8 +461,15 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.update_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.update_by_id(
+ entity_id="ea837e28-509b-4b6a-a600-d54b6aa0b1f5",
+ )
"""
_response = self._raw_client.update_by_id(
entity_id,
@@ -466,8 +508,15 @@ def post_entities_id_activate(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.post_entities_id_activate(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.post_entities_id_activate(
+ entity_id="ea837e28-509b-4b6a-a600-d54b6aa0b1f5",
+ )
"""
_response = self._raw_client.post_entities_id_activate(entity_id, request_options=request_options)
return _response.data
@@ -494,8 +543,15 @@ def post_entities_id_deactivate(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.post_entities_id_deactivate(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.post_entities_id_deactivate(
+ entity_id="ea837e28-509b-4b6a-a600-d54b6aa0b1f5",
+ )
"""
_response = self._raw_client.post_entities_id_deactivate(entity_id, request_options=request_options)
return _response.data
@@ -525,8 +581,15 @@ def upload_logo_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.upload_logo_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.upload_logo_by_id(
+ entity_id="ea837e28-509b-4b6a-a600-d54b6aa0b1f5",
+ )
"""
_response = self._raw_client.upload_logo_by_id(entity_id, file=file, request_options=request_options)
return _response.data
@@ -548,8 +611,15 @@ def delete_logo_by_id(self, entity_id: str, *, request_options: typing.Optional[
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.delete_logo_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.delete_logo_by_id(
+ entity_id="ea837e28-509b-4b6a-a600-d54b6aa0b1f5",
+ )
"""
_response = self._raw_client.delete_logo_by_id(entity_id, request_options=request_options)
return _response.data
@@ -575,8 +645,15 @@ def get_partner_metadata_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.get_partner_metadata_by_id(entity_id='entity_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.get_partner_metadata_by_id(
+ entity_id="entity_id",
+ )
"""
_response = self._raw_client.get_partner_metadata_by_id(entity_id, request_options=request_options)
return _response.data
@@ -609,9 +686,16 @@ def update_partner_metadata_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.update_partner_metadata_by_id(entity_id='entity_id', metadata={'key': 'value'
- }, )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.update_partner_metadata_by_id(
+ entity_id="entity_id",
+ metadata={"key": "value"},
+ )
"""
_response = self._raw_client.update_partner_metadata_by_id(
entity_id, metadata=metadata, request_options=request_options
@@ -640,8 +724,15 @@ def get_settings_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.get_settings_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.get_settings_by_id(
+ entity_id="ea837e28-509b-4b6a-a600-d54b6aa0b1f5",
+ )
"""
_response = self._raw_client.get_settings_by_id(entity_id, request_options=request_options)
return _response.data
@@ -729,8 +820,15 @@ def update_settings_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.update_settings_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.update_settings_by_id(
+ entity_id="ea837e28-509b-4b6a-a600-d54b6aa0b1f5",
+ )
"""
_response = self._raw_client.update_settings_by_id(
entity_id,
@@ -806,7 +904,12 @@ def upload_onboarding_documents(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.entities.upload_onboarding_documents()
"""
_response = self._raw_client.upload_onboarding_documents(
@@ -844,7 +947,12 @@ def get_onboarding_requirements(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.entities.get_onboarding_requirements()
"""
_response = self._raw_client.get_onboarding_requirements(request_options=request_options)
@@ -946,11 +1054,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.entities.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
@@ -1033,12 +1151,30 @@ async def create(
Examples
--------
- from monite import AsyncMonite
- from monite import EntityAddressSchema
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite, EntityAddressSchema
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.create(address=EntityAddressSchema(city='city', country="AF", line1='line1', postal_code='postal_code', ), email='email', type="individual", )
+ await client.entities.create(
+ address=EntityAddressSchema(
+ city="city",
+ country="AF",
+ line1="line1",
+ postal_code="postal_code",
+ ),
+ email="email",
+ type="individual",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -1072,11 +1208,21 @@ async def get_entities_me(self, *, request_options: typing.Optional[RequestOptio
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.entities.get_entities_me()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_entities_me(request_options=request_options)
@@ -1138,11 +1284,21 @@ async def patch_entities_me(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.entities.patch_entities_me()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.patch_entities_me(
@@ -1180,11 +1336,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.get_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
+ await client.entities.get_by_id(
+ entity_id="ea837e28-509b-4b6a-a600-d54b6aa0b1f5",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(entity_id, request_options=request_options)
@@ -1250,11 +1418,23 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.update_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
+ await client.entities.update_by_id(
+ entity_id="ea837e28-509b-4b6a-a600-d54b6aa0b1f5",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
@@ -1293,11 +1473,23 @@ async def post_entities_id_activate(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.post_entities_id_activate(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
+ await client.entities.post_entities_id_activate(
+ entity_id="ea837e28-509b-4b6a-a600-d54b6aa0b1f5",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.post_entities_id_activate(entity_id, request_options=request_options)
@@ -1324,11 +1516,23 @@ async def post_entities_id_deactivate(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.post_entities_id_deactivate(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
+ await client.entities.post_entities_id_deactivate(
+ entity_id="ea837e28-509b-4b6a-a600-d54b6aa0b1f5",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.post_entities_id_deactivate(entity_id, request_options=request_options)
@@ -1358,11 +1562,23 @@ async def upload_logo_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.upload_logo_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
+ await client.entities.upload_logo_by_id(
+ entity_id="ea837e28-509b-4b6a-a600-d54b6aa0b1f5",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.upload_logo_by_id(entity_id, file=file, request_options=request_options)
@@ -1386,11 +1602,23 @@ async def delete_logo_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.delete_logo_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
+ await client.entities.delete_logo_by_id(
+ entity_id="ea837e28-509b-4b6a-a600-d54b6aa0b1f5",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_logo_by_id(entity_id, request_options=request_options)
@@ -1416,11 +1644,23 @@ async def get_partner_metadata_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.get_partner_metadata_by_id(entity_id='entity_id', )
+ await client.entities.get_partner_metadata_by_id(
+ entity_id="entity_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_partner_metadata_by_id(entity_id, request_options=request_options)
@@ -1453,12 +1693,24 @@ async def update_partner_metadata_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.update_partner_metadata_by_id(entity_id='entity_id', metadata={'key': 'value'
- }, )
+ await client.entities.update_partner_metadata_by_id(
+ entity_id="entity_id",
+ metadata={"key": "value"},
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_partner_metadata_by_id(
@@ -1487,11 +1739,23 @@ async def get_settings_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.get_settings_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
+ await client.entities.get_settings_by_id(
+ entity_id="ea837e28-509b-4b6a-a600-d54b6aa0b1f5",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_settings_by_id(entity_id, request_options=request_options)
@@ -1579,11 +1843,23 @@ async def update_settings_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.update_settings_by_id(entity_id='ea837e28-509b-4b6a-a600-d54b6aa0b1f5', )
+ await client.entities.update_settings_by_id(
+ entity_id="ea837e28-509b-4b6a-a600-d54b6aa0b1f5",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_settings_by_id(
@@ -1659,11 +1935,21 @@ async def upload_onboarding_documents(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.entities.upload_onboarding_documents()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.upload_onboarding_documents(
@@ -1700,11 +1986,21 @@ async def get_onboarding_requirements(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.entities.get_onboarding_requirements()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_onboarding_requirements(request_options=request_options)
diff --git a/src/monite/entities/onboarding_data/client.py b/src/monite/entities/onboarding_data/client.py
index 407aa34..c4f61c8 100644
--- a/src/monite/entities/onboarding_data/client.py
+++ b/src/monite/entities/onboarding_data/client.py
@@ -48,8 +48,15 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.onboarding_data.get(entity_id='entity_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.onboarding_data.get(
+ entity_id="entity_id",
+ )
"""
_response = self._raw_client.get(entity_id, request_options=request_options)
return _response.data
@@ -88,8 +95,15 @@ def update(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.onboarding_data.update(entity_id='entity_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.onboarding_data.update(
+ entity_id="entity_id",
+ )
"""
_response = self._raw_client.update(
entity_id,
@@ -134,11 +148,23 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.onboarding_data.get(entity_id='entity_id', )
+ await client.entities.onboarding_data.get(
+ entity_id="entity_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(entity_id, request_options=request_options)
@@ -177,11 +203,23 @@ async def update(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.onboarding_data.update(entity_id='entity_id', )
+ await client.entities.onboarding_data.update(
+ entity_id="entity_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update(
diff --git a/src/monite/entities/payment_methods/client.py b/src/monite/entities/payment_methods/client.py
index 682674a..5ae0a11 100644
--- a/src/monite/entities/payment_methods/client.py
+++ b/src/monite/entities/payment_methods/client.py
@@ -48,8 +48,15 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.payment_methods.get(entity_id='entity_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.payment_methods.get(
+ entity_id="entity_id",
+ )
"""
_response = self._raw_client.get(entity_id, request_options=request_options)
return _response.data
@@ -90,8 +97,15 @@ def set(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.payment_methods.set(entity_id='entity_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.payment_methods.set(
+ entity_id="entity_id",
+ )
"""
_response = self._raw_client.set(
entity_id,
@@ -138,11 +152,23 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.payment_methods.get(entity_id='entity_id', )
+ await client.entities.payment_methods.get(
+ entity_id="entity_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(entity_id, request_options=request_options)
@@ -183,11 +209,23 @@ async def set(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.payment_methods.set(entity_id='entity_id', )
+ await client.entities.payment_methods.set(
+ entity_id="entity_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.set(
diff --git a/src/monite/entities/persons/client.py b/src/monite/entities/persons/client.py
index 65762dc..1e222b9 100644
--- a/src/monite/entities/persons/client.py
+++ b/src/monite/entities/persons/client.py
@@ -47,7 +47,12 @@ def get(self, *, request_options: typing.Optional[RequestOptions] = None) -> Per
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.entities.persons.get()
"""
_response = self._raw_client.get(request_options=request_options)
@@ -111,10 +116,19 @@ def create(
Examples
--------
- from monite import Monite
- from monite import PersonRelationshipRequest
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.persons.create(email='email', first_name='first_name', last_name='last_name', relationship=PersonRelationshipRequest(), )
+ from monite import Monite, PersonRelationshipRequest
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.persons.create(
+ email="email",
+ first_name="first_name",
+ last_name="last_name",
+ relationship=PersonRelationshipRequest(),
+ )
"""
_response = self._raw_client.create(
email=email,
@@ -148,8 +162,15 @@ def get_by_id(self, person_id: str, *, request_options: typing.Optional[RequestO
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.persons.get_by_id(person_id='person_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.persons.get_by_id(
+ person_id="person_id",
+ )
"""
_response = self._raw_client.get_by_id(person_id, request_options=request_options)
return _response.data
@@ -170,8 +191,15 @@ def delete_by_id(self, person_id: str, *, request_options: typing.Optional[Reque
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.persons.delete_by_id(person_id='person_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.persons.delete_by_id(
+ person_id="person_id",
+ )
"""
_response = self._raw_client.delete_by_id(person_id, request_options=request_options)
return _response.data
@@ -238,8 +266,15 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.persons.update_by_id(person_id='person_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.persons.update_by_id(
+ person_id="person_id",
+ )
"""
_response = self._raw_client.update_by_id(
person_id,
@@ -292,8 +327,15 @@ def upload_onboarding_documents(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.persons.upload_onboarding_documents(person_id='person_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.persons.upload_onboarding_documents(
+ person_id="person_id",
+ )
"""
_response = self._raw_client.upload_onboarding_documents(
person_id,
@@ -335,11 +377,21 @@ async def get(self, *, request_options: typing.Optional[RequestOptions] = None)
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.entities.persons.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(request_options=request_options)
@@ -403,12 +455,26 @@ async def create(
Examples
--------
- from monite import AsyncMonite
- from monite import PersonRelationshipRequest
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite, PersonRelationshipRequest
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.persons.create(email='email', first_name='first_name', last_name='last_name', relationship=PersonRelationshipRequest(), )
+ await client.entities.persons.create(
+ email="email",
+ first_name="first_name",
+ last_name="last_name",
+ relationship=PersonRelationshipRequest(),
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -444,11 +510,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.persons.get_by_id(person_id='person_id', )
+ await client.entities.persons.get_by_id(
+ person_id="person_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(person_id, request_options=request_options)
@@ -469,11 +547,23 @@ async def delete_by_id(self, person_id: str, *, request_options: typing.Optional
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.persons.delete_by_id(person_id='person_id', )
+ await client.entities.persons.delete_by_id(
+ person_id="person_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(person_id, request_options=request_options)
@@ -540,11 +630,23 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.persons.update_by_id(person_id='person_id', )
+ await client.entities.persons.update_by_id(
+ person_id="person_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
@@ -597,11 +699,23 @@ async def upload_onboarding_documents(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.persons.upload_onboarding_documents(person_id='person_id', )
+ await client.entities.persons.upload_onboarding_documents(
+ person_id="person_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.upload_onboarding_documents(
diff --git a/src/monite/entities/raw_client.py b/src/monite/entities/raw_client.py
index b509b1b..d26b71f 100644
--- a/src/monite/entities/raw_client.py
+++ b/src/monite/entities/raw_client.py
@@ -333,6 +333,17 @@ def create(
),
),
)
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -734,6 +745,17 @@ def update_by_id(
),
),
)
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -806,6 +828,17 @@ def post_entities_id_activate(
),
),
)
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -878,6 +911,17 @@ def post_entities_id_deactivate(
),
),
)
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -934,11 +978,9 @@ def upload_logo_by_id(
files={
"file": file,
},
- headers={
- "content-type": "multipart/form-data",
- },
request_options=request_options,
omit=OMIT,
+ force_multipart=True,
)
try:
if 200 <= _response.status_code < 300:
@@ -1867,6 +1909,17 @@ async def create(
),
),
)
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -2268,6 +2321,17 @@ async def update_by_id(
),
),
)
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -2340,6 +2404,17 @@ async def post_entities_id_activate(
),
),
)
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -2412,6 +2487,17 @@ async def post_entities_id_deactivate(
),
),
)
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -2468,11 +2554,9 @@ async def upload_logo_by_id(
files={
"file": file,
},
- headers={
- "content-type": "multipart/form-data",
- },
request_options=request_options,
omit=OMIT,
+ force_multipart=True,
)
try:
if 200 <= _response.status_code < 300:
diff --git a/src/monite/entities/vat_ids/client.py b/src/monite/entities/vat_ids/client.py
index dbc786d..d180fd3 100644
--- a/src/monite/entities/vat_ids/client.py
+++ b/src/monite/entities/vat_ids/client.py
@@ -48,8 +48,15 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.vat_ids.get(entity_id='entity_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.vat_ids.get(
+ entity_id="entity_id",
+ )
"""
_response = self._raw_client.get(entity_id, request_options=request_options)
return _response.data
@@ -85,8 +92,17 @@ def create(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.vat_ids.create(entity_id='entity_id', country="AF", value='123456789', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.vat_ids.create(
+ entity_id="entity_id",
+ country="AF",
+ value="123456789",
+ )
"""
_response = self._raw_client.create(
entity_id, country=country, value=value, type=type, request_options=request_options
@@ -114,8 +130,16 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.vat_ids.get_by_id(id='id', entity_id='entity_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.vat_ids.get_by_id(
+ id="id",
+ entity_id="entity_id",
+ )
"""
_response = self._raw_client.get_by_id(id, entity_id, request_options=request_options)
return _response.data
@@ -138,8 +162,16 @@ def delete_by_id(self, id: str, entity_id: str, *, request_options: typing.Optio
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.vat_ids.delete_by_id(id='id', entity_id='entity_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.vat_ids.delete_by_id(
+ id="id",
+ entity_id="entity_id",
+ )
"""
_response = self._raw_client.delete_by_id(id, entity_id, request_options=request_options)
return _response.data
@@ -178,8 +210,16 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entities.vat_ids.update_by_id(id='id', entity_id='entity_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entities.vat_ids.update_by_id(
+ id="id",
+ entity_id="entity_id",
+ )
"""
_response = self._raw_client.update_by_id(
id, entity_id, country=country, type=type, value=value, request_options=request_options
@@ -220,11 +260,23 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.vat_ids.get(entity_id='entity_id', )
+ await client.entities.vat_ids.get(
+ entity_id="entity_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(entity_id, request_options=request_options)
@@ -260,11 +312,25 @@ async def create(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.vat_ids.create(entity_id='entity_id', country="AF", value='123456789', )
+ await client.entities.vat_ids.create(
+ entity_id="entity_id",
+ country="AF",
+ value="123456789",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -292,11 +358,24 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.vat_ids.get_by_id(id='id', entity_id='entity_id', )
+ await client.entities.vat_ids.get_by_id(
+ id="id",
+ entity_id="entity_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(id, entity_id, request_options=request_options)
@@ -321,11 +400,24 @@ async def delete_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.vat_ids.delete_by_id(id='id', entity_id='entity_id', )
+ await client.entities.vat_ids.delete_by_id(
+ id="id",
+ entity_id="entity_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(id, entity_id, request_options=request_options)
@@ -364,11 +456,24 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entities.vat_ids.update_by_id(id='id', entity_id='entity_id', )
+ await client.entities.vat_ids.update_by_id(
+ id="id",
+ entity_id="entity_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
diff --git a/src/monite/entity_users/client.py b/src/monite/entity_users/client.py
index 38c9219..8a92244 100644
--- a/src/monite/entity_users/client.py
+++ b/src/monite/entity_users/client.py
@@ -110,7 +110,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.entity_users.get()
"""
_response = self._raw_client.get(
@@ -182,8 +187,16 @@ def create(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entity_users.create(first_name='Casey', login='login', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entity_users.create(
+ first_name="Casey",
+ login="login",
+ )
"""
_response = self._raw_client.create(
first_name=first_name,
@@ -214,7 +227,12 @@ def get_current(self, *, request_options: typing.Optional[RequestOptions] = None
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.entity_users.get_current()
"""
_response = self._raw_client.get_current(request_options=request_options)
@@ -261,7 +279,12 @@ def update_current(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.entity_users.update_current()
"""
_response = self._raw_client.update_current(
@@ -291,7 +314,12 @@ def get_current_entity(self, *, request_options: typing.Optional[RequestOptions]
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.entity_users.get_current_entity()
"""
_response = self._raw_client.get_current_entity(request_options=request_options)
@@ -354,7 +382,12 @@ def update_current_entity(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.entity_users.update_current_entity()
"""
_response = self._raw_client.update_current_entity(
@@ -388,7 +421,12 @@ def get_current_role(self, *, request_options: typing.Optional[RequestOptions] =
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.entity_users.get_current_role()
"""
_response = self._raw_client.get_current_role(request_options=request_options)
@@ -415,8 +453,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entity_users.get_by_id(entity_user_id='entity_user_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entity_users.get_by_id(
+ entity_user_id="entity_user_id",
+ )
"""
_response = self._raw_client.get_by_id(entity_user_id, request_options=request_options)
return _response.data
@@ -437,8 +482,15 @@ def delete_by_id(self, entity_user_id: str, *, request_options: typing.Optional[
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entity_users.delete_by_id(entity_user_id='entity_user_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entity_users.delete_by_id(
+ entity_user_id="entity_user_id",
+ )
"""
_response = self._raw_client.delete_by_id(entity_user_id, request_options=request_options)
return _response.data
@@ -495,8 +547,15 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.entity_users.update_by_id(entity_user_id='entity_user_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.entity_users.update_by_id(
+ entity_user_id="entity_user_id",
+ )
"""
_response = self._raw_client.update_by_id(
entity_user_id,
@@ -601,11 +660,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.entity_users.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
@@ -676,11 +745,24 @@ async def create(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entity_users.create(first_name='Casey', login='login', )
+ await client.entity_users.create(
+ first_name="Casey",
+ login="login",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -711,11 +793,21 @@ async def get_current(self, *, request_options: typing.Optional[RequestOptions]
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.entity_users.get_current()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_current(request_options=request_options)
@@ -761,11 +853,21 @@ async def update_current(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.entity_users.update_current()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_current(
@@ -794,11 +896,21 @@ async def get_current_entity(self, *, request_options: typing.Optional[RequestOp
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.entity_users.get_current_entity()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_current_entity(request_options=request_options)
@@ -860,11 +972,21 @@ async def update_current_entity(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.entity_users.update_current_entity()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_current_entity(
@@ -897,11 +1019,21 @@ async def get_current_role(self, *, request_options: typing.Optional[RequestOpti
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.entity_users.get_current_role()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_current_role(request_options=request_options)
@@ -927,11 +1059,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entity_users.get_by_id(entity_user_id='entity_user_id', )
+ await client.entity_users.get_by_id(
+ entity_user_id="entity_user_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(entity_user_id, request_options=request_options)
@@ -954,11 +1098,23 @@ async def delete_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entity_users.delete_by_id(entity_user_id='entity_user_id', )
+ await client.entity_users.delete_by_id(
+ entity_user_id="entity_user_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(entity_user_id, request_options=request_options)
@@ -1015,11 +1171,23 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.entity_users.update_by_id(entity_user_id='entity_user_id', )
+ await client.entity_users.update_by_id(
+ entity_user_id="entity_user_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
diff --git a/src/monite/events/client.py b/src/monite/events/client.py
index b39f081..edfb195 100644
--- a/src/monite/events/client.py
+++ b/src/monite/events/client.py
@@ -86,7 +86,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.events.get()
"""
_response = self._raw_client.get(
@@ -123,8 +128,15 @@ def get_by_id(self, event_id: str, *, request_options: typing.Optional[RequestOp
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.events.get_by_id(event_id='event_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.events.get_by_id(
+ event_id="event_id",
+ )
"""
_response = self._raw_client.get_by_id(event_id, request_options=request_options)
return _response.data
@@ -202,11 +214,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.events.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
@@ -244,11 +266,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.events.get_by_id(event_id='event_id', )
+ await client.events.get_by_id(
+ event_id="event_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(event_id, request_options=request_options)
diff --git a/src/monite/files/client.py b/src/monite/files/client.py
index 2f92755..538c922 100644
--- a/src/monite/files/client.py
+++ b/src/monite/files/client.py
@@ -51,7 +51,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.files.get()
"""
_response = self._raw_client.get(id_in=id_in, request_options=request_options)
@@ -79,8 +84,15 @@ def upload(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.files.upload(file_type="ocr_results", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.files.upload(
+ file_type="ocr_results",
+ )
"""
_response = self._raw_client.upload(file=file, file_type=file_type, request_options=request_options)
return _response.data
@@ -102,8 +114,15 @@ def get_by_id(self, file_id: str, *, request_options: typing.Optional[RequestOpt
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.files.get_by_id(file_id='file_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.files.get_by_id(
+ file_id="file_id",
+ )
"""
_response = self._raw_client.get_by_id(file_id, request_options=request_options)
return _response.data
@@ -124,8 +143,15 @@ def delete(self, file_id: str, *, request_options: typing.Optional[RequestOption
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.files.delete(file_id='file_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.files.delete(
+ file_id="file_id",
+ )
"""
_response = self._raw_client.delete(file_id, request_options=request_options)
return _response.data
@@ -167,11 +193,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.files.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(id_in=id_in, request_options=request_options)
@@ -198,11 +234,23 @@ async def upload(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.files.upload(file_type="ocr_results", )
+ await client.files.upload(
+ file_type="ocr_results",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.upload(file=file, file_type=file_type, request_options=request_options)
@@ -224,11 +272,23 @@ async def get_by_id(self, file_id: str, *, request_options: typing.Optional[Requ
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.files.get_by_id(file_id='file_id', )
+ await client.files.get_by_id(
+ file_id="file_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(file_id, request_options=request_options)
@@ -249,11 +309,23 @@ async def delete(self, file_id: str, *, request_options: typing.Optional[Request
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.files.delete(file_id='file_id', )
+ await client.files.delete(
+ file_id="file_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete(file_id, request_options=request_options)
diff --git a/src/monite/files/raw_client.py b/src/monite/files/raw_client.py
index ef0dd8e..b1d561d 100644
--- a/src/monite/files/raw_client.py
+++ b/src/monite/files/raw_client.py
@@ -116,11 +116,9 @@ def upload(
files={
"file": file,
},
- headers={
- "content-type": "multipart/form-data",
- },
request_options=request_options,
omit=OMIT,
+ force_multipart=True,
)
try:
if 200 <= _response.status_code < 300:
@@ -362,11 +360,9 @@ async def upload(
files={
"file": file,
},
- headers={
- "content-type": "multipart/form-data",
- },
request_options=request_options,
omit=OMIT,
+ force_multipart=True,
)
try:
if 200 <= _response.status_code < 300:
diff --git a/src/monite/financing/client.py b/src/monite/financing/client.py
index a8e620b..790f105 100644
--- a/src/monite/financing/client.py
+++ b/src/monite/financing/client.py
@@ -75,16 +75,18 @@ def get_financing_invoices(
Parameters
----------
order : typing.Optional[OrderEnum]
- Order by
+ Sort order (ascending by default). Typically used together with the `sort` parameter.
limit : typing.Optional[int]
- Max is 100
+ The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
pagination_token : typing.Optional[str]
- A token, obtained from previous page. Prior over other filters
+ A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+
+ If not specified, the first page of results will be returned.
sort : typing.Optional[FinancingInvoiceCursorFields]
- Allowed sort fields
+ The field to sort the results by. Typically used together with the `order` parameter.
invoice_id : typing.Optional[str]
ID of a payable or receivable invoice.
@@ -172,7 +174,12 @@ def get_financing_invoices(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.financing.get_financing_invoices()
"""
_response = self._raw_client.get_financing_invoices(
@@ -233,10 +240,21 @@ def post_financing_invoices(
Examples
--------
- from monite import Monite
- from monite import FinancingPushInvoicesRequestInvoice
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.financing.post_financing_invoices(invoices=[FinancingPushInvoicesRequestInvoice(id='id', type="payable", )], )
+ from monite import FinancingPushInvoicesRequestInvoice, Monite
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.financing.post_financing_invoices(
+ invoices=[
+ FinancingPushInvoicesRequestInvoice(
+ id="id",
+ type="payable",
+ )
+ ],
+ )
"""
_response = self._raw_client.post_financing_invoices(invoices=invoices, request_options=request_options)
return _response.data
@@ -260,7 +278,12 @@ def get_financing_offers(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.financing.get_financing_offers()
"""
_response = self._raw_client.get_financing_offers(request_options=request_options)
@@ -285,7 +308,12 @@ def post_financing_tokens(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.financing.post_financing_tokens()
"""
_response = self._raw_client.post_financing_tokens(request_options=request_options)
@@ -347,16 +375,18 @@ async def get_financing_invoices(
Parameters
----------
order : typing.Optional[OrderEnum]
- Order by
+ Sort order (ascending by default). Typically used together with the `sort` parameter.
limit : typing.Optional[int]
- Max is 100
+ The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
pagination_token : typing.Optional[str]
- A token, obtained from previous page. Prior over other filters
+ A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+
+ If not specified, the first page of results will be returned.
sort : typing.Optional[FinancingInvoiceCursorFields]
- Allowed sort fields
+ The field to sort the results by. Typically used together with the `order` parameter.
invoice_id : typing.Optional[str]
ID of a payable or receivable invoice.
@@ -443,11 +473,21 @@ async def get_financing_invoices(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.financing.get_financing_invoices()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_financing_invoices(
@@ -508,12 +548,28 @@ async def post_financing_invoices(
Examples
--------
- from monite import AsyncMonite
- from monite import FinancingPushInvoicesRequestInvoice
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite, FinancingPushInvoicesRequestInvoice
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.financing.post_financing_invoices(invoices=[FinancingPushInvoicesRequestInvoice(id='id', type="payable", )], )
+ await client.financing.post_financing_invoices(
+ invoices=[
+ FinancingPushInvoicesRequestInvoice(
+ id="id",
+ type="payable",
+ )
+ ],
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.post_financing_invoices(invoices=invoices, request_options=request_options)
@@ -537,11 +593,21 @@ async def get_financing_offers(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.financing.get_financing_offers()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_financing_offers(request_options=request_options)
@@ -565,11 +631,21 @@ async def post_financing_tokens(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.financing.post_financing_tokens()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.post_financing_tokens(request_options=request_options)
diff --git a/src/monite/financing/raw_client.py b/src/monite/financing/raw_client.py
index 8245c5c..019f3ed 100644
--- a/src/monite/financing/raw_client.py
+++ b/src/monite/financing/raw_client.py
@@ -71,16 +71,18 @@ def get_financing_invoices(
Parameters
----------
order : typing.Optional[OrderEnum]
- Order by
+ Sort order (ascending by default). Typically used together with the `sort` parameter.
limit : typing.Optional[int]
- Max is 100
+ The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
pagination_token : typing.Optional[str]
- A token, obtained from previous page. Prior over other filters
+ A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+
+ If not specified, the first page of results will be returned.
sort : typing.Optional[FinancingInvoiceCursorFields]
- Allowed sort fields
+ The field to sort the results by. Typically used together with the `order` parameter.
invoice_id : typing.Optional[str]
ID of a payable or receivable invoice.
@@ -472,16 +474,18 @@ async def get_financing_invoices(
Parameters
----------
order : typing.Optional[OrderEnum]
- Order by
+ Sort order (ascending by default). Typically used together with the `sort` parameter.
limit : typing.Optional[int]
- Max is 100
+ The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
pagination_token : typing.Optional[str]
- A token, obtained from previous page. Prior over other filters
+ A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+
+ If not specified, the first page of results will be returned.
sort : typing.Optional[FinancingInvoiceCursorFields]
- Allowed sort fields
+ The field to sort the results by. Typically used together with the `order` parameter.
invoice_id : typing.Optional[str]
ID of a payable or receivable invoice.
diff --git a/src/monite/mail_templates/client.py b/src/monite/mail_templates/client.py
index 304b9e8..88baa9b 100644
--- a/src/monite/mail_templates/client.py
+++ b/src/monite/mail_templates/client.py
@@ -98,7 +98,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.mail_templates.get()
"""
_response = self._raw_client.get(
@@ -163,8 +168,18 @@ def create(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.mail_templates.create(body_template='body_template', name='name', subject_template='subject_template', type="receivables_quote", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.mail_templates.create(
+ body_template="body_template",
+ name="name",
+ subject_template="subject_template",
+ type="receivables_quote",
+ )
"""
_response = self._raw_client.create(
body_template=body_template,
@@ -214,8 +229,18 @@ def preview(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.mail_templates.preview(body='body', document_type="receivables_quote", language_code="ab", subject='subject', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.mail_templates.preview(
+ body="body",
+ document_type="receivables_quote",
+ language_code="ab",
+ subject="subject",
+ )
"""
_response = self._raw_client.preview(
body=body,
@@ -243,7 +268,12 @@ def get_system(self, *, request_options: typing.Optional[RequestOptions] = None)
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.mail_templates.get_system()
"""
_response = self._raw_client.get_system(request_options=request_options)
@@ -270,8 +300,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.mail_templates.get_by_id(template_id='template_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.mail_templates.get_by_id(
+ template_id="template_id",
+ )
"""
_response = self._raw_client.get_by_id(template_id, request_options=request_options)
return _response.data
@@ -294,8 +331,15 @@ def delete_by_id(self, template_id: str, *, request_options: typing.Optional[Req
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.mail_templates.delete_by_id(template_id='template_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.mail_templates.delete_by_id(
+ template_id="template_id",
+ )
"""
_response = self._raw_client.delete_by_id(template_id, request_options=request_options)
return _response.data
@@ -340,8 +384,15 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.mail_templates.update_by_id(template_id='template_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.mail_templates.update_by_id(
+ template_id="template_id",
+ )
"""
_response = self._raw_client.update_by_id(
template_id,
@@ -374,8 +425,15 @@ def make_default_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.mail_templates.make_default_by_id(template_id='template_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.mail_templates.make_default_by_id(
+ template_id="template_id",
+ )
"""
_response = self._raw_client.make_default_by_id(template_id, request_options=request_options)
return _response.data
@@ -460,11 +518,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.mail_templates.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
@@ -528,11 +596,26 @@ async def create(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.mail_templates.create(body_template='body_template', name='name', subject_template='subject_template', type="receivables_quote", )
+ await client.mail_templates.create(
+ body_template="body_template",
+ name="name",
+ subject_template="subject_template",
+ type="receivables_quote",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -582,11 +665,26 @@ async def preview(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.mail_templates.preview(body='body', document_type="receivables_quote", language_code="ab", subject='subject', )
+ await client.mail_templates.preview(
+ body="body",
+ document_type="receivables_quote",
+ language_code="ab",
+ subject="subject",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.preview(
@@ -614,11 +712,21 @@ async def get_system(self, *, request_options: typing.Optional[RequestOptions] =
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.mail_templates.get_system()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_system(request_options=request_options)
@@ -644,11 +752,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.mail_templates.get_by_id(template_id='template_id', )
+ await client.mail_templates.get_by_id(
+ template_id="template_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(template_id, request_options=request_options)
@@ -671,11 +791,23 @@ async def delete_by_id(self, template_id: str, *, request_options: typing.Option
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.mail_templates.delete_by_id(template_id='template_id', )
+ await client.mail_templates.delete_by_id(
+ template_id="template_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(template_id, request_options=request_options)
@@ -720,11 +852,23 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.mail_templates.update_by_id(template_id='template_id', )
+ await client.mail_templates.update_by_id(
+ template_id="template_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
@@ -757,11 +901,23 @@ async def make_default_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.mail_templates.make_default_by_id(template_id='template_id', )
+ await client.mail_templates.make_default_by_id(
+ template_id="template_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.make_default_by_id(template_id, request_options=request_options)
diff --git a/src/monite/mailbox_domains/client.py b/src/monite/mailbox_domains/client.py
index 1d0cad8..0a2ee84 100644
--- a/src/monite/mailbox_domains/client.py
+++ b/src/monite/mailbox_domains/client.py
@@ -45,7 +45,12 @@ def get(self, *, request_options: typing.Optional[RequestOptions] = None) -> Dom
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.mailbox_domains.get()
"""
_response = self._raw_client.get(request_options=request_options)
@@ -71,8 +76,15 @@ def create(self, *, domain: str, request_options: typing.Optional[RequestOptions
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.mailbox_domains.create(domain='domain', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.mailbox_domains.create(
+ domain="domain",
+ )
"""
_response = self._raw_client.create(domain=domain, request_options=request_options)
return _response.data
@@ -95,8 +107,15 @@ def delete_by_id(self, domain_id: str, *, request_options: typing.Optional[Reque
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.mailbox_domains.delete_by_id(domain_id='domain_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.mailbox_domains.delete_by_id(
+ domain_id="domain_id",
+ )
"""
_response = self._raw_client.delete_by_id(domain_id, request_options=request_options)
return _response.data
@@ -122,8 +141,15 @@ def verify_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.mailbox_domains.verify_by_id(domain_id='domain_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.mailbox_domains.verify_by_id(
+ domain_id="domain_id",
+ )
"""
_response = self._raw_client.verify_by_id(domain_id, request_options=request_options)
return _response.data
@@ -160,11 +186,21 @@ async def get(self, *, request_options: typing.Optional[RequestOptions] = None)
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.mailbox_domains.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(request_options=request_options)
@@ -189,11 +225,23 @@ async def create(self, *, domain: str, request_options: typing.Optional[RequestO
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.mailbox_domains.create(domain='domain', )
+ await client.mailbox_domains.create(
+ domain="domain",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(domain=domain, request_options=request_options)
@@ -216,11 +264,23 @@ async def delete_by_id(self, domain_id: str, *, request_options: typing.Optional
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.mailbox_domains.delete_by_id(domain_id='domain_id', )
+ await client.mailbox_domains.delete_by_id(
+ domain_id="domain_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(domain_id, request_options=request_options)
@@ -246,11 +306,23 @@ async def verify_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.mailbox_domains.verify_by_id(domain_id='domain_id', )
+ await client.mailbox_domains.verify_by_id(
+ domain_id="domain_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.verify_by_id(domain_id, request_options=request_options)
diff --git a/src/monite/mailboxes/client.py b/src/monite/mailboxes/client.py
index 0e4cc57..62dc066 100644
--- a/src/monite/mailboxes/client.py
+++ b/src/monite/mailboxes/client.py
@@ -44,7 +44,12 @@ def get(self, *, request_options: typing.Optional[RequestOptions] = None) -> Mai
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.mailboxes.get()
"""
_response = self._raw_client.get(request_options=request_options)
@@ -73,8 +78,16 @@ def create(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.mailboxes.create(mailbox_domain_id='mailbox_domain_id', mailbox_name='mailbox_name', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.mailboxes.create(
+ mailbox_domain_id="mailbox_domain_id",
+ mailbox_name="mailbox_name",
+ )
"""
_response = self._raw_client.create(
mailbox_domain_id=mailbox_domain_id, mailbox_name=mailbox_name, request_options=request_options
@@ -102,8 +115,15 @@ def search(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.mailboxes.search(entity_ids=['entity_ids'], )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.mailboxes.search(
+ entity_ids=["entity_ids"],
+ )
"""
_response = self._raw_client.search(entity_ids=entity_ids, request_options=request_options)
return _response.data
@@ -126,8 +146,15 @@ def delete_by_id(self, mailbox_id: str, *, request_options: typing.Optional[Requ
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.mailboxes.delete_by_id(mailbox_id='mailbox_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.mailboxes.delete_by_id(
+ mailbox_id="mailbox_id",
+ )
"""
_response = self._raw_client.delete_by_id(mailbox_id, request_options=request_options)
return _response.data
@@ -164,11 +191,21 @@ async def get(self, *, request_options: typing.Optional[RequestOptions] = None)
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.mailboxes.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(request_options=request_options)
@@ -196,11 +233,24 @@ async def create(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.mailboxes.create(mailbox_domain_id='mailbox_domain_id', mailbox_name='mailbox_name', )
+ await client.mailboxes.create(
+ mailbox_domain_id="mailbox_domain_id",
+ mailbox_name="mailbox_name",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -228,11 +278,23 @@ async def search(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.mailboxes.search(entity_ids=['entity_ids'], )
+ await client.mailboxes.search(
+ entity_ids=["entity_ids"],
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.search(entity_ids=entity_ids, request_options=request_options)
@@ -255,11 +317,23 @@ async def delete_by_id(self, mailbox_id: str, *, request_options: typing.Optiona
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.mailboxes.delete_by_id(mailbox_id='mailbox_id', )
+ await client.mailboxes.delete_by_id(
+ mailbox_id="mailbox_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(mailbox_id, request_options=request_options)
diff --git a/src/monite/measure_units/client.py b/src/monite/measure_units/client.py
index c69edaa..6efa82e 100644
--- a/src/monite/measure_units/client.py
+++ b/src/monite/measure_units/client.py
@@ -42,7 +42,12 @@ def get(self, *, request_options: typing.Optional[RequestOptions] = None) -> Uni
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.measure_units.get()
"""
_response = self._raw_client.get(request_options=request_options)
@@ -73,8 +78,15 @@ def create(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.measure_units.create(name='name', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.measure_units.create(
+ name="name",
+ )
"""
_response = self._raw_client.create(name=name, description=description, request_options=request_options)
return _response.data
@@ -96,8 +108,15 @@ def get_by_id(self, unit_id: str, *, request_options: typing.Optional[RequestOpt
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.measure_units.get_by_id(unit_id='unit_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.measure_units.get_by_id(
+ unit_id="unit_id",
+ )
"""
_response = self._raw_client.get_by_id(unit_id, request_options=request_options)
return _response.data
@@ -118,8 +137,15 @@ def delete_by_id(self, unit_id: str, *, request_options: typing.Optional[Request
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.measure_units.delete_by_id(unit_id='unit_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.measure_units.delete_by_id(
+ unit_id="unit_id",
+ )
"""
_response = self._raw_client.delete_by_id(unit_id, request_options=request_options)
return _response.data
@@ -152,8 +178,15 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.measure_units.update_by_id(unit_id='unit_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.measure_units.update_by_id(
+ unit_id="unit_id",
+ )
"""
_response = self._raw_client.update_by_id(
unit_id, description=description, name=name, request_options=request_options
@@ -190,11 +223,21 @@ async def get(self, *, request_options: typing.Optional[RequestOptions] = None)
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.measure_units.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(request_options=request_options)
@@ -224,11 +267,23 @@ async def create(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.measure_units.create(name='name', )
+ await client.measure_units.create(
+ name="name",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(name=name, description=description, request_options=request_options)
@@ -250,11 +305,23 @@ async def get_by_id(self, unit_id: str, *, request_options: typing.Optional[Requ
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.measure_units.get_by_id(unit_id='unit_id', )
+ await client.measure_units.get_by_id(
+ unit_id="unit_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(unit_id, request_options=request_options)
@@ -275,11 +342,23 @@ async def delete_by_id(self, unit_id: str, *, request_options: typing.Optional[R
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.measure_units.delete_by_id(unit_id='unit_id', )
+ await client.measure_units.delete_by_id(
+ unit_id="unit_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(unit_id, request_options=request_options)
@@ -312,11 +391,23 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.measure_units.update_by_id(unit_id='unit_id', )
+ await client.measure_units.update_by_id(
+ unit_id="unit_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
diff --git a/src/monite/ocr/client.py b/src/monite/ocr/client.py
index bf40ddc..6121f84 100644
--- a/src/monite/ocr/client.py
+++ b/src/monite/ocr/client.py
@@ -100,7 +100,12 @@ def get_ocr_tasks(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.ocr.get_ocr_tasks()
"""
_response = self._raw_client.get_ocr_tasks(
@@ -144,8 +149,15 @@ def post_ocr_tasks(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.ocr.post_ocr_tasks(file_url='file_url', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.ocr.post_ocr_tasks(
+ file_url="file_url",
+ )
"""
_response = self._raw_client.post_ocr_tasks(
file_url=file_url, document_type=document_type, request_options=request_options
@@ -178,7 +190,12 @@ def post_ocr_tasks_upload_from_file(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.ocr.post_ocr_tasks_upload_from_file()
"""
_response = self._raw_client.post_ocr_tasks_upload_from_file(
@@ -205,8 +222,15 @@ def get_ocr_tasks_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.ocr.get_ocr_tasks_id(task_id='task_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.ocr.get_ocr_tasks_id(
+ task_id="task_id",
+ )
"""
_response = self._raw_client.get_ocr_tasks_id(task_id, request_options=request_options)
return _response.data
@@ -293,11 +317,21 @@ async def get_ocr_tasks(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.ocr.get_ocr_tasks()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_ocr_tasks(
@@ -340,11 +374,23 @@ async def post_ocr_tasks(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.ocr.post_ocr_tasks(file_url='file_url', )
+ await client.ocr.post_ocr_tasks(
+ file_url="file_url",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.post_ocr_tasks(
@@ -377,11 +423,21 @@ async def post_ocr_tasks_upload_from_file(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.ocr.post_ocr_tasks_upload_from_file()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.post_ocr_tasks_upload_from_file(
@@ -407,11 +463,23 @@ async def get_ocr_tasks_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.ocr.get_ocr_tasks_id(task_id='task_id', )
+ await client.ocr.get_ocr_tasks_id(
+ task_id="task_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_ocr_tasks_id(task_id, request_options=request_options)
diff --git a/src/monite/ocr/raw_client.py b/src/monite/ocr/raw_client.py
index 9d07817..f8797ca 100644
--- a/src/monite/ocr/raw_client.py
+++ b/src/monite/ocr/raw_client.py
@@ -325,11 +325,9 @@ def post_ocr_tasks_upload_from_file(
files={
"file": file,
},
- headers={
- "content-type": "multipart/form-data",
- },
request_options=request_options,
omit=OMIT,
+ force_multipart=True,
)
try:
if 200 <= _response.status_code < 300:
@@ -765,11 +763,9 @@ async def post_ocr_tasks_upload_from_file(
files={
"file": file,
},
- headers={
- "content-type": "multipart/form-data",
- },
request_options=request_options,
omit=OMIT,
+ force_multipart=True,
)
try:
if 200 <= _response.status_code < 300:
diff --git a/src/monite/overdue_reminders/client.py b/src/monite/overdue_reminders/client.py
index 8b805c7..aaba378 100644
--- a/src/monite/overdue_reminders/client.py
+++ b/src/monite/overdue_reminders/client.py
@@ -44,7 +44,12 @@ def get(self, *, request_options: typing.Optional[RequestOptions] = None) -> All
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.overdue_reminders.get()
"""
_response = self._raw_client.get(request_options=request_options)
@@ -79,8 +84,15 @@ def create(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.overdue_reminders.create(name='name', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.overdue_reminders.create(
+ name="name",
+ )
"""
_response = self._raw_client.create(
name=name, recipients=recipients, terms=terms, request_options=request_options
@@ -106,8 +118,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.overdue_reminders.get_by_id(overdue_reminder_id='overdue_reminder_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.overdue_reminders.get_by_id(
+ overdue_reminder_id="overdue_reminder_id",
+ )
"""
_response = self._raw_client.get_by_id(overdue_reminder_id, request_options=request_options)
return _response.data
@@ -130,8 +149,15 @@ def delete_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.overdue_reminders.delete_by_id(overdue_reminder_id='overdue_reminder_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.overdue_reminders.delete_by_id(
+ overdue_reminder_id="overdue_reminder_id",
+ )
"""
_response = self._raw_client.delete_by_id(overdue_reminder_id, request_options=request_options)
return _response.data
@@ -168,8 +194,15 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.overdue_reminders.update_by_id(overdue_reminder_id='overdue_reminder_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.overdue_reminders.update_by_id(
+ overdue_reminder_id="overdue_reminder_id",
+ )
"""
_response = self._raw_client.update_by_id(
overdue_reminder_id, name=name, recipients=recipients, terms=terms, request_options=request_options
@@ -206,11 +239,21 @@ async def get(self, *, request_options: typing.Optional[RequestOptions] = None)
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.overdue_reminders.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(request_options=request_options)
@@ -244,11 +287,23 @@ async def create(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.overdue_reminders.create(name='name', )
+ await client.overdue_reminders.create(
+ name="name",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -274,11 +329,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.overdue_reminders.get_by_id(overdue_reminder_id='overdue_reminder_id', )
+ await client.overdue_reminders.get_by_id(
+ overdue_reminder_id="overdue_reminder_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(overdue_reminder_id, request_options=request_options)
@@ -301,11 +368,23 @@ async def delete_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.overdue_reminders.delete_by_id(overdue_reminder_id='overdue_reminder_id', )
+ await client.overdue_reminders.delete_by_id(
+ overdue_reminder_id="overdue_reminder_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(overdue_reminder_id, request_options=request_options)
@@ -342,11 +421,23 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.overdue_reminders.update_by_id(overdue_reminder_id='overdue_reminder_id', )
+ await client.overdue_reminders.update_by_id(
+ overdue_reminder_id="overdue_reminder_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
diff --git a/src/monite/partner_settings/client.py b/src/monite/partner_settings/client.py
index d59eb61..5fa970a 100644
--- a/src/monite/partner_settings/client.py
+++ b/src/monite/partner_settings/client.py
@@ -50,7 +50,12 @@ def get(self, *, request_options: typing.Optional[RequestOptions] = None) -> Par
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.partner_settings.get()
"""
_response = self._raw_client.get(request_options=request_options)
@@ -116,7 +121,12 @@ def update(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.partner_settings.update()
"""
_response = self._raw_client.update(
@@ -168,11 +178,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.partner_settings.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(request_options=request_options)
@@ -237,11 +257,21 @@ async def update(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.partner_settings.update()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update(
diff --git a/src/monite/payables/client.py b/src/monite/payables/client.py
index e86562a..75e2670 100644
--- a/src/monite/payables/client.py
+++ b/src/monite/payables/client.py
@@ -12,6 +12,9 @@
from ..types.order_enum import OrderEnum
from ..types.payable_aggregated_data_response import PayableAggregatedDataResponse
from ..types.payable_cursor_fields import PayableCursorFields
+from ..types.payable_history_cursor_fields import PayableHistoryCursorFields
+from ..types.payable_history_event_type_enum import PayableHistoryEventTypeEnum
+from ..types.payable_history_pagination_response import PayableHistoryPaginationResponse
from ..types.payable_origin_enum import PayableOriginEnum
from ..types.payable_pagination_response import PayablePaginationResponse
from ..types.payable_payment_terms_create_payload import PayablePaymentTermsCreatePayload
@@ -98,6 +101,7 @@ def get(
project_id_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
tag_ids: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
tag_ids_not_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
+ has_tags: typing.Optional[bool] = None,
origin: typing.Optional[PayableOriginEnum] = None,
has_file: typing.Optional[bool] = None,
request_options: typing.Optional[RequestOptions] = None,
@@ -303,6 +307,9 @@ def get(
tag_ids_not_in : typing.Optional[typing.Union[str, typing.Sequence[str]]]
Return only payables whose `tags` do not include any of the tags with the specified IDs. Valid but nonexistent tag IDs do not raise errors but produce the results.
+ has_tags : typing.Optional[bool]
+ Filter objects based on whether they have tags. If true, only objects with tags are returned. If false, only objects without tags are returned.
+
origin : typing.Optional[PayableOriginEnum]
Return only payables from a given origin ['einvoice', 'upload', 'email']
@@ -320,7 +327,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.payables.get()
"""
_response = self._raw_client.get(
@@ -373,6 +385,7 @@ def get(
project_id_in=project_id_in,
tag_ids=tag_ids,
tag_ids_not_in=tag_ids_not_in,
+ has_tags=has_tags,
origin=origin,
has_file=has_file,
request_options=request_options,
@@ -500,7 +513,12 @@ def create(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.payables.create()
"""
_response = self._raw_client.create(
@@ -579,6 +597,7 @@ def get_analytics(
project_id_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
tag_ids: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
tag_ids_not_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
+ has_tags: typing.Optional[bool] = None,
origin: typing.Optional[PayableOriginEnum] = None,
has_file: typing.Optional[bool] = None,
request_options: typing.Optional[RequestOptions] = None,
@@ -741,6 +760,9 @@ def get_analytics(
tag_ids_not_in : typing.Optional[typing.Union[str, typing.Sequence[str]]]
Return only payables whose `tags` do not include any of the tags with the specified IDs. Valid but nonexistent tag IDs do not raise errors but produce the results.
+ has_tags : typing.Optional[bool]
+ Filter objects based on whether they have tags. If true, only objects with tags are returned. If false, only objects without tags are returned.
+
origin : typing.Optional[PayableOriginEnum]
Return only payables from a given origin ['einvoice', 'upload', 'email']
@@ -758,7 +780,12 @@ def get_analytics(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.payables.get_analytics()
"""
_response = self._raw_client.get_analytics(
@@ -807,6 +834,7 @@ def get_analytics(
project_id_in=project_id_in,
tag_ids=tag_ids,
tag_ids_not_in=tag_ids_not_in,
+ has_tags=has_tags,
origin=origin,
has_file=has_file,
request_options=request_options,
@@ -817,7 +845,7 @@ def upload_from_file(
self, *, file: core.File, request_options: typing.Optional[RequestOptions] = None
) -> PayableResponseSchema:
"""
- Upload an incoming invoice (payable) in PDF, PNG, JPEG, or TIFF format and scan its contents. The maximum file size is 10MB.
+ Upload an incoming invoice (payable) in PDF, PNG, or JPEG format and scan its contents. The maximum file size is 20MB.
Parameters
----------
@@ -835,7 +863,12 @@ def upload_from_file(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.payables.upload_from_file()
"""
_response = self._raw_client.upload_from_file(file=file, request_options=request_options)
@@ -858,7 +891,12 @@ def get_validations(self, *, request_options: typing.Optional[RequestOptions] =
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.payables.get_validations()
"""
_response = self._raw_client.get_validations(request_options=request_options)
@@ -888,8 +926,15 @@ def update_validations(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payables.update_validations(required_fields=["currency"], )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payables.update_validations(
+ required_fields=["currency"],
+ )
"""
_response = self._raw_client.update_validations(
required_fields=required_fields, request_options=request_options
@@ -915,7 +960,12 @@ def reset_validations(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.payables.reset_validations()
"""
_response = self._raw_client.reset_validations(request_options=request_options)
@@ -940,7 +990,12 @@ def get_variables(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.payables.get_variables()
"""
_response = self._raw_client.get_variables(request_options=request_options)
@@ -967,8 +1022,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payables.get_by_id(payable_id='payable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payables.get_by_id(
+ payable_id="payable_id",
+ )
"""
_response = self._raw_client.get_by_id(payable_id, request_options=request_options)
return _response.data
@@ -991,8 +1053,15 @@ def delete_by_id(self, payable_id: str, *, request_options: typing.Optional[Requ
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payables.delete_by_id(payable_id='payable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payables.delete_by_id(
+ payable_id="payable_id",
+ )
"""
_response = self._raw_client.delete_by_id(payable_id, request_options=request_options)
return _response.data
@@ -1109,8 +1178,15 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payables.update_by_id(payable_id='payable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payables.update_by_id(
+ payable_id="payable_id",
+ )
"""
_response = self._raw_client.update_by_id(
payable_id,
@@ -1161,8 +1237,15 @@ def approve_payment_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payables.approve_payment_by_id(payable_id='payable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payables.approve_payment_by_id(
+ payable_id="payable_id",
+ )
"""
_response = self._raw_client.approve_payment_by_id(payable_id, request_options=request_options)
return _response.data
@@ -1191,8 +1274,15 @@ def attach_file_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payables.attach_file_by_id(payable_id='payable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payables.attach_file_by_id(
+ payable_id="payable_id",
+ )
"""
_response = self._raw_client.attach_file_by_id(payable_id, file=file, request_options=request_options)
return _response.data
@@ -1218,8 +1308,15 @@ def cancel_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payables.cancel_by_id(payable_id='payable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payables.cancel_by_id(
+ payable_id="payable_id",
+ )
"""
_response = self._raw_client.cancel_by_id(payable_id, request_options=request_options)
return _response.data
@@ -1245,12 +1342,112 @@ def post_payables_id_cancel_ocr(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payables.post_payables_id_cancel_ocr(payable_id='payable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payables.post_payables_id_cancel_ocr(
+ payable_id="payable_id",
+ )
"""
_response = self._raw_client.post_payables_id_cancel_ocr(payable_id, request_options=request_options)
return _response.data
+ def get_payables_id_history(
+ self,
+ payable_id: str,
+ *,
+ order: typing.Optional[OrderEnum] = None,
+ limit: typing.Optional[int] = None,
+ pagination_token: typing.Optional[str] = None,
+ sort: typing.Optional[PayableHistoryCursorFields] = None,
+ event_type_in: typing.Optional[
+ typing.Union[PayableHistoryEventTypeEnum, typing.Sequence[PayableHistoryEventTypeEnum]]
+ ] = None,
+ entity_user_id_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
+ timestamp_gt: typing.Optional[dt.datetime] = None,
+ timestamp_lt: typing.Optional[dt.datetime] = None,
+ timestamp_gte: typing.Optional[dt.datetime] = None,
+ timestamp_lte: typing.Optional[dt.datetime] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> PayableHistoryPaginationResponse:
+ """
+ Parameters
+ ----------
+ payable_id : str
+
+ order : typing.Optional[OrderEnum]
+ Sort order (ascending by default). Typically used together with the `sort` parameter.
+
+ limit : typing.Optional[int]
+ The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+
+ pagination_token : typing.Optional[str]
+ A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+
+ If not specified, the first page of results will be returned.
+
+ sort : typing.Optional[PayableHistoryCursorFields]
+ The field to sort the results by. Typically used together with the `order` parameter.
+
+ event_type_in : typing.Optional[typing.Union[PayableHistoryEventTypeEnum, typing.Sequence[PayableHistoryEventTypeEnum]]]
+ Return only the specified event types
+
+ entity_user_id_in : typing.Optional[typing.Union[str, typing.Sequence[str]]]
+ Return only events caused by the entity users with the specified IDs. To specify multiple user IDs, repeat this parameter for each ID:
+ `entity_user_id__in=&entity_user_id__in=`
+
+ timestamp_gt : typing.Optional[dt.datetime]
+ Return only events that occurred after the specified date and time. The value must be in the ISO 8601 format `YYYY-MM-DDThh:mm[:ss[.ffffff]][Z|±hh:mm]`.
+
+ timestamp_lt : typing.Optional[dt.datetime]
+ Return only events that occurred before the specified date and time.
+
+ timestamp_gte : typing.Optional[dt.datetime]
+ Return only events that occurred on or after the specified date and time.
+
+ timestamp_lte : typing.Optional[dt.datetime]
+ Return only events that occurred before or on the specified date and time.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ PayableHistoryPaginationResponse
+ Successful Response
+
+ Examples
+ --------
+ from monite import Monite
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payables.get_payables_id_history(
+ payable_id="payable_id",
+ )
+ """
+ _response = self._raw_client.get_payables_id_history(
+ payable_id,
+ order=order,
+ limit=limit,
+ pagination_token=pagination_token,
+ sort=sort,
+ event_type_in=event_type_in,
+ entity_user_id_in=entity_user_id_in,
+ timestamp_gt=timestamp_gt,
+ timestamp_lt=timestamp_lt,
+ timestamp_gte=timestamp_gte,
+ timestamp_lte=timestamp_lte,
+ request_options=request_options,
+ )
+ return _response.data
+
def mark_as_paid_by_id(
self,
payable_id: str,
@@ -1300,8 +1497,15 @@ def mark_as_paid_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payables.mark_as_paid_by_id(payable_id='payable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payables.mark_as_paid_by_id(
+ payable_id="payable_id",
+ )
"""
_response = self._raw_client.mark_as_paid_by_id(payable_id, comment=comment, request_options=request_options)
return _response.data
@@ -1353,8 +1557,16 @@ def mark_as_partially_paid_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payables.mark_as_partially_paid_by_id(payable_id='payable_id', amount_paid=1, )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payables.mark_as_partially_paid_by_id(
+ payable_id="payable_id",
+ amount_paid=1,
+ )
"""
_response = self._raw_client.mark_as_partially_paid_by_id(
payable_id, amount_paid=amount_paid, request_options=request_options
@@ -1382,8 +1594,15 @@ def reject_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payables.reject_by_id(payable_id='payable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payables.reject_by_id(
+ payable_id="payable_id",
+ )
"""
_response = self._raw_client.reject_by_id(payable_id, request_options=request_options)
return _response.data
@@ -1409,8 +1628,15 @@ def reopen_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payables.reopen_by_id(payable_id='payable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payables.reopen_by_id(
+ payable_id="payable_id",
+ )
"""
_response = self._raw_client.reopen_by_id(payable_id, request_options=request_options)
return _response.data
@@ -1436,8 +1662,15 @@ def submit_for_approval_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payables.submit_for_approval_by_id(payable_id='payable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payables.submit_for_approval_by_id(
+ payable_id="payable_id",
+ )
"""
_response = self._raw_client.submit_for_approval_by_id(payable_id, request_options=request_options)
return _response.data
@@ -1463,8 +1696,15 @@ def validate_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payables.validate_by_id(payable_id='payable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payables.validate_by_id(
+ payable_id="payable_id",
+ )
"""
_response = self._raw_client.validate_by_id(payable_id, request_options=request_options)
return _response.data
@@ -1538,6 +1778,7 @@ async def get(
project_id_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
tag_ids: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
tag_ids_not_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
+ has_tags: typing.Optional[bool] = None,
origin: typing.Optional[PayableOriginEnum] = None,
has_file: typing.Optional[bool] = None,
request_options: typing.Optional[RequestOptions] = None,
@@ -1743,6 +1984,9 @@ async def get(
tag_ids_not_in : typing.Optional[typing.Union[str, typing.Sequence[str]]]
Return only payables whose `tags` do not include any of the tags with the specified IDs. Valid but nonexistent tag IDs do not raise errors but produce the results.
+ has_tags : typing.Optional[bool]
+ Filter objects based on whether they have tags. If true, only objects with tags are returned. If false, only objects without tags are returned.
+
origin : typing.Optional[PayableOriginEnum]
Return only payables from a given origin ['einvoice', 'upload', 'email']
@@ -1759,11 +2003,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.payables.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
@@ -1816,6 +2070,7 @@ async def main() -> None:
project_id_in=project_id_in,
tag_ids=tag_ids,
tag_ids_not_in=tag_ids_not_in,
+ has_tags=has_tags,
origin=origin,
has_file=has_file,
request_options=request_options,
@@ -1942,11 +2197,21 @@ async def create(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.payables.create()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -2025,6 +2290,7 @@ async def get_analytics(
project_id_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
tag_ids: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
tag_ids_not_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
+ has_tags: typing.Optional[bool] = None,
origin: typing.Optional[PayableOriginEnum] = None,
has_file: typing.Optional[bool] = None,
request_options: typing.Optional[RequestOptions] = None,
@@ -2187,6 +2453,9 @@ async def get_analytics(
tag_ids_not_in : typing.Optional[typing.Union[str, typing.Sequence[str]]]
Return only payables whose `tags` do not include any of the tags with the specified IDs. Valid but nonexistent tag IDs do not raise errors but produce the results.
+ has_tags : typing.Optional[bool]
+ Filter objects based on whether they have tags. If true, only objects with tags are returned. If false, only objects without tags are returned.
+
origin : typing.Optional[PayableOriginEnum]
Return only payables from a given origin ['einvoice', 'upload', 'email']
@@ -2203,11 +2472,21 @@ async def get_analytics(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.payables.get_analytics()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_analytics(
@@ -2256,6 +2535,7 @@ async def main() -> None:
project_id_in=project_id_in,
tag_ids=tag_ids,
tag_ids_not_in=tag_ids_not_in,
+ has_tags=has_tags,
origin=origin,
has_file=has_file,
request_options=request_options,
@@ -2266,7 +2546,7 @@ async def upload_from_file(
self, *, file: core.File, request_options: typing.Optional[RequestOptions] = None
) -> PayableResponseSchema:
"""
- Upload an incoming invoice (payable) in PDF, PNG, JPEG, or TIFF format and scan its contents. The maximum file size is 10MB.
+ Upload an incoming invoice (payable) in PDF, PNG, or JPEG format and scan its contents. The maximum file size is 20MB.
Parameters
----------
@@ -2283,11 +2563,21 @@ async def upload_from_file(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.payables.upload_from_file()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.upload_from_file(file=file, request_options=request_options)
@@ -2311,11 +2601,21 @@ async def get_validations(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.payables.get_validations()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_validations(request_options=request_options)
@@ -2344,11 +2644,23 @@ async def update_validations(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payables.update_validations(required_fields=["currency"], )
+ await client.payables.update_validations(
+ required_fields=["currency"],
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_validations(
@@ -2374,11 +2686,21 @@ async def reset_validations(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.payables.reset_validations()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.reset_validations(request_options=request_options)
@@ -2402,11 +2724,21 @@ async def get_variables(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.payables.get_variables()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_variables(request_options=request_options)
@@ -2432,11 +2764,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payables.get_by_id(payable_id='payable_id', )
+ await client.payables.get_by_id(
+ payable_id="payable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(payable_id, request_options=request_options)
@@ -2459,11 +2803,23 @@ async def delete_by_id(self, payable_id: str, *, request_options: typing.Optiona
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payables.delete_by_id(payable_id='payable_id', )
+ await client.payables.delete_by_id(
+ payable_id="payable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(payable_id, request_options=request_options)
@@ -2580,11 +2936,23 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payables.update_by_id(payable_id='payable_id', )
+ await client.payables.update_by_id(
+ payable_id="payable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
@@ -2635,11 +3003,23 @@ async def approve_payment_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payables.approve_payment_by_id(payable_id='payable_id', )
+ await client.payables.approve_payment_by_id(
+ payable_id="payable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.approve_payment_by_id(payable_id, request_options=request_options)
@@ -2668,11 +3048,23 @@ async def attach_file_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payables.attach_file_by_id(payable_id='payable_id', )
+ await client.payables.attach_file_by_id(
+ payable_id="payable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.attach_file_by_id(payable_id, file=file, request_options=request_options)
@@ -2698,11 +3090,23 @@ async def cancel_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payables.cancel_by_id(payable_id='payable_id', )
+ await client.payables.cancel_by_id(
+ payable_id="payable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.cancel_by_id(payable_id, request_options=request_options)
@@ -2728,16 +3132,129 @@ async def post_payables_id_cancel_ocr(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payables.post_payables_id_cancel_ocr(payable_id='payable_id', )
+ await client.payables.post_payables_id_cancel_ocr(
+ payable_id="payable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.post_payables_id_cancel_ocr(payable_id, request_options=request_options)
return _response.data
+ async def get_payables_id_history(
+ self,
+ payable_id: str,
+ *,
+ order: typing.Optional[OrderEnum] = None,
+ limit: typing.Optional[int] = None,
+ pagination_token: typing.Optional[str] = None,
+ sort: typing.Optional[PayableHistoryCursorFields] = None,
+ event_type_in: typing.Optional[
+ typing.Union[PayableHistoryEventTypeEnum, typing.Sequence[PayableHistoryEventTypeEnum]]
+ ] = None,
+ entity_user_id_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
+ timestamp_gt: typing.Optional[dt.datetime] = None,
+ timestamp_lt: typing.Optional[dt.datetime] = None,
+ timestamp_gte: typing.Optional[dt.datetime] = None,
+ timestamp_lte: typing.Optional[dt.datetime] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> PayableHistoryPaginationResponse:
+ """
+ Parameters
+ ----------
+ payable_id : str
+
+ order : typing.Optional[OrderEnum]
+ Sort order (ascending by default). Typically used together with the `sort` parameter.
+
+ limit : typing.Optional[int]
+ The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+
+ pagination_token : typing.Optional[str]
+ A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+
+ If not specified, the first page of results will be returned.
+
+ sort : typing.Optional[PayableHistoryCursorFields]
+ The field to sort the results by. Typically used together with the `order` parameter.
+
+ event_type_in : typing.Optional[typing.Union[PayableHistoryEventTypeEnum, typing.Sequence[PayableHistoryEventTypeEnum]]]
+ Return only the specified event types
+
+ entity_user_id_in : typing.Optional[typing.Union[str, typing.Sequence[str]]]
+ Return only events caused by the entity users with the specified IDs. To specify multiple user IDs, repeat this parameter for each ID:
+ `entity_user_id__in=&entity_user_id__in=`
+
+ timestamp_gt : typing.Optional[dt.datetime]
+ Return only events that occurred after the specified date and time. The value must be in the ISO 8601 format `YYYY-MM-DDThh:mm[:ss[.ffffff]][Z|±hh:mm]`.
+
+ timestamp_lt : typing.Optional[dt.datetime]
+ Return only events that occurred before the specified date and time.
+
+ timestamp_gte : typing.Optional[dt.datetime]
+ Return only events that occurred on or after the specified date and time.
+
+ timestamp_lte : typing.Optional[dt.datetime]
+ Return only events that occurred before or on the specified date and time.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ PayableHistoryPaginationResponse
+ Successful Response
+
+ Examples
+ --------
+ import asyncio
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
+ async def main() -> None:
+ await client.payables.get_payables_id_history(
+ payable_id="payable_id",
+ )
+
+
+ asyncio.run(main())
+ """
+ _response = await self._raw_client.get_payables_id_history(
+ payable_id,
+ order=order,
+ limit=limit,
+ pagination_token=pagination_token,
+ sort=sort,
+ event_type_in=event_type_in,
+ entity_user_id_in=entity_user_id_in,
+ timestamp_gt=timestamp_gt,
+ timestamp_lt=timestamp_lt,
+ timestamp_gte=timestamp_gte,
+ timestamp_lte=timestamp_lte,
+ request_options=request_options,
+ )
+ return _response.data
+
async def mark_as_paid_by_id(
self,
payable_id: str,
@@ -2786,11 +3303,23 @@ async def mark_as_paid_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payables.mark_as_paid_by_id(payable_id='payable_id', )
+ await client.payables.mark_as_paid_by_id(
+ payable_id="payable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.mark_as_paid_by_id(
@@ -2844,11 +3373,24 @@ async def mark_as_partially_paid_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payables.mark_as_partially_paid_by_id(payable_id='payable_id', amount_paid=1, )
+ await client.payables.mark_as_partially_paid_by_id(
+ payable_id="payable_id",
+ amount_paid=1,
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.mark_as_partially_paid_by_id(
@@ -2876,11 +3418,23 @@ async def reject_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payables.reject_by_id(payable_id='payable_id', )
+ await client.payables.reject_by_id(
+ payable_id="payable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.reject_by_id(payable_id, request_options=request_options)
@@ -2906,11 +3460,23 @@ async def reopen_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payables.reopen_by_id(payable_id='payable_id', )
+ await client.payables.reopen_by_id(
+ payable_id="payable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.reopen_by_id(payable_id, request_options=request_options)
@@ -2936,11 +3502,23 @@ async def submit_for_approval_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payables.submit_for_approval_by_id(payable_id='payable_id', )
+ await client.payables.submit_for_approval_by_id(
+ payable_id="payable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.submit_for_approval_by_id(payable_id, request_options=request_options)
@@ -2966,11 +3544,23 @@ async def validate_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payables.validate_by_id(payable_id='payable_id', )
+ await client.payables.validate_by_id(
+ payable_id="payable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.validate_by_id(payable_id, request_options=request_options)
diff --git a/src/monite/payables/line_items/client.py b/src/monite/payables/line_items/client.py
index f08a761..fb1f82b 100644
--- a/src/monite/payables/line_items/client.py
+++ b/src/monite/payables/line_items/client.py
@@ -83,8 +83,15 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payables.line_items.get(payable_id='payable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payables.line_items.get(
+ payable_id="payable_id",
+ )
"""
_response = self._raw_client.get(
payable_id,
@@ -165,8 +172,15 @@ def create(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payables.line_items.create(payable_id='payable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payables.line_items.create(
+ payable_id="payable_id",
+ )
"""
_response = self._raw_client.create(
payable_id,
@@ -216,10 +230,17 @@ def replace(
Examples
--------
- from monite import Monite
- from monite import LineItemInternalRequest
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payables.line_items.replace(payable_id='payable_id', data=[LineItemInternalRequest()], )
+ from monite import LineItemInternalRequest, Monite
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payables.line_items.replace(
+ payable_id="payable_id",
+ data=[LineItemInternalRequest()],
+ )
"""
_response = self._raw_client.replace(payable_id, data=data, request_options=request_options)
return _response.data
@@ -255,8 +276,16 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payables.line_items.get_by_id(line_item_id='line_item_id', payable_id='payable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payables.line_items.get_by_id(
+ line_item_id="line_item_id",
+ payable_id="payable_id",
+ )
"""
_response = self._raw_client.get_by_id(line_item_id, payable_id, request_options=request_options)
return _response.data
@@ -291,8 +320,16 @@ def delete_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payables.line_items.delete_by_id(line_item_id='line_item_id', payable_id='payable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payables.line_items.delete_by_id(
+ line_item_id="line_item_id",
+ payable_id="payable_id",
+ )
"""
_response = self._raw_client.delete_by_id(line_item_id, payable_id, request_options=request_options)
return _response.data
@@ -364,8 +401,16 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payables.line_items.update_by_id(line_item_id='line_item_id', payable_id='payable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payables.line_items.update_by_id(
+ line_item_id="line_item_id",
+ payable_id="payable_id",
+ )
"""
_response = self._raw_client.update_by_id(
line_item_id,
@@ -449,11 +494,23 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payables.line_items.get(payable_id='payable_id', )
+ await client.payables.line_items.get(
+ payable_id="payable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
@@ -534,11 +591,23 @@ async def create(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payables.line_items.create(payable_id='payable_id', )
+ await client.payables.line_items.create(
+ payable_id="payable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -589,12 +658,24 @@ async def replace(
Examples
--------
- from monite import AsyncMonite
- from monite import LineItemInternalRequest
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite, LineItemInternalRequest
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payables.line_items.replace(payable_id='payable_id', data=[LineItemInternalRequest()], )
+ await client.payables.line_items.replace(
+ payable_id="payable_id",
+ data=[LineItemInternalRequest()],
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.replace(payable_id, data=data, request_options=request_options)
@@ -630,11 +711,24 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payables.line_items.get_by_id(line_item_id='line_item_id', payable_id='payable_id', )
+ await client.payables.line_items.get_by_id(
+ line_item_id="line_item_id",
+ payable_id="payable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(line_item_id, payable_id, request_options=request_options)
@@ -669,11 +763,24 @@ async def delete_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payables.line_items.delete_by_id(line_item_id='line_item_id', payable_id='payable_id', )
+ await client.payables.line_items.delete_by_id(
+ line_item_id="line_item_id",
+ payable_id="payable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(line_item_id, payable_id, request_options=request_options)
@@ -745,11 +852,24 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payables.line_items.update_by_id(line_item_id='line_item_id', payable_id='payable_id', )
+ await client.payables.line_items.update_by_id(
+ line_item_id="line_item_id",
+ payable_id="payable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
diff --git a/src/monite/payables/raw_client.py b/src/monite/payables/raw_client.py
index 5f8e421..51aca2e 100644
--- a/src/monite/payables/raw_client.py
+++ b/src/monite/payables/raw_client.py
@@ -27,6 +27,9 @@
from ..types.order_enum import OrderEnum
from ..types.payable_aggregated_data_response import PayableAggregatedDataResponse
from ..types.payable_cursor_fields import PayableCursorFields
+from ..types.payable_history_cursor_fields import PayableHistoryCursorFields
+from ..types.payable_history_event_type_enum import PayableHistoryEventTypeEnum
+from ..types.payable_history_pagination_response import PayableHistoryPaginationResponse
from ..types.payable_origin_enum import PayableOriginEnum
from ..types.payable_pagination_response import PayablePaginationResponse
from ..types.payable_payment_terms_create_payload import PayablePaymentTermsCreatePayload
@@ -99,6 +102,7 @@ def get(
project_id_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
tag_ids: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
tag_ids_not_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
+ has_tags: typing.Optional[bool] = None,
origin: typing.Optional[PayableOriginEnum] = None,
has_file: typing.Optional[bool] = None,
request_options: typing.Optional[RequestOptions] = None,
@@ -304,6 +308,9 @@ def get(
tag_ids_not_in : typing.Optional[typing.Union[str, typing.Sequence[str]]]
Return only payables whose `tags` do not include any of the tags with the specified IDs. Valid but nonexistent tag IDs do not raise errors but produce the results.
+ has_tags : typing.Optional[bool]
+ Filter objects based on whether they have tags. If true, only objects with tags are returned. If false, only objects without tags are returned.
+
origin : typing.Optional[PayableOriginEnum]
Return only payables from a given origin ['einvoice', 'upload', 'email']
@@ -371,6 +378,7 @@ def get(
"project_id__in": project_id_in,
"tag_ids": tag_ids,
"tag_ids__not_in": tag_ids_not_in,
+ "has_tags": has_tags,
"origin": origin,
"has_file": has_file,
},
@@ -731,6 +739,7 @@ def get_analytics(
project_id_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
tag_ids: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
tag_ids_not_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
+ has_tags: typing.Optional[bool] = None,
origin: typing.Optional[PayableOriginEnum] = None,
has_file: typing.Optional[bool] = None,
request_options: typing.Optional[RequestOptions] = None,
@@ -893,6 +902,9 @@ def get_analytics(
tag_ids_not_in : typing.Optional[typing.Union[str, typing.Sequence[str]]]
Return only payables whose `tags` do not include any of the tags with the specified IDs. Valid but nonexistent tag IDs do not raise errors but produce the results.
+ has_tags : typing.Optional[bool]
+ Filter objects based on whether they have tags. If true, only objects with tags are returned. If false, only objects without tags are returned.
+
origin : typing.Optional[PayableOriginEnum]
Return only payables from a given origin ['einvoice', 'upload', 'email']
@@ -956,6 +968,7 @@ def get_analytics(
"project_id__in": project_id_in,
"tag_ids": tag_ids,
"tag_ids__not_in": tag_ids_not_in,
+ "has_tags": has_tags,
"origin": origin,
"has_file": has_file,
},
@@ -1024,7 +1037,7 @@ def upload_from_file(
self, *, file: core.File, request_options: typing.Optional[RequestOptions] = None
) -> HttpResponse[PayableResponseSchema]:
"""
- Upload an incoming invoice (payable) in PDF, PNG, JPEG, or TIFF format and scan its contents. The maximum file size is 10MB.
+ Upload an incoming invoice (payable) in PDF, PNG, or JPEG format and scan its contents. The maximum file size is 20MB.
Parameters
----------
@@ -1046,11 +1059,9 @@ def upload_from_file(
files={
"file": file,
},
- headers={
- "content-type": "multipart/form-data",
- },
request_options=request_options,
omit=OMIT,
+ force_multipart=True,
)
try:
if 200 <= _response.status_code < 300:
@@ -2059,11 +2070,9 @@ def attach_file_by_id(
files={
"file": file,
},
- headers={
- "content-type": "multipart/form-data",
- },
request_options=request_options,
omit=OMIT,
+ force_multipart=True,
)
try:
if 200 <= _response.status_code < 300:
@@ -2376,6 +2385,168 @@ def post_payables_id_cancel_ocr(
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+ def get_payables_id_history(
+ self,
+ payable_id: str,
+ *,
+ order: typing.Optional[OrderEnum] = None,
+ limit: typing.Optional[int] = None,
+ pagination_token: typing.Optional[str] = None,
+ sort: typing.Optional[PayableHistoryCursorFields] = None,
+ event_type_in: typing.Optional[
+ typing.Union[PayableHistoryEventTypeEnum, typing.Sequence[PayableHistoryEventTypeEnum]]
+ ] = None,
+ entity_user_id_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
+ timestamp_gt: typing.Optional[dt.datetime] = None,
+ timestamp_lt: typing.Optional[dt.datetime] = None,
+ timestamp_gte: typing.Optional[dt.datetime] = None,
+ timestamp_lte: typing.Optional[dt.datetime] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[PayableHistoryPaginationResponse]:
+ """
+ Parameters
+ ----------
+ payable_id : str
+
+ order : typing.Optional[OrderEnum]
+ Sort order (ascending by default). Typically used together with the `sort` parameter.
+
+ limit : typing.Optional[int]
+ The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+
+ pagination_token : typing.Optional[str]
+ A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+
+ If not specified, the first page of results will be returned.
+
+ sort : typing.Optional[PayableHistoryCursorFields]
+ The field to sort the results by. Typically used together with the `order` parameter.
+
+ event_type_in : typing.Optional[typing.Union[PayableHistoryEventTypeEnum, typing.Sequence[PayableHistoryEventTypeEnum]]]
+ Return only the specified event types
+
+ entity_user_id_in : typing.Optional[typing.Union[str, typing.Sequence[str]]]
+ Return only events caused by the entity users with the specified IDs. To specify multiple user IDs, repeat this parameter for each ID:
+ `entity_user_id__in=&entity_user_id__in=`
+
+ timestamp_gt : typing.Optional[dt.datetime]
+ Return only events that occurred after the specified date and time. The value must be in the ISO 8601 format `YYYY-MM-DDThh:mm[:ss[.ffffff]][Z|±hh:mm]`.
+
+ timestamp_lt : typing.Optional[dt.datetime]
+ Return only events that occurred before the specified date and time.
+
+ timestamp_gte : typing.Optional[dt.datetime]
+ Return only events that occurred on or after the specified date and time.
+
+ timestamp_lte : typing.Optional[dt.datetime]
+ Return only events that occurred before or on the specified date and time.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[PayableHistoryPaginationResponse]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ f"payables/{jsonable_encoder(payable_id)}/history",
+ method="GET",
+ params={
+ "order": order,
+ "limit": limit,
+ "pagination_token": pagination_token,
+ "sort": sort,
+ "event_type__in": event_type_in,
+ "entity_user_id__in": entity_user_id_in,
+ "timestamp__gt": serialize_datetime(timestamp_gt) if timestamp_gt is not None else None,
+ "timestamp__lt": serialize_datetime(timestamp_lt) if timestamp_lt is not None else None,
+ "timestamp__gte": serialize_datetime(timestamp_gte) if timestamp_gte is not None else None,
+ "timestamp__lte": serialize_datetime(timestamp_lte) if timestamp_lte is not None else None,
+ },
+ request_options=request_options,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ PayableHistoryPaginationResponse,
+ parse_obj_as(
+ type_=PayableHistoryPaginationResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 400:
+ raise BadRequestError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 401:
+ raise UnauthorizedError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 500:
+ raise InternalServerError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ _response_json = _response.json()
+ except JSONDecodeError:
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
def mark_as_paid_by_id(
self,
payable_id: str,
@@ -3180,6 +3351,7 @@ async def get(
project_id_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
tag_ids: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
tag_ids_not_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
+ has_tags: typing.Optional[bool] = None,
origin: typing.Optional[PayableOriginEnum] = None,
has_file: typing.Optional[bool] = None,
request_options: typing.Optional[RequestOptions] = None,
@@ -3385,6 +3557,9 @@ async def get(
tag_ids_not_in : typing.Optional[typing.Union[str, typing.Sequence[str]]]
Return only payables whose `tags` do not include any of the tags with the specified IDs. Valid but nonexistent tag IDs do not raise errors but produce the results.
+ has_tags : typing.Optional[bool]
+ Filter objects based on whether they have tags. If true, only objects with tags are returned. If false, only objects without tags are returned.
+
origin : typing.Optional[PayableOriginEnum]
Return only payables from a given origin ['einvoice', 'upload', 'email']
@@ -3452,6 +3627,7 @@ async def get(
"project_id__in": project_id_in,
"tag_ids": tag_ids,
"tag_ids__not_in": tag_ids_not_in,
+ "has_tags": has_tags,
"origin": origin,
"has_file": has_file,
},
@@ -3812,6 +3988,7 @@ async def get_analytics(
project_id_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
tag_ids: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
tag_ids_not_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
+ has_tags: typing.Optional[bool] = None,
origin: typing.Optional[PayableOriginEnum] = None,
has_file: typing.Optional[bool] = None,
request_options: typing.Optional[RequestOptions] = None,
@@ -3974,6 +4151,9 @@ async def get_analytics(
tag_ids_not_in : typing.Optional[typing.Union[str, typing.Sequence[str]]]
Return only payables whose `tags` do not include any of the tags with the specified IDs. Valid but nonexistent tag IDs do not raise errors but produce the results.
+ has_tags : typing.Optional[bool]
+ Filter objects based on whether they have tags. If true, only objects with tags are returned. If false, only objects without tags are returned.
+
origin : typing.Optional[PayableOriginEnum]
Return only payables from a given origin ['einvoice', 'upload', 'email']
@@ -4037,6 +4217,7 @@ async def get_analytics(
"project_id__in": project_id_in,
"tag_ids": tag_ids,
"tag_ids__not_in": tag_ids_not_in,
+ "has_tags": has_tags,
"origin": origin,
"has_file": has_file,
},
@@ -4105,7 +4286,7 @@ async def upload_from_file(
self, *, file: core.File, request_options: typing.Optional[RequestOptions] = None
) -> AsyncHttpResponse[PayableResponseSchema]:
"""
- Upload an incoming invoice (payable) in PDF, PNG, JPEG, or TIFF format and scan its contents. The maximum file size is 10MB.
+ Upload an incoming invoice (payable) in PDF, PNG, or JPEG format and scan its contents. The maximum file size is 20MB.
Parameters
----------
@@ -4127,11 +4308,9 @@ async def upload_from_file(
files={
"file": file,
},
- headers={
- "content-type": "multipart/form-data",
- },
request_options=request_options,
omit=OMIT,
+ force_multipart=True,
)
try:
if 200 <= _response.status_code < 300:
@@ -5140,11 +5319,9 @@ async def attach_file_by_id(
files={
"file": file,
},
- headers={
- "content-type": "multipart/form-data",
- },
request_options=request_options,
omit=OMIT,
+ force_multipart=True,
)
try:
if 200 <= _response.status_code < 300:
@@ -5457,6 +5634,168 @@ async def post_payables_id_cancel_ocr(
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+ async def get_payables_id_history(
+ self,
+ payable_id: str,
+ *,
+ order: typing.Optional[OrderEnum] = None,
+ limit: typing.Optional[int] = None,
+ pagination_token: typing.Optional[str] = None,
+ sort: typing.Optional[PayableHistoryCursorFields] = None,
+ event_type_in: typing.Optional[
+ typing.Union[PayableHistoryEventTypeEnum, typing.Sequence[PayableHistoryEventTypeEnum]]
+ ] = None,
+ entity_user_id_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
+ timestamp_gt: typing.Optional[dt.datetime] = None,
+ timestamp_lt: typing.Optional[dt.datetime] = None,
+ timestamp_gte: typing.Optional[dt.datetime] = None,
+ timestamp_lte: typing.Optional[dt.datetime] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> AsyncHttpResponse[PayableHistoryPaginationResponse]:
+ """
+ Parameters
+ ----------
+ payable_id : str
+
+ order : typing.Optional[OrderEnum]
+ Sort order (ascending by default). Typically used together with the `sort` parameter.
+
+ limit : typing.Optional[int]
+ The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
+
+ pagination_token : typing.Optional[str]
+ A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+
+ If not specified, the first page of results will be returned.
+
+ sort : typing.Optional[PayableHistoryCursorFields]
+ The field to sort the results by. Typically used together with the `order` parameter.
+
+ event_type_in : typing.Optional[typing.Union[PayableHistoryEventTypeEnum, typing.Sequence[PayableHistoryEventTypeEnum]]]
+ Return only the specified event types
+
+ entity_user_id_in : typing.Optional[typing.Union[str, typing.Sequence[str]]]
+ Return only events caused by the entity users with the specified IDs. To specify multiple user IDs, repeat this parameter for each ID:
+ `entity_user_id__in=&entity_user_id__in=`
+
+ timestamp_gt : typing.Optional[dt.datetime]
+ Return only events that occurred after the specified date and time. The value must be in the ISO 8601 format `YYYY-MM-DDThh:mm[:ss[.ffffff]][Z|±hh:mm]`.
+
+ timestamp_lt : typing.Optional[dt.datetime]
+ Return only events that occurred before the specified date and time.
+
+ timestamp_gte : typing.Optional[dt.datetime]
+ Return only events that occurred on or after the specified date and time.
+
+ timestamp_lte : typing.Optional[dt.datetime]
+ Return only events that occurred before or on the specified date and time.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ AsyncHttpResponse[PayableHistoryPaginationResponse]
+ Successful Response
+ """
+ _response = await self._client_wrapper.httpx_client.request(
+ f"payables/{jsonable_encoder(payable_id)}/history",
+ method="GET",
+ params={
+ "order": order,
+ "limit": limit,
+ "pagination_token": pagination_token,
+ "sort": sort,
+ "event_type__in": event_type_in,
+ "entity_user_id__in": entity_user_id_in,
+ "timestamp__gt": serialize_datetime(timestamp_gt) if timestamp_gt is not None else None,
+ "timestamp__lt": serialize_datetime(timestamp_lt) if timestamp_lt is not None else None,
+ "timestamp__gte": serialize_datetime(timestamp_gte) if timestamp_gte is not None else None,
+ "timestamp__lte": serialize_datetime(timestamp_lte) if timestamp_lte is not None else None,
+ },
+ request_options=request_options,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ PayableHistoryPaginationResponse,
+ parse_obj_as(
+ type_=PayableHistoryPaginationResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return AsyncHttpResponse(response=_response, data=_data)
+ if _response.status_code == 400:
+ raise BadRequestError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 401:
+ raise UnauthorizedError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 500:
+ raise InternalServerError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ _response_json = _response.json()
+ except JSONDecodeError:
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
async def mark_as_paid_by_id(
self,
payable_id: str,
diff --git a/src/monite/payment_intents/client.py b/src/monite/payment_intents/client.py
index d694a20..45050a3 100644
--- a/src/monite/payment_intents/client.py
+++ b/src/monite/payment_intents/client.py
@@ -45,16 +45,18 @@ def get(
Parameters
----------
order : typing.Optional[OrderEnum]
- Order by
+ Sort order (ascending by default). Typically used together with the `sort` parameter.
limit : typing.Optional[int]
- Max is 100
+ The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
pagination_token : typing.Optional[str]
- A token, obtained from previous page. Prior over other filters
+ A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+
+ If not specified, the first page of results will be returned.
sort : typing.Optional[PaymentIntentCursorFields]
- Allowed sort fields
+ The field to sort the results by. Typically used together with the `order` parameter.
object_id : typing.Optional[str]
ID of a payable or receivable invoice. If provided, returns only payment intents associated with the specified invoice.
@@ -73,7 +75,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.payment_intents.get()
"""
_response = self._raw_client.get(
@@ -106,8 +113,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payment_intents.get_by_id(payment_intent_id='payment_intent_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payment_intents.get_by_id(
+ payment_intent_id="payment_intent_id",
+ )
"""
_response = self._raw_client.get_by_id(payment_intent_id, request_options=request_options)
return _response.data
@@ -133,8 +147,16 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payment_intents.update_by_id(payment_intent_id='payment_intent_id', amount=1, )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payment_intents.update_by_id(
+ payment_intent_id="payment_intent_id",
+ amount=1,
+ )
"""
_response = self._raw_client.update_by_id(payment_intent_id, amount=amount, request_options=request_options)
return _response.data
@@ -158,8 +180,15 @@ def get_history_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payment_intents.get_history_by_id(payment_intent_id='payment_intent_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payment_intents.get_history_by_id(
+ payment_intent_id="payment_intent_id",
+ )
"""
_response = self._raw_client.get_history_by_id(payment_intent_id, request_options=request_options)
return _response.data
@@ -195,16 +224,18 @@ async def get(
Parameters
----------
order : typing.Optional[OrderEnum]
- Order by
+ Sort order (ascending by default). Typically used together with the `sort` parameter.
limit : typing.Optional[int]
- Max is 100
+ The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
pagination_token : typing.Optional[str]
- A token, obtained from previous page. Prior over other filters
+ A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+
+ If not specified, the first page of results will be returned.
sort : typing.Optional[PaymentIntentCursorFields]
- Allowed sort fields
+ The field to sort the results by. Typically used together with the `order` parameter.
object_id : typing.Optional[str]
ID of a payable or receivable invoice. If provided, returns only payment intents associated with the specified invoice.
@@ -222,11 +253,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.payment_intents.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
@@ -258,11 +299,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payment_intents.get_by_id(payment_intent_id='payment_intent_id', )
+ await client.payment_intents.get_by_id(
+ payment_intent_id="payment_intent_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(payment_intent_id, request_options=request_options)
@@ -288,11 +341,24 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payment_intents.update_by_id(payment_intent_id='payment_intent_id', amount=1, )
+ await client.payment_intents.update_by_id(
+ payment_intent_id="payment_intent_id",
+ amount=1,
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
@@ -318,11 +384,23 @@ async def get_history_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payment_intents.get_history_by_id(payment_intent_id='payment_intent_id', )
+ await client.payment_intents.get_history_by_id(
+ payment_intent_id="payment_intent_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_history_by_id(payment_intent_id, request_options=request_options)
diff --git a/src/monite/payment_intents/raw_client.py b/src/monite/payment_intents/raw_client.py
index 73a6895..96b51d3 100644
--- a/src/monite/payment_intents/raw_client.py
+++ b/src/monite/payment_intents/raw_client.py
@@ -40,16 +40,18 @@ def get(
Parameters
----------
order : typing.Optional[OrderEnum]
- Order by
+ Sort order (ascending by default). Typically used together with the `sort` parameter.
limit : typing.Optional[int]
- Max is 100
+ The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
pagination_token : typing.Optional[str]
- A token, obtained from previous page. Prior over other filters
+ A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+
+ If not specified, the first page of results will be returned.
sort : typing.Optional[PaymentIntentCursorFields]
- Allowed sort fields
+ The field to sort the results by. Typically used together with the `order` parameter.
object_id : typing.Optional[str]
ID of a payable or receivable invoice. If provided, returns only payment intents associated with the specified invoice.
@@ -318,16 +320,18 @@ async def get(
Parameters
----------
order : typing.Optional[OrderEnum]
- Order by
+ Sort order (ascending by default). Typically used together with the `sort` parameter.
limit : typing.Optional[int]
- Max is 100
+ The number of items (0 .. 100) to return in a single page of the response. The response may contain fewer items if it is the last or only page.
pagination_token : typing.Optional[str]
- A token, obtained from previous page. Prior over other filters
+ A pagination token obtained from a previous call to this endpoint. Use it to get the next or previous page of results for your initial query. If `pagination_token` is specified, all other query parameters are ignored and inferred from the initial query.
+
+ If not specified, the first page of results will be returned.
sort : typing.Optional[PaymentIntentCursorFields]
- Allowed sort fields
+ The field to sort the results by. Typically used together with the `order` parameter.
object_id : typing.Optional[str]
ID of a payable or receivable invoice. If provided, returns only payment intents associated with the specified invoice.
diff --git a/src/monite/payment_links/client.py b/src/monite/payment_links/client.py
index 52fe347..057877d 100644
--- a/src/monite/payment_links/client.py
+++ b/src/monite/payment_links/client.py
@@ -83,10 +83,20 @@ def create(
Examples
--------
- from monite import Monite
- from monite import PaymentAccountObject
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payment_links.create(payment_methods=["sepa_credit"], recipient=PaymentAccountObject(id='id', type="entity", ), )
+ from monite import Monite, PaymentAccountObject
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payment_links.create(
+ payment_methods=["sepa_credit"],
+ recipient=PaymentAccountObject(
+ id="id",
+ type="entity",
+ ),
+ )
"""
_response = self._raw_client.create(
payment_methods=payment_methods,
@@ -121,8 +131,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payment_links.get_by_id(payment_link_id='payment_link_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payment_links.get_by_id(
+ payment_link_id="payment_link_id",
+ )
"""
_response = self._raw_client.get_by_id(payment_link_id, request_options=request_options)
return _response.data
@@ -146,8 +163,15 @@ def expire_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payment_links.expire_by_id(payment_link_id='payment_link_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payment_links.expire_by_id(
+ payment_link_id="payment_link_id",
+ )
"""
_response = self._raw_client.expire_by_id(payment_link_id, request_options=request_options)
return _response.data
@@ -219,12 +243,27 @@ async def create(
Examples
--------
- from monite import AsyncMonite
- from monite import PaymentAccountObject
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite, PaymentAccountObject
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payment_links.create(payment_methods=["sepa_credit"], recipient=PaymentAccountObject(id='id', type="entity", ), )
+ await client.payment_links.create(
+ payment_methods=["sepa_credit"],
+ recipient=PaymentAccountObject(
+ id="id",
+ type="entity",
+ ),
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -259,11 +298,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payment_links.get_by_id(payment_link_id='payment_link_id', )
+ await client.payment_links.get_by_id(
+ payment_link_id="payment_link_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(payment_link_id, request_options=request_options)
@@ -287,11 +338,23 @@ async def expire_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payment_links.expire_by_id(payment_link_id='payment_link_id', )
+ await client.payment_links.expire_by_id(
+ payment_link_id="payment_link_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.expire_by_id(payment_link_id, request_options=request_options)
diff --git a/src/monite/payment_records/client.py b/src/monite/payment_records/client.py
index 818d509..e65e644 100644
--- a/src/monite/payment_records/client.py
+++ b/src/monite/payment_records/client.py
@@ -44,6 +44,7 @@ def get(
sort: typing.Optional[PaymentRecordCursorFields] = None,
is_external: typing.Optional[bool] = None,
object_id: typing.Optional[str] = None,
+ object_id_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
object_type: typing.Optional[ObjectTypeEnum] = None,
created_at_gt: typing.Optional[dt.datetime] = None,
created_at_lt: typing.Optional[dt.datetime] = None,
@@ -82,6 +83,9 @@ def get(
object_id : typing.Optional[str]
ID of the object, that is connected to payment
+ object_id_in : typing.Optional[typing.Union[str, typing.Sequence[str]]]
+ List of IDs of the objects, that are connected to payments
+
object_type : typing.Optional[ObjectTypeEnum]
Type of an object, which is connected with payment
@@ -138,7 +142,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.payment_records.get()
"""
_response = self._raw_client.get(
@@ -148,6 +157,7 @@ def get(
sort=sort,
is_external=is_external,
object_id=object_id,
+ object_id_in=object_id_in,
object_type=object_type,
created_at_gt=created_at_gt,
created_at_lt=created_at_lt,
@@ -225,10 +235,22 @@ def create(
Examples
--------
- from monite import Monite
- from monite import PaymentRecordObjectRequest
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payment_records.create(amount=1, currency="AED", object=PaymentRecordObjectRequest(id='id', type="receivable", ), payment_intent_id='payment_intent_id', )
+ from monite import Monite, PaymentRecordObjectRequest
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payment_records.create(
+ amount=1,
+ currency="AED",
+ object=PaymentRecordObjectRequest(
+ id="id",
+ type="receivable",
+ ),
+ payment_intent_id="payment_intent_id",
+ )
"""
_response = self._raw_client.create(
amount=amount,
@@ -264,8 +286,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payment_records.get_by_id(payment_record_id='payment_record_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payment_records.get_by_id(
+ payment_record_id="payment_record_id",
+ )
"""
_response = self._raw_client.get_by_id(payment_record_id, request_options=request_options)
return _response.data
@@ -328,8 +357,15 @@ def patch_payment_records_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payment_records.patch_payment_records_id(payment_record_id='payment_record_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payment_records.patch_payment_records_id(
+ payment_record_id="payment_record_id",
+ )
"""
_response = self._raw_client.patch_payment_records_id(
payment_record_id,
@@ -372,8 +408,15 @@ def post_payment_records_id_cancel(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payment_records.post_payment_records_id_cancel(payment_record_id='payment_record_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payment_records.post_payment_records_id_cancel(
+ payment_record_id="payment_record_id",
+ )
"""
_response = self._raw_client.post_payment_records_id_cancel(
payment_record_id, payment_intent_status=payment_intent_status, request_options=request_options
@@ -409,10 +452,21 @@ def post_payment_records_id_mark_as_succeeded(
Examples
--------
- from monite import Monite
import datetime
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payment_records.post_payment_records_id_mark_as_succeeded(payment_record_id='payment_record_id', paid_at=datetime.datetime.fromisoformat("2024-01-15 09:30:00+00:00", ), )
+
+ from monite import Monite
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payment_records.post_payment_records_id_mark_as_succeeded(
+ payment_record_id="payment_record_id",
+ paid_at=datetime.datetime.fromisoformat(
+ "2024-01-15 09:30:00+00:00",
+ ),
+ )
"""
_response = self._raw_client.post_payment_records_id_mark_as_succeeded(
payment_record_id,
@@ -448,8 +502,15 @@ def post_payment_records_id_start_processing(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payment_records.post_payment_records_id_start_processing(payment_record_id='payment_record_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payment_records.post_payment_records_id_start_processing(
+ payment_record_id="payment_record_id",
+ )
"""
_response = self._raw_client.post_payment_records_id_start_processing(
payment_record_id, payment_intent_status=payment_intent_status, request_options=request_options
@@ -481,6 +542,7 @@ async def get(
sort: typing.Optional[PaymentRecordCursorFields] = None,
is_external: typing.Optional[bool] = None,
object_id: typing.Optional[str] = None,
+ object_id_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
object_type: typing.Optional[ObjectTypeEnum] = None,
created_at_gt: typing.Optional[dt.datetime] = None,
created_at_lt: typing.Optional[dt.datetime] = None,
@@ -519,6 +581,9 @@ async def get(
object_id : typing.Optional[str]
ID of the object, that is connected to payment
+ object_id_in : typing.Optional[typing.Union[str, typing.Sequence[str]]]
+ List of IDs of the objects, that are connected to payments
+
object_type : typing.Optional[ObjectTypeEnum]
Type of an object, which is connected with payment
@@ -574,11 +639,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.payment_records.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
@@ -588,6 +663,7 @@ async def main() -> None:
sort=sort,
is_external=is_external,
object_id=object_id,
+ object_id_in=object_id_in,
object_type=object_type,
created_at_gt=created_at_gt,
created_at_lt=created_at_lt,
@@ -665,12 +741,29 @@ async def create(
Examples
--------
- from monite import AsyncMonite
- from monite import PaymentRecordObjectRequest
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite, PaymentRecordObjectRequest
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payment_records.create(amount=1, currency="AED", object=PaymentRecordObjectRequest(id='id', type="receivable", ), payment_intent_id='payment_intent_id', )
+ await client.payment_records.create(
+ amount=1,
+ currency="AED",
+ object=PaymentRecordObjectRequest(
+ id="id",
+ type="receivable",
+ ),
+ payment_intent_id="payment_intent_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -706,11 +799,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payment_records.get_by_id(payment_record_id='payment_record_id', )
+ await client.payment_records.get_by_id(
+ payment_record_id="payment_record_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(payment_record_id, request_options=request_options)
@@ -773,11 +878,23 @@ async def patch_payment_records_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payment_records.patch_payment_records_id(payment_record_id='payment_record_id', )
+ await client.payment_records.patch_payment_records_id(
+ payment_record_id="payment_record_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.patch_payment_records_id(
@@ -820,11 +937,23 @@ async def post_payment_records_id_cancel(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payment_records.post_payment_records_id_cancel(payment_record_id='payment_record_id', )
+ await client.payment_records.post_payment_records_id_cancel(
+ payment_record_id="payment_record_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.post_payment_records_id_cancel(
@@ -861,12 +990,27 @@ async def post_payment_records_id_mark_as_succeeded(
Examples
--------
- from monite import AsyncMonite
- import datetime
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+ import datetime
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payment_records.post_payment_records_id_mark_as_succeeded(payment_record_id='payment_record_id', paid_at=datetime.datetime.fromisoformat("2024-01-15 09:30:00+00:00", ), )
+ await client.payment_records.post_payment_records_id_mark_as_succeeded(
+ payment_record_id="payment_record_id",
+ paid_at=datetime.datetime.fromisoformat(
+ "2024-01-15 09:30:00+00:00",
+ ),
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.post_payment_records_id_mark_as_succeeded(
@@ -902,11 +1046,23 @@ async def post_payment_records_id_start_processing(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payment_records.post_payment_records_id_start_processing(payment_record_id='payment_record_id', )
+ await client.payment_records.post_payment_records_id_start_processing(
+ payment_record_id="payment_record_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.post_payment_records_id_start_processing(
diff --git a/src/monite/payment_records/raw_client.py b/src/monite/payment_records/raw_client.py
index 65e7998..7995509 100644
--- a/src/monite/payment_records/raw_client.py
+++ b/src/monite/payment_records/raw_client.py
@@ -41,6 +41,7 @@ def get(
sort: typing.Optional[PaymentRecordCursorFields] = None,
is_external: typing.Optional[bool] = None,
object_id: typing.Optional[str] = None,
+ object_id_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
object_type: typing.Optional[ObjectTypeEnum] = None,
created_at_gt: typing.Optional[dt.datetime] = None,
created_at_lt: typing.Optional[dt.datetime] = None,
@@ -79,6 +80,9 @@ def get(
object_id : typing.Optional[str]
ID of the object, that is connected to payment
+ object_id_in : typing.Optional[typing.Union[str, typing.Sequence[str]]]
+ List of IDs of the objects, that are connected to payments
+
object_type : typing.Optional[ObjectTypeEnum]
Type of an object, which is connected with payment
@@ -142,6 +146,7 @@ def get(
"sort": sort,
"is_external": is_external,
"object_id": object_id,
+ "object_id__in": object_id_in,
"object_type": object_type,
"created_at__gt": serialize_datetime(created_at_gt) if created_at_gt is not None else None,
"created_at__lt": serialize_datetime(created_at_lt) if created_at_lt is not None else None,
@@ -720,6 +725,7 @@ async def get(
sort: typing.Optional[PaymentRecordCursorFields] = None,
is_external: typing.Optional[bool] = None,
object_id: typing.Optional[str] = None,
+ object_id_in: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
object_type: typing.Optional[ObjectTypeEnum] = None,
created_at_gt: typing.Optional[dt.datetime] = None,
created_at_lt: typing.Optional[dt.datetime] = None,
@@ -758,6 +764,9 @@ async def get(
object_id : typing.Optional[str]
ID of the object, that is connected to payment
+ object_id_in : typing.Optional[typing.Union[str, typing.Sequence[str]]]
+ List of IDs of the objects, that are connected to payments
+
object_type : typing.Optional[ObjectTypeEnum]
Type of an object, which is connected with payment
@@ -821,6 +830,7 @@ async def get(
"sort": sort,
"is_external": is_external,
"object_id": object_id,
+ "object_id__in": object_id_in,
"object_type": object_type,
"created_at__gt": serialize_datetime(created_at_gt) if created_at_gt is not None else None,
"created_at__lt": serialize_datetime(created_at_lt) if created_at_lt is not None else None,
diff --git a/src/monite/payment_reminders/client.py b/src/monite/payment_reminders/client.py
index 02ccebb..af0a65b 100644
--- a/src/monite/payment_reminders/client.py
+++ b/src/monite/payment_reminders/client.py
@@ -44,7 +44,12 @@ def get(self, *, request_options: typing.Optional[RequestOptions] = None) -> Get
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.payment_reminders.get()
"""
_response = self._raw_client.get(request_options=request_options)
@@ -87,8 +92,15 @@ def create(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payment_reminders.create(name='name', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payment_reminders.create(
+ name="name",
+ )
"""
_response = self._raw_client.create(
name=name,
@@ -119,8 +131,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payment_reminders.get_by_id(payment_reminder_id='payment_reminder_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payment_reminders.get_by_id(
+ payment_reminder_id="payment_reminder_id",
+ )
"""
_response = self._raw_client.get_by_id(payment_reminder_id, request_options=request_options)
return _response.data
@@ -143,8 +162,15 @@ def delete_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payment_reminders.delete_by_id(payment_reminder_id='payment_reminder_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payment_reminders.delete_by_id(
+ payment_reminder_id="payment_reminder_id",
+ )
"""
_response = self._raw_client.delete_by_id(payment_reminder_id, request_options=request_options)
return _response.data
@@ -189,8 +215,15 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payment_reminders.update_by_id(payment_reminder_id='payment_reminder_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payment_reminders.update_by_id(
+ payment_reminder_id="payment_reminder_id",
+ )
"""
_response = self._raw_client.update_by_id(
payment_reminder_id,
@@ -233,11 +266,21 @@ async def get(self, *, request_options: typing.Optional[RequestOptions] = None)
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.payment_reminders.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(request_options=request_options)
@@ -279,11 +322,23 @@ async def create(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payment_reminders.create(name='name', )
+ await client.payment_reminders.create(
+ name="name",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -314,11 +369,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payment_reminders.get_by_id(payment_reminder_id='payment_reminder_id', )
+ await client.payment_reminders.get_by_id(
+ payment_reminder_id="payment_reminder_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(payment_reminder_id, request_options=request_options)
@@ -341,11 +408,23 @@ async def delete_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payment_reminders.delete_by_id(payment_reminder_id='payment_reminder_id', )
+ await client.payment_reminders.delete_by_id(
+ payment_reminder_id="payment_reminder_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(payment_reminder_id, request_options=request_options)
@@ -390,11 +469,23 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payment_reminders.update_by_id(payment_reminder_id='payment_reminder_id', )
+ await client.payment_reminders.update_by_id(
+ payment_reminder_id="payment_reminder_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
diff --git a/src/monite/payment_terms/client.py b/src/monite/payment_terms/client.py
index 61410d9..a0fcfe7 100644
--- a/src/monite/payment_terms/client.py
+++ b/src/monite/payment_terms/client.py
@@ -4,10 +4,10 @@
from ..core.client_wrapper import AsyncClientWrapper, SyncClientWrapper
from ..core.request_options import RequestOptions
-from ..types.payment_term import PaymentTerm
-from ..types.payment_term_discount import PaymentTermDiscount
from ..types.payment_terms_list_response import PaymentTermsListResponse
from ..types.payment_terms_response import PaymentTermsResponse
+from ..types.term_discount_days import TermDiscountDays
+from ..types.term_final_days import TermFinalDays
from .raw_client import AsyncRawPaymentTermsClient, RawPaymentTermsClient
# this is used as the default value for optional parameters
@@ -44,7 +44,12 @@ def get(self, *, request_options: typing.Optional[RequestOptions] = None) -> Pay
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.payment_terms.get()
"""
_response = self._raw_client.get(request_options=request_options)
@@ -54,10 +59,10 @@ def create(
self,
*,
name: str,
- term_final: PaymentTerm,
+ term_final: TermFinalDays,
description: typing.Optional[str] = OMIT,
- term1: typing.Optional[PaymentTermDiscount] = OMIT,
- term2: typing.Optional[PaymentTermDiscount] = OMIT,
+ term1: typing.Optional[TermDiscountDays] = OMIT,
+ term2: typing.Optional[TermDiscountDays] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
) -> PaymentTermsResponse:
"""
@@ -65,15 +70,15 @@ def create(
----------
name : str
- term_final : PaymentTerm
+ term_final : TermFinalDays
The final tier of the payment term. Defines the invoice due date.
description : typing.Optional[str]
- term1 : typing.Optional[PaymentTermDiscount]
+ term1 : typing.Optional[TermDiscountDays]
The first tier of the payment term. Represents the terms of the first early discount.
- term2 : typing.Optional[PaymentTermDiscount]
+ term2 : typing.Optional[TermDiscountDays]
The second tier of the payment term. Defines the terms of the second early discount.
request_options : typing.Optional[RequestOptions]
@@ -86,10 +91,19 @@ def create(
Examples
--------
- from monite import Monite
- from monite import PaymentTerm
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payment_terms.create(name='name', term_final=PaymentTerm(number_of_days=1, ), )
+ from monite import Monite, TermFinalDays
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payment_terms.create(
+ name="name",
+ term_final=TermFinalDays(
+ number_of_days=1,
+ ),
+ )
"""
_response = self._raw_client.create(
name=name,
@@ -120,8 +134,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payment_terms.get_by_id(payment_terms_id='payment_terms_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payment_terms.get_by_id(
+ payment_terms_id="payment_terms_id",
+ )
"""
_response = self._raw_client.get_by_id(payment_terms_id, request_options=request_options)
return _response.data
@@ -142,8 +163,15 @@ def delete_by_id(self, payment_terms_id: str, *, request_options: typing.Optiona
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payment_terms.delete_by_id(payment_terms_id='payment_terms_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payment_terms.delete_by_id(
+ payment_terms_id="payment_terms_id",
+ )
"""
_response = self._raw_client.delete_by_id(payment_terms_id, request_options=request_options)
return _response.data
@@ -154,9 +182,9 @@ def update_by_id(
*,
description: typing.Optional[str] = OMIT,
name: typing.Optional[str] = OMIT,
- term1: typing.Optional[PaymentTermDiscount] = OMIT,
- term2: typing.Optional[PaymentTermDiscount] = OMIT,
- term_final: typing.Optional[PaymentTerm] = OMIT,
+ term1: typing.Optional[TermDiscountDays] = OMIT,
+ term2: typing.Optional[TermDiscountDays] = OMIT,
+ term_final: typing.Optional[TermFinalDays] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
) -> PaymentTermsResponse:
"""
@@ -168,13 +196,13 @@ def update_by_id(
name : typing.Optional[str]
- term1 : typing.Optional[PaymentTermDiscount]
+ term1 : typing.Optional[TermDiscountDays]
The first tier of the payment term. Represents the terms of the first early discount.
- term2 : typing.Optional[PaymentTermDiscount]
+ term2 : typing.Optional[TermDiscountDays]
The second tier of the payment term. Defines the terms of the second early discount.
- term_final : typing.Optional[PaymentTerm]
+ term_final : typing.Optional[TermFinalDays]
The final tier of the payment term. Defines the invoice due date.
request_options : typing.Optional[RequestOptions]
@@ -188,8 +216,15 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.payment_terms.update_by_id(payment_terms_id='payment_terms_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.payment_terms.update_by_id(
+ payment_terms_id="payment_terms_id",
+ )
"""
_response = self._raw_client.update_by_id(
payment_terms_id,
@@ -232,11 +267,21 @@ async def get(self, *, request_options: typing.Optional[RequestOptions] = None)
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.payment_terms.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(request_options=request_options)
@@ -246,10 +291,10 @@ async def create(
self,
*,
name: str,
- term_final: PaymentTerm,
+ term_final: TermFinalDays,
description: typing.Optional[str] = OMIT,
- term1: typing.Optional[PaymentTermDiscount] = OMIT,
- term2: typing.Optional[PaymentTermDiscount] = OMIT,
+ term1: typing.Optional[TermDiscountDays] = OMIT,
+ term2: typing.Optional[TermDiscountDays] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
) -> PaymentTermsResponse:
"""
@@ -257,15 +302,15 @@ async def create(
----------
name : str
- term_final : PaymentTerm
+ term_final : TermFinalDays
The final tier of the payment term. Defines the invoice due date.
description : typing.Optional[str]
- term1 : typing.Optional[PaymentTermDiscount]
+ term1 : typing.Optional[TermDiscountDays]
The first tier of the payment term. Represents the terms of the first early discount.
- term2 : typing.Optional[PaymentTermDiscount]
+ term2 : typing.Optional[TermDiscountDays]
The second tier of the payment term. Defines the terms of the second early discount.
request_options : typing.Optional[RequestOptions]
@@ -278,12 +323,26 @@ async def create(
Examples
--------
- from monite import AsyncMonite
- from monite import PaymentTerm
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite, TermFinalDays
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payment_terms.create(name='name', term_final=PaymentTerm(number_of_days=1, ), )
+ await client.payment_terms.create(
+ name="name",
+ term_final=TermFinalDays(
+ number_of_days=1,
+ ),
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -314,11 +373,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payment_terms.get_by_id(payment_terms_id='payment_terms_id', )
+ await client.payment_terms.get_by_id(
+ payment_terms_id="payment_terms_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(payment_terms_id, request_options=request_options)
@@ -341,11 +412,23 @@ async def delete_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payment_terms.delete_by_id(payment_terms_id='payment_terms_id', )
+ await client.payment_terms.delete_by_id(
+ payment_terms_id="payment_terms_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(payment_terms_id, request_options=request_options)
@@ -357,9 +440,9 @@ async def update_by_id(
*,
description: typing.Optional[str] = OMIT,
name: typing.Optional[str] = OMIT,
- term1: typing.Optional[PaymentTermDiscount] = OMIT,
- term2: typing.Optional[PaymentTermDiscount] = OMIT,
- term_final: typing.Optional[PaymentTerm] = OMIT,
+ term1: typing.Optional[TermDiscountDays] = OMIT,
+ term2: typing.Optional[TermDiscountDays] = OMIT,
+ term_final: typing.Optional[TermFinalDays] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
) -> PaymentTermsResponse:
"""
@@ -371,13 +454,13 @@ async def update_by_id(
name : typing.Optional[str]
- term1 : typing.Optional[PaymentTermDiscount]
+ term1 : typing.Optional[TermDiscountDays]
The first tier of the payment term. Represents the terms of the first early discount.
- term2 : typing.Optional[PaymentTermDiscount]
+ term2 : typing.Optional[TermDiscountDays]
The second tier of the payment term. Defines the terms of the second early discount.
- term_final : typing.Optional[PaymentTerm]
+ term_final : typing.Optional[TermFinalDays]
The final tier of the payment term. Defines the invoice due date.
request_options : typing.Optional[RequestOptions]
@@ -390,11 +473,23 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.payment_terms.update_by_id(payment_terms_id='payment_terms_id', )
+ await client.payment_terms.update_by_id(
+ payment_terms_id="payment_terms_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
diff --git a/src/monite/payment_terms/raw_client.py b/src/monite/payment_terms/raw_client.py
index 26fdbb7..3085cab 100644
--- a/src/monite/payment_terms/raw_client.py
+++ b/src/monite/payment_terms/raw_client.py
@@ -16,10 +16,10 @@
from ..errors.not_found_error import NotFoundError
from ..errors.unauthorized_error import UnauthorizedError
from ..errors.unprocessable_entity_error import UnprocessableEntityError
-from ..types.payment_term import PaymentTerm
-from ..types.payment_term_discount import PaymentTermDiscount
from ..types.payment_terms_list_response import PaymentTermsListResponse
from ..types.payment_terms_response import PaymentTermsResponse
+from ..types.term_discount_days import TermDiscountDays
+from ..types.term_final_days import TermFinalDays
# this is used as the default value for optional parameters
OMIT = typing.cast(typing.Any, ...)
@@ -109,10 +109,10 @@ def create(
self,
*,
name: str,
- term_final: PaymentTerm,
+ term_final: TermFinalDays,
description: typing.Optional[str] = OMIT,
- term1: typing.Optional[PaymentTermDiscount] = OMIT,
- term2: typing.Optional[PaymentTermDiscount] = OMIT,
+ term1: typing.Optional[TermDiscountDays] = OMIT,
+ term2: typing.Optional[TermDiscountDays] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
) -> HttpResponse[PaymentTermsResponse]:
"""
@@ -120,15 +120,15 @@ def create(
----------
name : str
- term_final : PaymentTerm
+ term_final : TermFinalDays
The final tier of the payment term. Defines the invoice due date.
description : typing.Optional[str]
- term1 : typing.Optional[PaymentTermDiscount]
+ term1 : typing.Optional[TermDiscountDays]
The first tier of the payment term. Represents the terms of the first early discount.
- term2 : typing.Optional[PaymentTermDiscount]
+ term2 : typing.Optional[TermDiscountDays]
The second tier of the payment term. Defines the terms of the second early discount.
request_options : typing.Optional[RequestOptions]
@@ -146,13 +146,13 @@ def create(
"description": description,
"name": name,
"term_1": convert_and_respect_annotation_metadata(
- object_=term1, annotation=PaymentTermDiscount, direction="write"
+ object_=term1, annotation=TermDiscountDays, direction="write"
),
"term_2": convert_and_respect_annotation_metadata(
- object_=term2, annotation=PaymentTermDiscount, direction="write"
+ object_=term2, annotation=TermDiscountDays, direction="write"
),
"term_final": convert_and_respect_annotation_metadata(
- object_=term_final, annotation=PaymentTerm, direction="write"
+ object_=term_final, annotation=TermFinalDays, direction="write"
),
},
headers={
@@ -422,9 +422,9 @@ def update_by_id(
*,
description: typing.Optional[str] = OMIT,
name: typing.Optional[str] = OMIT,
- term1: typing.Optional[PaymentTermDiscount] = OMIT,
- term2: typing.Optional[PaymentTermDiscount] = OMIT,
- term_final: typing.Optional[PaymentTerm] = OMIT,
+ term1: typing.Optional[TermDiscountDays] = OMIT,
+ term2: typing.Optional[TermDiscountDays] = OMIT,
+ term_final: typing.Optional[TermFinalDays] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
) -> HttpResponse[PaymentTermsResponse]:
"""
@@ -436,13 +436,13 @@ def update_by_id(
name : typing.Optional[str]
- term1 : typing.Optional[PaymentTermDiscount]
+ term1 : typing.Optional[TermDiscountDays]
The first tier of the payment term. Represents the terms of the first early discount.
- term2 : typing.Optional[PaymentTermDiscount]
+ term2 : typing.Optional[TermDiscountDays]
The second tier of the payment term. Defines the terms of the second early discount.
- term_final : typing.Optional[PaymentTerm]
+ term_final : typing.Optional[TermFinalDays]
The final tier of the payment term. Defines the invoice due date.
request_options : typing.Optional[RequestOptions]
@@ -460,13 +460,13 @@ def update_by_id(
"description": description,
"name": name,
"term_1": convert_and_respect_annotation_metadata(
- object_=term1, annotation=PaymentTermDiscount, direction="write"
+ object_=term1, annotation=TermDiscountDays, direction="write"
),
"term_2": convert_and_respect_annotation_metadata(
- object_=term2, annotation=PaymentTermDiscount, direction="write"
+ object_=term2, annotation=TermDiscountDays, direction="write"
),
"term_final": convert_and_respect_annotation_metadata(
- object_=term_final, annotation=PaymentTerm, direction="write"
+ object_=term_final, annotation=TermFinalDays, direction="write"
),
},
headers={
@@ -643,10 +643,10 @@ async def create(
self,
*,
name: str,
- term_final: PaymentTerm,
+ term_final: TermFinalDays,
description: typing.Optional[str] = OMIT,
- term1: typing.Optional[PaymentTermDiscount] = OMIT,
- term2: typing.Optional[PaymentTermDiscount] = OMIT,
+ term1: typing.Optional[TermDiscountDays] = OMIT,
+ term2: typing.Optional[TermDiscountDays] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
) -> AsyncHttpResponse[PaymentTermsResponse]:
"""
@@ -654,15 +654,15 @@ async def create(
----------
name : str
- term_final : PaymentTerm
+ term_final : TermFinalDays
The final tier of the payment term. Defines the invoice due date.
description : typing.Optional[str]
- term1 : typing.Optional[PaymentTermDiscount]
+ term1 : typing.Optional[TermDiscountDays]
The first tier of the payment term. Represents the terms of the first early discount.
- term2 : typing.Optional[PaymentTermDiscount]
+ term2 : typing.Optional[TermDiscountDays]
The second tier of the payment term. Defines the terms of the second early discount.
request_options : typing.Optional[RequestOptions]
@@ -680,13 +680,13 @@ async def create(
"description": description,
"name": name,
"term_1": convert_and_respect_annotation_metadata(
- object_=term1, annotation=PaymentTermDiscount, direction="write"
+ object_=term1, annotation=TermDiscountDays, direction="write"
),
"term_2": convert_and_respect_annotation_metadata(
- object_=term2, annotation=PaymentTermDiscount, direction="write"
+ object_=term2, annotation=TermDiscountDays, direction="write"
),
"term_final": convert_and_respect_annotation_metadata(
- object_=term_final, annotation=PaymentTerm, direction="write"
+ object_=term_final, annotation=TermFinalDays, direction="write"
),
},
headers={
@@ -956,9 +956,9 @@ async def update_by_id(
*,
description: typing.Optional[str] = OMIT,
name: typing.Optional[str] = OMIT,
- term1: typing.Optional[PaymentTermDiscount] = OMIT,
- term2: typing.Optional[PaymentTermDiscount] = OMIT,
- term_final: typing.Optional[PaymentTerm] = OMIT,
+ term1: typing.Optional[TermDiscountDays] = OMIT,
+ term2: typing.Optional[TermDiscountDays] = OMIT,
+ term_final: typing.Optional[TermFinalDays] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
) -> AsyncHttpResponse[PaymentTermsResponse]:
"""
@@ -970,13 +970,13 @@ async def update_by_id(
name : typing.Optional[str]
- term1 : typing.Optional[PaymentTermDiscount]
+ term1 : typing.Optional[TermDiscountDays]
The first tier of the payment term. Represents the terms of the first early discount.
- term2 : typing.Optional[PaymentTermDiscount]
+ term2 : typing.Optional[TermDiscountDays]
The second tier of the payment term. Defines the terms of the second early discount.
- term_final : typing.Optional[PaymentTerm]
+ term_final : typing.Optional[TermFinalDays]
The final tier of the payment term. Defines the invoice due date.
request_options : typing.Optional[RequestOptions]
@@ -994,13 +994,13 @@ async def update_by_id(
"description": description,
"name": name,
"term_1": convert_and_respect_annotation_metadata(
- object_=term1, annotation=PaymentTermDiscount, direction="write"
+ object_=term1, annotation=TermDiscountDays, direction="write"
),
"term_2": convert_and_respect_annotation_metadata(
- object_=term2, annotation=PaymentTermDiscount, direction="write"
+ object_=term2, annotation=TermDiscountDays, direction="write"
),
"term_final": convert_and_respect_annotation_metadata(
- object_=term_final, annotation=PaymentTerm, direction="write"
+ object_=term_final, annotation=TermFinalDays, direction="write"
),
},
headers={
diff --git a/src/monite/pdf_templates/client.py b/src/monite/pdf_templates/client.py
index d0c0e2f..df65c22 100644
--- a/src/monite/pdf_templates/client.py
+++ b/src/monite/pdf_templates/client.py
@@ -41,7 +41,12 @@ def get(self, *, request_options: typing.Optional[RequestOptions] = None) -> Tem
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.pdf_templates.get()
"""
_response = self._raw_client.get(request_options=request_options)
@@ -64,7 +69,12 @@ def get_system(self, *, request_options: typing.Optional[RequestOptions] = None)
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.pdf_templates.get_system()
"""
_response = self._raw_client.get_system(request_options=request_options)
@@ -89,8 +99,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.pdf_templates.get_by_id(document_template_id='document_template_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.pdf_templates.get_by_id(
+ document_template_id="document_template_id",
+ )
"""
_response = self._raw_client.get_by_id(document_template_id, request_options=request_options)
return _response.data
@@ -114,8 +131,15 @@ def make_default_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.pdf_templates.make_default_by_id(document_template_id='document_template_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.pdf_templates.make_default_by_id(
+ document_template_id="document_template_id",
+ )
"""
_response = self._raw_client.make_default_by_id(document_template_id, request_options=request_options)
return _response.data
@@ -173,11 +197,21 @@ async def get(self, *, request_options: typing.Optional[RequestOptions] = None)
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.pdf_templates.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(request_options=request_options)
@@ -199,11 +233,21 @@ async def get_system(self, *, request_options: typing.Optional[RequestOptions] =
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.pdf_templates.get_system()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_system(request_options=request_options)
@@ -227,11 +271,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.pdf_templates.get_by_id(document_template_id='document_template_id', )
+ await client.pdf_templates.get_by_id(
+ document_template_id="document_template_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(document_template_id, request_options=request_options)
@@ -255,11 +311,23 @@ async def make_default_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.pdf_templates.make_default_by_id(document_template_id='document_template_id', )
+ await client.pdf_templates.make_default_by_id(
+ document_template_id="document_template_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.make_default_by_id(document_template_id, request_options=request_options)
@@ -284,5 +352,5 @@ async def preview_by_id(
Successful Response
"""
async with self._raw_client.preview_by_id(document_template_id, request_options=request_options) as r:
- async for data in r.data:
- yield data
+ async for _chunk in r.data:
+ yield _chunk
diff --git a/src/monite/pdf_templates/raw_client.py b/src/monite/pdf_templates/raw_client.py
index c1ea4ab..000858c 100644
--- a/src/monite/pdf_templates/raw_client.py
+++ b/src/monite/pdf_templates/raw_client.py
@@ -275,7 +275,7 @@ def preview_by_id(
request_options=request_options,
) as _response:
- def stream() -> HttpResponse[typing.Iterator[bytes]]:
+ def _stream() -> HttpResponse[typing.Iterator[bytes]]:
try:
if 200 <= _response.status_code < 300:
_chunk_size = request_options.get("chunk_size", None) if request_options is not None else None
@@ -312,7 +312,7 @@ def stream() -> HttpResponse[typing.Iterator[bytes]]:
)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- yield stream()
+ yield _stream()
class AsyncRawPdfTemplatesClient:
@@ -576,7 +576,7 @@ async def preview_by_id(
request_options=request_options,
) as _response:
- async def stream() -> AsyncHttpResponse[typing.AsyncIterator[bytes]]:
+ async def _stream() -> AsyncHttpResponse[typing.AsyncIterator[bytes]]:
try:
if 200 <= _response.status_code < 300:
_chunk_size = request_options.get("chunk_size", None) if request_options is not None else None
@@ -614,4 +614,4 @@ async def stream() -> AsyncHttpResponse[typing.AsyncIterator[bytes]]:
)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- yield await stream()
+ yield await _stream()
diff --git a/src/monite/products/client.py b/src/monite/products/client.py
index eeb6dd4..e000298 100644
--- a/src/monite/products/client.py
+++ b/src/monite/products/client.py
@@ -121,7 +121,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.products.get()
"""
_response = self._raw_client.get(
@@ -155,6 +160,7 @@ def create(
*,
name: str,
description: typing.Optional[str] = OMIT,
+ external_reference: typing.Optional[str] = OMIT,
ledger_account_id: typing.Optional[str] = OMIT,
measure_unit_id: typing.Optional[str] = OMIT,
price: typing.Optional[Price] = OMIT,
@@ -171,6 +177,9 @@ def create(
description : typing.Optional[str]
Description of the product.
+ external_reference : typing.Optional[str]
+ A user-defined identifier of the product. For example, an internal product code or SKU (stock keeping unit). Client applications can use this field to map the products in Monite to an external product catalog.
+
ledger_account_id : typing.Optional[str]
measure_unit_id : typing.Optional[str]
@@ -195,12 +204,20 @@ def create(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.products.create(name='name', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.products.create(
+ name="name",
+ )
"""
_response = self._raw_client.create(
name=name,
description=description,
+ external_reference=external_reference,
ledger_account_id=ledger_account_id,
measure_unit_id=measure_unit_id,
price=price,
@@ -229,8 +246,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.products.get_by_id(product_id='product_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.products.get_by_id(
+ product_id="product_id",
+ )
"""
_response = self._raw_client.get_by_id(product_id, request_options=request_options)
return _response.data
@@ -251,8 +275,15 @@ def delete_by_id(self, product_id: str, *, request_options: typing.Optional[Requ
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.products.delete_by_id(product_id='product_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.products.delete_by_id(
+ product_id="product_id",
+ )
"""
_response = self._raw_client.delete_by_id(product_id, request_options=request_options)
return _response.data
@@ -262,6 +293,7 @@ def update_by_id(
product_id: str,
*,
description: typing.Optional[str] = OMIT,
+ external_reference: typing.Optional[str] = OMIT,
ledger_account_id: typing.Optional[str] = OMIT,
measure_unit_id: typing.Optional[str] = OMIT,
name: typing.Optional[str] = OMIT,
@@ -278,6 +310,9 @@ def update_by_id(
description : typing.Optional[str]
Description of the product.
+ external_reference : typing.Optional[str]
+ A user-defined identifier of the product. For example, an internal product code or SKU (stock keeping unit). Client applications can use this field to map the products in Monite to an external product catalog.
+
ledger_account_id : typing.Optional[str]
measure_unit_id : typing.Optional[str]
@@ -305,12 +340,20 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.products.update_by_id(product_id='product_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.products.update_by_id(
+ product_id="product_id",
+ )
"""
_response = self._raw_client.update_by_id(
product_id,
description=description,
+ external_reference=external_reference,
ledger_account_id=ledger_account_id,
measure_unit_id=measure_unit_id,
name=name,
@@ -424,11 +467,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.products.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
@@ -462,6 +515,7 @@ async def create(
*,
name: str,
description: typing.Optional[str] = OMIT,
+ external_reference: typing.Optional[str] = OMIT,
ledger_account_id: typing.Optional[str] = OMIT,
measure_unit_id: typing.Optional[str] = OMIT,
price: typing.Optional[Price] = OMIT,
@@ -478,6 +532,9 @@ async def create(
description : typing.Optional[str]
Description of the product.
+ external_reference : typing.Optional[str]
+ A user-defined identifier of the product. For example, an internal product code or SKU (stock keeping unit). Client applications can use this field to map the products in Monite to an external product catalog.
+
ledger_account_id : typing.Optional[str]
measure_unit_id : typing.Optional[str]
@@ -501,16 +558,29 @@ async def create(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.products.create(name='name', )
+ await client.products.create(
+ name="name",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
name=name,
description=description,
+ external_reference=external_reference,
ledger_account_id=ledger_account_id,
measure_unit_id=measure_unit_id,
price=price,
@@ -538,11 +608,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.products.get_by_id(product_id='product_id', )
+ await client.products.get_by_id(
+ product_id="product_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(product_id, request_options=request_options)
@@ -563,11 +645,23 @@ async def delete_by_id(self, product_id: str, *, request_options: typing.Optiona
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.products.delete_by_id(product_id='product_id', )
+ await client.products.delete_by_id(
+ product_id="product_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(product_id, request_options=request_options)
@@ -578,6 +672,7 @@ async def update_by_id(
product_id: str,
*,
description: typing.Optional[str] = OMIT,
+ external_reference: typing.Optional[str] = OMIT,
ledger_account_id: typing.Optional[str] = OMIT,
measure_unit_id: typing.Optional[str] = OMIT,
name: typing.Optional[str] = OMIT,
@@ -594,6 +689,9 @@ async def update_by_id(
description : typing.Optional[str]
Description of the product.
+ external_reference : typing.Optional[str]
+ A user-defined identifier of the product. For example, an internal product code or SKU (stock keeping unit). Client applications can use this field to map the products in Monite to an external product catalog.
+
ledger_account_id : typing.Optional[str]
measure_unit_id : typing.Optional[str]
@@ -620,16 +718,29 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.products.update_by_id(product_id='product_id', )
+ await client.products.update_by_id(
+ product_id="product_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
product_id,
description=description,
+ external_reference=external_reference,
ledger_account_id=ledger_account_id,
measure_unit_id=measure_unit_id,
name=name,
diff --git a/src/monite/products/raw_client.py b/src/monite/products/raw_client.py
index f6fc9d5..7b594f5 100644
--- a/src/monite/products/raw_client.py
+++ b/src/monite/products/raw_client.py
@@ -222,6 +222,7 @@ def create(
*,
name: str,
description: typing.Optional[str] = OMIT,
+ external_reference: typing.Optional[str] = OMIT,
ledger_account_id: typing.Optional[str] = OMIT,
measure_unit_id: typing.Optional[str] = OMIT,
price: typing.Optional[Price] = OMIT,
@@ -238,6 +239,9 @@ def create(
description : typing.Optional[str]
Description of the product.
+ external_reference : typing.Optional[str]
+ A user-defined identifier of the product. For example, an internal product code or SKU (stock keeping unit). Client applications can use this field to map the products in Monite to an external product catalog.
+
ledger_account_id : typing.Optional[str]
measure_unit_id : typing.Optional[str]
@@ -264,6 +268,7 @@ def create(
method="POST",
json={
"description": description,
+ "external_reference": external_reference,
"ledger_account_id": ledger_account_id,
"measure_unit_id": measure_unit_id,
"name": name,
@@ -548,6 +553,7 @@ def update_by_id(
product_id: str,
*,
description: typing.Optional[str] = OMIT,
+ external_reference: typing.Optional[str] = OMIT,
ledger_account_id: typing.Optional[str] = OMIT,
measure_unit_id: typing.Optional[str] = OMIT,
name: typing.Optional[str] = OMIT,
@@ -564,6 +570,9 @@ def update_by_id(
description : typing.Optional[str]
Description of the product.
+ external_reference : typing.Optional[str]
+ A user-defined identifier of the product. For example, an internal product code or SKU (stock keeping unit). Client applications can use this field to map the products in Monite to an external product catalog.
+
ledger_account_id : typing.Optional[str]
measure_unit_id : typing.Optional[str]
@@ -593,6 +602,7 @@ def update_by_id(
method="PATCH",
json={
"description": description,
+ "external_reference": external_reference,
"ledger_account_id": ledger_account_id,
"measure_unit_id": measure_unit_id,
"name": name,
@@ -880,6 +890,7 @@ async def create(
*,
name: str,
description: typing.Optional[str] = OMIT,
+ external_reference: typing.Optional[str] = OMIT,
ledger_account_id: typing.Optional[str] = OMIT,
measure_unit_id: typing.Optional[str] = OMIT,
price: typing.Optional[Price] = OMIT,
@@ -896,6 +907,9 @@ async def create(
description : typing.Optional[str]
Description of the product.
+ external_reference : typing.Optional[str]
+ A user-defined identifier of the product. For example, an internal product code or SKU (stock keeping unit). Client applications can use this field to map the products in Monite to an external product catalog.
+
ledger_account_id : typing.Optional[str]
measure_unit_id : typing.Optional[str]
@@ -922,6 +936,7 @@ async def create(
method="POST",
json={
"description": description,
+ "external_reference": external_reference,
"ledger_account_id": ledger_account_id,
"measure_unit_id": measure_unit_id,
"name": name,
@@ -1206,6 +1221,7 @@ async def update_by_id(
product_id: str,
*,
description: typing.Optional[str] = OMIT,
+ external_reference: typing.Optional[str] = OMIT,
ledger_account_id: typing.Optional[str] = OMIT,
measure_unit_id: typing.Optional[str] = OMIT,
name: typing.Optional[str] = OMIT,
@@ -1222,6 +1238,9 @@ async def update_by_id(
description : typing.Optional[str]
Description of the product.
+ external_reference : typing.Optional[str]
+ A user-defined identifier of the product. For example, an internal product code or SKU (stock keeping unit). Client applications can use this field to map the products in Monite to an external product catalog.
+
ledger_account_id : typing.Optional[str]
measure_unit_id : typing.Optional[str]
@@ -1251,6 +1270,7 @@ async def update_by_id(
method="PATCH",
json={
"description": description,
+ "external_reference": external_reference,
"ledger_account_id": ledger_account_id,
"measure_unit_id": measure_unit_id,
"name": name,
diff --git a/src/monite/projects/client.py b/src/monite/projects/client.py
index 0f5e698..7fd7bd8 100644
--- a/src/monite/projects/client.py
+++ b/src/monite/projects/client.py
@@ -129,7 +129,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.projects.get()
"""
_response = self._raw_client.get(
@@ -218,8 +223,15 @@ def create(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.projects.create(name='Marketing', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.projects.create(
+ name="Marketing",
+ )
"""
_response = self._raw_client.create(
name=name,
@@ -254,8 +266,15 @@ def get_by_id(self, project_id: str, *, request_options: typing.Optional[Request
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.projects.get_by_id(project_id='project_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.projects.get_by_id(
+ project_id="project_id",
+ )
"""
_response = self._raw_client.get_by_id(project_id, request_options=request_options)
return _response.data
@@ -278,8 +297,15 @@ def delete_by_id(self, project_id: str, *, request_options: typing.Optional[Requ
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.projects.delete_by_id(project_id='project_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.projects.delete_by_id(
+ project_id="project_id",
+ )
"""
_response = self._raw_client.delete_by_id(project_id, request_options=request_options)
return _response.data
@@ -344,8 +370,15 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.projects.update_by_id(project_id='project_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.projects.update_by_id(
+ project_id="project_id",
+ )
"""
_response = self._raw_client.update_by_id(
project_id,
@@ -476,11 +509,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.projects.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
@@ -568,11 +611,23 @@ async def create(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.projects.create(name='Marketing', )
+ await client.projects.create(
+ name="Marketing",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -609,11 +664,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.projects.get_by_id(project_id='project_id', )
+ await client.projects.get_by_id(
+ project_id="project_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(project_id, request_options=request_options)
@@ -636,11 +703,23 @@ async def delete_by_id(self, project_id: str, *, request_options: typing.Optiona
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.projects.delete_by_id(project_id='project_id', )
+ await client.projects.delete_by_id(
+ project_id="project_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(project_id, request_options=request_options)
@@ -705,11 +784,23 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.projects.update_by_id(project_id='project_id', )
+ await client.projects.update_by_id(
+ project_id="project_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
diff --git a/src/monite/purchase_orders/client.py b/src/monite/purchase_orders/client.py
index ed4604b..9028724 100644
--- a/src/monite/purchase_orders/client.py
+++ b/src/monite/purchase_orders/client.py
@@ -139,7 +139,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.purchase_orders.get()
"""
_response = self._raw_client.get(
@@ -223,10 +228,29 @@ def create(
Examples
--------
- from monite import Monite
- from monite import PurchaseOrderItem
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.purchase_orders.create(counterpart_id='counterpart_id', currency="AED", items=[PurchaseOrderItem(currency="AED", name='name', price=1, quantity=1, unit='unit', vat_rate=1, )], message='message', valid_for_days=1, )
+ from monite import Monite, PurchaseOrderItem
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.purchase_orders.create(
+ counterpart_id="counterpart_id",
+ currency="AED",
+ items=[
+ PurchaseOrderItem(
+ currency="AED",
+ name="name",
+ price=1,
+ quantity=1,
+ unit="unit",
+ vat_rate=1,
+ )
+ ],
+ message="message",
+ valid_for_days=1,
+ )
"""
_response = self._raw_client.create(
counterpart_id=counterpart_id,
@@ -258,7 +282,12 @@ def get_variables(self, *, request_options: typing.Optional[RequestOptions] = No
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.purchase_orders.get_variables()
"""
_response = self._raw_client.get_variables(request_options=request_options)
@@ -283,8 +312,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.purchase_orders.get_by_id(purchase_order_id='purchase_order_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.purchase_orders.get_by_id(
+ purchase_order_id="purchase_order_id",
+ )
"""
_response = self._raw_client.get_by_id(purchase_order_id, request_options=request_options)
return _response.data
@@ -305,8 +341,15 @@ def delete_by_id(self, purchase_order_id: str, *, request_options: typing.Option
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.purchase_orders.delete_by_id(purchase_order_id='purchase_order_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.purchase_orders.delete_by_id(
+ purchase_order_id="purchase_order_id",
+ )
"""
_response = self._raw_client.delete_by_id(purchase_order_id, request_options=request_options)
return _response.data
@@ -361,8 +404,15 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.purchase_orders.update_by_id(purchase_order_id='purchase_order_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.purchase_orders.update_by_id(
+ purchase_order_id="purchase_order_id",
+ )
"""
_response = self._raw_client.update_by_id(
purchase_order_id,
@@ -405,8 +455,17 @@ def preview_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.purchase_orders.preview_by_id(purchase_order_id='purchase_order_id', body_text='body_text', subject_text='subject_text', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.purchase_orders.preview_by_id(
+ purchase_order_id="purchase_order_id",
+ body_text="body_text",
+ subject_text="subject_text",
+ )
"""
_response = self._raw_client.preview_by_id(
purchase_order_id, body_text=body_text, subject_text=subject_text, request_options=request_options
@@ -441,8 +500,17 @@ def send_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.purchase_orders.send_by_id(purchase_order_id='purchase_order_id', body_text='body_text', subject_text='subject_text', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.purchase_orders.send_by_id(
+ purchase_order_id="purchase_order_id",
+ body_text="body_text",
+ subject_text="subject_text",
+ )
"""
_response = self._raw_client.send_by_id(
purchase_order_id, body_text=body_text, subject_text=subject_text, request_options=request_options
@@ -567,11 +635,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.purchase_orders.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
@@ -655,12 +733,36 @@ async def create(
Examples
--------
- from monite import AsyncMonite
- from monite import PurchaseOrderItem
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite, PurchaseOrderItem
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.purchase_orders.create(counterpart_id='counterpart_id', currency="AED", items=[PurchaseOrderItem(currency="AED", name='name', price=1, quantity=1, unit='unit', vat_rate=1, )], message='message', valid_for_days=1, )
+ await client.purchase_orders.create(
+ counterpart_id="counterpart_id",
+ currency="AED",
+ items=[
+ PurchaseOrderItem(
+ currency="AED",
+ name="name",
+ price=1,
+ quantity=1,
+ unit="unit",
+ vat_rate=1,
+ )
+ ],
+ message="message",
+ valid_for_days=1,
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -692,11 +794,21 @@ async def get_variables(self, *, request_options: typing.Optional[RequestOptions
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.purchase_orders.get_variables()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_variables(request_options=request_options)
@@ -720,11 +832,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.purchase_orders.get_by_id(purchase_order_id='purchase_order_id', )
+ await client.purchase_orders.get_by_id(
+ purchase_order_id="purchase_order_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(purchase_order_id, request_options=request_options)
@@ -747,11 +871,23 @@ async def delete_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.purchase_orders.delete_by_id(purchase_order_id='purchase_order_id', )
+ await client.purchase_orders.delete_by_id(
+ purchase_order_id="purchase_order_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(purchase_order_id, request_options=request_options)
@@ -806,11 +942,23 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.purchase_orders.update_by_id(purchase_order_id='purchase_order_id', )
+ await client.purchase_orders.update_by_id(
+ purchase_order_id="purchase_order_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
@@ -853,11 +1001,25 @@ async def preview_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.purchase_orders.preview_by_id(purchase_order_id='purchase_order_id', body_text='body_text', subject_text='subject_text', )
+ await client.purchase_orders.preview_by_id(
+ purchase_order_id="purchase_order_id",
+ body_text="body_text",
+ subject_text="subject_text",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.preview_by_id(
@@ -892,11 +1054,25 @@ async def send_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.purchase_orders.send_by_id(purchase_order_id='purchase_order_id', body_text='body_text', subject_text='subject_text', )
+ await client.purchase_orders.send_by_id(
+ purchase_order_id="purchase_order_id",
+ body_text="body_text",
+ subject_text="subject_text",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.send_by_id(
diff --git a/src/monite/receivables/__init__.py b/src/monite/receivables/__init__.py
index bb149b9..446c0ea 100644
--- a/src/monite/receivables/__init__.py
+++ b/src/monite/receivables/__init__.py
@@ -2,6 +2,6 @@
# isort: skip_file
-from .types import ReceivablesGetRequestStatus, ReceivablesGetRequestStatusInItem
+from .types import ReceivablesGetRequestStatus, ReceivablesGetRequestStatusInItem, ReceivablesSearchRequestStatus
-__all__ = ["ReceivablesGetRequestStatus", "ReceivablesGetRequestStatusInItem"]
+__all__ = ["ReceivablesGetRequestStatus", "ReceivablesGetRequestStatusInItem", "ReceivablesSearchRequestStatus"]
diff --git a/src/monite/receivables/client.py b/src/monite/receivables/client.py
index eb37999..1398226 100644
--- a/src/monite/receivables/client.py
+++ b/src/monite/receivables/client.py
@@ -12,6 +12,7 @@
from ..types.line_items_response import LineItemsResponse
from ..types.order_enum import OrderEnum
from ..types.receivable_cursor_fields import ReceivableCursorFields
+from ..types.receivable_cursor_fields2 import ReceivableCursorFields2
from ..types.receivable_facade_create_payload import ReceivableFacadeCreatePayload
from ..types.receivable_file_url import ReceivableFileUrl
from ..types.receivable_history_cursor_fields import ReceivableHistoryCursorFields
@@ -40,6 +41,7 @@
from .raw_client import AsyncRawReceivablesClient, RawReceivablesClient
from .types.receivables_get_request_status import ReceivablesGetRequestStatus
from .types.receivables_get_request_status_in_item import ReceivablesGetRequestStatusInItem
+from .types.receivables_search_request_status import ReceivablesSearchRequestStatus
# this is used as the default value for optional parameters
OMIT = typing.cast(typing.Any, ...)
@@ -98,6 +100,11 @@ def get(
total_amount_lt: typing.Optional[int] = None,
total_amount_gte: typing.Optional[int] = None,
total_amount_lte: typing.Optional[int] = None,
+ discounted_subtotal: typing.Optional[int] = None,
+ discounted_subtotal_gt: typing.Optional[int] = None,
+ discounted_subtotal_lt: typing.Optional[int] = None,
+ discounted_subtotal_gte: typing.Optional[int] = None,
+ discounted_subtotal_lte: typing.Optional[int] = None,
status: typing.Optional[ReceivablesGetRequestStatus] = None,
entity_user_id: typing.Optional[str] = None,
based_on: typing.Optional[str] = None,
@@ -319,6 +326,16 @@ def get(
total_amount_lte : typing.Optional[int]
+ discounted_subtotal : typing.Optional[int]
+
+ discounted_subtotal_gt : typing.Optional[int]
+
+ discounted_subtotal_lt : typing.Optional[int]
+
+ discounted_subtotal_gte : typing.Optional[int]
+
+ discounted_subtotal_lte : typing.Optional[int]
+
status : typing.Optional[ReceivablesGetRequestStatus]
entity_user_id : typing.Optional[str]
@@ -346,7 +363,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.receivables.get()
"""
_response = self._raw_client.get(
@@ -383,6 +405,11 @@ def get(
total_amount_lt=total_amount_lt,
total_amount_gte=total_amount_gte,
total_amount_lte=total_amount_lte,
+ discounted_subtotal=discounted_subtotal,
+ discounted_subtotal_gt=discounted_subtotal_gt,
+ discounted_subtotal_lt=discounted_subtotal_lt,
+ discounted_subtotal_gte=discounted_subtotal_gte,
+ discounted_subtotal_lte=discounted_subtotal_lte,
status=status,
entity_user_id=entity_user_id,
based_on=based_on,
@@ -413,11 +440,25 @@ def create(
Examples
--------
- from monite import Monite
- from monite import ReceivableFacadeCreateQuotePayload
- from monite import LineItem
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.receivables.create(request=ReceivableFacadeCreateQuotePayload(counterpart_billing_address_id='counterpart_billing_address_id', counterpart_id='counterpart_id', currency="AED", line_items=[LineItem(quantity=1.1, )], ), )
+ from monite import LineItem, Monite, ReceivableFacadeCreateQuotePayload
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.receivables.create(
+ request=ReceivableFacadeCreateQuotePayload(
+ counterpart_billing_address_id="counterpart_billing_address_id",
+ counterpart_id="counterpart_id",
+ currency="AED",
+ line_items=[
+ LineItem(
+ quantity=1.1,
+ )
+ ],
+ ),
+ )
"""
_response = self._raw_client.create(request=request, request_options=request_options)
return _response.data
@@ -461,7 +502,12 @@ def get_receivables_required_fields(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.receivables.get_receivables_required_fields()
"""
_response = self._raw_client.get_receivables_required_fields(
@@ -475,6 +521,281 @@ def get_receivables_required_fields(
)
return _response.data
+ def post_receivables_search(
+ self,
+ *,
+ discounted_subtotal: typing.Optional[int] = OMIT,
+ discounted_subtotal_gt: typing.Optional[int] = OMIT,
+ discounted_subtotal_gte: typing.Optional[int] = OMIT,
+ discounted_subtotal_lt: typing.Optional[int] = OMIT,
+ discounted_subtotal_lte: typing.Optional[int] = OMIT,
+ based_on: typing.Optional[str] = OMIT,
+ counterpart_id: typing.Optional[str] = OMIT,
+ counterpart_name: typing.Optional[str] = OMIT,
+ counterpart_name_contains: typing.Optional[str] = OMIT,
+ counterpart_name_icontains: typing.Optional[str] = OMIT,
+ created_at_gt: typing.Optional[dt.datetime] = OMIT,
+ created_at_gte: typing.Optional[dt.datetime] = OMIT,
+ created_at_lt: typing.Optional[dt.datetime] = OMIT,
+ created_at_lte: typing.Optional[dt.datetime] = OMIT,
+ document_id: typing.Optional[str] = OMIT,
+ document_id_contains: typing.Optional[str] = OMIT,
+ document_id_icontains: typing.Optional[str] = OMIT,
+ due_date_gt: typing.Optional[str] = OMIT,
+ due_date_gte: typing.Optional[str] = OMIT,
+ due_date_lt: typing.Optional[str] = OMIT,
+ due_date_lte: typing.Optional[str] = OMIT,
+ entity_user_id: typing.Optional[str] = OMIT,
+ entity_user_id_in: typing.Optional[typing.Sequence[str]] = OMIT,
+ id_in: typing.Optional[typing.Sequence[str]] = OMIT,
+ issue_date_gt: typing.Optional[dt.datetime] = OMIT,
+ issue_date_gte: typing.Optional[dt.datetime] = OMIT,
+ issue_date_lt: typing.Optional[dt.datetime] = OMIT,
+ issue_date_lte: typing.Optional[dt.datetime] = OMIT,
+ limit: typing.Optional[int] = OMIT,
+ order: typing.Optional[OrderEnum] = OMIT,
+ pagination_token: typing.Optional[str] = OMIT,
+ product_ids: typing.Optional[typing.Sequence[str]] = OMIT,
+ product_ids_in: typing.Optional[typing.Sequence[str]] = OMIT,
+ project_id: typing.Optional[str] = OMIT,
+ project_id_in: typing.Optional[typing.Sequence[str]] = OMIT,
+ sort: typing.Optional[ReceivableCursorFields2] = OMIT,
+ status: typing.Optional[ReceivablesSearchRequestStatus] = OMIT,
+ status_in: typing.Optional[typing.Sequence[str]] = OMIT,
+ tag_ids: typing.Optional[typing.Sequence[str]] = OMIT,
+ tag_ids_in: typing.Optional[typing.Sequence[str]] = OMIT,
+ total_amount: typing.Optional[int] = OMIT,
+ total_amount_gt: typing.Optional[int] = OMIT,
+ total_amount_gte: typing.Optional[int] = OMIT,
+ total_amount_lt: typing.Optional[int] = OMIT,
+ total_amount_lte: typing.Optional[int] = OMIT,
+ type: typing.Optional[ReceivableType] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> ReceivablePaginationResponse:
+ """
+ This is a POST version of the `GET /receivables` endpoint. Use it to send search and filter parameters in the request body instead of the URL query string in case the query is too long and exceeds the URL length limit of your HTTP client.
+
+ Parameters
+ ----------
+ discounted_subtotal : typing.Optional[int]
+ Return only receivables with the exact specified discounted subtotal. The amount must be specified in the [minor units](https://docs.monite.com/references/currencies#minor-units) of currency. For example, $12.5 is represented as 1250.
+
+ discounted_subtotal_gt : typing.Optional[int]
+ Return only receivables whose discounted subtotal (in minor units) is greater than the specified value.
+
+ discounted_subtotal_gte : typing.Optional[int]
+ Return only receivables whose discounted subtotal (in minor units) is greater than or equal to the specified value.
+
+ discounted_subtotal_lt : typing.Optional[int]
+ Return only receivables whose discounted subtotal (in minor units) is less than the specified value.
+
+ discounted_subtotal_lte : typing.Optional[int]
+ Return only receivables whose discounted subtotal (in minor units) is less than or equal to the specified value.
+
+ based_on : typing.Optional[str]
+ This parameter accepts a quote ID or an invoice ID.
+
+ * Specify a quote ID to find invoices created from this quote.
+ * Specify an invoice ID to find credit notes created for this invoice.
+
+ Valid but nonexistent IDs do not raise errors but produce no results.
+
+ counterpart_id : typing.Optional[str]
+ Return only receivables created for the counterpart with the specified ID.
+
+ Counterparts that have been deleted but have associated receivables will still return results here because the receivables contain a frozen copy of the counterpart data.
+
+ If the specified counterpart ID does not exist and never existed, no results are returned.
+
+ counterpart_name : typing.Optional[str]
+ Return only receivables created for counterparts with the specified name (exact match, case-sensitive). For counterparts of `type` = `individual`, the full name is formatted as `first_name last_name`.
+
+ counterpart_name_contains : typing.Optional[str]
+ Return only receivables created for counterparts whose name contains the specified string (case-sensitive).
+
+ counterpart_name_icontains : typing.Optional[str]
+ Return only receivables created for counterparts whose name contains the specified string (case-insensitive).
+
+ created_at_gt : typing.Optional[dt.datetime]
+ Return only receivables created after the specified date and time. The value must be in the ISO 8601 format `YYYY-MM-DDThh:mm[:ss[.ffffff]][Z|±hh:mm]`.
+
+ created_at_gte : typing.Optional[dt.datetime]
+ Return only receivables created on or after the specified date and time.
+
+ created_at_lt : typing.Optional[dt.datetime]
+ Return only receivables created before the specified date and time.
+
+ created_at_lte : typing.Optional[dt.datetime]
+ Return only receivables created before or on the specified date and time.
+
+ document_id : typing.Optional[str]
+ Return a receivable with the exact specified document number (case-sensitive). The `document_id` is the user-facing document number such as INV-00042, not to be confused with Monite resource IDs (`id`).
+
+ document_id_contains : typing.Optional[str]
+ Return only receivables whose document number (`document_id`) contains the specified string (case-sensitive).
+
+ document_id_icontains : typing.Optional[str]
+ Return only receivables whose document number (`document_id`) contains the specified string (case-insensitive).
+
+ due_date_gt : typing.Optional[str]
+ Return invoices that are due after the specified date (exclusive, `YYYY-MM-DD`).
+
+ This filter excludes quotes, credit notes, and draft invoices.
+
+ due_date_gte : typing.Optional[str]
+ Return invoices that are due on or after the specified date (`YYYY-MM-DD`).
+
+ This filter excludes quotes, credit notes, and draft invoices.
+
+ due_date_lt : typing.Optional[str]
+ Return invoices that are due before the specified date (exclusive, `YYYY-MM-DD`).
+
+ This filter excludes quotes, credit notes, and draft invoices.
+
+ due_date_lte : typing.Optional[str]
+ Return invoices that are due before or on the specified date (`YYYY-MM-DD`).
+
+ This filter excludes quotes, credit notes, and draft invoices.
+
+ entity_user_id : typing.Optional[str]
+ Return only receivables created by the entity user with the specified ID. To query receivables by multiple user IDs at once, use the `entity_user_id__in` parameter instead.
+
+ If the request is authenticated using an entity user token, this user must have the `receivable.read.allowed` (rather than `allowed_for_own`) permission to be able to query receivables created by other users.
+
+ IDs of deleted users will still produce results here if those users had associated receivables. Valid but nonexistent user IDs do not raise errors but produce no results.
+
+ entity_user_id_in : typing.Optional[typing.Sequence[str]]
+
+ id_in : typing.Optional[typing.Sequence[str]]
+
+ issue_date_gt : typing.Optional[dt.datetime]
+ Return only non-draft receivables that were issued after the specified date and time. The value must be in the ISO 8601 format `YYYY-MM-DDThh:mm[:ss[.ffffff]][Z|±hh:mm]`.
+
+ issue_date_gte : typing.Optional[dt.datetime]
+ Return only non-draft receivables that were issued on or after the specified date and time.
+
+ issue_date_lt : typing.Optional[dt.datetime]
+ Return only non-draft receivables that were issued before the specified date and time.
+
+ issue_date_lte : typing.Optional[dt.datetime]
+ Return only non-draft receivables that were issued before or on the specified date and time.
+
+ limit : typing.Optional[int]
+
+ order : typing.Optional[OrderEnum]
+
+ pagination_token : typing.Optional[str]
+
+ product_ids : typing.Optional[typing.Sequence[str]]
+
+ product_ids_in : typing.Optional[typing.Sequence[str]]
+
+ project_id : typing.Optional[str]
+ Return only receivables assigned to the project with the specified ID. Valid but nonexistent project IDs do not raise errors but return no results.
+
+ project_id_in : typing.Optional[typing.Sequence[str]]
+
+ sort : typing.Optional[ReceivableCursorFields2]
+
+ status : typing.Optional[ReceivablesSearchRequestStatus]
+ Return only receivables that have the specified status. See the applicable [invoice statuses](https://docs.monite.com/accounts-receivable/invoices/index), [quote statuses](https://docs.monite.com/accounts-receivable/quotes/index), and [credit note statuses](https://docs.monite.com/accounts-receivable/credit-notes#credit-note-lifecycle).
+
+ To query multiple statuses at once, use the `status__in` parameter instead.
+
+ status_in : typing.Optional[typing.Sequence[str]]
+
+ tag_ids : typing.Optional[typing.Sequence[str]]
+
+ tag_ids_in : typing.Optional[typing.Sequence[str]]
+
+ total_amount : typing.Optional[int]
+ Return only receivables with the exact specified total amount. The amount must be specified in the [minor units](https://docs.monite.com/references/currencies#minor-units) of currency. For example, $12.5 is represented as 1250.
+
+ total_amount_gt : typing.Optional[int]
+ Return only receivables whose total amount (in minor units) exceeds the specified value.
+
+ total_amount_gte : typing.Optional[int]
+ Return only receivables whose total amount (in minor units) is greater than or equal to the specified value.
+
+ total_amount_lt : typing.Optional[int]
+ Return only receivables whose total amount (in minor units) is less than the specified value.
+
+ total_amount_lte : typing.Optional[int]
+ Return only receivables whose total amount (in minor units) is less than or equal to the specified value.
+
+ type : typing.Optional[ReceivableType]
+ Return only receivables of the specified type. Use this parameter to get only invoices, or only quotes, or only credit notes.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ ReceivablePaginationResponse
+ Successful Response
+
+ Examples
+ --------
+ from monite import Monite
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.receivables.post_receivables_search()
+ """
+ _response = self._raw_client.post_receivables_search(
+ discounted_subtotal=discounted_subtotal,
+ discounted_subtotal_gt=discounted_subtotal_gt,
+ discounted_subtotal_gte=discounted_subtotal_gte,
+ discounted_subtotal_lt=discounted_subtotal_lt,
+ discounted_subtotal_lte=discounted_subtotal_lte,
+ based_on=based_on,
+ counterpart_id=counterpart_id,
+ counterpart_name=counterpart_name,
+ counterpart_name_contains=counterpart_name_contains,
+ counterpart_name_icontains=counterpart_name_icontains,
+ created_at_gt=created_at_gt,
+ created_at_gte=created_at_gte,
+ created_at_lt=created_at_lt,
+ created_at_lte=created_at_lte,
+ document_id=document_id,
+ document_id_contains=document_id_contains,
+ document_id_icontains=document_id_icontains,
+ due_date_gt=due_date_gt,
+ due_date_gte=due_date_gte,
+ due_date_lt=due_date_lt,
+ due_date_lte=due_date_lte,
+ entity_user_id=entity_user_id,
+ entity_user_id_in=entity_user_id_in,
+ id_in=id_in,
+ issue_date_gt=issue_date_gt,
+ issue_date_gte=issue_date_gte,
+ issue_date_lt=issue_date_lt,
+ issue_date_lte=issue_date_lte,
+ limit=limit,
+ order=order,
+ pagination_token=pagination_token,
+ product_ids=product_ids,
+ product_ids_in=product_ids_in,
+ project_id=project_id,
+ project_id_in=project_id_in,
+ sort=sort,
+ status=status,
+ status_in=status_in,
+ tag_ids=tag_ids,
+ tag_ids_in=tag_ids_in,
+ total_amount=total_amount,
+ total_amount_gt=total_amount_gt,
+ total_amount_gte=total_amount_gte,
+ total_amount_lt=total_amount_lt,
+ total_amount_lte=total_amount_lte,
+ type=type,
+ request_options=request_options,
+ )
+ return _response.data
+
def get_variables(
self, *, request_options: typing.Optional[RequestOptions] = None
) -> ReceivableTemplatesVariablesObjectList:
@@ -494,7 +815,12 @@ def get_variables(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.receivables.get_variables()
"""
_response = self._raw_client.get_variables(request_options=request_options)
@@ -519,8 +845,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.receivables.get_by_id(receivable_id='receivable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.receivables.get_by_id(
+ receivable_id="receivable_id",
+ )
"""
_response = self._raw_client.get_by_id(receivable_id, request_options=request_options)
return _response.data
@@ -541,8 +874,15 @@ def delete_by_id(self, receivable_id: str, *, request_options: typing.Optional[R
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.receivables.delete_by_id(receivable_id='receivable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.receivables.delete_by_id(
+ receivable_id="receivable_id",
+ )
"""
_response = self._raw_client.delete_by_id(receivable_id, request_options=request_options)
return _response.data
@@ -571,11 +911,19 @@ def update_by_id(
Examples
--------
- from monite import Monite
- from monite import UpdateQuotePayload
- from monite import UpdateQuote
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.receivables.update_by_id(receivable_id='receivable_id', request=UpdateQuotePayload(quote=UpdateQuote(), ), )
+ from monite import Monite, UpdateQuote, UpdateQuotePayload
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.receivables.update_by_id(
+ receivable_id="receivable_id",
+ request=UpdateQuotePayload(
+ quote=UpdateQuote(),
+ ),
+ )
"""
_response = self._raw_client.update_by_id(receivable_id, request=request, request_options=request_options)
return _response.data
@@ -606,8 +954,15 @@ def accept_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.receivables.accept_by_id(receivable_id='receivable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.receivables.accept_by_id(
+ receivable_id="receivable_id",
+ )
"""
_response = self._raw_client.accept_by_id(receivable_id, signature=signature, request_options=request_options)
return _response.data
@@ -628,8 +983,15 @@ def cancel_by_id(self, receivable_id: str, *, request_options: typing.Optional[R
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.receivables.cancel_by_id(receivable_id='receivable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.receivables.cancel_by_id(
+ receivable_id="receivable_id",
+ )
"""
_response = self._raw_client.cancel_by_id(receivable_id, request_options=request_options)
return _response.data
@@ -653,8 +1015,15 @@ def clone_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.receivables.clone_by_id(receivable_id='receivable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.receivables.clone_by_id(
+ receivable_id="receivable_id",
+ )
"""
_response = self._raw_client.clone_by_id(receivable_id, request_options=request_options)
return _response.data
@@ -685,8 +1054,15 @@ def decline_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.receivables.decline_by_id(receivable_id='receivable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.receivables.decline_by_id(
+ receivable_id="receivable_id",
+ )
"""
_response = self._raw_client.decline_by_id(receivable_id, comment=comment, request_options=request_options)
return _response.data
@@ -764,8 +1140,15 @@ def get_history(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.receivables.get_history(receivable_id='receivable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.receivables.get_history(
+ receivable_id="receivable_id",
+ )
"""
_response = self._raw_client.get_history(
receivable_id,
@@ -808,8 +1191,16 @@ def get_history_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.receivables.get_history_by_id(receivable_history_id='receivable_history_id', receivable_id='receivable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.receivables.get_history_by_id(
+ receivable_history_id="receivable_history_id",
+ receivable_id="receivable_id",
+ )
"""
_response = self._raw_client.get_history_by_id(
receivable_history_id, receivable_id, request_options=request_options
@@ -835,8 +1226,15 @@ def issue_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.receivables.issue_by_id(receivable_id='receivable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.receivables.issue_by_id(
+ receivable_id="receivable_id",
+ )
"""
_response = self._raw_client.issue_by_id(receivable_id, request_options=request_options)
return _response.data
@@ -867,10 +1265,21 @@ def update_line_items_by_id(
Examples
--------
- from monite import Monite
- from monite import LineItem
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.receivables.update_line_items_by_id(receivable_id='receivable_id', data=[LineItem(quantity=1.1, )], )
+ from monite import LineItem, Monite
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.receivables.update_line_items_by_id(
+ receivable_id="receivable_id",
+ data=[
+ LineItem(
+ quantity=1.1,
+ )
+ ],
+ )
"""
_response = self._raw_client.update_line_items_by_id(receivable_id, data=data, request_options=request_options)
return _response.data
@@ -935,8 +1344,15 @@ def get_mails(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.receivables.get_mails(receivable_id='receivable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.receivables.get_mails(
+ receivable_id="receivable_id",
+ )
"""
_response = self._raw_client.get_mails(
receivable_id,
@@ -975,8 +1391,16 @@ def get_mail_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.receivables.get_mail_by_id(receivable_id='receivable_id', mail_id='mail_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.receivables.get_mail_by_id(
+ receivable_id="receivable_id",
+ mail_id="mail_id",
+ )
"""
_response = self._raw_client.get_mail_by_id(receivable_id, mail_id, request_options=request_options)
return _response.data
@@ -1011,8 +1435,15 @@ def mark_as_paid_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.receivables.mark_as_paid_by_id(receivable_id='receivable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.receivables.mark_as_paid_by_id(
+ receivable_id="receivable_id",
+ )
"""
_response = self._raw_client.mark_as_paid_by_id(
receivable_id, comment=comment, paid_at=paid_at, request_options=request_options
@@ -1051,8 +1482,16 @@ def mark_as_partially_paid_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.receivables.mark_as_partially_paid_by_id(receivable_id='receivable_id', amount_paid=1, )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.receivables.mark_as_partially_paid_by_id(
+ receivable_id="receivable_id",
+ amount_paid=1,
+ )
"""
_response = self._raw_client.mark_as_partially_paid_by_id(
receivable_id, amount_paid=amount_paid, comment=comment, request_options=request_options
@@ -1085,8 +1524,15 @@ def mark_as_uncollectible_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.receivables.mark_as_uncollectible_by_id(receivable_id='receivable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.receivables.mark_as_uncollectible_by_id(
+ receivable_id="receivable_id",
+ )
"""
_response = self._raw_client.mark_as_uncollectible_by_id(
receivable_id, comment=comment, request_options=request_options
@@ -1112,8 +1558,15 @@ def get_pdf_link_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.receivables.get_pdf_link_by_id(receivable_id='receivable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.receivables.get_pdf_link_by_id(
+ receivable_id="receivable_id",
+ )
"""
_response = self._raw_client.get_pdf_link_by_id(receivable_id, request_options=request_options)
return _response.data
@@ -1156,8 +1609,17 @@ def preview_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.receivables.preview_by_id(receivable_id='receivable_id', body_text='body_text', subject_text='subject_text', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.receivables.preview_by_id(
+ receivable_id="receivable_id",
+ body_text="body_text",
+ subject_text="subject_text",
+ )
"""
_response = self._raw_client.preview_by_id(
receivable_id,
@@ -1202,8 +1664,17 @@ def send_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.receivables.send_by_id(receivable_id='receivable_id', body_text='body_text', subject_text='subject_text', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.receivables.send_by_id(
+ receivable_id="receivable_id",
+ body_text="body_text",
+ subject_text="subject_text",
+ )
"""
_response = self._raw_client.send_by_id(
receivable_id,
@@ -1243,8 +1714,16 @@ def send_test_reminder_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.receivables.send_test_reminder_by_id(receivable_id='receivable_id', reminder_type="term_1", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.receivables.send_test_reminder_by_id(
+ receivable_id="receivable_id",
+ reminder_type="term_1",
+ )
"""
_response = self._raw_client.send_test_reminder_by_id(
receivable_id, reminder_type=reminder_type, recipients=recipients, request_options=request_options
@@ -1270,8 +1749,15 @@ def verify_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.receivables.verify_by_id(receivable_id='receivable_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.receivables.verify_by_id(
+ receivable_id="receivable_id",
+ )
"""
_response = self._raw_client.verify_by_id(receivable_id, request_options=request_options)
return _response.data
@@ -1330,6 +1816,11 @@ async def get(
total_amount_lt: typing.Optional[int] = None,
total_amount_gte: typing.Optional[int] = None,
total_amount_lte: typing.Optional[int] = None,
+ discounted_subtotal: typing.Optional[int] = None,
+ discounted_subtotal_gt: typing.Optional[int] = None,
+ discounted_subtotal_lt: typing.Optional[int] = None,
+ discounted_subtotal_gte: typing.Optional[int] = None,
+ discounted_subtotal_lte: typing.Optional[int] = None,
status: typing.Optional[ReceivablesGetRequestStatus] = None,
entity_user_id: typing.Optional[str] = None,
based_on: typing.Optional[str] = None,
@@ -1551,6 +2042,16 @@ async def get(
total_amount_lte : typing.Optional[int]
+ discounted_subtotal : typing.Optional[int]
+
+ discounted_subtotal_gt : typing.Optional[int]
+
+ discounted_subtotal_lt : typing.Optional[int]
+
+ discounted_subtotal_gte : typing.Optional[int]
+
+ discounted_subtotal_lte : typing.Optional[int]
+
status : typing.Optional[ReceivablesGetRequestStatus]
entity_user_id : typing.Optional[str]
@@ -1577,11 +2078,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.receivables.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
@@ -1618,6 +2129,11 @@ async def main() -> None:
total_amount_lt=total_amount_lt,
total_amount_gte=total_amount_gte,
total_amount_lte=total_amount_lte,
+ discounted_subtotal=discounted_subtotal,
+ discounted_subtotal_gt=discounted_subtotal_gt,
+ discounted_subtotal_lt=discounted_subtotal_lt,
+ discounted_subtotal_gte=discounted_subtotal_gte,
+ discounted_subtotal_lte=discounted_subtotal_lte,
status=status,
entity_user_id=entity_user_id,
based_on=based_on,
@@ -1648,17 +2164,36 @@ async def create(
Examples
--------
- from monite import AsyncMonite
- from monite import ReceivableFacadeCreateQuotePayload
- from monite import LineItem
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- async def main() -> None:
- await client.receivables.create(request=ReceivableFacadeCreateQuotePayload(counterpart_billing_address_id='counterpart_billing_address_id', counterpart_id='counterpart_id', currency="AED", line_items=[LineItem(quantity=1.1, )], ), )
- asyncio.run(main())
- """
- _response = await self._raw_client.create(request=request, request_options=request_options)
- return _response.data
+
+ from monite import AsyncMonite, LineItem, ReceivableFacadeCreateQuotePayload
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
+ async def main() -> None:
+ await client.receivables.create(
+ request=ReceivableFacadeCreateQuotePayload(
+ counterpart_billing_address_id="counterpart_billing_address_id",
+ counterpart_id="counterpart_id",
+ currency="AED",
+ line_items=[
+ LineItem(
+ quantity=1.1,
+ )
+ ],
+ ),
+ )
+
+
+ asyncio.run(main())
+ """
+ _response = await self._raw_client.create(request=request, request_options=request_options)
+ return _response.data
async def get_receivables_required_fields(
self,
@@ -1698,11 +2233,21 @@ async def get_receivables_required_fields(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.receivables.get_receivables_required_fields()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_receivables_required_fields(
@@ -1716,6 +2261,289 @@ async def main() -> None:
)
return _response.data
+ async def post_receivables_search(
+ self,
+ *,
+ discounted_subtotal: typing.Optional[int] = OMIT,
+ discounted_subtotal_gt: typing.Optional[int] = OMIT,
+ discounted_subtotal_gte: typing.Optional[int] = OMIT,
+ discounted_subtotal_lt: typing.Optional[int] = OMIT,
+ discounted_subtotal_lte: typing.Optional[int] = OMIT,
+ based_on: typing.Optional[str] = OMIT,
+ counterpart_id: typing.Optional[str] = OMIT,
+ counterpart_name: typing.Optional[str] = OMIT,
+ counterpart_name_contains: typing.Optional[str] = OMIT,
+ counterpart_name_icontains: typing.Optional[str] = OMIT,
+ created_at_gt: typing.Optional[dt.datetime] = OMIT,
+ created_at_gte: typing.Optional[dt.datetime] = OMIT,
+ created_at_lt: typing.Optional[dt.datetime] = OMIT,
+ created_at_lte: typing.Optional[dt.datetime] = OMIT,
+ document_id: typing.Optional[str] = OMIT,
+ document_id_contains: typing.Optional[str] = OMIT,
+ document_id_icontains: typing.Optional[str] = OMIT,
+ due_date_gt: typing.Optional[str] = OMIT,
+ due_date_gte: typing.Optional[str] = OMIT,
+ due_date_lt: typing.Optional[str] = OMIT,
+ due_date_lte: typing.Optional[str] = OMIT,
+ entity_user_id: typing.Optional[str] = OMIT,
+ entity_user_id_in: typing.Optional[typing.Sequence[str]] = OMIT,
+ id_in: typing.Optional[typing.Sequence[str]] = OMIT,
+ issue_date_gt: typing.Optional[dt.datetime] = OMIT,
+ issue_date_gte: typing.Optional[dt.datetime] = OMIT,
+ issue_date_lt: typing.Optional[dt.datetime] = OMIT,
+ issue_date_lte: typing.Optional[dt.datetime] = OMIT,
+ limit: typing.Optional[int] = OMIT,
+ order: typing.Optional[OrderEnum] = OMIT,
+ pagination_token: typing.Optional[str] = OMIT,
+ product_ids: typing.Optional[typing.Sequence[str]] = OMIT,
+ product_ids_in: typing.Optional[typing.Sequence[str]] = OMIT,
+ project_id: typing.Optional[str] = OMIT,
+ project_id_in: typing.Optional[typing.Sequence[str]] = OMIT,
+ sort: typing.Optional[ReceivableCursorFields2] = OMIT,
+ status: typing.Optional[ReceivablesSearchRequestStatus] = OMIT,
+ status_in: typing.Optional[typing.Sequence[str]] = OMIT,
+ tag_ids: typing.Optional[typing.Sequence[str]] = OMIT,
+ tag_ids_in: typing.Optional[typing.Sequence[str]] = OMIT,
+ total_amount: typing.Optional[int] = OMIT,
+ total_amount_gt: typing.Optional[int] = OMIT,
+ total_amount_gte: typing.Optional[int] = OMIT,
+ total_amount_lt: typing.Optional[int] = OMIT,
+ total_amount_lte: typing.Optional[int] = OMIT,
+ type: typing.Optional[ReceivableType] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> ReceivablePaginationResponse:
+ """
+ This is a POST version of the `GET /receivables` endpoint. Use it to send search and filter parameters in the request body instead of the URL query string in case the query is too long and exceeds the URL length limit of your HTTP client.
+
+ Parameters
+ ----------
+ discounted_subtotal : typing.Optional[int]
+ Return only receivables with the exact specified discounted subtotal. The amount must be specified in the [minor units](https://docs.monite.com/references/currencies#minor-units) of currency. For example, $12.5 is represented as 1250.
+
+ discounted_subtotal_gt : typing.Optional[int]
+ Return only receivables whose discounted subtotal (in minor units) is greater than the specified value.
+
+ discounted_subtotal_gte : typing.Optional[int]
+ Return only receivables whose discounted subtotal (in minor units) is greater than or equal to the specified value.
+
+ discounted_subtotal_lt : typing.Optional[int]
+ Return only receivables whose discounted subtotal (in minor units) is less than the specified value.
+
+ discounted_subtotal_lte : typing.Optional[int]
+ Return only receivables whose discounted subtotal (in minor units) is less than or equal to the specified value.
+
+ based_on : typing.Optional[str]
+ This parameter accepts a quote ID or an invoice ID.
+
+ * Specify a quote ID to find invoices created from this quote.
+ * Specify an invoice ID to find credit notes created for this invoice.
+
+ Valid but nonexistent IDs do not raise errors but produce no results.
+
+ counterpart_id : typing.Optional[str]
+ Return only receivables created for the counterpart with the specified ID.
+
+ Counterparts that have been deleted but have associated receivables will still return results here because the receivables contain a frozen copy of the counterpart data.
+
+ If the specified counterpart ID does not exist and never existed, no results are returned.
+
+ counterpart_name : typing.Optional[str]
+ Return only receivables created for counterparts with the specified name (exact match, case-sensitive). For counterparts of `type` = `individual`, the full name is formatted as `first_name last_name`.
+
+ counterpart_name_contains : typing.Optional[str]
+ Return only receivables created for counterparts whose name contains the specified string (case-sensitive).
+
+ counterpart_name_icontains : typing.Optional[str]
+ Return only receivables created for counterparts whose name contains the specified string (case-insensitive).
+
+ created_at_gt : typing.Optional[dt.datetime]
+ Return only receivables created after the specified date and time. The value must be in the ISO 8601 format `YYYY-MM-DDThh:mm[:ss[.ffffff]][Z|±hh:mm]`.
+
+ created_at_gte : typing.Optional[dt.datetime]
+ Return only receivables created on or after the specified date and time.
+
+ created_at_lt : typing.Optional[dt.datetime]
+ Return only receivables created before the specified date and time.
+
+ created_at_lte : typing.Optional[dt.datetime]
+ Return only receivables created before or on the specified date and time.
+
+ document_id : typing.Optional[str]
+ Return a receivable with the exact specified document number (case-sensitive). The `document_id` is the user-facing document number such as INV-00042, not to be confused with Monite resource IDs (`id`).
+
+ document_id_contains : typing.Optional[str]
+ Return only receivables whose document number (`document_id`) contains the specified string (case-sensitive).
+
+ document_id_icontains : typing.Optional[str]
+ Return only receivables whose document number (`document_id`) contains the specified string (case-insensitive).
+
+ due_date_gt : typing.Optional[str]
+ Return invoices that are due after the specified date (exclusive, `YYYY-MM-DD`).
+
+ This filter excludes quotes, credit notes, and draft invoices.
+
+ due_date_gte : typing.Optional[str]
+ Return invoices that are due on or after the specified date (`YYYY-MM-DD`).
+
+ This filter excludes quotes, credit notes, and draft invoices.
+
+ due_date_lt : typing.Optional[str]
+ Return invoices that are due before the specified date (exclusive, `YYYY-MM-DD`).
+
+ This filter excludes quotes, credit notes, and draft invoices.
+
+ due_date_lte : typing.Optional[str]
+ Return invoices that are due before or on the specified date (`YYYY-MM-DD`).
+
+ This filter excludes quotes, credit notes, and draft invoices.
+
+ entity_user_id : typing.Optional[str]
+ Return only receivables created by the entity user with the specified ID. To query receivables by multiple user IDs at once, use the `entity_user_id__in` parameter instead.
+
+ If the request is authenticated using an entity user token, this user must have the `receivable.read.allowed` (rather than `allowed_for_own`) permission to be able to query receivables created by other users.
+
+ IDs of deleted users will still produce results here if those users had associated receivables. Valid but nonexistent user IDs do not raise errors but produce no results.
+
+ entity_user_id_in : typing.Optional[typing.Sequence[str]]
+
+ id_in : typing.Optional[typing.Sequence[str]]
+
+ issue_date_gt : typing.Optional[dt.datetime]
+ Return only non-draft receivables that were issued after the specified date and time. The value must be in the ISO 8601 format `YYYY-MM-DDThh:mm[:ss[.ffffff]][Z|±hh:mm]`.
+
+ issue_date_gte : typing.Optional[dt.datetime]
+ Return only non-draft receivables that were issued on or after the specified date and time.
+
+ issue_date_lt : typing.Optional[dt.datetime]
+ Return only non-draft receivables that were issued before the specified date and time.
+
+ issue_date_lte : typing.Optional[dt.datetime]
+ Return only non-draft receivables that were issued before or on the specified date and time.
+
+ limit : typing.Optional[int]
+
+ order : typing.Optional[OrderEnum]
+
+ pagination_token : typing.Optional[str]
+
+ product_ids : typing.Optional[typing.Sequence[str]]
+
+ product_ids_in : typing.Optional[typing.Sequence[str]]
+
+ project_id : typing.Optional[str]
+ Return only receivables assigned to the project with the specified ID. Valid but nonexistent project IDs do not raise errors but return no results.
+
+ project_id_in : typing.Optional[typing.Sequence[str]]
+
+ sort : typing.Optional[ReceivableCursorFields2]
+
+ status : typing.Optional[ReceivablesSearchRequestStatus]
+ Return only receivables that have the specified status. See the applicable [invoice statuses](https://docs.monite.com/accounts-receivable/invoices/index), [quote statuses](https://docs.monite.com/accounts-receivable/quotes/index), and [credit note statuses](https://docs.monite.com/accounts-receivable/credit-notes#credit-note-lifecycle).
+
+ To query multiple statuses at once, use the `status__in` parameter instead.
+
+ status_in : typing.Optional[typing.Sequence[str]]
+
+ tag_ids : typing.Optional[typing.Sequence[str]]
+
+ tag_ids_in : typing.Optional[typing.Sequence[str]]
+
+ total_amount : typing.Optional[int]
+ Return only receivables with the exact specified total amount. The amount must be specified in the [minor units](https://docs.monite.com/references/currencies#minor-units) of currency. For example, $12.5 is represented as 1250.
+
+ total_amount_gt : typing.Optional[int]
+ Return only receivables whose total amount (in minor units) exceeds the specified value.
+
+ total_amount_gte : typing.Optional[int]
+ Return only receivables whose total amount (in minor units) is greater than or equal to the specified value.
+
+ total_amount_lt : typing.Optional[int]
+ Return only receivables whose total amount (in minor units) is less than the specified value.
+
+ total_amount_lte : typing.Optional[int]
+ Return only receivables whose total amount (in minor units) is less than or equal to the specified value.
+
+ type : typing.Optional[ReceivableType]
+ Return only receivables of the specified type. Use this parameter to get only invoices, or only quotes, or only credit notes.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ ReceivablePaginationResponse
+ Successful Response
+
+ Examples
+ --------
+ import asyncio
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
+ async def main() -> None:
+ await client.receivables.post_receivables_search()
+
+
+ asyncio.run(main())
+ """
+ _response = await self._raw_client.post_receivables_search(
+ discounted_subtotal=discounted_subtotal,
+ discounted_subtotal_gt=discounted_subtotal_gt,
+ discounted_subtotal_gte=discounted_subtotal_gte,
+ discounted_subtotal_lt=discounted_subtotal_lt,
+ discounted_subtotal_lte=discounted_subtotal_lte,
+ based_on=based_on,
+ counterpart_id=counterpart_id,
+ counterpart_name=counterpart_name,
+ counterpart_name_contains=counterpart_name_contains,
+ counterpart_name_icontains=counterpart_name_icontains,
+ created_at_gt=created_at_gt,
+ created_at_gte=created_at_gte,
+ created_at_lt=created_at_lt,
+ created_at_lte=created_at_lte,
+ document_id=document_id,
+ document_id_contains=document_id_contains,
+ document_id_icontains=document_id_icontains,
+ due_date_gt=due_date_gt,
+ due_date_gte=due_date_gte,
+ due_date_lt=due_date_lt,
+ due_date_lte=due_date_lte,
+ entity_user_id=entity_user_id,
+ entity_user_id_in=entity_user_id_in,
+ id_in=id_in,
+ issue_date_gt=issue_date_gt,
+ issue_date_gte=issue_date_gte,
+ issue_date_lt=issue_date_lt,
+ issue_date_lte=issue_date_lte,
+ limit=limit,
+ order=order,
+ pagination_token=pagination_token,
+ product_ids=product_ids,
+ product_ids_in=product_ids_in,
+ project_id=project_id,
+ project_id_in=project_id_in,
+ sort=sort,
+ status=status,
+ status_in=status_in,
+ tag_ids=tag_ids,
+ tag_ids_in=tag_ids_in,
+ total_amount=total_amount,
+ total_amount_gt=total_amount_gt,
+ total_amount_gte=total_amount_gte,
+ total_amount_lt=total_amount_lt,
+ total_amount_lte=total_amount_lte,
+ type=type,
+ request_options=request_options,
+ )
+ return _response.data
+
async def get_variables(
self, *, request_options: typing.Optional[RequestOptions] = None
) -> ReceivableTemplatesVariablesObjectList:
@@ -1734,11 +2562,21 @@ async def get_variables(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.receivables.get_variables()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_variables(request_options=request_options)
@@ -1762,11 +2600,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.receivables.get_by_id(receivable_id='receivable_id', )
+ await client.receivables.get_by_id(
+ receivable_id="receivable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(receivable_id, request_options=request_options)
@@ -1789,11 +2639,23 @@ async def delete_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.receivables.delete_by_id(receivable_id='receivable_id', )
+ await client.receivables.delete_by_id(
+ receivable_id="receivable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(receivable_id, request_options=request_options)
@@ -1823,13 +2685,26 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
- from monite import UpdateQuotePayload
- from monite import UpdateQuote
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite, UpdateQuote, UpdateQuotePayload
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.receivables.update_by_id(receivable_id='receivable_id', request=UpdateQuotePayload(quote=UpdateQuote(), ), )
+ await client.receivables.update_by_id(
+ receivable_id="receivable_id",
+ request=UpdateQuotePayload(
+ quote=UpdateQuote(),
+ ),
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(receivable_id, request=request, request_options=request_options)
@@ -1860,11 +2735,23 @@ async def accept_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.receivables.accept_by_id(receivable_id='receivable_id', )
+ await client.receivables.accept_by_id(
+ receivable_id="receivable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.accept_by_id(
@@ -1889,11 +2776,23 @@ async def cancel_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.receivables.cancel_by_id(receivable_id='receivable_id', )
+ await client.receivables.cancel_by_id(
+ receivable_id="receivable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.cancel_by_id(receivable_id, request_options=request_options)
@@ -1917,11 +2816,23 @@ async def clone_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.receivables.clone_by_id(receivable_id='receivable_id', )
+ await client.receivables.clone_by_id(
+ receivable_id="receivable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.clone_by_id(receivable_id, request_options=request_options)
@@ -1952,11 +2863,23 @@ async def decline_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.receivables.decline_by_id(receivable_id='receivable_id', )
+ await client.receivables.decline_by_id(
+ receivable_id="receivable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.decline_by_id(
@@ -2036,11 +2959,23 @@ async def get_history(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.receivables.get_history(receivable_id='receivable_id', )
+ await client.receivables.get_history(
+ receivable_id="receivable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_history(
@@ -2083,11 +3018,24 @@ async def get_history_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.receivables.get_history_by_id(receivable_history_id='receivable_history_id', receivable_id='receivable_id', )
+ await client.receivables.get_history_by_id(
+ receivable_history_id="receivable_history_id",
+ receivable_id="receivable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_history_by_id(
@@ -2113,11 +3061,23 @@ async def issue_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.receivables.issue_by_id(receivable_id='receivable_id', )
+ await client.receivables.issue_by_id(
+ receivable_id="receivable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.issue_by_id(receivable_id, request_options=request_options)
@@ -2149,12 +3109,28 @@ async def update_line_items_by_id(
Examples
--------
- from monite import AsyncMonite
- from monite import LineItem
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite, LineItem
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.receivables.update_line_items_by_id(receivable_id='receivable_id', data=[LineItem(quantity=1.1, )], )
+ await client.receivables.update_line_items_by_id(
+ receivable_id="receivable_id",
+ data=[
+ LineItem(
+ quantity=1.1,
+ )
+ ],
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_line_items_by_id(
@@ -2221,11 +3197,23 @@ async def get_mails(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.receivables.get_mails(receivable_id='receivable_id', )
+ await client.receivables.get_mails(
+ receivable_id="receivable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_mails(
@@ -2264,11 +3252,24 @@ async def get_mail_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.receivables.get_mail_by_id(receivable_id='receivable_id', mail_id='mail_id', )
+ await client.receivables.get_mail_by_id(
+ receivable_id="receivable_id",
+ mail_id="mail_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_mail_by_id(receivable_id, mail_id, request_options=request_options)
@@ -2303,11 +3304,23 @@ async def mark_as_paid_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.receivables.mark_as_paid_by_id(receivable_id='receivable_id', )
+ await client.receivables.mark_as_paid_by_id(
+ receivable_id="receivable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.mark_as_paid_by_id(
@@ -2346,11 +3359,24 @@ async def mark_as_partially_paid_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.receivables.mark_as_partially_paid_by_id(receivable_id='receivable_id', amount_paid=1, )
+ await client.receivables.mark_as_partially_paid_by_id(
+ receivable_id="receivable_id",
+ amount_paid=1,
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.mark_as_partially_paid_by_id(
@@ -2383,11 +3409,23 @@ async def mark_as_uncollectible_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.receivables.mark_as_uncollectible_by_id(receivable_id='receivable_id', )
+ await client.receivables.mark_as_uncollectible_by_id(
+ receivable_id="receivable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.mark_as_uncollectible_by_id(
@@ -2413,11 +3451,23 @@ async def get_pdf_link_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.receivables.get_pdf_link_by_id(receivable_id='receivable_id', )
+ await client.receivables.get_pdf_link_by_id(
+ receivable_id="receivable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_pdf_link_by_id(receivable_id, request_options=request_options)
@@ -2460,11 +3510,25 @@ async def preview_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.receivables.preview_by_id(receivable_id='receivable_id', body_text='body_text', subject_text='subject_text', )
+ await client.receivables.preview_by_id(
+ receivable_id="receivable_id",
+ body_text="body_text",
+ subject_text="subject_text",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.preview_by_id(
@@ -2509,11 +3573,25 @@ async def send_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.receivables.send_by_id(receivable_id='receivable_id', body_text='body_text', subject_text='subject_text', )
+ await client.receivables.send_by_id(
+ receivable_id="receivable_id",
+ body_text="body_text",
+ subject_text="subject_text",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.send_by_id(
@@ -2553,11 +3631,24 @@ async def send_test_reminder_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.receivables.send_test_reminder_by_id(receivable_id='receivable_id', reminder_type="term_1", )
+ await client.receivables.send_test_reminder_by_id(
+ receivable_id="receivable_id",
+ reminder_type="term_1",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.send_test_reminder_by_id(
@@ -2583,11 +3674,23 @@ async def verify_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.receivables.verify_by_id(receivable_id='receivable_id', )
+ await client.receivables.verify_by_id(
+ receivable_id="receivable_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.verify_by_id(receivable_id, request_options=request_options)
diff --git a/src/monite/receivables/raw_client.py b/src/monite/receivables/raw_client.py
index 02b1c74..add192a 100644
--- a/src/monite/receivables/raw_client.py
+++ b/src/monite/receivables/raw_client.py
@@ -27,6 +27,7 @@
from ..types.line_items_response import LineItemsResponse
from ..types.order_enum import OrderEnum
from ..types.receivable_cursor_fields import ReceivableCursorFields
+from ..types.receivable_cursor_fields2 import ReceivableCursorFields2
from ..types.receivable_facade_create_payload import ReceivableFacadeCreatePayload
from ..types.receivable_file_url import ReceivableFileUrl
from ..types.receivable_history_cursor_fields import ReceivableHistoryCursorFields
@@ -54,6 +55,7 @@
from ..types.success_result import SuccessResult
from .types.receivables_get_request_status import ReceivablesGetRequestStatus
from .types.receivables_get_request_status_in_item import ReceivablesGetRequestStatusInItem
+from .types.receivables_search_request_status import ReceivablesSearchRequestStatus
# this is used as the default value for optional parameters
OMIT = typing.cast(typing.Any, ...)
@@ -101,6 +103,11 @@ def get(
total_amount_lt: typing.Optional[int] = None,
total_amount_gte: typing.Optional[int] = None,
total_amount_lte: typing.Optional[int] = None,
+ discounted_subtotal: typing.Optional[int] = None,
+ discounted_subtotal_gt: typing.Optional[int] = None,
+ discounted_subtotal_lt: typing.Optional[int] = None,
+ discounted_subtotal_gte: typing.Optional[int] = None,
+ discounted_subtotal_lte: typing.Optional[int] = None,
status: typing.Optional[ReceivablesGetRequestStatus] = None,
entity_user_id: typing.Optional[str] = None,
based_on: typing.Optional[str] = None,
@@ -322,6 +329,16 @@ def get(
total_amount_lte : typing.Optional[int]
+ discounted_subtotal : typing.Optional[int]
+
+ discounted_subtotal_gt : typing.Optional[int]
+
+ discounted_subtotal_lt : typing.Optional[int]
+
+ discounted_subtotal_gte : typing.Optional[int]
+
+ discounted_subtotal_lte : typing.Optional[int]
+
status : typing.Optional[ReceivablesGetRequestStatus]
entity_user_id : typing.Optional[str]
@@ -383,6 +400,11 @@ def get(
"total_amount__lt": total_amount_lt,
"total_amount__gte": total_amount_gte,
"total_amount__lte": total_amount_lte,
+ "discounted_subtotal": discounted_subtotal,
+ "discounted_subtotal__gt": discounted_subtotal_gt,
+ "discounted_subtotal__lt": discounted_subtotal_lt,
+ "discounted_subtotal__gte": discounted_subtotal_gte,
+ "discounted_subtotal__lte": discounted_subtotal_lte,
"status": status,
"entity_user_id": entity_user_id,
"based_on": based_on,
@@ -681,6 +703,357 @@ def get_receivables_required_fields(
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+ def post_receivables_search(
+ self,
+ *,
+ discounted_subtotal: typing.Optional[int] = OMIT,
+ discounted_subtotal_gt: typing.Optional[int] = OMIT,
+ discounted_subtotal_gte: typing.Optional[int] = OMIT,
+ discounted_subtotal_lt: typing.Optional[int] = OMIT,
+ discounted_subtotal_lte: typing.Optional[int] = OMIT,
+ based_on: typing.Optional[str] = OMIT,
+ counterpart_id: typing.Optional[str] = OMIT,
+ counterpart_name: typing.Optional[str] = OMIT,
+ counterpart_name_contains: typing.Optional[str] = OMIT,
+ counterpart_name_icontains: typing.Optional[str] = OMIT,
+ created_at_gt: typing.Optional[dt.datetime] = OMIT,
+ created_at_gte: typing.Optional[dt.datetime] = OMIT,
+ created_at_lt: typing.Optional[dt.datetime] = OMIT,
+ created_at_lte: typing.Optional[dt.datetime] = OMIT,
+ document_id: typing.Optional[str] = OMIT,
+ document_id_contains: typing.Optional[str] = OMIT,
+ document_id_icontains: typing.Optional[str] = OMIT,
+ due_date_gt: typing.Optional[str] = OMIT,
+ due_date_gte: typing.Optional[str] = OMIT,
+ due_date_lt: typing.Optional[str] = OMIT,
+ due_date_lte: typing.Optional[str] = OMIT,
+ entity_user_id: typing.Optional[str] = OMIT,
+ entity_user_id_in: typing.Optional[typing.Sequence[str]] = OMIT,
+ id_in: typing.Optional[typing.Sequence[str]] = OMIT,
+ issue_date_gt: typing.Optional[dt.datetime] = OMIT,
+ issue_date_gte: typing.Optional[dt.datetime] = OMIT,
+ issue_date_lt: typing.Optional[dt.datetime] = OMIT,
+ issue_date_lte: typing.Optional[dt.datetime] = OMIT,
+ limit: typing.Optional[int] = OMIT,
+ order: typing.Optional[OrderEnum] = OMIT,
+ pagination_token: typing.Optional[str] = OMIT,
+ product_ids: typing.Optional[typing.Sequence[str]] = OMIT,
+ product_ids_in: typing.Optional[typing.Sequence[str]] = OMIT,
+ project_id: typing.Optional[str] = OMIT,
+ project_id_in: typing.Optional[typing.Sequence[str]] = OMIT,
+ sort: typing.Optional[ReceivableCursorFields2] = OMIT,
+ status: typing.Optional[ReceivablesSearchRequestStatus] = OMIT,
+ status_in: typing.Optional[typing.Sequence[str]] = OMIT,
+ tag_ids: typing.Optional[typing.Sequence[str]] = OMIT,
+ tag_ids_in: typing.Optional[typing.Sequence[str]] = OMIT,
+ total_amount: typing.Optional[int] = OMIT,
+ total_amount_gt: typing.Optional[int] = OMIT,
+ total_amount_gte: typing.Optional[int] = OMIT,
+ total_amount_lt: typing.Optional[int] = OMIT,
+ total_amount_lte: typing.Optional[int] = OMIT,
+ type: typing.Optional[ReceivableType] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[ReceivablePaginationResponse]:
+ """
+ This is a POST version of the `GET /receivables` endpoint. Use it to send search and filter parameters in the request body instead of the URL query string in case the query is too long and exceeds the URL length limit of your HTTP client.
+
+ Parameters
+ ----------
+ discounted_subtotal : typing.Optional[int]
+ Return only receivables with the exact specified discounted subtotal. The amount must be specified in the [minor units](https://docs.monite.com/references/currencies#minor-units) of currency. For example, $12.5 is represented as 1250.
+
+ discounted_subtotal_gt : typing.Optional[int]
+ Return only receivables whose discounted subtotal (in minor units) is greater than the specified value.
+
+ discounted_subtotal_gte : typing.Optional[int]
+ Return only receivables whose discounted subtotal (in minor units) is greater than or equal to the specified value.
+
+ discounted_subtotal_lt : typing.Optional[int]
+ Return only receivables whose discounted subtotal (in minor units) is less than the specified value.
+
+ discounted_subtotal_lte : typing.Optional[int]
+ Return only receivables whose discounted subtotal (in minor units) is less than or equal to the specified value.
+
+ based_on : typing.Optional[str]
+ This parameter accepts a quote ID or an invoice ID.
+
+ * Specify a quote ID to find invoices created from this quote.
+ * Specify an invoice ID to find credit notes created for this invoice.
+
+ Valid but nonexistent IDs do not raise errors but produce no results.
+
+ counterpart_id : typing.Optional[str]
+ Return only receivables created for the counterpart with the specified ID.
+
+ Counterparts that have been deleted but have associated receivables will still return results here because the receivables contain a frozen copy of the counterpart data.
+
+ If the specified counterpart ID does not exist and never existed, no results are returned.
+
+ counterpart_name : typing.Optional[str]
+ Return only receivables created for counterparts with the specified name (exact match, case-sensitive). For counterparts of `type` = `individual`, the full name is formatted as `first_name last_name`.
+
+ counterpart_name_contains : typing.Optional[str]
+ Return only receivables created for counterparts whose name contains the specified string (case-sensitive).
+
+ counterpart_name_icontains : typing.Optional[str]
+ Return only receivables created for counterparts whose name contains the specified string (case-insensitive).
+
+ created_at_gt : typing.Optional[dt.datetime]
+ Return only receivables created after the specified date and time. The value must be in the ISO 8601 format `YYYY-MM-DDThh:mm[:ss[.ffffff]][Z|±hh:mm]`.
+
+ created_at_gte : typing.Optional[dt.datetime]
+ Return only receivables created on or after the specified date and time.
+
+ created_at_lt : typing.Optional[dt.datetime]
+ Return only receivables created before the specified date and time.
+
+ created_at_lte : typing.Optional[dt.datetime]
+ Return only receivables created before or on the specified date and time.
+
+ document_id : typing.Optional[str]
+ Return a receivable with the exact specified document number (case-sensitive). The `document_id` is the user-facing document number such as INV-00042, not to be confused with Monite resource IDs (`id`).
+
+ document_id_contains : typing.Optional[str]
+ Return only receivables whose document number (`document_id`) contains the specified string (case-sensitive).
+
+ document_id_icontains : typing.Optional[str]
+ Return only receivables whose document number (`document_id`) contains the specified string (case-insensitive).
+
+ due_date_gt : typing.Optional[str]
+ Return invoices that are due after the specified date (exclusive, `YYYY-MM-DD`).
+
+ This filter excludes quotes, credit notes, and draft invoices.
+
+ due_date_gte : typing.Optional[str]
+ Return invoices that are due on or after the specified date (`YYYY-MM-DD`).
+
+ This filter excludes quotes, credit notes, and draft invoices.
+
+ due_date_lt : typing.Optional[str]
+ Return invoices that are due before the specified date (exclusive, `YYYY-MM-DD`).
+
+ This filter excludes quotes, credit notes, and draft invoices.
+
+ due_date_lte : typing.Optional[str]
+ Return invoices that are due before or on the specified date (`YYYY-MM-DD`).
+
+ This filter excludes quotes, credit notes, and draft invoices.
+
+ entity_user_id : typing.Optional[str]
+ Return only receivables created by the entity user with the specified ID. To query receivables by multiple user IDs at once, use the `entity_user_id__in` parameter instead.
+
+ If the request is authenticated using an entity user token, this user must have the `receivable.read.allowed` (rather than `allowed_for_own`) permission to be able to query receivables created by other users.
+
+ IDs of deleted users will still produce results here if those users had associated receivables. Valid but nonexistent user IDs do not raise errors but produce no results.
+
+ entity_user_id_in : typing.Optional[typing.Sequence[str]]
+
+ id_in : typing.Optional[typing.Sequence[str]]
+
+ issue_date_gt : typing.Optional[dt.datetime]
+ Return only non-draft receivables that were issued after the specified date and time. The value must be in the ISO 8601 format `YYYY-MM-DDThh:mm[:ss[.ffffff]][Z|±hh:mm]`.
+
+ issue_date_gte : typing.Optional[dt.datetime]
+ Return only non-draft receivables that were issued on or after the specified date and time.
+
+ issue_date_lt : typing.Optional[dt.datetime]
+ Return only non-draft receivables that were issued before the specified date and time.
+
+ issue_date_lte : typing.Optional[dt.datetime]
+ Return only non-draft receivables that were issued before or on the specified date and time.
+
+ limit : typing.Optional[int]
+
+ order : typing.Optional[OrderEnum]
+
+ pagination_token : typing.Optional[str]
+
+ product_ids : typing.Optional[typing.Sequence[str]]
+
+ product_ids_in : typing.Optional[typing.Sequence[str]]
+
+ project_id : typing.Optional[str]
+ Return only receivables assigned to the project with the specified ID. Valid but nonexistent project IDs do not raise errors but return no results.
+
+ project_id_in : typing.Optional[typing.Sequence[str]]
+
+ sort : typing.Optional[ReceivableCursorFields2]
+
+ status : typing.Optional[ReceivablesSearchRequestStatus]
+ Return only receivables that have the specified status. See the applicable [invoice statuses](https://docs.monite.com/accounts-receivable/invoices/index), [quote statuses](https://docs.monite.com/accounts-receivable/quotes/index), and [credit note statuses](https://docs.monite.com/accounts-receivable/credit-notes#credit-note-lifecycle).
+
+ To query multiple statuses at once, use the `status__in` parameter instead.
+
+ status_in : typing.Optional[typing.Sequence[str]]
+
+ tag_ids : typing.Optional[typing.Sequence[str]]
+
+ tag_ids_in : typing.Optional[typing.Sequence[str]]
+
+ total_amount : typing.Optional[int]
+ Return only receivables with the exact specified total amount. The amount must be specified in the [minor units](https://docs.monite.com/references/currencies#minor-units) of currency. For example, $12.5 is represented as 1250.
+
+ total_amount_gt : typing.Optional[int]
+ Return only receivables whose total amount (in minor units) exceeds the specified value.
+
+ total_amount_gte : typing.Optional[int]
+ Return only receivables whose total amount (in minor units) is greater than or equal to the specified value.
+
+ total_amount_lt : typing.Optional[int]
+ Return only receivables whose total amount (in minor units) is less than the specified value.
+
+ total_amount_lte : typing.Optional[int]
+ Return only receivables whose total amount (in minor units) is less than or equal to the specified value.
+
+ type : typing.Optional[ReceivableType]
+ Return only receivables of the specified type. Use this parameter to get only invoices, or only quotes, or only credit notes.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[ReceivablePaginationResponse]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ "receivables/search",
+ method="POST",
+ json={
+ "discounted_subtotal": discounted_subtotal,
+ "discounted_subtotal__gt": discounted_subtotal_gt,
+ "discounted_subtotal__gte": discounted_subtotal_gte,
+ "discounted_subtotal__lt": discounted_subtotal_lt,
+ "discounted_subtotal__lte": discounted_subtotal_lte,
+ "based_on": based_on,
+ "counterpart_id": counterpart_id,
+ "counterpart_name": counterpart_name,
+ "counterpart_name__contains": counterpart_name_contains,
+ "counterpart_name__icontains": counterpart_name_icontains,
+ "created_at__gt": created_at_gt,
+ "created_at__gte": created_at_gte,
+ "created_at__lt": created_at_lt,
+ "created_at__lte": created_at_lte,
+ "document_id": document_id,
+ "document_id__contains": document_id_contains,
+ "document_id__icontains": document_id_icontains,
+ "due_date__gt": due_date_gt,
+ "due_date__gte": due_date_gte,
+ "due_date__lt": due_date_lt,
+ "due_date__lte": due_date_lte,
+ "entity_user_id": entity_user_id,
+ "entity_user_id__in": entity_user_id_in,
+ "id__in": id_in,
+ "issue_date__gt": issue_date_gt,
+ "issue_date__gte": issue_date_gte,
+ "issue_date__lt": issue_date_lt,
+ "issue_date__lte": issue_date_lte,
+ "limit": limit,
+ "order": order,
+ "pagination_token": pagination_token,
+ "product_ids": product_ids,
+ "product_ids__in": product_ids_in,
+ "project_id": project_id,
+ "project_id__in": project_id_in,
+ "sort": sort,
+ "status": status,
+ "status__in": status_in,
+ "tag_ids": tag_ids,
+ "tag_ids__in": tag_ids_in,
+ "total_amount": total_amount,
+ "total_amount__gt": total_amount_gt,
+ "total_amount__gte": total_amount_gte,
+ "total_amount__lt": total_amount_lt,
+ "total_amount__lte": total_amount_lte,
+ "type": type,
+ },
+ headers={
+ "content-type": "application/json",
+ },
+ request_options=request_options,
+ omit=OMIT,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ ReceivablePaginationResponse,
+ parse_obj_as(
+ type_=ReceivablePaginationResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 400:
+ raise BadRequestError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 406:
+ raise NotAcceptableError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 409:
+ raise ConflictError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 500:
+ raise InternalServerError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ _response_json = _response.json()
+ except JSONDecodeError:
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
def get_variables(
self, *, request_options: typing.Optional[RequestOptions] = None
) -> HttpResponse[ReceivableTemplatesVariablesObjectList]:
@@ -3388,6 +3761,11 @@ async def get(
total_amount_lt: typing.Optional[int] = None,
total_amount_gte: typing.Optional[int] = None,
total_amount_lte: typing.Optional[int] = None,
+ discounted_subtotal: typing.Optional[int] = None,
+ discounted_subtotal_gt: typing.Optional[int] = None,
+ discounted_subtotal_lt: typing.Optional[int] = None,
+ discounted_subtotal_gte: typing.Optional[int] = None,
+ discounted_subtotal_lte: typing.Optional[int] = None,
status: typing.Optional[ReceivablesGetRequestStatus] = None,
entity_user_id: typing.Optional[str] = None,
based_on: typing.Optional[str] = None,
@@ -3609,6 +3987,16 @@ async def get(
total_amount_lte : typing.Optional[int]
+ discounted_subtotal : typing.Optional[int]
+
+ discounted_subtotal_gt : typing.Optional[int]
+
+ discounted_subtotal_lt : typing.Optional[int]
+
+ discounted_subtotal_gte : typing.Optional[int]
+
+ discounted_subtotal_lte : typing.Optional[int]
+
status : typing.Optional[ReceivablesGetRequestStatus]
entity_user_id : typing.Optional[str]
@@ -3670,6 +4058,11 @@ async def get(
"total_amount__lt": total_amount_lt,
"total_amount__gte": total_amount_gte,
"total_amount__lte": total_amount_lte,
+ "discounted_subtotal": discounted_subtotal,
+ "discounted_subtotal__gt": discounted_subtotal_gt,
+ "discounted_subtotal__lt": discounted_subtotal_lt,
+ "discounted_subtotal__gte": discounted_subtotal_gte,
+ "discounted_subtotal__lte": discounted_subtotal_lte,
"status": status,
"entity_user_id": entity_user_id,
"based_on": based_on,
@@ -3968,6 +4361,357 @@ async def get_receivables_required_fields(
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+ async def post_receivables_search(
+ self,
+ *,
+ discounted_subtotal: typing.Optional[int] = OMIT,
+ discounted_subtotal_gt: typing.Optional[int] = OMIT,
+ discounted_subtotal_gte: typing.Optional[int] = OMIT,
+ discounted_subtotal_lt: typing.Optional[int] = OMIT,
+ discounted_subtotal_lte: typing.Optional[int] = OMIT,
+ based_on: typing.Optional[str] = OMIT,
+ counterpart_id: typing.Optional[str] = OMIT,
+ counterpart_name: typing.Optional[str] = OMIT,
+ counterpart_name_contains: typing.Optional[str] = OMIT,
+ counterpart_name_icontains: typing.Optional[str] = OMIT,
+ created_at_gt: typing.Optional[dt.datetime] = OMIT,
+ created_at_gte: typing.Optional[dt.datetime] = OMIT,
+ created_at_lt: typing.Optional[dt.datetime] = OMIT,
+ created_at_lte: typing.Optional[dt.datetime] = OMIT,
+ document_id: typing.Optional[str] = OMIT,
+ document_id_contains: typing.Optional[str] = OMIT,
+ document_id_icontains: typing.Optional[str] = OMIT,
+ due_date_gt: typing.Optional[str] = OMIT,
+ due_date_gte: typing.Optional[str] = OMIT,
+ due_date_lt: typing.Optional[str] = OMIT,
+ due_date_lte: typing.Optional[str] = OMIT,
+ entity_user_id: typing.Optional[str] = OMIT,
+ entity_user_id_in: typing.Optional[typing.Sequence[str]] = OMIT,
+ id_in: typing.Optional[typing.Sequence[str]] = OMIT,
+ issue_date_gt: typing.Optional[dt.datetime] = OMIT,
+ issue_date_gte: typing.Optional[dt.datetime] = OMIT,
+ issue_date_lt: typing.Optional[dt.datetime] = OMIT,
+ issue_date_lte: typing.Optional[dt.datetime] = OMIT,
+ limit: typing.Optional[int] = OMIT,
+ order: typing.Optional[OrderEnum] = OMIT,
+ pagination_token: typing.Optional[str] = OMIT,
+ product_ids: typing.Optional[typing.Sequence[str]] = OMIT,
+ product_ids_in: typing.Optional[typing.Sequence[str]] = OMIT,
+ project_id: typing.Optional[str] = OMIT,
+ project_id_in: typing.Optional[typing.Sequence[str]] = OMIT,
+ sort: typing.Optional[ReceivableCursorFields2] = OMIT,
+ status: typing.Optional[ReceivablesSearchRequestStatus] = OMIT,
+ status_in: typing.Optional[typing.Sequence[str]] = OMIT,
+ tag_ids: typing.Optional[typing.Sequence[str]] = OMIT,
+ tag_ids_in: typing.Optional[typing.Sequence[str]] = OMIT,
+ total_amount: typing.Optional[int] = OMIT,
+ total_amount_gt: typing.Optional[int] = OMIT,
+ total_amount_gte: typing.Optional[int] = OMIT,
+ total_amount_lt: typing.Optional[int] = OMIT,
+ total_amount_lte: typing.Optional[int] = OMIT,
+ type: typing.Optional[ReceivableType] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> AsyncHttpResponse[ReceivablePaginationResponse]:
+ """
+ This is a POST version of the `GET /receivables` endpoint. Use it to send search and filter parameters in the request body instead of the URL query string in case the query is too long and exceeds the URL length limit of your HTTP client.
+
+ Parameters
+ ----------
+ discounted_subtotal : typing.Optional[int]
+ Return only receivables with the exact specified discounted subtotal. The amount must be specified in the [minor units](https://docs.monite.com/references/currencies#minor-units) of currency. For example, $12.5 is represented as 1250.
+
+ discounted_subtotal_gt : typing.Optional[int]
+ Return only receivables whose discounted subtotal (in minor units) is greater than the specified value.
+
+ discounted_subtotal_gte : typing.Optional[int]
+ Return only receivables whose discounted subtotal (in minor units) is greater than or equal to the specified value.
+
+ discounted_subtotal_lt : typing.Optional[int]
+ Return only receivables whose discounted subtotal (in minor units) is less than the specified value.
+
+ discounted_subtotal_lte : typing.Optional[int]
+ Return only receivables whose discounted subtotal (in minor units) is less than or equal to the specified value.
+
+ based_on : typing.Optional[str]
+ This parameter accepts a quote ID or an invoice ID.
+
+ * Specify a quote ID to find invoices created from this quote.
+ * Specify an invoice ID to find credit notes created for this invoice.
+
+ Valid but nonexistent IDs do not raise errors but produce no results.
+
+ counterpart_id : typing.Optional[str]
+ Return only receivables created for the counterpart with the specified ID.
+
+ Counterparts that have been deleted but have associated receivables will still return results here because the receivables contain a frozen copy of the counterpart data.
+
+ If the specified counterpart ID does not exist and never existed, no results are returned.
+
+ counterpart_name : typing.Optional[str]
+ Return only receivables created for counterparts with the specified name (exact match, case-sensitive). For counterparts of `type` = `individual`, the full name is formatted as `first_name last_name`.
+
+ counterpart_name_contains : typing.Optional[str]
+ Return only receivables created for counterparts whose name contains the specified string (case-sensitive).
+
+ counterpart_name_icontains : typing.Optional[str]
+ Return only receivables created for counterparts whose name contains the specified string (case-insensitive).
+
+ created_at_gt : typing.Optional[dt.datetime]
+ Return only receivables created after the specified date and time. The value must be in the ISO 8601 format `YYYY-MM-DDThh:mm[:ss[.ffffff]][Z|±hh:mm]`.
+
+ created_at_gte : typing.Optional[dt.datetime]
+ Return only receivables created on or after the specified date and time.
+
+ created_at_lt : typing.Optional[dt.datetime]
+ Return only receivables created before the specified date and time.
+
+ created_at_lte : typing.Optional[dt.datetime]
+ Return only receivables created before or on the specified date and time.
+
+ document_id : typing.Optional[str]
+ Return a receivable with the exact specified document number (case-sensitive). The `document_id` is the user-facing document number such as INV-00042, not to be confused with Monite resource IDs (`id`).
+
+ document_id_contains : typing.Optional[str]
+ Return only receivables whose document number (`document_id`) contains the specified string (case-sensitive).
+
+ document_id_icontains : typing.Optional[str]
+ Return only receivables whose document number (`document_id`) contains the specified string (case-insensitive).
+
+ due_date_gt : typing.Optional[str]
+ Return invoices that are due after the specified date (exclusive, `YYYY-MM-DD`).
+
+ This filter excludes quotes, credit notes, and draft invoices.
+
+ due_date_gte : typing.Optional[str]
+ Return invoices that are due on or after the specified date (`YYYY-MM-DD`).
+
+ This filter excludes quotes, credit notes, and draft invoices.
+
+ due_date_lt : typing.Optional[str]
+ Return invoices that are due before the specified date (exclusive, `YYYY-MM-DD`).
+
+ This filter excludes quotes, credit notes, and draft invoices.
+
+ due_date_lte : typing.Optional[str]
+ Return invoices that are due before or on the specified date (`YYYY-MM-DD`).
+
+ This filter excludes quotes, credit notes, and draft invoices.
+
+ entity_user_id : typing.Optional[str]
+ Return only receivables created by the entity user with the specified ID. To query receivables by multiple user IDs at once, use the `entity_user_id__in` parameter instead.
+
+ If the request is authenticated using an entity user token, this user must have the `receivable.read.allowed` (rather than `allowed_for_own`) permission to be able to query receivables created by other users.
+
+ IDs of deleted users will still produce results here if those users had associated receivables. Valid but nonexistent user IDs do not raise errors but produce no results.
+
+ entity_user_id_in : typing.Optional[typing.Sequence[str]]
+
+ id_in : typing.Optional[typing.Sequence[str]]
+
+ issue_date_gt : typing.Optional[dt.datetime]
+ Return only non-draft receivables that were issued after the specified date and time. The value must be in the ISO 8601 format `YYYY-MM-DDThh:mm[:ss[.ffffff]][Z|±hh:mm]`.
+
+ issue_date_gte : typing.Optional[dt.datetime]
+ Return only non-draft receivables that were issued on or after the specified date and time.
+
+ issue_date_lt : typing.Optional[dt.datetime]
+ Return only non-draft receivables that were issued before the specified date and time.
+
+ issue_date_lte : typing.Optional[dt.datetime]
+ Return only non-draft receivables that were issued before or on the specified date and time.
+
+ limit : typing.Optional[int]
+
+ order : typing.Optional[OrderEnum]
+
+ pagination_token : typing.Optional[str]
+
+ product_ids : typing.Optional[typing.Sequence[str]]
+
+ product_ids_in : typing.Optional[typing.Sequence[str]]
+
+ project_id : typing.Optional[str]
+ Return only receivables assigned to the project with the specified ID. Valid but nonexistent project IDs do not raise errors but return no results.
+
+ project_id_in : typing.Optional[typing.Sequence[str]]
+
+ sort : typing.Optional[ReceivableCursorFields2]
+
+ status : typing.Optional[ReceivablesSearchRequestStatus]
+ Return only receivables that have the specified status. See the applicable [invoice statuses](https://docs.monite.com/accounts-receivable/invoices/index), [quote statuses](https://docs.monite.com/accounts-receivable/quotes/index), and [credit note statuses](https://docs.monite.com/accounts-receivable/credit-notes#credit-note-lifecycle).
+
+ To query multiple statuses at once, use the `status__in` parameter instead.
+
+ status_in : typing.Optional[typing.Sequence[str]]
+
+ tag_ids : typing.Optional[typing.Sequence[str]]
+
+ tag_ids_in : typing.Optional[typing.Sequence[str]]
+
+ total_amount : typing.Optional[int]
+ Return only receivables with the exact specified total amount. The amount must be specified in the [minor units](https://docs.monite.com/references/currencies#minor-units) of currency. For example, $12.5 is represented as 1250.
+
+ total_amount_gt : typing.Optional[int]
+ Return only receivables whose total amount (in minor units) exceeds the specified value.
+
+ total_amount_gte : typing.Optional[int]
+ Return only receivables whose total amount (in minor units) is greater than or equal to the specified value.
+
+ total_amount_lt : typing.Optional[int]
+ Return only receivables whose total amount (in minor units) is less than the specified value.
+
+ total_amount_lte : typing.Optional[int]
+ Return only receivables whose total amount (in minor units) is less than or equal to the specified value.
+
+ type : typing.Optional[ReceivableType]
+ Return only receivables of the specified type. Use this parameter to get only invoices, or only quotes, or only credit notes.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ AsyncHttpResponse[ReceivablePaginationResponse]
+ Successful Response
+ """
+ _response = await self._client_wrapper.httpx_client.request(
+ "receivables/search",
+ method="POST",
+ json={
+ "discounted_subtotal": discounted_subtotal,
+ "discounted_subtotal__gt": discounted_subtotal_gt,
+ "discounted_subtotal__gte": discounted_subtotal_gte,
+ "discounted_subtotal__lt": discounted_subtotal_lt,
+ "discounted_subtotal__lte": discounted_subtotal_lte,
+ "based_on": based_on,
+ "counterpart_id": counterpart_id,
+ "counterpart_name": counterpart_name,
+ "counterpart_name__contains": counterpart_name_contains,
+ "counterpart_name__icontains": counterpart_name_icontains,
+ "created_at__gt": created_at_gt,
+ "created_at__gte": created_at_gte,
+ "created_at__lt": created_at_lt,
+ "created_at__lte": created_at_lte,
+ "document_id": document_id,
+ "document_id__contains": document_id_contains,
+ "document_id__icontains": document_id_icontains,
+ "due_date__gt": due_date_gt,
+ "due_date__gte": due_date_gte,
+ "due_date__lt": due_date_lt,
+ "due_date__lte": due_date_lte,
+ "entity_user_id": entity_user_id,
+ "entity_user_id__in": entity_user_id_in,
+ "id__in": id_in,
+ "issue_date__gt": issue_date_gt,
+ "issue_date__gte": issue_date_gte,
+ "issue_date__lt": issue_date_lt,
+ "issue_date__lte": issue_date_lte,
+ "limit": limit,
+ "order": order,
+ "pagination_token": pagination_token,
+ "product_ids": product_ids,
+ "product_ids__in": product_ids_in,
+ "project_id": project_id,
+ "project_id__in": project_id_in,
+ "sort": sort,
+ "status": status,
+ "status__in": status_in,
+ "tag_ids": tag_ids,
+ "tag_ids__in": tag_ids_in,
+ "total_amount": total_amount,
+ "total_amount__gt": total_amount_gt,
+ "total_amount__gte": total_amount_gte,
+ "total_amount__lt": total_amount_lt,
+ "total_amount__lte": total_amount_lte,
+ "type": type,
+ },
+ headers={
+ "content-type": "application/json",
+ },
+ request_options=request_options,
+ omit=OMIT,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ ReceivablePaginationResponse,
+ parse_obj_as(
+ type_=ReceivablePaginationResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return AsyncHttpResponse(response=_response, data=_data)
+ if _response.status_code == 400:
+ raise BadRequestError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 406:
+ raise NotAcceptableError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 409:
+ raise ConflictError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 500:
+ raise InternalServerError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ _response_json = _response.json()
+ except JSONDecodeError:
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
async def get_variables(
self, *, request_options: typing.Optional[RequestOptions] = None
) -> AsyncHttpResponse[ReceivableTemplatesVariablesObjectList]:
diff --git a/src/monite/receivables/types/__init__.py b/src/monite/receivables/types/__init__.py
index 366a805..ea27e89 100644
--- a/src/monite/receivables/types/__init__.py
+++ b/src/monite/receivables/types/__init__.py
@@ -4,5 +4,6 @@
from .receivables_get_request_status import ReceivablesGetRequestStatus
from .receivables_get_request_status_in_item import ReceivablesGetRequestStatusInItem
+from .receivables_search_request_status import ReceivablesSearchRequestStatus
-__all__ = ["ReceivablesGetRequestStatus", "ReceivablesGetRequestStatusInItem"]
+__all__ = ["ReceivablesGetRequestStatus", "ReceivablesGetRequestStatusInItem", "ReceivablesSearchRequestStatus"]
diff --git a/src/monite/receivables/types/receivables_search_request_status.py b/src/monite/receivables/types/receivables_search_request_status.py
new file mode 100644
index 0000000..cb9db86
--- /dev/null
+++ b/src/monite/receivables/types/receivables_search_request_status.py
@@ -0,0 +1,22 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+ReceivablesSearchRequestStatus = typing.Union[
+ typing.Literal[
+ "draft",
+ "issuing",
+ "issued",
+ "failed",
+ "accepted",
+ "expired",
+ "declined",
+ "recurring",
+ "partially_paid",
+ "paid",
+ "overdue",
+ "uncollectible",
+ "canceled",
+ ],
+ typing.Any,
+]
diff --git a/src/monite/recurrences/client.py b/src/monite/recurrences/client.py
index 9f888e2..62ee0b8 100644
--- a/src/monite/recurrences/client.py
+++ b/src/monite/recurrences/client.py
@@ -6,9 +6,10 @@
from ..core.request_options import RequestOptions
from ..types.automation_level import AutomationLevel
from ..types.day_of_month import DayOfMonth
-from ..types.get_all_recurrences import GetAllRecurrences
from ..types.recipients import Recipients
-from ..types.recurrence import Recurrence
+from ..types.recurrence_frequency import RecurrenceFrequency
+from ..types.recurrence_response import RecurrenceResponse
+from ..types.recurrence_response_list import RecurrenceResponseList
from .raw_client import AsyncRawRecurrencesClient, RawRecurrencesClient
# this is used as the default value for optional parameters
@@ -30,7 +31,7 @@ def with_raw_response(self) -> RawRecurrencesClient:
"""
return self._raw_client
- def get(self, *, request_options: typing.Optional[RequestOptions] = None) -> GetAllRecurrences:
+ def get(self, *, request_options: typing.Optional[RequestOptions] = None) -> RecurrenceResponseList:
"""
Parameters
----------
@@ -39,13 +40,18 @@ def get(self, *, request_options: typing.Optional[RequestOptions] = None) -> Get
Returns
-------
- GetAllRecurrences
+ RecurrenceResponseList
Successful Response
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.recurrences.get()
"""
_response = self._raw_client.get(request_options=request_options)
@@ -54,32 +60,28 @@ def get(self, *, request_options: typing.Optional[RequestOptions] = None) -> Get
def create(
self,
*,
- day_of_month: DayOfMonth,
- end_month: int,
- end_year: int,
invoice_id: str,
- start_month: int,
- start_year: int,
automation_level: typing.Optional[AutomationLevel] = OMIT,
body_text: typing.Optional[str] = OMIT,
+ day_of_month: typing.Optional[DayOfMonth] = OMIT,
+ end_date: typing.Optional[str] = OMIT,
+ end_month: typing.Optional[int] = OMIT,
+ end_year: typing.Optional[int] = OMIT,
+ frequency: typing.Optional[RecurrenceFrequency] = OMIT,
+ interval: typing.Optional[int] = OMIT,
+ max_occurrences: typing.Optional[int] = OMIT,
recipients: typing.Optional[Recipients] = OMIT,
+ start_date: typing.Optional[str] = OMIT,
+ start_month: typing.Optional[int] = OMIT,
+ start_year: typing.Optional[int] = OMIT,
subject_text: typing.Optional[str] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> Recurrence:
+ ) -> RecurrenceResponse:
"""
Parameters
----------
- day_of_month : DayOfMonth
-
- end_month : int
-
- end_year : int
-
invoice_id : str
-
- start_month : int
-
- start_year : int
+ ID of the base invoice that will be used as a template for creating recurring invoices.
automation_level : typing.Optional[AutomationLevel]
Controls how invoices are processed when generated:
@@ -92,41 +94,88 @@ def create(
Note: When using "issue_and_send", both subject_text and body_text must be provided.
body_text : typing.Optional[str]
+ The body text for the email that will be sent with the recurring invoice.
+
+ day_of_month : typing.Optional[DayOfMonth]
+ Deprecated, use `start_date` instead
+
+ end_date : typing.Optional[str]
+ The end date of the recurring invoice, in the `yyyy-mm-dd` format. The end date is inclusive, that is, the last invoice will be created on this date if the last occurrence falls on this date. `end_date` is mutually exclusive with `max_occurrences`. Either `end_date` or `max_occurrences` must be specified.
+
+ end_month : typing.Optional[int]
+ Deprecated, use `end_date` instead
+
+ end_year : typing.Optional[int]
+ Deprecated, use `end_date` instead
+
+ frequency : typing.Optional[RecurrenceFrequency]
+ How often the invoice will be created.
+
+ interval : typing.Optional[int]
+ The interval between each occurrence of the invoice. For example, when using monthly frequency, an interval of 1 means invoices will be created every month, an interval of 2 means invoices will be created every 2 months.
+
+ max_occurrences : typing.Optional[int]
+ How many times the recurring invoice will be created. The recurrence will stop after this number is reached. `max_occurrences` is mutually exclusive with `end_date`. Either `max_occurrences` or `end_date` must be specified.
recipients : typing.Optional[Recipients]
+ An object containing the recipients (To, CC, BCC) of the recurring invoices. Can be omitted if the base invoice has the counterpart contact email specified in the `counterpart_contact.email` field.
+
+ start_date : typing.Optional[str]
+ The date when the first invoice will be created, in the `yyyy-mm-dd` format. Cannot be a past date. Subsequent invoice dates will be calculated based on `start_date`, `frequency`, and `interval`.
+
+ start_month : typing.Optional[int]
+ Deprecated, use `start_date` instead
+
+ start_year : typing.Optional[int]
+ Deprecated, use `start_date` instead
subject_text : typing.Optional[str]
+ The subject for the email that will be sent with the recurring invoice.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- Recurrence
+ RecurrenceResponse
Successful Response
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.recurrences.create(day_of_month="first_day", end_month=1, end_year=1, invoice_id='invoice_id', start_month=1, start_year=1, )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.recurrences.create(
+ invoice_id="invoice_id",
+ )
"""
_response = self._raw_client.create(
+ invoice_id=invoice_id,
+ automation_level=automation_level,
+ body_text=body_text,
day_of_month=day_of_month,
+ end_date=end_date,
end_month=end_month,
end_year=end_year,
- invoice_id=invoice_id,
+ frequency=frequency,
+ interval=interval,
+ max_occurrences=max_occurrences,
+ recipients=recipients,
+ start_date=start_date,
start_month=start_month,
start_year=start_year,
- automation_level=automation_level,
- body_text=body_text,
- recipients=recipients,
subject_text=subject_text,
request_options=request_options,
)
return _response.data
- def get_by_id(self, recurrence_id: str, *, request_options: typing.Optional[RequestOptions] = None) -> Recurrence:
+ def get_by_id(
+ self, recurrence_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> RecurrenceResponse:
"""
Parameters
----------
@@ -137,14 +186,21 @@ def get_by_id(self, recurrence_id: str, *, request_options: typing.Optional[Requ
Returns
-------
- Recurrence
+ RecurrenceResponse
Successful Response
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.recurrences.get_by_id(recurrence_id='recurrence_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.recurrences.get_by_id(
+ recurrence_id="recurrence_id",
+ )
"""
_response = self._raw_client.get_by_id(recurrence_id, request_options=request_options)
return _response.data
@@ -156,12 +212,17 @@ def update_by_id(
automation_level: typing.Optional[AutomationLevel] = OMIT,
body_text: typing.Optional[str] = OMIT,
day_of_month: typing.Optional[DayOfMonth] = OMIT,
+ end_date: typing.Optional[str] = OMIT,
end_month: typing.Optional[int] = OMIT,
end_year: typing.Optional[int] = OMIT,
+ frequency: typing.Optional[RecurrenceFrequency] = OMIT,
+ interval: typing.Optional[int] = OMIT,
+ max_occurrences: typing.Optional[int] = OMIT,
recipients: typing.Optional[Recipients] = OMIT,
+ start_date: typing.Optional[str] = OMIT,
subject_text: typing.Optional[str] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> Recurrence:
+ ) -> RecurrenceResponse:
"""
Parameters
----------
@@ -178,39 +239,72 @@ def update_by_id(
Note: When using "issue_and_send", both subject_text and body_text must be provided.
body_text : typing.Optional[str]
+ The body text for the email that will be sent with the recurring invoice.
day_of_month : typing.Optional[DayOfMonth]
+ Deprecated, use `start_date` instead
+
+ end_date : typing.Optional[str]
+ The end date of the recurring invoice, in the `yyyy-mm-dd` format. The end date is inclusive, that is, the last invoice will be created on this date if the last occurrence falls on this date. `end_date` is mutually exclusive with `max_occurrences`. Either `end_date` or `max_occurrences` must be specified.
end_month : typing.Optional[int]
+ Deprecated, use `end_date` instead
end_year : typing.Optional[int]
+ Deprecated, use `end_date` instead
+
+ frequency : typing.Optional[RecurrenceFrequency]
+ How often the invoice will be created.
+
+ interval : typing.Optional[int]
+ The interval between each occurrence of the invoice. For example, when using monthly frequency, an interval of 1 means invoices will be created every month, an interval of 2 means invoices will be created every 2 months.
+
+ max_occurrences : typing.Optional[int]
+ How many times the recurring invoice will be created. The recurrence will stop after this number is reached. `max_occurrences` is mutually exclusive with `end_date`. Either `max_occurrences` or `end_date` must be specified.
recipients : typing.Optional[Recipients]
+ An object containing the recipients (To, CC, BCC) of the recurring invoices. Can be omitted if the base invoice has the counterpart contact email specified in the `counterpart_contact.email` field.
+
+ start_date : typing.Optional[str]
+ The date when the first invoice will be created, in the `yyyy-mm-dd` format. Cannot be a past date. Subsequent invoice dates will be calculated based on `start_date`, `frequency`, and `interval`.
subject_text : typing.Optional[str]
+ The subject for the email that will be sent with the recurring invoice.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- Recurrence
+ RecurrenceResponse
Successful Response
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.recurrences.update_by_id(recurrence_id='recurrence_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.recurrences.update_by_id(
+ recurrence_id="recurrence_id",
+ )
"""
_response = self._raw_client.update_by_id(
recurrence_id,
automation_level=automation_level,
body_text=body_text,
day_of_month=day_of_month,
+ end_date=end_date,
end_month=end_month,
end_year=end_year,
+ frequency=frequency,
+ interval=interval,
+ max_occurrences=max_occurrences,
recipients=recipients,
+ start_date=start_date,
subject_text=subject_text,
request_options=request_options,
)
@@ -232,12 +326,83 @@ def cancel_by_id(self, recurrence_id: str, *, request_options: typing.Optional[R
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.recurrences.cancel_by_id(recurrence_id='recurrence_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.recurrences.cancel_by_id(
+ recurrence_id="recurrence_id",
+ )
"""
_response = self._raw_client.cancel_by_id(recurrence_id, request_options=request_options)
return _response.data
+ def post_recurrences_id_pause(
+ self, recurrence_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> typing.Optional[typing.Any]:
+ """
+ Parameters
+ ----------
+ recurrence_id : str
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ typing.Optional[typing.Any]
+ Successful Response
+
+ Examples
+ --------
+ from monite import Monite
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.recurrences.post_recurrences_id_pause(
+ recurrence_id="recurrence_id",
+ )
+ """
+ _response = self._raw_client.post_recurrences_id_pause(recurrence_id, request_options=request_options)
+ return _response.data
+
+ def post_recurrences_id_resume(
+ self, recurrence_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> typing.Optional[typing.Any]:
+ """
+ Parameters
+ ----------
+ recurrence_id : str
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ typing.Optional[typing.Any]
+ Successful Response
+
+ Examples
+ --------
+ from monite import Monite
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.recurrences.post_recurrences_id_resume(
+ recurrence_id="recurrence_id",
+ )
+ """
+ _response = self._raw_client.post_recurrences_id_resume(recurrence_id, request_options=request_options)
+ return _response.data
+
class AsyncRecurrencesClient:
def __init__(self, *, client_wrapper: AsyncClientWrapper):
@@ -254,7 +419,7 @@ def with_raw_response(self) -> AsyncRawRecurrencesClient:
"""
return self._raw_client
- async def get(self, *, request_options: typing.Optional[RequestOptions] = None) -> GetAllRecurrences:
+ async def get(self, *, request_options: typing.Optional[RequestOptions] = None) -> RecurrenceResponseList:
"""
Parameters
----------
@@ -263,16 +428,26 @@ async def get(self, *, request_options: typing.Optional[RequestOptions] = None)
Returns
-------
- GetAllRecurrences
+ RecurrenceResponseList
Successful Response
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.recurrences.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(request_options=request_options)
@@ -281,32 +456,28 @@ async def main() -> None:
async def create(
self,
*,
- day_of_month: DayOfMonth,
- end_month: int,
- end_year: int,
invoice_id: str,
- start_month: int,
- start_year: int,
automation_level: typing.Optional[AutomationLevel] = OMIT,
body_text: typing.Optional[str] = OMIT,
+ day_of_month: typing.Optional[DayOfMonth] = OMIT,
+ end_date: typing.Optional[str] = OMIT,
+ end_month: typing.Optional[int] = OMIT,
+ end_year: typing.Optional[int] = OMIT,
+ frequency: typing.Optional[RecurrenceFrequency] = OMIT,
+ interval: typing.Optional[int] = OMIT,
+ max_occurrences: typing.Optional[int] = OMIT,
recipients: typing.Optional[Recipients] = OMIT,
+ start_date: typing.Optional[str] = OMIT,
+ start_month: typing.Optional[int] = OMIT,
+ start_year: typing.Optional[int] = OMIT,
subject_text: typing.Optional[str] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> Recurrence:
+ ) -> RecurrenceResponse:
"""
Parameters
----------
- day_of_month : DayOfMonth
-
- end_month : int
-
- end_year : int
-
invoice_id : str
-
- start_month : int
-
- start_year : int
+ ID of the base invoice that will be used as a template for creating recurring invoices.
automation_level : typing.Optional[AutomationLevel]
Controls how invoices are processed when generated:
@@ -319,38 +490,88 @@ async def create(
Note: When using "issue_and_send", both subject_text and body_text must be provided.
body_text : typing.Optional[str]
+ The body text for the email that will be sent with the recurring invoice.
+
+ day_of_month : typing.Optional[DayOfMonth]
+ Deprecated, use `start_date` instead
+
+ end_date : typing.Optional[str]
+ The end date of the recurring invoice, in the `yyyy-mm-dd` format. The end date is inclusive, that is, the last invoice will be created on this date if the last occurrence falls on this date. `end_date` is mutually exclusive with `max_occurrences`. Either `end_date` or `max_occurrences` must be specified.
+
+ end_month : typing.Optional[int]
+ Deprecated, use `end_date` instead
+
+ end_year : typing.Optional[int]
+ Deprecated, use `end_date` instead
+
+ frequency : typing.Optional[RecurrenceFrequency]
+ How often the invoice will be created.
+
+ interval : typing.Optional[int]
+ The interval between each occurrence of the invoice. For example, when using monthly frequency, an interval of 1 means invoices will be created every month, an interval of 2 means invoices will be created every 2 months.
+
+ max_occurrences : typing.Optional[int]
+ How many times the recurring invoice will be created. The recurrence will stop after this number is reached. `max_occurrences` is mutually exclusive with `end_date`. Either `max_occurrences` or `end_date` must be specified.
recipients : typing.Optional[Recipients]
+ An object containing the recipients (To, CC, BCC) of the recurring invoices. Can be omitted if the base invoice has the counterpart contact email specified in the `counterpart_contact.email` field.
+
+ start_date : typing.Optional[str]
+ The date when the first invoice will be created, in the `yyyy-mm-dd` format. Cannot be a past date. Subsequent invoice dates will be calculated based on `start_date`, `frequency`, and `interval`.
+
+ start_month : typing.Optional[int]
+ Deprecated, use `start_date` instead
+
+ start_year : typing.Optional[int]
+ Deprecated, use `start_date` instead
subject_text : typing.Optional[str]
+ The subject for the email that will be sent with the recurring invoice.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- Recurrence
+ RecurrenceResponse
Successful Response
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.recurrences.create(day_of_month="first_day", end_month=1, end_year=1, invoice_id='invoice_id', start_month=1, start_year=1, )
+ await client.recurrences.create(
+ invoice_id="invoice_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
+ invoice_id=invoice_id,
+ automation_level=automation_level,
+ body_text=body_text,
day_of_month=day_of_month,
+ end_date=end_date,
end_month=end_month,
end_year=end_year,
- invoice_id=invoice_id,
+ frequency=frequency,
+ interval=interval,
+ max_occurrences=max_occurrences,
+ recipients=recipients,
+ start_date=start_date,
start_month=start_month,
start_year=start_year,
- automation_level=automation_level,
- body_text=body_text,
- recipients=recipients,
subject_text=subject_text,
request_options=request_options,
)
@@ -358,7 +579,7 @@ async def main() -> None:
async def get_by_id(
self, recurrence_id: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> Recurrence:
+ ) -> RecurrenceResponse:
"""
Parameters
----------
@@ -369,16 +590,28 @@ async def get_by_id(
Returns
-------
- Recurrence
+ RecurrenceResponse
Successful Response
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.recurrences.get_by_id(recurrence_id='recurrence_id', )
+ await client.recurrences.get_by_id(
+ recurrence_id="recurrence_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(recurrence_id, request_options=request_options)
@@ -391,12 +624,17 @@ async def update_by_id(
automation_level: typing.Optional[AutomationLevel] = OMIT,
body_text: typing.Optional[str] = OMIT,
day_of_month: typing.Optional[DayOfMonth] = OMIT,
+ end_date: typing.Optional[str] = OMIT,
end_month: typing.Optional[int] = OMIT,
end_year: typing.Optional[int] = OMIT,
+ frequency: typing.Optional[RecurrenceFrequency] = OMIT,
+ interval: typing.Optional[int] = OMIT,
+ max_occurrences: typing.Optional[int] = OMIT,
recipients: typing.Optional[Recipients] = OMIT,
+ start_date: typing.Optional[str] = OMIT,
subject_text: typing.Optional[str] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> Recurrence:
+ ) -> RecurrenceResponse:
"""
Parameters
----------
@@ -413,32 +651,65 @@ async def update_by_id(
Note: When using "issue_and_send", both subject_text and body_text must be provided.
body_text : typing.Optional[str]
+ The body text for the email that will be sent with the recurring invoice.
day_of_month : typing.Optional[DayOfMonth]
+ Deprecated, use `start_date` instead
+
+ end_date : typing.Optional[str]
+ The end date of the recurring invoice, in the `yyyy-mm-dd` format. The end date is inclusive, that is, the last invoice will be created on this date if the last occurrence falls on this date. `end_date` is mutually exclusive with `max_occurrences`. Either `end_date` or `max_occurrences` must be specified.
end_month : typing.Optional[int]
+ Deprecated, use `end_date` instead
end_year : typing.Optional[int]
+ Deprecated, use `end_date` instead
+
+ frequency : typing.Optional[RecurrenceFrequency]
+ How often the invoice will be created.
+
+ interval : typing.Optional[int]
+ The interval between each occurrence of the invoice. For example, when using monthly frequency, an interval of 1 means invoices will be created every month, an interval of 2 means invoices will be created every 2 months.
+
+ max_occurrences : typing.Optional[int]
+ How many times the recurring invoice will be created. The recurrence will stop after this number is reached. `max_occurrences` is mutually exclusive with `end_date`. Either `max_occurrences` or `end_date` must be specified.
recipients : typing.Optional[Recipients]
+ An object containing the recipients (To, CC, BCC) of the recurring invoices. Can be omitted if the base invoice has the counterpart contact email specified in the `counterpart_contact.email` field.
+
+ start_date : typing.Optional[str]
+ The date when the first invoice will be created, in the `yyyy-mm-dd` format. Cannot be a past date. Subsequent invoice dates will be calculated based on `start_date`, `frequency`, and `interval`.
subject_text : typing.Optional[str]
+ The subject for the email that will be sent with the recurring invoice.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- Recurrence
+ RecurrenceResponse
Successful Response
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.recurrences.update_by_id(recurrence_id='recurrence_id', )
+ await client.recurrences.update_by_id(
+ recurrence_id="recurrence_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
@@ -446,9 +717,14 @@ async def main() -> None:
automation_level=automation_level,
body_text=body_text,
day_of_month=day_of_month,
+ end_date=end_date,
end_month=end_month,
end_year=end_year,
+ frequency=frequency,
+ interval=interval,
+ max_occurrences=max_occurrences,
recipients=recipients,
+ start_date=start_date,
subject_text=subject_text,
request_options=request_options,
)
@@ -471,12 +747,104 @@ async def cancel_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.recurrences.cancel_by_id(recurrence_id='recurrence_id', )
+ await client.recurrences.cancel_by_id(
+ recurrence_id="recurrence_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.cancel_by_id(recurrence_id, request_options=request_options)
return _response.data
+
+ async def post_recurrences_id_pause(
+ self, recurrence_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> typing.Optional[typing.Any]:
+ """
+ Parameters
+ ----------
+ recurrence_id : str
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ typing.Optional[typing.Any]
+ Successful Response
+
+ Examples
+ --------
+ import asyncio
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
+ async def main() -> None:
+ await client.recurrences.post_recurrences_id_pause(
+ recurrence_id="recurrence_id",
+ )
+
+
+ asyncio.run(main())
+ """
+ _response = await self._raw_client.post_recurrences_id_pause(recurrence_id, request_options=request_options)
+ return _response.data
+
+ async def post_recurrences_id_resume(
+ self, recurrence_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> typing.Optional[typing.Any]:
+ """
+ Parameters
+ ----------
+ recurrence_id : str
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ typing.Optional[typing.Any]
+ Successful Response
+
+ Examples
+ --------
+ import asyncio
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
+ async def main() -> None:
+ await client.recurrences.post_recurrences_id_resume(
+ recurrence_id="recurrence_id",
+ )
+
+
+ asyncio.run(main())
+ """
+ _response = await self._raw_client.post_recurrences_id_resume(recurrence_id, request_options=request_options)
+ return _response.data
diff --git a/src/monite/recurrences/raw_client.py b/src/monite/recurrences/raw_client.py
index 20db49c..a6594cc 100644
--- a/src/monite/recurrences/raw_client.py
+++ b/src/monite/recurrences/raw_client.py
@@ -19,9 +19,10 @@
from ..errors.unprocessable_entity_error import UnprocessableEntityError
from ..types.automation_level import AutomationLevel
from ..types.day_of_month import DayOfMonth
-from ..types.get_all_recurrences import GetAllRecurrences
from ..types.recipients import Recipients
-from ..types.recurrence import Recurrence
+from ..types.recurrence_frequency import RecurrenceFrequency
+from ..types.recurrence_response import RecurrenceResponse
+from ..types.recurrence_response_list import RecurrenceResponseList
# this is used as the default value for optional parameters
OMIT = typing.cast(typing.Any, ...)
@@ -31,7 +32,7 @@ class RawRecurrencesClient:
def __init__(self, *, client_wrapper: SyncClientWrapper):
self._client_wrapper = client_wrapper
- def get(self, *, request_options: typing.Optional[RequestOptions] = None) -> HttpResponse[GetAllRecurrences]:
+ def get(self, *, request_options: typing.Optional[RequestOptions] = None) -> HttpResponse[RecurrenceResponseList]:
"""
Parameters
----------
@@ -40,7 +41,7 @@ def get(self, *, request_options: typing.Optional[RequestOptions] = None) -> Htt
Returns
-------
- HttpResponse[GetAllRecurrences]
+ HttpResponse[RecurrenceResponseList]
Successful Response
"""
_response = self._client_wrapper.httpx_client.request(
@@ -51,9 +52,9 @@ def get(self, *, request_options: typing.Optional[RequestOptions] = None) -> Htt
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- GetAllRecurrences,
+ RecurrenceResponseList,
parse_obj_as(
- type_=GetAllRecurrences, # type: ignore
+ type_=RecurrenceResponseList, # type: ignore
object_=_response.json(),
),
)
@@ -132,32 +133,28 @@ def get(self, *, request_options: typing.Optional[RequestOptions] = None) -> Htt
def create(
self,
*,
- day_of_month: DayOfMonth,
- end_month: int,
- end_year: int,
invoice_id: str,
- start_month: int,
- start_year: int,
automation_level: typing.Optional[AutomationLevel] = OMIT,
body_text: typing.Optional[str] = OMIT,
+ day_of_month: typing.Optional[DayOfMonth] = OMIT,
+ end_date: typing.Optional[str] = OMIT,
+ end_month: typing.Optional[int] = OMIT,
+ end_year: typing.Optional[int] = OMIT,
+ frequency: typing.Optional[RecurrenceFrequency] = OMIT,
+ interval: typing.Optional[int] = OMIT,
+ max_occurrences: typing.Optional[int] = OMIT,
recipients: typing.Optional[Recipients] = OMIT,
+ start_date: typing.Optional[str] = OMIT,
+ start_month: typing.Optional[int] = OMIT,
+ start_year: typing.Optional[int] = OMIT,
subject_text: typing.Optional[str] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[Recurrence]:
+ ) -> HttpResponse[RecurrenceResponse]:
"""
Parameters
----------
- day_of_month : DayOfMonth
-
- end_month : int
-
- end_year : int
-
invoice_id : str
-
- start_month : int
-
- start_year : int
+ ID of the base invoice that will be used as a template for creating recurring invoices.
automation_level : typing.Optional[AutomationLevel]
Controls how invoices are processed when generated:
@@ -170,17 +167,50 @@ def create(
Note: When using "issue_and_send", both subject_text and body_text must be provided.
body_text : typing.Optional[str]
+ The body text for the email that will be sent with the recurring invoice.
+
+ day_of_month : typing.Optional[DayOfMonth]
+ Deprecated, use `start_date` instead
+
+ end_date : typing.Optional[str]
+ The end date of the recurring invoice, in the `yyyy-mm-dd` format. The end date is inclusive, that is, the last invoice will be created on this date if the last occurrence falls on this date. `end_date` is mutually exclusive with `max_occurrences`. Either `end_date` or `max_occurrences` must be specified.
+
+ end_month : typing.Optional[int]
+ Deprecated, use `end_date` instead
+
+ end_year : typing.Optional[int]
+ Deprecated, use `end_date` instead
+
+ frequency : typing.Optional[RecurrenceFrequency]
+ How often the invoice will be created.
+
+ interval : typing.Optional[int]
+ The interval between each occurrence of the invoice. For example, when using monthly frequency, an interval of 1 means invoices will be created every month, an interval of 2 means invoices will be created every 2 months.
+
+ max_occurrences : typing.Optional[int]
+ How many times the recurring invoice will be created. The recurrence will stop after this number is reached. `max_occurrences` is mutually exclusive with `end_date`. Either `max_occurrences` or `end_date` must be specified.
recipients : typing.Optional[Recipients]
+ An object containing the recipients (To, CC, BCC) of the recurring invoices. Can be omitted if the base invoice has the counterpart contact email specified in the `counterpart_contact.email` field.
+
+ start_date : typing.Optional[str]
+ The date when the first invoice will be created, in the `yyyy-mm-dd` format. Cannot be a past date. Subsequent invoice dates will be calculated based on `start_date`, `frequency`, and `interval`.
+
+ start_month : typing.Optional[int]
+ Deprecated, use `start_date` instead
+
+ start_year : typing.Optional[int]
+ Deprecated, use `start_date` instead
subject_text : typing.Optional[str]
+ The subject for the email that will be sent with the recurring invoice.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[Recurrence]
+ HttpResponse[RecurrenceResponse]
Successful Response
"""
_response = self._client_wrapper.httpx_client.request(
@@ -190,12 +220,17 @@ def create(
"automation_level": automation_level,
"body_text": body_text,
"day_of_month": day_of_month,
+ "end_date": end_date,
"end_month": end_month,
"end_year": end_year,
+ "frequency": frequency,
+ "interval": interval,
"invoice_id": invoice_id,
+ "max_occurrences": max_occurrences,
"recipients": convert_and_respect_annotation_metadata(
object_=recipients, annotation=Recipients, direction="write"
),
+ "start_date": start_date,
"start_month": start_month,
"start_year": start_year,
"subject_text": subject_text,
@@ -209,9 +244,9 @@ def create(
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- Recurrence,
+ RecurrenceResponse,
parse_obj_as(
- type_=Recurrence, # type: ignore
+ type_=RecurrenceResponse, # type: ignore
object_=_response.json(),
),
)
@@ -289,7 +324,7 @@ def create(
def get_by_id(
self, recurrence_id: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> HttpResponse[Recurrence]:
+ ) -> HttpResponse[RecurrenceResponse]:
"""
Parameters
----------
@@ -300,7 +335,7 @@ def get_by_id(
Returns
-------
- HttpResponse[Recurrence]
+ HttpResponse[RecurrenceResponse]
Successful Response
"""
_response = self._client_wrapper.httpx_client.request(
@@ -311,9 +346,9 @@ def get_by_id(
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- Recurrence,
+ RecurrenceResponse,
parse_obj_as(
- type_=Recurrence, # type: ignore
+ type_=RecurrenceResponse, # type: ignore
object_=_response.json(),
),
)
@@ -396,12 +431,17 @@ def update_by_id(
automation_level: typing.Optional[AutomationLevel] = OMIT,
body_text: typing.Optional[str] = OMIT,
day_of_month: typing.Optional[DayOfMonth] = OMIT,
+ end_date: typing.Optional[str] = OMIT,
end_month: typing.Optional[int] = OMIT,
end_year: typing.Optional[int] = OMIT,
+ frequency: typing.Optional[RecurrenceFrequency] = OMIT,
+ interval: typing.Optional[int] = OMIT,
+ max_occurrences: typing.Optional[int] = OMIT,
recipients: typing.Optional[Recipients] = OMIT,
+ start_date: typing.Optional[str] = OMIT,
subject_text: typing.Optional[str] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[Recurrence]:
+ ) -> HttpResponse[RecurrenceResponse]:
"""
Parameters
----------
@@ -418,23 +458,44 @@ def update_by_id(
Note: When using "issue_and_send", both subject_text and body_text must be provided.
body_text : typing.Optional[str]
+ The body text for the email that will be sent with the recurring invoice.
day_of_month : typing.Optional[DayOfMonth]
+ Deprecated, use `start_date` instead
+
+ end_date : typing.Optional[str]
+ The end date of the recurring invoice, in the `yyyy-mm-dd` format. The end date is inclusive, that is, the last invoice will be created on this date if the last occurrence falls on this date. `end_date` is mutually exclusive with `max_occurrences`. Either `end_date` or `max_occurrences` must be specified.
end_month : typing.Optional[int]
+ Deprecated, use `end_date` instead
end_year : typing.Optional[int]
+ Deprecated, use `end_date` instead
+
+ frequency : typing.Optional[RecurrenceFrequency]
+ How often the invoice will be created.
+
+ interval : typing.Optional[int]
+ The interval between each occurrence of the invoice. For example, when using monthly frequency, an interval of 1 means invoices will be created every month, an interval of 2 means invoices will be created every 2 months.
+
+ max_occurrences : typing.Optional[int]
+ How many times the recurring invoice will be created. The recurrence will stop after this number is reached. `max_occurrences` is mutually exclusive with `end_date`. Either `max_occurrences` or `end_date` must be specified.
recipients : typing.Optional[Recipients]
+ An object containing the recipients (To, CC, BCC) of the recurring invoices. Can be omitted if the base invoice has the counterpart contact email specified in the `counterpart_contact.email` field.
+
+ start_date : typing.Optional[str]
+ The date when the first invoice will be created, in the `yyyy-mm-dd` format. Cannot be a past date. Subsequent invoice dates will be calculated based on `start_date`, `frequency`, and `interval`.
subject_text : typing.Optional[str]
+ The subject for the email that will be sent with the recurring invoice.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[Recurrence]
+ HttpResponse[RecurrenceResponse]
Successful Response
"""
_response = self._client_wrapper.httpx_client.request(
@@ -444,11 +505,16 @@ def update_by_id(
"automation_level": automation_level,
"body_text": body_text,
"day_of_month": day_of_month,
+ "end_date": end_date,
"end_month": end_month,
"end_year": end_year,
+ "frequency": frequency,
+ "interval": interval,
+ "max_occurrences": max_occurrences,
"recipients": convert_and_respect_annotation_metadata(
object_=recipients, annotation=Recipients, direction="write"
),
+ "start_date": start_date,
"subject_text": subject_text,
},
headers={
@@ -460,9 +526,9 @@ def update_by_id(
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- Recurrence,
+ RecurrenceResponse,
parse_obj_as(
- type_=Recurrence, # type: ignore
+ type_=RecurrenceResponse, # type: ignore
object_=_response.json(),
),
)
@@ -643,6 +709,236 @@ def cancel_by_id(
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+ def post_recurrences_id_pause(
+ self, recurrence_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[typing.Optional[typing.Any]]:
+ """
+ Parameters
+ ----------
+ recurrence_id : str
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[typing.Optional[typing.Any]]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ f"recurrences/{jsonable_encoder(recurrence_id)}/pause",
+ method="POST",
+ request_options=request_options,
+ )
+ try:
+ if _response is None or not _response.text.strip():
+ return HttpResponse(response=_response, data=None)
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 400:
+ raise BadRequestError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 401:
+ raise UnauthorizedError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 409:
+ raise ConflictError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 500:
+ raise InternalServerError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ _response_json = _response.json()
+ except JSONDecodeError:
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def post_recurrences_id_resume(
+ self, recurrence_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[typing.Optional[typing.Any]]:
+ """
+ Parameters
+ ----------
+ recurrence_id : str
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[typing.Optional[typing.Any]]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ f"recurrences/{jsonable_encoder(recurrence_id)}/resume",
+ method="POST",
+ request_options=request_options,
+ )
+ try:
+ if _response is None or not _response.text.strip():
+ return HttpResponse(response=_response, data=None)
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 400:
+ raise BadRequestError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 401:
+ raise UnauthorizedError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 409:
+ raise ConflictError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 500:
+ raise InternalServerError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ _response_json = _response.json()
+ except JSONDecodeError:
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
class AsyncRawRecurrencesClient:
def __init__(self, *, client_wrapper: AsyncClientWrapper):
@@ -650,7 +946,7 @@ def __init__(self, *, client_wrapper: AsyncClientWrapper):
async def get(
self, *, request_options: typing.Optional[RequestOptions] = None
- ) -> AsyncHttpResponse[GetAllRecurrences]:
+ ) -> AsyncHttpResponse[RecurrenceResponseList]:
"""
Parameters
----------
@@ -659,7 +955,7 @@ async def get(
Returns
-------
- AsyncHttpResponse[GetAllRecurrences]
+ AsyncHttpResponse[RecurrenceResponseList]
Successful Response
"""
_response = await self._client_wrapper.httpx_client.request(
@@ -670,9 +966,9 @@ async def get(
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- GetAllRecurrences,
+ RecurrenceResponseList,
parse_obj_as(
- type_=GetAllRecurrences, # type: ignore
+ type_=RecurrenceResponseList, # type: ignore
object_=_response.json(),
),
)
@@ -751,32 +1047,28 @@ async def get(
async def create(
self,
*,
- day_of_month: DayOfMonth,
- end_month: int,
- end_year: int,
invoice_id: str,
- start_month: int,
- start_year: int,
automation_level: typing.Optional[AutomationLevel] = OMIT,
body_text: typing.Optional[str] = OMIT,
+ day_of_month: typing.Optional[DayOfMonth] = OMIT,
+ end_date: typing.Optional[str] = OMIT,
+ end_month: typing.Optional[int] = OMIT,
+ end_year: typing.Optional[int] = OMIT,
+ frequency: typing.Optional[RecurrenceFrequency] = OMIT,
+ interval: typing.Optional[int] = OMIT,
+ max_occurrences: typing.Optional[int] = OMIT,
recipients: typing.Optional[Recipients] = OMIT,
+ start_date: typing.Optional[str] = OMIT,
+ start_month: typing.Optional[int] = OMIT,
+ start_year: typing.Optional[int] = OMIT,
subject_text: typing.Optional[str] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> AsyncHttpResponse[Recurrence]:
+ ) -> AsyncHttpResponse[RecurrenceResponse]:
"""
Parameters
----------
- day_of_month : DayOfMonth
-
- end_month : int
-
- end_year : int
-
invoice_id : str
-
- start_month : int
-
- start_year : int
+ ID of the base invoice that will be used as a template for creating recurring invoices.
automation_level : typing.Optional[AutomationLevel]
Controls how invoices are processed when generated:
@@ -789,17 +1081,50 @@ async def create(
Note: When using "issue_and_send", both subject_text and body_text must be provided.
body_text : typing.Optional[str]
+ The body text for the email that will be sent with the recurring invoice.
+
+ day_of_month : typing.Optional[DayOfMonth]
+ Deprecated, use `start_date` instead
+
+ end_date : typing.Optional[str]
+ The end date of the recurring invoice, in the `yyyy-mm-dd` format. The end date is inclusive, that is, the last invoice will be created on this date if the last occurrence falls on this date. `end_date` is mutually exclusive with `max_occurrences`. Either `end_date` or `max_occurrences` must be specified.
+
+ end_month : typing.Optional[int]
+ Deprecated, use `end_date` instead
+
+ end_year : typing.Optional[int]
+ Deprecated, use `end_date` instead
+
+ frequency : typing.Optional[RecurrenceFrequency]
+ How often the invoice will be created.
+
+ interval : typing.Optional[int]
+ The interval between each occurrence of the invoice. For example, when using monthly frequency, an interval of 1 means invoices will be created every month, an interval of 2 means invoices will be created every 2 months.
+
+ max_occurrences : typing.Optional[int]
+ How many times the recurring invoice will be created. The recurrence will stop after this number is reached. `max_occurrences` is mutually exclusive with `end_date`. Either `max_occurrences` or `end_date` must be specified.
recipients : typing.Optional[Recipients]
+ An object containing the recipients (To, CC, BCC) of the recurring invoices. Can be omitted if the base invoice has the counterpart contact email specified in the `counterpart_contact.email` field.
+
+ start_date : typing.Optional[str]
+ The date when the first invoice will be created, in the `yyyy-mm-dd` format. Cannot be a past date. Subsequent invoice dates will be calculated based on `start_date`, `frequency`, and `interval`.
+
+ start_month : typing.Optional[int]
+ Deprecated, use `start_date` instead
+
+ start_year : typing.Optional[int]
+ Deprecated, use `start_date` instead
subject_text : typing.Optional[str]
+ The subject for the email that will be sent with the recurring invoice.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- AsyncHttpResponse[Recurrence]
+ AsyncHttpResponse[RecurrenceResponse]
Successful Response
"""
_response = await self._client_wrapper.httpx_client.request(
@@ -809,12 +1134,17 @@ async def create(
"automation_level": automation_level,
"body_text": body_text,
"day_of_month": day_of_month,
+ "end_date": end_date,
"end_month": end_month,
"end_year": end_year,
+ "frequency": frequency,
+ "interval": interval,
"invoice_id": invoice_id,
+ "max_occurrences": max_occurrences,
"recipients": convert_and_respect_annotation_metadata(
object_=recipients, annotation=Recipients, direction="write"
),
+ "start_date": start_date,
"start_month": start_month,
"start_year": start_year,
"subject_text": subject_text,
@@ -828,9 +1158,9 @@ async def create(
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- Recurrence,
+ RecurrenceResponse,
parse_obj_as(
- type_=Recurrence, # type: ignore
+ type_=RecurrenceResponse, # type: ignore
object_=_response.json(),
),
)
@@ -908,7 +1238,7 @@ async def create(
async def get_by_id(
self, recurrence_id: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> AsyncHttpResponse[Recurrence]:
+ ) -> AsyncHttpResponse[RecurrenceResponse]:
"""
Parameters
----------
@@ -919,7 +1249,7 @@ async def get_by_id(
Returns
-------
- AsyncHttpResponse[Recurrence]
+ AsyncHttpResponse[RecurrenceResponse]
Successful Response
"""
_response = await self._client_wrapper.httpx_client.request(
@@ -930,9 +1260,9 @@ async def get_by_id(
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- Recurrence,
+ RecurrenceResponse,
parse_obj_as(
- type_=Recurrence, # type: ignore
+ type_=RecurrenceResponse, # type: ignore
object_=_response.json(),
),
)
@@ -1015,12 +1345,17 @@ async def update_by_id(
automation_level: typing.Optional[AutomationLevel] = OMIT,
body_text: typing.Optional[str] = OMIT,
day_of_month: typing.Optional[DayOfMonth] = OMIT,
+ end_date: typing.Optional[str] = OMIT,
end_month: typing.Optional[int] = OMIT,
end_year: typing.Optional[int] = OMIT,
+ frequency: typing.Optional[RecurrenceFrequency] = OMIT,
+ interval: typing.Optional[int] = OMIT,
+ max_occurrences: typing.Optional[int] = OMIT,
recipients: typing.Optional[Recipients] = OMIT,
+ start_date: typing.Optional[str] = OMIT,
subject_text: typing.Optional[str] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> AsyncHttpResponse[Recurrence]:
+ ) -> AsyncHttpResponse[RecurrenceResponse]:
"""
Parameters
----------
@@ -1037,23 +1372,44 @@ async def update_by_id(
Note: When using "issue_and_send", both subject_text and body_text must be provided.
body_text : typing.Optional[str]
+ The body text for the email that will be sent with the recurring invoice.
day_of_month : typing.Optional[DayOfMonth]
+ Deprecated, use `start_date` instead
+
+ end_date : typing.Optional[str]
+ The end date of the recurring invoice, in the `yyyy-mm-dd` format. The end date is inclusive, that is, the last invoice will be created on this date if the last occurrence falls on this date. `end_date` is mutually exclusive with `max_occurrences`. Either `end_date` or `max_occurrences` must be specified.
end_month : typing.Optional[int]
+ Deprecated, use `end_date` instead
end_year : typing.Optional[int]
+ Deprecated, use `end_date` instead
+
+ frequency : typing.Optional[RecurrenceFrequency]
+ How often the invoice will be created.
+
+ interval : typing.Optional[int]
+ The interval between each occurrence of the invoice. For example, when using monthly frequency, an interval of 1 means invoices will be created every month, an interval of 2 means invoices will be created every 2 months.
+
+ max_occurrences : typing.Optional[int]
+ How many times the recurring invoice will be created. The recurrence will stop after this number is reached. `max_occurrences` is mutually exclusive with `end_date`. Either `max_occurrences` or `end_date` must be specified.
recipients : typing.Optional[Recipients]
+ An object containing the recipients (To, CC, BCC) of the recurring invoices. Can be omitted if the base invoice has the counterpart contact email specified in the `counterpart_contact.email` field.
+
+ start_date : typing.Optional[str]
+ The date when the first invoice will be created, in the `yyyy-mm-dd` format. Cannot be a past date. Subsequent invoice dates will be calculated based on `start_date`, `frequency`, and `interval`.
subject_text : typing.Optional[str]
+ The subject for the email that will be sent with the recurring invoice.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- AsyncHttpResponse[Recurrence]
+ AsyncHttpResponse[RecurrenceResponse]
Successful Response
"""
_response = await self._client_wrapper.httpx_client.request(
@@ -1063,11 +1419,16 @@ async def update_by_id(
"automation_level": automation_level,
"body_text": body_text,
"day_of_month": day_of_month,
+ "end_date": end_date,
"end_month": end_month,
"end_year": end_year,
+ "frequency": frequency,
+ "interval": interval,
+ "max_occurrences": max_occurrences,
"recipients": convert_and_respect_annotation_metadata(
object_=recipients, annotation=Recipients, direction="write"
),
+ "start_date": start_date,
"subject_text": subject_text,
},
headers={
@@ -1079,9 +1440,9 @@ async def update_by_id(
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- Recurrence,
+ RecurrenceResponse,
parse_obj_as(
- type_=Recurrence, # type: ignore
+ type_=RecurrenceResponse, # type: ignore
object_=_response.json(),
),
)
@@ -1261,3 +1622,233 @@ async def cancel_by_id(
except JSONDecodeError:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ async def post_recurrences_id_pause(
+ self, recurrence_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> AsyncHttpResponse[typing.Optional[typing.Any]]:
+ """
+ Parameters
+ ----------
+ recurrence_id : str
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ AsyncHttpResponse[typing.Optional[typing.Any]]
+ Successful Response
+ """
+ _response = await self._client_wrapper.httpx_client.request(
+ f"recurrences/{jsonable_encoder(recurrence_id)}/pause",
+ method="POST",
+ request_options=request_options,
+ )
+ try:
+ if _response is None or not _response.text.strip():
+ return AsyncHttpResponse(response=_response, data=None)
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return AsyncHttpResponse(response=_response, data=_data)
+ if _response.status_code == 400:
+ raise BadRequestError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 401:
+ raise UnauthorizedError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 409:
+ raise ConflictError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 500:
+ raise InternalServerError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ _response_json = _response.json()
+ except JSONDecodeError:
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ async def post_recurrences_id_resume(
+ self, recurrence_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> AsyncHttpResponse[typing.Optional[typing.Any]]:
+ """
+ Parameters
+ ----------
+ recurrence_id : str
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ AsyncHttpResponse[typing.Optional[typing.Any]]
+ Successful Response
+ """
+ _response = await self._client_wrapper.httpx_client.request(
+ f"recurrences/{jsonable_encoder(recurrence_id)}/resume",
+ method="POST",
+ request_options=request_options,
+ )
+ try:
+ if _response is None or not _response.text.strip():
+ return AsyncHttpResponse(response=_response, data=None)
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return AsyncHttpResponse(response=_response, data=_data)
+ if _response.status_code == 400:
+ raise BadRequestError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 401:
+ raise UnauthorizedError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 409:
+ raise ConflictError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 500:
+ raise InternalServerError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ _response_json = _response.json()
+ except JSONDecodeError:
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
diff --git a/src/monite/roles/client.py b/src/monite/roles/client.py
index f783e39..a7c8933 100644
--- a/src/monite/roles/client.py
+++ b/src/monite/roles/client.py
@@ -91,7 +91,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.roles.get()
"""
_response = self._raw_client.get(
@@ -134,10 +139,17 @@ def create(
Examples
--------
- from monite import Monite
- from monite import BizObjectsSchemaInput
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.roles.create(name='name', permissions=BizObjectsSchemaInput(), )
+ from monite import BizObjectsSchemaInput, Monite
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.roles.create(
+ name="name",
+ permissions=BizObjectsSchemaInput(),
+ )
"""
_response = self._raw_client.create(name=name, permissions=permissions, request_options=request_options)
return _response.data
@@ -159,8 +171,15 @@ def get_by_id(self, role_id: str, *, request_options: typing.Optional[RequestOpt
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.roles.get_by_id(role_id='role_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.roles.get_by_id(
+ role_id="role_id",
+ )
"""
_response = self._raw_client.get_by_id(role_id, request_options=request_options)
return _response.data
@@ -183,8 +202,15 @@ def delete_roles_id(self, role_id: str, *, request_options: typing.Optional[Requ
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.roles.delete_roles_id(role_id='role_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.roles.delete_roles_id(
+ role_id="role_id",
+ )
"""
_response = self._raw_client.delete_roles_id(role_id, request_options=request_options)
return _response.data
@@ -221,8 +247,15 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.roles.update_by_id(role_id='role_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.roles.update_by_id(
+ role_id="role_id",
+ )
"""
_response = self._raw_client.update_by_id(
role_id, name=name, permissions=permissions, request_options=request_options
@@ -304,11 +337,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.roles.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
@@ -351,12 +394,24 @@ async def create(
Examples
--------
- from monite import AsyncMonite
- from monite import BizObjectsSchemaInput
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite, BizObjectsSchemaInput
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.roles.create(name='name', permissions=BizObjectsSchemaInput(), )
+ await client.roles.create(
+ name="name",
+ permissions=BizObjectsSchemaInput(),
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(name=name, permissions=permissions, request_options=request_options)
@@ -378,11 +433,23 @@ async def get_by_id(self, role_id: str, *, request_options: typing.Optional[Requ
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.roles.get_by_id(role_id='role_id', )
+ await client.roles.get_by_id(
+ role_id="role_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(role_id, request_options=request_options)
@@ -405,11 +472,23 @@ async def delete_roles_id(self, role_id: str, *, request_options: typing.Optiona
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.roles.delete_roles_id(role_id='role_id', )
+ await client.roles.delete_roles_id(
+ role_id="role_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_roles_id(role_id, request_options=request_options)
@@ -446,11 +525,23 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.roles.update_by_id(role_id='role_id', )
+ await client.roles.update_by_id(
+ role_id="role_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
diff --git a/src/monite/tags/client.py b/src/monite/tags/client.py
index 50945b1..fca3aff 100644
--- a/src/monite/tags/client.py
+++ b/src/monite/tags/client.py
@@ -79,7 +79,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.tags.get()
"""
_response = self._raw_client.get(
@@ -132,8 +137,15 @@ def create(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.tags.create(name='Marketing', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.tags.create(
+ name="Marketing",
+ )
"""
_response = self._raw_client.create(
name=name, category=category, description=description, request_options=request_options
@@ -159,8 +171,15 @@ def get_by_id(self, tag_id: str, *, request_options: typing.Optional[RequestOpti
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.tags.get_by_id(tag_id='tag_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.tags.get_by_id(
+ tag_id="tag_id",
+ )
"""
_response = self._raw_client.get_by_id(tag_id, request_options=request_options)
return _response.data
@@ -183,8 +202,15 @@ def delete_by_id(self, tag_id: str, *, request_options: typing.Optional[RequestO
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.tags.delete_by_id(tag_id='tag_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.tags.delete_by_id(
+ tag_id="tag_id",
+ )
"""
_response = self._raw_client.delete_by_id(tag_id, request_options=request_options)
return _response.data
@@ -226,8 +252,15 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.tags.update_by_id(tag_id='tag_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.tags.update_by_id(
+ tag_id="tag_id",
+ )
"""
_response = self._raw_client.update_by_id(
tag_id, category=category, description=description, name=name, request_options=request_options
@@ -298,11 +331,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.tags.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
@@ -354,11 +397,23 @@ async def create(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.tags.create(name='Marketing', )
+ await client.tags.create(
+ name="Marketing",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -384,11 +439,23 @@ async def get_by_id(self, tag_id: str, *, request_options: typing.Optional[Reque
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.tags.get_by_id(tag_id='tag_id', )
+ await client.tags.get_by_id(
+ tag_id="tag_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(tag_id, request_options=request_options)
@@ -411,11 +478,23 @@ async def delete_by_id(self, tag_id: str, *, request_options: typing.Optional[Re
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.tags.delete_by_id(tag_id='tag_id', )
+ await client.tags.delete_by_id(
+ tag_id="tag_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(tag_id, request_options=request_options)
@@ -457,11 +536,23 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.tags.update_by_id(tag_id='tag_id', )
+ await client.tags.update_by_id(
+ tag_id="tag_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
diff --git a/src/monite/text_templates/client.py b/src/monite/text_templates/client.py
index e73a54f..e52a324 100644
--- a/src/monite/text_templates/client.py
+++ b/src/monite/text_templates/client.py
@@ -59,7 +59,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.text_templates.get()
"""
_response = self._raw_client.get(
@@ -100,8 +105,18 @@ def create(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.text_templates.create(document_type="quote", name='name', template='template', type="email_header", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.text_templates.create(
+ document_type="quote",
+ name="name",
+ template="template",
+ type="email_header",
+ )
"""
_response = self._raw_client.create(
document_type=document_type, name=name, template=template, type=type, request_options=request_options
@@ -129,8 +144,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.text_templates.get_by_id(text_template_id='text_template_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.text_templates.get_by_id(
+ text_template_id="text_template_id",
+ )
"""
_response = self._raw_client.get_by_id(text_template_id, request_options=request_options)
return _response.data
@@ -154,8 +176,15 @@ def delete_by_id(self, text_template_id: str, *, request_options: typing.Optiona
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.text_templates.delete_by_id(text_template_id='text_template_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.text_templates.delete_by_id(
+ text_template_id="text_template_id",
+ )
"""
_response = self._raw_client.delete_by_id(text_template_id, request_options=request_options)
return _response.data
@@ -191,8 +220,15 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.text_templates.update_by_id(text_template_id='text_template_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.text_templates.update_by_id(
+ text_template_id="text_template_id",
+ )
"""
_response = self._raw_client.update_by_id(
text_template_id, name=name, template=template, request_options=request_options
@@ -221,8 +257,15 @@ def make_default_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.text_templates.make_default_by_id(text_template_id='text_template_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.text_templates.make_default_by_id(
+ text_template_id="text_template_id",
+ )
"""
_response = self._raw_client.make_default_by_id(text_template_id, request_options=request_options)
return _response.data
@@ -272,11 +315,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.text_templates.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
@@ -316,11 +369,26 @@ async def create(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.text_templates.create(document_type="quote", name='name', template='template', type="email_header", )
+ await client.text_templates.create(
+ document_type="quote",
+ name="name",
+ template="template",
+ type="email_header",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -348,11 +416,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.text_templates.get_by_id(text_template_id='text_template_id', )
+ await client.text_templates.get_by_id(
+ text_template_id="text_template_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(text_template_id, request_options=request_options)
@@ -378,11 +458,23 @@ async def delete_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.text_templates.delete_by_id(text_template_id='text_template_id', )
+ await client.text_templates.delete_by_id(
+ text_template_id="text_template_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(text_template_id, request_options=request_options)
@@ -418,11 +510,23 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.text_templates.update_by_id(text_template_id='text_template_id', )
+ await client.text_templates.update_by_id(
+ text_template_id="text_template_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
@@ -451,11 +555,23 @@ async def make_default_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.text_templates.make_default_by_id(text_template_id='text_template_id', )
+ await client.text_templates.make_default_by_id(
+ text_template_id="text_template_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.make_default_by_id(text_template_id, request_options=request_options)
diff --git a/src/monite/types/__init__.py b/src/monite/types/__init__.py
index 2081e18..ce2c72d 100644
--- a/src/monite/types/__init__.py
+++ b/src/monite/types/__init__.py
@@ -119,7 +119,6 @@
from .counterpart_raw_vat_id import CounterpartRawVatId
from .counterpart_raw_vat_id_update_request import CounterpartRawVatIdUpdateRequest
from .counterpart_response import CounterpartResponse
-from .counterpart_tag_category import CounterpartTagCategory
from .counterpart_tag_schema import CounterpartTagSchema
from .counterpart_type import CounterpartType
from .counterpart_update_payload import CounterpartUpdatePayload
@@ -160,6 +159,8 @@
from .custom_template_data_schema import CustomTemplateDataSchema
from .custom_templates_cursor_fields import CustomTemplatesCursorFields
from .custom_templates_pagination_response import CustomTemplatesPaginationResponse
+from .custom_vat_rate_response import CustomVatRateResponse
+from .custom_vat_rate_response_list import CustomVatRateResponseList
from .data_export_cursor_fields import DataExportCursorFields
from .date_dimension_breakdown_enum import DateDimensionBreakdownEnum
from .day_of_month import DayOfMonth
@@ -181,6 +182,7 @@
from .delivery_note_resource_list import DeliveryNoteResourceList
from .delivery_note_status_enum import DeliveryNoteStatusEnum
from .discount import Discount
+from .discount_response import DiscountResponse
from .discount_type import DiscountType
from .dns_record import DnsRecord
from .dns_record_purpose import DnsRecordPurpose
@@ -242,6 +244,7 @@
from .extra_data_resource import ExtraDataResource
from .extra_data_resource_list import ExtraDataResourceList
from .field_schema import FieldSchema
+from .file_attached_event_data import FileAttachedEventData
from .file_response import FileResponse
from .file_schema import FileSchema
from .file_schema2 import FileSchema2
@@ -257,12 +260,14 @@
from .financing_push_invoices_response import FinancingPushInvoicesResponse
from .financing_token_response import FinancingTokenResponse
from .get_all_payment_reminders import GetAllPaymentReminders
-from .get_all_recurrences import GetAllRecurrences
from .get_onboarding_requirements_response import GetOnboardingRequirementsResponse
from .grant_type import GrantType
from .http_validation_error import HttpValidationError
from .individual_response_schema import IndividualResponseSchema
from .individual_schema import IndividualSchema
+from .inline_payment_terms_request_payload import InlinePaymentTermsRequestPayload
+from .inline_term_discount import InlineTermDiscount
+from .inline_term_final import InlineTermFinal
from .invoice import Invoice
from .invoice_file import InvoiceFile
from .invoice_rendering_settings import InvoiceRenderingSettings
@@ -362,13 +367,21 @@
from .payable_aggregated_data_response import PayableAggregatedDataResponse
from .payable_aggregated_item import PayableAggregatedItem
from .payable_analytics_response import PayableAnalyticsResponse
+from .payable_created_event_data import PayableCreatedEventData
from .payable_credit_note_data import PayableCreditNoteData
+from .payable_credit_note_linked_event_data import PayableCreditNoteLinkedEventData
from .payable_credit_note_state_enum import PayableCreditNoteStateEnum
+from .payable_credit_note_unlinked_event_data import PayableCreditNoteUnlinkedEventData
from .payable_cursor_fields import PayableCursorFields
from .payable_dimension_enum import PayableDimensionEnum
from .payable_entity_address_schema import PayableEntityAddressSchema
from .payable_entity_individual_response import PayableEntityIndividualResponse
from .payable_entity_organization_response import PayableEntityOrganizationResponse
+from .payable_history_cursor_fields import PayableHistoryCursorFields
+from .payable_history_event_type_enum import PayableHistoryEventTypeEnum
+from .payable_history_pagination_response import PayableHistoryPaginationResponse
+from .payable_history_response import PayableHistoryResponse
+from .payable_history_response_event_data import PayableHistoryResponseEventData
from .payable_individual_schema import PayableIndividualSchema
from .payable_metric_enum import PayableMetricEnum
from .payable_organization_schema import PayableOrganizationSchema
@@ -383,9 +396,11 @@
from .payable_schema_output import PayableSchemaOutput
from .payable_settings import PayableSettings
from .payable_state_enum import PayableStateEnum
+from .payable_status_changed_event_data import PayableStatusChangedEventData
from .payable_templates_variable import PayableTemplatesVariable
from .payable_templates_variables_object import PayableTemplatesVariablesObject
from .payable_templates_variables_object_list import PayableTemplatesVariablesObjectList
+from .payable_updated_event_data import PayableUpdatedEventData
from .payable_validation_response import PayableValidationResponse
from .payable_validations_resource import PayableValidationsResource
from .payables_fields_allowed_for_validate import PayablesFieldsAllowedForValidate
@@ -412,6 +427,7 @@
from .payment_priority_enum import PaymentPriorityEnum
from .payment_received_event_data import PaymentReceivedEventData
from .payment_record_cursor_fields import PaymentRecordCursorFields
+from .payment_record_history_response import PaymentRecordHistoryResponse
from .payment_record_object_request import PaymentRecordObjectRequest
from .payment_record_object_response import PaymentRecordObjectResponse
from .payment_record_response import PaymentRecordResponse
@@ -420,9 +436,6 @@
from .payment_record_status_update_request import PaymentRecordStatusUpdateRequest
from .payment_reminder_response import PaymentReminderResponse
from .payment_requirements import PaymentRequirements
-from .payment_term import PaymentTerm
-from .payment_term_discount import PaymentTermDiscount
-from .payment_term_discount_with_date import PaymentTermDiscountWithDate
from .payment_terms import PaymentTerms
from .payment_terms_list_response import PaymentTermsListResponse
from .payment_terms_response import PaymentTermsResponse
@@ -481,11 +494,11 @@
)
from .quote_state_enum import QuoteStateEnum
from .receivable_counterpart_contact import ReceivableCounterpartContact
-from .receivable_counterpart_type import ReceivableCounterpartType
from .receivable_counterpart_vat_id_response import ReceivableCounterpartVatIdResponse
from .receivable_create_based_on_payload import ReceivableCreateBasedOnPayload
from .receivable_created_event_data import ReceivableCreatedEventData
from .receivable_cursor_fields import ReceivableCursorFields
+from .receivable_cursor_fields2 import ReceivableCursorFields2
from .receivable_dimension_enum import ReceivableDimensionEnum
from .receivable_edit_flow import ReceivableEditFlow
from .receivable_entity_address_schema import ReceivableEntityAddressSchema
@@ -522,7 +535,6 @@
)
from .receivable_send_response import ReceivableSendResponse
from .receivable_settings import ReceivableSettings
-from .receivable_tag_category import ReceivableTagCategory
from .receivable_templates_variable import ReceivableTemplatesVariable
from .receivable_templates_variables_object import ReceivableTemplatesVariablesObject
from .receivable_templates_variables_object_list import ReceivableTemplatesVariablesObjectList
@@ -543,8 +555,10 @@
from .recipient_account_response import RecipientAccountResponse
from .recipient_type import RecipientType
from .recipients import Recipients
-from .recurrence import Recurrence
+from .recurrence_frequency import RecurrenceFrequency
from .recurrence_iteration import RecurrenceIteration
+from .recurrence_response import RecurrenceResponse
+from .recurrence_response_list import RecurrenceResponseList
from .recurrence_status import RecurrenceStatus
from .related_documents import RelatedDocuments
from .reminder import Reminder
@@ -653,7 +667,8 @@
from .template_list_response import TemplateListResponse
from .template_receivable_response import TemplateReceivableResponse
from .template_type_enum import TemplateTypeEnum
-from .term_final_with_date import TermFinalWithDate
+from .term_discount_days import TermDiscountDays
+from .term_final_days import TermFinalDays
from .terms_of_service_acceptance_input import TermsOfServiceAcceptanceInput
from .terms_of_service_acceptance_output import TermsOfServiceAcceptanceOutput
from .text_template_document_type_enum import TextTemplateDocumentTypeEnum
@@ -661,12 +676,14 @@
from .text_template_response_list import TextTemplateResponseList
from .text_template_type import TextTemplateType
from .total_vat_amount_item import TotalVatAmountItem
+from .total_vat_amount_item_component import TotalVatAmountItemComponent
from .unit import Unit
from .unit_list_response import UnitListResponse
from .unit_request import UnitRequest
from .unit_response import UnitResponse
from .update_credit_note import UpdateCreditNote
from .update_credit_note_payload import UpdateCreditNotePayload
+from .update_einvoicing_address import UpdateEinvoicingAddress
from .update_entity_address_schema import UpdateEntityAddressSchema
from .update_entity_request import UpdateEntityRequest
from .update_invoice import UpdateInvoice
@@ -690,6 +707,7 @@
from .variables_type import VariablesType
from .vat_id_type_enum import VatIdTypeEnum
from .vat_mode_enum import VatModeEnum
+from .vat_rate_component import VatRateComponent
from .vat_rate_creator import VatRateCreator
from .vat_rate_list_response import VatRateListResponse
from .vat_rate_response import VatRateResponse
@@ -831,7 +849,6 @@
"CounterpartRawVatId",
"CounterpartRawVatIdUpdateRequest",
"CounterpartResponse",
- "CounterpartTagCategory",
"CounterpartTagSchema",
"CounterpartType",
"CounterpartUpdatePayload",
@@ -868,6 +885,8 @@
"CustomTemplateDataSchema",
"CustomTemplatesCursorFields",
"CustomTemplatesPaginationResponse",
+ "CustomVatRateResponse",
+ "CustomVatRateResponseList",
"DataExportCursorFields",
"DateDimensionBreakdownEnum",
"DayOfMonth",
@@ -887,6 +906,7 @@
"DeliveryNoteResourceList",
"DeliveryNoteStatusEnum",
"Discount",
+ "DiscountResponse",
"DiscountType",
"DnsRecord",
"DnsRecordPurpose",
@@ -952,6 +972,7 @@
"ExtraDataResource",
"ExtraDataResourceList",
"FieldSchema",
+ "FileAttachedEventData",
"FileResponse",
"FileSchema",
"FileSchema2",
@@ -967,12 +988,14 @@
"FinancingPushInvoicesResponse",
"FinancingTokenResponse",
"GetAllPaymentReminders",
- "GetAllRecurrences",
"GetOnboardingRequirementsResponse",
"GrantType",
"HttpValidationError",
"IndividualResponseSchema",
"IndividualSchema",
+ "InlinePaymentTermsRequestPayload",
+ "InlineTermDiscount",
+ "InlineTermFinal",
"Invoice",
"InvoiceFile",
"InvoiceRenderingSettings",
@@ -1068,13 +1091,21 @@
"PayableAggregatedDataResponse",
"PayableAggregatedItem",
"PayableAnalyticsResponse",
+ "PayableCreatedEventData",
"PayableCreditNoteData",
+ "PayableCreditNoteLinkedEventData",
"PayableCreditNoteStateEnum",
+ "PayableCreditNoteUnlinkedEventData",
"PayableCursorFields",
"PayableDimensionEnum",
"PayableEntityAddressSchema",
"PayableEntityIndividualResponse",
"PayableEntityOrganizationResponse",
+ "PayableHistoryCursorFields",
+ "PayableHistoryEventTypeEnum",
+ "PayableHistoryPaginationResponse",
+ "PayableHistoryResponse",
+ "PayableHistoryResponseEventData",
"PayableIndividualSchema",
"PayableMetricEnum",
"PayableOrganizationSchema",
@@ -1089,9 +1120,11 @@
"PayableSchemaOutput",
"PayableSettings",
"PayableStateEnum",
+ "PayableStatusChangedEventData",
"PayableTemplatesVariable",
"PayableTemplatesVariablesObject",
"PayableTemplatesVariablesObjectList",
+ "PayableUpdatedEventData",
"PayableValidationResponse",
"PayableValidationsResource",
"PayablesFieldsAllowedForValidate",
@@ -1118,6 +1151,7 @@
"PaymentPriorityEnum",
"PaymentReceivedEventData",
"PaymentRecordCursorFields",
+ "PaymentRecordHistoryResponse",
"PaymentRecordObjectRequest",
"PaymentRecordObjectResponse",
"PaymentRecordResponse",
@@ -1126,9 +1160,6 @@
"PaymentRecordStatusUpdateRequest",
"PaymentReminderResponse",
"PaymentRequirements",
- "PaymentTerm",
- "PaymentTermDiscount",
- "PaymentTermDiscountWithDate",
"PaymentTerms",
"PaymentTermsListResponse",
"PaymentTermsResponse",
@@ -1185,11 +1216,11 @@
"QuoteResponsePayloadEntity_Organization",
"QuoteStateEnum",
"ReceivableCounterpartContact",
- "ReceivableCounterpartType",
"ReceivableCounterpartVatIdResponse",
"ReceivableCreateBasedOnPayload",
"ReceivableCreatedEventData",
"ReceivableCursorFields",
+ "ReceivableCursorFields2",
"ReceivableDimensionEnum",
"ReceivableEditFlow",
"ReceivableEntityAddressSchema",
@@ -1224,7 +1255,6 @@
"ReceivableResponse_Quote",
"ReceivableSendResponse",
"ReceivableSettings",
- "ReceivableTagCategory",
"ReceivableTemplatesVariable",
"ReceivableTemplatesVariablesObject",
"ReceivableTemplatesVariablesObjectList",
@@ -1245,8 +1275,10 @@
"RecipientAccountResponse",
"RecipientType",
"Recipients",
- "Recurrence",
+ "RecurrenceFrequency",
"RecurrenceIteration",
+ "RecurrenceResponse",
+ "RecurrenceResponseList",
"RecurrenceStatus",
"RelatedDocuments",
"Reminder",
@@ -1351,7 +1383,8 @@
"TemplateListResponse",
"TemplateReceivableResponse",
"TemplateTypeEnum",
- "TermFinalWithDate",
+ "TermDiscountDays",
+ "TermFinalDays",
"TermsOfServiceAcceptanceInput",
"TermsOfServiceAcceptanceOutput",
"TextTemplateDocumentTypeEnum",
@@ -1359,12 +1392,14 @@
"TextTemplateResponseList",
"TextTemplateType",
"TotalVatAmountItem",
+ "TotalVatAmountItemComponent",
"Unit",
"UnitListResponse",
"UnitRequest",
"UnitResponse",
"UpdateCreditNote",
"UpdateCreditNotePayload",
+ "UpdateEinvoicingAddress",
"UpdateEntityAddressSchema",
"UpdateEntityRequest",
"UpdateInvoice",
@@ -1386,6 +1421,7 @@
"VariablesType",
"VatIdTypeEnum",
"VatModeEnum",
+ "VatRateComponent",
"VatRateCreator",
"VatRateListResponse",
"VatRateResponse",
diff --git a/src/monite/types/counterpart_tag_category.py b/src/monite/types/counterpart_tag_category.py
deleted file mode 100644
index 38dc0b7..0000000
--- a/src/monite/types/counterpart_tag_category.py
+++ /dev/null
@@ -1,10 +0,0 @@
-# This file was auto-generated by Fern from our API Definition.
-
-import typing
-
-CounterpartTagCategory = typing.Union[
- typing.Literal[
- "document_type", "department", "project", "cost_center", "vendor_type", "payment_method", "approval_status"
- ],
- typing.Any,
-]
diff --git a/src/monite/types/counterpart_tag_schema.py b/src/monite/types/counterpart_tag_schema.py
index c93cfd8..09da45a 100644
--- a/src/monite/types/counterpart_tag_schema.py
+++ b/src/monite/types/counterpart_tag_schema.py
@@ -5,7 +5,7 @@
import pydantic
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
-from .counterpart_tag_category import CounterpartTagCategory
+from .tag_category import TagCategory
class CounterpartTagSchema(UniversalBaseModel):
@@ -28,7 +28,7 @@ class CounterpartTagSchema(UniversalBaseModel):
Date and time when the tag was last updated. Timestamps follow the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) standard.
"""
- category: typing.Optional[CounterpartTagCategory] = pydantic.Field(default=None)
+ category: typing.Optional[TagCategory] = pydantic.Field(default=None)
"""
The tag category.
"""
diff --git a/src/monite/types/credit_note_response_payload.py b/src/monite/types/credit_note_response_payload.py
index cca5252..047a288 100644
--- a/src/monite/types/credit_note_response_payload.py
+++ b/src/monite/types/credit_note_response_payload.py
@@ -5,14 +5,14 @@
import pydantic
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .counterpart_type import CounterpartType
from .credit_note_response_payload_entity import CreditNoteResponsePayloadEntity
from .credit_note_state_enum import CreditNoteStateEnum
from .currency_enum import CurrencyEnum
-from .discount import Discount
+from .discount_response import DiscountResponse
from .einvoicing_credentials import EinvoicingCredentials
from .language_code_enum import LanguageCodeEnum
from .receivable_counterpart_contact import ReceivableCounterpartContact
-from .receivable_counterpart_type import ReceivableCounterpartType
from .receivable_counterpart_vat_id_response import ReceivableCounterpartVatIdResponse
from .receivable_entity_address_schema import ReceivableEntityAddressSchema
from .receivable_entity_vat_id_response import ReceivableEntityVatIdResponse
@@ -100,7 +100,7 @@ class CreditNoteResponsePayload(UniversalBaseModel):
The VAT/TAX ID of the counterpart.
"""
- counterpart_type: ReceivableCounterpartType = pydantic.Field()
+ counterpart_type: CounterpartType = pydantic.Field()
"""
The type of the counterpart.
"""
@@ -121,7 +121,7 @@ class CreditNoteResponsePayload(UniversalBaseModel):
A note with additional information about a tax deduction
"""
- discount: typing.Optional[Discount] = pydantic.Field(default=None)
+ discount: typing.Optional[DiscountResponse] = pydantic.Field(default=None)
"""
The discount for a receivable.
"""
diff --git a/src/monite/types/custom_vat_rate_response.py b/src/monite/types/custom_vat_rate_response.py
new file mode 100644
index 0000000..4235461
--- /dev/null
+++ b/src/monite/types/custom_vat_rate_response.py
@@ -0,0 +1,50 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import datetime as dt
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .vat_rate_component import VatRateComponent
+
+
+class CustomVatRateResponse(UniversalBaseModel):
+ id: str
+ created_at: dt.datetime = pydantic.Field()
+ """
+ Time at which the Custom VAT rate was created. Timestamps follow the ISO 8601 standard.
+ """
+
+ updated_at: dt.datetime = pydantic.Field()
+ """
+ Time at which the Custom VAT rate was last updated. Timestamps follow the ISO 8601 standard.
+ """
+
+ components: typing.List[VatRateComponent] = pydantic.Field()
+ """
+ Sub-taxes included in the Custom VAT.
+ """
+
+ created_by_entity_user_id: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ ID of the user that created the Custom VAT rate
+ """
+
+ name: str = pydantic.Field()
+ """
+ Display name of the Custom VAT.
+ """
+
+ value: float = pydantic.Field()
+ """
+ Total sum of the Custom VAT rate including components. Percent multiplied by a 100. Example: 12.125% is 1212.5.
+ """
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/src/monite/types/custom_vat_rate_response_list.py b/src/monite/types/custom_vat_rate_response_list.py
new file mode 100644
index 0000000..8977254
--- /dev/null
+++ b/src/monite/types/custom_vat_rate_response_list.py
@@ -0,0 +1,20 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .custom_vat_rate_response import CustomVatRateResponse
+
+
+class CustomVatRateResponseList(UniversalBaseModel):
+ data: typing.List[CustomVatRateResponse]
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/src/monite/types/discount_response.py b/src/monite/types/discount_response.py
new file mode 100644
index 0000000..bab4019
--- /dev/null
+++ b/src/monite/types/discount_response.py
@@ -0,0 +1,33 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .discount_type import DiscountType
+
+
+class DiscountResponse(UniversalBaseModel):
+ amount: int = pydantic.Field()
+ """
+ The actual discount of the product in [minor units](https://docs.monite.com/references/currencies#minor-units) if type field equals amount, else in percent minor units
+ """
+
+ type: DiscountType = pydantic.Field()
+ """
+ The field specifies whether to use product currency or %.
+ """
+
+ value: typing.Optional[int] = pydantic.Field(default=None)
+ """
+ The monetary amount of the discount, in [minor units](https://docs.monite.com/references/currencies#minor-units). If the discount `type` is `amount`, this value is the same as the `amount` value. If `type` is `percentage`, the value is the calculated discount amount.
+ """
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/src/monite/types/einvoicing_connection_response.py b/src/monite/types/einvoicing_connection_response.py
index cf67b8e..a266ae3 100644
--- a/src/monite/types/einvoicing_connection_response.py
+++ b/src/monite/types/einvoicing_connection_response.py
@@ -36,6 +36,16 @@ class EinvoicingConnectionResponse(UniversalBaseModel):
ID of the entity
"""
+ is_receiver: typing.Optional[bool] = pydantic.Field(default=None)
+ """
+ Set to `true` if the entity needs to receive e-invoices.
+ """
+
+ is_sender: typing.Optional[bool] = pydantic.Field(default=None)
+ """
+ Set to `true` if the entity needs to send e-invoices. Either `is_sender` or `is_receiver` or both must be `true`.
+ """
+
legal_name: str = pydantic.Field()
"""
Legal name of the Entity
diff --git a/src/monite/types/entity_pagination_response.py b/src/monite/types/entity_pagination_response.py
index 0dcd139..ffb600a 100644
--- a/src/monite/types/entity_pagination_response.py
+++ b/src/monite/types/entity_pagination_response.py
@@ -13,14 +13,14 @@ class EntityPaginationResponse(UniversalBaseModel):
A set of entities of different types returned per page
"""
- prev_pagination_token: typing.Optional[str] = pydantic.Field(default=None)
+ next_pagination_token: typing.Optional[str] = pydantic.Field(default=None)
"""
- A token that can be sent in the `pagination_token` query parameter to get the previous page of results, or `null` if there is no previous page (i.e. you've reached the first page).
+ A token that can be sent in the `pagination_token` query parameter to get the next page of results, or `null` if there is no next page (i.e. you've reached the last page).
"""
- next_pagination_token: typing.Optional[str] = pydantic.Field(default=None)
+ prev_pagination_token: typing.Optional[str] = pydantic.Field(default=None)
"""
- A token that can be sent in the `pagination_token` query parameter to get the next page of results, or `null` if there is no next page (i.e. you've reached the last page).
+ A token that can be sent in the `pagination_token` query parameter to get the previous page of results, or `null` if there is no previous page (i.e. you've reached the first page).
"""
if IS_PYDANTIC_V2:
diff --git a/src/monite/types/get_all_recurrences.py b/src/monite/types/file_attached_event_data.py
similarity index 80%
rename from src/monite/types/get_all_recurrences.py
rename to src/monite/types/file_attached_event_data.py
index 116f5de..6dfe9d4 100644
--- a/src/monite/types/get_all_recurrences.py
+++ b/src/monite/types/file_attached_event_data.py
@@ -4,11 +4,12 @@
import pydantic
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
-from .recurrence import Recurrence
-class GetAllRecurrences(UniversalBaseModel):
- data: typing.List[Recurrence]
+class FileAttachedEventData(UniversalBaseModel):
+ file_name: str
+ file_size: int
+ url: str
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
diff --git a/src/monite/types/inline_payment_terms_request_payload.py b/src/monite/types/inline_payment_terms_request_payload.py
new file mode 100644
index 0000000..4014a0a
--- /dev/null
+++ b/src/monite/types/inline_payment_terms_request_payload.py
@@ -0,0 +1,40 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+import typing_extensions
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from ..core.serialization import FieldMetadata
+from .inline_term_discount import InlineTermDiscount
+from .inline_term_final import InlineTermFinal
+
+
+class InlinePaymentTermsRequestPayload(UniversalBaseModel):
+ term1: typing_extensions.Annotated[typing.Optional[InlineTermDiscount], FieldMetadata(alias="term_1")] = (
+ pydantic.Field(default=None)
+ )
+ """
+ The first tier of the payment term. Represents the terms of the first early discount.
+ """
+
+ term2: typing_extensions.Annotated[typing.Optional[InlineTermDiscount], FieldMetadata(alias="term_2")] = (
+ pydantic.Field(default=None)
+ )
+ """
+ The second tier of the payment term. Defines the terms of the second early discount.
+ """
+
+ term_final: InlineTermFinal = pydantic.Field()
+ """
+ The final tier of the payment term. Defines the invoice due date.
+ """
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/src/monite/types/payment_term_discount_with_date.py b/src/monite/types/inline_term_discount.py
similarity index 85%
rename from src/monite/types/payment_term_discount_with_date.py
rename to src/monite/types/inline_term_discount.py
index 913366a..1a32fd1 100644
--- a/src/monite/types/payment_term_discount_with_date.py
+++ b/src/monite/types/inline_term_discount.py
@@ -6,14 +6,14 @@
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
-class PaymentTermDiscountWithDate(UniversalBaseModel):
+class InlineTermDiscount(UniversalBaseModel):
discount: int = pydantic.Field()
"""
The discount percentage in minor units. E.g., 200 means 2%. 1050 means 10.5%.
"""
end_date: typing.Optional[str] = None
- number_of_days: int = pydantic.Field()
+ number_of_days: typing.Optional[int] = pydantic.Field(default=None)
"""
The amount of days after the invoice issue date.
"""
diff --git a/src/monite/types/term_final_with_date.py b/src/monite/types/inline_term_final.py
similarity index 83%
rename from src/monite/types/term_final_with_date.py
rename to src/monite/types/inline_term_final.py
index f3e32cc..1abb3e5 100644
--- a/src/monite/types/term_final_with_date.py
+++ b/src/monite/types/inline_term_final.py
@@ -6,9 +6,9 @@
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
-class TermFinalWithDate(UniversalBaseModel):
+class InlineTermFinal(UniversalBaseModel):
end_date: typing.Optional[str] = None
- number_of_days: int = pydantic.Field()
+ number_of_days: typing.Optional[int] = pydantic.Field(default=None)
"""
The amount of days after the invoice issue date.
"""
diff --git a/src/monite/types/invoice_response_payload.py b/src/monite/types/invoice_response_payload.py
index 77fef77..12f6b19 100644
--- a/src/monite/types/invoice_response_payload.py
+++ b/src/monite/types/invoice_response_payload.py
@@ -5,14 +5,14 @@
import pydantic
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .counterpart_type import CounterpartType
from .currency_enum import CurrencyEnum
-from .discount import Discount
+from .discount_response import DiscountResponse
from .einvoicing_credentials import EinvoicingCredentials
from .invoice_response_payload_entity import InvoiceResponsePayloadEntity
from .language_code_enum import LanguageCodeEnum
from .payment_terms import PaymentTerms
from .receivable_counterpart_contact import ReceivableCounterpartContact
-from .receivable_counterpart_type import ReceivableCounterpartType
from .receivable_counterpart_vat_id_response import ReceivableCounterpartVatIdResponse
from .receivable_entity_address_schema import ReceivableEntityAddressSchema
from .receivable_entity_vat_id_response import ReceivableEntityVatIdResponse
@@ -122,7 +122,7 @@ class InvoiceResponsePayload(UniversalBaseModel):
The VAT/TAX ID of the counterpart.
"""
- counterpart_type: ReceivableCounterpartType = pydantic.Field()
+ counterpart_type: CounterpartType = pydantic.Field()
"""
The type of the counterpart.
"""
@@ -143,7 +143,7 @@ class InvoiceResponsePayload(UniversalBaseModel):
A note with additional information about a tax deduction
"""
- discount: typing.Optional[Discount] = pydantic.Field(default=None)
+ discount: typing.Optional[DiscountResponse] = pydantic.Field(default=None)
"""
The discount for a receivable.
"""
diff --git a/src/monite/types/item.py b/src/monite/types/item.py
index a3cfc24..8a4f5ba 100644
--- a/src/monite/types/item.py
+++ b/src/monite/types/item.py
@@ -11,17 +11,16 @@ class Item(UniversalBaseModel):
Contains information about a text block or line extracted from an uploaded document by OCR.
"""
- text: str = pydantic.Field()
- """
- The text as recognized by OCR.
- """
-
confidence: float = pydantic.Field()
"""
OCR confidence score - the estimated accuracy percentage of character recognition of the extracted text, from 0 to 100%.
"""
processed_text: typing.Optional[typing.Optional[typing.Any]] = None
+ text: str = pydantic.Field()
+ """
+ The text as recognized by OCR.
+ """
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
diff --git a/src/monite/types/iteration_status.py b/src/monite/types/iteration_status.py
index dac16f7..1ecdcd2 100644
--- a/src/monite/types/iteration_status.py
+++ b/src/monite/types/iteration_status.py
@@ -3,5 +3,5 @@
import typing
IterationStatus = typing.Union[
- typing.Literal["pending", "completed", "canceled", "issue_failed", "send_failed"], typing.Any
+ typing.Literal["pending", "completed", "canceled", "skipped", "issue_failed", "send_failed"], typing.Any
]
diff --git a/src/monite/types/line_item.py b/src/monite/types/line_item.py
index 00cdc0f..e488cb5 100644
--- a/src/monite/types/line_item.py
+++ b/src/monite/types/line_item.py
@@ -14,6 +14,11 @@ class LineItem(UniversalBaseModel):
ID of the tax rate in the connected accounting system, to be used when pushing the invoice to that accounting system. Use `GET /accounting_tax_rates` to get these IDs. If omitted, Monite will attempt to match the tax rates based on their numeric value.
"""
+ custom_vat_rate_id: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Unique identifier of the user-defined vat rate object.
+ """
+
discount: typing.Optional[Discount] = pydantic.Field(default=None)
"""
The discount for a product.
@@ -34,6 +39,11 @@ class LineItem(UniversalBaseModel):
The quantity of each of the goods, materials, or services listed in the receivable.
"""
+ tax_rate_name: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Specifies the display name of the tax rate. This field is applicable only when tax_rate_value is also provided.
+ """
+
tax_rate_value: typing.Optional[int] = pydantic.Field(default=None)
"""
Percent minor units. Example: 12.5% is 1250. This field is only required on invoices issued by entities in the US, Pakistan, and other unsupported countries.
diff --git a/src/monite/types/line_item_product.py b/src/monite/types/line_item_product.py
index 020067f..665a6fc 100644
--- a/src/monite/types/line_item_product.py
+++ b/src/monite/types/line_item_product.py
@@ -26,6 +26,11 @@ class LineItemProduct(UniversalBaseModel):
Description of the product.
"""
+ external_reference: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ A user-defined identifier of the product. For example, an internal product code or SKU (stock keeping unit). Client applications can use this field to map the products in Monite to an external product catalog.
+ """
+
is_inline: typing.Optional[bool] = pydantic.Field(default=None)
"""
Indicates whether the product is inline
diff --git a/src/monite/types/line_item_product_create.py b/src/monite/types/line_item_product_create.py
index 592f056..b10f1c9 100644
--- a/src/monite/types/line_item_product_create.py
+++ b/src/monite/types/line_item_product_create.py
@@ -15,6 +15,11 @@ class LineItemProductCreate(UniversalBaseModel):
Description of the product.
"""
+ external_reference: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ A user-defined identifier of the product. For example, an internal product code or SKU (stock keeping unit). Client applications can use this field to map the products in Monite to an external product catalog.
+ """
+
ledger_account_id: typing.Optional[str] = None
measure_unit: typing.Optional[UnitRequest] = None
name: str = pydantic.Field()
diff --git a/src/monite/types/line_item_product_vat_rate.py b/src/monite/types/line_item_product_vat_rate.py
index d32dde0..c671f94 100644
--- a/src/monite/types/line_item_product_vat_rate.py
+++ b/src/monite/types/line_item_product_vat_rate.py
@@ -5,6 +5,7 @@
import pydantic
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
from .allowed_countries import AllowedCountries
+from .vat_rate_component import VatRateComponent
class LineItemProductVatRate(UniversalBaseModel):
@@ -13,11 +14,26 @@ class LineItemProductVatRate(UniversalBaseModel):
Unique identifier of the vat rate object.
"""
+ components: typing.Optional[typing.List[VatRateComponent]] = pydantic.Field(default=None)
+ """
+ Sub-taxes included in the VAT.
+ """
+
country: AllowedCountries = pydantic.Field()
"""
Two-letter ISO country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
"""
+ is_custom: typing.Optional[bool] = pydantic.Field(default=None)
+ """
+ Indicates whether this vat rate is defined by user.
+ """
+
+ name: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Display name of the vat rate.
+ """
+
value: int = pydantic.Field()
"""
Percent minor units. Example: 12.5% is 1250.
diff --git a/src/monite/types/line_item_update.py b/src/monite/types/line_item_update.py
index 627f859..47069da 100644
--- a/src/monite/types/line_item_update.py
+++ b/src/monite/types/line_item_update.py
@@ -8,6 +8,11 @@
class LineItemUpdate(UniversalBaseModel):
+ custom_vat_rate_id: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Unique identifier of the user-defined vat rate object.
+ """
+
discount: typing.Optional[Discount] = pydantic.Field(default=None)
"""
The discount for a product.
@@ -23,6 +28,11 @@ class LineItemUpdate(UniversalBaseModel):
The quantity of each of the goods, materials, or services listed in the receivable.
"""
+ tax_rate_name: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Specifies the display name of the tax rate. This field is applicable only when tax_rate_value is also provided.
+ """
+
tax_rate_value: typing.Optional[int] = pydantic.Field(default=None)
"""
Percent minor units. Example: 12.5% is 1250. This field is only required on invoices issued by entities in the US, Pakistan, and other unsupported countries.
diff --git a/src/monite/types/monite_all_payment_methods.py b/src/monite/types/monite_all_payment_methods.py
index bdc76dd..1efd8a3 100644
--- a/src/monite/types/monite_all_payment_methods.py
+++ b/src/monite/types/monite_all_payment_methods.py
@@ -18,6 +18,8 @@
"SOFORT",
"Apple Pay",
"Google Pay",
+ "Affirm",
+ "Klarna",
],
typing.Any,
]
diff --git a/src/monite/types/monite_all_payment_methods_types.py b/src/monite/types/monite_all_payment_methods_types.py
index a0c97f2..b1121a5 100644
--- a/src/monite/types/monite_all_payment_methods_types.py
+++ b/src/monite/types/monite_all_payment_methods_types.py
@@ -18,6 +18,8 @@
"sofort",
"applepay",
"googlepay",
+ "affirm",
+ "klarna",
],
typing.Any,
]
diff --git a/src/monite/types/ocr_address.py b/src/monite/types/ocr_address.py
index 485c8d7..fe5ba2a 100644
--- a/src/monite/types/ocr_address.py
+++ b/src/monite/types/ocr_address.py
@@ -13,39 +13,39 @@ class OcrAddress(UniversalBaseModel):
* There is an additional field original_country_name
"""
- country: typing.Optional[str] = pydantic.Field(default=None)
+ city: typing.Optional[str] = pydantic.Field(default=None)
"""
- Two-letter ISO country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
+ City name.
"""
- original_country_name: typing.Optional[str] = pydantic.Field(default=None)
+ country: typing.Optional[str] = pydantic.Field(default=None)
"""
- Country name as it is stated in the document.
+ Two-letter ISO country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
"""
- city: typing.Optional[str] = pydantic.Field(default=None)
+ line1: typing.Optional[str] = pydantic.Field(default=None)
"""
- City name.
+ Street address.
"""
- postal_code: typing.Optional[str] = pydantic.Field(default=None)
+ line2: typing.Optional[str] = pydantic.Field(default=None)
"""
- ZIP or postal code.
+ Additional address information (if any).
"""
- state: typing.Optional[str] = pydantic.Field(default=None)
+ original_country_name: typing.Optional[str] = pydantic.Field(default=None)
"""
- State, region, province, or county.
+ Country name as it is stated in the document.
"""
- line1: typing.Optional[str] = pydantic.Field(default=None)
+ postal_code: typing.Optional[str] = pydantic.Field(default=None)
"""
- Street address.
+ ZIP or postal code.
"""
- line2: typing.Optional[str] = pydantic.Field(default=None)
+ state: typing.Optional[str] = pydantic.Field(default=None)
"""
- Additional address information (if any).
+ State, region, province, or county.
"""
if IS_PYDANTIC_V2:
diff --git a/src/monite/types/ocr_document_type_enum.py b/src/monite/types/ocr_document_type_enum.py
index 382a2ab..c6b4024 100644
--- a/src/monite/types/ocr_document_type_enum.py
+++ b/src/monite/types/ocr_document_type_enum.py
@@ -2,15 +2,4 @@
import typing
-OcrDocumentTypeEnum = typing.Union[
- typing.Literal[
- "quote",
- "invoice",
- "credit_note",
- "discount_reminder",
- "final_reminder",
- "payables_purchase_order",
- "overdue_reminder",
- ],
- typing.Any,
-]
+OcrDocumentTypeEnum = typing.Union[typing.Literal["invoice", "credit_note", "receipt"], typing.Any]
diff --git a/src/monite/types/payable_created_event_data.py b/src/monite/types/payable_created_event_data.py
new file mode 100644
index 0000000..9e2794f
--- /dev/null
+++ b/src/monite/types/payable_created_event_data.py
@@ -0,0 +1,20 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .payable_origin_enum import PayableOriginEnum
+
+
+class PayableCreatedEventData(UniversalBaseModel):
+ payable_source: PayableOriginEnum
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/src/monite/types/payable_credit_note_linked_event_data.py b/src/monite/types/payable_credit_note_linked_event_data.py
new file mode 100644
index 0000000..60e8cb0
--- /dev/null
+++ b/src/monite/types/payable_credit_note_linked_event_data.py
@@ -0,0 +1,20 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+
+
+class PayableCreditNoteLinkedEventData(UniversalBaseModel):
+ credit_note_document_id: typing.Optional[str] = None
+ credit_note_id: str
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/src/monite/types/payable_credit_note_unlinked_event_data.py b/src/monite/types/payable_credit_note_unlinked_event_data.py
new file mode 100644
index 0000000..7eccde7
--- /dev/null
+++ b/src/monite/types/payable_credit_note_unlinked_event_data.py
@@ -0,0 +1,20 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+
+
+class PayableCreditNoteUnlinkedEventData(UniversalBaseModel):
+ credit_note_document_id: typing.Optional[str] = None
+ credit_note_id: str
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/src/monite/types/payable_history_cursor_fields.py b/src/monite/types/payable_history_cursor_fields.py
new file mode 100644
index 0000000..f3d54d4
--- /dev/null
+++ b/src/monite/types/payable_history_cursor_fields.py
@@ -0,0 +1,5 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+PayableHistoryCursorFields = typing.Literal["timestamp"]
diff --git a/src/monite/types/payable_history_event_type_enum.py b/src/monite/types/payable_history_event_type_enum.py
new file mode 100644
index 0000000..c4ff5a3
--- /dev/null
+++ b/src/monite/types/payable_history_event_type_enum.py
@@ -0,0 +1,15 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+PayableHistoryEventTypeEnum = typing.Union[
+ typing.Literal[
+ "status_changed",
+ "payable_created",
+ "payable_updated",
+ "credit_note_linked",
+ "credit_note_unlinked",
+ "file_attached",
+ ],
+ typing.Any,
+]
diff --git a/src/monite/types/payable_history_pagination_response.py b/src/monite/types/payable_history_pagination_response.py
new file mode 100644
index 0000000..4554fc5
--- /dev/null
+++ b/src/monite/types/payable_history_pagination_response.py
@@ -0,0 +1,33 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .payable_history_response import PayableHistoryResponse
+
+
+class PayableHistoryPaginationResponse(UniversalBaseModel):
+ """
+ A paginated list of change history records.
+ """
+
+ data: typing.List[PayableHistoryResponse]
+ next_pagination_token: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ A token that can be sent in the `pagination_token` query parameter to get the next page of results, or `null` if there is no next page (i.e. you've reached the last page).
+ """
+
+ prev_pagination_token: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ A token that can be sent in the `pagination_token` query parameter to get the previous page of results, or `null` if there is no previous page (i.e. you've reached the first page).
+ """
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/src/monite/types/payable_history_response.py b/src/monite/types/payable_history_response.py
new file mode 100644
index 0000000..b1e8de5
--- /dev/null
+++ b/src/monite/types/payable_history_response.py
@@ -0,0 +1,50 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import datetime as dt
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .payable_history_event_type_enum import PayableHistoryEventTypeEnum
+from .payable_history_response_event_data import PayableHistoryResponseEventData
+
+
+class PayableHistoryResponse(UniversalBaseModel):
+ id: str = pydantic.Field()
+ """
+ A unique ID of the history record.
+ """
+
+ entity_user_id: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ ID of the entity user who made the change or trigger the event, or `null` if it was done by using a partner access token.
+ """
+
+ event_data: PayableHistoryResponseEventData = pydantic.Field()
+ """
+ An object containing additional information about the event or change. The object structure varies based on the `event_type`.
+ """
+
+ event_type: PayableHistoryEventTypeEnum = pydantic.Field()
+ """
+ The type of the event or change.
+ """
+
+ payable_id: str = pydantic.Field()
+ """
+ ID of the payable document that was changed or triggered an event.
+ """
+
+ timestamp: dt.datetime = pydantic.Field()
+ """
+ UTC date and time when the event or change occurred.
+ """
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/src/monite/types/payable_history_response_event_data.py b/src/monite/types/payable_history_response_event_data.py
new file mode 100644
index 0000000..6a5d219
--- /dev/null
+++ b/src/monite/types/payable_history_response_event_data.py
@@ -0,0 +1,19 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+from .file_attached_event_data import FileAttachedEventData
+from .payable_created_event_data import PayableCreatedEventData
+from .payable_credit_note_linked_event_data import PayableCreditNoteLinkedEventData
+from .payable_credit_note_unlinked_event_data import PayableCreditNoteUnlinkedEventData
+from .payable_status_changed_event_data import PayableStatusChangedEventData
+from .payable_updated_event_data import PayableUpdatedEventData
+
+PayableHistoryResponseEventData = typing.Union[
+ PayableStatusChangedEventData,
+ PayableUpdatedEventData,
+ PayableCreatedEventData,
+ PayableCreditNoteLinkedEventData,
+ PayableCreditNoteUnlinkedEventData,
+ FileAttachedEventData,
+]
diff --git a/src/monite/types/payable_status_changed_event_data.py b/src/monite/types/payable_status_changed_event_data.py
new file mode 100644
index 0000000..705d0a0
--- /dev/null
+++ b/src/monite/types/payable_status_changed_event_data.py
@@ -0,0 +1,21 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .payable_state_enum import PayableStateEnum
+
+
+class PayableStatusChangedEventData(UniversalBaseModel):
+ new_status: PayableStateEnum
+ old_status: PayableStateEnum
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/src/monite/types/payable_updated_event_data.py b/src/monite/types/payable_updated_event_data.py
new file mode 100644
index 0000000..1ec60da
--- /dev/null
+++ b/src/monite/types/payable_updated_event_data.py
@@ -0,0 +1,17 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+
+
+class PayableUpdatedEventData(UniversalBaseModel):
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/src/monite/types/payment_record_history_response.py b/src/monite/types/payment_record_history_response.py
new file mode 100644
index 0000000..cf3a23b
--- /dev/null
+++ b/src/monite/types/payment_record_history_response.py
@@ -0,0 +1,26 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import datetime as dt
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .payment_record_status_enum import PaymentRecordStatusEnum
+
+
+class PaymentRecordHistoryResponse(UniversalBaseModel):
+ entity_user_id: typing.Optional[str] = None
+ status: PaymentRecordStatusEnum
+ timestamp: dt.datetime = pydantic.Field()
+ """
+ Timestamp of the change in a history
+ """
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/src/monite/types/payment_record_response.py b/src/monite/types/payment_record_response.py
index effbd23..694f0a2 100644
--- a/src/monite/types/payment_record_response.py
+++ b/src/monite/types/payment_record_response.py
@@ -6,6 +6,7 @@
import pydantic
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
from .currency_enum import CurrencyEnum
+from .payment_record_history_response import PaymentRecordHistoryResponse
from .payment_record_object_response import PaymentRecordObjectResponse
@@ -26,6 +27,11 @@ class PaymentRecordResponse(UniversalBaseModel):
ID of the user associated with the payment, if applicable.
"""
+ history: typing.List[PaymentRecordHistoryResponse] = pydantic.Field()
+ """
+ History of the payment record.
+ """
+
is_external: bool
object: PaymentRecordObjectResponse
overpaid_amount: typing.Optional[int] = pydantic.Field(default=None)
diff --git a/src/monite/types/payment_terms.py b/src/monite/types/payment_terms.py
index 9b88b29..1c195e1 100644
--- a/src/monite/types/payment_terms.py
+++ b/src/monite/types/payment_terms.py
@@ -6,28 +6,33 @@
import typing_extensions
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
from ..core.serialization import FieldMetadata
-from .payment_term_discount_with_date import PaymentTermDiscountWithDate
-from .term_final_with_date import TermFinalWithDate
+from .inline_term_discount import InlineTermDiscount
+from .inline_term_final import InlineTermFinal
class PaymentTerms(UniversalBaseModel):
- id: str
+ id: typing.Optional[str] = None
+ description: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Description of the payment term.
+ """
+
name: typing.Optional[str] = None
- term1: typing_extensions.Annotated[typing.Optional[PaymentTermDiscountWithDate], FieldMetadata(alias="term_1")] = (
+ term1: typing_extensions.Annotated[typing.Optional[InlineTermDiscount], FieldMetadata(alias="term_1")] = (
pydantic.Field(default=None)
)
"""
The first tier of the payment term. Represents the terms of the first early discount.
"""
- term2: typing_extensions.Annotated[typing.Optional[PaymentTermDiscountWithDate], FieldMetadata(alias="term_2")] = (
+ term2: typing_extensions.Annotated[typing.Optional[InlineTermDiscount], FieldMetadata(alias="term_2")] = (
pydantic.Field(default=None)
)
"""
The second tier of the payment term. Defines the terms of the second early discount.
"""
- term_final: TermFinalWithDate = pydantic.Field()
+ term_final: InlineTermFinal = pydantic.Field()
"""
The final tier of the payment term. Defines the invoice due date.
"""
diff --git a/src/monite/types/payment_terms_response.py b/src/monite/types/payment_terms_response.py
index 7ce0a4e..c8dea74 100644
--- a/src/monite/types/payment_terms_response.py
+++ b/src/monite/types/payment_terms_response.py
@@ -6,29 +6,29 @@
import typing_extensions
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
from ..core.serialization import FieldMetadata
-from .payment_term import PaymentTerm
-from .payment_term_discount import PaymentTermDiscount
+from .term_discount_days import TermDiscountDays
+from .term_final_days import TermFinalDays
class PaymentTermsResponse(UniversalBaseModel):
id: str
description: typing.Optional[str] = None
name: str
- term1: typing_extensions.Annotated[typing.Optional[PaymentTermDiscount], FieldMetadata(alias="term_1")] = (
+ term1: typing_extensions.Annotated[typing.Optional[TermDiscountDays], FieldMetadata(alias="term_1")] = (
pydantic.Field(default=None)
)
"""
The first tier of the payment term. Represents the terms of the first early discount.
"""
- term2: typing_extensions.Annotated[typing.Optional[PaymentTermDiscount], FieldMetadata(alias="term_2")] = (
+ term2: typing_extensions.Annotated[typing.Optional[TermDiscountDays], FieldMetadata(alias="term_2")] = (
pydantic.Field(default=None)
)
"""
The second tier of the payment term. Defines the terms of the second early discount.
"""
- term_final: PaymentTerm = pydantic.Field()
+ term_final: TermFinalDays = pydantic.Field()
"""
The final tier of the payment term. Defines the invoice due date.
"""
diff --git a/src/monite/types/product_service_response.py b/src/monite/types/product_service_response.py
index cfcb095..c87770e 100644
--- a/src/monite/types/product_service_response.py
+++ b/src/monite/types/product_service_response.py
@@ -32,6 +32,11 @@ class ProductServiceResponse(UniversalBaseModel):
entity_id: str
entity_user_id: typing.Optional[str] = None
+ external_reference: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ A user-defined identifier of the product. For example, an internal product code or SKU (stock keeping unit). Client applications can use this field to map the products in Monite to an external product catalog.
+ """
+
ledger_account_id: typing.Optional[str] = None
measure_unit_id: typing.Optional[str] = pydantic.Field(default=None)
"""
diff --git a/src/monite/types/quote_response_payload.py b/src/monite/types/quote_response_payload.py
index 174f268..e35765e 100644
--- a/src/monite/types/quote_response_payload.py
+++ b/src/monite/types/quote_response_payload.py
@@ -5,13 +5,13 @@
import pydantic
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .counterpart_type import CounterpartType
from .currency_enum import CurrencyEnum
-from .discount import Discount
+from .discount_response import DiscountResponse
from .language_code_enum import LanguageCodeEnum
from .quote_response_payload_entity import QuoteResponsePayloadEntity
from .quote_state_enum import QuoteStateEnum
from .receivable_counterpart_contact import ReceivableCounterpartContact
-from .receivable_counterpart_type import ReceivableCounterpartType
from .receivable_counterpart_vat_id_response import ReceivableCounterpartVatIdResponse
from .receivable_entity_address_schema import ReceivableEntityAddressSchema
from .receivable_entity_vat_id_response import ReceivableEntityVatIdResponse
@@ -99,7 +99,7 @@ class QuoteResponsePayload(UniversalBaseModel):
The VAT/TAX ID of the counterpart.
"""
- counterpart_type: ReceivableCounterpartType = pydantic.Field()
+ counterpart_type: CounterpartType = pydantic.Field()
"""
The type of the counterpart.
"""
@@ -120,7 +120,7 @@ class QuoteResponsePayload(UniversalBaseModel):
A note with additional information about a tax deduction
"""
- discount: typing.Optional[Discount] = pydantic.Field(default=None)
+ discount: typing.Optional[DiscountResponse] = pydantic.Field(default=None)
"""
The discount for a receivable.
"""
diff --git a/src/monite/types/receivable_counterpart_type.py b/src/monite/types/receivable_counterpart_type.py
deleted file mode 100644
index a00bc79..0000000
--- a/src/monite/types/receivable_counterpart_type.py
+++ /dev/null
@@ -1,5 +0,0 @@
-# This file was auto-generated by Fern from our API Definition.
-
-import typing
-
-ReceivableCounterpartType = typing.Union[typing.Literal["individual", "organization"], typing.Any]
diff --git a/src/monite/types/receivable_cursor_fields.py b/src/monite/types/receivable_cursor_fields.py
index 6f32615..4a4e0a8 100644
--- a/src/monite/types/receivable_cursor_fields.py
+++ b/src/monite/types/receivable_cursor_fields.py
@@ -8,6 +8,7 @@
"counterpart_id",
"amount",
"total_amount",
+ "discounted_subtotal",
"status",
"due_date",
"issue_date",
diff --git a/src/monite/types/receivable_cursor_fields2.py b/src/monite/types/receivable_cursor_fields2.py
new file mode 100644
index 0000000..708f4f4
--- /dev/null
+++ b/src/monite/types/receivable_cursor_fields2.py
@@ -0,0 +1,19 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+ReceivableCursorFields2 = typing.Union[
+ typing.Literal[
+ "counterpart_name",
+ "counterpart_id",
+ "amount",
+ "total_amount",
+ "status",
+ "due_date",
+ "issue_date",
+ "document_id",
+ "created_at",
+ "project_id",
+ ],
+ typing.Any,
+]
diff --git a/src/monite/types/receivable_facade_create_invoice_payload.py b/src/monite/types/receivable_facade_create_invoice_payload.py
index 316e56a..63ae028 100644
--- a/src/monite/types/receivable_facade_create_invoice_payload.py
+++ b/src/monite/types/receivable_facade_create_invoice_payload.py
@@ -6,6 +6,7 @@
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
from .currency_enum import CurrencyEnum
from .discount import Discount
+from .inline_payment_terms_request_payload import InlinePaymentTermsRequestPayload
from .line_item import LineItem
from .receivable_entity_base import ReceivableEntityBase
from .vat_mode_enum import VatModeEnum
@@ -113,6 +114,7 @@ class ReceivableFacadeCreateInvoicePayload(UniversalBaseModel):
"""
payment_reminder_id: typing.Optional[str] = None
+ payment_terms: typing.Optional[InlinePaymentTermsRequestPayload] = None
payment_terms_id: typing.Optional[str] = None
project_id: typing.Optional[str] = pydantic.Field(default=None)
"""
diff --git a/src/monite/types/receivable_response.py b/src/monite/types/receivable_response.py
index d97af2a..aa22652 100644
--- a/src/monite/types/receivable_response.py
+++ b/src/monite/types/receivable_response.py
@@ -7,10 +7,11 @@
import pydantic
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .counterpart_type import CounterpartType
from .credit_note_response_payload_entity import CreditNoteResponsePayloadEntity
from .credit_note_state_enum import CreditNoteStateEnum
from .currency_enum import CurrencyEnum
-from .discount import Discount
+from .discount_response import DiscountResponse
from .einvoicing_credentials import EinvoicingCredentials
from .invoice_response_payload_entity import InvoiceResponsePayloadEntity
from .language_code_enum import LanguageCodeEnum
@@ -18,7 +19,6 @@
from .quote_response_payload_entity import QuoteResponsePayloadEntity
from .quote_state_enum import QuoteStateEnum
from .receivable_counterpart_contact import ReceivableCounterpartContact
-from .receivable_counterpart_type import ReceivableCounterpartType
from .receivable_counterpart_vat_id_response import ReceivableCounterpartVatIdResponse
from .receivable_entity_address_schema import ReceivableEntityAddressSchema
from .receivable_entity_vat_id_response import ReceivableEntityVatIdResponse
@@ -49,12 +49,12 @@ class ReceivableResponse_Quote(UniversalBaseModel):
counterpart_name: typing.Optional[str] = None
counterpart_shipping_address: typing.Optional[ReceivablesRepresentationOfCounterpartAddress] = None
counterpart_tax_id: typing.Optional[str] = None
- counterpart_type: ReceivableCounterpartType
+ counterpart_type: CounterpartType
counterpart_vat_id: typing.Optional[ReceivableCounterpartVatIdResponse] = None
currency: CurrencyEnum
deduction_amount: typing.Optional[int] = None
deduction_memo: typing.Optional[str] = None
- discount: typing.Optional[Discount] = None
+ discount: typing.Optional[DiscountResponse] = None
discounted_subtotal: typing.Optional[int] = None
document_id: typing.Optional[str] = None
due_date: typing.Optional[str] = None
@@ -123,12 +123,12 @@ class ReceivableResponse_Invoice(UniversalBaseModel):
counterpart_name: typing.Optional[str] = None
counterpart_shipping_address: typing.Optional[ReceivablesRepresentationOfCounterpartAddress] = None
counterpart_tax_id: typing.Optional[str] = None
- counterpart_type: ReceivableCounterpartType
+ counterpart_type: CounterpartType
counterpart_vat_id: typing.Optional[ReceivableCounterpartVatIdResponse] = None
currency: CurrencyEnum
deduction_amount: typing.Optional[int] = None
deduction_memo: typing.Optional[str] = None
- discount: typing.Optional[Discount] = None
+ discount: typing.Optional[DiscountResponse] = None
discounted_subtotal: typing.Optional[int] = None
document_id: typing.Optional[str] = None
due_date: typing.Optional[str] = None
@@ -203,12 +203,12 @@ class ReceivableResponse_CreditNote(UniversalBaseModel):
counterpart_name: typing.Optional[str] = None
counterpart_shipping_address: typing.Optional[ReceivablesRepresentationOfCounterpartAddress] = None
counterpart_tax_id: typing.Optional[str] = None
- counterpart_type: ReceivableCounterpartType
+ counterpart_type: CounterpartType
counterpart_vat_id: typing.Optional[ReceivableCounterpartVatIdResponse] = None
currency: CurrencyEnum
deduction_amount: typing.Optional[int] = None
deduction_memo: typing.Optional[str] = None
- discount: typing.Optional[Discount] = None
+ discount: typing.Optional[DiscountResponse] = None
discounted_subtotal: typing.Optional[int] = None
document_id: typing.Optional[str] = None
due_date: typing.Optional[str] = None
diff --git a/src/monite/types/receivable_tag_category.py b/src/monite/types/receivable_tag_category.py
deleted file mode 100644
index e388dc4..0000000
--- a/src/monite/types/receivable_tag_category.py
+++ /dev/null
@@ -1,10 +0,0 @@
-# This file was auto-generated by Fern from our API Definition.
-
-import typing
-
-ReceivableTagCategory = typing.Union[
- typing.Literal[
- "document_type", "department", "project", "cost_center", "vendor_type", "payment_method", "approval_status"
- ],
- typing.Any,
-]
diff --git a/src/monite/types/recurrence.py b/src/monite/types/recurrence.py
deleted file mode 100644
index 9ce1592..0000000
--- a/src/monite/types/recurrence.py
+++ /dev/null
@@ -1,59 +0,0 @@
-# This file was auto-generated by Fern from our API Definition.
-
-import datetime as dt
-import typing
-
-import pydantic
-from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
-from .automation_level import AutomationLevel
-from .day_of_month import DayOfMonth
-from .recipients import Recipients
-from .recurrence_iteration import RecurrenceIteration
-from .recurrence_status import RecurrenceStatus
-
-
-class Recurrence(UniversalBaseModel):
- id: str
- created_at: dt.datetime = pydantic.Field()
- """
- Time at which the receivable was created. Timestamps follow the ISO 8601 standard.
- """
-
- updated_at: dt.datetime = pydantic.Field()
- """
- Time at which the receivable was last updated. Timestamps follow the ISO 8601 standard.
- """
-
- automation_level: AutomationLevel = pydantic.Field()
- """
- Controls how invoices are processed when generated:
- - "draft": Creates invoices in draft status, requiring manual review, issuing, and sending
- - "issue": Automatically issues invoices but requires manual sending
- - "issue_and_send": Fully automates the process (creates, issues, and sends invoices)
-
- Default: "issue" (or "issue_and_send" if subject_text and body_text are provided)
-
- Note: When using "issue_and_send", both subject_text and body_text must be provided.
- """
-
- body_text: typing.Optional[str] = None
- current_iteration: int
- day_of_month: DayOfMonth
- end_month: int
- end_year: int
- invoice_id: str
- iterations: typing.List[RecurrenceIteration]
- recipients: typing.Optional[Recipients] = None
- start_month: int
- start_year: int
- status: RecurrenceStatus
- subject_text: typing.Optional[str] = None
-
- if IS_PYDANTIC_V2:
- model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
- else:
-
- class Config:
- frozen = True
- smart_union = True
- extra = pydantic.Extra.allow
diff --git a/src/monite/types/recurrence_frequency.py b/src/monite/types/recurrence_frequency.py
new file mode 100644
index 0000000..c8f4e85
--- /dev/null
+++ b/src/monite/types/recurrence_frequency.py
@@ -0,0 +1,5 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+RecurrenceFrequency = typing.Union[typing.Literal["day", "week", "month", "quarter", "year"], typing.Any]
diff --git a/src/monite/types/recurrence_response.py b/src/monite/types/recurrence_response.py
new file mode 100644
index 0000000..7b76011
--- /dev/null
+++ b/src/monite/types/recurrence_response.py
@@ -0,0 +1,132 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import datetime as dt
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .automation_level import AutomationLevel
+from .day_of_month import DayOfMonth
+from .recipients import Recipients
+from .recurrence_frequency import RecurrenceFrequency
+from .recurrence_iteration import RecurrenceIteration
+from .recurrence_status import RecurrenceStatus
+
+
+class RecurrenceResponse(UniversalBaseModel):
+ id: str
+ created_at: dt.datetime = pydantic.Field()
+ """
+ Time at which the recurrence was created. Timestamps follow the ISO 8601 standard.
+ """
+
+ updated_at: dt.datetime = pydantic.Field()
+ """
+ Time at which the recurrence was last updated. Timestamps follow the ISO 8601 standard.
+ """
+
+ automation_level: AutomationLevel = pydantic.Field()
+ """
+ Controls how invoices are processed when generated:
+ - "draft": Creates invoices in draft status, requiring manual review, issuing, and sending
+ - "issue": Automatically issues invoices but requires manual sending
+ - "issue_and_send": Fully automates the process (creates, issues, and sends invoices)
+
+ Default: "issue" (or "issue_and_send" if subject_text and body_text are provided)
+
+ Note: When using "issue_and_send", both subject_text and body_text must be provided.
+ """
+
+ body_text: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ The body text for the email that will be sent with the recurring invoice.
+ """
+
+ current_iteration: int = pydantic.Field()
+ """
+ Current iteration number
+ """
+
+ day_of_month: DayOfMonth = pydantic.Field()
+ """
+ Deprecated, use `start_date` instead
+ """
+
+ end_date: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ The end date of the recurring invoice, in the `yyyy-mm-dd` format. The end date is inclusive, that is, the last invoice will be created on this date if the last occurrence falls on this date. `end_date` is mutually exclusive with `max_occurrences`. Either `end_date` or `max_occurrences` must be specified.
+ """
+
+ end_month: typing.Optional[int] = pydantic.Field(default=None)
+ """
+ Deprecated, use `end_date` instead
+ """
+
+ end_year: typing.Optional[int] = pydantic.Field(default=None)
+ """
+ Deprecated, use `end_date` instead
+ """
+
+ frequency: RecurrenceFrequency = pydantic.Field()
+ """
+ How often the invoice will be created.
+ """
+
+ interval: int = pydantic.Field()
+ """
+ The interval between each occurrence of the invoice. For example, when using monthly frequency, an interval of 1 means invoices will be created every month, an interval of 2 means invoices will be created every 2 months.
+ """
+
+ invoice_id: str = pydantic.Field()
+ """
+ ID of the base invoice that will be used as a template for creating recurring invoices.
+ """
+
+ iterations: typing.List[RecurrenceIteration] = pydantic.Field()
+ """
+ List of iterations for the recurrence
+ """
+
+ max_occurrences: typing.Optional[int] = pydantic.Field(default=None)
+ """
+ How many times the recurring invoice will be created. The recurrence will stop after this number is reached. `max_occurrences` is mutually exclusive with `end_date`. Either `max_occurrences` or `end_date` must be specified.
+ """
+
+ recipients: typing.Optional[Recipients] = pydantic.Field(default=None)
+ """
+ An object containing the recipients (To, CC, BCC) of the recurring invoices. Can be omitted if the base invoice has the counterpart contact email specified in the `counterpart_contact.email` field.
+ """
+
+ start_date: str = pydantic.Field()
+ """
+ The date when the first invoice will be created, in the `yyyy-mm-dd` format. Cannot be a past date. Subsequent invoice dates will be calculated based on `start_date`, `frequency`, and `interval`.
+ """
+
+ start_month: int = pydantic.Field()
+ """
+ Deprecated, use `start_date` instead
+ """
+
+ start_year: int = pydantic.Field()
+ """
+ Deprecated, use `start_date` instead
+ """
+
+ status: RecurrenceStatus = pydantic.Field()
+ """
+ Status of the recurrence
+ """
+
+ subject_text: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ The subject for the email that will be sent with the recurring invoice.
+ """
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/src/monite/types/recurrence_response_list.py b/src/monite/types/recurrence_response_list.py
new file mode 100644
index 0000000..5478c4f
--- /dev/null
+++ b/src/monite/types/recurrence_response_list.py
@@ -0,0 +1,20 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .recurrence_response import RecurrenceResponse
+
+
+class RecurrenceResponseList(UniversalBaseModel):
+ data: typing.List[RecurrenceResponse]
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/src/monite/types/recurrence_status.py b/src/monite/types/recurrence_status.py
index fb3e909..c02e153 100644
--- a/src/monite/types/recurrence_status.py
+++ b/src/monite/types/recurrence_status.py
@@ -2,4 +2,4 @@
import typing
-RecurrenceStatus = typing.Union[typing.Literal["active", "canceled", "completed"], typing.Any]
+RecurrenceStatus = typing.Union[typing.Literal["active", "paused", "canceled", "completed"], typing.Any]
diff --git a/src/monite/types/tag_read_schema.py b/src/monite/types/tag_read_schema.py
index aaf47cb..2c85caa 100644
--- a/src/monite/types/tag_read_schema.py
+++ b/src/monite/types/tag_read_schema.py
@@ -5,7 +5,7 @@
import pydantic
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
-from .receivable_tag_category import ReceivableTagCategory
+from .tag_category import TagCategory
class TagReadSchema(UniversalBaseModel):
@@ -28,7 +28,7 @@ class TagReadSchema(UniversalBaseModel):
Date and time when the tag was last updated. Timestamps follow the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) standard.
"""
- category: typing.Optional[ReceivableTagCategory] = pydantic.Field(default=None)
+ category: typing.Optional[TagCategory] = pydantic.Field(default=None)
"""
The tag category.
"""
diff --git a/src/monite/types/payment_term_discount.py b/src/monite/types/term_discount_days.py
similarity index 93%
rename from src/monite/types/payment_term_discount.py
rename to src/monite/types/term_discount_days.py
index c2b96e1..219eaac 100644
--- a/src/monite/types/payment_term_discount.py
+++ b/src/monite/types/term_discount_days.py
@@ -6,7 +6,7 @@
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
-class PaymentTermDiscount(UniversalBaseModel):
+class TermDiscountDays(UniversalBaseModel):
discount: int = pydantic.Field()
"""
The discount percentage in minor units. E.g., 200 means 2%. 1050 means 10.5%.
diff --git a/src/monite/types/payment_term.py b/src/monite/types/term_final_days.py
similarity index 93%
rename from src/monite/types/payment_term.py
rename to src/monite/types/term_final_days.py
index c818379..6de65da 100644
--- a/src/monite/types/payment_term.py
+++ b/src/monite/types/term_final_days.py
@@ -6,7 +6,7 @@
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
-class PaymentTerm(UniversalBaseModel):
+class TermFinalDays(UniversalBaseModel):
number_of_days: int = pydantic.Field()
"""
The amount of days after the invoice issue date.
diff --git a/src/monite/types/total_vat_amount_item.py b/src/monite/types/total_vat_amount_item.py
index 1d05532..f408695 100644
--- a/src/monite/types/total_vat_amount_item.py
+++ b/src/monite/types/total_vat_amount_item.py
@@ -4,6 +4,7 @@
import pydantic
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .total_vat_amount_item_component import TotalVatAmountItemComponent
class TotalVatAmountItem(UniversalBaseModel):
@@ -13,6 +14,16 @@ class TotalVatAmountItem(UniversalBaseModel):
The total VAT of all line items, in [minor units](https://docs.monite.com/references/currencies#minor-units).
"""
+ components: typing.Optional[typing.List[TotalVatAmountItemComponent]] = pydantic.Field(default=None)
+ """
+ Sub-taxes included in the VAT.
+ """
+
+ name: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Display name of the vat rate.
+ """
+
taxable_amount: int = pydantic.Field()
"""
The amount on which this VAT is calculated, in [minor units](https://docs.monite.com/references/currencies#minor-units).
diff --git a/src/monite/types/total_vat_amount_item_component.py b/src/monite/types/total_vat_amount_item_component.py
new file mode 100644
index 0000000..c4f5024
--- /dev/null
+++ b/src/monite/types/total_vat_amount_item_component.py
@@ -0,0 +1,28 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+
+
+class TotalVatAmountItemComponent(UniversalBaseModel):
+ name: str
+ value: float = pydantic.Field()
+ """
+ Percent minor units. Example: 12.5% is 1250.
+ """
+
+ amount: int = pydantic.Field()
+ """
+ The total VAT of all line items, in [minor units](https://docs.monite.com/references/currencies#minor-units).
+ """
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/src/monite/types/update_einvoicing_address.py b/src/monite/types/update_einvoicing_address.py
new file mode 100644
index 0000000..8d2b678
--- /dev/null
+++ b/src/monite/types/update_einvoicing_address.py
@@ -0,0 +1,42 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+
+
+class UpdateEinvoicingAddress(UniversalBaseModel):
+ address_line1: str = pydantic.Field()
+ """
+ Street address line 1
+ """
+
+ address_line2: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Street address line 2
+ """
+
+ city: str = pydantic.Field()
+ """
+ City name
+ """
+
+ postal_code: str = pydantic.Field()
+ """
+ Postal/ZIP code
+ """
+
+ state: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ State/Province/County
+ """
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/src/monite/types/update_invoice.py b/src/monite/types/update_invoice.py
index 353cbad..1e588e2 100644
--- a/src/monite/types/update_invoice.py
+++ b/src/monite/types/update_invoice.py
@@ -6,6 +6,7 @@
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
from .currency_enum import CurrencyEnum
from .discount import Discount
+from .inline_payment_terms_request_payload import InlinePaymentTermsRequestPayload
from .line_item_update import LineItemUpdate
from .receivable_entity_base import ReceivableEntityBase
@@ -110,6 +111,7 @@ class UpdateInvoice(UniversalBaseModel):
"""
payment_reminder_id: typing.Optional[str] = None
+ payment_terms: typing.Optional[InlinePaymentTermsRequestPayload] = None
payment_terms_id: typing.Optional[str] = pydantic.Field(default=None)
"""
Unique ID of the payment terms.
diff --git a/src/monite/types/update_issued_invoice.py b/src/monite/types/update_issued_invoice.py
index 4a4a7a2..6d82fc5 100644
--- a/src/monite/types/update_issued_invoice.py
+++ b/src/monite/types/update_issued_invoice.py
@@ -5,6 +5,7 @@
import pydantic
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .inline_payment_terms_request_payload import InlinePaymentTermsRequestPayload
from .receivable_entity_address_schema import ReceivableEntityAddressSchema
from .update_issued_invoice_entity import UpdateIssuedInvoiceEntity
@@ -68,6 +69,7 @@ class UpdateIssuedInvoice(UniversalBaseModel):
"""
payment_reminder_id: typing.Optional[str] = None
+ payment_terms: typing.Optional[InlinePaymentTermsRequestPayload] = None
payment_terms_id: typing.Optional[str] = None
project_id: typing.Optional[str] = pydantic.Field(default=None)
"""
diff --git a/src/monite/types/update_quote.py b/src/monite/types/update_quote.py
index e0552fa..13996b8 100644
--- a/src/monite/types/update_quote.py
+++ b/src/monite/types/update_quote.py
@@ -6,6 +6,7 @@
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
from .currency_enum import CurrencyEnum
from .discount import Discount
+from .inline_payment_terms_request_payload import InlinePaymentTermsRequestPayload
from .line_item_update import LineItemUpdate
from .receivable_entity_base import ReceivableEntityBase
@@ -84,6 +85,7 @@ class UpdateQuote(UniversalBaseModel):
Metadata for partner needs
"""
+ payment_terms: typing.Optional[InlinePaymentTermsRequestPayload] = None
payment_terms_id: typing.Optional[str] = pydantic.Field(default=None)
"""
Unique ID of the payment terms.
diff --git a/src/monite/types/variables_object.py b/src/monite/types/variables_object.py
index d40d359..95e4b2d 100644
--- a/src/monite/types/variables_object.py
+++ b/src/monite/types/variables_object.py
@@ -4,12 +4,12 @@
import pydantic
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
-from .ocr_document_type_enum import OcrDocumentTypeEnum
+from .document_type_enum import DocumentTypeEnum
from .variable import Variable
class VariablesObject(UniversalBaseModel):
- object_subtype: OcrDocumentTypeEnum
+ object_subtype: DocumentTypeEnum
object_type: str
variables: typing.List[Variable]
diff --git a/src/monite/types/vat_rate_component.py b/src/monite/types/vat_rate_component.py
new file mode 100644
index 0000000..0775027
--- /dev/null
+++ b/src/monite/types/vat_rate_component.py
@@ -0,0 +1,27 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+
+
+class VatRateComponent(UniversalBaseModel):
+ name: str = pydantic.Field()
+ """
+ Display name of the Tax.
+ """
+
+ value: float = pydantic.Field()
+ """
+ Percent multiplied by a 100. Example: 12.125% is 1212.5. Will be rounded to 2 decimal places
+ """
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/src/monite/types/vat_rate_response.py b/src/monite/types/vat_rate_response.py
index 6903ebe..94a05a8 100644
--- a/src/monite/types/vat_rate_response.py
+++ b/src/monite/types/vat_rate_response.py
@@ -6,6 +6,7 @@
import pydantic
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
from .allowed_countries import AllowedCountries
+from .vat_rate_component import VatRateComponent
from .vat_rate_creator import VatRateCreator
from .vat_rate_status_enum import VatRateStatusEnum
@@ -26,6 +27,11 @@ class VatRateResponse(UniversalBaseModel):
Date/time when this rate was updated in the table.
"""
+ components: typing.Optional[typing.List[VatRateComponent]] = pydantic.Field(default=None)
+ """
+ Sub-taxes included in the VAT.
+ """
+
country: AllowedCountries = pydantic.Field()
"""
Two-letter ISO country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
diff --git a/src/monite/vat_rates/client.py b/src/monite/vat_rates/client.py
index e2b6154..58d4e56 100644
--- a/src/monite/vat_rates/client.py
+++ b/src/monite/vat_rates/client.py
@@ -58,7 +58,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.vat_rates.get()
"""
_response = self._raw_client.get(
@@ -120,11 +125,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.vat_rates.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
diff --git a/src/monite/webhook_deliveries/client.py b/src/monite/webhook_deliveries/client.py
index a3d4668..ce84607 100644
--- a/src/monite/webhook_deliveries/client.py
+++ b/src/monite/webhook_deliveries/client.py
@@ -91,7 +91,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.webhook_deliveries.get()
"""
_response = self._raw_client.get(
@@ -189,11 +194,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.webhook_deliveries.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
diff --git a/src/monite/webhook_subscriptions/client.py b/src/monite/webhook_subscriptions/client.py
index a9cac31..bcaa707 100644
--- a/src/monite/webhook_subscriptions/client.py
+++ b/src/monite/webhook_subscriptions/client.py
@@ -84,7 +84,12 @@ def get(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
client.webhook_subscriptions.get()
"""
_response = self._raw_client.get(
@@ -129,8 +134,16 @@ def create(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.webhook_subscriptions.create(object_type="account", url='url', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.webhook_subscriptions.create(
+ object_type="account",
+ url="url",
+ )
"""
_response = self._raw_client.create(
object_type=object_type, url=url, event_types=event_types, request_options=request_options
@@ -156,8 +169,15 @@ def get_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.webhook_subscriptions.get_by_id(webhook_subscription_id='webhook_subscription_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.webhook_subscriptions.get_by_id(
+ webhook_subscription_id="webhook_subscription_id",
+ )
"""
_response = self._raw_client.get_by_id(webhook_subscription_id, request_options=request_options)
return _response.data
@@ -180,8 +200,15 @@ def delete_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.webhook_subscriptions.delete_by_id(webhook_subscription_id='webhook_subscription_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.webhook_subscriptions.delete_by_id(
+ webhook_subscription_id="webhook_subscription_id",
+ )
"""
_response = self._raw_client.delete_by_id(webhook_subscription_id, request_options=request_options)
return _response.data
@@ -217,8 +244,15 @@ def update_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.webhook_subscriptions.update_by_id(webhook_subscription_id='webhook_subscription_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.webhook_subscriptions.update_by_id(
+ webhook_subscription_id="webhook_subscription_id",
+ )
"""
_response = self._raw_client.update_by_id(
webhook_subscription_id,
@@ -248,8 +282,15 @@ def disable_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.webhook_subscriptions.disable_by_id(webhook_subscription_id='webhook_subscription_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.webhook_subscriptions.disable_by_id(
+ webhook_subscription_id="webhook_subscription_id",
+ )
"""
_response = self._raw_client.disable_by_id(webhook_subscription_id, request_options=request_options)
return _response.data
@@ -273,8 +314,15 @@ def enable_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.webhook_subscriptions.enable_by_id(webhook_subscription_id='webhook_subscription_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.webhook_subscriptions.enable_by_id(
+ webhook_subscription_id="webhook_subscription_id",
+ )
"""
_response = self._raw_client.enable_by_id(webhook_subscription_id, request_options=request_options)
return _response.data
@@ -298,8 +346,15 @@ def regenerate_secret_by_id(
Examples
--------
from monite import Monite
- client = Monite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
- client.webhook_subscriptions.regenerate_secret_by_id(webhook_subscription_id='webhook_subscription_id', )
+
+ client = Monite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+ client.webhook_subscriptions.regenerate_secret_by_id(
+ webhook_subscription_id="webhook_subscription_id",
+ )
"""
_response = self._raw_client.regenerate_secret_by_id(webhook_subscription_id, request_options=request_options)
return _response.data
@@ -371,11 +426,21 @@ async def get(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
await client.webhook_subscriptions.get()
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get(
@@ -419,11 +484,24 @@ async def create(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.webhook_subscriptions.create(object_type="account", url='url', )
+ await client.webhook_subscriptions.create(
+ object_type="account",
+ url="url",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.create(
@@ -449,11 +527,23 @@ async def get_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.webhook_subscriptions.get_by_id(webhook_subscription_id='webhook_subscription_id', )
+ await client.webhook_subscriptions.get_by_id(
+ webhook_subscription_id="webhook_subscription_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.get_by_id(webhook_subscription_id, request_options=request_options)
@@ -476,11 +566,23 @@ async def delete_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.webhook_subscriptions.delete_by_id(webhook_subscription_id='webhook_subscription_id', )
+ await client.webhook_subscriptions.delete_by_id(
+ webhook_subscription_id="webhook_subscription_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.delete_by_id(webhook_subscription_id, request_options=request_options)
@@ -516,11 +618,23 @@ async def update_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.webhook_subscriptions.update_by_id(webhook_subscription_id='webhook_subscription_id', )
+ await client.webhook_subscriptions.update_by_id(
+ webhook_subscription_id="webhook_subscription_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.update_by_id(
@@ -550,11 +664,23 @@ async def disable_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.webhook_subscriptions.disable_by_id(webhook_subscription_id='webhook_subscription_id', )
+ await client.webhook_subscriptions.disable_by_id(
+ webhook_subscription_id="webhook_subscription_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.disable_by_id(webhook_subscription_id, request_options=request_options)
@@ -578,11 +704,23 @@ async def enable_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.webhook_subscriptions.enable_by_id(webhook_subscription_id='webhook_subscription_id', )
+ await client.webhook_subscriptions.enable_by_id(
+ webhook_subscription_id="webhook_subscription_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.enable_by_id(webhook_subscription_id, request_options=request_options)
@@ -606,11 +744,23 @@ async def regenerate_secret_by_id(
Examples
--------
- from monite import AsyncMonite
import asyncio
- client = AsyncMonite(monite_version="YOUR_MONITE_VERSION", monite_entity_id="YOUR_MONITE_ENTITY_ID", token="YOUR_TOKEN", )
+
+ from monite import AsyncMonite
+
+ client = AsyncMonite(
+ monite_version="YOUR_MONITE_VERSION",
+ monite_entity_id="YOUR_MONITE_ENTITY_ID",
+ token="YOUR_TOKEN",
+ )
+
+
async def main() -> None:
- await client.webhook_subscriptions.regenerate_secret_by_id(webhook_subscription_id='webhook_subscription_id', )
+ await client.webhook_subscriptions.regenerate_secret_by_id(
+ webhook_subscription_id="webhook_subscription_id",
+ )
+
+
asyncio.run(main())
"""
_response = await self._raw_client.regenerate_secret_by_id(