diff --git a/.speakeasy/workflow.lock b/.speakeasy/workflow.lock index 280a29b44..07960800e 100644 --- a/.speakeasy/workflow.lock +++ b/.speakeasy/workflow.lock @@ -1,4 +1,4 @@ -speakeasyVersion: 1.396.9 +speakeasyVersion: 1.405.9 sources: accounting-source: sourceNamespace: accounting-source @@ -93,8 +93,8 @@ sources: - main sync-for-payables-source: sourceNamespace: sync-for-payables-source - sourceRevisionDigest: sha256:c089e0d3003774c49fbe6d87c1feb141ae3ec0f0f526375b408027808af3d8b9 - sourceBlobDigest: sha256:6ed96ad8ecab289621839d0df446a473e3dc8ea83765e3316020a6670b44da0b + sourceRevisionDigest: sha256:e7ae43ebd42c02cb47c75d20ca011455eb6e1c64b68c5830bd1d4536744bda40 + sourceBlobDigest: sha256:b2999b2b9b935bfc647fe90125f27429ceca251baba134fe2e1b28ee05204eb6 tags: - latest - main @@ -181,8 +181,8 @@ targets: sync-for-payables-library: source: sync-for-payables-source sourceNamespace: sync-for-payables-source - sourceRevisionDigest: sha256:c089e0d3003774c49fbe6d87c1feb141ae3ec0f0f526375b408027808af3d8b9 - sourceBlobDigest: sha256:6ed96ad8ecab289621839d0df446a473e3dc8ea83765e3316020a6670b44da0b + sourceRevisionDigest: sha256:e7ae43ebd42c02cb47c75d20ca011455eb6e1c64b68c5830bd1d4536744bda40 + sourceBlobDigest: sha256:b2999b2b9b935bfc647fe90125f27429ceca251baba134fe2e1b28ee05204eb6 sync-for-payables-version-1-library: source: sync-for-payables-version-1-source sourceNamespace: sync-for-payables-version-1-source diff --git a/sync-for-payables/.speakeasy/gen.lock b/sync-for-payables/.speakeasy/gen.lock index d84a229fe..ec05c9b96 100644 --- a/sync-for-payables/.speakeasy/gen.lock +++ b/sync-for-payables/.speakeasy/gen.lock @@ -1,12 +1,12 @@ lockVersion: 2.0.0 id: 402c5670-2c12-44b7-81b8-9ee7a4664285 management: - docChecksum: 8f7c309d737e74dd8e124f6da34b399c + docChecksum: a559a506ab0305a8733b93fc4eb7d3e4 docVersion: 3.0.0 - speakeasyVersion: 1.396.9 - generationVersion: 2.415.7 - releaseVersion: 1.0.0 - configChecksum: 1ba344ade1365ee05466a257f1b9f8fe + speakeasyVersion: 1.405.9 + generationVersion: 2.429.0 + releaseVersion: 2.0.0 + configChecksum: f3f9e31c78ff6ce8ef3df9429978e4be repoURL: https://github.com/codatio/client-sdk-go.git repoSubDirectory: sync-for-payables installationURL: https://github.com/codatio/client-sdk-go/sync-for-payables @@ -14,7 +14,7 @@ features: go: additionalDependencies: 0.1.0 constsAndDefaults: 0.1.6 - core: 3.5.8 + core: 3.5.12 decimal: 0.1.0 defaultEnabledRetries: 0.2.0 deprecations: 2.81.1 @@ -100,7 +100,6 @@ generatedFiles: - /pkg/models/shared/halref.go - /pkg/models/shared/httpmetadata.go - /pkg/models/shared/links.go - - /pkg/models/shared/one.go - /pkg/models/shared/pagination.go - /pkg/models/shared/paymentmappingoptions.go - /pkg/models/shared/security.go @@ -109,6 +108,7 @@ generatedFiles: - /pkg/models/shared/supplierref.go - /pkg/models/shared/suppliers.go - /pkg/models/shared/supplierstatus.go + - /pkg/models/shared/tags.go - /pkg/models/shared/taxratemappingoption.go - /pkg/models/webhooks/clientratelimitreached.go - /pkg/models/webhooks/clientratelimitreset.go @@ -202,6 +202,7 @@ generatedFiles: - docs/pkg/models/shared/company.md - docs/pkg/models/shared/companyinformation.md - docs/pkg/models/shared/companyrequestbody.md + - docs/pkg/models/shared/companytags.md - docs/pkg/models/shared/connection.md - docs/pkg/models/shared/connections.md - docs/pkg/models/shared/dataconnectionerror.md @@ -209,11 +210,9 @@ generatedFiles: - docs/pkg/models/shared/errorstatus.md - docs/pkg/models/shared/errorvalidation.md - docs/pkg/models/shared/errorvalidationitem.md - - docs/pkg/models/shared/groupreference.md - docs/pkg/models/shared/halref.md - docs/pkg/models/shared/httpmetadata.md - docs/pkg/models/shared/links.md - - docs/pkg/models/shared/one.md - docs/pkg/models/shared/pagination.md - docs/pkg/models/shared/paymentmappingoptions.md - docs/pkg/models/shared/security.md @@ -281,7 +280,7 @@ examples: orderBy: "-modifiedDate" responses: "200": - application/json: {"results": [{"id": "3fa85f64-5717-4562-b3fc-2c963f66afa6", "name": "My Test Company", "description": "My Test Company make testing software", "redirect": "https://link.codat.io/company/3fa85f64-5717-4562-b3fc-2c963f66afa6", "lastSync": "2022-01-01T12:30:00.000Z", "created": "2022-01-01T11:30:00Z", "createdByUserName": "Mike Smith", "dataConnections": [{"id": "51baa045-4836-4317-a42e-3542e991e581", "integrationId": "1c312d69-e638-46d4-ad31-72e6c3ba8390", "integrationKey": "vjms", "sourceId": "396c3158-5dd7-481b-a7c4-a795ca31792b", "sourceType": "Accounting", "platformName": "Pandle", "linkUrl": "https://link-api.codat.io/companies/3fa85f64-5717-4562-b3fc-2c963f66afa6/connections/51baa045-4836-4317-a42e-3542e991e581/start", "status": "Linked", "lastSync": "2022-01-01T12:30:00.000Z", "created": "2022-01-01T11:30:00Z", "dataConnectionErrors": []}]}], "pageNumber": 1, "pageSize": 100, "totalResults": 1, "_links": {"self": {"href": "/companies"}, "current": {"href": "/companies?page=1&pageSize=100"}}} + application/json: {"results": [{"id": "3fa85f64-5717-4562-b3fc-2c963f66afa6", "name": "My Test Company", "description": "My Test Company make testing software", "redirect": "https://link.codat.io/company/3fa85f64-5717-4562-b3fc-2c963f66afa6", "lastSync": "2022-01-01T12:30:00.000Z", "created": "2022-01-01T11:30:00Z", "createdByUserName": "Mike Smith", "dataConnections": [{"id": "51baa045-4836-4317-a42e-3542e991e581", "integrationId": "1c312d69-e638-46d4-ad31-72e6c3ba8390", "integrationKey": "vjms", "sourceId": "396c3158-5dd7-481b-a7c4-a795ca31792b", "sourceType": "Accounting", "platformName": "Pandle", "linkUrl": "https://link-api.codat.io/companies/3fa85f64-5717-4562-b3fc-2c963f66afa6/connections/51baa045-4836-4317-a42e-3542e991e581/start", "status": "Linked", "lastSync": "2022-01-01T12:30:00.000Z", "created": "2022-01-01T11:30:00Z", "dataConnectionErrors": [{"erroredOnUtc": "2022-10-23T00:00:00Z", "resolvedOnUtc": "2022-10-23T00:00:00Z"}, {"erroredOnUtc": "2022-10-23T00:00:00Z", "resolvedOnUtc": "2022-10-23T00:00:00Z"}, {"erroredOnUtc": "2022-10-23T00:00:00Z", "resolvedOnUtc": "2022-10-23T00:00:00Z"}]}]}], "pageNumber": 1, "pageSize": 100, "totalResults": 1, "_links": {"self": {"href": "/companies"}, "current": {"href": "/companies?page=1&pageSize=100"}}} List of Companies: parameters: query: @@ -291,7 +290,7 @@ examples: orderBy: "-modifiedDate" responses: "200": - application/json: {"results": [{"id": "d1568dde-adf6-11ed-afa1-0242ac120002", "name": "Technicalium", "description": "Technology services, including web and app design and development", "redirect": "https://link.codat.io/company/d1568dde-adf6-11ed-afa1-0242ac120002", "lastSync": "2022-01-01T12:30:00.000Z", "created": "2022-01-01T11:30:00Z", "createdByUserName": "Joe Bloggs", "dataConnections": [{"id": "51baa045-4836-4317-a42e-3542e991e581", "integrationId": "1c312d69-e638-46d4-ad31-72e6c3ba8390", "integrationKey": "vjms", "sourceId": "396c3158-5dd7-481b-a7c4-a795ca31792b", "sourceType": "Accounting", "platformName": "Pandle", "linkUrl": "https://link-api.codat.io/companies/d1568dde-adf6-11ed-afa1-0242ac120002/connections/51baa045-4836-4317-a42e-3542e991e581/start", "status": "Linked", "lastSync": "2022-01-01T12:30:00.000Z", "created": "2022-01-01T11:30:00Z", "dataConnectionErrors": []}]}, {"id": "096db70b-78de-4ff0-aa98-299cb5fe17a0", "name": "Godata", "description": "A new digital agency with a passion for creating amazing digital experiences", "redirect": "https://link.codat.io/company/096db70b-78de-4ff0-aa98-299cb5fe17a0", "lastSync": "2022-01-01T12:30:00.000Z", "created": "2022-01-01T11:30:00Z", "createdByUserName": "Mike Smith", "dataConnections": [{"id": "a70bc148-dc21-46b2-a257-d9c58ac15cbb", "integrationId": "1c312d69-e638-46d4-ad31-72e6c3ba8390", "integrationKey": "vjms", "sourceId": "396c3158-5dd7-481b-a7c4-a795ca31792b", "sourceType": "Accounting", "platformName": "Pandle", "linkUrl": "https://link-api.codat.io/companies/096db70b-78de-4ff0-aa98-299cb5fe17a0/connections/a70bc148-dc21-46b2-a257-d9c58ac15cbb/start", "status": "Linked", "lastSync": "2022-01-01T12:30:00.000Z", "created": "2022-01-01T11:30:00Z", "dataConnectionErrors": []}]}], "pageNumber": 1, "pageSize": 100, "totalResults": 2, "_links": {"self": {"href": "/companies"}, "current": {"href": "/companies?page=1&pageSize=100"}}} + application/json: {"results": [{"id": "d1568dde-adf6-11ed-afa1-0242ac120002", "name": "Technicalium", "description": "Technology services, including web and app design and development", "redirect": "https://link.codat.io/company/d1568dde-adf6-11ed-afa1-0242ac120002", "lastSync": "2022-01-01T12:30:00.000Z", "created": "2022-01-01T11:30:00Z", "createdByUserName": "Joe Bloggs", "dataConnections": [{"id": "51baa045-4836-4317-a42e-3542e991e581", "integrationId": "1c312d69-e638-46d4-ad31-72e6c3ba8390", "integrationKey": "vjms", "sourceId": "396c3158-5dd7-481b-a7c4-a795ca31792b", "sourceType": "Accounting", "platformName": "Pandle", "linkUrl": "https://link-api.codat.io/companies/d1568dde-adf6-11ed-afa1-0242ac120002/connections/51baa045-4836-4317-a42e-3542e991e581/start", "status": "Linked", "lastSync": "2022-01-01T12:30:00.000Z", "created": "2022-01-01T11:30:00Z", "dataConnectionErrors": [{"erroredOnUtc": "2022-10-23T00:00:00Z", "resolvedOnUtc": "2022-10-23T00:00:00Z"}, {"erroredOnUtc": "2022-10-23T00:00:00Z", "resolvedOnUtc": "2022-10-23T00:00:00Z"}]}]}, {"id": "096db70b-78de-4ff0-aa98-299cb5fe17a0", "name": "Godata", "description": "A new digital agency with a passion for creating amazing digital experiences", "redirect": "https://link.codat.io/company/096db70b-78de-4ff0-aa98-299cb5fe17a0", "lastSync": "2022-01-01T12:30:00.000Z", "created": "2022-01-01T11:30:00Z", "createdByUserName": "Mike Smith", "dataConnections": [{"id": "a70bc148-dc21-46b2-a257-d9c58ac15cbb", "integrationId": "1c312d69-e638-46d4-ad31-72e6c3ba8390", "integrationKey": "vjms", "sourceId": "396c3158-5dd7-481b-a7c4-a795ca31792b", "sourceType": "Accounting", "platformName": "Pandle", "linkUrl": "https://link-api.codat.io/companies/096db70b-78de-4ff0-aa98-299cb5fe17a0/connections/a70bc148-dc21-46b2-a257-d9c58ac15cbb/start", "status": "Linked", "lastSync": "2022-01-01T12:30:00.000Z", "created": "2022-01-01T11:30:00Z", "dataConnectionErrors": [{"erroredOnUtc": "2022-10-23T00:00:00Z", "resolvedOnUtc": "2022-10-23T00:00:00Z"}, {"erroredOnUtc": "2022-10-23T00:00:00Z", "resolvedOnUtc": "2022-10-23T00:00:00Z"}]}]}], "pageNumber": 1, "pageSize": 100, "totalResults": 2, "_links": {"self": {"href": "/companies"}, "current": {"href": "/companies?page=1&pageSize=100"}}} Malformed query: parameters: query: @@ -315,14 +314,14 @@ examples: create-company: With no description: requestBody: - application/json: {"name": "Technicalium", "description": "Requested early access to the new financing scheme.", "groups": []} + application/json: {"name": "Technicalium", "description": "Requested early access to the new financing scheme."} responses: "200": application/json: {"id": "ab12c58d-a678-4ebf-a159-ae99e1807bd0", "name": "Technicalium", "description": "", "redirect": "https://link.codat.io/company/ab12c58d-a678-4ebf-a159-ae99e1807bd0", "lastSync": "2022-10-23T00:00:00Z", "created": "2022-11-10T10:45:18.1950523Z", "createdByUserName": "Dan Tzabar", "dataConnections": []} "400": {} With a description: requestBody: - application/json: {"name": "Technicalium", "description": "Technology services, including web and app design and development", "groups": []} + application/json: {"name": "Technicalium", "description": "Technology services, including web and app design and development"} responses: "200": application/json: {"id": "ab12c58d-a678-4ebf-a159-ae99e1807bd0", "name": "Technicalium", "description": "Technology services, including web and app design and development", "redirect": "https://link.codat.io/company/ab12c58d-a678-4ebf-a159-ae99e1807bd0", "lastSync": "2022-10-23T00:00:00Z", "created": "2022-11-10T10:45:18.1950523Z", "createdByUserName": "Dan Tzabar", "dataConnections": []} @@ -336,27 +335,33 @@ examples: "400": {} Malformed query: requestBody: - application/json: {"name": "Bank of Dave", "description": "Requested early access to the new financing scheme.", "groups": []} + application/json: {"name": "Bank of Dave", "description": "Requested early access to the new financing scheme."} responses: "400": application/json: {"statusCode": 400, "service": "PublicApi", "error": "Error processing request - not valid.", "correlationId": "bc997528a9d7abb9161ef45f05d38599", "canBeRetried": "Unknown", "detailedErrorCode": 0} + With a tag: + requestBody: + application/json: {"name": "Bank of Dave", "description": "Requested early access to the new financing scheme."} + responses: + "200": + application/json: {"id": "ab12c58d-a678-4ebf-a159-ae99e1807bd0", "name": "Technicalium", "description": "", "redirect": "https://link.codat.io/company/ab12c58d-a678-4ebf-a159-ae99e1807bd0", "lastSync": "2022-10-23T00:00:00Z", "created": "2022-11-10T10:45:18.1950523Z", "createdByUserName": "Dan Tzabar", "dataConnections": []} update-company: Update name: parameters: path: companyId: "8a210b68-6988-11ed-a1eb-0242ac120002" requestBody: - application/json: {"name": "New Name", "description": "Requested early access to the new financing scheme.", "groups": []} + application/json: {"name": "New Name", "description": "Requested early access to the new financing scheme."} responses: "200": - application/json: {"id": "0498e921-9b53-4396-a412-4f2f5983b0a2", "name": "string", "description": "Requested early access to the new financing scheme.", "redirect": "https://link.codat.io/company/27628208-459c-46a2-a705-5641ce25f739", "lastSync": "2022-01-01T12:00:00.000Z", "created": "2022-01-01T12:00:00.000Z", "createdByUserName": "string", "dataConnections": [{"id": "ee2eb431-c0fa-4dc9-93fa-d29781c12bcd", "integrationId": "bf083d72-62c7-493e-aec9-81b4dbba7e2c", "integrationKey": "dfxm", "sourceId": "bdd831ce-eebd-4896-89a7-20e5ee8989ee", "sourceType": "Banking", "platformName": "Basiq", "linkUrl": "https://link-api.codat.io/companies/86bd88cb-44ab-4dfb-b32f-87b19b14287f/connections/ee2eb431-c0fa-4dc9-93fa-d29781c12bcd/start", "status": "Linked", "lastSync": "2022-10-27T10:22:43.6464237Z", "created": "2022-10-27T09:53:29Z", "dataConnectionErrors": []}]} + application/json: {"id": "0498e921-9b53-4396-a412-4f2f5983b0a2", "name": "string", "description": "Requested early access to the new financing scheme.", "redirect": "https://link.codat.io/company/27628208-459c-46a2-a705-5641ce25f739", "lastSync": "2022-01-01T12:00:00.000Z", "created": "2022-01-01T12:00:00.000Z", "createdByUserName": "string", "dataConnections": [{"id": "ee2eb431-c0fa-4dc9-93fa-d29781c12bcd", "integrationId": "bf083d72-62c7-493e-aec9-81b4dbba7e2c", "integrationKey": "dfxm", "sourceId": "bdd831ce-eebd-4896-89a7-20e5ee8989ee", "sourceType": "Banking", "platformName": "Basiq", "linkUrl": "https://link-api.codat.io/companies/86bd88cb-44ab-4dfb-b32f-87b19b14287f/connections/ee2eb431-c0fa-4dc9-93fa-d29781c12bcd/start", "status": "Linked", "lastSync": "2022-10-27T10:22:43.6464237Z", "created": "2022-10-27T09:53:29Z", "dataConnectionErrors": [{"erroredOnUtc": "2022-10-23T00:00:00Z", "resolvedOnUtc": "2022-10-23T00:00:00Z"}, {"erroredOnUtc": "2022-10-23T00:00:00Z", "resolvedOnUtc": "2022-10-23T00:00:00Z"}, {"erroredOnUtc": "2022-10-23T00:00:00Z", "resolvedOnUtc": "2022-10-23T00:00:00Z"}]}]} "401": {} Update description: parameters: path: companyId: "8a210b68-6988-11ed-a1eb-0242ac120002" requestBody: - application/json: {"name": "Same name", "description": "Additional documents required", "groups": []} + application/json: {"name": "Same name", "description": "Additional documents required"} responses: "200": application/json: {"id": "0498e921-9b53-4396-a412-4f2f5983b0a2", "name": "string", "description": "Requested early access to the new financing scheme.", "redirect": "https://link.codat.io/company/27628208-459c-46a2-a705-5641ce25f739", "lastSync": "2022-01-01T12:00:00.000Z", "created": "2022-01-01T12:00:00.000Z", "createdByUserName": "string", "dataConnections": [{"id": "ee2eb431-c0fa-4dc9-93fa-d29781c12bcd", "integrationId": "bf083d72-62c7-493e-aec9-81b4dbba7e2c", "integrationKey": "dfxm", "sourceId": "bdd831ce-eebd-4896-89a7-20e5ee8989ee", "sourceType": "Banking", "platformName": "Basiq", "linkUrl": "https://link-api.codat.io/companies/86bd88cb-44ab-4dfb-b32f-87b19b14287f/connections/ee2eb431-c0fa-4dc9-93fa-d29781c12bcd/start", "status": "Linked", "lastSync": "2022-10-27T10:22:43.6464237Z", "created": "2022-10-27T09:53:29Z", "dataConnectionErrors": []}]} @@ -366,7 +371,7 @@ examples: path: companyId: "8a210b68-6988-11ed-a1eb-0242ac120002" requestBody: - application/json: {"name": "Bank of Dave", "description": "Requested early access to the new financing scheme.", "groups": []} + application/json: {"name": "Bank of Dave", "description": "Requested early access to the new financing scheme."} responses: "401": application/json: {"statusCode": 401, "service": "PublicApi", "error": "Unauthorized", "correlationId": "7eb40d6b415d7bcd99ce658268284056", "canBeRetried": "Unknown", "detailedErrorCode": 0} @@ -425,7 +430,7 @@ examples: orderBy: "-modifiedDate" responses: "200": - application/json: {"results": [{"id": "ee2eb431-c0fa-4dc9-93fa-d29781c12bcd", "integrationId": "bf083d72-62c7-493e-aec9-81b4dbba7e2c", "integrationKey": "dfxm", "sourceId": "bdd831ce-eebd-4896-89a7-20e5ee8989ee", "sourceType": "Banking", "platformName": "Basiq", "linkUrl": "https://link-api.codat.io/companies/86bd88cb-44ab-4dfb-b32f-87b19b14287f/connections/ee2eb431-c0fa-4dc9-93fa-d29781c12bcd/start", "status": "Linked", "lastSync": "2022-10-27T10:22:43.6464237Z", "created": "2022-10-27T09:53:29Z", "dataConnectionErrors": []}], "pageNumber": 0, "pageSize": 0, "totalResults": 0, "_links": {"self": {"href": "string"}, "current": {"href": "string"}, "next": {"href": "string"}, "previous": {"href": "string"}}} + application/json: {"results": [{"id": "ee2eb431-c0fa-4dc9-93fa-d29781c12bcd", "integrationId": "bf083d72-62c7-493e-aec9-81b4dbba7e2c", "integrationKey": "dfxm", "sourceId": "bdd831ce-eebd-4896-89a7-20e5ee8989ee", "sourceType": "Banking", "platformName": "Basiq", "linkUrl": "https://link-api.codat.io/companies/86bd88cb-44ab-4dfb-b32f-87b19b14287f/connections/ee2eb431-c0fa-4dc9-93fa-d29781c12bcd/start", "status": "Linked", "lastSync": "2022-10-27T10:22:43.6464237Z", "created": "2022-10-27T09:53:29Z", "dataConnectionErrors": [{"erroredOnUtc": "2022-10-23T00:00:00Z", "resolvedOnUtc": "2022-10-23T00:00:00Z"}, {"erroredOnUtc": "2022-10-23T00:00:00Z", "resolvedOnUtc": "2022-10-23T00:00:00Z"}, {"erroredOnUtc": "2022-10-23T00:00:00Z", "resolvedOnUtc": "2022-10-23T00:00:00Z"}]}], "pageNumber": 0, "pageSize": 0, "totalResults": 0, "_links": {"self": {"href": "string"}, "current": {"href": "string"}, "next": {"href": "string"}, "previous": {"href": "string"}}} Malformed query: parameters: path: @@ -637,7 +642,7 @@ examples: continuationToken: "continuationToken=eyJwYWdlIjoyLCJwYWdlU2l6ZSI6MTAwLCJwYWdlQ291bnQiOjExfQ==" responses: "200": - application/json: {"results": [{"id": "18", "reference": "12", "supplierRef": {"id": "4", "supplierName": "BILLy elliot"}, "issueDate": "2019-05-13T00:00:00", "dueDate": "2019-05-13T00:00:00", "currency": "GBP", "currencyRate": "1,", "lineItems": [{"description": "Dance shoes", "unitAmount": 5, "quantity": 1, "taxAmount": 0, "accountRef": {"id": "16"}, "totalAmount": 5, "taxRateRef": {"id": "NON"}}], "status": "Open", "totalAmount": 5, "amountDue": 0, "sourceModifiedDate": {"sourceModifiedDate": "2022-10-23T00:00:00Z"}}, {"id": "22", "reference": "12", "supplierRef": {"id": "4", "supplierName": "BILLy elliot"}, "issueDate": "2019-05-13T00:00:00", "dueDate": "2019-05-13T00:00:00", "currency": "GBP", "currencyRate": 1, "lineItems": [{"description": "Dance shoes", "unitAmount": 5, "quantity": 1, "taxAmount": 0, "accountRef": {"id": "16"}, "totalAmount": 5, "taxRateRef": {"id": "NON"}}], "status": "Paid", "totalAmount": 5, "amountDue": 0, "sourceModifiedDate": {"sourceModifiedDate": "2022-10-23T00:00:00Z"}}], "pagination": {"continuationToken": "eyJwYWdlIjoyLCJwYWdlU2l6ZSI6MTAwLCJwYWdlQ291bnQiOjExfQ=="}} + application/json: {"results": [{"id": "18", "reference": "12", "supplierRef": {"id": "4", "supplierName": "BILLy elliot"}, "issueDate": "2019-05-13T00:00:00", "dueDate": "2019-05-13T00:00:00", "currency": "GBP", "currencyRate": "1,", "lineItems": [{"description": "Dance shoes", "unitAmount": 5, "quantity": 1, "taxAmount": 0, "accountRef": {"id": "16"}, "totalAmount": 5, "taxRateRef": {"id": "NON"}}], "status": "Open", "totalAmount": 5, "amountDue": 0, "sourceModifiedDate": "2022-05-26T10:34:10Z"}, {"id": "22", "reference": "12", "supplierRef": {"id": "4", "supplierName": "BILLy elliot"}, "issueDate": "2019-05-13T00:00:00", "dueDate": "2019-05-13T00:00:00", "currency": "GBP", "currencyRate": 1, "lineItems": [{"description": "Dance shoes", "unitAmount": 5, "quantity": 1, "taxAmount": 0, "accountRef": {"id": "16"}, "totalAmount": 5, "taxRateRef": {"id": "NON"}}], "status": "Paid", "totalAmount": 5, "amountDue": 0, "sourceModifiedDate": "2022-05-26T10:34:10Z"}], "pagination": {"continuationToken": "eyJwYWdlIjoyLCJwYWdlU2l6ZSI6MTAwLCJwYWdlQ291bnQiOjExfQ=="}} Malformed query: parameters: path: @@ -669,7 +674,7 @@ examples: application/json: {"reference": "bill_b8qmmj4ksf1suax", "supplierRef": {"id": "1262c350-fe0f-40ec-aeff-41c95b4a45af", "supplierName": "DIISR - Small Business Services"}, "issueDate": "2023-04-23T00:00:00", "dueDate": "2023-04-23T00:00:00", "currency": "GBP", "currencyRate": 1, "lineItems": [{"description": "Half day training - Microsoft Office", "unitAmount": 1800, "quantity": 1, "taxAmount": 360, "accountRef": {"id": "46f9461e-788b-4906-8b74-d1ea17f6dc10"}, "totalAmount": 2160, "taxRateRef": {"id": "INPUT2"}}, {"description": "Desktop/network support via email & phone.Per month fixed fee for minimum 20 hours/month.", "unitAmount": 4000, "quantity": 1, "taxAmount": 800, "accountRef": {"id": "f96c9458-d724-47bf-8f74-a9d5726465ce"}, "totalAmount": 4800, "taxRateRef": {"id": "INPUT2"}}, {"description": "Stationery charges", "unitAmount": 32, "quantity": 8, "taxAmount": 51.2, "accountRef": {"id": "cba6527d-f102-4538-b421-e483233e9d5a"}, "totalAmount": 307.2, "taxRateRef": {"id": "INPUT2"}}], "status": "Open", "totalAmount": 7267.2, "amountDue": 7267.2} responses: "200": - application/json: {"supplierRef": {"id": ""}, "issueDate": "2022-10-23T00:00:00Z", "dueDate": "2022-10-23T00:00:00Z", "currency": "GBP", "status": "Open", "sourceModifiedDate": {"sourceModifiedDate": "2022-10-23T00:00:00Z"}} + application/json: {"supplierRef": {"id": ""}, "issueDate": "2022-10-23T00:00:00Z", "dueDate": "2022-10-23T00:00:00Z", "currency": "GBP", "status": "Open", "sourceModifiedDate": "{\"sourceModifiedDate\":\"2022-10-23T00:00:00Z\"}"} "400": {} Created bill: parameters: @@ -681,7 +686,7 @@ examples: application/json: {"supplierRef": {"id": ""}, "issueDate": "2022-10-23T00:00:00Z", "dueDate": "2022-10-23T00:00:00Z", "currency": "USD", "status": "Open"} responses: "200": - application/json: {"id": "bill-1029932", "reference": "bill_b8qmmj4ksf1suax", "supplierRef": {"id": "1262c350-fe0f-40ec-aeff-41c95b4a45af", "supplierName": "DIISR - Small Business Services"}, "issueDate": "2023-04-23T00:00:00", "dueDate": "2023-04-23T00:00:00", "currency": "GBP", "lineItems": [{"description": "Half day training - Microsoft Office", "unitAmount": 1800, "quantity": 1, "taxAmount": 360, "accountRef": {"id": "46f9461e-788b-4906-8b74-d1ea17f6dc10"}, "totalAmount": 2160, "taxRateRef": {"id": "INPUT2"}}, {"description": "Desktop/network support via email & phone.Per month fixed fee for minimum 20 hours/month.", "unitAmount": 4000, "quantity": 1, "taxAmount": 800, "accountRef": {"id": "f96c9458-d724-47bf-8f74-a9d5726465ce"}, "totalAmount": 4800, "taxRateRef": {"id": "INPUT2"}}, {"description": "Stationery charges", "unitAmount": 32, "quantity": 8, "taxAmount": 51.2, "accountRef": {"id": "cba6527d-f102-4538-b421-e483233e9d5a"}, "totalAmount": 307.2, "taxRateRef": {"id": "INPUT2"}}], "status": "Open", "totalAmount": 7267.2, "amountDue": 7267.2, "sourceModifiedDate": {"sourceModifiedDate": "2022-10-23T00:00:00Z"}} + application/json: {"id": "bill-1029932", "reference": "bill_b8qmmj4ksf1suax", "supplierRef": {"id": "1262c350-fe0f-40ec-aeff-41c95b4a45af", "supplierName": "DIISR - Small Business Services"}, "issueDate": "2023-04-23T00:00:00", "dueDate": "2023-04-23T00:00:00", "currency": "GBP", "lineItems": [{"description": "Half day training - Microsoft Office", "unitAmount": 1800, "quantity": 1, "taxAmount": 360, "accountRef": {"id": "46f9461e-788b-4906-8b74-d1ea17f6dc10"}, "totalAmount": 2160, "taxRateRef": {"id": "INPUT2"}}, {"description": "Desktop/network support via email & phone.Per month fixed fee for minimum 20 hours/month.", "unitAmount": 4000, "quantity": 1, "taxAmount": 800, "accountRef": {"id": "f96c9458-d724-47bf-8f74-a9d5726465ce"}, "totalAmount": 4800, "taxRateRef": {"id": "INPUT2"}}, {"description": "Stationery charges", "unitAmount": 32, "quantity": 8, "taxAmount": 51.2, "accountRef": {"id": "cba6527d-f102-4538-b421-e483233e9d5a"}, "totalAmount": 307.2, "taxRateRef": {"id": "INPUT2"}}], "status": "Open", "totalAmount": 7267.2, "amountDue": 7267.2, "sourceModifiedDate": "{\"sourceModifiedDate\":\"2022-10-23T00:00:00Z\"}"} Malformed query: parameters: path: @@ -718,7 +723,7 @@ examples: path: companyId: "8a210b68-6988-11ed-a1eb-0242ac120002" connectionId: "2e9d2c44-f675-40ba-8049-353bfcb5e171" - billId: "9wg4lep4ush5cxs79pl8sozmsndbaukll3ind4g7buqbm1h2" + billId: "13d946f0-c5d5-42bc-b092-97ece17923ab" responses: "401": application/json: {"statusCode": 401, "service": "PublicApi", "error": "Unauthorized", "correlationId": "7eb40d6b415d7bcd99ce658268284056", "canBeRetried": "Unknown", "detailedErrorCode": 0} @@ -774,7 +779,7 @@ examples: path: companyId: "8a210b68-6988-11ed-a1eb-0242ac120002" connectionId: "2e9d2c44-f675-40ba-8049-353bfcb5e171" - billId: "7110701885" + billId: "9wg4lep4ush5cxs79pl8sozmsndbaukll3ind4g7buqbm1h2" header: {} requestBody: application/json: {"amount": 22, "date": "2022-10-23T00:00:00.000Z", "reference": "Bill Payment against bill c13e37b6 dfaa-4894-b3be-9fe97bda9f44", "accountRef": {"id": "7bda9f44sr56"}, "currencyRate": 1} @@ -787,7 +792,7 @@ examples: path: companyId: "8a210b68-6988-11ed-a1eb-0242ac120002" connectionId: "2e9d2c44-f675-40ba-8049-353bfcb5e171" - billId: "EILBDVJVNUAGVKRQ" + billId: "7110701885" header: {} requestBody: application/json: {"amount": 1329.54, "date": "2022-10-23T00:00:00Z", "reference": "Bill Payment against bill c13e37b6-dfaa-4894-b3be-9fe97bda9f44", "accountRef": {"id": ""}} @@ -817,7 +822,7 @@ examples: query: "sourceModifiedDate>2023-12-15T00:00:00.000Z" responses: "200": - application/json: {"results": [{"id": "C520FFD4-F6F6-4FC2-A6D2-5D7088B2B14F", "supplierName": "Kelly's Industrial Supplies", "contactName": "Kelly Ipsum", "emailAddress": "sales@kellysupplies.com", "phone": "07999 999999", "addresses": [{"type": "Billing", "line1": "Unit 51", "line2": "Bakersfield Industrial Estate", "city": "Bakersfield", "region": "California", "country": "USA"}], "status": "Active", "defaultCurrency": "GBP", "sourceModifiedDate": {"sourceModifiedDate": "2022-10-23T00:00:00Z"}}]} + application/json: {"results": [{"id": "C520FFD4-F6F6-4FC2-A6D2-5D7088B2B14F", "supplierName": "Kelly's Industrial Supplies", "contactName": "Kelly Ipsum", "emailAddress": "sales@kellysupplies.com", "phone": "07999 999999", "addresses": [{"type": "Billing", "line1": "Unit 51", "line2": "Bakersfield Industrial Estate", "city": "Bakersfield", "region": "California", "country": "USA"}], "status": "Active", "defaultCurrency": "GBP", "sourceModifiedDate": "{\"sourceModifiedDate\":\"2022-10-23T00:00:00Z\"}"}]} "400": {} Status (active): parameters: @@ -829,7 +834,7 @@ examples: query: "status=Active" responses: "200": - application/json: {"results": [{"id": "C520FFD4-F6F6-4FC2-A6D2-5D7088B2B14F", "supplierName": "Kelly's Industrial Supplies", "contactName": "Kelly Ipsum", "emailAddress": "sales@kellysupplies.com", "phone": "07999 999999", "addresses": [{"type": "Billing", "line1": "Unit 51", "line2": "Bakersfield Industrial Estate", "city": "Bakersfield", "region": "California", "country": "USA"}], "status": "Active", "defaultCurrency": "GBP", "sourceModifiedDate": {"sourceModifiedDate": "2022-10-23T00:00:00Z"}}]} + application/json: {"results": [{"id": "C520FFD4-F6F6-4FC2-A6D2-5D7088B2B14F", "supplierName": "Kelly's Industrial Supplies", "contactName": "Kelly Ipsum", "emailAddress": "sales@kellysupplies.com", "phone": "07999 999999", "addresses": [{"type": "Billing", "line1": "Unit 51", "line2": "Bakersfield Industrial Estate", "city": "Bakersfield", "region": "California", "country": "USA"}], "status": "Active", "defaultCurrency": "GBP", "sourceModifiedDate": "{\"sourceModifiedDate\":\"2022-10-23T00:00:00Z\"}"}]} "400": {} Status (archived): parameters: @@ -841,7 +846,7 @@ examples: query: "status=Archived" responses: "200": - application/json: {"results": [{"id": "C520FFD4-F6F6-4FC2-A6D2-5D7088B2B14F", "supplierName": "Kelly's Industrial Supplies", "contactName": "Kelly Ipsum", "emailAddress": "sales@kellysupplies.com", "phone": "07999 999999", "addresses": [{"type": "Billing", "line1": "Unit 51", "line2": "Bakersfield Industrial Estate", "city": "Bakersfield", "region": "California", "country": "USA"}], "status": "Active", "defaultCurrency": "GBP", "sourceModifiedDate": {"sourceModifiedDate": "2022-10-23T00:00:00Z"}}]} + application/json: {"results": [{"id": "C520FFD4-F6F6-4FC2-A6D2-5D7088B2B14F", "supplierName": "Kelly's Industrial Supplies", "contactName": "Kelly Ipsum", "emailAddress": "sales@kellysupplies.com", "phone": "07999 999999", "addresses": [{"type": "Billing", "line1": "Unit 51", "line2": "Bakersfield Industrial Estate", "city": "Bakersfield", "region": "California", "country": "USA"}], "status": "Active", "defaultCurrency": "GBP", "sourceModifiedDate": "{\"sourceModifiedDate\":\"2022-10-23T00:00:00Z\"}"}]} "400": {} Status (active) & source modified date: parameters: @@ -853,7 +858,7 @@ examples: query: "sourceModifiedDate>2023-12-15T00:00:00.000Z&&status=Active" responses: "200": - application/json: {"results": [{"id": "C520FFD4-F6F6-4FC2-A6D2-5D7088B2B14F", "supplierName": "Kelly's Industrial Supplies", "contactName": "Kelly Ipsum", "emailAddress": "sales@kellysupplies.com", "phone": "07999 999999", "addresses": [{"type": "Billing", "line1": "Unit 51", "line2": "Bakersfield Industrial Estate", "city": "Bakersfield", "region": "California", "country": "USA"}], "status": "Active", "defaultCurrency": "GBP", "sourceModifiedDate": {"sourceModifiedDate": "2022-10-23T00:00:00Z"}}]} + application/json: {"results": [{"id": "C520FFD4-F6F6-4FC2-A6D2-5D7088B2B14F", "supplierName": "Kelly's Industrial Supplies", "contactName": "Kelly Ipsum", "emailAddress": "sales@kellysupplies.com", "phone": "07999 999999", "addresses": [{"type": "Billing", "line1": "Unit 51", "line2": "Bakersfield Industrial Estate", "city": "Bakersfield", "region": "California", "country": "USA"}], "status": "Active", "defaultCurrency": "GBP", "sourceModifiedDate": "{\"sourceModifiedDate\":\"2022-10-23T00:00:00Z\"}"}]} "400": {} Status (archived) & source modified date: parameters: @@ -865,7 +870,7 @@ examples: query: "sourceModifiedDate>2023-12-15T00:00:00.000Z&&status=Archived" responses: "200": - application/json: {"results": [{"id": "C520FFD4-F6F6-4FC2-A6D2-5D7088B2B14F", "supplierName": "Kelly's Industrial Supplies", "contactName": "Kelly Ipsum", "emailAddress": "sales@kellysupplies.com", "phone": "07999 999999", "addresses": [{"type": "Billing", "line1": "Unit 51", "line2": "Bakersfield Industrial Estate", "city": "Bakersfield", "region": "California", "country": "USA"}], "status": "Active", "defaultCurrency": "GBP", "sourceModifiedDate": {"sourceModifiedDate": "2022-10-23T00:00:00Z"}}]} + application/json: {"results": [{"id": "C520FFD4-F6F6-4FC2-A6D2-5D7088B2B14F", "supplierName": "Kelly's Industrial Supplies", "contactName": "Kelly Ipsum", "emailAddress": "sales@kellysupplies.com", "phone": "07999 999999", "addresses": [{"type": "Billing", "line1": "Unit 51", "line2": "Bakersfield Industrial Estate", "city": "Bakersfield", "region": "California", "country": "USA"}], "status": "Active", "defaultCurrency": "GBP", "sourceModifiedDate": "{\"sourceModifiedDate\":\"2022-10-23T00:00:00Z\"}"}]} "400": {} Suppliers: parameters: @@ -876,7 +881,7 @@ examples: continuationToken: "continuationToken=eyJwYWdlIjoyLCJwYWdlU2l6ZSI6MTAwLCJwYWdlQ291bnQiOjExfQ==" responses: "200": - application/json: {"results": [{"id": "c523e12f-8b74-4d3a-bbd8-32d7a2f598b4", "supplierName": "City Limousines", "contactName": "Martin Dale", "emailAddress": "martyd@citylim.co", "phone": "07999 999999", "addresses": [{"type": "Billing", "line1": "Unit 51", "line2": "Bakersfield Industrial Estate", "city": "Bakersfield", "region": "California", "country": "USA"}], "status": "Active", "balance": 100, "defaultCurrency": "GBP", "sourceModifiedDate": {"sourceModifiedDate": "2022-10-23T00:00:00Z"}}, {"id": "41", "supplierName": "AI Support", "contactName": "AI Support", "phone": "+44 25691 154789", "addresses": [{"type": "Billing", "line1": "test", "region": "string", "country": "Djibouti"}], "status": "Active", "defaultCurrency": "GBP", "sourceModifiedDate": {"sourceModifiedDate": "2022-10-23T00:00:00Z"}}], "pagination": {"continuationToken": "eyJwYWdlIjoyLCJwYWdlU2l6ZSI6MTAwLCJwYWdlQ291bnQiOjExfQ=="}} + application/json: {"results": [{"id": "c523e12f-8b74-4d3a-bbd8-32d7a2f598b4", "supplierName": "City Limousines", "contactName": "Martin Dale", "emailAddress": "martyd@citylim.co", "phone": "07999 999999", "addresses": [{"type": "Billing", "line1": "Unit 51", "line2": "Bakersfield Industrial Estate", "city": "Bakersfield", "region": "California", "country": "USA"}], "status": "Active", "balance": 100, "defaultCurrency": "GBP", "sourceModifiedDate": "2022-10-23T00:00:00Z"}, {"id": "41", "supplierName": "AI Support", "contactName": "AI Support", "phone": "01224 658 999", "addresses": [{"type": "Billing", "line1": "test", "region": "string", "country": "Djibouti"}], "status": "Active", "defaultCurrency": "GBP", "sourceModifiedDate": "2022-12-07T10:48:18Z"}], "pagination": {"continuationToken": "eyJwYWdlIjoyLCJwYWdlU2l6ZSI6MTAwLCJwYWdlQ291bnQiOjExfQ=="}} Malformed query: parameters: path: @@ -908,7 +913,7 @@ examples: application/json: {"supplierName": "Greggs", "contactName": "Greg Greggs", "emailAddress": "greg@greggs.com", "phone": "+44 (0)1223 322410", "addresses": [{"type": "Billing", "line1": "Flat 1", "line2": "2 Dennis Avenue", "city": "London", "region": "Camden", "country": "GBR", "postalCode": "EC1N 7TE"}], "status": "Active", "defaultCurrency": "GBP"} responses: "200": - application/json: {"id": "sup-10933920", "supplierName": "Greggs", "contactName": "Greg Greggs", "emailAddress": "greg@greggs.com", "phone": "+44 (0)1223 322410", "status": "Active", "defaultCurrency": "GBP", "sourceModifiedDate": {"sourceModifiedDate": "2022-10-23T00:00:00Z"}} + application/json: {"id": "sup-10933920", "supplierName": "Greggs", "contactName": "Greg Greggs", "emailAddress": "greg@greggs.com", "phone": "+44 (0)1223 322410", "status": "Active", "defaultCurrency": "GBP", "sourceModifiedDate": "{\"sourceModifiedDate\":\"2022-10-23T00:00:00Z\"}"} "400": {} Malformed query: parameters: diff --git a/sync-for-payables/.speakeasy/gen.yaml b/sync-for-payables/.speakeasy/gen.yaml index 31ecde8c6..8aa22a8ba 100644 --- a/sync-for-payables/.speakeasy/gen.yaml +++ b/sync-for-payables/.speakeasy/gen.yaml @@ -13,7 +13,7 @@ generation: oAuth2ClientCredentialsEnabled: true telemetryEnabled: true go: - version: 1.0.0 + version: 2.0.0 additionalDependencies: {} allowUnknownFieldsInWeakUnions: false clientServerStatusCodesAsErrors: true diff --git a/sync-for-payables/README.md b/sync-for-payables/README.md index e5080f866..22e56d88a 100644 --- a/sync-for-payables/README.md +++ b/sync-for-payables/README.md @@ -76,9 +76,9 @@ package main import ( "context" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" "log" ) @@ -171,10 +171,10 @@ package main import ( "context" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/retry" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/retry" "log" "pkg/models/operations" ) @@ -219,10 +219,10 @@ package main import ( "context" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/retry" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/retry" "log" ) @@ -265,12 +265,16 @@ func main() { ## Error Handling -Handling errors in this SDK should largely match your expectations. All operations return a response object or an error, they will never return both. When specified by the OpenAPI spec document, the SDK will return the appropriate subclass. +Handling errors in this SDK should largely match your expectations. All operations return a response object or an error, they will never return both. -| Error Object | Status Code | Content Type | -| ------------------------------- | ------------------------------- | ------------------------------- | -| sdkerrors.ErrorMessage | 400,401,402,403,404,429,500,503 | application/json | -| sdkerrors.SDKError | 4xx-5xx | */* | +By Default, an API error will return `sdkerrors.SDKError`. When custom error responses are specified for an operation, the SDK may also return their associated error. You can refer to respective *Errors* tables in SDK docs for more details on possible error types for each operation. + +For example, the `List` function may return the following errors: + +| Error Type | Status Code | Content Type | +| -------------------------------------- | -------------------------------------- | -------------------------------------- | +| sdkerrors.ErrorMessage | 400, 401, 402, 403, 404, 429, 500, 503 | application/json | +| sdkerrors.SDKError | 4XX, 5XX | \*/\* | ### Example @@ -280,10 +284,10 @@ package main import ( "context" "errors" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/sdkerrors" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/sdkerrors" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" "log" ) @@ -338,9 +342,9 @@ package main import ( "context" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" "log" ) @@ -378,9 +382,9 @@ package main import ( "context" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" "log" ) @@ -456,9 +460,9 @@ package main import ( "context" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" "log" ) diff --git a/sync-for-payables/RELEASES.md b/sync-for-payables/RELEASES.md index a84555dda..9eb740d31 100644 --- a/sync-for-payables/RELEASES.md +++ b/sync-for-payables/RELEASES.md @@ -8,4 +8,14 @@ Based on: ### Generated - [go v1.0.0] sync-for-payables ### Releases -- [Go v1.0.0] https://github.com/codatio/client-sdk-go/releases/tag/sync-for-payables/v1.0.0 - sync-for-payables \ No newline at end of file +- [Go v1.0.0] https://github.com/codatio/client-sdk-go/releases/tag/sync-for-payables/v1.0.0 - sync-for-payables + +## 2024-10-02 13:20:38 +### Changes +Based on: +- OpenAPI Doc +- Speakeasy CLI 1.405.9 (2.429.0) https://github.com/speakeasy-api/speakeasy +### Generated +- [go v2.0.0] sync-for-payables +### Releases +- [Go v2.0.0] https://github.com/codatio/client-sdk-go/releases/tag/sync-for-payables/v2.0.0 - sync-for-payables \ No newline at end of file diff --git a/sync-for-payables/USAGE.md b/sync-for-payables/USAGE.md index af59cf522..8fae16db1 100644 --- a/sync-for-payables/USAGE.md +++ b/sync-for-payables/USAGE.md @@ -4,9 +4,9 @@ package main import ( "context" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" "log" ) diff --git a/sync-for-payables/bankaccounts.go b/sync-for-payables/bankaccounts.go index bcbda4126..fe0ea3318 100644 --- a/sync-for-payables/bankaccounts.go +++ b/sync-for-payables/bankaccounts.go @@ -7,12 +7,12 @@ import ( "context" "fmt" "github.com/cenkalti/backoff/v4" - "github.com/codatio/client-sdk-go/sync-for-payables/internal/hooks" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/sdkerrors" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/retry" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/utils" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/internal/hooks" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/sdkerrors" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/retry" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/utils" "io" "net/http" ) diff --git a/sync-for-payables/billpayments.go b/sync-for-payables/billpayments.go index 67307718d..cbec5850b 100644 --- a/sync-for-payables/billpayments.go +++ b/sync-for-payables/billpayments.go @@ -7,12 +7,12 @@ import ( "context" "fmt" "github.com/cenkalti/backoff/v4" - "github.com/codatio/client-sdk-go/sync-for-payables/internal/hooks" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/sdkerrors" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/retry" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/utils" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/internal/hooks" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/sdkerrors" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/retry" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/utils" "io" "net/http" ) diff --git a/sync-for-payables/bills.go b/sync-for-payables/bills.go index 6b0a92d76..71e605073 100644 --- a/sync-for-payables/bills.go +++ b/sync-for-payables/bills.go @@ -7,12 +7,12 @@ import ( "context" "fmt" "github.com/cenkalti/backoff/v4" - "github.com/codatio/client-sdk-go/sync-for-payables/internal/hooks" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/sdkerrors" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/retry" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/utils" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/internal/hooks" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/sdkerrors" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/retry" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/utils" "io" "net/http" ) diff --git a/sync-for-payables/codatsyncpayables.go b/sync-for-payables/codatsyncpayables.go index f30ebd339..7fee56019 100644 --- a/sync-for-payables/codatsyncpayables.go +++ b/sync-for-payables/codatsyncpayables.go @@ -5,10 +5,10 @@ package syncforpayables import ( "context" "fmt" - "github.com/codatio/client-sdk-go/sync-for-payables/internal/hooks" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/retry" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/utils" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/internal/hooks" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/retry" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/utils" "net/http" "time" ) @@ -180,9 +180,9 @@ func New(opts ...SDKOption) *CodatSyncPayables { sdkConfiguration: sdkConfiguration{ Language: "go", OpenAPIDocVersion: "3.0.0", - SDKVersion: "1.0.0", - GenVersion: "2.415.7", - UserAgent: "speakeasy-sdk/go 1.0.0 2.415.7 3.0.0 github.com/codatio/client-sdk-go/sync-for-payables", + SDKVersion: "2.0.0", + GenVersion: "2.429.0", + UserAgent: "speakeasy-sdk/go 2.0.0 2.429.0 3.0.0 github.com/codatio/client-sdk-go/sync-for-payables", Hooks: hooks.New(), }, } diff --git a/sync-for-payables/companies.go b/sync-for-payables/companies.go index 855b13271..2a4f2a9d7 100644 --- a/sync-for-payables/companies.go +++ b/sync-for-payables/companies.go @@ -7,12 +7,12 @@ import ( "context" "fmt" "github.com/cenkalti/backoff/v4" - "github.com/codatio/client-sdk-go/sync-for-payables/internal/hooks" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/sdkerrors" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/retry" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/utils" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/internal/hooks" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/sdkerrors" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/retry" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/utils" "io" "net/http" "net/url" @@ -529,7 +529,6 @@ func (s *Companies) Create(ctx context.Context, request *shared.CompanyRequestBo // Update company // Use the *Update company* endpoint to update both the name and description of the company. -// If you use [groups](https://docs.codat.io/sync-for-payables-api#/schemas/Group) to manage a set of companies, use the [Add company](https://docs.codat.io/sync-for-payables-api#/operations/add-company-to-group) or [Remove company](https://docs.codat.io/sync-for-payables-api#/operations/remove-company-from-group) endpoints to add or remove a company from a group. // // A [company](https://docs.codat.io/sync-for-payables-api#/schemas/Company) represents a business sharing access to their data. // Each company can have multiple [connections](https://docs.codat.io/sync-for-payables-api#/schemas/Connection) to different data sources, such as one connection to Xero for accounting data, two connections to Plaid for two bank accounts, and a connection to Zettle for POS data. diff --git a/sync-for-payables/companyinformation.go b/sync-for-payables/companyinformation.go index b39ca85e8..26adf9de8 100644 --- a/sync-for-payables/companyinformation.go +++ b/sync-for-payables/companyinformation.go @@ -7,12 +7,12 @@ import ( "context" "fmt" "github.com/cenkalti/backoff/v4" - "github.com/codatio/client-sdk-go/sync-for-payables/internal/hooks" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/sdkerrors" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/retry" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/utils" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/internal/hooks" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/sdkerrors" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/retry" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/utils" "io" "net/http" ) diff --git a/sync-for-payables/connections.go b/sync-for-payables/connections.go index 4e2635f52..c633bfe50 100644 --- a/sync-for-payables/connections.go +++ b/sync-for-payables/connections.go @@ -7,12 +7,12 @@ import ( "context" "fmt" "github.com/cenkalti/backoff/v4" - "github.com/codatio/client-sdk-go/sync-for-payables/internal/hooks" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/sdkerrors" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/retry" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/utils" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/internal/hooks" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/sdkerrors" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/retry" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/utils" "io" "net/http" ) diff --git a/sync-for-payables/docs/pkg/models/sdkerrors/errormessage.md b/sync-for-payables/docs/pkg/models/sdkerrors/errormessage.md index e4f989ffe..29fcb280d 100644 --- a/sync-for-payables/docs/pkg/models/sdkerrors/errormessage.md +++ b/sync-for-payables/docs/pkg/models/sdkerrors/errormessage.md @@ -1,6 +1,6 @@ # ErrorMessage -The request made is not valid. +Your `query` parameter was not correctly formed ## Fields diff --git a/sync-for-payables/docs/pkg/models/shared/bill.md b/sync-for-payables/docs/pkg/models/shared/bill.md index f272b9449..5ed70f9a7 100644 --- a/sync-for-payables/docs/pkg/models/shared/bill.md +++ b/sync-for-payables/docs/pkg/models/shared/bill.md @@ -18,4 +18,4 @@ | `Status` | [shared.BillStatus](../../../pkg/models/shared/billstatus.md) | :heavy_check_mark: | Current state of the bill. If creating a bill the status must be `Open`. | Open | | `TotalAmount` | [*decimal.Big](https://pkg.go.dev/github.com/ericlagergren/decimal#Big) | :heavy_minus_sign: | Amount of the bill, including tax. | | | `AmountDue` | [*decimal.Big](https://pkg.go.dev/github.com/ericlagergren/decimal#Big) | :heavy_minus_sign: | Amount outstanding on the bill. | | -| `SourceModifiedDate` | [*shared.One](../../../pkg/models/shared/one.md) | :heavy_minus_sign: | N/A | | \ No newline at end of file +| `SourceModifiedDate` | **string* | :heavy_minus_sign: | N/A | 2022-10-23 00:00:00 +0000 UTC | \ No newline at end of file diff --git a/sync-for-payables/docs/pkg/models/shared/company.md b/sync-for-payables/docs/pkg/models/shared/company.md index 8caeb4c2f..8f09c7933 100644 --- a/sync-for-payables/docs/pkg/models/shared/company.md +++ b/sync-for-payables/docs/pkg/models/shared/company.md @@ -18,5 +18,6 @@ When you create a company, you can specify a `name` and we will automatically ge | `LastSync` | **string* | :heavy_minus_sign: | In Codat's data model, dates and times are represented using the ISO 8601 standard. Date and time fields are formatted as strings; for example:

```
2020-10-08T22:40:50Z
2021-01-01T00:00:00
```



When syncing data that contains `DateTime` fields from Codat, make sure you support the following cases when reading time information:

- Coordinated Universal Time (UTC): `2021-11-15T06:00:00Z`
- Unqualified local time: `2021-11-15T01:00:00`
- UTC time offsets: `2021-11-15T01:00:00-05:00`

> Time zones
>
> Not all dates from Codat will contain information about time zones.
> Where it is not available from the underlying platform, Codat will return these as times local to the business whose data has been synced. | 2022-10-23 00:00:00 +0000 UTC | | `Created` | **string* | :heavy_minus_sign: | In Codat's data model, dates and times are represented using the ISO 8601 standard. Date and time fields are formatted as strings; for example:

```
2020-10-08T22:40:50Z
2021-01-01T00:00:00
```



When syncing data that contains `DateTime` fields from Codat, make sure you support the following cases when reading time information:

- Coordinated Universal Time (UTC): `2021-11-15T06:00:00Z`
- Unqualified local time: `2021-11-15T01:00:00`
- UTC time offsets: `2021-11-15T01:00:00-05:00`

> Time zones
>
> Not all dates from Codat will contain information about time zones.
> Where it is not available from the underlying platform, Codat will return these as times local to the business whose data has been synced. | 2022-10-23 00:00:00 +0000 UTC | | `CreatedByUserName` | **string* | :heavy_minus_sign: | Name of user that created the company in Codat. | | -| `Tags` | [*shared.Tags](../../../pkg/models/shared/tags.md) | :heavy_minus_sign: | A collection of user-defined key-value pairs that store custom metadata against the company. | | +| `Products` | []*string* | :heavy_minus_sign: | An array of products that are currently enabled for the company. | | +| `Tags` | [*shared.CompanyTags](../../../pkg/models/shared/companytags.md) | :heavy_minus_sign: | A collection of user-defined key-value pairs that store custom metadata against the company. | | | `DataConnections` | [][shared.Connection](../../../pkg/models/shared/connection.md) | :heavy_minus_sign: | N/A | | \ No newline at end of file diff --git a/sync-for-payables/docs/pkg/models/shared/companyrequestbody.md b/sync-for-payables/docs/pkg/models/shared/companyrequestbody.md index a8c134f49..469b3fef3 100644 --- a/sync-for-payables/docs/pkg/models/shared/companyrequestbody.md +++ b/sync-for-payables/docs/pkg/models/shared/companyrequestbody.md @@ -7,4 +7,4 @@ | ------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------- | | `Name` | *string* | :heavy_check_mark: | Name of company being connected. | Bank of Dave | | `Description` | **string* | :heavy_minus_sign: | Additional information about the company. This can be used to store foreign IDs, references, etc. | Requested early access to the new financing scheme. | -| `Groups` | [][shared.GroupReference](../../../pkg/models/shared/groupreference.md) | :heavy_minus_sign: | Reference to the groups that the company is assigned to. | | \ No newline at end of file +| `Tags` | [*shared.Tags](../../../pkg/models/shared/tags.md) | :heavy_minus_sign: | A collection of user-defined key-value pairs that store custom metadata against the company. | | \ No newline at end of file diff --git a/sync-for-payables/docs/pkg/models/shared/companytags.md b/sync-for-payables/docs/pkg/models/shared/companytags.md new file mode 100644 index 000000000..cbbb3f90f --- /dev/null +++ b/sync-for-payables/docs/pkg/models/shared/companytags.md @@ -0,0 +1,9 @@ +# CompanyTags + +A collection of user-defined key-value pairs that store custom metadata against the company. + + +## Fields + +| Field | Type | Required | Description | +| ----------- | ----------- | ----------- | ----------- | \ No newline at end of file diff --git a/sync-for-payables/docs/pkg/models/shared/connection.md b/sync-for-payables/docs/pkg/models/shared/connection.md index 3836edd6d..037e9cde7 100644 --- a/sync-for-payables/docs/pkg/models/shared/connection.md +++ b/sync-for-payables/docs/pkg/models/shared/connection.md @@ -27,5 +27,4 @@ Before you can use a data connection to pull or push data, the company must gran | `LastSync` | **string* | :heavy_minus_sign: | In Codat's data model, dates and times are represented using the ISO 8601 standard. Date and time fields are formatted as strings; for example:

```
2020-10-08T22:40:50Z
2021-01-01T00:00:00
```



When syncing data that contains `DateTime` fields from Codat, make sure you support the following cases when reading time information:

- Coordinated Universal Time (UTC): `2021-11-15T06:00:00Z`
- Unqualified local time: `2021-11-15T01:00:00`
- UTC time offsets: `2021-11-15T01:00:00-05:00`

> Time zones
>
> Not all dates from Codat will contain information about time zones.
> Where it is not available from the underlying platform, Codat will return these as times local to the business whose data has been synced. | 2022-10-23 00:00:00 +0000 UTC | | `Created` | *string* | :heavy_check_mark: | In Codat's data model, dates and times are represented using the ISO 8601 standard. Date and time fields are formatted as strings; for example:

```
2020-10-08T22:40:50Z
2021-01-01T00:00:00
```



When syncing data that contains `DateTime` fields from Codat, make sure you support the following cases when reading time information:

- Coordinated Universal Time (UTC): `2021-11-15T06:00:00Z`
- Unqualified local time: `2021-11-15T01:00:00`
- UTC time offsets: `2021-11-15T01:00:00-05:00`

> Time zones
>
> Not all dates from Codat will contain information about time zones.
> Where it is not available from the underlying platform, Codat will return these as times local to the business whose data has been synced. | 2022-10-23 00:00:00 +0000 UTC | | `DataConnectionErrors` | [][shared.DataConnectionError](../../../pkg/models/shared/dataconnectionerror.md) | :heavy_minus_sign: | N/A | | -| `ConnectionInfo` | map[string]*string* | :heavy_minus_sign: | N/A | | -| `AdditionalProperties` | *any* | :heavy_minus_sign: | N/A | | \ No newline at end of file +| `ConnectionInfo` | map[string]*string* | :heavy_minus_sign: | N/A | | \ No newline at end of file diff --git a/sync-for-payables/docs/pkg/models/shared/groupreference.md b/sync-for-payables/docs/pkg/models/shared/groupreference.md deleted file mode 100644 index 6bf386bd0..000000000 --- a/sync-for-payables/docs/pkg/models/shared/groupreference.md +++ /dev/null @@ -1,8 +0,0 @@ -# GroupReference - - -## Fields - -| Field | Type | Required | Description | Example | -| ------------------------------------ | ------------------------------------ | ------------------------------------ | ------------------------------------ | ------------------------------------ | -| `ID` | **string* | :heavy_minus_sign: | Unique identifier for the group. | 60d2fa12-8a04-11ee-b9d1-0242ac120002 | \ No newline at end of file diff --git a/sync-for-payables/docs/pkg/models/shared/one.md b/sync-for-payables/docs/pkg/models/shared/one.md deleted file mode 100644 index b4f54ae29..000000000 --- a/sync-for-payables/docs/pkg/models/shared/one.md +++ /dev/null @@ -1,8 +0,0 @@ -# One - - -## Fields - -| Field | Type | Required | Description | Example | -| ----------------------------- | ----------------------------- | ----------------------------- | ----------------------------- | ----------------------------- | -| `SourceModifiedDate` | **string* | :heavy_minus_sign: | N/A | 2022-10-23 00:00:00 +0000 UTC | \ No newline at end of file diff --git a/sync-for-payables/docs/pkg/models/shared/supplier.md b/sync-for-payables/docs/pkg/models/shared/supplier.md index 492fe25ed..bedfac94a 100644 --- a/sync-for-payables/docs/pkg/models/shared/supplier.md +++ b/sync-for-payables/docs/pkg/models/shared/supplier.md @@ -19,4 +19,4 @@ Suppliers' data links to accounts payable [bills](https://docs.codat.io/sync-for | `Status` | [*shared.SupplierStatus](../../../pkg/models/shared/supplierstatus.md) | :heavy_minus_sign: | Status of the supplier. | | | `Balance` | [*decimal.Big](https://pkg.go.dev/github.com/ericlagergren/decimal#Big) | :heavy_minus_sign: | Amount outstanding against the supplier. | | | `DefaultCurrency` | **string* | :heavy_minus_sign: | Default currency the supplier's transactional data is recorded in. | | -| `SourceModifiedDate` | [*shared.One](../../../pkg/models/shared/one.md) | :heavy_minus_sign: | N/A | | \ No newline at end of file +| `SourceModifiedDate` | **string* | :heavy_minus_sign: | N/A | 2022-10-23 00:00:00 +0000 UTC | \ No newline at end of file diff --git a/sync-for-payables/docs/sdks/bankaccounts/README.md b/sync-for-payables/docs/sdks/bankaccounts/README.md index d170cd2af..d53675843 100644 --- a/sync-for-payables/docs/sdks/bankaccounts/README.md +++ b/sync-for-payables/docs/sdks/bankaccounts/README.md @@ -21,10 +21,10 @@ The *Create bank account* endpoint creates a new [bank account](https://docs.cod package main import( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" "context" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" "log" ) @@ -71,7 +71,7 @@ func main() { ### Errors -| Error Object | Status Code | Content Type | -| ------------------------------- | ------------------------------- | ------------------------------- | -| sdkerrors.ErrorMessage | 400,401,402,403,404,429,500,503 | application/json | -| sdkerrors.SDKError | 4xx-5xx | */* | +| Error Type | Status Code | Content Type | +| -------------------------------------- | -------------------------------------- | -------------------------------------- | +| sdkerrors.ErrorMessage | 400, 401, 402, 403, 404, 429, 500, 503 | application/json | +| sdkerrors.SDKError | 4XX, 5XX | \*/\* | \ No newline at end of file diff --git a/sync-for-payables/docs/sdks/billpayments/README.md b/sync-for-payables/docs/sdks/billpayments/README.md index 95f72d497..41af3c1c0 100644 --- a/sync-for-payables/docs/sdks/billpayments/README.md +++ b/sync-for-payables/docs/sdks/billpayments/README.md @@ -24,10 +24,10 @@ Mapping options are a set of bank accounts used to configure the SMB's payables package main import( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" "context" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" "log" ) @@ -68,11 +68,10 @@ func main() { ### Errors -| Error Object | Status Code | Content Type | -| ------------------------------- | ------------------------------- | ------------------------------- | -| sdkerrors.ErrorMessage | 400,401,402,403,404,429,500,503 | application/json | -| sdkerrors.SDKError | 4xx-5xx | */* | - +| Error Type | Status Code | Content Type | +| -------------------------------------- | -------------------------------------- | -------------------------------------- | +| sdkerrors.ErrorMessage | 400, 401, 402, 403, 404, 429, 500, 503 | application/json | +| sdkerrors.SDKError | 4XX, 5XX | \*/\* | ## Create @@ -86,11 +85,11 @@ The *Create bill payment* endpoint creates a new [bill payment](https://docs.cod package main import( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" "context" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/types" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/types" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" "log" ) @@ -105,7 +104,7 @@ func main() { res, err := s.BillPayments.Create(ctx, operations.CreateBillPaymentRequest{ CompanyID: "8a210b68-6988-11ed-a1eb-0242ac120002", ConnectionID: "2e9d2c44-f675-40ba-8049-353bfcb5e171", - BillID: "7110701885", + BillID: "9wg4lep4ush5cxs79pl8sozmsndbaukll3ind4g7buqbm1h2", BillPaymentPrototype: &shared.BillPaymentPrototype{ Amount: types.MustNewDecimalFromString("22"), Date: "2022-10-23T00:00:00.000Z", @@ -139,7 +138,7 @@ func main() { ### Errors -| Error Object | Status Code | Content Type | -| ----------------------------------- | ----------------------------------- | ----------------------------------- | -| sdkerrors.ErrorMessage | 400,401,402,403,404,409,429,500,503 | application/json | -| sdkerrors.SDKError | 4xx-5xx | */* | +| Error Type | Status Code | Content Type | +| ------------------------------------------- | ------------------------------------------- | ------------------------------------------- | +| sdkerrors.ErrorMessage | 400, 401, 402, 403, 404, 409, 429, 500, 503 | application/json | +| sdkerrors.SDKError | 4XX, 5XX | \*/\* | \ No newline at end of file diff --git a/sync-for-payables/docs/sdks/bills/README.md b/sync-for-payables/docs/sdks/bills/README.md index dbdada974..099be18a6 100644 --- a/sync-for-payables/docs/sdks/bills/README.md +++ b/sync-for-payables/docs/sdks/bills/README.md @@ -28,10 +28,10 @@ Mapping options are a set of accounts and tax rates used to configure the SMB's package main import( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" "context" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" "log" ) @@ -72,11 +72,10 @@ func main() { ### Errors -| Error Object | Status Code | Content Type | -| ------------------------------- | ------------------------------- | ------------------------------- | -| sdkerrors.ErrorMessage | 400,401,402,403,404,429,500,503 | application/json | -| sdkerrors.SDKError | 4xx-5xx | */* | - +| Error Type | Status Code | Content Type | +| -------------------------------------- | -------------------------------------- | -------------------------------------- | +| sdkerrors.ErrorMessage | 400, 401, 402, 403, 404, 429, 500, 503 | application/json | +| sdkerrors.SDKError | 4XX, 5XX | \*/\* | ## List @@ -92,10 +91,10 @@ By default, the endpoint will return all bills with a status of 'Open' & 'Partia package main import( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" "context" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" "log" ) @@ -136,11 +135,10 @@ func main() { ### Errors -| Error Object | Status Code | Content Type | -| ----------------------------------- | ----------------------------------- | ----------------------------------- | -| sdkerrors.ErrorMessage | 400,401,402,403,404,409,429,500,503 | application/json | -| sdkerrors.SDKError | 4xx-5xx | */* | - +| Error Type | Status Code | Content Type | +| ------------------------------------------- | ------------------------------------------- | ------------------------------------------- | +| sdkerrors.ErrorMessage | 400, 401, 402, 403, 404, 409, 429, 500, 503 | application/json | +| sdkerrors.SDKError | 4XX, 5XX | \*/\* | ## Create @@ -154,11 +152,11 @@ The *Create bill* endpoint creates a new [bill](https://docs.codat.io/sync-for-p package main import( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" "context" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/types" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/types" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" "log" ) @@ -252,11 +250,10 @@ func main() { ### Errors -| Error Object | Status Code | Content Type | -| ----------------------------------- | ----------------------------------- | ----------------------------------- | -| sdkerrors.ErrorMessage | 400,401,402,403,404,409,429,500,503 | application/json | -| sdkerrors.SDKError | 4xx-5xx | */* | - +| Error Type | Status Code | Content Type | +| ------------------------------------------- | ------------------------------------------- | ------------------------------------------- | +| sdkerrors.ErrorMessage | 400, 401, 402, 403, 404, 409, 429, 500, 503 | application/json | +| sdkerrors.SDKError | 4XX, 5XX | \*/\* | ## UploadAttachment @@ -270,11 +267,11 @@ The *Upload bill attachment* endpoint uploads an attachment and assigns it again package main import( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" "os" "context" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" "log" ) @@ -319,11 +316,10 @@ func main() { ### Errors -| Error Object | Status Code | Content Type | -| ------------------------------- | ------------------------------- | ------------------------------- | -| sdkerrors.ErrorMessage | 400,401,402,403,404,429,500,503 | application/json | -| sdkerrors.SDKError | 4xx-5xx | */* | - +| Error Type | Status Code | Content Type | +| -------------------------------------- | -------------------------------------- | -------------------------------------- | +| sdkerrors.ErrorMessage | 400, 401, 402, 403, 404, 429, 500, 503 | application/json | +| sdkerrors.SDKError | 4XX, 5XX | \*/\* | ## ListAttachments @@ -337,10 +333,10 @@ The *List bill attachments* endpoint returns a list of attachments available to package main import( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" "context" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" "log" ) @@ -380,11 +376,10 @@ func main() { ### Errors -| Error Object | Status Code | Content Type | -| ------------------------------- | ------------------------------- | ------------------------------- | -| sdkerrors.ErrorMessage | 401,402,403,404,409,429,500,503 | application/json | -| sdkerrors.SDKError | 4xx-5xx | */* | - +| Error Type | Status Code | Content Type | +| -------------------------------------- | -------------------------------------- | -------------------------------------- | +| sdkerrors.ErrorMessage | 401, 402, 403, 404, 409, 429, 500, 503 | application/json | +| sdkerrors.SDKError | 4XX, 5XX | \*/\* | ## DownloadAttachment @@ -401,10 +396,10 @@ Check out our [coverage explorer](https://knowledge.codat.io/supported-features/ package main import( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" "context" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" "log" ) @@ -445,7 +440,7 @@ func main() { ### Errors -| Error Object | Status Code | Content Type | -| --------------------------- | --------------------------- | --------------------------- | -| sdkerrors.ErrorMessage | 401,402,403,404,429,500,503 | application/json | -| sdkerrors.SDKError | 4xx-5xx | */* | +| Error Type | Status Code | Content Type | +| --------------------------------- | --------------------------------- | --------------------------------- | +| sdkerrors.ErrorMessage | 401, 402, 403, 404, 429, 500, 503 | application/json | +| sdkerrors.SDKError | 4XX, 5XX | \*/\* | \ No newline at end of file diff --git a/sync-for-payables/docs/sdks/companies/README.md b/sync-for-payables/docs/sdks/companies/README.md index 48293c0b7..73361a43b 100644 --- a/sync-for-payables/docs/sdks/companies/README.md +++ b/sync-for-payables/docs/sdks/companies/README.md @@ -26,10 +26,10 @@ Each company can have multiple [connections](https://docs.codat.io/sync-for-paya package main import( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" "context" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" "log" ) @@ -70,11 +70,10 @@ func main() { ### Errors -| Error Object | Status Code | Content Type | -| ------------------------------- | ------------------------------- | ------------------------------- | -| sdkerrors.ErrorMessage | 400,401,402,403,404,429,500,503 | application/json | -| sdkerrors.SDKError | 4xx-5xx | */* | - +| Error Type | Status Code | Content Type | +| -------------------------------------- | -------------------------------------- | -------------------------------------- | +| sdkerrors.ErrorMessage | 400, 401, 402, 403, 404, 429, 500, 503 | application/json | +| sdkerrors.SDKError | 4XX, 5XX | \*/\* | ## Create @@ -91,8 +90,8 @@ If forbidden characters (see `name` pattern) are present in the request, a compa package main import( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" "context" "log" ) @@ -108,11 +107,6 @@ func main() { res, err := s.Companies.Create(ctx, &shared.CompanyRequestBody{ Name: "Technicalium", Description: syncforpayables.String("Requested early access to the new financing scheme."), - Groups: []shared.GroupReference{ - shared.GroupReference{ - ID: syncforpayables.String("60d2fa12-8a04-11ee-b9d1-0242ac120002"), - }, - }, }) if err != nil { log.Fatal(err) @@ -137,16 +131,14 @@ func main() { ### Errors -| Error Object | Status Code | Content Type | -| --------------------------- | --------------------------- | --------------------------- | -| sdkerrors.ErrorMessage | 400,401,402,403,429,500,503 | application/json | -| sdkerrors.SDKError | 4xx-5xx | */* | - +| Error Type | Status Code | Content Type | +| --------------------------------- | --------------------------------- | --------------------------------- | +| sdkerrors.ErrorMessage | 400, 401, 402, 403, 429, 500, 503 | application/json | +| sdkerrors.SDKError | 4XX, 5XX | \*/\* | ## Update Use the *Update company* endpoint to update both the name and description of the company. -If you use [groups](https://docs.codat.io/sync-for-payables-api#/schemas/Group) to manage a set of companies, use the [Add company](https://docs.codat.io/sync-for-payables-api#/operations/add-company-to-group) or [Remove company](https://docs.codat.io/sync-for-payables-api#/operations/remove-company-from-group) endpoints to add or remove a company from a group. A [company](https://docs.codat.io/sync-for-payables-api#/schemas/Company) represents a business sharing access to their data. Each company can have multiple [connections](https://docs.codat.io/sync-for-payables-api#/schemas/Connection) to different data sources, such as one connection to Xero for accounting data, two connections to Plaid for two bank accounts, and a connection to Zettle for POS data. @@ -157,10 +149,10 @@ Each company can have multiple [connections](https://docs.codat.io/sync-for-paya package main import( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" "context" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" "log" ) @@ -177,11 +169,6 @@ func main() { CompanyRequestBody: &shared.CompanyRequestBody{ Name: "New Name", Description: syncforpayables.String("Requested early access to the new financing scheme."), - Groups: []shared.GroupReference{ - shared.GroupReference{ - ID: syncforpayables.String("60d2fa12-8a04-11ee-b9d1-0242ac120002"), - }, - }, }, }) if err != nil { @@ -207,11 +194,10 @@ func main() { ### Errors -| Error Object | Status Code | Content Type | -| --------------------------- | --------------------------- | --------------------------- | -| sdkerrors.ErrorMessage | 401,402,403,404,429,500,503 | application/json | -| sdkerrors.SDKError | 4xx-5xx | */* | - +| Error Type | Status Code | Content Type | +| --------------------------------- | --------------------------------- | --------------------------------- | +| sdkerrors.ErrorMessage | 401, 402, 403, 404, 429, 500, 503 | application/json | +| sdkerrors.SDKError | 4XX, 5XX | \*/\* | ## Delete @@ -227,10 +213,10 @@ Each company can have multiple [connections](https://docs.codat.io/sync-for-paya package main import( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" "context" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" "log" ) @@ -268,11 +254,10 @@ func main() { ### Errors -| Error Object | Status Code | Content Type | -| --------------------------- | --------------------------- | --------------------------- | -| sdkerrors.ErrorMessage | 401,402,403,404,429,500,503 | application/json | -| sdkerrors.SDKError | 4xx-5xx | */* | - +| Error Type | Status Code | Content Type | +| --------------------------------- | --------------------------------- | --------------------------------- | +| sdkerrors.ErrorMessage | 401, 402, 403, 404, 429, 500, 503 | application/json | +| sdkerrors.SDKError | 4XX, 5XX | \*/\* | ## Get @@ -288,10 +273,10 @@ Each company can have multiple [connections](https://docs.codat.io/sync-for-paya package main import( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" "context" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" "log" ) @@ -329,7 +314,7 @@ func main() { ### Errors -| Error Object | Status Code | Content Type | -| --------------------------- | --------------------------- | --------------------------- | -| sdkerrors.ErrorMessage | 401,402,403,404,429,500,503 | application/json | -| sdkerrors.SDKError | 4xx-5xx | */* | +| Error Type | Status Code | Content Type | +| --------------------------------- | --------------------------------- | --------------------------------- | +| sdkerrors.ErrorMessage | 401, 402, 403, 404, 429, 500, 503 | application/json | +| sdkerrors.SDKError | 4XX, 5XX | \*/\* | \ No newline at end of file diff --git a/sync-for-payables/docs/sdks/companyinformation/README.md b/sync-for-payables/docs/sdks/companyinformation/README.md index 3e8f39a23..97e289588 100644 --- a/sync-for-payables/docs/sdks/companyinformation/README.md +++ b/sync-for-payables/docs/sdks/companyinformation/README.md @@ -21,10 +21,10 @@ Use the *Get company information* endpoint to return information about the compa package main import( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" "context" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" "log" ) @@ -63,7 +63,7 @@ func main() { ### Errors -| Error Object | Status Code | Content Type | -| ------------------------------- | ------------------------------- | ------------------------------- | -| sdkerrors.ErrorMessage | 400,401,402,403,404,429,500,503 | application/json | -| sdkerrors.SDKError | 4xx-5xx | */* | +| Error Type | Status Code | Content Type | +| -------------------------------------- | -------------------------------------- | -------------------------------------- | +| sdkerrors.ErrorMessage | 400, 401, 402, 403, 404, 429, 500, 503 | application/json | +| sdkerrors.SDKError | 4XX, 5XX | \*/\* | \ No newline at end of file diff --git a/sync-for-payables/docs/sdks/connections/README.md b/sync-for-payables/docs/sdks/connections/README.md index af9e3b476..f71d53cce 100644 --- a/sync-for-payables/docs/sdks/connections/README.md +++ b/sync-for-payables/docs/sdks/connections/README.md @@ -23,10 +23,10 @@ Create new and manage existing data connections for a company. package main import( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" "context" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" "log" ) @@ -68,11 +68,10 @@ func main() { ### Errors -| Error Object | Status Code | Content Type | -| ------------------------------- | ------------------------------- | ------------------------------- | -| sdkerrors.ErrorMessage | 400,401,402,403,404,429,500,503 | application/json | -| sdkerrors.SDKError | 4xx-5xx | */* | - +| Error Type | Status Code | Content Type | +| -------------------------------------- | -------------------------------------- | -------------------------------------- | +| sdkerrors.ErrorMessage | 400, 401, 402, 403, 404, 429, 500, 503 | application/json | +| sdkerrors.SDKError | 4XX, 5XX | \*/\* | ## Create @@ -86,10 +85,10 @@ Use the [List Integrations](https://docs.codat.io/sync-for-payables-api#/operati package main import( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" "context" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" "log" ) @@ -130,11 +129,10 @@ func main() { ### Errors -| Error Object | Status Code | Content Type | -| --------------------------- | --------------------------- | --------------------------- | -| sdkerrors.ErrorMessage | 401,402,403,404,429,500,503 | application/json | -| sdkerrors.SDKError | 4xx-5xx | */* | - +| Error Type | Status Code | Content Type | +| --------------------------------- | --------------------------------- | --------------------------------- | +| sdkerrors.ErrorMessage | 401, 402, 403, 404, 429, 500, 503 | application/json | +| sdkerrors.SDKError | 4XX, 5XX | \*/\* | ## Get @@ -146,10 +144,10 @@ func main() { package main import( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" "context" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" "log" ) @@ -188,11 +186,10 @@ func main() { ### Errors -| Error Object | Status Code | Content Type | -| --------------------------- | --------------------------- | --------------------------- | -| sdkerrors.ErrorMessage | 401,402,403,404,429,500,503 | application/json | -| sdkerrors.SDKError | 4xx-5xx | */* | - +| Error Type | Status Code | Content Type | +| --------------------------------- | --------------------------------- | --------------------------------- | +| sdkerrors.ErrorMessage | 401, 402, 403, 404, 429, 500, 503 | application/json | +| sdkerrors.SDKError | 4XX, 5XX | \*/\* | ## Delete @@ -205,10 +202,10 @@ This operation is not reversible. The end user would need to reauthorize a new d package main import( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" "context" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" "log" ) @@ -247,11 +244,10 @@ func main() { ### Errors -| Error Object | Status Code | Content Type | -| --------------------------- | --------------------------- | --------------------------- | -| sdkerrors.ErrorMessage | 401,402,403,404,429,500,503 | application/json | -| sdkerrors.SDKError | 4xx-5xx | */* | - +| Error Type | Status Code | Content Type | +| --------------------------------- | --------------------------------- | --------------------------------- | +| sdkerrors.ErrorMessage | 401, 402, 403, 404, 429, 500, 503 | application/json | +| sdkerrors.SDKError | 4XX, 5XX | \*/\* | ## Unlink @@ -263,10 +259,10 @@ func main() { package main import( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" "context" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" "log" ) @@ -308,7 +304,7 @@ func main() { ### Errors -| Error Object | Status Code | Content Type | -| --------------------------- | --------------------------- | --------------------------- | -| sdkerrors.ErrorMessage | 401,402,403,404,429,500,503 | application/json | -| sdkerrors.SDKError | 4xx-5xx | */* | +| Error Type | Status Code | Content Type | +| --------------------------------- | --------------------------------- | --------------------------------- | +| sdkerrors.ErrorMessage | 401, 402, 403, 404, 429, 500, 503 | application/json | +| sdkerrors.SDKError | 4XX, 5XX | \*/\* | \ No newline at end of file diff --git a/sync-for-payables/docs/sdks/suppliers/README.md b/sync-for-payables/docs/sdks/suppliers/README.md index 675e6ad6b..ca9457fe4 100644 --- a/sync-for-payables/docs/sdks/suppliers/README.md +++ b/sync-for-payables/docs/sdks/suppliers/README.md @@ -26,10 +26,10 @@ For example, to retrieve only active suppliers (i.e. `status=Active`) or supplie package main import( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" "context" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" "log" ) @@ -70,11 +70,10 @@ func main() { ### Errors -| Error Object | Status Code | Content Type | -| ----------------------------------- | ----------------------------------- | ----------------------------------- | -| sdkerrors.ErrorMessage | 400,401,402,403,404,409,429,500,503 | application/json | -| sdkerrors.SDKError | 4xx-5xx | */* | - +| Error Type | Status Code | Content Type | +| ------------------------------------------- | ------------------------------------------- | ------------------------------------------- | +| sdkerrors.ErrorMessage | 400, 401, 402, 403, 404, 409, 429, 500, 503 | application/json | +| sdkerrors.SDKError | 4XX, 5XX | \*/\* | ## Create @@ -89,10 +88,10 @@ The *Create supplier* endpoint creates a new [supplier](https://docs.codat.io/sy package main import( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + syncforpayables "github.com/codatio/client-sdk-go/sync-for-payables/v2" "context" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" "log" ) @@ -150,7 +149,7 @@ func main() { ### Errors -| Error Object | Status Code | Content Type | -| ------------------------------- | ------------------------------- | ------------------------------- | -| sdkerrors.ErrorMessage | 400,401,402,403,404,429,500,503 | application/json | -| sdkerrors.SDKError | 4xx-5xx | */* | +| Error Type | Status Code | Content Type | +| -------------------------------------- | -------------------------------------- | -------------------------------------- | +| sdkerrors.ErrorMessage | 400, 401, 402, 403, 404, 429, 500, 503 | application/json | +| sdkerrors.SDKError | 4XX, 5XX | \*/\* | \ No newline at end of file diff --git a/sync-for-payables/go.mod b/sync-for-payables/go.mod index 96045f116..90a2040d6 100644 --- a/sync-for-payables/go.mod +++ b/sync-for-payables/go.mod @@ -1,4 +1,4 @@ -module github.com/codatio/client-sdk-go/sync-for-payables +module github.com/codatio/client-sdk-go/sync-for-payables/v2 go 1.20 diff --git a/sync-for-payables/pkg/models/operations/createbankaccount.go b/sync-for-payables/pkg/models/operations/createbankaccount.go index a77bbfcbf..c7df067bc 100644 --- a/sync-for-payables/pkg/models/operations/createbankaccount.go +++ b/sync-for-payables/pkg/models/operations/createbankaccount.go @@ -3,7 +3,7 @@ package operations import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" ) type CreateBankAccountRequest struct { diff --git a/sync-for-payables/pkg/models/operations/createbill.go b/sync-for-payables/pkg/models/operations/createbill.go index 95d7b756f..aa3b5cd82 100644 --- a/sync-for-payables/pkg/models/operations/createbill.go +++ b/sync-for-payables/pkg/models/operations/createbill.go @@ -3,7 +3,7 @@ package operations import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" ) type CreateBillRequest struct { diff --git a/sync-for-payables/pkg/models/operations/createbillpayment.go b/sync-for-payables/pkg/models/operations/createbillpayment.go index c78157136..764f27dfb 100644 --- a/sync-for-payables/pkg/models/operations/createbillpayment.go +++ b/sync-for-payables/pkg/models/operations/createbillpayment.go @@ -3,7 +3,7 @@ package operations import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" ) type CreateBillPaymentRequest struct { diff --git a/sync-for-payables/pkg/models/operations/createcompany.go b/sync-for-payables/pkg/models/operations/createcompany.go index d898870ed..6cc237106 100644 --- a/sync-for-payables/pkg/models/operations/createcompany.go +++ b/sync-for-payables/pkg/models/operations/createcompany.go @@ -3,7 +3,7 @@ package operations import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" ) type CreateCompanyResponse struct { diff --git a/sync-for-payables/pkg/models/operations/createconnection.go b/sync-for-payables/pkg/models/operations/createconnection.go index ea9e53368..3e34d54ab 100644 --- a/sync-for-payables/pkg/models/operations/createconnection.go +++ b/sync-for-payables/pkg/models/operations/createconnection.go @@ -3,7 +3,7 @@ package operations import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" ) type CreateConnectionRequestBody struct { diff --git a/sync-for-payables/pkg/models/operations/createsupplier.go b/sync-for-payables/pkg/models/operations/createsupplier.go index 2d4d313da..e19c94de4 100644 --- a/sync-for-payables/pkg/models/operations/createsupplier.go +++ b/sync-for-payables/pkg/models/operations/createsupplier.go @@ -3,7 +3,7 @@ package operations import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" ) type CreateSupplierRequest struct { diff --git a/sync-for-payables/pkg/models/operations/deletecompany.go b/sync-for-payables/pkg/models/operations/deletecompany.go index fab99a38f..78fc2e244 100644 --- a/sync-for-payables/pkg/models/operations/deletecompany.go +++ b/sync-for-payables/pkg/models/operations/deletecompany.go @@ -3,7 +3,7 @@ package operations import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" ) type DeleteCompanyRequest struct { diff --git a/sync-for-payables/pkg/models/operations/deleteconnection.go b/sync-for-payables/pkg/models/operations/deleteconnection.go index 2d616d989..6660a82b8 100644 --- a/sync-for-payables/pkg/models/operations/deleteconnection.go +++ b/sync-for-payables/pkg/models/operations/deleteconnection.go @@ -3,7 +3,7 @@ package operations import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" ) type DeleteConnectionRequest struct { diff --git a/sync-for-payables/pkg/models/operations/downloadbillattachment.go b/sync-for-payables/pkg/models/operations/downloadbillattachment.go index 7a742a723..0f627920d 100644 --- a/sync-for-payables/pkg/models/operations/downloadbillattachment.go +++ b/sync-for-payables/pkg/models/operations/downloadbillattachment.go @@ -3,7 +3,7 @@ package operations import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" "io" ) diff --git a/sync-for-payables/pkg/models/operations/getcompany.go b/sync-for-payables/pkg/models/operations/getcompany.go index 71eba6caf..0589abebd 100644 --- a/sync-for-payables/pkg/models/operations/getcompany.go +++ b/sync-for-payables/pkg/models/operations/getcompany.go @@ -3,7 +3,7 @@ package operations import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" ) type GetCompanyRequest struct { diff --git a/sync-for-payables/pkg/models/operations/getcompanyinformation.go b/sync-for-payables/pkg/models/operations/getcompanyinformation.go index e5643e323..ff5fe0cc8 100644 --- a/sync-for-payables/pkg/models/operations/getcompanyinformation.go +++ b/sync-for-payables/pkg/models/operations/getcompanyinformation.go @@ -3,7 +3,7 @@ package operations import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" ) type GetCompanyInformationRequest struct { diff --git a/sync-for-payables/pkg/models/operations/getconnection.go b/sync-for-payables/pkg/models/operations/getconnection.go index 4c49551d0..dff6360f6 100644 --- a/sync-for-payables/pkg/models/operations/getconnection.go +++ b/sync-for-payables/pkg/models/operations/getconnection.go @@ -3,7 +3,7 @@ package operations import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" ) type GetConnectionRequest struct { diff --git a/sync-for-payables/pkg/models/operations/getmappingoptionsbills.go b/sync-for-payables/pkg/models/operations/getmappingoptionsbills.go index de69e2939..1f1d786a2 100644 --- a/sync-for-payables/pkg/models/operations/getmappingoptionsbills.go +++ b/sync-for-payables/pkg/models/operations/getmappingoptionsbills.go @@ -3,7 +3,7 @@ package operations import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" ) type GetMappingOptionsBillsRequest struct { diff --git a/sync-for-payables/pkg/models/operations/getmappingoptionspayments.go b/sync-for-payables/pkg/models/operations/getmappingoptionspayments.go index cacfde7b3..3c926029c 100644 --- a/sync-for-payables/pkg/models/operations/getmappingoptionspayments.go +++ b/sync-for-payables/pkg/models/operations/getmappingoptionspayments.go @@ -3,7 +3,7 @@ package operations import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" ) type GetMappingOptionsPaymentsRequest struct { diff --git a/sync-for-payables/pkg/models/operations/listbillattachments.go b/sync-for-payables/pkg/models/operations/listbillattachments.go index 50b4433a5..09e41fabc 100644 --- a/sync-for-payables/pkg/models/operations/listbillattachments.go +++ b/sync-for-payables/pkg/models/operations/listbillattachments.go @@ -3,7 +3,7 @@ package operations import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" ) type ListBillAttachmentsRequest struct { diff --git a/sync-for-payables/pkg/models/operations/listbills.go b/sync-for-payables/pkg/models/operations/listbills.go index 64584476d..c6c255882 100644 --- a/sync-for-payables/pkg/models/operations/listbills.go +++ b/sync-for-payables/pkg/models/operations/listbills.go @@ -3,7 +3,7 @@ package operations import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" ) type ListBillsRequest struct { diff --git a/sync-for-payables/pkg/models/operations/listcompanies.go b/sync-for-payables/pkg/models/operations/listcompanies.go index 257606ff3..573fbab19 100644 --- a/sync-for-payables/pkg/models/operations/listcompanies.go +++ b/sync-for-payables/pkg/models/operations/listcompanies.go @@ -3,8 +3,8 @@ package operations import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/utils" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/utils" ) type ListCompaniesRequest struct { diff --git a/sync-for-payables/pkg/models/operations/listconnections.go b/sync-for-payables/pkg/models/operations/listconnections.go index 56f164420..a55f570da 100644 --- a/sync-for-payables/pkg/models/operations/listconnections.go +++ b/sync-for-payables/pkg/models/operations/listconnections.go @@ -3,8 +3,8 @@ package operations import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/utils" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/utils" ) type ListConnectionsRequest struct { diff --git a/sync-for-payables/pkg/models/operations/listsuppliers.go b/sync-for-payables/pkg/models/operations/listsuppliers.go index b809d0f9b..cf1d84cf1 100644 --- a/sync-for-payables/pkg/models/operations/listsuppliers.go +++ b/sync-for-payables/pkg/models/operations/listsuppliers.go @@ -3,7 +3,7 @@ package operations import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" ) type ListSuppliersRequest struct { diff --git a/sync-for-payables/pkg/models/operations/options.go b/sync-for-payables/pkg/models/operations/options.go index 75ed675d3..eb907be4a 100644 --- a/sync-for-payables/pkg/models/operations/options.go +++ b/sync-for-payables/pkg/models/operations/options.go @@ -4,8 +4,8 @@ package operations import ( "errors" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/retry" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/utils" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/retry" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/utils" "time" ) diff --git a/sync-for-payables/pkg/models/operations/unlinkconnection.go b/sync-for-payables/pkg/models/operations/unlinkconnection.go index 78a433028..f219eb602 100644 --- a/sync-for-payables/pkg/models/operations/unlinkconnection.go +++ b/sync-for-payables/pkg/models/operations/unlinkconnection.go @@ -3,7 +3,7 @@ package operations import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" ) type UnlinkConnectionUpdateConnection struct { diff --git a/sync-for-payables/pkg/models/operations/updatecompany.go b/sync-for-payables/pkg/models/operations/updatecompany.go index 9523e2bc9..997d649c0 100644 --- a/sync-for-payables/pkg/models/operations/updatecompany.go +++ b/sync-for-payables/pkg/models/operations/updatecompany.go @@ -3,7 +3,7 @@ package operations import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" ) type UpdateCompanyRequest struct { diff --git a/sync-for-payables/pkg/models/operations/uploadbillattachment.go b/sync-for-payables/pkg/models/operations/uploadbillattachment.go index 5a273a462..a2cb6ec18 100644 --- a/sync-for-payables/pkg/models/operations/uploadbillattachment.go +++ b/sync-for-payables/pkg/models/operations/uploadbillattachment.go @@ -3,7 +3,7 @@ package operations import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" ) type UploadBillAttachmentRequest struct { diff --git a/sync-for-payables/pkg/models/sdkerrors/errormessage.go b/sync-for-payables/pkg/models/sdkerrors/errormessage.go index b27992ae0..9533c3b59 100644 --- a/sync-for-payables/pkg/models/sdkerrors/errormessage.go +++ b/sync-for-payables/pkg/models/sdkerrors/errormessage.go @@ -4,10 +4,10 @@ package sdkerrors import ( "encoding/json" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" ) -// ErrorMessage - The request made is not valid. +// ErrorMessage - Your `query` parameter was not correctly formed type ErrorMessage struct { // The HTTP status code returned by the error. StatusCode *int64 `json:"statusCode,omitempty"` diff --git a/sync-for-payables/pkg/models/shared/bill.go b/sync-for-payables/pkg/models/shared/bill.go index 7e52350e0..07fdb55ff 100644 --- a/sync-for-payables/pkg/models/shared/bill.go +++ b/sync-for-payables/pkg/models/shared/bill.go @@ -3,7 +3,7 @@ package shared import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/utils" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/utils" "github.com/ericlagergren/decimal" ) @@ -66,7 +66,7 @@ type Bill struct { TotalAmount *decimal.Big `decimal:"number" json:"totalAmount,omitempty"` // Amount outstanding on the bill. AmountDue *decimal.Big `decimal:"number" json:"amountDue,omitempty"` - SourceModifiedDate *One `json:"sourceModifiedDate,omitempty"` + SourceModifiedDate *string `json:"sourceModifiedDate,omitempty"` } func (b Bill) MarshalJSON() ([]byte, error) { @@ -157,7 +157,7 @@ func (o *Bill) GetAmountDue() *decimal.Big { return o.AmountDue } -func (o *Bill) GetSourceModifiedDate() *One { +func (o *Bill) GetSourceModifiedDate() *string { if o == nil { return nil } diff --git a/sync-for-payables/pkg/models/shared/billlineitem.go b/sync-for-payables/pkg/models/shared/billlineitem.go index 0afebb8fd..f99f9f7ea 100644 --- a/sync-for-payables/pkg/models/shared/billlineitem.go +++ b/sync-for-payables/pkg/models/shared/billlineitem.go @@ -3,7 +3,7 @@ package shared import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/utils" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/utils" "github.com/ericlagergren/decimal" ) diff --git a/sync-for-payables/pkg/models/shared/billpayment.go b/sync-for-payables/pkg/models/shared/billpayment.go index 037ee4dcb..793c053cb 100644 --- a/sync-for-payables/pkg/models/shared/billpayment.go +++ b/sync-for-payables/pkg/models/shared/billpayment.go @@ -3,7 +3,7 @@ package shared import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/utils" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/utils" "github.com/ericlagergren/decimal" ) diff --git a/sync-for-payables/pkg/models/shared/billpaymentprototype.go b/sync-for-payables/pkg/models/shared/billpaymentprototype.go index 85efdae63..2228c5132 100644 --- a/sync-for-payables/pkg/models/shared/billpaymentprototype.go +++ b/sync-for-payables/pkg/models/shared/billpaymentprototype.go @@ -3,7 +3,7 @@ package shared import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/utils" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/utils" "github.com/ericlagergren/decimal" ) diff --git a/sync-for-payables/pkg/models/shared/billprototype.go b/sync-for-payables/pkg/models/shared/billprototype.go index c12127b40..087e2ecb7 100644 --- a/sync-for-payables/pkg/models/shared/billprototype.go +++ b/sync-for-payables/pkg/models/shared/billprototype.go @@ -3,7 +3,7 @@ package shared import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/utils" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/utils" "github.com/ericlagergren/decimal" ) diff --git a/sync-for-payables/pkg/models/shared/company.go b/sync-for-payables/pkg/models/shared/company.go index 0f4938dd8..592fca09c 100644 --- a/sync-for-payables/pkg/models/shared/company.go +++ b/sync-for-payables/pkg/models/shared/company.go @@ -2,8 +2,8 @@ package shared -// Tags - A collection of user-defined key-value pairs that store custom metadata against the company. -type Tags struct { +// CompanyTags - A collection of user-defined key-value pairs that store custom metadata against the company. +type CompanyTags struct { } // Company - In Codat, a company represents a business sharing access to their data. Each company can have multiple [connections](https://docs.codat.io/sync-for-payables-api#/schemas/Connection) to different data sources such as one connection to [Xero](https://docs.codat.io/integrations/accounting/xero/accounting-xero) for accounting data, two connections to [Plaid](https://docs.codat.io/integrations/banking/plaid/banking-plaid) for two bank accounts and a connection to [Zettle](https://docs.codat.io/integrations/commerce/zettle/commerce-zettle) for POS data. @@ -62,8 +62,10 @@ type Company struct { Created *string `json:"created,omitempty"` // Name of user that created the company in Codat. CreatedByUserName *string `json:"createdByUserName,omitempty"` + // An array of products that are currently enabled for the company. + Products []string `json:"products,omitempty"` // A collection of user-defined key-value pairs that store custom metadata against the company. - Tags *Tags `json:"tags,omitempty"` + Tags *CompanyTags `json:"tags,omitempty"` DataConnections []Connection `json:"dataConnections,omitempty"` } @@ -116,7 +118,14 @@ func (o *Company) GetCreatedByUserName() *string { return o.CreatedByUserName } -func (o *Company) GetTags() *Tags { +func (o *Company) GetProducts() []string { + if o == nil { + return nil + } + return o.Products +} + +func (o *Company) GetTags() *CompanyTags { if o == nil { return nil } diff --git a/sync-for-payables/pkg/models/shared/companyrequestbody.go b/sync-for-payables/pkg/models/shared/companyrequestbody.go index 7e70aaf5a..2425ebc02 100644 --- a/sync-for-payables/pkg/models/shared/companyrequestbody.go +++ b/sync-for-payables/pkg/models/shared/companyrequestbody.go @@ -2,25 +2,13 @@ package shared -type GroupReference struct { - // Unique identifier for the group. - ID *string `json:"id,omitempty"` -} - -func (o *GroupReference) GetID() *string { - if o == nil { - return nil - } - return o.ID -} - type CompanyRequestBody struct { // Name of company being connected. Name string `json:"name"` // Additional information about the company. This can be used to store foreign IDs, references, etc. Description *string `json:"description,omitempty"` - // Reference to the groups that the company is assigned to. - Groups []GroupReference `json:"groups,omitempty"` + // A collection of user-defined key-value pairs that store custom metadata against the company. + Tags *Tags `json:"tags,omitempty"` } func (o *CompanyRequestBody) GetName() string { @@ -37,9 +25,9 @@ func (o *CompanyRequestBody) GetDescription() *string { return o.Description } -func (o *CompanyRequestBody) GetGroups() []GroupReference { +func (o *CompanyRequestBody) GetTags() *Tags { if o == nil { return nil } - return o.Groups + return o.Tags } diff --git a/sync-for-payables/pkg/models/shared/connection.go b/sync-for-payables/pkg/models/shared/connection.go index b023ad26a..089a17801 100644 --- a/sync-for-payables/pkg/models/shared/connection.go +++ b/sync-for-payables/pkg/models/shared/connection.go @@ -118,7 +118,6 @@ type Connection struct { Created string `json:"created"` DataConnectionErrors []DataConnectionError `json:"dataConnectionErrors,omitempty"` ConnectionInfo map[string]string `json:"connectionInfo,omitempty"` - AdditionalProperties any `json:"additionalProperties,omitempty"` } func (o *Connection) GetID() string { @@ -204,10 +203,3 @@ func (o *Connection) GetConnectionInfo() map[string]string { } return o.ConnectionInfo } - -func (o *Connection) GetAdditionalProperties() any { - if o == nil { - return nil - } - return o.AdditionalProperties -} diff --git a/sync-for-payables/pkg/models/shared/one.go b/sync-for-payables/pkg/models/shared/one.go deleted file mode 100644 index fbcdcd0ba..000000000 --- a/sync-for-payables/pkg/models/shared/one.go +++ /dev/null @@ -1,14 +0,0 @@ -// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. - -package shared - -type One struct { - SourceModifiedDate *string `json:"sourceModifiedDate,omitempty"` -} - -func (o *One) GetSourceModifiedDate() *string { - if o == nil { - return nil - } - return o.SourceModifiedDate -} diff --git a/sync-for-payables/pkg/models/shared/supplier.go b/sync-for-payables/pkg/models/shared/supplier.go index c60caeda5..920f8bc7c 100644 --- a/sync-for-payables/pkg/models/shared/supplier.go +++ b/sync-for-payables/pkg/models/shared/supplier.go @@ -3,7 +3,7 @@ package shared import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/utils" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/utils" "github.com/ericlagergren/decimal" ) @@ -29,7 +29,7 @@ type Supplier struct { Balance *decimal.Big `decimal:"number" json:"balance,omitempty"` // Default currency the supplier's transactional data is recorded in. DefaultCurrency *string `json:"defaultCurrency,omitempty"` - SourceModifiedDate *One `json:"sourceModifiedDate,omitempty"` + SourceModifiedDate *string `json:"sourceModifiedDate,omitempty"` } func (s Supplier) MarshalJSON() ([]byte, error) { @@ -106,7 +106,7 @@ func (o *Supplier) GetDefaultCurrency() *string { return o.DefaultCurrency } -func (o *Supplier) GetSourceModifiedDate() *One { +func (o *Supplier) GetSourceModifiedDate() *string { if o == nil { return nil } diff --git a/sync-for-payables/pkg/models/shared/supplierprototype.go b/sync-for-payables/pkg/models/shared/supplierprototype.go index d67f03635..2b3f128b0 100644 --- a/sync-for-payables/pkg/models/shared/supplierprototype.go +++ b/sync-for-payables/pkg/models/shared/supplierprototype.go @@ -3,7 +3,7 @@ package shared import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/utils" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/utils" "github.com/ericlagergren/decimal" ) diff --git a/sync-for-payables/pkg/models/shared/tags.go b/sync-for-payables/pkg/models/shared/tags.go new file mode 100644 index 000000000..f0600c525 --- /dev/null +++ b/sync-for-payables/pkg/models/shared/tags.go @@ -0,0 +1,7 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package shared + +// Tags - A collection of user-defined key-value pairs that store custom metadata against the company. +type Tags struct { +} diff --git a/sync-for-payables/pkg/models/shared/taxratemappingoption.go b/sync-for-payables/pkg/models/shared/taxratemappingoption.go index 4688c1d5f..e6327a788 100644 --- a/sync-for-payables/pkg/models/shared/taxratemappingoption.go +++ b/sync-for-payables/pkg/models/shared/taxratemappingoption.go @@ -5,7 +5,7 @@ package shared import ( "encoding/json" "fmt" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/utils" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/utils" "github.com/ericlagergren/decimal" ) diff --git a/sync-for-payables/pkg/models/webhooks/clientratelimitreached.go b/sync-for-payables/pkg/models/webhooks/clientratelimitreached.go index 93962f189..4c38eaed0 100644 --- a/sync-for-payables/pkg/models/webhooks/clientratelimitreached.go +++ b/sync-for-payables/pkg/models/webhooks/clientratelimitreached.go @@ -3,7 +3,7 @@ package webhooks import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" ) type ClientRateLimitReachedResponse1 struct { diff --git a/sync-for-payables/pkg/models/webhooks/clientratelimitreset.go b/sync-for-payables/pkg/models/webhooks/clientratelimitreset.go index c5c7ff1cf..5d8ebf743 100644 --- a/sync-for-payables/pkg/models/webhooks/clientratelimitreset.go +++ b/sync-for-payables/pkg/models/webhooks/clientratelimitreset.go @@ -3,7 +3,7 @@ package webhooks import ( - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" ) type ClientRateLimitResetResponse1 struct { diff --git a/sync-for-payables/pkg/utils/form.go b/sync-for-payables/pkg/utils/form.go index 2864977cb..27d9d6c43 100644 --- a/sync-for-payables/pkg/utils/form.go +++ b/sync-for-payables/pkg/utils/form.go @@ -12,7 +12,7 @@ import ( "github.com/ericlagergren/decimal" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/types" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/types" ) func populateForm(paramName string, explode bool, objType reflect.Type, objValue reflect.Value, delimiter string, getFieldName func(reflect.StructField) string) url.Values { diff --git a/sync-for-payables/pkg/utils/json.go b/sync-for-payables/pkg/utils/json.go index bac99dded..97b5a0bb7 100644 --- a/sync-for-payables/pkg/utils/json.go +++ b/sync-for-payables/pkg/utils/json.go @@ -13,7 +13,7 @@ import ( "time" "unsafe" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/types" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/types" "github.com/ericlagergren/decimal" ) diff --git a/sync-for-payables/pkg/utils/pathparams.go b/sync-for-payables/pkg/utils/pathparams.go index 0c655dc74..fe5012059 100644 --- a/sync-for-payables/pkg/utils/pathparams.go +++ b/sync-for-payables/pkg/utils/pathparams.go @@ -13,7 +13,7 @@ import ( "github.com/ericlagergren/decimal" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/types" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/types" ) func GenerateURL(_ context.Context, serverURL, path string, pathParams interface{}, globals interface{}) (string, error) { diff --git a/sync-for-payables/pkg/utils/queryparams.go b/sync-for-payables/pkg/utils/queryparams.go index ac0f5a8c5..cfab68bc4 100644 --- a/sync-for-payables/pkg/utils/queryparams.go +++ b/sync-for-payables/pkg/utils/queryparams.go @@ -14,7 +14,7 @@ import ( "github.com/ericlagergren/decimal" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/types" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/types" ) func PopulateQueryParams(_ context.Context, req *http.Request, queryParams interface{}, globals interface{}) error { diff --git a/sync-for-payables/pkg/utils/retries.go b/sync-for-payables/pkg/utils/retries.go index 82b0417a9..e8b4c8f69 100644 --- a/sync-for-payables/pkg/utils/retries.go +++ b/sync-for-payables/pkg/utils/retries.go @@ -7,7 +7,7 @@ import ( "errors" "fmt" "github.com/cenkalti/backoff/v4" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/retry" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/retry" "net/http" "net/url" "strconv" diff --git a/sync-for-payables/suppliers.go b/sync-for-payables/suppliers.go index d10f011e1..f14c22117 100644 --- a/sync-for-payables/suppliers.go +++ b/sync-for-payables/suppliers.go @@ -7,12 +7,12 @@ import ( "context" "fmt" "github.com/cenkalti/backoff/v4" - "github.com/codatio/client-sdk-go/sync-for-payables/internal/hooks" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/operations" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/sdkerrors" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/models/shared" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/retry" - "github.com/codatio/client-sdk-go/sync-for-payables/pkg/utils" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/internal/hooks" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/operations" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/sdkerrors" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/models/shared" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/retry" + "github.com/codatio/client-sdk-go/sync-for-payables/v2/pkg/utils" "io" "net/http" )