Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions .speakeasy/workflow.lock
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
speakeasyVersion: 1.423.3
speakeasyVersion: 1.423.5
sources:
accounting-source:
sourceNamespace: accounting-source
Expand Down Expand Up @@ -65,8 +65,8 @@ sources:
- main
sync-for-payables-source:
sourceNamespace: sync-for-payables-source
sourceRevisionDigest: sha256:666b91d3454006f19097463c442428b273b95d632e0bc0099b6db10194f7284e
sourceBlobDigest: sha256:1ffa6da669abbf5bb7fef62b991e1c237af95f876b930288b8ab14994e0ab0b5
sourceRevisionDigest: sha256:9b7390685375f6bb8f444cfdaef0cf211fe30a63abac80c98d441203bd76d654
sourceBlobDigest: sha256:f472244dc98845d90f55da060a2cc4acee05c771a89a0ff55bc5db04108e5693
tags:
- latest
- main
Expand Down Expand Up @@ -126,8 +126,8 @@ targets:
sync-for-payables-library:
source: sync-for-payables-source
sourceNamespace: sync-for-payables-source
sourceRevisionDigest: sha256:666b91d3454006f19097463c442428b273b95d632e0bc0099b6db10194f7284e
sourceBlobDigest: sha256:1ffa6da669abbf5bb7fef62b991e1c237af95f876b930288b8ab14994e0ab0b5
sourceRevisionDigest: sha256:9b7390685375f6bb8f444cfdaef0cf211fe30a63abac80c98d441203bd76d654
sourceBlobDigest: sha256:f472244dc98845d90f55da060a2cc4acee05c771a89a0ff55bc5db04108e5693
sync-for-payables-version-1-library:
source: sync-for-payables-version-1-source
sourceNamespace: sync-for-payables-version-1-source
Expand Down
30 changes: 24 additions & 6 deletions sync-for-payables/.speakeasy/gen.lock
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
lockVersion: 2.0.0
id: 0722f07c-657c-4062-93f1-39ee3fe757d0
management:
docChecksum: 16c2aba5060738f14671556b6526c400
docChecksum: c0f4a56a46c488781ea9be7def894f8c
docVersion: 3.0.0
speakeasyVersion: 1.423.3
generationVersion: 2.442.11
releaseVersion: 6.0.0
configChecksum: 969122e26723670a0043a6789d53d844
speakeasyVersion: 1.423.5
generationVersion: 2.445.1
releaseVersion: 7.0.0
configChecksum: cac49a7fdde1648960a7e91570796611
repoURL: https://github.com/codatio/client-sdk-python.git
repoSubDirectory: sync-for-payables
installationURL: https://github.com/codatio/client-sdk-python.git#subdirectory=sync-for-payables
Expand All @@ -15,7 +15,7 @@ features:
python:
additionalDependencies: 1.0.0
constsAndDefaults: 1.0.4
core: 5.6.0
core: 5.6.1
decimal: 1.0.0
defaultEnabledRetries: 0.2.0
deprecations: 3.0.0
Expand Down Expand Up @@ -680,6 +680,15 @@ examples:
responses:
"400":
application/json: {"statusCode": 400, "service": "PublicApi", "error": "Error processing request - not valid.", "correlationId": "bc997528a9d7abb9161ef45f05d38599", "canBeRetried": "Unknown", "detailedErrorCode": 0}
Attachment metadata:
parameters:
path:
companyId: "8a210b68-6988-11ed-a1eb-0242ac120002"
connectionId: "2e9d2c44-f675-40ba-8049-353bfcb5e171"
billId: "EILBDVJVNUAGVKRQ"
responses:
"201":
application/json: {"id": "422f093f-e556-4bf3-91c0-93af70c3e850", "name": "receipt.png", "contentType": "image/png", "dateCreated": "2022-10-23T00:00:00.000Z", "fileSize": 100, "includeWhenSent": true, "sourceModifiedDate": "2022-05-26T10:34:10Z"}
list-bill-attachments:
Info:
parameters:
Expand All @@ -699,6 +708,15 @@ examples:
responses:
"401":
application/json: {"statusCode": 401, "service": "PublicApi", "error": "Unauthorized", "correlationId": "7eb40d6b415d7bcd99ce658268284056", "canBeRetried": "Unknown", "detailedErrorCode": 0}
Attachments:
parameters:
path:
companyId: "8a210b68-6988-11ed-a1eb-0242ac120002"
connectionId: "2e9d2c44-f675-40ba-8049-353bfcb5e171"
billId: "EILBDVJVNUAGVKRQ"
responses:
"200":
application/json: [{"id": "422f093f-e556-4bf3-91c0-93af70c3e850", "name": "receipt.png", "contentType": "image/png", "dateCreated": "2022-10-23T00:00:00.000Z", "fileSize": 100, "includeWhenSent": true, "sourceModifiedDate": "2022-05-26T10:34:10Z"}, {"id": "20cfd269-2f0f-44ef-a28c-7b5f725cf1aa", "name": "another_receipt.png", "contentType": "image/png", "dateCreated": "2022-10-24T00:00:00.000Z", "fileSize": 98, "includeWhenSent": true, "sourceModifiedDate": "2022-05-27T12:38:10Z"}]
download-bill-attachment:
Unauthorized:
parameters:
Expand Down
2 changes: 1 addition & 1 deletion sync-for-payables/.speakeasy/gen.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ generation:
auth:
oAuth2ClientCredentialsEnabled: false
python:
version: 6.0.0
version: 7.0.0
additionalDependencies:
dev: {}
main: {}
Expand Down
6 changes: 4 additions & 2 deletions sync-for-payables/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -218,13 +218,15 @@ s = CodatSyncPayables(
),
)

s.bills.upload_attachment(request={
res = s.bills.upload_attachment(request={
"company_id": "8a210b68-6988-11ed-a1eb-0242ac120002",
"connection_id": "2e9d2c44-f675-40ba-8049-353bfcb5e171",
"bill_id": "EILBDVJVNUAGVKRQ",
})

# Use the SDK ...
if res is not None:
# handle response
pass

```
<!-- End File uploads [file-upload] -->
Expand Down
12 changes: 11 additions & 1 deletion sync-for-payables/RELEASES.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,4 +28,14 @@ Based on:
### Generated
- [python v6.0.0] sync-for-payables
### Releases
- [PyPI v6.0.0] https://pypi.org/project/codat-sync-for-payables/6.0.0 - sync-for-payables
- [PyPI v6.0.0] https://pypi.org/project/codat-sync-for-payables/6.0.0 - sync-for-payables

## 2024-10-31 13:31:23
### Changes
Based on:
- OpenAPI Doc
- Speakeasy CLI 1.423.5 (2.445.1) https://github.com/speakeasy-api/speakeasy
### Generated
- [python v7.0.0] sync-for-payables
### Releases
- [PyPI v7.0.0] https://pypi.org/project/codat-sync-for-payables/7.0.0 - sync-for-payables
12 changes: 9 additions & 3 deletions sync-for-payables/docs/sdks/bills/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -235,13 +235,15 @@ s = CodatSyncPayables(
),
)

s.bills.upload_attachment(request={
res = s.bills.upload_attachment(request={
"company_id": "8a210b68-6988-11ed-a1eb-0242ac120002",
"connection_id": "2e9d2c44-f675-40ba-8049-353bfcb5e171",
"bill_id": "EILBDVJVNUAGVKRQ",
})

# Use the SDK ...
if res is not None:
# handle response
pass

```

Expand All @@ -252,6 +254,10 @@ s.bills.upload_attachment(request={
| `request` | [operations.UploadBillAttachmentRequest](../../models/operations/uploadbillattachmentrequest.md) | :heavy_check_mark: | The request object to use for the request. |
| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. |

### Response

**[shared.Attachment](../../models/shared/attachment.md)**

### Errors

| Error Type | Status Code | Content Type |
Expand Down Expand Up @@ -298,7 +304,7 @@ if res is not None:

### Response

**[shared.Attachment](../../models/shared/attachment.md)**
**[List[shared.Attachment]](../../models/.md)**

### Errors

Expand Down
2 changes: 1 addition & 1 deletion sync-for-payables/poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions sync-for-payables/pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "codat-sync-for-payables"
version = "6.0.0"
version = "7.0.0"
description = "Streamline your customers' accounts payable workflow."
authors = ["Speakeasy",]
readme = "README-PYPI.md"
Expand All @@ -21,7 +21,7 @@ python = "^3.8"
eval-type-backport = "^0.2.0"
httpx = "^0.27.0"
jsonpath-python = "^1.0.6"
pydantic = "~2.9.0"
pydantic = "~2.9.2"
python-dateutil = "2.8.2"
typing-inspect = "^0.9.0"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import importlib.metadata

__title__: str = "codat-sync-for-payables"
__version__: str = "6.0.0"
__version__: str = "7.0.0"

try:
if __package__ is not None:
Expand Down
26 changes: 13 additions & 13 deletions sync-for-payables/src/codat_sync_for_payables/bills.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
from codat_sync_for_payables.models import errors, operations, shared
from codat_sync_for_payables.types import BaseModel, OptionalNullable, UNSET
import httpx
from typing import Any, Optional, Union, cast
from typing import Any, List, Optional, Union, cast


class Bills(BaseSDK):
Expand Down Expand Up @@ -692,7 +692,7 @@ def upload_attachment(
retries: OptionalNullable[utils.RetryConfig] = UNSET,
server_url: Optional[str] = None,
timeout_ms: Optional[int] = None,
):
) -> shared.Attachment:
r"""Upload bill attachment

The *Upload bill attachment* endpoint uploads an attachment and assigns it against a specific `billId`.
Expand Down Expand Up @@ -773,8 +773,8 @@ def upload_attachment(
)

data: Any = None
if utils.match_response(http_res, "201", "*"):
return
if utils.match_response(http_res, "201", "application/json"):
return utils.unmarshal_json(http_res.text, shared.Attachment)
if utils.match_response(
http_res,
["400", "401", "402", "403", "404", "429", "500", "503"],
Expand Down Expand Up @@ -807,7 +807,7 @@ async def upload_attachment_async(
retries: OptionalNullable[utils.RetryConfig] = UNSET,
server_url: Optional[str] = None,
timeout_ms: Optional[int] = None,
):
) -> shared.Attachment:
r"""Upload bill attachment

The *Upload bill attachment* endpoint uploads an attachment and assigns it against a specific `billId`.
Expand Down Expand Up @@ -888,8 +888,8 @@ async def upload_attachment_async(
)

data: Any = None
if utils.match_response(http_res, "201", "*"):
return
if utils.match_response(http_res, "201", "application/json"):
return utils.unmarshal_json(http_res.text, shared.Attachment)
if utils.match_response(
http_res,
["400", "401", "402", "403", "404", "429", "500", "503"],
Expand Down Expand Up @@ -922,7 +922,7 @@ def list_attachments(
retries: OptionalNullable[utils.RetryConfig] = UNSET,
server_url: Optional[str] = None,
timeout_ms: Optional[int] = None,
) -> shared.Attachment:
) -> List[shared.Attachment]:
r"""List bill attachments

The *List bill attachments* endpoint returns a list of attachments available to download for a given `billId`.
Expand All @@ -948,7 +948,7 @@ def list_attachments(

req = self.build_request(
method="GET",
path="/companies/{companyId}/connections/{connectionId}/bills/{billId}/attachments",
path="/companies/{companyId}/connections/{connectionId}/payables/bills/{billId}/attachments",
base_url=base_url,
url_variables=url_variables,
request=request,
Expand Down Expand Up @@ -997,7 +997,7 @@ def list_attachments(

data: Any = None
if utils.match_response(http_res, "200", "application/json"):
return utils.unmarshal_json(http_res.text, shared.Attachment)
return utils.unmarshal_json(http_res.text, List[shared.Attachment])
if utils.match_response(
http_res,
["401", "402", "403", "404", "409", "429", "500", "503"],
Expand Down Expand Up @@ -1030,7 +1030,7 @@ async def list_attachments_async(
retries: OptionalNullable[utils.RetryConfig] = UNSET,
server_url: Optional[str] = None,
timeout_ms: Optional[int] = None,
) -> shared.Attachment:
) -> List[shared.Attachment]:
r"""List bill attachments

The *List bill attachments* endpoint returns a list of attachments available to download for a given `billId`.
Expand All @@ -1056,7 +1056,7 @@ async def list_attachments_async(

req = self.build_request_async(
method="GET",
path="/companies/{companyId}/connections/{connectionId}/bills/{billId}/attachments",
path="/companies/{companyId}/connections/{connectionId}/payables/bills/{billId}/attachments",
base_url=base_url,
url_variables=url_variables,
request=request,
Expand Down Expand Up @@ -1105,7 +1105,7 @@ async def list_attachments_async(

data: Any = None
if utils.match_response(http_res, "200", "application/json"):
return utils.unmarshal_json(http_res.text, shared.Attachment)
return utils.unmarshal_json(http_res.text, List[shared.Attachment])
if utils.match_response(
http_res,
["401", "402", "403", "404", "409", "429", "500", "503"],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,9 @@ class SDKConfiguration:
server_idx: Optional[int] = 0
language: str = "python"
openapi_doc_version: str = "3.0.0"
sdk_version: str = "6.0.0"
gen_version: str = "2.442.11"
user_agent: str = (
"speakeasy-sdk/python 6.0.0 2.442.11 3.0.0 codat-sync-for-payables"
)
sdk_version: str = "7.0.0"
gen_version: str = "2.445.1"
user_agent: str = "speakeasy-sdk/python 7.0.0 2.445.1 3.0.0 codat-sync-for-payables"
retry_config: OptionalNullable[RetryConfig] = Field(default_factory=lambda: UNSET)
timeout_ms: Optional[int] = None

Expand Down