Skip to content

Commit

Permalink
Merge pull request #479 from codatio/speakeasy-sdk-regen-1701853426
Browse files Browse the repository at this point in the history
chore: 🐝 Update SDK - Generate Accounting library
  • Loading branch information
dcoplowe authored Dec 6, 2023
2 parents b073e89 + 8ae7c15 commit 952afb5
Show file tree
Hide file tree
Showing 17 changed files with 100 additions and 84 deletions.
12 changes: 11 additions & 1 deletion previous-versions/accounting/RELEASES.md
Original file line number Diff line number Diff line change
Expand Up @@ -390,4 +390,14 @@ Based on:
### Generated
- [go v0.28.0] previous-versions/accounting
### Releases
- [Go v0.28.0] https://github.com/codatio/client-sdk-go/releases/tag/previous-versions/accounting/v0.28.0 - previous-versions/accounting
- [Go v0.28.0] https://github.com/codatio/client-sdk-go/releases/tag/previous-versions/accounting/v0.28.0 - previous-versions/accounting

## 2023-12-06 09:03:43
### Changes
Based on:
- OpenAPI Doc 3.0.0 https://raw.githubusercontent.com/codatio/oas/main/yaml/Codat-Accounting.yaml
- Speakeasy CLI 1.125.2 (2.210.6) https://github.com/speakeasy-api/speakeasy
### Generated
- [go v0.29.0] previous-versions/accounting
### Releases
- [Go v0.29.0] https://github.com/codatio/client-sdk-go/releases/tag/previous-versions/accounting/v0.29.0 - previous-versions/accounting
2 changes: 1 addition & 1 deletion previous-versions/accounting/bills.go
Original file line number Diff line number Diff line change
Expand Up @@ -1279,7 +1279,7 @@ func (s *Bills) UploadAttachment(ctx context.Context, request operations.UploadB
return nil, fmt.Errorf("error generating URL: %w", err)
}

bodyReader, reqContentType, err := utils.SerializeRequestBody(ctx, request, false, true, "RequestBody", "multipart", `multipartForm:"file" request:"mediaType=multipart/form-data"`)
bodyReader, reqContentType, err := utils.SerializeRequestBody(ctx, request, false, true, "AttachmentUpload", "multipart", `request:"mediaType=multipart/form-data"`)
if err != nil {
return nil, fmt.Errorf("error serializing request body: %w", err)
}
Expand Down
6 changes: 3 additions & 3 deletions previous-versions/accounting/codataccounting.go
Original file line number Diff line number Diff line change
Expand Up @@ -199,9 +199,9 @@ func New(opts ...SDKOption) *CodatAccounting {
sdkConfiguration: sdkConfiguration{
Language: "go",
OpenAPIDocVersion: "3.0.0",
SDKVersion: "0.28.0",
GenVersion: "2.210.3",
UserAgent: "speakeasy-sdk/go 0.28.0 2.210.3 3.0.0 github.com/codatio/client-sdk-go/previous-versions/accounting",
SDKVersion: "0.29.0",
GenVersion: "2.210.6",
UserAgent: "speakeasy-sdk/go 0.29.0 2.210.6 3.0.0 github.com/codatio/client-sdk-go/previous-versions/accounting",
},
}
for _, opt := range opts {
Expand Down
2 changes: 1 addition & 1 deletion previous-versions/accounting/directcosts.go
Original file line number Diff line number Diff line change
Expand Up @@ -981,7 +981,7 @@ func (s *DirectCosts) UploadAttachment(ctx context.Context, request operations.U
return nil, fmt.Errorf("error generating URL: %w", err)
}

bodyReader, reqContentType, err := utils.SerializeRequestBody(ctx, request, false, true, "RequestBody", "multipart", `multipartForm:"file" request:"mediaType=multipart/form-data"`)
bodyReader, reqContentType, err := utils.SerializeRequestBody(ctx, request, false, true, "AttachmentUpload", "multipart", `request:"mediaType=multipart/form-data"`)
if err != nil {
return nil, fmt.Errorf("error serializing request body: %w", err)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@

## Fields

| Field | Type | Required | Description | Example |
| ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- |
| `RequestBody` | [*operations.UploadBillAttachmentRequestBody](../../../pkg/models/operations/uploadbillattachmentrequestbody.md) | :heavy_minus_sign: | N/A | |
| `BillID` | *string* | :heavy_check_mark: | Unique identifier for a bill. | 13d946f0-c5d5-42bc-b092-97ece17923ab |
| `CompanyID` | *string* | :heavy_check_mark: | Unique identifier for a company. | 8a210b68-6988-11ed-a1eb-0242ac120002 |
| `ConnectionID` | *string* | :heavy_check_mark: | Unique identifier for a connection. | 2e9d2c44-f675-40ba-8049-353bfcb5e171 |
| Field | Type | Required | Description | Example |
| -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- |
| `AttachmentUpload` | [*shared.AttachmentUpload](../../../pkg/models/shared/attachmentupload.md) | :heavy_minus_sign: | N/A | |
| `BillID` | *string* | :heavy_check_mark: | Unique identifier for a bill. | 13d946f0-c5d5-42bc-b092-97ece17923ab |
| `CompanyID` | *string* | :heavy_check_mark: | Unique identifier for a company. | 8a210b68-6988-11ed-a1eb-0242ac120002 |
| `ConnectionID` | *string* | :heavy_check_mark: | Unique identifier for a connection. | 2e9d2c44-f675-40ba-8049-353bfcb5e171 |
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@

## Fields

| Field | Type | Required | Description | Example |
| ---------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------- |
| `RequestBody` | [*operations.UploadDirectCostAttachmentRequestBody](../../../pkg/models/operations/uploaddirectcostattachmentrequestbody.md) | :heavy_minus_sign: | N/A | |
| `CompanyID` | *string* | :heavy_check_mark: | Unique identifier for a company. | 8a210b68-6988-11ed-a1eb-0242ac120002 |
| `ConnectionID` | *string* | :heavy_check_mark: | Unique identifier for a connection. | 2e9d2c44-f675-40ba-8049-353bfcb5e171 |
| `DirectCostID` | *string* | :heavy_check_mark: | Unique identifier for a direct cost. | |
| Field | Type | Required | Description | Example |
| -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- |
| `AttachmentUpload` | [*shared.AttachmentUpload](../../../pkg/models/shared/attachmentupload.md) | :heavy_minus_sign: | N/A | |
| `CompanyID` | *string* | :heavy_check_mark: | Unique identifier for a company. | 8a210b68-6988-11ed-a1eb-0242ac120002 |
| `ConnectionID` | *string* | :heavy_check_mark: | Unique identifier for a connection. | 2e9d2c44-f675-40ba-8049-353bfcb5e171 |
| `DirectCostID` | *string* | :heavy_check_mark: | Unique identifier for a direct cost. | |

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# AttachmentUpload


## Fields

| Field | Type | Required | Description |
| ----------------------------------------------------------- | ----------------------------------------------------------- | ----------------------------------------------------------- | ----------------------------------------------------------- |
| `File` | [shared.CodatFile](../../../pkg/models/shared/codatfile.md) | :heavy_check_mark: | The file to be uploaded as an attachment. |
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# UploadBillAttachmentRequestBody
# CodatFile


## Fields
Expand Down
8 changes: 5 additions & 3 deletions previous-versions/accounting/docs/sdks/bills/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -803,9 +803,11 @@ func main() {

ctx := context.Background()
res, err := s.Bills.UploadAttachment(ctx, operations.UploadBillAttachmentRequest{
RequestBody: &operations.UploadBillAttachmentRequestBody{
Content: []byte("0xE3ABc1980E"),
FileName: "elegant_producer_electric.jpeg",
AttachmentUpload: &shared.AttachmentUpload{
File: shared.CodatFile{
Content: []byte("0xE3ABc1980E"),
FileName: "elegant_producer_electric.jpeg",
},
},
BillID: "9wg4lep4ush5cxs79pl8sozmsndbaukll3ind4g7buqbm1h2",
CompanyID: "8a210b68-6988-11ed-a1eb-0242ac120002",
Expand Down
8 changes: 5 additions & 3 deletions previous-versions/accounting/docs/sdks/directcosts/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -556,9 +556,11 @@ func main() {

ctx := context.Background()
res, err := s.DirectCosts.UploadAttachment(ctx, operations.UploadDirectCostAttachmentRequest{
RequestBody: &operations.UploadDirectCostAttachmentRequestBody{
Content: []byte("0xE3ABc1980E"),
FileName: "elegant_producer_electric.jpeg",
AttachmentUpload: &shared.AttachmentUpload{
File: shared.CodatFile{
Content: []byte("0xE3ABc1980E"),
FileName: "elegant_producer_electric.jpeg",
},
},
CompanyID: "8a210b68-6988-11ed-a1eb-0242ac120002",
ConnectionID: "2e9d2c44-f675-40ba-8049-353bfcb5e171",
Expand Down
6 changes: 4 additions & 2 deletions previous-versions/accounting/files.gen
Original file line number Diff line number Diff line change
Expand Up @@ -230,6 +230,8 @@ pkg/utils/utils.go
/pkg/models/shared/bills.go
/pkg/models/shared/attachmentsdataset.go
/pkg/models/shared/updatebillresponse.go
/pkg/models/shared/attachmentupload.go
/pkg/models/shared/codatfile.go
/pkg/models/shared/createcustomerresponse.go
/pkg/models/shared/customer.go
/pkg/models/shared/customerstatus.go
Expand Down Expand Up @@ -407,7 +409,6 @@ docs/pkg/models/operations/listbillattachmentsrequest.md
docs/pkg/models/operations/listbillattachmentsresponse.md
docs/pkg/models/operations/updatebillrequest.md
docs/pkg/models/operations/updatebillresponse.md
docs/pkg/models/operations/uploadbillattachmentrequestbody.md
docs/pkg/models/operations/uploadbillattachmentrequest.md
docs/pkg/models/operations/uploadbillattachmentresponse.md
docs/pkg/models/operations/createcustomerrequest.md
Expand Down Expand Up @@ -440,7 +441,6 @@ docs/pkg/models/operations/listdirectcostsrequest.md
docs/pkg/models/operations/listdirectcostsresponse.md
docs/pkg/models/operations/listdirectcostattachmentsrequest.md
docs/pkg/models/operations/listdirectcostattachmentsresponse.md
docs/pkg/models/operations/uploaddirectcostattachmentrequestbody.md
docs/pkg/models/operations/uploaddirectcostattachmentrequest.md
docs/pkg/models/operations/uploaddirectcostattachmentresponse.md
docs/pkg/models/operations/createdirectincomerequest.md
Expand Down Expand Up @@ -701,6 +701,8 @@ docs/pkg/models/shared/attachment.md
docs/pkg/models/shared/bills.md
docs/pkg/models/shared/attachmentsdataset.md
docs/pkg/models/shared/updatebillresponse.md
docs/pkg/models/shared/attachmentupload.md
docs/pkg/models/shared/codatfile.md
docs/pkg/models/shared/createcustomerresponse.md
docs/pkg/models/shared/customer.md
docs/pkg/models/shared/customerstatus.md
Expand Down
8 changes: 4 additions & 4 deletions previous-versions/accounting/gen.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
configVersion: 1.0.0
management:
docChecksum: 1643e696b57c43c25f8da2810bbbeae4
docChecksum: 643eb8e5abb697d514899964068b369b
docVersion: 3.0.0
speakeasyVersion: 1.125.1
generationVersion: 2.210.3
speakeasyVersion: 1.125.2
generationVersion: 2.210.6
generation:
comments: {}
sdkClassName: CodatAccounting
Expand All @@ -24,7 +24,7 @@ features:
nameOverrides: 2.81.1
retries: 2.82.1
go:
version: 0.28.0
version: 0.29.0
clientServerStatusCodesAsErrors: true
flattenGlobalSecurity: false
imports:
Expand Down
Loading

0 comments on commit 952afb5

Please sign in to comment.