From b825bc439e63ced2ab1f619e59e13d61dc87099e Mon Sep 17 00:00:00 2001 From: speakeasybot Date: Thu, 13 Aug 2026 00:31:04 +0000 Subject: [PATCH 1/2] ## Python SDK Changes Detected: * `apideck.accounting.sales_receipts.list()`: **Added** * `apideck.accounting.sales_receipts.create()`: **Added** * `apideck.accounting.sales_receipts.get()`: **Added** * `apideck.accounting.sales_receipts.update()`: **Added** * `apideck.accounting.sales_receipts.delete()`: **Added** * `apideck.accounting.payment_methods.list()`: **Added** * `apideck.accounting.payment_methods.create()`: **Added** * `apideck.accounting.payment_methods.get()`: **Added** * `apideck.accounting.payment_methods.update()`: **Added** * `apideck.accounting.payment_methods.delete()`: **Added** * `apideck.accounting.tax_rates.list()`: `response.data.[].custom_fields.[]` **Changed** * `apideck.accounting.tax_rates.create()`: * `request.custom_fields.[]` **Changed** * `apideck.accounting.tax_rates.get()`: `response.data.custom_fields.[]` **Changed** * `apideck.accounting.tax_rates.update()`: * `request.custom_fields.[]` **Changed** * `apideck.accounting.bills.list()`: `response.data.[].custom_fields.[]` **Changed** * `apideck.accounting.bills.create()`: * `request.custom_fields.[]` **Changed** * `apideck.accounting.bills.get()`: `response.data.custom_fields.[]` **Changed** * `apideck.accounting.bills.update()`: * `request.custom_fields.[]` **Changed** * `apideck.accounting.invoices.list()`: `response.data.[].line_items.[].custom_fields.[]` **Changed** * `apideck.accounting.invoices.create()`: * `request.line_items.[].custom_fields.[]` **Changed** * `apideck.accounting.invoices.get()`: `response.data.line_items.[].custom_fields.[]` **Changed** * `apideck.accounting.invoices.update()`: * `request.line_items.[].custom_fields.[]` **Changed** * `apideck.accounting.ledger_accounts.list()`: `response.data.[].custom_fields.[]` **Changed** * `apideck.accounting.ledger_accounts.create()`: * `request.custom_fields.[]` **Changed** * `apideck.accounting.ledger_accounts.get()`: `response.data.custom_fields.[]` **Changed** * `apideck.accounting.ledger_accounts.update()`: * `request.custom_fields.[]` **Changed** * `apideck.accounting.credit_notes.list()`: `response.data.[].line_items.[].custom_fields.[]` **Changed** * `apideck.accounting.credit_notes.create()`: * `request.line_items.[].custom_fields.[]` **Changed** * `apideck.accounting.credit_notes.get()`: `response.data.line_items.[].custom_fields.[]` **Changed** * `apideck.accounting.credit_notes.update()`: * `request.line_items.[].custom_fields.[]` **Changed** * `apideck.accounting.customers.list()`: `response.data.[].custom_fields.[]` **Changed** * `apideck.accounting.customers.create()`: * `request.custom_fields.[]` **Changed** * `apideck.accounting.customers.get()`: `response.data.custom_fields.[]` **Changed** * `apideck.accounting.customers.update()`: * `request.custom_fields.[]` **Changed** * `apideck.accounting.suppliers.list()`: `response.data.[].custom_fields.[]` **Changed** * `apideck.accounting.suppliers.create()`: * `request.custom_fields.[]` **Changed** * `apideck.accounting.suppliers.get()`: `response.data.custom_fields.[]` **Changed** * `apideck.accounting.suppliers.update()`: * `request.custom_fields.[]` **Changed** * `apideck.accounting.payments.list()`: `response.data.[].custom_fields.[]` **Changed** * `apideck.accounting.payments.create()`: * `request.custom_fields.[]` **Changed** * `apideck.accounting.payments.get()`: `response.data.custom_fields.[]` **Changed** * `apideck.accounting.payments.update()`: * `request.custom_fields.[]` **Changed** * `apideck.accounting.refunds.list()`: `response.data.[].line_items.[].custom_fields.[]` **Changed** * `apideck.accounting.refunds.create()`: * `request.line_items.[].custom_fields.[]` **Changed** * `apideck.accounting.refunds.get()`: `response.data.line_items.[].custom_fields.[]` **Changed** * `apideck.accounting.refunds.update()`: * `request.line_items.[].custom_fields.[]` **Changed** * `apideck.accounting.company_info.get()`: `response.data.default_sales_tax.custom_fields.[]` **Changed** * `apideck.accounting.journal_entries.list()`: `response.data.[].custom_fields.[]` **Changed** * `apideck.accounting.journal_entries.create()`: * `request.custom_fields.[]` **Changed** * `apideck.accounting.journal_entries.get()`: `response.data.custom_fields.[]` **Changed** * `apideck.accounting.journal_entries.update()`: * `request.custom_fields.[]` **Changed** * `apideck.accounting.general_ledger_transactions.list()`: `response.data.[].custom_fields.[]` **Changed** * `apideck.accounting.general_ledger_transactions.get()`: `response.data.custom_fields.[]` **Changed** * `apideck.accounting.purchase_orders.list()`: `response.data.[].line_items.[].custom_fields.[]` **Changed** * `apideck.accounting.purchase_orders.create()`: * `request.line_items.[].custom_fields.[]` **Changed** * `apideck.accounting.purchase_orders.get()`: `response.data.line_items.[].custom_fields.[]` **Changed** * `apideck.accounting.purchase_orders.update()`: * `request.line_items.[].custom_fields.[]` **Changed** * `apideck.accounting.attachments.list()`: `response.data.[].file_url` **Added** * `apideck.accounting.attachments.get()`: `response.data.file_url` **Added** * `apideck.accounting.attachments.download()`: `request.follow_redirects` **Added** * `apideck.accounting.bank_accounts.list()`: `response.data.[].custom_fields.[]` **Changed** * `apideck.accounting.bank_accounts.create()`: * `request.custom_fields.[]` **Changed** * `apideck.accounting.bank_accounts.get()`: `response.data.custom_fields.[]` **Changed** * `apideck.accounting.bank_accounts.update()`: * `request.custom_fields.[]` **Changed** * `apideck.accounting.bill_payments.list()`: `response.data.[].custom_fields.[]` **Changed** * `apideck.accounting.bill_payments.create()`: * `request.custom_fields.[]` **Changed** * `apideck.accounting.bill_payments.get()`: `response.data.custom_fields.[]` **Changed** * `apideck.accounting.bill_payments.update()`: * `request.custom_fields.[]` **Changed** * `apideck.accounting.expenses.list()`: `response.data.[].custom_fields.[]` **Changed** * `apideck.accounting.expenses.create()`: * `request.custom_fields.[]` **Changed** * `apideck.accounting.expenses.get()`: `response.data.custom_fields.[]` **Changed** * `apideck.accounting.expenses.update()`: * `request.custom_fields.[]` **Changed** * `apideck.accounting.bank_feed_accounts.list()`: `response.data.[]` **Changed** * `apideck.accounting.bank_feed_accounts.create()`: `request` **Changed** * `apideck.accounting.bank_feed_accounts.get()`: `response.data` **Changed** * `apideck.accounting.bank_feed_accounts.update()`: `request` **Changed** * `apideck.accounting.bank_feed_statements.list()`: `response.data.[].transactions.[].merchant_category_code` **Added** * `apideck.accounting.bank_feed_statements.create()`: * `request.transactions.[].merchant_category_code` **Added** * `apideck.accounting.bank_feed_statements.get()`: `response.data.transactions.[].merchant_category_code` **Added** * `apideck.accounting.bank_feed_statements.update()`: * `request.transactions.[].merchant_category_code` **Added** * `apideck.accounting.quotes.list()`: `response.data.[].line_items.[].custom_fields.[]` **Changed** * `apideck.accounting.quotes.create()`: * `request.line_items.[].custom_fields.[]` **Changed** * `apideck.accounting.quotes.get()`: `response.data.line_items.[].custom_fields.[]` **Changed** * `apideck.accounting.quotes.update()`: * `request.line_items.[].custom_fields.[]` **Changed** * `apideck.accounting.projects.list()`: `response.data.[].custom_fields.[]` **Changed** * `apideck.accounting.projects.create()`: * `request.custom_fields.[]` **Changed** * `apideck.accounting.projects.get()`: `response.data.custom_fields.[]` **Changed** * `apideck.accounting.projects.update()`: * `request.custom_fields.[]` **Changed** * `apideck.accounting.employees.list()`: `response.data.[].custom_fields.[]` **Changed** * `apideck.accounting.employees.create()`: * `request.custom_fields.[]` **Changed** * `apideck.accounting.employees.get()`: `response.data.custom_fields.[]` **Changed** * `apideck.accounting.employees.update()`: * `request.custom_fields.[]` **Changed** * `apideck.accounting.expense_reports.list()`: `response.data.[].custom_fields.[]` **Changed** * `apideck.accounting.expense_reports.create()`: * `request.custom_fields.[]` **Changed** * `apideck.accounting.expense_reports.get()`: `response.data.custom_fields.[]` **Changed** * `apideck.accounting.expense_reports.update()`: * `request.custom_fields.[]` **Changed** * `apideck.ats.jobs.list()`: `response.data.[].custom_fields.[]` **Changed** * `apideck.ats.jobs.create()`: * `request.custom_fields.[]` **Changed** * `apideck.ats.jobs.get()`: `response.data.custom_fields.[]` **Changed** * `apideck.ats.jobs.update()`: * `request.custom_fields.[]` **Changed** * `apideck.ats.applicants.list()`: `response.data.[].custom_fields.[]` **Changed** * `apideck.ats.applicants.create()`: * `request.custom_fields.[]` **Changed** * `apideck.ats.applicants.get()`: `response.data.custom_fields.[]` **Changed** * `apideck.ats.applicants.update()`: * `request.custom_fields.[]` **Changed** * `apideck.crm.companies.list()`: `response.data.[].custom_fields.[]` **Changed** * `apideck.crm.companies.create()`: * `request.custom_fields.[]` **Changed** * `apideck.crm.companies.get()`: `response.data.custom_fields.[]` **Changed** * `apideck.crm.companies.update()`: * `request.custom_fields.[]` **Changed** * `apideck.crm.contacts.list()`: `response.data.[].custom_fields.[]` **Changed** * `apideck.crm.contacts.create()`: * `request.custom_fields.[]` **Changed** * `apideck.crm.contacts.get()`: `response.data.custom_fields.[]` **Changed** * `apideck.crm.contacts.update()`: * `request.custom_fields.[]` **Changed** * `apideck.crm.opportunities.list()`: `response.data.[].custom_fields.[]` **Changed** * `apideck.crm.opportunities.create()`: * `request.custom_fields.[]` **Changed** * `apideck.crm.opportunities.get()`: `response.data.custom_fields.[]` **Changed** * `apideck.crm.opportunities.update()`: * `request.custom_fields.[]` **Changed** * `apideck.crm.leads.list()`: `response.data.[].custom_fields.[]` **Changed** * `apideck.crm.leads.create()`: * `request.custom_fields.[]` **Changed** * `apideck.crm.leads.get()`: `response.data.custom_fields.[]` **Changed** * `apideck.crm.leads.update()`: * `request.custom_fields.[]` **Changed** * `apideck.crm.lists.list()`: `response.data.[].custom_fields.[]` **Changed** * `apideck.crm.lists.get()`: `response.data.custom_fields.[]` **Changed** * `apideck.crm.activities.list()`: `response.data.[].custom_fields.[]` **Changed** * `apideck.crm.activities.create()`: * `request.custom_fields.[]` **Changed** * `apideck.crm.activities.get()`: `response.data.custom_fields.[]` **Changed** * `apideck.crm.activities.update()`: * `request.custom_fields.[]` **Changed** * `apideck.file_storage.files.download()`: `request.follow_redirects` **Added** * `apideck.hris.employees.list()`: `response.data.[].custom_fields.[]` **Changed** * `apideck.hris.employees.create()`: * `request.custom_fields.[]` **Changed** * `apideck.hris.employees.get()`: `response.data.custom_fields.[]` **Changed** * `apideck.hris.employees.update()`: * `request.custom_fields.[]` **Changed** * `apideck.hris.employee_schedules.list()`: `response.data.employee.custom_fields.[]` **Changed** * `apideck.proxy.get()`: `request.follow_redirects` **Added** * `apideck.proxy.options()`: `request.follow_redirects` **Added** * `apideck.proxy.post()`: `request.follow_redirects` **Added** * `apideck.proxy.put()`: `request.follow_redirects` **Added** * `apideck.proxy.patch()`: `request.follow_redirects` **Added** * `apideck.proxy.delete()`: `request.follow_redirects` **Added** --- .speakeasy/gen.lock | 663 +++++- .speakeasy/gen.yaml | 2 +- .speakeasy/workflow.lock | 14 +- README.md | 20 +- RELEASES.md | 12 +- .../accountingattachmentsdownloadrequest.md | 3 +- .../accountingattachmentsdownloadresponse.md | 10 +- docs/models/accountingpaymentmethod.md | 19 + docs/models/accountingpaymentmethodinput.md | 12 + .../accountingpaymentmethodsaddglobals.md | 9 + .../accountingpaymentmethodsaddrequest.md | 12 + .../accountingpaymentmethodsaddresponse.md | 10 + .../accountingpaymentmethodsallglobals.md | 9 + .../accountingpaymentmethodsallrequest.md | 15 + .../accountingpaymentmethodsallresponse.md | 10 + .../accountingpaymentmethodsdeleteglobals.md | 9 + .../accountingpaymentmethodsdeleterequest.md | 12 + .../accountingpaymentmethodsdeleteresponse.md | 10 + .../accountingpaymentmethodsoneglobals.md | 9 + .../accountingpaymentmethodsonerequest.md | 13 + .../accountingpaymentmethodsoneresponse.md | 10 + docs/models/accountingpaymentmethodstatus.md | 11 + .../accountingpaymentmethodsupdateglobals.md | 9 + .../accountingpaymentmethodsupdaterequest.md | 13 + .../accountingpaymentmethodsupdateresponse.md | 10 + docs/models/accountingpaymentmethodtype.md | 17 + .../accountingsalesreceiptsaddglobals.md | 9 + .../accountingsalesreceiptsaddrequest.md | 13 + .../accountingsalesreceiptsaddresponse.md | 10 + .../accountingsalesreceiptsallglobals.md | 9 + .../accountingsalesreceiptsallrequest.md | 18 + .../accountingsalesreceiptsallresponse.md | 10 + .../accountingsalesreceiptsdeleteglobals.md | 9 + .../accountingsalesreceiptsdeleterequest.md | 13 + .../accountingsalesreceiptsdeleteresponse.md | 10 + .../accountingsalesreceiptsoneglobals.md | 9 + .../accountingsalesreceiptsonerequest.md | 14 + .../accountingsalesreceiptsoneresponse.md | 10 + .../accountingsalesreceiptsupdateglobals.md | 9 + .../accountingsalesreceiptsupdaterequest.md | 14 + .../accountingsalesreceiptsupdateresponse.md | 10 + docs/models/attachment.md | 1 + docs/models/bankfeedaccount.md | 4 + docs/models/bankfeedaccountinput.md | 4 + docs/models/createpaymentmethodresponse.md | 16 + docs/models/createsalesreceiptresponse.md | 16 + docs/models/customfield1.md | 13 +- docs/models/customfield2.md | 13 +- docs/models/deletepaymentmethodresponse.md | 16 + docs/models/deletesalesreceiptresponse.md | 16 + .../models/filestoragefilesdownloadrequest.md | 3 +- .../filestoragefilesdownloadresponse.md | 10 +- docs/models/filestoragefilesexportresponse.md | 10 +- docs/models/getpaymentmethodresponse.md | 17 + docs/models/getpaymentmethodsresponse.md | 18 + docs/models/getsalesreceiptresponse.md | 17 + docs/models/getsalesreceiptsresponse.md | 18 + docs/models/proxydeleteproxyrequest.md | 19 +- docs/models/proxydeleteproxyresponse.md | 28 +- docs/models/proxygetproxyrequest.md | 19 +- docs/models/proxygetproxyresponse.md | 28 +- docs/models/proxyoptionsproxyrequest.md | 19 +- docs/models/proxyoptionsproxyresponse.md | 28 +- docs/models/proxypatchproxyrequest.md | 21 +- docs/models/proxypatchproxyresponse.md | 28 +- docs/models/proxypostproxyrequest.md | 21 +- docs/models/proxypostproxyresponse.md | 28 +- docs/models/proxyputproxyrequest.md | 21 +- docs/models/proxyputproxyresponse.md | 28 +- docs/models/salesreceipt.md | 40 + docs/models/salesreceiptinput.md | 34 + docs/models/salesreceiptsfilter.md | 9 + docs/models/salesreceiptssort.md | 9 + docs/models/salesreceiptssortby.md | 11 + docs/models/transactions.md | 21 +- docs/models/updatepaymentmethodresponse.md | 16 + docs/models/updatesalesreceiptresponse.md | 16 + docs/sdks/attachments/README.md | 3 +- docs/sdks/bankfeedaccounts/README.md | 12 +- docs/sdks/files/README.md | 3 +- docs/sdks/paymentmethods/README.md | 322 +++ docs/sdks/proxy/README.md | 144 +- docs/sdks/salesreceipts/README.md | 689 ++++++ pyproject.toml | 2 +- src/apideck_unify/_version.py | 6 +- src/apideck_unify/accounting.py | 10 + src/apideck_unify/attachments.py | 6 + src/apideck_unify/bankfeedaccounts.py | 48 + src/apideck_unify/files.py | 6 + src/apideck_unify/models/__init__.py | 326 +++ .../accounting_attachmentsdownloadop.py | 22 +- .../models/accounting_paymentmethodsaddop.py | 113 + .../models/accounting_paymentmethodsallop.py | 178 ++ .../accounting_paymentmethodsdeleteop.py | 110 + .../models/accounting_paymentmethodsoneop.py | 155 ++ .../accounting_paymentmethodsupdateop.py | 121 + .../models/accounting_salesreceiptsaddop.py | 119 + .../models/accounting_salesreceiptsallop.py | 209 ++ .../accounting_salesreceiptsdeleteop.py | 119 + .../models/accounting_salesreceiptsoneop.py | 171 ++ .../accounting_salesreceiptsupdateop.py | 127 + .../models/accountingpaymentmethod.py | 265 +++ src/apideck_unify/models/attachment.py | 7 + src/apideck_unify/models/bankfeedaccount.py | 61 +- src/apideck_unify/models/bankfeedstatement.py | 41 + .../models/createpaymentmethodresponse.py | 91 + .../models/createsalesreceiptresponse.py | 91 + src/apideck_unify/models/customfield.py | 18 +- .../models/deletepaymentmethodresponse.py | 91 + .../models/deletesalesreceiptresponse.py | 91 + .../models/filestorage_filesdownloadop.py | 21 +- .../models/filestorage_filesexportop.py | 4 +- .../models/getpaymentmethodresponse.py | 98 + .../models/getpaymentmethodsresponse.py | 104 + .../models/getsalesreceiptresponse.py | 95 + .../models/getsalesreceiptsresponse.py | 101 + .../models/proxy_deleteproxyop.py | 33 +- src/apideck_unify/models/proxy_getproxyop.py | 33 +- .../models/proxy_optionsproxyop.py | 33 +- .../models/proxy_patchproxyop.py | 33 +- src/apideck_unify/models/proxy_postproxyop.py | 33 +- src/apideck_unify/models/proxy_putproxyop.py | 33 +- src/apideck_unify/models/salesreceipt.py | 294 +++ .../models/salesreceipt_input.py | 257 ++ .../models/salesreceiptsfilter.py | 21 + src/apideck_unify/models/salesreceiptssort.py | 60 + .../models/updatepaymentmethodresponse.py | 91 + .../models/updatesalesreceiptresponse.py | 91 + src/apideck_unify/paymentmethods.py | 1602 +++++++++++++ src/apideck_unify/proxy.py | 36 + src/apideck_unify/salesreceipts.py | 2067 +++++++++++++++++ 131 files changed, 10236 insertions(+), 427 deletions(-) create mode 100644 docs/models/accountingpaymentmethod.md create mode 100644 docs/models/accountingpaymentmethodinput.md create mode 100644 docs/models/accountingpaymentmethodsaddglobals.md create mode 100644 docs/models/accountingpaymentmethodsaddrequest.md create mode 100644 docs/models/accountingpaymentmethodsaddresponse.md create mode 100644 docs/models/accountingpaymentmethodsallglobals.md create mode 100644 docs/models/accountingpaymentmethodsallrequest.md create mode 100644 docs/models/accountingpaymentmethodsallresponse.md create mode 100644 docs/models/accountingpaymentmethodsdeleteglobals.md create mode 100644 docs/models/accountingpaymentmethodsdeleterequest.md create mode 100644 docs/models/accountingpaymentmethodsdeleteresponse.md create mode 100644 docs/models/accountingpaymentmethodsoneglobals.md create mode 100644 docs/models/accountingpaymentmethodsonerequest.md create mode 100644 docs/models/accountingpaymentmethodsoneresponse.md create mode 100644 docs/models/accountingpaymentmethodstatus.md create mode 100644 docs/models/accountingpaymentmethodsupdateglobals.md create mode 100644 docs/models/accountingpaymentmethodsupdaterequest.md create mode 100644 docs/models/accountingpaymentmethodsupdateresponse.md create mode 100644 docs/models/accountingpaymentmethodtype.md create mode 100644 docs/models/accountingsalesreceiptsaddglobals.md create mode 100644 docs/models/accountingsalesreceiptsaddrequest.md create mode 100644 docs/models/accountingsalesreceiptsaddresponse.md create mode 100644 docs/models/accountingsalesreceiptsallglobals.md create mode 100644 docs/models/accountingsalesreceiptsallrequest.md create mode 100644 docs/models/accountingsalesreceiptsallresponse.md create mode 100644 docs/models/accountingsalesreceiptsdeleteglobals.md create mode 100644 docs/models/accountingsalesreceiptsdeleterequest.md create mode 100644 docs/models/accountingsalesreceiptsdeleteresponse.md create mode 100644 docs/models/accountingsalesreceiptsoneglobals.md create mode 100644 docs/models/accountingsalesreceiptsonerequest.md create mode 100644 docs/models/accountingsalesreceiptsoneresponse.md create mode 100644 docs/models/accountingsalesreceiptsupdateglobals.md create mode 100644 docs/models/accountingsalesreceiptsupdaterequest.md create mode 100644 docs/models/accountingsalesreceiptsupdateresponse.md create mode 100644 docs/models/createpaymentmethodresponse.md create mode 100644 docs/models/createsalesreceiptresponse.md create mode 100644 docs/models/deletepaymentmethodresponse.md create mode 100644 docs/models/deletesalesreceiptresponse.md create mode 100644 docs/models/getpaymentmethodresponse.md create mode 100644 docs/models/getpaymentmethodsresponse.md create mode 100644 docs/models/getsalesreceiptresponse.md create mode 100644 docs/models/getsalesreceiptsresponse.md create mode 100644 docs/models/salesreceipt.md create mode 100644 docs/models/salesreceiptinput.md create mode 100644 docs/models/salesreceiptsfilter.md create mode 100644 docs/models/salesreceiptssort.md create mode 100644 docs/models/salesreceiptssortby.md create mode 100644 docs/models/updatepaymentmethodresponse.md create mode 100644 docs/models/updatesalesreceiptresponse.md create mode 100644 docs/sdks/paymentmethods/README.md create mode 100644 docs/sdks/salesreceipts/README.md create mode 100644 src/apideck_unify/models/accounting_paymentmethodsaddop.py create mode 100644 src/apideck_unify/models/accounting_paymentmethodsallop.py create mode 100644 src/apideck_unify/models/accounting_paymentmethodsdeleteop.py create mode 100644 src/apideck_unify/models/accounting_paymentmethodsoneop.py create mode 100644 src/apideck_unify/models/accounting_paymentmethodsupdateop.py create mode 100644 src/apideck_unify/models/accounting_salesreceiptsaddop.py create mode 100644 src/apideck_unify/models/accounting_salesreceiptsallop.py create mode 100644 src/apideck_unify/models/accounting_salesreceiptsdeleteop.py create mode 100644 src/apideck_unify/models/accounting_salesreceiptsoneop.py create mode 100644 src/apideck_unify/models/accounting_salesreceiptsupdateop.py create mode 100644 src/apideck_unify/models/accountingpaymentmethod.py create mode 100644 src/apideck_unify/models/createpaymentmethodresponse.py create mode 100644 src/apideck_unify/models/createsalesreceiptresponse.py create mode 100644 src/apideck_unify/models/deletepaymentmethodresponse.py create mode 100644 src/apideck_unify/models/deletesalesreceiptresponse.py create mode 100644 src/apideck_unify/models/getpaymentmethodresponse.py create mode 100644 src/apideck_unify/models/getpaymentmethodsresponse.py create mode 100644 src/apideck_unify/models/getsalesreceiptresponse.py create mode 100644 src/apideck_unify/models/getsalesreceiptsresponse.py create mode 100644 src/apideck_unify/models/salesreceipt.py create mode 100644 src/apideck_unify/models/salesreceipt_input.py create mode 100644 src/apideck_unify/models/salesreceiptsfilter.py create mode 100644 src/apideck_unify/models/salesreceiptssort.py create mode 100644 src/apideck_unify/models/updatepaymentmethodresponse.py create mode 100644 src/apideck_unify/models/updatesalesreceiptresponse.py create mode 100644 src/apideck_unify/paymentmethods.py create mode 100644 src/apideck_unify/salesreceipts.py diff --git a/.speakeasy/gen.lock b/.speakeasy/gen.lock index 1443b016..a7c45091 100644 --- a/.speakeasy/gen.lock +++ b/.speakeasy/gen.lock @@ -1,12 +1,12 @@ lockVersion: 2.0.0 id: fca0ac3a-5f4e-452c-bbc7-2311afa8da40 management: - docChecksum: 9f3555dd6bfbb134dd1c354d722d51cd - docVersion: 10.32.0 + docChecksum: 26690dbb0bcdb613a15f7e2bb0fca1cf + docVersion: 10.38.0 speakeasyVersion: 1.656.1 generationVersion: 2.753.1 - releaseVersion: 0.36.0 - configChecksum: 1928e1a3a55bbe660fc9260c7d01431d + releaseVersion: 0.37.0 + configChecksum: 26e65832b6862f2be3dcdf586b138442 repoURL: https://github.com/apideck-libraries/sdk-python.git installationURL: https://github.com/apideck-libraries/sdk-python.git published: true @@ -367,6 +367,25 @@ generatedFiles: - docs/models/accountinglocationsupdaterequest.md - docs/models/accountinglocationsupdateresponse.md - docs/models/accountingmethod.md + - docs/models/accountingpaymentmethod.md + - docs/models/accountingpaymentmethodinput.md + - docs/models/accountingpaymentmethodsaddglobals.md + - docs/models/accountingpaymentmethodsaddrequest.md + - docs/models/accountingpaymentmethodsaddresponse.md + - docs/models/accountingpaymentmethodsallglobals.md + - docs/models/accountingpaymentmethodsallrequest.md + - docs/models/accountingpaymentmethodsallresponse.md + - docs/models/accountingpaymentmethodsdeleteglobals.md + - docs/models/accountingpaymentmethodsdeleterequest.md + - docs/models/accountingpaymentmethodsdeleteresponse.md + - docs/models/accountingpaymentmethodsoneglobals.md + - docs/models/accountingpaymentmethodsonerequest.md + - docs/models/accountingpaymentmethodsoneresponse.md + - docs/models/accountingpaymentmethodstatus.md + - docs/models/accountingpaymentmethodsupdateglobals.md + - docs/models/accountingpaymentmethodsupdaterequest.md + - docs/models/accountingpaymentmethodsupdateresponse.md + - docs/models/accountingpaymentmethodtype.md - docs/models/accountingpaymentsaddglobals.md - docs/models/accountingpaymentsaddrequest.md - docs/models/accountingpaymentsaddresponse.md @@ -446,6 +465,21 @@ generatedFiles: - docs/models/accountingrefundsupdateglobals.md - docs/models/accountingrefundsupdaterequest.md - docs/models/accountingrefundsupdateresponse.md + - docs/models/accountingsalesreceiptsaddglobals.md + - docs/models/accountingsalesreceiptsaddrequest.md + - docs/models/accountingsalesreceiptsaddresponse.md + - docs/models/accountingsalesreceiptsallglobals.md + - docs/models/accountingsalesreceiptsallrequest.md + - docs/models/accountingsalesreceiptsallresponse.md + - docs/models/accountingsalesreceiptsdeleteglobals.md + - docs/models/accountingsalesreceiptsdeleterequest.md + - docs/models/accountingsalesreceiptsdeleteresponse.md + - docs/models/accountingsalesreceiptsoneglobals.md + - docs/models/accountingsalesreceiptsonerequest.md + - docs/models/accountingsalesreceiptsoneresponse.md + - docs/models/accountingsalesreceiptsupdateglobals.md + - docs/models/accountingsalesreceiptsupdaterequest.md + - docs/models/accountingsalesreceiptsupdateresponse.md - docs/models/accountingsubsidiariesaddglobals.md - docs/models/accountingsubsidiariesaddrequest.md - docs/models/accountingsubsidiariesaddresponse.md @@ -784,12 +818,14 @@ generatedFiles: - docs/models/createmessageresponse.md - docs/models/createnoteresponse.md - docs/models/createopportunityresponse.md + - docs/models/createpaymentmethodresponse.md - docs/models/createpaymentresponse.md - docs/models/createpipelineresponse.md - docs/models/createprojectresponse.md - docs/models/createpurchaseorderresponse.md - docs/models/createquoteresponse.md - docs/models/createrefundresponse.md + - docs/models/createsalesreceiptresponse.md - docs/models/createsessionresponse.md - docs/models/createsessionresponsedata.md - docs/models/createsharedlinkresponse.md @@ -1047,12 +1083,14 @@ generatedFiles: - docs/models/deletemessageresponse.md - docs/models/deletenoteresponse.md - docs/models/deleteopportunityresponse.md + - docs/models/deletepaymentmethodresponse.md - docs/models/deletepaymentresponse.md - docs/models/deletepipelineresponse.md - docs/models/deleteprojectresponse.md - docs/models/deletepurchaseorderresponse.md - docs/models/deletequoteresponse.md - docs/models/deleterefundresponse.md + - docs/models/deletesalesreceiptresponse.md - docs/models/deletesharedlinkresponse.md - docs/models/deletesubsidiaryresponse.md - docs/models/deletesupplierresponse.md @@ -1412,6 +1450,8 @@ generatedFiles: - docs/models/getnotesresponse.md - docs/models/getopportunitiesresponse.md - docs/models/getopportunityresponse.md + - docs/models/getpaymentmethodresponse.md + - docs/models/getpaymentmethodsresponse.md - docs/models/getpaymentresponse.md - docs/models/getpaymentsresponse.md - docs/models/getpayrollresponse.md @@ -1429,6 +1469,8 @@ generatedFiles: - docs/models/getquotesresponse.md - docs/models/getrefundresponse.md - docs/models/getrefundsresponse.md + - docs/models/getsalesreceiptresponse.md + - docs/models/getsalesreceiptsresponse.md - docs/models/getsharedlinkresponse.md - docs/models/getsharedlinksresponse.md - docs/models/getstoreresponse.md @@ -1820,6 +1862,11 @@ generatedFiles: - docs/models/responsibilitymatrix.md - docs/models/salary.md - docs/models/salesdetails.md + - docs/models/salesreceipt.md + - docs/models/salesreceiptinput.md + - docs/models/salesreceiptsfilter.md + - docs/models/salesreceiptssort.md + - docs/models/salesreceiptssortby.md - docs/models/schedule.md - docs/models/schedulestatus.md - docs/models/schema.md @@ -1967,12 +2014,14 @@ generatedFiles: - docs/models/updatemessageresponse.md - docs/models/updatenoteresponse.md - docs/models/updateopportunityresponse.md + - docs/models/updatepaymentmethodresponse.md - docs/models/updatepaymentresponse.md - docs/models/updatepipelineresponse.md - docs/models/updateprojectresponse.md - docs/models/updatepurchaseorderresponse.md - docs/models/updatequoteresponse.md - docs/models/updaterefundresponse.md + - docs/models/updatesalesreceiptresponse.md - docs/models/updatesharedlinkresponse.md - docs/models/updatesubsidiaryresponse.md - docs/models/updatesupplierresponse.md @@ -2175,6 +2224,7 @@ generatedFiles: - docs/sdks/notes/README.md - docs/sdks/opportunities/README.md - docs/sdks/orders/README.md + - docs/sdks/paymentmethods/README.md - docs/sdks/payments/README.md - docs/sdks/payrolls/README.md - docs/sdks/pipelines/README.md @@ -2185,6 +2235,7 @@ generatedFiles: - docs/sdks/purchaseorders/README.md - docs/sdks/quotes/README.md - docs/sdks/refunds/README.md + - docs/sdks/salesreceipts/README.md - docs/sdks/sessions/README.md - docs/sdks/sharedlinks/README.md - docs/sdks/stores/README.md @@ -2388,6 +2439,11 @@ generatedFiles: - src/apideck_unify/models/accounting_locationsdeleteop.py - src/apideck_unify/models/accounting_locationsoneop.py - src/apideck_unify/models/accounting_locationsupdateop.py + - src/apideck_unify/models/accounting_paymentmethodsaddop.py + - src/apideck_unify/models/accounting_paymentmethodsallop.py + - src/apideck_unify/models/accounting_paymentmethodsdeleteop.py + - src/apideck_unify/models/accounting_paymentmethodsoneop.py + - src/apideck_unify/models/accounting_paymentmethodsupdateop.py - src/apideck_unify/models/accounting_paymentsaddop.py - src/apideck_unify/models/accounting_paymentsallop.py - src/apideck_unify/models/accounting_paymentsdeleteop.py @@ -2414,6 +2470,11 @@ generatedFiles: - src/apideck_unify/models/accounting_refundsdeleteop.py - src/apideck_unify/models/accounting_refundsoneop.py - src/apideck_unify/models/accounting_refundsupdateop.py + - src/apideck_unify/models/accounting_salesreceiptsaddop.py + - src/apideck_unify/models/accounting_salesreceiptsallop.py + - src/apideck_unify/models/accounting_salesreceiptsdeleteop.py + - src/apideck_unify/models/accounting_salesreceiptsoneop.py + - src/apideck_unify/models/accounting_salesreceiptsupdateop.py - src/apideck_unify/models/accounting_subsidiariesaddop.py - src/apideck_unify/models/accounting_subsidiariesallop.py - src/apideck_unify/models/accounting_subsidiariesdeleteop.py @@ -2442,6 +2503,7 @@ generatedFiles: - src/apideck_unify/models/accountingemployeesfilter.py - src/apideck_unify/models/accountinglocation.py - src/apideck_unify/models/accountinglocationsfilter.py + - src/apideck_unify/models/accountingpaymentmethod.py - src/apideck_unify/models/activitiesfilter.py - src/apideck_unify/models/activitiessort.py - src/apideck_unify/models/activity.py @@ -2594,12 +2656,14 @@ generatedFiles: - src/apideck_unify/models/createmessageresponse.py - src/apideck_unify/models/createnoteresponse.py - src/apideck_unify/models/createopportunityresponse.py + - src/apideck_unify/models/createpaymentmethodresponse.py - src/apideck_unify/models/createpaymentresponse.py - src/apideck_unify/models/createpipelineresponse.py - src/apideck_unify/models/createprojectresponse.py - src/apideck_unify/models/createpurchaseorderresponse.py - src/apideck_unify/models/createquoteresponse.py - src/apideck_unify/models/createrefundresponse.py + - src/apideck_unify/models/createsalesreceiptresponse.py - src/apideck_unify/models/createsessionresponse.py - src/apideck_unify/models/createsharedlinkresponse.py - src/apideck_unify/models/createsubsidiaryresponse.py @@ -2722,12 +2786,14 @@ generatedFiles: - src/apideck_unify/models/deletemessageresponse.py - src/apideck_unify/models/deletenoteresponse.py - src/apideck_unify/models/deleteopportunityresponse.py + - src/apideck_unify/models/deletepaymentmethodresponse.py - src/apideck_unify/models/deletepaymentresponse.py - src/apideck_unify/models/deletepipelineresponse.py - src/apideck_unify/models/deleteprojectresponse.py - src/apideck_unify/models/deletepurchaseorderresponse.py - src/apideck_unify/models/deletequoteresponse.py - src/apideck_unify/models/deleterefundresponse.py + - src/apideck_unify/models/deletesalesreceiptresponse.py - src/apideck_unify/models/deletesharedlinkresponse.py - src/apideck_unify/models/deletesubsidiaryresponse.py - src/apideck_unify/models/deletesupplierresponse.py @@ -2947,6 +3013,8 @@ generatedFiles: - src/apideck_unify/models/getnotesresponse.py - src/apideck_unify/models/getopportunitiesresponse.py - src/apideck_unify/models/getopportunityresponse.py + - src/apideck_unify/models/getpaymentmethodresponse.py + - src/apideck_unify/models/getpaymentmethodsresponse.py - src/apideck_unify/models/getpaymentresponse.py - src/apideck_unify/models/getpaymentsresponse.py - src/apideck_unify/models/getpayrollresponse.py @@ -2964,6 +3032,8 @@ generatedFiles: - src/apideck_unify/models/getquotesresponse.py - src/apideck_unify/models/getrefundresponse.py - src/apideck_unify/models/getrefundsresponse.py + - src/apideck_unify/models/getsalesreceiptresponse.py + - src/apideck_unify/models/getsalesreceiptsresponse.py - src/apideck_unify/models/getsharedlinkresponse.py - src/apideck_unify/models/getsharedlinksresponse.py - src/apideck_unify/models/getstoreresponse.py @@ -3153,6 +3223,10 @@ generatedFiles: - src/apideck_unify/models/requestcountallocation.py - src/apideck_unify/models/resourcestatus.py - src/apideck_unify/models/responsevalidationerror.py + - src/apideck_unify/models/salesreceipt.py + - src/apideck_unify/models/salesreceipt_input.py + - src/apideck_unify/models/salesreceiptsfilter.py + - src/apideck_unify/models/salesreceiptssort.py - src/apideck_unify/models/schedule.py - src/apideck_unify/models/schemasupport.py - src/apideck_unify/models/security.py @@ -3236,12 +3310,14 @@ generatedFiles: - src/apideck_unify/models/updatemessageresponse.py - src/apideck_unify/models/updatenoteresponse.py - src/apideck_unify/models/updateopportunityresponse.py + - src/apideck_unify/models/updatepaymentmethodresponse.py - src/apideck_unify/models/updatepaymentresponse.py - src/apideck_unify/models/updatepipelineresponse.py - src/apideck_unify/models/updateprojectresponse.py - src/apideck_unify/models/updatepurchaseorderresponse.py - src/apideck_unify/models/updatequoteresponse.py - src/apideck_unify/models/updaterefundresponse.py + - src/apideck_unify/models/updatesalesreceiptresponse.py - src/apideck_unify/models/updatesharedlinkresponse.py - src/apideck_unify/models/updatesubsidiaryresponse.py - src/apideck_unify/models/updatesupplierresponse.py @@ -3298,6 +3374,7 @@ generatedFiles: - src/apideck_unify/notes.py - src/apideck_unify/opportunities.py - src/apideck_unify/orders.py + - src/apideck_unify/paymentmethods.py - src/apideck_unify/payments.py - src/apideck_unify/payrolls.py - src/apideck_unify/pipelines.py @@ -3309,6 +3386,7 @@ generatedFiles: - src/apideck_unify/py.typed - src/apideck_unify/quotes.py - src/apideck_unify/refunds.py + - src/apideck_unify/salesreceipts.py - src/apideck_unify/sdk.py - src/apideck_unify/sdkconfiguration.py - src/apideck_unify/sessions.py @@ -7472,7 +7550,7 @@ examples: x-apideck-company-id: "12345" responses: "200": - application/json: {"status_code": 200, "status": "OK", "service": "xero", "resource": "payments", "operation": "one", "data": {"id": "12345", "display_id": "sample ID", "name": "sample.jpg", "mime_type": "image/jpeg", "size": 1810673, "reference": {"type": "invoice", "id": "12345"}, "description": "A sample image", "parent_folder_id": "123", "updated_by": "12345", "created_by": "12345", "updated_at": "2020-09-30T07:43:32.000Z", "created_at": "2020-09-30T07:43:32.000Z", "pass_through": [{"service_id": "", "extend_paths": [{"path": "$.nested.property", "value": {"TaxClassificationRef": {"value": "EUC-99990201-V1-00020000"}}}]}]}, "meta": {"items_on_page": 50, "cursors": {"previous": "em9oby1jcm06OnBhZ2U6OjE=", "current": "em9oby1jcm06OnBhZ2U6OjI=", "next": "em9oby1jcm06OnBhZ2U6OjM="}, "total_count": 1, "warnings": [{"type": "downstream_request_failed", "status_code": 429, "operation": "getManager"}]}} + application/json: {"status_code": 200, "status": "OK", "service": "xero", "resource": "payments", "operation": "one", "data": {"id": "12345", "display_id": "sample ID", "name": "sample.jpg", "mime_type": "image/jpeg", "size": 1810673, "reference": {"type": "invoice", "id": "12345"}, "description": "A sample image", "file_url": "https://example.com/files/sample.jpg", "parent_folder_id": "123", "updated_by": "12345", "created_by": "12345", "updated_at": "2020-09-30T07:43:32.000Z", "created_at": "2020-09-30T07:43:32.000Z", "pass_through": [{"service_id": "", "extend_paths": [{"path": "$.nested.property", "value": {"TaxClassificationRef": {"value": "EUC-99990201-V1-00020000"}}}]}]}, "meta": {"items_on_page": 50, "cursors": {"previous": "em9oby1jcm06OnBhZ2U6OjE=", "current": "em9oby1jcm06OnBhZ2U6OjI=", "next": "em9oby1jcm06OnBhZ2U6OjM="}, "total_count": 1, "warnings": [{"type": "downstream_request_failed", "status_code": 429, "operation": "getManager"}]}} "400": application/json: {"status_code": 400, "error": "Bad Request", "type_name": "RequestValidationError", "message": "Invalid Params", "detail": "Missing property foobar", "ref": "https://developers.apideck.com/errors#requestvalidationerror", "downstream_errors": [{"message": "Account code '100' has been archived or deleted", "detail": "Each line item must reference a valid account", "code": "VALIDATION_ERROR"}]} "401": @@ -7581,6 +7659,7 @@ examples: x-apideck-app-id: "dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX" x-apideck-service-id: "salesforce" x-apideck-company-id: "12345" + x-apideck-follow-redirects: false responses: "200": '*/*': "x-file: example.file" @@ -8593,7 +8672,7 @@ examples: x-apideck-app-id: "dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX" x-apideck-service-id: "salesforce" requestBody: - application/json: {"bank_account_type": "bank", "source_account_id": "src_456", "target_account_id": "tgt_789", "target_account_name": "Main Company Checking", "target_account_number": "NL91ABNA0417164300", "currency": "USD", "feed_status": "pending", "country": "US", "custom_fields": [{"id": "2389328923893298", "name": "employee_level", "description": "Employee Level", "value": "Uses Salesforce and Marketo"}]} + application/json: {"bank_account_type": "bank", "source_account_id": "src_456", "source_routing_number": "021000021", "source_account_number": "123465", "target_account_id": "tgt_789", "target_account_name": "Main Company Checking", "target_account_number": "NL91ABNA0417164300", "balance": 25000, "available_balance": 24500, "currency": "USD", "feed_status": "pending", "country": "US", "custom_fields": [{"id": "2389328923893298", "name": "employee_level", "description": "Employee Level", "value": "Uses Salesforce and Marketo"}]} responses: "201": application/json: {"status_code": 200, "status": "OK", "service": "xero", "resource": "bills", "operation": "add", "data": {"id": "12345"}} @@ -8650,7 +8729,7 @@ examples: x-apideck-company-id: "12345" responses: "200": - application/json: {"status_code": 200, "status": "OK", "service": "xero", "resource": "bank-feed-accounts", "operation": "one", "data": {"id": "12345", "bank_account_type": "bank", "source_account_id": "src_456", "target_account_id": "tgt_789", "target_account_name": "Main Company Checking", "target_account_number": "NL91ABNA0417164300", "currency": "USD", "feed_status": "pending", "country": "US", "custom_fields": [{"id": "2389328923893298", "name": "employee_level", "description": "Employee Level", "value": "Uses Salesforce and Marketo"}], "created_at": "2020-09-30T07:43:32.000Z", "updated_at": "2020-09-30T07:43:32.000Z", "updated_by": "12345", "created_by": "12345"}, "meta": {"items_on_page": 50, "cursors": {"previous": "em9oby1jcm06OnBhZ2U6OjE=", "current": "em9oby1jcm06OnBhZ2U6OjI=", "next": "em9oby1jcm06OnBhZ2U6OjM="}, "total_count": 1, "warnings": [{"type": "downstream_request_failed", "status_code": 429, "operation": "getManager"}]}} + application/json: {"status_code": 200, "status": "OK", "service": "xero", "resource": "bank-feed-accounts", "operation": "one", "data": {"id": "12345", "bank_account_type": "bank", "source_account_id": "src_456", "source_routing_number": "021000021", "source_account_number": "123465", "target_account_id": "tgt_789", "target_account_name": "Main Company Checking", "target_account_number": "NL91ABNA0417164300", "balance": 25000, "available_balance": 24500, "currency": "USD", "feed_status": "pending", "country": "US", "custom_fields": [{"id": "2389328923893298", "name": "employee_level", "description": "Employee Level", "value": "Uses Salesforce and Marketo"}], "created_at": "2020-09-30T07:43:32.000Z", "updated_at": "2020-09-30T07:43:32.000Z", "updated_by": "12345", "created_by": "12345"}, "meta": {"items_on_page": 50, "cursors": {"previous": "em9oby1jcm06OnBhZ2U6OjE=", "current": "em9oby1jcm06OnBhZ2U6OjI=", "next": "em9oby1jcm06OnBhZ2U6OjM="}, "total_count": 1, "warnings": [{"type": "downstream_request_failed", "status_code": 429, "operation": "getManager"}]}} "400": application/json: {"status_code": 400, "error": "Bad Request", "type_name": "RequestValidationError", "message": "Invalid Params", "detail": "Missing property foobar", "ref": "https://developers.apideck.com/errors#requestvalidationerror", "downstream_errors": [{"message": "Account code '100' has been archived or deleted", "detail": "Each line item must reference a valid account", "code": "VALIDATION_ERROR"}]} "401": @@ -8702,7 +8781,7 @@ examples: x-apideck-app-id: "dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX" x-apideck-service-id: "salesforce" requestBody: - application/json: {"bank_account_type": "bank", "source_account_id": "src_456", "target_account_id": "tgt_789", "target_account_name": "Main Company Checking", "target_account_number": "NL91ABNA0417164300", "currency": "USD", "feed_status": "pending", "country": "US", "custom_fields": [{"id": "2389328923893298", "name": "employee_level", "description": "Employee Level", "value": "Uses Salesforce and Marketo"}]} + application/json: {"bank_account_type": "bank", "source_account_id": "src_456", "source_routing_number": "021000021", "source_account_number": "123465", "target_account_id": "tgt_789", "target_account_name": "Main Company Checking", "target_account_number": "NL91ABNA0417164300", "balance": 25000, "available_balance": 24500, "currency": "USD", "feed_status": "pending", "country": "US", "custom_fields": [{"id": "2389328923893298", "name": "employee_level", "description": "Employee Level", "value": "Uses Salesforce and Marketo"}]} responses: "200": application/json: {"status_code": 200, "status": "OK", "service": "xero", "resource": "bank-feed-accounts", "operation": "update", "data": {"id": "12345"}} @@ -12478,6 +12557,7 @@ examples: x-apideck-consumer-id: "test-consumer" x-apideck-app-id: "dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX" x-apideck-service-id: "salesforce" + x-apideck-follow-redirects: false responses: "200": '*/*': "x-file: example.file" @@ -18954,6 +19034,7 @@ examples: x-apideck-downstream-url: "https://api.close.com/api/v1/lead" x-apideck-downstream-authorization: "Bearer " x-apideck-timeout: 30000 + x-apideck-follow-redirects: false responses: "200": application/json: {"key": "", "key1": "", "key2": ""} @@ -18980,6 +19061,7 @@ examples: x-apideck-downstream-url: "https://api.close.com/api/v1/lead" x-apideck-downstream-authorization: "Bearer " x-apideck-timeout: 30000 + x-apideck-follow-redirects: false responses: "200": application/json: {"key": "", "key1": ""} @@ -19006,6 +19088,7 @@ examples: x-apideck-downstream-url: "https://api.close.com/api/v1/lead" x-apideck-downstream-authorization: "Bearer " x-apideck-timeout: 30000 + x-apideck-follow-redirects: false responses: "200": application/json: {"key": ""} @@ -19032,6 +19115,7 @@ examples: x-apideck-downstream-url: "https://api.close.com/api/v1/lead" x-apideck-downstream-authorization: "Bearer " x-apideck-timeout: 30000 + x-apideck-follow-redirects: false responses: "200": application/json: {"key": ""} @@ -19058,6 +19142,7 @@ examples: x-apideck-downstream-url: "https://api.close.com/api/v1/lead" x-apideck-downstream-authorization: "Bearer " x-apideck-timeout: 30000 + x-apideck-follow-redirects: false responses: "200": application/json: {"key": "", "key1": ""} @@ -19084,6 +19169,7 @@ examples: x-apideck-downstream-url: "https://api.close.com/api/v1/lead" x-apideck-downstream-authorization: "Bearer " x-apideck-timeout: 30000 + x-apideck-follow-redirects: false responses: "200": application/json: {"key": "", "key1": ""} @@ -19917,11 +20003,284 @@ examples: application/json: {"status_code": 422, "error": "Unprocessable Entity", "type_name": "InvalidStateError", "message": "Invalid State", "detail": "Unprocessable request, please verify your request headers and body.", "ref": "https://developers.apideck.com/errors#invalidstateerror"} default: application/json: {"status_code": 400, "error": "Bad Request", "type_name": "RequestHeadersValidationError", "message": "Invalid Params", "detail": "Missing Header: x-apideck-consumer-id", "ref": "https://developers.apideck.com/errors#unauthorizederror"} + accounting.salesReceiptsAll: + speakeasy-default-accounting-sales-receipts-all: + parameters: + query: + raw: false + limit: 20 + filter: {"updated_since": "2020-09-30T07:43:32.000Z", "customer_id": "123abc"} + sort: {"by": "updated_at", "direction": "desc"} + pass_through: {"search": "San Francisco"} + fields: "id,updated_at" + header: + x-apideck-consumer-id: "test-consumer" + x-apideck-app-id: "dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX" + x-apideck-service-id: "salesforce" + x-apideck-company-id: "12345" + responses: + "200": + application/json: {"status_code": 200, "status": "OK", "service": "quickbooks", "resource": "sales-receipts", "operation": "all", "data": [], "meta": {"items_on_page": 50, "cursors": {"previous": "em9oby1jcm06OnBhZ2U6OjE=", "current": "em9oby1jcm06OnBhZ2U6OjI=", "next": "em9oby1jcm06OnBhZ2U6OjM="}, "total_count": 1, "warnings": [{"type": "downstream_request_failed", "status_code": 429, "operation": "getManager"}]}, "links": {"previous": "https://unify.apideck.com/crm/companies?cursor=em9oby1jcm06OnBhZ2U6OjE%3D", "current": "https://unify.apideck.com/crm/companies", "next": "https://unify.apideck.com/crm/companies?cursor=em9oby1jcm06OnBhZ2U6OjM"}} + "400": + application/json: {"status_code": 400, "error": "Bad Request", "type_name": "RequestValidationError", "message": "Invalid Params", "detail": "Missing property foobar", "ref": "https://developers.apideck.com/errors#requestvalidationerror", "downstream_errors": [{"message": "Account code '100' has been archived or deleted", "detail": "Each line item must reference a valid account", "code": "VALIDATION_ERROR"}]} + "401": + application/json: {"status_code": 401, "error": "Unauthorized", "type_name": "UnauthorizedError", "message": "Unauthorized Request", "detail": "Missing authentication", "ref": "https://developers.apideck.com/errors#unauthorizederror"} + "402": + application/json: {"status_code": 402, "error": "Payment Required", "type_name": "RequestLimitError", "message": "Request Limit Reached", "detail": "You have reached your limit of 2000", "ref": "https://developers.apideck.com/errors#requestlimiterror"} + "404": + application/json: {"status_code": 404, "error": "Not Found", "type_name": "EntityNotFoundError", "message": "Unknown Widget", "detail": "Could not find widget with id: '123'", "ref": "https://developers.apideck.com/errors#entitynotfounderror"} + "422": + application/json: {"status_code": 422, "error": "Unprocessable Entity", "type_name": "InvalidStateError", "message": "Invalid State", "detail": "Unprocessable request, please verify your request headers and body.", "ref": "https://developers.apideck.com/errors#invalidstateerror"} + default: + application/json: {"status_code": 400, "error": "Bad Request", "type_name": "RequestHeadersValidationError", "message": "Invalid Params", "detail": "Missing Header: x-apideck-consumer-id", "ref": "https://developers.apideck.com/errors#unauthorizederror"} + accounting.salesReceiptsAdd: + speakeasy-default-accounting-sales-receipts-add: + parameters: + query: + raw: false + header: + x-apideck-consumer-id: "test-consumer" + x-apideck-app-id: "dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX" + x-apideck-service-id: "salesforce" + x-apideck-company-id: "12345" + requestBody: + application/json: {"number": "SR-00001", "customer": {"id": "12345", "display_name": "Windsurf Shop", "email": "boring@boring.com"}, "currency": "USD", "currency_rate": 0.69, "tax_inclusive": true, "sub_total": 250, "total_amount": 49.99, "total_tax": 25, "transaction_date": "2021-05-01T12:00:00.000Z", "payment_method": "cash", "payment_method_reference": "123456", "payment_method_id": "12345", "account": {"id": "123456", "name": "Bank account", "nominal_code": "N091", "code": "453", "parent_id": "123456", "display_id": "123456"}, "line_items": [{"id": "12345", "row_id": "12345", "code": "120-C", "line_number": 1, "description": "Model Y is a fully electric, mid-size SUV, with seating for up to seven, dual motor AWD and unparalleled protection.", "type": "sales_item", "tax_amount": 27500, "total_amount": 27500, "quantity": 1, "unit_price": 27500.5, "unit_of_measure": "pc.", "discount_percentage": 0.01, "discount_amount": 19.99, "service_date": "2024-01-15", "category_id": "12345", "location_id": "12345", "department_id": "12345", "subsidiary_id": "12345", "shipping_id": "12345", "memo": "Some memo", "prepaid": true, "item": {"id": "12344", "code": "120-C", "name": "Model Y"}, "tax_applicable_on": "Domestic_Purchase_of_Goods_and_Services", "tax_recoverability": "Fully_Recoverable", "tax_method": "Due_to_Supplier", "worktags": [{"id": "123456", "value": "New York"}], "tax_rate": {"id": "123456", "code": "N-T", "rate": 10}, "tracking_categories": [{"id": "123456", "code": "100", "name": "New York", "parent_id": "123456", "parent_name": "New York"}], "ledger_account": {"id": "123456", "name": "Bank account", "nominal_code": "N091", "code": "453", "parent_id": "123456", "display_id": "123456"}, "custom_fields": [{"id": "2389328923893298", "name": "employee_level", "ref_name": "Marketing", "description": "Employee Level", "value": "Uses Salesforce and Marketo"}], "row_version": "1-12345"}], "tax_code": "1234", "discount_percentage": 5.5, "discount_amount": 25, "note": "Thank you for your purchase", "customer_memo": "Thank you for your business and have a great day!", "reference": "REF-123456", "billing_address": {"id": "123", "type": "primary", "string": "25 Spring Street, Blackburn, VIC 3130", "name": "HQ US", "line1": "Main street", "line2": "apt #", "line3": "Suite #", "line4": "delivery instructions", "line5": "Attention: Finance Dept", "street_number": "25", "city": "San Francisco", "state": "CA", "postal_code": "94104", "country": "US", "latitude": "40.759211", "longitude": "-73.984638", "county": "Santa Clara", "contact_name": "Elon Musk", "salutation": "Mr", "phone_number": "111-111-1111", "fax": "122-111-1111", "email": "elon@musk.com", "website": "https://elonmusk.com", "notes": "Address notes or delivery instructions.", "row_version": "1-12345"}, "shipping_address": {"id": "123", "type": "primary", "string": "25 Spring Street, Blackburn, VIC 3130", "name": "HQ US", "line1": "Main street", "line2": "apt #", "line3": "Suite #", "line4": "delivery instructions", "line5": "Attention: Finance Dept", "street_number": "25", "city": "San Francisco", "state": "CA", "postal_code": "94104", "country": "US", "latitude": "40.759211", "longitude": "-73.984638", "county": "Santa Clara", "contact_name": "Elon Musk", "salutation": "Mr", "phone_number": "111-111-1111", "fax": "122-111-1111", "email": "elon@musk.com", "website": "https://elonmusk.com", "notes": "Address notes or delivery instructions.", "row_version": "1-12345"}, "department": {"display_id": "123456", "name": "Acme Inc."}, "tracking_categories": [{"id": "123456", "code": "100", "name": "New York", "parent_id": "123456", "parent_name": "New York"}], "custom_fields": [{"id": "2389328923893298", "name": "employee_level", "ref_name": "Marketing", "description": "Employee Level", "value": "Uses Salesforce and Marketo"}], "row_version": "1-12345", "pass_through": [{"service_id": "", "extend_paths": [{"path": "$.nested.property", "value": {"TaxClassificationRef": {"value": "EUC-99990201-V1-00020000"}}}]}]} + responses: + "201": + application/json: {"status_code": 200, "status": "OK", "service": "quickbooks", "resource": "sales-receipts", "operation": "add", "data": {"id": "12345"}} + "400": + application/json: {"status_code": 400, "error": "Bad Request", "type_name": "RequestValidationError", "message": "Invalid Params", "detail": "Missing property foobar", "ref": "https://developers.apideck.com/errors#requestvalidationerror", "downstream_errors": [{"message": "Account code '100' has been archived or deleted", "detail": "Each line item must reference a valid account", "code": "VALIDATION_ERROR"}]} + "401": + application/json: {"status_code": 401, "error": "Unauthorized", "type_name": "UnauthorizedError", "message": "Unauthorized Request", "detail": "Missing authentication", "ref": "https://developers.apideck.com/errors#unauthorizederror"} + "402": + application/json: {"status_code": 402, "error": "Payment Required", "type_name": "RequestLimitError", "message": "Request Limit Reached", "detail": "You have reached your limit of 2000", "ref": "https://developers.apideck.com/errors#requestlimiterror"} + "404": + application/json: {"status_code": 404, "error": "Not Found", "type_name": "EntityNotFoundError", "message": "Unknown Widget", "detail": "Could not find widget with id: '123'", "ref": "https://developers.apideck.com/errors#entitynotfounderror"} + "422": + application/json: {"status_code": 422, "error": "Unprocessable Entity", "type_name": "InvalidStateError", "message": "Invalid State", "detail": "Unprocessable request, please verify your request headers and body.", "ref": "https://developers.apideck.com/errors#invalidstateerror"} + default: + application/json: {"status_code": 400, "error": "Bad Request", "type_name": "RequestHeadersValidationError", "message": "Invalid Params", "detail": "Missing Header: x-apideck-consumer-id", "ref": "https://developers.apideck.com/errors#unauthorizederror"} + accounting.salesReceiptsOne: + speakeasy-default-accounting-sales-receipts-one: + parameters: + path: + id: "" + query: + raw: false + fields: "id,updated_at" + header: + x-apideck-consumer-id: "test-consumer" + x-apideck-app-id: "dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX" + x-apideck-service-id: "salesforce" + x-apideck-company-id: "12345" + responses: + "200": + application/json: {"status_code": 200, "status": "OK", "service": "quickbooks", "resource": "sales-receipts", "operation": "one", "data": {"id": "123456", "number": "SR-00001", "customer": {"id": "12345", "display_id": "CUST00101", "display_name": "Windsurf Shop", "company_name": "The boring company", "email": "boring@boring.com"}, "currency": "USD", "currency_rate": 0.69, "tax_inclusive": true, "sub_total": 250, "total_amount": 49.99, "total_tax": 25, "transaction_date": "2021-05-01T12:00:00.000Z", "payment_method": "cash", "payment_method_reference": "123456", "payment_method_id": "12345", "account": {"id": "123456", "name": "Bank account", "nominal_code": "N091", "code": "453", "parent_id": "123456", "display_id": "123456"}, "line_items": [{"id": "12345", "row_id": "12345", "code": "120-C", "line_number": 1, "description": "Model Y is a fully electric, mid-size SUV, with seating for up to seven, dual motor AWD and unparalleled protection.", "type": "sales_item", "tax_amount": 27500, "total_amount": 27500, "quantity": 1, "unit_price": 27500.5, "unit_of_measure": "pc.", "discount_percentage": 0.01, "discount_amount": 19.99, "service_date": "2024-01-15", "category_id": "12345", "location_id": "12345", "department_id": "12345", "subsidiary_id": "12345", "shipping_id": "12345", "memo": "Some memo", "prepaid": true, "item": {"id": "12344", "code": "120-C", "name": "Model Y"}, "tax_applicable_on": "Domestic_Purchase_of_Goods_and_Services", "tax_recoverability": "Fully_Recoverable", "tax_method": "Due_to_Supplier", "worktags": [{"id": "123456", "value": "New York"}], "tax_rate": {"id": "123456", "code": "N-T", "name": "GST on Purchases", "rate": 10}, "tracking_categories": [{"id": "123456", "code": "100", "name": "New York", "parent_id": "123456", "parent_name": "New York"}], "ledger_account": {"id": "123456", "name": "Bank account", "nominal_code": "N091", "code": "453", "parent_id": "123456", "display_id": "123456"}, "custom_fields": [{"id": "2389328923893298", "name": "employee_level", "ref_name": "Marketing", "description": "Employee Level", "value": null}], "row_version": "1-12345", "updated_by": "12345", "created_by": "12345", "created_at": "2020-09-30T07:43:32.000Z", "updated_at": "2020-09-30T07:43:32.000Z"}], "tax_code": "1234", "discount_percentage": 5.5, "discount_amount": 25, "note": "Thank you for your purchase", "customer_memo": "Thank you for your business and have a great day!", "reference": "REF-123456", "billing_address": {"id": "123", "type": "primary", "string": "25 Spring Street, Blackburn, VIC 3130", "name": "HQ US", "line1": "Main street", "line2": "apt #", "line3": "Suite #", "line4": "delivery instructions", "line5": "Attention: Finance Dept", "street_number": "25", "city": "San Francisco", "state": "CA", "postal_code": "94104", "country": "US", "latitude": "40.759211", "longitude": "-73.984638", "county": "Santa Clara", "contact_name": "Elon Musk", "salutation": "Mr", "phone_number": "111-111-1111", "fax": "122-111-1111", "email": "elon@musk.com", "website": "https://elonmusk.com", "notes": "Address notes or delivery instructions.", "row_version": "1-12345"}, "shipping_address": {"id": "123", "type": "primary", "string": "25 Spring Street, Blackburn, VIC 3130", "name": "HQ US", "line1": "Main street", "line2": "apt #", "line3": "Suite #", "line4": "delivery instructions", "line5": "Attention: Finance Dept", "street_number": "25", "city": "San Francisco", "state": "CA", "postal_code": "94104", "country": "US", "latitude": "40.759211", "longitude": "-73.984638", "county": "Santa Clara", "contact_name": "Elon Musk", "salutation": "Mr", "phone_number": "111-111-1111", "fax": "122-111-1111", "email": "elon@musk.com", "website": "https://elonmusk.com", "notes": "Address notes or delivery instructions.", "row_version": "1-12345"}, "department": {"id": "12345", "display_id": "123456", "name": "Acme Inc.", "downstream_id": "12345"}, "tracking_categories": [{"id": "123456", "code": "100", "name": "New York", "parent_id": "123456", "parent_name": "New York"}], "custom_fields": [{"id": "2389328923893298", "name": "employee_level", "ref_name": "Marketing", "description": "Employee Level", "value": "Uses Salesforce and Marketo"}], "row_version": "1-12345", "updated_by": "12345", "created_by": "12345", "updated_at": "2020-09-30T07:43:32.000Z", "created_at": "2020-09-30T07:43:32.000Z", "pass_through": [{"service_id": "", "extend_paths": [{"path": "$.nested.property", "value": {"TaxClassificationRef": {"value": "EUC-99990201-V1-00020000"}}}]}]}, "meta": {"items_on_page": 50, "cursors": {"previous": "em9oby1jcm06OnBhZ2U6OjE=", "current": "em9oby1jcm06OnBhZ2U6OjI=", "next": "em9oby1jcm06OnBhZ2U6OjM="}, "total_count": 1, "warnings": [{"type": "downstream_request_failed", "status_code": 429, "operation": "getManager"}]}} + "400": + application/json: {"status_code": 400, "error": "Bad Request", "type_name": "RequestValidationError", "message": "Invalid Params", "detail": "Missing property foobar", "ref": "https://developers.apideck.com/errors#requestvalidationerror", "downstream_errors": [{"message": "Account code '100' has been archived or deleted", "detail": "Each line item must reference a valid account", "code": "VALIDATION_ERROR"}]} + "401": + application/json: {"status_code": 401, "error": "Unauthorized", "type_name": "UnauthorizedError", "message": "Unauthorized Request", "detail": "Missing authentication", "ref": "https://developers.apideck.com/errors#unauthorizederror"} + "402": + application/json: {"status_code": 402, "error": "Payment Required", "type_name": "RequestLimitError", "message": "Request Limit Reached", "detail": "You have reached your limit of 2000", "ref": "https://developers.apideck.com/errors#requestlimiterror"} + "404": + application/json: {"status_code": 404, "error": "Not Found", "type_name": "EntityNotFoundError", "message": "Unknown Widget", "detail": "Could not find widget with id: '123'", "ref": "https://developers.apideck.com/errors#entitynotfounderror"} + "422": + application/json: {"status_code": 422, "error": "Unprocessable Entity", "type_name": "InvalidStateError", "message": "Invalid State", "detail": "Unprocessable request, please verify your request headers and body.", "ref": "https://developers.apideck.com/errors#invalidstateerror"} + default: + application/json: {"status_code": 400, "error": "Bad Request", "type_name": "RequestHeadersValidationError", "message": "Invalid Params", "detail": "Missing Header: x-apideck-consumer-id", "ref": "https://developers.apideck.com/errors#unauthorizederror"} + accounting.salesReceiptsUpdate: + speakeasy-default-accounting-sales-receipts-update: + parameters: + path: + id: "" + query: + raw: false + header: + x-apideck-consumer-id: "test-consumer" + x-apideck-app-id: "dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX" + x-apideck-service-id: "salesforce" + x-apideck-company-id: "12345" + requestBody: + application/json: {"number": "SR-00001", "customer": {"id": "12345", "display_name": "Windsurf Shop", "email": "boring@boring.com"}, "currency": "USD", "currency_rate": 0.69, "tax_inclusive": true, "sub_total": 250, "total_amount": 49.99, "total_tax": 25, "transaction_date": "2021-05-01T12:00:00.000Z", "payment_method": "cash", "payment_method_reference": "123456", "payment_method_id": "12345", "account": {"id": "123456", "name": "Bank account", "nominal_code": "N091", "code": "453", "parent_id": "123456", "display_id": "123456"}, "line_items": [{"id": "12345", "row_id": "12345", "code": "120-C", "line_number": 1, "description": "Model Y is a fully electric, mid-size SUV, with seating for up to seven, dual motor AWD and unparalleled protection.", "type": "sales_item", "tax_amount": 27500, "total_amount": 27500, "quantity": 1, "unit_price": 27500.5, "unit_of_measure": "pc.", "discount_percentage": 0.01, "discount_amount": 19.99, "service_date": "2024-01-15", "category_id": "12345", "location_id": "12345", "department_id": "12345", "subsidiary_id": "12345", "shipping_id": "12345", "memo": "Some memo", "prepaid": true, "item": {"id": "12344", "code": "120-C", "name": "Model Y"}, "tax_applicable_on": "Domestic_Purchase_of_Goods_and_Services", "tax_recoverability": "Fully_Recoverable", "tax_method": "Due_to_Supplier", "worktags": [{"id": "123456", "value": "New York"}], "tax_rate": {"id": "123456", "code": "N-T", "rate": 10}, "tracking_categories": [{"id": "123456", "code": "100", "name": "New York", "parent_id": "123456", "parent_name": "New York"}], "ledger_account": {"id": "123456", "name": "Bank account", "nominal_code": "N091", "code": "453", "parent_id": "123456", "display_id": "123456"}, "custom_fields": [{"id": "2389328923893298", "name": "employee_level", "ref_name": "Marketing", "description": "Employee Level", "value": "Uses Salesforce and Marketo"}], "row_version": "1-12345"}], "tax_code": "1234", "discount_percentage": 5.5, "discount_amount": 25, "note": "Thank you for your purchase", "customer_memo": "Thank you for your business and have a great day!", "reference": "REF-123456", "billing_address": {"id": "123", "type": "primary", "string": "25 Spring Street, Blackburn, VIC 3130", "name": "HQ US", "line1": "Main street", "line2": "apt #", "line3": "Suite #", "line4": "delivery instructions", "line5": "Attention: Finance Dept", "street_number": "25", "city": "San Francisco", "state": "CA", "postal_code": "94104", "country": "US", "latitude": "40.759211", "longitude": "-73.984638", "county": "Santa Clara", "contact_name": "Elon Musk", "salutation": "Mr", "phone_number": "111-111-1111", "fax": "122-111-1111", "email": "elon@musk.com", "website": "https://elonmusk.com", "notes": "Address notes or delivery instructions.", "row_version": "1-12345"}, "shipping_address": {"id": "123", "type": "primary", "string": "25 Spring Street, Blackburn, VIC 3130", "name": "HQ US", "line1": "Main street", "line2": "apt #", "line3": "Suite #", "line4": "delivery instructions", "line5": "Attention: Finance Dept", "street_number": "25", "city": "San Francisco", "state": "CA", "postal_code": "94104", "country": "US", "latitude": "40.759211", "longitude": "-73.984638", "county": "Santa Clara", "contact_name": "Elon Musk", "salutation": "Mr", "phone_number": "111-111-1111", "fax": "122-111-1111", "email": "elon@musk.com", "website": "https://elonmusk.com", "notes": "Address notes or delivery instructions.", "row_version": "1-12345"}, "department": {"display_id": "123456", "name": "Acme Inc."}, "tracking_categories": [{"id": "123456", "code": "100", "name": "New York", "parent_id": "123456", "parent_name": "New York"}], "custom_fields": [{"id": "2389328923893298", "name": "employee_level", "ref_name": "Marketing", "description": "Employee Level", "value": "Uses Salesforce and Marketo"}], "row_version": "1-12345", "pass_through": [{"service_id": "", "extend_paths": [{"path": "$.nested.property", "value": {"TaxClassificationRef": {"value": "EUC-99990201-V1-00020000"}}}]}]} + responses: + "200": + application/json: {"status_code": 200, "status": "OK", "service": "quickbooks", "resource": "sales-receipts", "operation": "update", "data": {"id": "12345"}} + "400": + application/json: {"status_code": 400, "error": "Bad Request", "type_name": "RequestValidationError", "message": "Invalid Params", "detail": "Missing property foobar", "ref": "https://developers.apideck.com/errors#requestvalidationerror", "downstream_errors": [{"message": "Account code '100' has been archived or deleted", "detail": "Each line item must reference a valid account", "code": "VALIDATION_ERROR"}]} + "401": + application/json: {"status_code": 401, "error": "Unauthorized", "type_name": "UnauthorizedError", "message": "Unauthorized Request", "detail": "Missing authentication", "ref": "https://developers.apideck.com/errors#unauthorizederror"} + "402": + application/json: {"status_code": 402, "error": "Payment Required", "type_name": "RequestLimitError", "message": "Request Limit Reached", "detail": "You have reached your limit of 2000", "ref": "https://developers.apideck.com/errors#requestlimiterror"} + "404": + application/json: {"status_code": 404, "error": "Not Found", "type_name": "EntityNotFoundError", "message": "Unknown Widget", "detail": "Could not find widget with id: '123'", "ref": "https://developers.apideck.com/errors#entitynotfounderror"} + "422": + application/json: {"status_code": 422, "error": "Unprocessable Entity", "type_name": "InvalidStateError", "message": "Invalid State", "detail": "Unprocessable request, please verify your request headers and body.", "ref": "https://developers.apideck.com/errors#invalidstateerror"} + default: + application/json: {"status_code": 400, "error": "Bad Request", "type_name": "RequestHeadersValidationError", "message": "Invalid Params", "detail": "Missing Header: x-apideck-consumer-id", "ref": "https://developers.apideck.com/errors#unauthorizederror"} + accounting.salesReceiptsDelete: + speakeasy-default-accounting-sales-receipts-delete: + parameters: + path: + id: "" + query: + raw: false + header: + x-apideck-consumer-id: "test-consumer" + x-apideck-app-id: "dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX" + x-apideck-service-id: "salesforce" + x-apideck-company-id: "12345" + responses: + "200": + application/json: {"status_code": 200, "status": "OK", "service": "quickbooks", "resource": "sales-receipts", "operation": "delete", "data": {"id": "12345"}} + "400": + application/json: {"status_code": 400, "error": "Bad Request", "type_name": "RequestValidationError", "message": "Invalid Params", "detail": "Missing property foobar", "ref": "https://developers.apideck.com/errors#requestvalidationerror", "downstream_errors": [{"message": "Account code '100' has been archived or deleted", "detail": "Each line item must reference a valid account", "code": "VALIDATION_ERROR"}]} + "401": + application/json: {"status_code": 401, "error": "Unauthorized", "type_name": "UnauthorizedError", "message": "Unauthorized Request", "detail": "Missing authentication", "ref": "https://developers.apideck.com/errors#unauthorizederror"} + "402": + application/json: {"status_code": 402, "error": "Payment Required", "type_name": "RequestLimitError", "message": "Request Limit Reached", "detail": "You have reached your limit of 2000", "ref": "https://developers.apideck.com/errors#requestlimiterror"} + "404": + application/json: {"status_code": 404, "error": "Not Found", "type_name": "EntityNotFoundError", "message": "Unknown Widget", "detail": "Could not find widget with id: '123'", "ref": "https://developers.apideck.com/errors#entitynotfounderror"} + "422": + application/json: {"status_code": 422, "error": "Unprocessable Entity", "type_name": "InvalidStateError", "message": "Invalid State", "detail": "Unprocessable request, please verify your request headers and body.", "ref": "https://developers.apideck.com/errors#invalidstateerror"} + default: + application/json: {"status_code": 400, "error": "Bad Request", "type_name": "RequestHeadersValidationError", "message": "Invalid Params", "detail": "Missing Header: x-apideck-consumer-id", "ref": "https://developers.apideck.com/errors#unauthorizederror"} + accounting.paymentMethodsAll: + speakeasy-default-accounting-payment-methods-all: + parameters: + query: + raw: false + limit: 20 + fields: "id,updated_at" + pass_through: {"search": "San Francisco"} + header: + x-apideck-consumer-id: "test-consumer" + x-apideck-app-id: "dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX" + x-apideck-service-id: "salesforce" + responses: + "200": + application/json: {"status_code": 200, "status": "OK", "service": "quickbooks", "resource": "PaymentMethods", "operation": "all", "data": [], "meta": {"items_on_page": 50, "cursors": {"previous": "em9oby1jcm06OnBhZ2U6OjE=", "current": "em9oby1jcm06OnBhZ2U6OjI=", "next": "em9oby1jcm06OnBhZ2U6OjM="}, "total_count": 1, "warnings": null}, "links": {"previous": "https://unify.apideck.com/crm/companies?cursor=em9oby1jcm06OnBhZ2U6OjE%3D", "current": "https://unify.apideck.com/crm/companies", "next": "https://unify.apideck.com/crm/companies?cursor=em9oby1jcm06OnBhZ2U6OjM"}} + "400": + application/json: {"status_code": 400, "error": "Bad Request", "type_name": "RequestValidationError", "message": "Invalid Params", "detail": "Missing property foobar", "ref": "https://developers.apideck.com/errors#requestvalidationerror", "downstream_errors": [{"message": "Account code '100' has been archived or deleted", "detail": "Each line item must reference a valid account", "code": "VALIDATION_ERROR"}]} + "401": + application/json: {"status_code": 401, "error": "Unauthorized", "type_name": "UnauthorizedError", "message": "Unauthorized Request", "detail": "Missing authentication", "ref": "https://developers.apideck.com/errors#unauthorizederror"} + "402": + application/json: {"status_code": 402, "error": "Payment Required", "type_name": "RequestLimitError", "message": "Request Limit Reached", "detail": "You have reached your limit of 2000", "ref": "https://developers.apideck.com/errors#requestlimiterror"} + "404": + application/json: {"status_code": 404, "error": "Not Found", "type_name": "EntityNotFoundError", "message": "Unknown Widget", "detail": "Could not find widget with id: '123'", "ref": "https://developers.apideck.com/errors#entitynotfounderror"} + "422": + application/json: {"status_code": 422, "error": "Unprocessable Entity", "type_name": "InvalidStateError", "message": "Invalid State", "detail": "Unprocessable request, please verify your request headers and body.", "ref": "https://developers.apideck.com/errors#invalidstateerror"} + default: + application/json: {"status_code": 400, "error": "Bad Request", "type_name": "RequestHeadersValidationError", "message": "Invalid Params", "detail": "Missing Header: x-apideck-consumer-id", "ref": "https://developers.apideck.com/errors#unauthorizederror"} + accounting.paymentMethodsAdd: + speakeasy-default-accounting-payment-methods-add: + parameters: + query: + raw: false + header: + x-apideck-consumer-id: "test-consumer" + x-apideck-app-id: "dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX" + x-apideck-service-id: "salesforce" + requestBody: + application/json: {"name": "Cash", "type": "cash", "status": "active", "row_version": "1-12345", "pass_through": [{"service_id": "", "extend_paths": [{"path": "$.nested.property", "value": {"TaxClassificationRef": {"value": "EUC-99990201-V1-00020000"}}}]}]} + responses: + "201": + application/json: {"status_code": 200, "status": "OK", "service": "quickbooks", "resource": "PaymentMethods", "operation": "add", "data": {"id": "12345"}} + "400": + application/json: {"status_code": 400, "error": "Bad Request", "type_name": "RequestValidationError", "message": "Invalid Params", "detail": "Missing property foobar", "ref": "https://developers.apideck.com/errors#requestvalidationerror", "downstream_errors": [{"message": "Account code '100' has been archived or deleted", "detail": "Each line item must reference a valid account", "code": "VALIDATION_ERROR"}]} + "401": + application/json: {"status_code": 401, "error": "Unauthorized", "type_name": "UnauthorizedError", "message": "Unauthorized Request", "detail": "Missing authentication", "ref": "https://developers.apideck.com/errors#unauthorizederror"} + "402": + application/json: {"status_code": 402, "error": "Payment Required", "type_name": "RequestLimitError", "message": "Request Limit Reached", "detail": "You have reached your limit of 2000", "ref": "https://developers.apideck.com/errors#requestlimiterror"} + "404": + application/json: {"status_code": 404, "error": "Not Found", "type_name": "EntityNotFoundError", "message": "Unknown Widget", "detail": "Could not find widget with id: '123'", "ref": "https://developers.apideck.com/errors#entitynotfounderror"} + "422": + application/json: {"status_code": 422, "error": "Unprocessable Entity", "type_name": "InvalidStateError", "message": "Invalid State", "detail": "Unprocessable request, please verify your request headers and body.", "ref": "https://developers.apideck.com/errors#invalidstateerror"} + default: + application/json: {"status_code": 400, "error": "Bad Request", "type_name": "RequestHeadersValidationError", "message": "Invalid Params", "detail": "Missing Header: x-apideck-consumer-id", "ref": "https://developers.apideck.com/errors#unauthorizederror"} + accounting.paymentMethodsOne: + speakeasy-default-accounting-payment-methods-one: + parameters: + path: + id: "" + query: + raw: false + fields: "id,updated_at" + header: + x-apideck-consumer-id: "test-consumer" + x-apideck-app-id: "dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX" + x-apideck-service-id: "salesforce" + responses: + "200": + application/json: {"status_code": 200, "status": "OK", "service": "quickbooks", "resource": "PaymentMethods", "operation": "one", "data": {"id": "12345", "name": "Cash", "type": "cash", "status": "active", "downstream_id": "12345", "row_version": "1-12345", "updated_by": "12345", "created_by": "12345", "updated_at": "2020-09-30T07:43:32.000Z", "created_at": "2020-09-30T07:43:32.000Z", "pass_through": [{"service_id": "", "extend_paths": [{"path": "$.nested.property", "value": {"TaxClassificationRef": {"value": "EUC-99990201-V1-00020000"}}}]}]}, "meta": {"items_on_page": 50, "cursors": {"previous": "em9oby1jcm06OnBhZ2U6OjE=", "current": "em9oby1jcm06OnBhZ2U6OjI=", "next": "em9oby1jcm06OnBhZ2U6OjM="}, "total_count": 1, "warnings": [{"type": "downstream_request_failed", "status_code": 429, "operation": "getManager"}]}} + "400": + application/json: {"status_code": 400, "error": "Bad Request", "type_name": "RequestValidationError", "message": "Invalid Params", "detail": "Missing property foobar", "ref": "https://developers.apideck.com/errors#requestvalidationerror", "downstream_errors": [{"message": "Account code '100' has been archived or deleted", "detail": "Each line item must reference a valid account", "code": "VALIDATION_ERROR"}]} + "401": + application/json: {"status_code": 401, "error": "Unauthorized", "type_name": "UnauthorizedError", "message": "Unauthorized Request", "detail": "Missing authentication", "ref": "https://developers.apideck.com/errors#unauthorizederror"} + "402": + application/json: {"status_code": 402, "error": "Payment Required", "type_name": "RequestLimitError", "message": "Request Limit Reached", "detail": "You have reached your limit of 2000", "ref": "https://developers.apideck.com/errors#requestlimiterror"} + "404": + application/json: {"status_code": 404, "error": "Not Found", "type_name": "EntityNotFoundError", "message": "Unknown Widget", "detail": "Could not find widget with id: '123'", "ref": "https://developers.apideck.com/errors#entitynotfounderror"} + "422": + application/json: {"status_code": 422, "error": "Unprocessable Entity", "type_name": "InvalidStateError", "message": "Invalid State", "detail": "Unprocessable request, please verify your request headers and body.", "ref": "https://developers.apideck.com/errors#invalidstateerror"} + default: + application/json: {"status_code": 400, "error": "Bad Request", "type_name": "RequestHeadersValidationError", "message": "Invalid Params", "detail": "Missing Header: x-apideck-consumer-id", "ref": "https://developers.apideck.com/errors#unauthorizederror"} + accounting.paymentMethodsUpdate: + speakeasy-default-accounting-payment-methods-update: + parameters: + path: + id: "" + query: + raw: false + header: + x-apideck-consumer-id: "test-consumer" + x-apideck-app-id: "dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX" + x-apideck-service-id: "salesforce" + requestBody: + application/json: {"name": "Cash", "type": "cash", "status": "active", "row_version": "1-12345", "pass_through": [{"service_id": "", "extend_paths": [{"path": "$.nested.property", "value": {"TaxClassificationRef": {"value": "EUC-99990201-V1-00020000"}}}]}]} + responses: + "200": + application/json: {"status_code": 200, "status": "OK", "service": "quickbooks", "resource": "PaymentMethods", "operation": "update", "data": {"id": "12345"}} + "400": + application/json: {"status_code": 400, "error": "Bad Request", "type_name": "RequestValidationError", "message": "Invalid Params", "detail": "Missing property foobar", "ref": "https://developers.apideck.com/errors#requestvalidationerror", "downstream_errors": [{"message": "Account code '100' has been archived or deleted", "detail": "Each line item must reference a valid account", "code": "VALIDATION_ERROR"}]} + "401": + application/json: {"status_code": 401, "error": "Unauthorized", "type_name": "UnauthorizedError", "message": "Unauthorized Request", "detail": "Missing authentication", "ref": "https://developers.apideck.com/errors#unauthorizederror"} + "402": + application/json: {"status_code": 402, "error": "Payment Required", "type_name": "RequestLimitError", "message": "Request Limit Reached", "detail": "You have reached your limit of 2000", "ref": "https://developers.apideck.com/errors#requestlimiterror"} + "404": + application/json: {"status_code": 404, "error": "Not Found", "type_name": "EntityNotFoundError", "message": "Unknown Widget", "detail": "Could not find widget with id: '123'", "ref": "https://developers.apideck.com/errors#entitynotfounderror"} + "422": + application/json: {"status_code": 422, "error": "Unprocessable Entity", "type_name": "InvalidStateError", "message": "Invalid State", "detail": "Unprocessable request, please verify your request headers and body.", "ref": "https://developers.apideck.com/errors#invalidstateerror"} + default: + application/json: {"status_code": 400, "error": "Bad Request", "type_name": "RequestHeadersValidationError", "message": "Invalid Params", "detail": "Missing Header: x-apideck-consumer-id", "ref": "https://developers.apideck.com/errors#unauthorizederror"} + accounting.paymentMethodsDelete: + speakeasy-default-accounting-payment-methods-delete: + parameters: + path: + id: "" + query: + raw: false + header: + x-apideck-consumer-id: "test-consumer" + x-apideck-app-id: "dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX" + x-apideck-service-id: "salesforce" + responses: + "200": + application/json: {"status_code": 200, "status": "OK", "service": "quickbooks", "resource": "PaymentMethods", "operation": "delete", "data": {"id": "12345"}} + "400": + application/json: {"status_code": 400, "error": "Bad Request", "type_name": "RequestValidationError", "message": "Invalid Params", "detail": "Missing property foobar", "ref": "https://developers.apideck.com/errors#requestvalidationerror", "downstream_errors": [{"message": "Account code '100' has been archived or deleted", "detail": "Each line item must reference a valid account", "code": "VALIDATION_ERROR"}]} + "401": + application/json: {"status_code": 401, "error": "Unauthorized", "type_name": "UnauthorizedError", "message": "Unauthorized Request", "detail": "Missing authentication", "ref": "https://developers.apideck.com/errors#unauthorizederror"} + "402": + application/json: {"status_code": 402, "error": "Payment Required", "type_name": "RequestLimitError", "message": "Request Limit Reached", "detail": "You have reached your limit of 2000", "ref": "https://developers.apideck.com/errors#requestlimiterror"} + "404": + application/json: {"status_code": 404, "error": "Not Found", "type_name": "EntityNotFoundError", "message": "Unknown Widget", "detail": "Could not find widget with id: '123'", "ref": "https://developers.apideck.com/errors#entitynotfounderror"} + "422": + application/json: {"status_code": 422, "error": "Unprocessable Entity", "type_name": "InvalidStateError", "message": "Invalid State", "detail": "Unprocessable request, please verify your request headers and body.", "ref": "https://developers.apideck.com/errors#invalidstateerror"} + default: + application/json: {"status_code": 400, "error": "Bad Request", "type_name": "RequestHeadersValidationError", "message": "Invalid Params", "detail": "Missing Header: x-apideck-consumer-id", "ref": "https://developers.apideck.com/errors#unauthorizederror"} examplesVersion: 1.0.2 generatedTests: {} -releaseNotes: | - ## Python SDK Changes Detected: - * `apideck.crm.list_members.list()`: **Added** +releaseNotes: "## Python SDK Changes Detected:\n* `apideck.accounting.sales_receipts.list()`: **Added**\n* `apideck.accounting.sales_receipts.create()`: **Added**\n* `apideck.accounting.sales_receipts.get()`: **Added**\n* `apideck.accounting.sales_receipts.update()`: **Added**\n* `apideck.accounting.sales_receipts.delete()`: **Added**\n* `apideck.accounting.payment_methods.list()`: **Added**\n* `apideck.accounting.payment_methods.create()`: **Added**\n* `apideck.accounting.payment_methods.get()`: **Added**\n* `apideck.accounting.payment_methods.update()`: **Added**\n* `apideck.accounting.payment_methods.delete()`: **Added**\n* `apideck.accounting.tax_rates.list()`: `response.data.[].custom_fields.[]` **Changed**\n* `apideck.accounting.tax_rates.create()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.accounting.tax_rates.get()`: `response.data.custom_fields.[]` **Changed**\n* `apideck.accounting.tax_rates.update()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.accounting.bills.list()`: `response.data.[].custom_fields.[]` **Changed**\n* `apideck.accounting.bills.create()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.accounting.bills.get()`: `response.data.custom_fields.[]` **Changed**\n* `apideck.accounting.bills.update()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.accounting.invoices.list()`: `response.data.[].line_items.[].custom_fields.[]` **Changed**\n* `apideck.accounting.invoices.create()`: \n * `request.line_items.[].custom_fields.[]` **Changed**\n* `apideck.accounting.invoices.get()`: `response.data.line_items.[].custom_fields.[]` **Changed**\n* `apideck.accounting.invoices.update()`: \n * `request.line_items.[].custom_fields.[]` **Changed**\n* `apideck.accounting.ledger_accounts.list()`: `response.data.[].custom_fields.[]` **Changed**\n* `apideck.accounting.ledger_accounts.create()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.accounting.ledger_accounts.get()`: `response.data.custom_fields.[]` **Changed**\n* `apideck.accounting.ledger_accounts.update()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.accounting.credit_notes.list()`: `response.data.[].line_items.[].custom_fields.[]` **Changed**\n* `apideck.accounting.credit_notes.create()`: \n * `request.line_items.[].custom_fields.[]` **Changed**\n* `apideck.accounting.credit_notes.get()`: `response.data.line_items.[].custom_fields.[]` **Changed**\n* `apideck.accounting.credit_notes.update()`: \n * `request.line_items.[].custom_fields.[]` **Changed**\n* `apideck.accounting.customers.list()`: `response.data.[].custom_fields.[]` **Changed**\n* `apideck.accounting.customers.create()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.accounting.customers.get()`: `response.data.custom_fields.[]` **Changed**\n* `apideck.accounting.customers.update()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.accounting.suppliers.list()`: `response.data.[].custom_fields.[]` **Changed**\n* `apideck.accounting.suppliers.create()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.accounting.suppliers.get()`: `response.data.custom_fields.[]` **Changed**\n* `apideck.accounting.suppliers.update()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.accounting.payments.list()`: `response.data.[].custom_fields.[]` **Changed**\n* `apideck.accounting.payments.create()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.accounting.payments.get()`: `response.data.custom_fields.[]` **Changed**\n* `apideck.accounting.payments.update()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.accounting.refunds.list()`: `response.data.[].line_items.[].custom_fields.[]` **Changed**\n* `apideck.accounting.refunds.create()`: \n * `request.line_items.[].custom_fields.[]` **Changed**\n* `apideck.accounting.refunds.get()`: `response.data.line_items.[].custom_fields.[]` **Changed**\n* `apideck.accounting.refunds.update()`: \n * `request.line_items.[].custom_fields.[]` **Changed**\n* `apideck.accounting.company_info.get()`: `response.data.default_sales_tax.custom_fields.[]` **Changed**\n* `apideck.accounting.journal_entries.list()`: `response.data.[].custom_fields.[]` **Changed**\n* `apideck.accounting.journal_entries.create()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.accounting.journal_entries.get()`: `response.data.custom_fields.[]` **Changed**\n* `apideck.accounting.journal_entries.update()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.accounting.general_ledger_transactions.list()`: `response.data.[].custom_fields.[]` **Changed**\n* `apideck.accounting.general_ledger_transactions.get()`: `response.data.custom_fields.[]` **Changed**\n* `apideck.accounting.purchase_orders.list()`: `response.data.[].line_items.[].custom_fields.[]` **Changed**\n* `apideck.accounting.purchase_orders.create()`: \n * `request.line_items.[].custom_fields.[]` **Changed**\n* `apideck.accounting.purchase_orders.get()`: `response.data.line_items.[].custom_fields.[]` **Changed**\n* `apideck.accounting.purchase_orders.update()`: \n * `request.line_items.[].custom_fields.[]` **Changed**\n* `apideck.accounting.attachments.list()`: `response.data.[].file_url` **Added**\n* `apideck.accounting.attachments.get()`: `response.data.file_url` **Added**\n* `apideck.accounting.attachments.download()`: `request.follow_redirects` **Added**\n* `apideck.accounting.bank_accounts.list()`: `response.data.[].custom_fields.[]` **Changed**\n* `apideck.accounting.bank_accounts.create()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.accounting.bank_accounts.get()`: `response.data.custom_fields.[]` **Changed**\n* `apideck.accounting.bank_accounts.update()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.accounting.bill_payments.list()`: `response.data.[].custom_fields.[]` **Changed**\n* `apideck.accounting.bill_payments.create()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.accounting.bill_payments.get()`: `response.data.custom_fields.[]` **Changed**\n* `apideck.accounting.bill_payments.update()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.accounting.expenses.list()`: `response.data.[].custom_fields.[]` **Changed**\n* `apideck.accounting.expenses.create()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.accounting.expenses.get()`: `response.data.custom_fields.[]` **Changed**\n* `apideck.accounting.expenses.update()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.accounting.bank_feed_accounts.list()`: `response.data.[]` **Changed**\n* `apideck.accounting.bank_feed_accounts.create()`: `request` **Changed**\n* `apideck.accounting.bank_feed_accounts.get()`: `response.data` **Changed**\n* `apideck.accounting.bank_feed_accounts.update()`: `request` **Changed**\n* `apideck.accounting.bank_feed_statements.list()`: `response.data.[].transactions.[].merchant_category_code` **Added**\n* `apideck.accounting.bank_feed_statements.create()`: \n * `request.transactions.[].merchant_category_code` **Added**\n* `apideck.accounting.bank_feed_statements.get()`: `response.data.transactions.[].merchant_category_code` **Added**\n* `apideck.accounting.bank_feed_statements.update()`: \n * `request.transactions.[].merchant_category_code` **Added**\n* `apideck.accounting.quotes.list()`: `response.data.[].line_items.[].custom_fields.[]` **Changed**\n* `apideck.accounting.quotes.create()`: \n * `request.line_items.[].custom_fields.[]` **Changed**\n* `apideck.accounting.quotes.get()`: `response.data.line_items.[].custom_fields.[]` **Changed**\n* `apideck.accounting.quotes.update()`: \n * `request.line_items.[].custom_fields.[]` **Changed**\n* `apideck.accounting.projects.list()`: `response.data.[].custom_fields.[]` **Changed**\n* `apideck.accounting.projects.create()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.accounting.projects.get()`: `response.data.custom_fields.[]` **Changed**\n* `apideck.accounting.projects.update()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.accounting.employees.list()`: `response.data.[].custom_fields.[]` **Changed**\n* `apideck.accounting.employees.create()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.accounting.employees.get()`: `response.data.custom_fields.[]` **Changed**\n* `apideck.accounting.employees.update()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.accounting.expense_reports.list()`: `response.data.[].custom_fields.[]` **Changed**\n* `apideck.accounting.expense_reports.create()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.accounting.expense_reports.get()`: `response.data.custom_fields.[]` **Changed**\n* `apideck.accounting.expense_reports.update()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.ats.jobs.list()`: `response.data.[].custom_fields.[]` **Changed**\n* `apideck.ats.jobs.create()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.ats.jobs.get()`: `response.data.custom_fields.[]` **Changed**\n* `apideck.ats.jobs.update()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.ats.applicants.list()`: `response.data.[].custom_fields.[]` **Changed**\n* `apideck.ats.applicants.create()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.ats.applicants.get()`: `response.data.custom_fields.[]` **Changed**\n* `apideck.ats.applicants.update()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.crm.companies.list()`: `response.data.[].custom_fields.[]` **Changed**\n* `apideck.crm.companies.create()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.crm.companies.get()`: `response.data.custom_fields.[]` **Changed**\n* `apideck.crm.companies.update()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.crm.contacts.list()`: `response.data.[].custom_fields.[]` **Changed**\n* `apideck.crm.contacts.create()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.crm.contacts.get()`: `response.data.custom_fields.[]` **Changed**\n* `apideck.crm.contacts.update()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.crm.opportunities.list()`: `response.data.[].custom_fields.[]` **Changed**\n* `apideck.crm.opportunities.create()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.crm.opportunities.get()`: `response.data.custom_fields.[]` **Changed**\n* `apideck.crm.opportunities.update()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.crm.leads.list()`: `response.data.[].custom_fields.[]` **Changed**\n* `apideck.crm.leads.create()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.crm.leads.get()`: `response.data.custom_fields.[]` **Changed**\n* `apideck.crm.leads.update()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.crm.lists.list()`: `response.data.[].custom_fields.[]` **Changed**\n* `apideck.crm.lists.get()`: `response.data.custom_fields.[]` **Changed**\n* `apideck.crm.activities.list()`: `response.data.[].custom_fields.[]` **Changed**\n* `apideck.crm.activities.create()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.crm.activities.get()`: `response.data.custom_fields.[]` **Changed**\n* `apideck.crm.activities.update()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.file_storage.files.download()`: `request.follow_redirects` **Added**\n* `apideck.hris.employees.list()`: `response.data.[].custom_fields.[]` **Changed**\n* `apideck.hris.employees.create()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.hris.employees.get()`: `response.data.custom_fields.[]` **Changed**\n* `apideck.hris.employees.update()`: \n * `request.custom_fields.[]` **Changed**\n* `apideck.hris.employee_schedules.list()`: `response.data.employee.custom_fields.[]` **Changed**\n* `apideck.proxy.get()`: `request.follow_redirects` **Added**\n* `apideck.proxy.options()`: `request.follow_redirects` **Added**\n* `apideck.proxy.post()`: `request.follow_redirects` **Added**\n* `apideck.proxy.put()`: `request.follow_redirects` **Added**\n* `apideck.proxy.patch()`: `request.follow_redirects` **Added**\n* `apideck.proxy.delete()`: `request.follow_redirects` **Added**\n" trackedFiles: .devcontainer/README.md: last_write_checksum: sha1:07adb0c0c051a9be4d479ea06461f3a9b3bbeb2f @@ -19962,9 +20321,9 @@ trackedFiles: docs/models/accountingattachmentsdownloadglobals.md: last_write_checksum: sha1:d64065eb41a12319fd104e55d9d04fd5477b43fb docs/models/accountingattachmentsdownloadrequest.md: - last_write_checksum: sha1:0be1c6f72f216de04f8b80bdab561e69c1b7e349 + last_write_checksum: sha1:a19979dc4ddf58d5a3726c74b255baeaf4b25cb3 docs/models/accountingattachmentsdownloadresponse.md: - last_write_checksum: sha1:ef45ecab442529876c4ca6a255ef1655cf6bf5cc + last_write_checksum: sha1:383e1cf6bb686cc290c984e7c6e03ef938b14e1d docs/models/accountingattachmentsoneglobals.md: last_write_checksum: sha1:4e914f3de7390a63d30a09b7102c0b3c50ca71aa docs/models/accountingattachmentsonerequest.md: @@ -20563,6 +20922,44 @@ trackedFiles: last_write_checksum: sha1:4cd02162cbd609359ee1fc548f247bfecd6cbba2 docs/models/accountingmethod.md: last_write_checksum: sha1:d3df43a44022000aca2587b3d6692cdf048ddb32 + docs/models/accountingpaymentmethod.md: + last_write_checksum: sha1:bb68d15a59075cb49d77ac90b06055b584c92211 + docs/models/accountingpaymentmethodinput.md: + last_write_checksum: sha1:0aebcfe5bd81c838ed9c5147632d93215f58e3f9 + docs/models/accountingpaymentmethodsaddglobals.md: + last_write_checksum: sha1:2ccb3e98fc8fcfe5e1695bcec95da0c5a06ab3da + docs/models/accountingpaymentmethodsaddrequest.md: + last_write_checksum: sha1:dc718c42f168c085666b7f1ebbab464da3fc8303 + docs/models/accountingpaymentmethodsaddresponse.md: + last_write_checksum: sha1:83a5f352b836e38571a97332513184c6a7488555 + docs/models/accountingpaymentmethodsallglobals.md: + last_write_checksum: sha1:7ed74ea2b8c756b555ae6b9a77d317a1dfa1c930 + docs/models/accountingpaymentmethodsallrequest.md: + last_write_checksum: sha1:309879900ca551aba3042652fa40cc48943807b0 + docs/models/accountingpaymentmethodsallresponse.md: + last_write_checksum: sha1:ba3a375a8d2a7b586a71357e62aa4f81895c704e + docs/models/accountingpaymentmethodsdeleteglobals.md: + last_write_checksum: sha1:677923150ab30d47c2b55dd5c01008959ea0ead1 + docs/models/accountingpaymentmethodsdeleterequest.md: + last_write_checksum: sha1:4742c70522ce493fd2f8c730438eaa022199f4a4 + docs/models/accountingpaymentmethodsdeleteresponse.md: + last_write_checksum: sha1:76b3894fb88534e754791ab5d8ac03841582b475 + docs/models/accountingpaymentmethodsoneglobals.md: + last_write_checksum: sha1:dc03ca922d785bb4d83b079f550788fdeb4f0ab6 + docs/models/accountingpaymentmethodsonerequest.md: + last_write_checksum: sha1:8812b4e95155005a7a8e578c976f00ad596d1bda + docs/models/accountingpaymentmethodsoneresponse.md: + last_write_checksum: sha1:d83b4641963844328e0eb131a24b5c36fa2bb1ec + docs/models/accountingpaymentmethodstatus.md: + last_write_checksum: sha1:c294ee3fe6168513ca0672df771774e77a172e6c + docs/models/accountingpaymentmethodsupdateglobals.md: + last_write_checksum: sha1:37ae262233fef0841b54ddfe88a2b4ab071f65fa + docs/models/accountingpaymentmethodsupdaterequest.md: + last_write_checksum: sha1:ade8f12c4a8171b79d5d977fa3ab2a91c8a8d534 + docs/models/accountingpaymentmethodsupdateresponse.md: + last_write_checksum: sha1:b430bd97548cb467a5c378c6acbed5994c74f10d + docs/models/accountingpaymentmethodtype.md: + last_write_checksum: sha1:071ed412216ef374b9d96043c3e192885db886b4 docs/models/accountingpaymentsaddglobals.md: last_write_checksum: sha1:d5968c6f81d95414ccef7ae3c9511bb15ac65ba9 docs/models/accountingpaymentsaddrequest.md: @@ -20721,6 +21118,36 @@ trackedFiles: last_write_checksum: sha1:712ad48af3b704b5749f357dd2992d5c762ec573 docs/models/accountingrefundsupdateresponse.md: last_write_checksum: sha1:678f3673a94cde429faa5179b81b7765caa6649e + docs/models/accountingsalesreceiptsaddglobals.md: + last_write_checksum: sha1:e1b41ca9e0c29986cf6eebc137dd415b5d1e0eba + docs/models/accountingsalesreceiptsaddrequest.md: + last_write_checksum: sha1:244b40f29b36cc40a5980ee336777003df2e0046 + docs/models/accountingsalesreceiptsaddresponse.md: + last_write_checksum: sha1:a23078b1487a9b80f092fa8e8cd519834cd9c3ee + docs/models/accountingsalesreceiptsallglobals.md: + last_write_checksum: sha1:743e89ab29d42103367febe76bea435448273953 + docs/models/accountingsalesreceiptsallrequest.md: + last_write_checksum: sha1:6ca28ba09472cb9a029a6c12526b853ec712933b + docs/models/accountingsalesreceiptsallresponse.md: + last_write_checksum: sha1:2d6bcae5e6c6e7d43e0c9a5b02ee58a28cb1fc26 + docs/models/accountingsalesreceiptsdeleteglobals.md: + last_write_checksum: sha1:899490360e0bbc21d797a5bc15fa049ed4c7bf0b + docs/models/accountingsalesreceiptsdeleterequest.md: + last_write_checksum: sha1:019b833934d7935d40bd946ce7e10426ee70a367 + docs/models/accountingsalesreceiptsdeleteresponse.md: + last_write_checksum: sha1:d5ba5bb97f0788ef033ecec639b1be46d98274e2 + docs/models/accountingsalesreceiptsoneglobals.md: + last_write_checksum: sha1:166144bde5b11f58e753138e0bfca307adef6ca4 + docs/models/accountingsalesreceiptsonerequest.md: + last_write_checksum: sha1:b1e36ea453388bb4ab6d3dade32ff52e4f58bc17 + docs/models/accountingsalesreceiptsoneresponse.md: + last_write_checksum: sha1:bf86504ec9233d8bd68967890fb894aa14911245 + docs/models/accountingsalesreceiptsupdateglobals.md: + last_write_checksum: sha1:1cf2b38c4a242a6de9fdcc30aac72e165f3800f4 + docs/models/accountingsalesreceiptsupdaterequest.md: + last_write_checksum: sha1:bc7918fc286e44e742d01fc6338ade15988785c0 + docs/models/accountingsalesreceiptsupdateresponse.md: + last_write_checksum: sha1:8c0a8a3ed70d751d5f06d8b78638765f722bc50a docs/models/accountingsubsidiariesaddglobals.md: last_write_checksum: sha1:f6227d13ae58a33377d04e533945cdf374da6522 docs/models/accountingsubsidiariesaddrequest.md: @@ -21010,7 +21437,7 @@ trackedFiles: docs/models/atsjobsupdateresponse.md: last_write_checksum: sha1:463c65790680826784ddc337e6b35687615e08f3 docs/models/attachment.md: - last_write_checksum: sha1:73960c48c78ce8693bb7b33aa476cfedf7e24769 + last_write_checksum: sha1:ed365ee747c0824917f6ea95226cd6b7ad9552eb docs/models/attachmentreference.md: last_write_checksum: sha1:e1309515117268d54df56cf96fcd22651a6b174e docs/models/attachmentreferencetype.md: @@ -21070,9 +21497,9 @@ trackedFiles: docs/models/bankaccounttype.md: last_write_checksum: sha1:6a9f6db9724072d065371f2803f6f6d9f977be70 docs/models/bankfeedaccount.md: - last_write_checksum: sha1:20c0daa58d282e51e9ac91248ae11a9c05b4f12c + last_write_checksum: sha1:1ceeb92c0c65633780cee02c814bdecfac7d6b31 docs/models/bankfeedaccountinput.md: - last_write_checksum: sha1:5ce8fe9b54522b721e5a632d3f3aacf7b17df691 + last_write_checksum: sha1:172bce2600471159cd67bcd0561998d752036103 docs/models/bankfeedstatement.md: last_write_checksum: sha1:6192257d44e888e76cfab4d060f33bf0373efbc1 docs/models/bankfeedstatementinput.md: @@ -21397,6 +21824,8 @@ trackedFiles: last_write_checksum: sha1:9e80122d2f69bcd8d41d12226f23c4aed0154dad docs/models/createopportunityresponse.md: last_write_checksum: sha1:0e40997d01afd3e9144b5b5e683f872f149e4f50 + docs/models/createpaymentmethodresponse.md: + last_write_checksum: sha1:1846edadf9f9e66ae153bbde3a78b025539c274f docs/models/createpaymentresponse.md: last_write_checksum: sha1:d277e8cb9b5d8df206a6ecb84fbf52c08a5c46c2 docs/models/createpipelineresponse.md: @@ -21409,6 +21838,8 @@ trackedFiles: last_write_checksum: sha1:36b0622ca557b64b7a7d537287b9959e21698e49 docs/models/createrefundresponse.md: last_write_checksum: sha1:629f87a8047b6774ebcb11af139b4d1e7b2a1864 + docs/models/createsalesreceiptresponse.md: + last_write_checksum: sha1:7c8592e8feb5c28f64df5eeee1c1eb1f32cde51a docs/models/createsessionresponse.md: last_write_checksum: sha1:dd34ea11c50835083f9b4c7012908fc593810920 docs/models/createsessionresponsedata.md: @@ -21798,9 +22229,9 @@ trackedFiles: docs/models/customfield1value.md: last_write_checksum: sha1:8b8a8e2eff2b0f451da1030a328a2cdd8eeba8cb docs/models/customfield1.md: - last_write_checksum: sha1:66da9e38480f812326bc1672753c781822ce53ae + last_write_checksum: sha1:cc4f42dc768fdf52a209e92a188b155f8007ddf0 docs/models/customfield2.md: - last_write_checksum: sha1:80c125b23bb1206e2c2be9f5032f2587c90e1058 + last_write_checksum: sha1:a65cd2adf4548b3c7fc5a92c49cb43d00b37d32c docs/models/customfieldfinder.md: last_write_checksum: sha1:57e60df631e4df801506a3aae94ad10b0d6df524 docs/models/customfieldvalue.md: @@ -21923,6 +22354,8 @@ trackedFiles: last_write_checksum: sha1:06d43ab0b372274f86b2d804a2e45c785e5d2df8 docs/models/deleteopportunityresponse.md: last_write_checksum: sha1:0f77c392b805fa9bb25f4ca3e6a6b43689c283fe + docs/models/deletepaymentmethodresponse.md: + last_write_checksum: sha1:8a3a3577115e2845f2951b2210552bebc4989a54 docs/models/deletepaymentresponse.md: last_write_checksum: sha1:073cae4a9cd9ac15f22d738d6951b531e308362b docs/models/deletepipelineresponse.md: @@ -21935,6 +22368,8 @@ trackedFiles: last_write_checksum: sha1:b1e3023de49c59bd25ae8fdcec06ab1e81de34ad docs/models/deleterefundresponse.md: last_write_checksum: sha1:832fe9fcb47ea00658f46531f008ef8c8735caeb + docs/models/deletesalesreceiptresponse.md: + last_write_checksum: sha1:a874b7a4d1b2bea483a65fc346b0d8e064707037 docs/models/deletesharedlinkresponse.md: last_write_checksum: sha1:6935c7d9958068a8193e4c8daa7bdff8578f2e4a docs/models/deletesubsidiaryresponse.md: @@ -22268,15 +22703,15 @@ trackedFiles: docs/models/filestoragefilesdownloadglobals.md: last_write_checksum: sha1:556101bac1aef633083c2248cc6df59d8035837b docs/models/filestoragefilesdownloadrequest.md: - last_write_checksum: sha1:4dcc000115972c3e2a6e9908b4a05101bd446a26 + last_write_checksum: sha1:d4f931fc36abe82356316634c69ae428b45eb1f8 docs/models/filestoragefilesdownloadresponse.md: - last_write_checksum: sha1:ba6dbb81552d7d8f4262e88ffb1e49ae9ea97698 + last_write_checksum: sha1:4460d895c7b6958f2bb5e48297aafaea2e19b56d docs/models/filestoragefilesexportglobals.md: last_write_checksum: sha1:a09eb746cba79aee7e5db2d70d262ba613fbc9c9 docs/models/filestoragefilesexportrequest.md: last_write_checksum: sha1:b81a34c2ef98618821e0bc1af4f23c852bb2d6a1 docs/models/filestoragefilesexportresponse.md: - last_write_checksum: sha1:ebf87eb3716b6649553bc1370e6951482671310b + last_write_checksum: sha1:8663f61f3b6e002de5083c9d297240a458ccb0de docs/models/filestoragefilesoneglobals.md: last_write_checksum: sha1:8667809d227995e38279e7b5c599ac0cd1434f45 docs/models/filestoragefilesonerequest.md: @@ -22653,6 +23088,10 @@ trackedFiles: last_write_checksum: sha1:a8b104cf91f5887ce1d95b0da9268017aa133f84 docs/models/getopportunityresponse.md: last_write_checksum: sha1:39842c5338662682b39b4ffb60e3031b34b8ace3 + docs/models/getpaymentmethodresponse.md: + last_write_checksum: sha1:2b27d7f2f080ee93107da2b9619bde270a7af614 + docs/models/getpaymentmethodsresponse.md: + last_write_checksum: sha1:b78c654b2e7544776ab2d131c555aed0ce00689a docs/models/getpaymentresponse.md: last_write_checksum: sha1:94f887c64d184b75d032b8e2ede0251683d28cfe docs/models/getpaymentsresponse.md: @@ -22687,6 +23126,10 @@ trackedFiles: last_write_checksum: sha1:df8bc68cdc6ba445a4184a9394ceeec526c618ae docs/models/getrefundsresponse.md: last_write_checksum: sha1:d89cff97abbfe162bc94cb8aa112ef0424fe407c + docs/models/getsalesreceiptresponse.md: + last_write_checksum: sha1:c87ca786706d30ee5d973fa37213d82c5e30b1a0 + docs/models/getsalesreceiptsresponse.md: + last_write_checksum: sha1:beceda04a5219ba9f38df7dbf089129cb89d18d5 docs/models/getsharedlinkresponse.md: last_write_checksum: sha1:afe7af9bce4b50c193bb0ed284a170557622097d docs/models/getsharedlinksresponse.md: @@ -23356,45 +23799,45 @@ trackedFiles: docs/models/proxydeleteproxyglobals.md: last_write_checksum: sha1:c16f7d91cb601bda587c2de8d7d9977d2c34ffb7 docs/models/proxydeleteproxyrequest.md: - last_write_checksum: sha1:f3246d3ee382d88aff21a6b002674af60e24c873 + last_write_checksum: sha1:aa12ea69cd050de6217a9f8c94e5a9589d922afa docs/models/proxydeleteproxyresponse.md: - last_write_checksum: sha1:c85fe51f772a0acc912f2bb547dc6b4749bd566c + last_write_checksum: sha1:a983cb244245c4f0c0cae936cd6913ee8f15f919 docs/models/proxygetproxyglobals.md: last_write_checksum: sha1:61c8f5876078eaaa314435082e1752e0e77144d3 docs/models/proxygetproxyrequest.md: - last_write_checksum: sha1:e699753055b99d3dc1c9213b29980995588edd5e + last_write_checksum: sha1:532e5a64903d9a3f30afc0f738c66dd77fb7e8b2 docs/models/proxygetproxyresponse.md: - last_write_checksum: sha1:c7987d214a6e56fd82a7f9ec0e6100c56f7fb44e + last_write_checksum: sha1:e127b36aef7f40dbab5d53dc2191802e31284edc docs/models/proxyoptionsproxyglobals.md: last_write_checksum: sha1:0477e45ae5344eda3728f1803ffa3f5de9bce4f3 docs/models/proxyoptionsproxyrequest.md: - last_write_checksum: sha1:47a0b2711600fc471800fdc76be57686a738fcc8 + last_write_checksum: sha1:ea665408054ed6e7370dfe3d3500d5c9ea78e0ed docs/models/proxyoptionsproxyresponse.md: - last_write_checksum: sha1:d5822a6230461dd0a40ca5371b0458c1db2f135a + last_write_checksum: sha1:1c9fadc37b1686a812f94ec6b38524edb2e78e81 docs/models/proxypatchproxyglobals.md: last_write_checksum: sha1:073afd34d739d9466ce6683e1f613fad77c779b0 docs/models/proxypatchproxyrequest.md: - last_write_checksum: sha1:cb8915b22e5094f7d4d163bd5e9277e6c881f8e7 + last_write_checksum: sha1:49a629e6b8c3db8b66bbebb3e64b7abcf511a025 docs/models/proxypatchproxyrequestbody1.md: last_write_checksum: sha1:e7e8bbb12c000abebef2594ac8da50e8a7f74560 docs/models/proxypatchproxyrequestbody3.md: last_write_checksum: sha1:8f6adca137e42046ebd2bd1cec5adfaf0850b602 docs/models/proxypatchproxyresponse.md: - last_write_checksum: sha1:3a1a13be029c158f57c8e5287282d9ac95edebee + last_write_checksum: sha1:ff9f22b3b7376e27d391da83bdd503ccbf19330a docs/models/proxypostproxyglobals.md: last_write_checksum: sha1:5b023a35a7f26e74d138b6aa9a9339734f3c4b0b docs/models/proxypostproxyrequest.md: - last_write_checksum: sha1:fc83ee18297c0f82a512cc984f0ad796014bd923 + last_write_checksum: sha1:3c6a16f1d589ffd20ab39a897186b9e534c3b894 docs/models/proxypostproxyresponse.md: - last_write_checksum: sha1:efd5286040540fba8736515e09f4acc9daa66fb9 + last_write_checksum: sha1:5112b4a0a242d86caa25ed8c51819037e9c1d579 docs/models/proxyputproxyglobals.md: last_write_checksum: sha1:cf2f5a4fb62f46d95fe7ca111aa2c7223dfc0ac0 docs/models/proxyputproxyrequest.md: - last_write_checksum: sha1:5aee7e6878a713423711c762405a8db83e9e6944 + last_write_checksum: sha1:21b0295daf807acf161d32080516d8102d5e6764 docs/models/proxyputproxyrequestbody1.md: last_write_checksum: sha1:c4945cce68426332675be1972315dddc4c95deca docs/models/proxyputproxyresponse.md: - last_write_checksum: sha1:3d75863f2154c8497c190d6c9b5dba28563adfe1 + last_write_checksum: sha1:ffc9d7ec038cb805a90ab03f911db135c42b2556 docs/models/purchasedetails.md: last_write_checksum: sha1:a15d102e5f9ce95f490d38d6427b419839c25128 docs/models/purchaseorder.md: @@ -23469,6 +23912,16 @@ trackedFiles: last_write_checksum: sha1:145626e28eaec2cee61b2ec4135e9319fdd00418 docs/models/salesdetails.md: last_write_checksum: sha1:59e01428f27a08d8e73d5b7caf8ecbcadc454174 + docs/models/salesreceipt.md: + last_write_checksum: sha1:bd0399b86d707a0392a94f85480c427456ba4e39 + docs/models/salesreceiptinput.md: + last_write_checksum: sha1:49056d9f9c5b9dec265bbebf7034a7fe7a5f31c2 + docs/models/salesreceiptsfilter.md: + last_write_checksum: sha1:21faeceb0026b8150f11926d5852258aadab2ee4 + docs/models/salesreceiptssort.md: + last_write_checksum: sha1:cf8f276110d210ace9166cc204a54c73daf12d40 + docs/models/salesreceiptssortby.md: + last_write_checksum: sha1:3192727a3c47327233213105afde62ab98560689 docs/models/schedule.md: last_write_checksum: sha1:ccc6fd5f3721e9dbdaae3d1f47607f54d793652e docs/models/schedulestatus.md: @@ -23636,7 +24089,7 @@ trackedFiles: docs/models/trackingitem.md: last_write_checksum: sha1:47d20fff20586195a056c87a99dd0e005ff2d472 docs/models/transactions.md: - last_write_checksum: sha1:2f923ff552a7b75cfb3d22c0127ad02183e383a9 + last_write_checksum: sha1:74ba83a5e0aac4089b0bf5787ec7b18e624bafc9 docs/models/transactiontype.md: last_write_checksum: sha1:85ddb6b9e257d16b7d326080d2c944c6d13ec29c docs/models/two.md: @@ -23763,6 +24216,8 @@ trackedFiles: last_write_checksum: sha1:868544261693c7737d8f4bb4a5769fa28e2e8d61 docs/models/updateopportunityresponse.md: last_write_checksum: sha1:41622428cc6bec173d0270f5c900bd914f5c178b + docs/models/updatepaymentmethodresponse.md: + last_write_checksum: sha1:2c5fa63cd90567ec6773dc5e5706d394d1e81268 docs/models/updatepaymentresponse.md: last_write_checksum: sha1:4e5dc8c5c60cf9f2c91064e2079ef1cff13b1fe0 docs/models/updatepipelineresponse.md: @@ -23775,6 +24230,8 @@ trackedFiles: last_write_checksum: sha1:3b33d9c68bac0255ffc11185942448ec2b0b2153 docs/models/updaterefundresponse.md: last_write_checksum: sha1:51d4bb2d366b56f35c5bfbf3576395d550432f95 + docs/models/updatesalesreceiptresponse.md: + last_write_checksum: sha1:485412714051b8d632eb5a401057310a8963dce9 docs/models/updatesharedlinkresponse.md: last_write_checksum: sha1:ccd7d33d0d9005e8b36e9f09cda40dfa93ce222c docs/models/updatesubsidiaryresponse.md: @@ -24060,13 +24517,13 @@ trackedFiles: docs/sdks/applications/README.md: last_write_checksum: sha1:46a22b489c4872fb33f7b73705232d893785bc3e docs/sdks/attachments/README.md: - last_write_checksum: sha1:e3747c8b49f54270c7f8cd181cdcf8c2fc72f4bf + last_write_checksum: sha1:f12d9eb3bda57db3e3aa01c589dcee494124e6dd docs/sdks/balancesheetsdk/README.md: last_write_checksum: sha1:47308e0099d4f7a4de9fd131ebcf4eb2f53f26e2 docs/sdks/bankaccounts/README.md: last_write_checksum: sha1:6d779f048c175eeb51d207b78bed7750858dc694 docs/sdks/bankfeedaccounts/README.md: - last_write_checksum: sha1:a50fcab806b8a1a580c75a9aa57995ce1f1dcbcc + last_write_checksum: sha1:a4ec29b64e1246c75f82a080016a0e11a669dc49 docs/sdks/bankfeedstatements/README.md: last_write_checksum: sha1:dc4e86b81dc7c23d30dba5ebb12fba03d4be8850 docs/sdks/billpayments/README.md: @@ -24146,7 +24603,7 @@ trackedFiles: docs/sdks/expenses/README.md: last_write_checksum: sha1:807b3f70c96441c34b9d080b79dda4a57df8f52a docs/sdks/files/README.md: - last_write_checksum: sha1:6fafca167285487e1d60275037ff6cb4ac3978f3 + last_write_checksum: sha1:0057885a8e80e3571519cf5cada56d0fe7b2bf6e docs/sdks/folders/README.md: last_write_checksum: sha1:2997e8070c3ac42b86e6a3b8e611ab6a468c54ab docs/sdks/generalledgertransactions/README.md: @@ -24179,6 +24636,8 @@ trackedFiles: last_write_checksum: sha1:d90f239920b2833dc8dc548aa9c88c3efc5f4f67 docs/sdks/orders/README.md: last_write_checksum: sha1:dcb1b40d536f93c51a86aba423dbf130425ee888 + docs/sdks/paymentmethods/README.md: + last_write_checksum: sha1:9f492b450aae25dc5031f82fac4e210af3e27b9b docs/sdks/payments/README.md: last_write_checksum: sha1:8bcce17871aa6b721bf6cf65c057187c41ea325f docs/sdks/payrolls/README.md: @@ -24192,13 +24651,15 @@ trackedFiles: docs/sdks/projects/README.md: last_write_checksum: sha1:f267cb7704f6dcd0b1cab8e48babb1ca8f065bea docs/sdks/proxy/README.md: - last_write_checksum: sha1:760057f2466a416fc7462f42efb264893b645bfd + last_write_checksum: sha1:f639cf9757ae90a3c0f188472322647aa5d24769 docs/sdks/purchaseorders/README.md: last_write_checksum: sha1:fb84ad40ffac3213e8249afbb310b4c4d5b4dfed docs/sdks/quotes/README.md: last_write_checksum: sha1:9419f691ddabb312b0a912a6f0a98da028a96ba1 docs/sdks/refunds/README.md: last_write_checksum: sha1:f02f4f6ba8629d448e1708c0a82e505f526c7079 + docs/sdks/salesreceipts/README.md: + last_write_checksum: sha1:5278da59bfc684ed9a8383cffc4cdf38e4058307 docs/sdks/sessions/README.md: last_write_checksum: sha1:d68c81526c32b02dadeaf7b116edf23931eec337 docs/sdks/sharedlinks/README.md: @@ -24230,7 +24691,7 @@ trackedFiles: pylintrc: last_write_checksum: sha1:ec6665a4862060890cf4c6ba61438d11decf5c3c pyproject.toml: - last_write_checksum: sha1:6ac4dade3f8fb20f441a81afe18c5bf2a68b8145 + last_write_checksum: sha1:bb13d309654b3239b54edd03be305401946d854a scripts/prepare_readme.py: last_write_checksum: sha1:798a05bafe4fbbfff5b67037866fa25efc52f11a scripts/publish.sh: @@ -24244,9 +24705,9 @@ trackedFiles: src/apideck_unify/_hooks/types.py: last_write_checksum: sha1:d57be38e644de01983a9224b9733ae0add898d43 src/apideck_unify/_version.py: - last_write_checksum: sha1:9cc39c32648dba7c105b813caab897829c618bfb + last_write_checksum: sha1:46aad06cdb4f70dca47706114bf53756ea1d6df8 src/apideck_unify/accounting.py: - last_write_checksum: sha1:63ea555e29266c0cbe993e2bddf21ffecd9b02b9 + last_write_checksum: sha1:b6ffaba7a3af019489bff091acec26c331b2acbc src/apideck_unify/activities.py: last_write_checksum: sha1:d0d893423acbd8366c1581b05f4f76efffc9ef23 src/apideck_unify/agedcreditors_sdk.py: @@ -24260,7 +24721,7 @@ trackedFiles: src/apideck_unify/apideck_departments.py: last_write_checksum: sha1:9c6e4af55297ccb825e8bf5bb5c4089e53e344b5 src/apideck_unify/apideck_employees.py: - last_write_checksum: sha1:16b462466cb92e469dd907c54aec6ecd7511c4fa + last_write_checksum: sha1:9c74abf83c80b2002e4abe0e612e8582bf87c272 src/apideck_unify/apideck_hris_companies.py: last_write_checksum: sha1:8b1eb48fe3ec7b1d4d84e283a19556d98160d3ca src/apideck_unify/apiresourcecoverage_sdk.py: @@ -24276,21 +24737,21 @@ trackedFiles: src/apideck_unify/ats.py: last_write_checksum: sha1:0d5c5cedbfeb231840eb69958e0240f2fbb630f8 src/apideck_unify/attachments.py: - last_write_checksum: sha1:80d48e3d3ea5c0dfe89aab50435ded5c77017570 + last_write_checksum: sha1:66fe86f178abac2c2593fdd47a56139cec91ae9b src/apideck_unify/balancesheet_sdk.py: last_write_checksum: sha1:31ef71c6f4e4d19f5bc4eb0b677516d43158d2ce src/apideck_unify/bankaccounts.py: last_write_checksum: sha1:ee3fcef1e3f733cc7167a550904261fed2ba8ae6 src/apideck_unify/bankfeedaccounts.py: - last_write_checksum: sha1:3ce766d9daa3d36b75fca67fb551bb40c7c5100c + last_write_checksum: sha1:ff0441a7ef51fb46e591287a137b0cfc34bb2340 src/apideck_unify/bankfeedstatements.py: last_write_checksum: sha1:bb28775794f79365f01b373c7d19da7670b3cbb4 src/apideck_unify/basesdk.py: last_write_checksum: sha1:02f62bd40dfedb9697666050be333be287dd5a5b src/apideck_unify/billpayments.py: - last_write_checksum: sha1:30e7111d4df64bff502a27733255ea1b8fbb0fe2 + last_write_checksum: sha1:c7650954fb380a4f72664203ad03f483457240ae src/apideck_unify/bills.py: - last_write_checksum: sha1:d5c9b128cbb95da88e260a13a2b747edf9c476df + last_write_checksum: sha1:3f03a1fd9f4e59bd4e840e24c831cfeec55bac62 src/apideck_unify/categories.py: last_write_checksum: sha1:e1ea6fe95dd3b5357c4b6dab95d0cf6e78f33750 src/apideck_unify/collections.py: @@ -24334,7 +24795,7 @@ trackedFiles: src/apideck_unify/createcallback.py: last_write_checksum: sha1:fa6cddb89b59b3890fbc0a06c4b7730e91e76f2e src/apideck_unify/creditnotes.py: - last_write_checksum: sha1:c3c18f3cf2946eb8aec09b9149f06e47f4b0a3de + last_write_checksum: sha1:025d699ff7c2aed7c8f662aec4472f82240ef4e3 src/apideck_unify/crm.py: last_write_checksum: sha1:0a3f32ca2265dd9bf40c9b5c0373685dab9e5da6 src/apideck_unify/customers.py: @@ -24358,7 +24819,7 @@ trackedFiles: src/apideck_unify/employeepayrolls.py: last_write_checksum: sha1:c84a061f34d666312600b49bf07abc88e56942a5 src/apideck_unify/employees.py: - last_write_checksum: sha1:cde502c6db47a7df56383f120efe7de5deb543e4 + last_write_checksum: sha1:cb380dd40d1645aa0ccc34a2789495d227c4ac10 src/apideck_unify/employeeschedules_sdk.py: last_write_checksum: sha1:a6be96924e77fe71013a32069043a73d29185028 src/apideck_unify/eventlogs.py: @@ -24366,11 +24827,11 @@ trackedFiles: src/apideck_unify/expensecategories.py: last_write_checksum: sha1:544e423a166f01fc368728ce058e837803221af1 src/apideck_unify/expensereports.py: - last_write_checksum: sha1:1f9eb71ffb486d1833c4892429ccc851e910a4ba + last_write_checksum: sha1:3f6f38c22128c7d4c74bb4fe4305a6c7ab1574f9 src/apideck_unify/expenses.py: - last_write_checksum: sha1:5d11fcb901f3f2924210468457aa2ad1110c8fbc + last_write_checksum: sha1:b54a66055cb6ec4c44a1128455eb1e0266e3e5cd src/apideck_unify/files.py: - last_write_checksum: sha1:d2a613a636558499fec8b923c3aa0d46a7e7e9ad + last_write_checksum: sha1:21b25dc08beaf72df1e912f498f65cb5f57846e9 src/apideck_unify/filestorage.py: last_write_checksum: sha1:cf935b847c21f965790ff3c0c664c0223aa0d78c src/apideck_unify/folders.py: @@ -24382,15 +24843,15 @@ trackedFiles: src/apideck_unify/httpclient.py: last_write_checksum: sha1:5e55338d6ee9f01ab648cad4380201a8a3da7dd7 src/apideck_unify/invoiceitems.py: - last_write_checksum: sha1:3a5fbe8a25fdcd0e9345480bb8d06a2b7c6b1b01 + last_write_checksum: sha1:81e59871780612c8d8b88ace54b3f1bc19630149 src/apideck_unify/invoices.py: - last_write_checksum: sha1:44d7c19417d38a872578e2e32fb83a98a789d4b9 + last_write_checksum: sha1:08abccca6d2b523678b625d90425d5ccd8349b9b src/apideck_unify/issuetracking.py: last_write_checksum: sha1:a18420473c9ae884dcdc562042a52205924643c5 src/apideck_unify/jobs.py: last_write_checksum: sha1:68126ac4bf72cb0457e888f727138e29fa49c498 src/apideck_unify/journalentries.py: - last_write_checksum: sha1:56c50c181c507472aa59abfaac6b9f97389114cc + last_write_checksum: sha1:d175ba6e5150ada1931a8e33dd994e58cf4022df src/apideck_unify/leads.py: last_write_checksum: sha1:b1898e48cf89d3269f10074a3a9bf5f6d6c945c3 src/apideck_unify/ledgeraccounts.py: @@ -24406,7 +24867,7 @@ trackedFiles: src/apideck_unify/messages.py: last_write_checksum: sha1:8b1e180d3c7d2ae9916b1f645460caebf5281d7b src/apideck_unify/models/__init__.py: - last_write_checksum: sha1:6a069b237cc8036b23ce7f6153c2ad322985646d + last_write_checksum: sha1:0b53ed3a40873992803c5141786f306e281b87f4 src/apideck_unify/models/accounting_agedcreditorsoneop.py: last_write_checksum: sha1:7346d1ab1c21db21995aae34c5ba01549c2786c2 src/apideck_unify/models/accounting_ageddebtorsoneop.py: @@ -24416,7 +24877,7 @@ trackedFiles: src/apideck_unify/models/accounting_attachmentsdeleteop.py: last_write_checksum: sha1:eba00e4e65bde241fb837e72df78c988d0225be3 src/apideck_unify/models/accounting_attachmentsdownloadop.py: - last_write_checksum: sha1:5ad84b9be1f12fc6afcb705956b78db3717c0a48 + last_write_checksum: sha1:18e94c55bd6d073bb3722331a680e344d363796d src/apideck_unify/models/accounting_attachmentsoneop.py: last_write_checksum: sha1:fa5720ac61d24de4f8b63fe60b534ac8cbd547be src/apideck_unify/models/accounting_attachmentsuploadop.py: @@ -24605,6 +25066,16 @@ trackedFiles: last_write_checksum: sha1:76cab42319c6418ce469635ad46fc01aecc1ca7f src/apideck_unify/models/accounting_locationsupdateop.py: last_write_checksum: sha1:e4fa5dfa5e3310a6671c8a2394616d009dd25bbc + src/apideck_unify/models/accounting_paymentmethodsaddop.py: + last_write_checksum: sha1:ec9be14742f84ea3a598cacc539f0eddea81d740 + src/apideck_unify/models/accounting_paymentmethodsallop.py: + last_write_checksum: sha1:280cebb8072486a276f818cc2e124fada47ec87d + src/apideck_unify/models/accounting_paymentmethodsdeleteop.py: + last_write_checksum: sha1:635a21ffbe957fdf1bdd5559adfe7b7c2cf45751 + src/apideck_unify/models/accounting_paymentmethodsoneop.py: + last_write_checksum: sha1:cc03ca9b8827ef131cbfcd4622058fa0aef18a74 + src/apideck_unify/models/accounting_paymentmethodsupdateop.py: + last_write_checksum: sha1:b27d0b6d11411a9cf8f2b8d9f7fa9adb5c83af7b src/apideck_unify/models/accounting_paymentsaddop.py: last_write_checksum: sha1:f85cd28902574597c452d26317586093a1a62e04 src/apideck_unify/models/accounting_paymentsallop.py: @@ -24657,6 +25128,16 @@ trackedFiles: last_write_checksum: sha1:92d7dd2501e3c6758162ceb906b0aa6083c0fab0 src/apideck_unify/models/accounting_refundsupdateop.py: last_write_checksum: sha1:8f5a05bba5934c0ae1b2532b718418200d616e0f + src/apideck_unify/models/accounting_salesreceiptsaddop.py: + last_write_checksum: sha1:5a3c20ef10911a61b5f552e2fb9d94a3ced5ff42 + src/apideck_unify/models/accounting_salesreceiptsallop.py: + last_write_checksum: sha1:a40e94796030d2151aa461e4c65cdbd4b6339513 + src/apideck_unify/models/accounting_salesreceiptsdeleteop.py: + last_write_checksum: sha1:e72785298e2ea416b4aa0f99aa464c4834ffde43 + src/apideck_unify/models/accounting_salesreceiptsoneop.py: + last_write_checksum: sha1:0996b3ef081847a53fe775901fd198b5bf093d54 + src/apideck_unify/models/accounting_salesreceiptsupdateop.py: + last_write_checksum: sha1:36a67d081c81f24b6bfbbabad193429dc6373b6c src/apideck_unify/models/accounting_subsidiariesaddop.py: last_write_checksum: sha1:396e8292bb237e13c803a0a58bee211194630d81 src/apideck_unify/models/accounting_subsidiariesallop.py: @@ -24713,6 +25194,8 @@ trackedFiles: last_write_checksum: sha1:acd9653a038bdb5b1b806a09f79dd7e07ef8d394 src/apideck_unify/models/accountinglocationsfilter.py: last_write_checksum: sha1:88aaa2c5a14976f854d08515ffddcc6c5910cb76 + src/apideck_unify/models/accountingpaymentmethod.py: + last_write_checksum: sha1:33bf48ec1c00fc3961b71adc35b4f191e3a41892 src/apideck_unify/models/activitiesfilter.py: last_write_checksum: sha1:56f47cd0e05c391b812cdd7c74eb0473551b1b8e src/apideck_unify/models/activitiessort.py: @@ -24786,7 +25269,7 @@ trackedFiles: src/apideck_unify/models/ats_jobsupdateop.py: last_write_checksum: sha1:183dcbc21546b00c90c982e1ff65386be066dc5b src/apideck_unify/models/attachment.py: - last_write_checksum: sha1:45053b3c1831b0fe98feaf28d3503903f7d71b9c + last_write_checksum: sha1:1644908e960296f9b386c5d8fe96fd7db8c86a23 src/apideck_unify/models/attachmentreference.py: last_write_checksum: sha1:b2f4588cec995080da804b500d30e69e64f204c4 src/apideck_unify/models/attachmentreferencetype.py: @@ -24816,9 +25299,9 @@ trackedFiles: src/apideck_unify/models/bankaccountssort.py: last_write_checksum: sha1:b92fbc10748133c6b4bd8bee30cd4ec38855a765 src/apideck_unify/models/bankfeedaccount.py: - last_write_checksum: sha1:78731f901544e849d64ad7bfaa496f47764973bd + last_write_checksum: sha1:ed3bfc176affc4deb08a855e602b9bbb1df919d5 src/apideck_unify/models/bankfeedstatement.py: - last_write_checksum: sha1:67245a3b8e64298da622284023eaf2beb2602238 + last_write_checksum: sha1:276ab4383fbca6acaff819174169a36adeccfd26 src/apideck_unify/models/benefit.py: last_write_checksum: sha1:e538d645b907406fb5af8a000ab66db60907fbe5 src/apideck_unify/models/bill.py: @@ -25017,6 +25500,8 @@ trackedFiles: last_write_checksum: sha1:487542b58be0aebdae16dc8088cd6a7fc1ba5ed7 src/apideck_unify/models/createopportunityresponse.py: last_write_checksum: sha1:39c444a668acc4f887212af59cd7a8ea919287eb + src/apideck_unify/models/createpaymentmethodresponse.py: + last_write_checksum: sha1:33050c8a5b0f3f4e766d217561a9e45d5801861c src/apideck_unify/models/createpaymentresponse.py: last_write_checksum: sha1:4addae38c058fec44f76291a26344237c6577404 src/apideck_unify/models/createpipelineresponse.py: @@ -25029,6 +25514,8 @@ trackedFiles: last_write_checksum: sha1:da1f6a6b634a180dc91f524498275f5de36dfd2f src/apideck_unify/models/createrefundresponse.py: last_write_checksum: sha1:e3c4b2bfe1926c3f7bd72ab3ef9210fcca96fb6d + src/apideck_unify/models/createsalesreceiptresponse.py: + last_write_checksum: sha1:67850be6dce0cd8e39694e6b25d32ecaac4e6ac4 src/apideck_unify/models/createsessionresponse.py: last_write_checksum: sha1:79b234105a086a305dedb7769f4cf1cb562ba0b8 src/apideck_unify/models/createsharedlinkresponse.py: @@ -25178,7 +25665,7 @@ trackedFiles: src/apideck_unify/models/customerssort.py: last_write_checksum: sha1:1ae868c9919cd921fe7a4c953cede4a382bd804e src/apideck_unify/models/customfield.py: - last_write_checksum: sha1:995d2a52685a22fdc8a941685f56d8d5600f3d43 + last_write_checksum: sha1:353df7bbe31e33553a315d20aea64775303e323f src/apideck_unify/models/customfieldfinder.py: last_write_checksum: sha1:ce3f41f3b118a9b4e7e4cb2aa4e4248780e28e13 src/apideck_unify/models/custommapping.py: @@ -25273,6 +25760,8 @@ trackedFiles: last_write_checksum: sha1:94fa93f66a8bc60ca0066c017a812c86a2d87304 src/apideck_unify/models/deleteopportunityresponse.py: last_write_checksum: sha1:da141a07b86fe0cfcb24ed799085fa06f1f43e26 + src/apideck_unify/models/deletepaymentmethodresponse.py: + last_write_checksum: sha1:542145852359183bd0e8ecacf2606bf051c2019d src/apideck_unify/models/deletepaymentresponse.py: last_write_checksum: sha1:b590cd7d8f83921ca97049993fb0563d56b566e7 src/apideck_unify/models/deletepipelineresponse.py: @@ -25285,6 +25774,8 @@ trackedFiles: last_write_checksum: sha1:492fce611527fcbc20ed23c20d9b57b8606f8534 src/apideck_unify/models/deleterefundresponse.py: last_write_checksum: sha1:dded5458010b54d509a45c21f93f6512259de19e + src/apideck_unify/models/deletesalesreceiptresponse.py: + last_write_checksum: sha1:3673da94f95af8f47a7ee516cffe555f03f84fc9 src/apideck_unify/models/deletesharedlinkresponse.py: last_write_checksum: sha1:99b6636f4e380bf3b8ba2f0d204bf82ed0a2b556 src/apideck_unify/models/deletesubsidiaryresponse.py: @@ -25436,9 +25927,9 @@ trackedFiles: src/apideck_unify/models/filestorage_filesdeleteop.py: last_write_checksum: sha1:b56d1c77bf2544de675cdcb048119c7bf3203aef src/apideck_unify/models/filestorage_filesdownloadop.py: - last_write_checksum: sha1:95775e5918101f2915fcec1d2799769ccaba3ce1 + last_write_checksum: sha1:0b3ce2bf7ee8894c925ec3cc6eebd43315aba496 src/apideck_unify/models/filestorage_filesexportop.py: - last_write_checksum: sha1:b7d1c396c34c3d652eafeaf91688870104116c96 + last_write_checksum: sha1:33cb35d6ac176a661544c2fd5dafcd2bbe92158c src/apideck_unify/models/filestorage_filesoneop.py: last_write_checksum: sha1:6fa47231da41e22f30c3689cb2c44ee43dca21ca src/apideck_unify/models/filestorage_filessearchop.py: @@ -25723,6 +26214,10 @@ trackedFiles: last_write_checksum: sha1:576ef7a3f9ae09f36fd4e93722147396b7ad9ed0 src/apideck_unify/models/getopportunityresponse.py: last_write_checksum: sha1:54ebd9d4bc88989705b3f74e9ea1e8b608cb8632 + src/apideck_unify/models/getpaymentmethodresponse.py: + last_write_checksum: sha1:3259e79e90920b2fcf98a83accb23384de7cbf49 + src/apideck_unify/models/getpaymentmethodsresponse.py: + last_write_checksum: sha1:8ee4f9992b7743cad2d7b7786988a6cd9fb0e441 src/apideck_unify/models/getpaymentresponse.py: last_write_checksum: sha1:586d1e40513c445985e01de4f0a68e77ce217749 src/apideck_unify/models/getpaymentsresponse.py: @@ -25757,6 +26252,10 @@ trackedFiles: last_write_checksum: sha1:8ec25bcdff7049612f11040bb238ce1cfb04bc28 src/apideck_unify/models/getrefundsresponse.py: last_write_checksum: sha1:fe80419e1785cb1c0a5d2c1584cbf308403708c4 + src/apideck_unify/models/getsalesreceiptresponse.py: + last_write_checksum: sha1:a7521a852e9f3d297f4e6758f1746bdb26245ef7 + src/apideck_unify/models/getsalesreceiptsresponse.py: + last_write_checksum: sha1:0d6b8ba78dd8cc8846569ba2e5ce52edf9ea36e7 src/apideck_unify/models/getsharedlinkresponse.py: last_write_checksum: sha1:18274c7450003b4c77e5abaa22b4529217fdeb1f src/apideck_unify/models/getsharedlinksresponse.py: @@ -26092,17 +26591,17 @@ trackedFiles: src/apideck_unify/models/projectssort.py: last_write_checksum: sha1:9d0d1dd7a8480ffe52d267112db83cb0423fc3aa src/apideck_unify/models/proxy_deleteproxyop.py: - last_write_checksum: sha1:e8da144bc463ba2d447504c0e81bc543c7bfb23c + last_write_checksum: sha1:e14c64b2fc60153870760e9a3c61cbfaaa51294d src/apideck_unify/models/proxy_getproxyop.py: - last_write_checksum: sha1:4b116fb6466007dbb1db35d38d8d2cda48bdb792 + last_write_checksum: sha1:74fb8364d9409cb45d1d604736f545d25c133c0d src/apideck_unify/models/proxy_optionsproxyop.py: - last_write_checksum: sha1:5b97523e4c4e6ae2772d219bed54e8c925448e16 + last_write_checksum: sha1:7ae82c0045535704c6096fbb89ea8880d6e45195 src/apideck_unify/models/proxy_patchproxyop.py: - last_write_checksum: sha1:8b70fb83d7aef3135f653ceed066be427a59a97e + last_write_checksum: sha1:da715919e554341e313463b1899c2ebc89f9dfc9 src/apideck_unify/models/proxy_postproxyop.py: - last_write_checksum: sha1:bff2c4b25486b5d5dd7cb3d858ee6d0c9d67cd35 + last_write_checksum: sha1:d40dae075682ff37be4db8897e3c3c086a272a6d src/apideck_unify/models/proxy_putproxyop.py: - last_write_checksum: sha1:62e2597061b595184c644af37a8c4ec23bc988a5 + last_write_checksum: sha1:9744c98d8c79e010c3b2fb461564a816768b9a5b src/apideck_unify/models/purchaseorder.py: last_write_checksum: sha1:9db492fdb96faee51447d63714d1181de9f95714 src/apideck_unify/models/purchaseordersfilter.py: @@ -26135,6 +26634,14 @@ trackedFiles: last_write_checksum: sha1:be7e15a7fa5d409dcacbae9c0cae874d710e1095 src/apideck_unify/models/responsevalidationerror.py: last_write_checksum: sha1:532f05168bca571541f925e27639d6953c628935 + src/apideck_unify/models/salesreceipt.py: + last_write_checksum: sha1:9607edfe841a2a9ed0cf94a0d34e8544b4d594e0 + src/apideck_unify/models/salesreceipt_input.py: + last_write_checksum: sha1:a66ef838af20bee629ba55bf035baf3c75b6f2dd + src/apideck_unify/models/salesreceiptsfilter.py: + last_write_checksum: sha1:0569e36b4dd3cba93fc460babb9dfe7371248269 + src/apideck_unify/models/salesreceiptssort.py: + last_write_checksum: sha1:19f2d84cf00aeb5c35525cc3b6c906b36f6e9b80 src/apideck_unify/models/schedule.py: last_write_checksum: sha1:1f6703c6c4b10af0039d282b7eef44b91dedfa14 src/apideck_unify/models/schemasupport.py: @@ -26301,6 +26808,8 @@ trackedFiles: last_write_checksum: sha1:0a3c7ab4f0ee2eb77400348999d5271d6b47834e src/apideck_unify/models/updateopportunityresponse.py: last_write_checksum: sha1:fa11c254926f1394aab2c2d4e375cf5e2a0a1652 + src/apideck_unify/models/updatepaymentmethodresponse.py: + last_write_checksum: sha1:031be545c05aa48d76769c4afe18f33ed7e01032 src/apideck_unify/models/updatepaymentresponse.py: last_write_checksum: sha1:ff3da9be703f881b92b01c5c63623048ccba956d src/apideck_unify/models/updatepipelineresponse.py: @@ -26313,6 +26822,8 @@ trackedFiles: last_write_checksum: sha1:c75631693dfd661213a5076d8b2be78db52ac87d src/apideck_unify/models/updaterefundresponse.py: last_write_checksum: sha1:d98c079de92745784866dbe79debf14feb10dde4 + src/apideck_unify/models/updatesalesreceiptresponse.py: + last_write_checksum: sha1:cc120004dc5fd52e88a7e387e9436b28b1b9548e src/apideck_unify/models/updatesharedlinkresponse.py: last_write_checksum: sha1:e150d958d67fccd2bd5e19994bd03906e069c86e src/apideck_unify/models/updatesubsidiaryresponse.py: @@ -26422,11 +26933,13 @@ trackedFiles: src/apideck_unify/notes.py: last_write_checksum: sha1:2835a9acd16ab47fdb69d556098865d91d2f1ef4 src/apideck_unify/opportunities.py: - last_write_checksum: sha1:52703136ab8c58db2b105a2c830a33e8f3050191 + last_write_checksum: sha1:93256b50e99311f6e9b6553d9d44fab71f532022 src/apideck_unify/orders.py: last_write_checksum: sha1:3b864ab4956ca88a67f699d9c18016e20b797871 + src/apideck_unify/paymentmethods.py: + last_write_checksum: sha1:a68c41452a51a65c54d870429657f61606be215c src/apideck_unify/payments.py: - last_write_checksum: sha1:b3127ae2d3f64ca0a1e02c522c8631fefb4fbb58 + last_write_checksum: sha1:92315a648ee8af0f10e3563f48fafa01416a6359 src/apideck_unify/payrolls.py: last_write_checksum: sha1:5ccd0b249a6acb7ec93202cf3e02d445138a66b0 src/apideck_unify/pipelines.py: @@ -26438,15 +26951,17 @@ trackedFiles: src/apideck_unify/projects.py: last_write_checksum: sha1:7419506683eb90a693ffaa501c053ffa8af71f09 src/apideck_unify/proxy.py: - last_write_checksum: sha1:deaaafe32a577977cd7ee2a32315491d9caf6a73 + last_write_checksum: sha1:53cac21bb7cb5e5c3424547235d9915d7dcc5319 src/apideck_unify/purchaseorders.py: - last_write_checksum: sha1:a01b351803034830b0b8b00a4e7df19a76d6c1f0 + last_write_checksum: sha1:9bb57ed3d6716a41453465a824d3485e132d2deb src/apideck_unify/py.typed: last_write_checksum: sha1:8efc425ffe830805ffcc0f3055871bdcdc542c60 src/apideck_unify/quotes.py: - last_write_checksum: sha1:d7434c42b50b1be4f1e8d417ce22b7d61f8b97cf + last_write_checksum: sha1:355d58629deb7bf8eab878954056f3221820e241 src/apideck_unify/refunds.py: - last_write_checksum: sha1:8cb402fa74d6fdc5512561436174ac55e33fcc52 + last_write_checksum: sha1:ac9ef09d7f731d2b2b8eadda804a38d5097f489b + src/apideck_unify/salesreceipts.py: + last_write_checksum: sha1:ee356b7ade5bf52c2b6f81ab68ce05131cf3c0d9 src/apideck_unify/sdk.py: last_write_checksum: sha1:c36fd87d8a9d1b51c46deeb198cc84a9761aedfb src/apideck_unify/sdkconfiguration.py: diff --git a/.speakeasy/gen.yaml b/.speakeasy/gen.yaml index e114690a..10caa599 100644 --- a/.speakeasy/gen.yaml +++ b/.speakeasy/gen.yaml @@ -32,7 +32,7 @@ generation: persistentEdits: {} versioningStrategy: automatic python: - version: 0.36.0 + version: 0.37.0 additionalDependencies: dev: {} main: {} diff --git a/.speakeasy/workflow.lock b/.speakeasy/workflow.lock index 2666e55c..d3165d3c 100644 --- a/.speakeasy/workflow.lock +++ b/.speakeasy/workflow.lock @@ -2,20 +2,20 @@ speakeasyVersion: 1.656.1 sources: Apideck: sourceNamespace: apideck - sourceRevisionDigest: sha256:76683a9f95b9f0f17e568c32509b42f8258c05e93690eaf75bd29dde069d8e98 - sourceBlobDigest: sha256:627caaeba3ccaac43cdc59d8aed1dfefe8f9e14e5ec4301dc8d2147d625e988c + sourceRevisionDigest: sha256:1ffe20d7e2f57a61fb6214a180c3d2b02a1f382fef19fad6c16b3ec1723c8a09 + sourceBlobDigest: sha256:2ee36308da04122ec3af762481120010dda1373ec4d955ac8316a1321234ce30 tags: - latest - - speakeasy-sdk-regen-1786010008 - - 10.32.0 + - speakeasy-sdk-regen-1786387580 + - 10.38.0 targets: apideck: source: Apideck sourceNamespace: apideck - sourceRevisionDigest: sha256:76683a9f95b9f0f17e568c32509b42f8258c05e93690eaf75bd29dde069d8e98 - sourceBlobDigest: sha256:627caaeba3ccaac43cdc59d8aed1dfefe8f9e14e5ec4301dc8d2147d625e988c + sourceRevisionDigest: sha256:1ffe20d7e2f57a61fb6214a180c3d2b02a1f382fef19fad6c16b3ec1723c8a09 + sourceBlobDigest: sha256:2ee36308da04122ec3af762481120010dda1373ec4d955ac8316a1321234ce30 codeSamplesNamespace: apideck-python-code-samples - codeSamplesRevisionDigest: sha256:d198e0f3062e34870b64da3e077e725dcace0710f0b52e06481b673d27e81ceb + codeSamplesRevisionDigest: sha256:ae70d500185e3e449ef31de2142af64e7dc3ccaf9b7b1e5349e7be6b9511625f workflow: workflowVersion: 1.0.0 speakeasyVersion: latest diff --git a/README.md b/README.md index 7cd807f9..66070987 100644 --- a/README.md +++ b/README.md @@ -408,6 +408,14 @@ with Apideck( * [update](docs/sdks/locations/README.md#update) - Update Location * [delete](docs/sdks/locations/README.md#delete) - Delete Location +#### [accounting.payment_methods](docs/sdks/paymentmethods/README.md) + +* [list](docs/sdks/paymentmethods/README.md#list) - List Payment Methods +* [create](docs/sdks/paymentmethods/README.md#create) - Create Payment Method +* [get](docs/sdks/paymentmethods/README.md#get) - Get Payment Method +* [update](docs/sdks/paymentmethods/README.md#update) - Update Payment Method +* [delete](docs/sdks/paymentmethods/README.md#delete) - Delete Payment Method + #### [accounting.payments](docs/sdks/payments/README.md) * [list](docs/sdks/payments/README.md#list) - List Payments @@ -452,6 +460,14 @@ with Apideck( * [update](docs/sdks/refunds/README.md#update) - Update Refund * [delete](docs/sdks/refunds/README.md#delete) - Delete Refund +#### [accounting.sales_receipts](docs/sdks/salesreceipts/README.md) + +* [list](docs/sdks/salesreceipts/README.md#list) - List Sales Receipts +* [create](docs/sdks/salesreceipts/README.md#create) - Create Sales Receipt +* [get](docs/sdks/salesreceipts/README.md#get) - Get Sales Receipt +* [update](docs/sdks/salesreceipts/README.md#update) - Update Sales Receipt +* [delete](docs/sdks/salesreceipts/README.md#delete) - Delete Sales Receipt + #### [accounting.subsidiaries](docs/sdks/subsidiaries/README.md) * [list](docs/sdks/subsidiaries/README.md#list) - List Subsidiaries @@ -1082,8 +1098,8 @@ with Apideck( **Inherit from [`ApideckError`](./src/apideck_unify/models/apideckerror.py)**: -* [`Unauthorized`](./src/apideck_unify/models/unauthorized.py): Unauthorized. Status code `401`. Applicable to 6 of 341 methods.* -* [`ConflictResponse`](./src/apideck_unify/models/conflictresponse.py): Conflict — a connection already exists for the target connector. Status code `409`. Applicable to 1 of 341 methods.* +* [`Unauthorized`](./src/apideck_unify/models/unauthorized.py): Unauthorized. Status code `401`. Applicable to 6 of 351 methods.* +* [`ConflictResponse`](./src/apideck_unify/models/conflictresponse.py): Conflict — a connection already exists for the target connector. Status code `409`. Applicable to 1 of 351 methods.* * [`ResponseValidationError`](./src/apideck_unify/models/responsevalidationerror.py): Type mismatch between the response data and the expected Pydantic model. Provides access to the Pydantic validation error via the `cause` attribute. diff --git a/RELEASES.md b/RELEASES.md index 4e44984d..5ed9a066 100644 --- a/RELEASES.md +++ b/RELEASES.md @@ -1458,4 +1458,14 @@ Based on: ### Generated - [python v0.36.0] . ### Releases -- [PyPI v0.36.0] https://pypi.org/project/apideck-unify/0.36.0 - . \ No newline at end of file +- [PyPI v0.36.0] https://pypi.org/project/apideck-unify/0.36.0 - . + +## 2026-08-13 00:24:00 +### Changes +Based on: +- OpenAPI Doc +- Speakeasy CLI 1.656.1 (2.753.1) https://github.com/speakeasy-api/speakeasy +### Generated +- [python v0.37.0] . +### Releases +- [PyPI v0.37.0] https://pypi.org/project/apideck-unify/0.37.0 - . \ No newline at end of file diff --git a/docs/models/accountingattachmentsdownloadrequest.md b/docs/models/accountingattachmentsdownloadrequest.md index e65fe0b9..d1c54643 100644 --- a/docs/models/accountingattachmentsdownloadrequest.md +++ b/docs/models/accountingattachmentsdownloadrequest.md @@ -12,4 +12,5 @@ | `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | | `service_id` | *Optional[str]* | :heavy_minus_sign: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | salesforce | | `company_id` | *Optional[str]* | :heavy_minus_sign: | The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings. | 12345 | -| `fields` | *OptionalNullable[str]* | :heavy_minus_sign: | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. | id,updated_at | \ No newline at end of file +| `fields` | *OptionalNullable[str]* | :heavy_minus_sign: | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. | id,updated_at | +| `follow_redirects` | *Optional[bool]* | :heavy_minus_sign: | Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. | false | \ No newline at end of file diff --git a/docs/models/accountingattachmentsdownloadresponse.md b/docs/models/accountingattachmentsdownloadresponse.md index dcbdd0bc..56689fb8 100644 --- a/docs/models/accountingattachmentsdownloadresponse.md +++ b/docs/models/accountingattachmentsdownloadresponse.md @@ -3,8 +3,8 @@ ## Fields -| Field | Type | Required | Description | -| -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | -| `get_attachment_download_response` | *Optional[httpx.Response]* | :heavy_minus_sign: | Attachment Download | -| `unexpected_error_response` | [Optional[models.UnexpectedErrorResponse]](../models/unexpectederrorresponse.md) | :heavy_minus_sign: | Unexpected error | \ No newline at end of file +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | +| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | +| `get_attachment_download_response` | *Optional[httpx.Response]* | :heavy_minus_sign: | Attachment Download. When the request includes `x-apideck-follow-redirects: false` and the download would otherwise redirect to a presigned URL, the response body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the attachment. | +| `unexpected_error_response` | [Optional[models.UnexpectedErrorResponse]](../models/unexpectederrorresponse.md) | :heavy_minus_sign: | Unexpected error | \ No newline at end of file diff --git a/docs/models/accountingpaymentmethod.md b/docs/models/accountingpaymentmethod.md new file mode 100644 index 00000000..c8d90c9d --- /dev/null +++ b/docs/models/accountingpaymentmethod.md @@ -0,0 +1,19 @@ +# AccountingPaymentMethod + + +## Fields + +| Field | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `id` | *Optional[str]* | :heavy_minus_sign: | A unique identifier for an object. | 12345 | +| `name` | *Optional[str]* | :heavy_minus_sign: | The name of the payment method. | Cash | +| `type` | [OptionalNullable[models.AccountingPaymentMethodType]](../models/accountingpaymentmethodtype.md) | :heavy_minus_sign: | The type of payment method. | cash | +| `status` | [OptionalNullable[models.AccountingPaymentMethodStatus]](../models/accountingpaymentmethodstatus.md) | :heavy_minus_sign: | The status of the payment method. | active | +| `custom_mappings` | Dict[str, *Any*] | :heavy_minus_sign: | When custom mappings are configured on the resource, the result is included here. | | +| `downstream_id` | *OptionalNullable[str]* | :heavy_minus_sign: | The third-party API ID of original entity | 12345 | +| `row_version` | *OptionalNullable[str]* | :heavy_minus_sign: | A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object. | 1-12345 | +| `updated_by` | *OptionalNullable[str]* | :heavy_minus_sign: | The user who last updated the object. | 12345 | +| `created_by` | *OptionalNullable[str]* | :heavy_minus_sign: | The user who created the object. | 12345 | +| `updated_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_minus_sign: | The date and time when the object was last updated. | 2020-09-30T07:43:32.000Z | +| `created_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_minus_sign: | The date and time when the object was created. | 2020-09-30T07:43:32.000Z | +| `pass_through` | List[[models.PassThroughBody](../models/passthroughbody.md)] | :heavy_minus_sign: | The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources. | | \ No newline at end of file diff --git a/docs/models/accountingpaymentmethodinput.md b/docs/models/accountingpaymentmethodinput.md new file mode 100644 index 00000000..749578fe --- /dev/null +++ b/docs/models/accountingpaymentmethodinput.md @@ -0,0 +1,12 @@ +# AccountingPaymentMethodInput + + +## Fields + +| Field | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `name` | *Optional[str]* | :heavy_minus_sign: | The name of the payment method. | Cash | +| `type` | [OptionalNullable[models.AccountingPaymentMethodType]](../models/accountingpaymentmethodtype.md) | :heavy_minus_sign: | The type of payment method. | cash | +| `status` | [OptionalNullable[models.AccountingPaymentMethodStatus]](../models/accountingpaymentmethodstatus.md) | :heavy_minus_sign: | The status of the payment method. | active | +| `row_version` | *OptionalNullable[str]* | :heavy_minus_sign: | A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object. | 1-12345 | +| `pass_through` | List[[models.PassThroughBody](../models/passthroughbody.md)] | :heavy_minus_sign: | The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources. | | \ No newline at end of file diff --git a/docs/models/accountingpaymentmethodsaddglobals.md b/docs/models/accountingpaymentmethodsaddglobals.md new file mode 100644 index 00000000..2657f65e --- /dev/null +++ b/docs/models/accountingpaymentmethodsaddglobals.md @@ -0,0 +1,9 @@ +# AccountingPaymentMethodsAddGlobals + + +## Fields + +| Field | Type | Required | Description | Example | +| ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | \ No newline at end of file diff --git a/docs/models/accountingpaymentmethodsaddrequest.md b/docs/models/accountingpaymentmethodsaddrequest.md new file mode 100644 index 00000000..915a5cb8 --- /dev/null +++ b/docs/models/accountingpaymentmethodsaddrequest.md @@ -0,0 +1,12 @@ +# AccountingPaymentMethodsAddRequest + + +## Fields + +| Field | Type | Required | Description | Example | +| --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | +| `raw` | *Optional[bool]* | :heavy_minus_sign: | Include raw response. Mostly used for debugging purposes | | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *Optional[str]* | :heavy_minus_sign: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | salesforce | +| `accounting_payment_method` | [models.AccountingPaymentMethodInput](../models/accountingpaymentmethodinput.md) | :heavy_check_mark: | N/A | | \ No newline at end of file diff --git a/docs/models/accountingpaymentmethodsaddresponse.md b/docs/models/accountingpaymentmethodsaddresponse.md new file mode 100644 index 00000000..c50b6e8e --- /dev/null +++ b/docs/models/accountingpaymentmethodsaddresponse.md @@ -0,0 +1,10 @@ +# AccountingPaymentMethodsAddResponse + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | +| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | +| `create_payment_method_response` | [Optional[models.CreatePaymentMethodResponse]](../models/createpaymentmethodresponse.md) | :heavy_minus_sign: | Payment Methods | +| `unexpected_error_response` | [Optional[models.UnexpectedErrorResponse]](../models/unexpectederrorresponse.md) | :heavy_minus_sign: | Unexpected error | \ No newline at end of file diff --git a/docs/models/accountingpaymentmethodsallglobals.md b/docs/models/accountingpaymentmethodsallglobals.md new file mode 100644 index 00000000..263b39e1 --- /dev/null +++ b/docs/models/accountingpaymentmethodsallglobals.md @@ -0,0 +1,9 @@ +# AccountingPaymentMethodsAllGlobals + + +## Fields + +| Field | Type | Required | Description | Example | +| ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | \ No newline at end of file diff --git a/docs/models/accountingpaymentmethodsallrequest.md b/docs/models/accountingpaymentmethodsallrequest.md new file mode 100644 index 00000000..2593da1a --- /dev/null +++ b/docs/models/accountingpaymentmethodsallrequest.md @@ -0,0 +1,15 @@ +# AccountingPaymentMethodsAllRequest + + +## Fields + +| Field | Type | Required | Description | Example | +| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `raw` | *Optional[bool]* | :heavy_minus_sign: | Include raw response. Mostly used for debugging purposes | | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *Optional[str]* | :heavy_minus_sign: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | salesforce | +| `cursor` | *OptionalNullable[str]* | :heavy_minus_sign: | Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. | | +| `limit` | *Optional[int]* | :heavy_minus_sign: | Number of results to return. Minimum 1, Maximum 200, Default 20 | | +| `fields` | *OptionalNullable[str]* | :heavy_minus_sign: | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. | id,updated_at | +| `pass_through` | Dict[str, *Any*] | :heavy_minus_sign: | Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads | {
"search": "San Francisco"
} | \ No newline at end of file diff --git a/docs/models/accountingpaymentmethodsallresponse.md b/docs/models/accountingpaymentmethodsallresponse.md new file mode 100644 index 00000000..39947df9 --- /dev/null +++ b/docs/models/accountingpaymentmethodsallresponse.md @@ -0,0 +1,10 @@ +# AccountingPaymentMethodsAllResponse + + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | +| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | +| `get_payment_methods_response` | [Optional[models.GetPaymentMethodsResponse]](../models/getpaymentmethodsresponse.md) | :heavy_minus_sign: | Payment Methods | +| `unexpected_error_response` | [Optional[models.UnexpectedErrorResponse]](../models/unexpectederrorresponse.md) | :heavy_minus_sign: | Unexpected error | \ No newline at end of file diff --git a/docs/models/accountingpaymentmethodsdeleteglobals.md b/docs/models/accountingpaymentmethodsdeleteglobals.md new file mode 100644 index 00000000..2de7ff02 --- /dev/null +++ b/docs/models/accountingpaymentmethodsdeleteglobals.md @@ -0,0 +1,9 @@ +# AccountingPaymentMethodsDeleteGlobals + + +## Fields + +| Field | Type | Required | Description | Example | +| ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | \ No newline at end of file diff --git a/docs/models/accountingpaymentmethodsdeleterequest.md b/docs/models/accountingpaymentmethodsdeleterequest.md new file mode 100644 index 00000000..0a77784a --- /dev/null +++ b/docs/models/accountingpaymentmethodsdeleterequest.md @@ -0,0 +1,12 @@ +# AccountingPaymentMethodsDeleteRequest + + +## Fields + +| Field | Type | Required | Description | Example | +| --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | +| `id` | *str* | :heavy_check_mark: | ID of the record you are acting upon. | | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *Optional[str]* | :heavy_minus_sign: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | salesforce | +| `raw` | *Optional[bool]* | :heavy_minus_sign: | Include raw response. Mostly used for debugging purposes | | \ No newline at end of file diff --git a/docs/models/accountingpaymentmethodsdeleteresponse.md b/docs/models/accountingpaymentmethodsdeleteresponse.md new file mode 100644 index 00000000..983770d9 --- /dev/null +++ b/docs/models/accountingpaymentmethodsdeleteresponse.md @@ -0,0 +1,10 @@ +# AccountingPaymentMethodsDeleteResponse + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | +| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | +| `delete_payment_method_response` | [Optional[models.DeletePaymentMethodResponse]](../models/deletepaymentmethodresponse.md) | :heavy_minus_sign: | Payment Methods | +| `unexpected_error_response` | [Optional[models.UnexpectedErrorResponse]](../models/unexpectederrorresponse.md) | :heavy_minus_sign: | Unexpected error | \ No newline at end of file diff --git a/docs/models/accountingpaymentmethodsoneglobals.md b/docs/models/accountingpaymentmethodsoneglobals.md new file mode 100644 index 00000000..bfa393b5 --- /dev/null +++ b/docs/models/accountingpaymentmethodsoneglobals.md @@ -0,0 +1,9 @@ +# AccountingPaymentMethodsOneGlobals + + +## Fields + +| Field | Type | Required | Description | Example | +| ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | \ No newline at end of file diff --git a/docs/models/accountingpaymentmethodsonerequest.md b/docs/models/accountingpaymentmethodsonerequest.md new file mode 100644 index 00000000..ae470077 --- /dev/null +++ b/docs/models/accountingpaymentmethodsonerequest.md @@ -0,0 +1,13 @@ +# AccountingPaymentMethodsOneRequest + + +## Fields + +| Field | Type | Required | Description | Example | +| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `id` | *str* | :heavy_check_mark: | ID of the record you are acting upon. | | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *Optional[str]* | :heavy_minus_sign: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | salesforce | +| `raw` | *Optional[bool]* | :heavy_minus_sign: | Include raw response. Mostly used for debugging purposes | | +| `fields` | *OptionalNullable[str]* | :heavy_minus_sign: | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. | id,updated_at | \ No newline at end of file diff --git a/docs/models/accountingpaymentmethodsoneresponse.md b/docs/models/accountingpaymentmethodsoneresponse.md new file mode 100644 index 00000000..6b7633f5 --- /dev/null +++ b/docs/models/accountingpaymentmethodsoneresponse.md @@ -0,0 +1,10 @@ +# AccountingPaymentMethodsOneResponse + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | +| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | +| `get_payment_method_response` | [Optional[models.GetPaymentMethodResponse]](../models/getpaymentmethodresponse.md) | :heavy_minus_sign: | Payment Methods | +| `unexpected_error_response` | [Optional[models.UnexpectedErrorResponse]](../models/unexpectederrorresponse.md) | :heavy_minus_sign: | Unexpected error | \ No newline at end of file diff --git a/docs/models/accountingpaymentmethodstatus.md b/docs/models/accountingpaymentmethodstatus.md new file mode 100644 index 00000000..aa441aee --- /dev/null +++ b/docs/models/accountingpaymentmethodstatus.md @@ -0,0 +1,11 @@ +# AccountingPaymentMethodStatus + +The status of the payment method. + + +## Values + +| Name | Value | +| ---------- | ---------- | +| `ACTIVE` | active | +| `INACTIVE` | inactive | \ No newline at end of file diff --git a/docs/models/accountingpaymentmethodsupdateglobals.md b/docs/models/accountingpaymentmethodsupdateglobals.md new file mode 100644 index 00000000..053ce8e9 --- /dev/null +++ b/docs/models/accountingpaymentmethodsupdateglobals.md @@ -0,0 +1,9 @@ +# AccountingPaymentMethodsUpdateGlobals + + +## Fields + +| Field | Type | Required | Description | Example | +| ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | \ No newline at end of file diff --git a/docs/models/accountingpaymentmethodsupdaterequest.md b/docs/models/accountingpaymentmethodsupdaterequest.md new file mode 100644 index 00000000..722e865a --- /dev/null +++ b/docs/models/accountingpaymentmethodsupdaterequest.md @@ -0,0 +1,13 @@ +# AccountingPaymentMethodsUpdateRequest + + +## Fields + +| Field | Type | Required | Description | Example | +| --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | +| `id` | *str* | :heavy_check_mark: | ID of the record you are acting upon. | | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *Optional[str]* | :heavy_minus_sign: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | salesforce | +| `raw` | *Optional[bool]* | :heavy_minus_sign: | Include raw response. Mostly used for debugging purposes | | +| `accounting_payment_method` | [models.AccountingPaymentMethodInput](../models/accountingpaymentmethodinput.md) | :heavy_check_mark: | N/A | | \ No newline at end of file diff --git a/docs/models/accountingpaymentmethodsupdateresponse.md b/docs/models/accountingpaymentmethodsupdateresponse.md new file mode 100644 index 00000000..f368b823 --- /dev/null +++ b/docs/models/accountingpaymentmethodsupdateresponse.md @@ -0,0 +1,10 @@ +# AccountingPaymentMethodsUpdateResponse + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | +| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | +| `update_payment_method_response` | [Optional[models.UpdatePaymentMethodResponse]](../models/updatepaymentmethodresponse.md) | :heavy_minus_sign: | Payment Methods | +| `unexpected_error_response` | [Optional[models.UnexpectedErrorResponse]](../models/unexpectederrorresponse.md) | :heavy_minus_sign: | Unexpected error | \ No newline at end of file diff --git a/docs/models/accountingpaymentmethodtype.md b/docs/models/accountingpaymentmethodtype.md new file mode 100644 index 00000000..511f8629 --- /dev/null +++ b/docs/models/accountingpaymentmethodtype.md @@ -0,0 +1,17 @@ +# AccountingPaymentMethodType + +The type of payment method. + + +## Values + +| Name | Value | +| --------------- | --------------- | +| `CASH` | cash | +| `CHECK` | check | +| `CREDIT_CARD` | credit_card | +| `DEBIT_CARD` | debit_card | +| `BANK_TRANSFER` | bank_transfer | +| `ELECTRONIC` | electronic | +| `OTHER` | other | +| `UNKNOWN` | unknown | \ No newline at end of file diff --git a/docs/models/accountingsalesreceiptsaddglobals.md b/docs/models/accountingsalesreceiptsaddglobals.md new file mode 100644 index 00000000..0152bf84 --- /dev/null +++ b/docs/models/accountingsalesreceiptsaddglobals.md @@ -0,0 +1,9 @@ +# AccountingSalesReceiptsAddGlobals + + +## Fields + +| Field | Type | Required | Description | Example | +| ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | \ No newline at end of file diff --git a/docs/models/accountingsalesreceiptsaddrequest.md b/docs/models/accountingsalesreceiptsaddrequest.md new file mode 100644 index 00000000..62aec4f7 --- /dev/null +++ b/docs/models/accountingsalesreceiptsaddrequest.md @@ -0,0 +1,13 @@ +# AccountingSalesReceiptsAddRequest + + +## Fields + +| Field | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | +| `raw` | *Optional[bool]* | :heavy_minus_sign: | Include raw response. Mostly used for debugging purposes | | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *Optional[str]* | :heavy_minus_sign: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | salesforce | +| `company_id` | *Optional[str]* | :heavy_minus_sign: | The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings. | 12345 | +| `sales_receipt` | [models.SalesReceiptInput](../models/salesreceiptinput.md) | :heavy_check_mark: | N/A | | \ No newline at end of file diff --git a/docs/models/accountingsalesreceiptsaddresponse.md b/docs/models/accountingsalesreceiptsaddresponse.md new file mode 100644 index 00000000..56c27821 --- /dev/null +++ b/docs/models/accountingsalesreceiptsaddresponse.md @@ -0,0 +1,10 @@ +# AccountingSalesReceiptsAddResponse + + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | +| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | +| `create_sales_receipt_response` | [Optional[models.CreateSalesReceiptResponse]](../models/createsalesreceiptresponse.md) | :heavy_minus_sign: | SalesReceipt created | +| `unexpected_error_response` | [Optional[models.UnexpectedErrorResponse]](../models/unexpectederrorresponse.md) | :heavy_minus_sign: | Unexpected error | \ No newline at end of file diff --git a/docs/models/accountingsalesreceiptsallglobals.md b/docs/models/accountingsalesreceiptsallglobals.md new file mode 100644 index 00000000..61361a70 --- /dev/null +++ b/docs/models/accountingsalesreceiptsallglobals.md @@ -0,0 +1,9 @@ +# AccountingSalesReceiptsAllGlobals + + +## Fields + +| Field | Type | Required | Description | Example | +| ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | \ No newline at end of file diff --git a/docs/models/accountingsalesreceiptsallrequest.md b/docs/models/accountingsalesreceiptsallrequest.md new file mode 100644 index 00000000..0a8e9b90 --- /dev/null +++ b/docs/models/accountingsalesreceiptsallrequest.md @@ -0,0 +1,18 @@ +# AccountingSalesReceiptsAllRequest + + +## Fields + +| Field | Type | Required | Description | Example | +| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `raw` | *Optional[bool]* | :heavy_minus_sign: | Include raw response. Mostly used for debugging purposes | | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *Optional[str]* | :heavy_minus_sign: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | salesforce | +| `company_id` | *Optional[str]* | :heavy_minus_sign: | The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings. | 12345 | +| `cursor` | *OptionalNullable[str]* | :heavy_minus_sign: | Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. | | +| `limit` | *Optional[int]* | :heavy_minus_sign: | Number of results to return. Minimum 1, Maximum 200, Default 20 | | +| `filter_` | [Optional[models.SalesReceiptsFilter]](../models/salesreceiptsfilter.md) | :heavy_minus_sign: | Apply filters | {
"updated_since": "2020-09-30T07:43:32.000Z",
"customer_id": "123abc"
} | +| `sort` | [Optional[models.SalesReceiptsSort]](../models/salesreceiptssort.md) | :heavy_minus_sign: | Apply sorting | {
"by": "updated_at",
"direction": "desc"
} | +| `pass_through` | Dict[str, *Any*] | :heavy_minus_sign: | Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads | {
"search": "San Francisco"
} | +| `fields` | *OptionalNullable[str]* | :heavy_minus_sign: | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. | id,updated_at | \ No newline at end of file diff --git a/docs/models/accountingsalesreceiptsallresponse.md b/docs/models/accountingsalesreceiptsallresponse.md new file mode 100644 index 00000000..2d7f3b90 --- /dev/null +++ b/docs/models/accountingsalesreceiptsallresponse.md @@ -0,0 +1,10 @@ +# AccountingSalesReceiptsAllResponse + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | +| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | +| `get_sales_receipts_response` | [Optional[models.GetSalesReceiptsResponse]](../models/getsalesreceiptsresponse.md) | :heavy_minus_sign: | SalesReceipts | +| `unexpected_error_response` | [Optional[models.UnexpectedErrorResponse]](../models/unexpectederrorresponse.md) | :heavy_minus_sign: | Unexpected error | \ No newline at end of file diff --git a/docs/models/accountingsalesreceiptsdeleteglobals.md b/docs/models/accountingsalesreceiptsdeleteglobals.md new file mode 100644 index 00000000..15452eba --- /dev/null +++ b/docs/models/accountingsalesreceiptsdeleteglobals.md @@ -0,0 +1,9 @@ +# AccountingSalesReceiptsDeleteGlobals + + +## Fields + +| Field | Type | Required | Description | Example | +| ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | \ No newline at end of file diff --git a/docs/models/accountingsalesreceiptsdeleterequest.md b/docs/models/accountingsalesreceiptsdeleterequest.md new file mode 100644 index 00000000..2766fcb9 --- /dev/null +++ b/docs/models/accountingsalesreceiptsdeleterequest.md @@ -0,0 +1,13 @@ +# AccountingSalesReceiptsDeleteRequest + + +## Fields + +| Field | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | +| `id` | *str* | :heavy_check_mark: | ID of the record you are acting upon. | | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *Optional[str]* | :heavy_minus_sign: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | salesforce | +| `raw` | *Optional[bool]* | :heavy_minus_sign: | Include raw response. Mostly used for debugging purposes | | +| `company_id` | *Optional[str]* | :heavy_minus_sign: | The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings. | 12345 | \ No newline at end of file diff --git a/docs/models/accountingsalesreceiptsdeleteresponse.md b/docs/models/accountingsalesreceiptsdeleteresponse.md new file mode 100644 index 00000000..5fc36def --- /dev/null +++ b/docs/models/accountingsalesreceiptsdeleteresponse.md @@ -0,0 +1,10 @@ +# AccountingSalesReceiptsDeleteResponse + + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | +| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | +| `delete_sales_receipt_response` | [Optional[models.DeleteSalesReceiptResponse]](../models/deletesalesreceiptresponse.md) | :heavy_minus_sign: | SalesReceipt deleted | +| `unexpected_error_response` | [Optional[models.UnexpectedErrorResponse]](../models/unexpectederrorresponse.md) | :heavy_minus_sign: | Unexpected error | \ No newline at end of file diff --git a/docs/models/accountingsalesreceiptsoneglobals.md b/docs/models/accountingsalesreceiptsoneglobals.md new file mode 100644 index 00000000..89054c9b --- /dev/null +++ b/docs/models/accountingsalesreceiptsoneglobals.md @@ -0,0 +1,9 @@ +# AccountingSalesReceiptsOneGlobals + + +## Fields + +| Field | Type | Required | Description | Example | +| ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | \ No newline at end of file diff --git a/docs/models/accountingsalesreceiptsonerequest.md b/docs/models/accountingsalesreceiptsonerequest.md new file mode 100644 index 00000000..fe85302f --- /dev/null +++ b/docs/models/accountingsalesreceiptsonerequest.md @@ -0,0 +1,14 @@ +# AccountingSalesReceiptsOneRequest + + +## Fields + +| Field | Type | Required | Description | Example | +| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `id` | *str* | :heavy_check_mark: | ID of the record you are acting upon. | | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *Optional[str]* | :heavy_minus_sign: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | salesforce | +| `company_id` | *Optional[str]* | :heavy_minus_sign: | The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings. | 12345 | +| `raw` | *Optional[bool]* | :heavy_minus_sign: | Include raw response. Mostly used for debugging purposes | | +| `fields` | *OptionalNullable[str]* | :heavy_minus_sign: | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. | id,updated_at | \ No newline at end of file diff --git a/docs/models/accountingsalesreceiptsoneresponse.md b/docs/models/accountingsalesreceiptsoneresponse.md new file mode 100644 index 00000000..5d771879 --- /dev/null +++ b/docs/models/accountingsalesreceiptsoneresponse.md @@ -0,0 +1,10 @@ +# AccountingSalesReceiptsOneResponse + + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | +| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | +| `get_sales_receipt_response` | [Optional[models.GetSalesReceiptResponse]](../models/getsalesreceiptresponse.md) | :heavy_minus_sign: | SalesReceipt | +| `unexpected_error_response` | [Optional[models.UnexpectedErrorResponse]](../models/unexpectederrorresponse.md) | :heavy_minus_sign: | Unexpected error | \ No newline at end of file diff --git a/docs/models/accountingsalesreceiptsupdateglobals.md b/docs/models/accountingsalesreceiptsupdateglobals.md new file mode 100644 index 00000000..50cd91a9 --- /dev/null +++ b/docs/models/accountingsalesreceiptsupdateglobals.md @@ -0,0 +1,9 @@ +# AccountingSalesReceiptsUpdateGlobals + + +## Fields + +| Field | Type | Required | Description | Example | +| ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | \ No newline at end of file diff --git a/docs/models/accountingsalesreceiptsupdaterequest.md b/docs/models/accountingsalesreceiptsupdaterequest.md new file mode 100644 index 00000000..361efdca --- /dev/null +++ b/docs/models/accountingsalesreceiptsupdaterequest.md @@ -0,0 +1,14 @@ +# AccountingSalesReceiptsUpdateRequest + + +## Fields + +| Field | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | +| `id` | *str* | :heavy_check_mark: | ID of the record you are acting upon. | | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *Optional[str]* | :heavy_minus_sign: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | salesforce | +| `raw` | *Optional[bool]* | :heavy_minus_sign: | Include raw response. Mostly used for debugging purposes | | +| `company_id` | *Optional[str]* | :heavy_minus_sign: | The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings. | 12345 | +| `sales_receipt` | [models.SalesReceiptInput](../models/salesreceiptinput.md) | :heavy_check_mark: | N/A | | \ No newline at end of file diff --git a/docs/models/accountingsalesreceiptsupdateresponse.md b/docs/models/accountingsalesreceiptsupdateresponse.md new file mode 100644 index 00000000..f4c4a552 --- /dev/null +++ b/docs/models/accountingsalesreceiptsupdateresponse.md @@ -0,0 +1,10 @@ +# AccountingSalesReceiptsUpdateResponse + + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | +| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | +| `update_sales_receipt_response` | [Optional[models.UpdateSalesReceiptResponse]](../models/updatesalesreceiptresponse.md) | :heavy_minus_sign: | SalesReceipt updated | +| `unexpected_error_response` | [Optional[models.UnexpectedErrorResponse]](../models/unexpectederrorresponse.md) | :heavy_minus_sign: | Unexpected error | \ No newline at end of file diff --git a/docs/models/attachment.md b/docs/models/attachment.md index e9255d60..fda4a199 100644 --- a/docs/models/attachment.md +++ b/docs/models/attachment.md @@ -12,6 +12,7 @@ | `size` | *OptionalNullable[int]* | :heavy_minus_sign: | The size of the file in bytes | 1810673 | | `reference` | [Optional[models.AttachmentReference]](../models/attachmentreference.md) | :heavy_minus_sign: | N/A | | | `description` | *OptionalNullable[str]* | :heavy_minus_sign: | Optional description of the file | A sample image | +| `file_url` | *OptionalNullable[str]* | :heavy_minus_sign: | The URL to download or preview the file | https://example.com/files/sample.jpg | | `parent_folder_id` | *OptionalNullable[str]* | :heavy_minus_sign: | The folder id where this attachment belong to | 123 | | `updated_by` | *OptionalNullable[str]* | :heavy_minus_sign: | The user who last updated the object. | 12345 | | `created_by` | *OptionalNullable[str]* | :heavy_minus_sign: | The user who created the object. | 12345 | diff --git a/docs/models/bankfeedaccount.md b/docs/models/bankfeedaccount.md index cdc8347a..0563af9e 100644 --- a/docs/models/bankfeedaccount.md +++ b/docs/models/bankfeedaccount.md @@ -8,9 +8,13 @@ | `id` | *str* | :heavy_check_mark: | A unique identifier for an object. | 12345 | | `bank_account_type` | [Optional[models.BankAccountType]](../models/bankaccounttype.md) | :heavy_minus_sign: | Type of the bank account. | bank | | `source_account_id` | *Optional[str]* | :heavy_minus_sign: | The source account's unique identifier. | src_456 | +| `source_routing_number` | *OptionalNullable[str]* | :heavy_minus_sign: | Bank routing number (US) | 021000021 | +| `source_account_number` | *OptionalNullable[str]* | :heavy_minus_sign: | The bank account number | 123465 | | `target_account_id` | *Optional[str]* | :heavy_minus_sign: | The target account's unique identifier in the accounting connector. | tgt_789 | | `target_account_name` | *Optional[str]* | :heavy_minus_sign: | Name associated with the target account. | Main Company Checking | | `target_account_number` | *Optional[str]* | :heavy_minus_sign: | Account number of the destination bank account. | NL91ABNA0417164300 | +| `balance` | *OptionalNullable[float]* | :heavy_minus_sign: | The current balance of the source bank account. | 25000 | +| `available_balance` | *OptionalNullable[float]* | :heavy_minus_sign: | The available balance of the source bank account (considering pending transactions and overdraft). | 24500 | | `currency` | [OptionalNullable[models.Currency]](../models/currency.md) | :heavy_minus_sign: | Indicates the associated currency for an amount of money. Values correspond to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217). | USD | | `feed_status` | [Optional[models.FeedStatus]](../models/feedstatus.md) | :heavy_minus_sign: | Current status of the bank feed. | pending | | `country` | *OptionalNullable[str]* | :heavy_minus_sign: | Country code according to ISO 3166-1 alpha-2. | US | diff --git a/docs/models/bankfeedaccountinput.md b/docs/models/bankfeedaccountinput.md index 0fb0e076..645be362 100644 --- a/docs/models/bankfeedaccountinput.md +++ b/docs/models/bankfeedaccountinput.md @@ -7,9 +7,13 @@ | ---------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------- | | `bank_account_type` | [Optional[models.BankAccountType]](../models/bankaccounttype.md) | :heavy_minus_sign: | Type of the bank account. | bank | | `source_account_id` | *Optional[str]* | :heavy_minus_sign: | The source account's unique identifier. | src_456 | +| `source_routing_number` | *OptionalNullable[str]* | :heavy_minus_sign: | Bank routing number (US) | 021000021 | +| `source_account_number` | *OptionalNullable[str]* | :heavy_minus_sign: | The bank account number | 123465 | | `target_account_id` | *Optional[str]* | :heavy_minus_sign: | The target account's unique identifier in the accounting connector. | tgt_789 | | `target_account_name` | *Optional[str]* | :heavy_minus_sign: | Name associated with the target account. | Main Company Checking | | `target_account_number` | *Optional[str]* | :heavy_minus_sign: | Account number of the destination bank account. | NL91ABNA0417164300 | +| `balance` | *OptionalNullable[float]* | :heavy_minus_sign: | The current balance of the source bank account. | 25000 | +| `available_balance` | *OptionalNullable[float]* | :heavy_minus_sign: | The available balance of the source bank account (considering pending transactions and overdraft). | 24500 | | `currency` | [OptionalNullable[models.Currency]](../models/currency.md) | :heavy_minus_sign: | Indicates the associated currency for an amount of money. Values correspond to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217). | USD | | `feed_status` | [Optional[models.FeedStatus]](../models/feedstatus.md) | :heavy_minus_sign: | Current status of the bank feed. | pending | | `country` | *OptionalNullable[str]* | :heavy_minus_sign: | Country code according to ISO 3166-1 alpha-2. | US | diff --git a/docs/models/createpaymentmethodresponse.md b/docs/models/createpaymentmethodresponse.md new file mode 100644 index 00000000..b0af97b3 --- /dev/null +++ b/docs/models/createpaymentmethodresponse.md @@ -0,0 +1,16 @@ +# CreatePaymentMethodResponse + +Payment Methods + + +## Fields + +| Field | Type | Required | Description | Example | +| ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | +| `status_code` | *int* | :heavy_check_mark: | HTTP Response Status Code | 200 | +| `status` | *str* | :heavy_check_mark: | HTTP Response Status | OK | +| `service` | *str* | :heavy_check_mark: | Apideck ID of service provider | quickbooks | +| `resource` | *str* | :heavy_check_mark: | Unified API resource name | PaymentMethods | +| `operation` | *str* | :heavy_check_mark: | Operation performed | add | +| `data` | [models.UnifiedID](../models/unifiedid.md) | :heavy_check_mark: | A object containing a unique identifier for the resource that was created, updated, or deleted. | | +| `raw` | Dict[str, *Any*] | :heavy_minus_sign: | Raw response from the integration when raw=true query param is provided | | \ No newline at end of file diff --git a/docs/models/createsalesreceiptresponse.md b/docs/models/createsalesreceiptresponse.md new file mode 100644 index 00000000..3433fcb2 --- /dev/null +++ b/docs/models/createsalesreceiptresponse.md @@ -0,0 +1,16 @@ +# CreateSalesReceiptResponse + +SalesReceipt created + + +## Fields + +| Field | Type | Required | Description | Example | +| ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | +| `status_code` | *int* | :heavy_check_mark: | HTTP Response Status Code | 200 | +| `status` | *str* | :heavy_check_mark: | HTTP Response Status | OK | +| `service` | *str* | :heavy_check_mark: | Apideck ID of service provider | quickbooks | +| `resource` | *str* | :heavy_check_mark: | Unified API resource name | sales-receipts | +| `operation` | *str* | :heavy_check_mark: | Operation performed | add | +| `data` | [models.UnifiedID](../models/unifiedid.md) | :heavy_check_mark: | A object containing a unique identifier for the resource that was created, updated, or deleted. | | +| `raw` | Dict[str, *Any*] | :heavy_minus_sign: | Raw response from the integration when raw=true query param is provided | | \ No newline at end of file diff --git a/docs/models/customfield1.md b/docs/models/customfield1.md index 56498f33..7fadc737 100644 --- a/docs/models/customfield1.md +++ b/docs/models/customfield1.md @@ -3,9 +3,10 @@ ## Fields -| Field | Type | Required | Description | Example | -| ---------------------------------------------------------------------------- | ---------------------------------------------------------------------------- | ---------------------------------------------------------------------------- | ---------------------------------------------------------------------------- | ---------------------------------------------------------------------------- | -| `id` | *Nullable[str]* | :heavy_check_mark: | Unique identifier for the custom field. | 2389328923893298 | -| `name` | *OptionalNullable[str]* | :heavy_minus_sign: | Name of the custom field. | employee_level | -| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | More information about the custom field | Employee Level | -| `value` | [OptionalNullable[models.CustomField1Value]](../models/customfield1value.md) | :heavy_minus_sign: | N/A | | \ No newline at end of file +| Field | Type | Required | Description | Example | +| ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `id` | *Nullable[str]* | :heavy_check_mark: | Unique identifier for the custom field. | 2389328923893298 | +| `name` | *OptionalNullable[str]* | :heavy_minus_sign: | Name of the custom field. | employee_level | +| `ref_name` | *OptionalNullable[str]* | :heavy_minus_sign: | Display name of the record a reference-type custom field points at. `value` carries that record's id; this carries its human-readable name, so a consumer does not need a second lookup to render it. | Marketing | +| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | More information about the custom field | Employee Level | +| `value` | [OptionalNullable[models.CustomField1Value]](../models/customfield1value.md) | :heavy_minus_sign: | N/A | | \ No newline at end of file diff --git a/docs/models/customfield2.md b/docs/models/customfield2.md index 3be92912..1949fcf9 100644 --- a/docs/models/customfield2.md +++ b/docs/models/customfield2.md @@ -3,9 +3,10 @@ ## Fields -| Field | Type | Required | Description | Example | -| -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -| `id` | *OptionalNullable[str]* | :heavy_minus_sign: | Unique identifier for the custom field. | 2389328923893298 | -| `name` | *Nullable[str]* | :heavy_check_mark: | Name of the custom field. | employee_level | -| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | More information about the custom field | Employee Level | -| `value` | [OptionalNullable[models.CustomFieldValue]](../models/customfieldvalue.md) | :heavy_minus_sign: | N/A | | \ No newline at end of file +| Field | Type | Required | Description | Example | +| ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `id` | *OptionalNullable[str]* | :heavy_minus_sign: | Unique identifier for the custom field. | 2389328923893298 | +| `name` | *Nullable[str]* | :heavy_check_mark: | Name of the custom field. | employee_level | +| `ref_name` | *OptionalNullable[str]* | :heavy_minus_sign: | Display name of the record a reference-type custom field points at. `value` carries that record's id; this carries its human-readable name, so a consumer does not need a second lookup to render it. | Marketing | +| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | More information about the custom field | Employee Level | +| `value` | [OptionalNullable[models.CustomFieldValue]](../models/customfieldvalue.md) | :heavy_minus_sign: | N/A | | \ No newline at end of file diff --git a/docs/models/deletepaymentmethodresponse.md b/docs/models/deletepaymentmethodresponse.md new file mode 100644 index 00000000..9b6742eb --- /dev/null +++ b/docs/models/deletepaymentmethodresponse.md @@ -0,0 +1,16 @@ +# DeletePaymentMethodResponse + +Payment Methods + + +## Fields + +| Field | Type | Required | Description | Example | +| ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | +| `status_code` | *int* | :heavy_check_mark: | HTTP Response Status Code | 200 | +| `status` | *str* | :heavy_check_mark: | HTTP Response Status | OK | +| `service` | *str* | :heavy_check_mark: | Apideck ID of service provider | quickbooks | +| `resource` | *str* | :heavy_check_mark: | Unified API resource name | PaymentMethods | +| `operation` | *str* | :heavy_check_mark: | Operation performed | delete | +| `data` | [models.UnifiedID](../models/unifiedid.md) | :heavy_check_mark: | A object containing a unique identifier for the resource that was created, updated, or deleted. | | +| `raw` | Dict[str, *Any*] | :heavy_minus_sign: | Raw response from the integration when raw=true query param is provided | | \ No newline at end of file diff --git a/docs/models/deletesalesreceiptresponse.md b/docs/models/deletesalesreceiptresponse.md new file mode 100644 index 00000000..5aece1e8 --- /dev/null +++ b/docs/models/deletesalesreceiptresponse.md @@ -0,0 +1,16 @@ +# DeleteSalesReceiptResponse + +SalesReceipt deleted + + +## Fields + +| Field | Type | Required | Description | Example | +| ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | +| `status_code` | *int* | :heavy_check_mark: | HTTP Response Status Code | 200 | +| `status` | *str* | :heavy_check_mark: | HTTP Response Status | OK | +| `service` | *str* | :heavy_check_mark: | Apideck ID of service provider | quickbooks | +| `resource` | *str* | :heavy_check_mark: | Unified API resource name | sales-receipts | +| `operation` | *str* | :heavy_check_mark: | Operation performed | delete | +| `data` | [models.UnifiedID](../models/unifiedid.md) | :heavy_check_mark: | A object containing a unique identifier for the resource that was created, updated, or deleted. | | +| `raw` | Dict[str, *Any*] | :heavy_minus_sign: | Raw response from the integration when raw=true query param is provided | | \ No newline at end of file diff --git a/docs/models/filestoragefilesdownloadrequest.md b/docs/models/filestoragefilesdownloadrequest.md index 8d4f89a2..431184d0 100644 --- a/docs/models/filestoragefilesdownloadrequest.md +++ b/docs/models/filestoragefilesdownloadrequest.md @@ -9,4 +9,5 @@ | `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | | `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | | `service_id` | *Optional[str]* | :heavy_minus_sign: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | salesforce | -| `fields` | *OptionalNullable[str]* | :heavy_minus_sign: | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. | id,updated_at | \ No newline at end of file +| `fields` | *OptionalNullable[str]* | :heavy_minus_sign: | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. | id,updated_at | +| `follow_redirects` | *Optional[bool]* | :heavy_minus_sign: | Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. | false | \ No newline at end of file diff --git a/docs/models/filestoragefilesdownloadresponse.md b/docs/models/filestoragefilesdownloadresponse.md index a11aa305..44f28e8c 100644 --- a/docs/models/filestoragefilesdownloadresponse.md +++ b/docs/models/filestoragefilesdownloadresponse.md @@ -3,8 +3,8 @@ ## Fields -| Field | Type | Required | Description | -| -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | -| `get_file_download_response` | *Optional[httpx.Response]* | :heavy_minus_sign: | File Download | -| `unexpected_error_response` | [Optional[models.UnexpectedErrorResponse]](../models/unexpectederrorresponse.md) | :heavy_minus_sign: | Unexpected error | \ No newline at end of file +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | +| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | +| `get_file_download_response` | *Optional[httpx.Response]* | :heavy_minus_sign: | File Download. When the request includes `x-apideck-follow-redirects: false` and the download would otherwise redirect to a presigned URL, the response body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the file. | +| `unexpected_error_response` | [Optional[models.UnexpectedErrorResponse]](../models/unexpectederrorresponse.md) | :heavy_minus_sign: | Unexpected error | \ No newline at end of file diff --git a/docs/models/filestoragefilesexportresponse.md b/docs/models/filestoragefilesexportresponse.md index ddbe94d3..a5243b9d 100644 --- a/docs/models/filestoragefilesexportresponse.md +++ b/docs/models/filestoragefilesexportresponse.md @@ -3,8 +3,8 @@ ## Fields -| Field | Type | Required | Description | -| -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | -| `get_file_download_response` | *Optional[httpx.Response]* | :heavy_minus_sign: | File Download | -| `unexpected_error_response` | [Optional[models.UnexpectedErrorResponse]](../models/unexpectederrorresponse.md) | :heavy_minus_sign: | Unexpected error | \ No newline at end of file +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | +| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | +| `get_file_download_response` | *Optional[httpx.Response]* | :heavy_minus_sign: | File Download. When the request includes `x-apideck-follow-redirects: false` and the download would otherwise redirect to a presigned URL, the response body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the file. | +| `unexpected_error_response` | [Optional[models.UnexpectedErrorResponse]](../models/unexpectederrorresponse.md) | :heavy_minus_sign: | Unexpected error | \ No newline at end of file diff --git a/docs/models/getpaymentmethodresponse.md b/docs/models/getpaymentmethodresponse.md new file mode 100644 index 00000000..9f9b4280 --- /dev/null +++ b/docs/models/getpaymentmethodresponse.md @@ -0,0 +1,17 @@ +# GetPaymentMethodResponse + +Payment Methods + + +## Fields + +| Field | Type | Required | Description | Example | +| ----------------------------------------------------------------------- | ----------------------------------------------------------------------- | ----------------------------------------------------------------------- | ----------------------------------------------------------------------- | ----------------------------------------------------------------------- | +| `status_code` | *int* | :heavy_check_mark: | HTTP Response Status Code | 200 | +| `status` | *str* | :heavy_check_mark: | HTTP Response Status | OK | +| `service` | *str* | :heavy_check_mark: | Apideck ID of service provider | quickbooks | +| `resource` | *str* | :heavy_check_mark: | Unified API resource name | PaymentMethods | +| `operation` | *str* | :heavy_check_mark: | Operation performed | one | +| `data` | [models.AccountingPaymentMethod](../models/accountingpaymentmethod.md) | :heavy_check_mark: | N/A | | +| `meta` | [Optional[models.Meta]](../models/meta.md) | :heavy_minus_sign: | Response metadata | | +| `raw` | Dict[str, *Any*] | :heavy_minus_sign: | Raw response from the integration when raw=true query param is provided | | \ No newline at end of file diff --git a/docs/models/getpaymentmethodsresponse.md b/docs/models/getpaymentmethodsresponse.md new file mode 100644 index 00000000..ccffe654 --- /dev/null +++ b/docs/models/getpaymentmethodsresponse.md @@ -0,0 +1,18 @@ +# GetPaymentMethodsResponse + +Payment Methods + + +## Fields + +| Field | Type | Required | Description | Example | +| ---------------------------------------------------------------------------- | ---------------------------------------------------------------------------- | ---------------------------------------------------------------------------- | ---------------------------------------------------------------------------- | ---------------------------------------------------------------------------- | +| `status_code` | *int* | :heavy_check_mark: | HTTP Response Status Code | 200 | +| `status` | *str* | :heavy_check_mark: | HTTP Response Status | OK | +| `service` | *str* | :heavy_check_mark: | Apideck ID of service provider | quickbooks | +| `resource` | *str* | :heavy_check_mark: | Unified API resource name | PaymentMethods | +| `operation` | *str* | :heavy_check_mark: | Operation performed | all | +| `data` | List[[models.AccountingPaymentMethod](../models/accountingpaymentmethod.md)] | :heavy_check_mark: | N/A | | +| `meta` | [Optional[models.Meta]](../models/meta.md) | :heavy_minus_sign: | Response metadata | | +| `links` | [Optional[models.Links]](../models/links.md) | :heavy_minus_sign: | Links to navigate to previous or next pages through the API | | +| `raw` | Dict[str, *Any*] | :heavy_minus_sign: | Raw response from the integration when raw=true query param is provided | | \ No newline at end of file diff --git a/docs/models/getsalesreceiptresponse.md b/docs/models/getsalesreceiptresponse.md new file mode 100644 index 00000000..811db98a --- /dev/null +++ b/docs/models/getsalesreceiptresponse.md @@ -0,0 +1,17 @@ +# GetSalesReceiptResponse + +SalesReceipt + + +## Fields + +| Field | Type | Required | Description | Example | +| ----------------------------------------------------------------------- | ----------------------------------------------------------------------- | ----------------------------------------------------------------------- | ----------------------------------------------------------------------- | ----------------------------------------------------------------------- | +| `status_code` | *int* | :heavy_check_mark: | HTTP Response Status Code | 200 | +| `status` | *str* | :heavy_check_mark: | HTTP Response Status | OK | +| `service` | *str* | :heavy_check_mark: | Apideck ID of service provider | quickbooks | +| `resource` | *str* | :heavy_check_mark: | Unified API resource name | sales-receipts | +| `operation` | *str* | :heavy_check_mark: | Operation performed | one | +| `data` | [models.SalesReceipt](../models/salesreceipt.md) | :heavy_check_mark: | N/A | | +| `meta` | [Optional[models.Meta]](../models/meta.md) | :heavy_minus_sign: | Response metadata | | +| `raw` | Dict[str, *Any*] | :heavy_minus_sign: | Raw response from the integration when raw=true query param is provided | | \ No newline at end of file diff --git a/docs/models/getsalesreceiptsresponse.md b/docs/models/getsalesreceiptsresponse.md new file mode 100644 index 00000000..d4ae2352 --- /dev/null +++ b/docs/models/getsalesreceiptsresponse.md @@ -0,0 +1,18 @@ +# GetSalesReceiptsResponse + +SalesReceipts + + +## Fields + +| Field | Type | Required | Description | Example | +| ----------------------------------------------------------------------- | ----------------------------------------------------------------------- | ----------------------------------------------------------------------- | ----------------------------------------------------------------------- | ----------------------------------------------------------------------- | +| `status_code` | *int* | :heavy_check_mark: | HTTP Response Status Code | 200 | +| `status` | *str* | :heavy_check_mark: | HTTP Response Status | OK | +| `service` | *str* | :heavy_check_mark: | Apideck ID of service provider | quickbooks | +| `resource` | *str* | :heavy_check_mark: | Unified API resource name | sales-receipts | +| `operation` | *str* | :heavy_check_mark: | Operation performed | all | +| `data` | List[[models.SalesReceipt](../models/salesreceipt.md)] | :heavy_check_mark: | N/A | | +| `meta` | [Optional[models.Meta]](../models/meta.md) | :heavy_minus_sign: | Response metadata | | +| `links` | [Optional[models.Links]](../models/links.md) | :heavy_minus_sign: | Links to navigate to previous or next pages through the API | | +| `raw` | Dict[str, *Any*] | :heavy_minus_sign: | Raw response from the integration when raw=true query param is provided | | \ No newline at end of file diff --git a/docs/models/proxydeleteproxyrequest.md b/docs/models/proxydeleteproxyrequest.md index 08f12093..d27bce0b 100644 --- a/docs/models/proxydeleteproxyrequest.md +++ b/docs/models/proxydeleteproxyrequest.md @@ -3,12 +3,13 @@ ## Fields -| Field | Type | Required | Description | Example | -| --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | -| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | -| `service_id` | *str* | :heavy_check_mark: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | close | -| `unified_api` | *Optional[str]* | :heavy_minus_sign: | Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. | hris | -| `downstream_url` | *str* | :heavy_check_mark: | Downstream URL | https://api.close.com/api/v1/lead | -| `downstream_authorization` | *Optional[str]* | :heavy_minus_sign: | Downstream authorization header. This will skip the Vault token injection. | Bearer | -| `timeout` | *Optional[int]* | :heavy_minus_sign: | Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). | 30000 | \ No newline at end of file +| Field | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *str* | :heavy_check_mark: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | close | +| `unified_api` | *Optional[str]* | :heavy_minus_sign: | Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. | hris | +| `downstream_url` | *str* | :heavy_check_mark: | Downstream URL | https://api.close.com/api/v1/lead | +| `downstream_authorization` | *Optional[str]* | :heavy_minus_sign: | Downstream authorization header. This will skip the Vault token injection. | Bearer | +| `timeout` | *Optional[int]* | :heavy_minus_sign: | Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). | 30000 | +| `follow_redirects` | *Optional[bool]* | :heavy_minus_sign: | Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. | false | \ No newline at end of file diff --git a/docs/models/proxydeleteproxyresponse.md b/docs/models/proxydeleteproxyresponse.md index ecb79c5a..ee505e15 100644 --- a/docs/models/proxydeleteproxyresponse.md +++ b/docs/models/proxydeleteproxyresponse.md @@ -3,17 +3,17 @@ ## Fields -| Field | Type | Required | Description | -| ------------------------------------------------ | ------------------------------------------------ | ------------------------------------------------ | ------------------------------------------------ | -| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | -| `response_json` | Dict[str, *Any*] | :heavy_minus_sign: | Ok | -| `response_binary` | *Optional[httpx.Response]* | :heavy_minus_sign: | Ok | -| `response_pdf` | *Optional[httpx.Response]* | :heavy_minus_sign: | Ok | -| `response_xml` | *Optional[str]* | :heavy_minus_sign: | Ok | -| `response_csv` | *Optional[str]* | :heavy_minus_sign: | Ok | -| `response_text` | *Optional[str]* | :heavy_minus_sign: | Ok | -| `error_json` | Dict[str, *Any*] | :heavy_minus_sign: | Proxy error | -| `error_xml` | *Optional[str]* | :heavy_minus_sign: | Proxy error | -| `error_html` | *Optional[str]* | :heavy_minus_sign: | Proxy error | -| `error_text` | *Optional[str]* | :heavy_minus_sign: | Proxy error | -| `headers` | Dict[str, List[*str*]] | :heavy_check_mark: | N/A | \ No newline at end of file +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | +| `response_json` | Dict[str, *Any*] | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_binary` | *Optional[httpx.Response]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_pdf` | *Optional[httpx.Response]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_xml` | *Optional[str]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_csv` | *Optional[str]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_text` | *Optional[str]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `error_json` | Dict[str, *Any*] | :heavy_minus_sign: | Proxy error | +| `error_xml` | *Optional[str]* | :heavy_minus_sign: | Proxy error | +| `error_html` | *Optional[str]* | :heavy_minus_sign: | Proxy error | +| `error_text` | *Optional[str]* | :heavy_minus_sign: | Proxy error | +| `headers` | Dict[str, List[*str*]] | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/proxygetproxyrequest.md b/docs/models/proxygetproxyrequest.md index 53295db4..aaf078e9 100644 --- a/docs/models/proxygetproxyrequest.md +++ b/docs/models/proxygetproxyrequest.md @@ -3,12 +3,13 @@ ## Fields -| Field | Type | Required | Description | Example | -| --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | -| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | -| `service_id` | *str* | :heavy_check_mark: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | close | -| `unified_api` | *Optional[str]* | :heavy_minus_sign: | Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. | hris | -| `downstream_url` | *str* | :heavy_check_mark: | Downstream URL | https://api.close.com/api/v1/lead | -| `downstream_authorization` | *Optional[str]* | :heavy_minus_sign: | Downstream authorization header. This will skip the Vault token injection. | Bearer | -| `timeout` | *Optional[int]* | :heavy_minus_sign: | Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). | 30000 | \ No newline at end of file +| Field | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *str* | :heavy_check_mark: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | close | +| `unified_api` | *Optional[str]* | :heavy_minus_sign: | Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. | hris | +| `downstream_url` | *str* | :heavy_check_mark: | Downstream URL | https://api.close.com/api/v1/lead | +| `downstream_authorization` | *Optional[str]* | :heavy_minus_sign: | Downstream authorization header. This will skip the Vault token injection. | Bearer | +| `timeout` | *Optional[int]* | :heavy_minus_sign: | Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). | 30000 | +| `follow_redirects` | *Optional[bool]* | :heavy_minus_sign: | Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. | false | \ No newline at end of file diff --git a/docs/models/proxygetproxyresponse.md b/docs/models/proxygetproxyresponse.md index 46ce2252..7d98c8c7 100644 --- a/docs/models/proxygetproxyresponse.md +++ b/docs/models/proxygetproxyresponse.md @@ -3,17 +3,17 @@ ## Fields -| Field | Type | Required | Description | -| ------------------------------------------------ | ------------------------------------------------ | ------------------------------------------------ | ------------------------------------------------ | -| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | -| `response_json` | Dict[str, *Any*] | :heavy_minus_sign: | Ok | -| `response_binary` | *Optional[httpx.Response]* | :heavy_minus_sign: | Ok | -| `response_pdf` | *Optional[httpx.Response]* | :heavy_minus_sign: | Ok | -| `response_xml` | *Optional[str]* | :heavy_minus_sign: | Ok | -| `response_csv` | *Optional[str]* | :heavy_minus_sign: | Ok | -| `response_text` | *Optional[str]* | :heavy_minus_sign: | Ok | -| `error_json` | Dict[str, *Any*] | :heavy_minus_sign: | Proxy error | -| `error_xml` | *Optional[str]* | :heavy_minus_sign: | Proxy error | -| `error_html` | *Optional[str]* | :heavy_minus_sign: | Proxy error | -| `error_text` | *Optional[str]* | :heavy_minus_sign: | Proxy error | -| `headers` | Dict[str, List[*str*]] | :heavy_check_mark: | N/A | \ No newline at end of file +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | +| `response_json` | Dict[str, *Any*] | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_binary` | *Optional[httpx.Response]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_pdf` | *Optional[httpx.Response]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_xml` | *Optional[str]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_csv` | *Optional[str]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_text` | *Optional[str]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `error_json` | Dict[str, *Any*] | :heavy_minus_sign: | Proxy error | +| `error_xml` | *Optional[str]* | :heavy_minus_sign: | Proxy error | +| `error_html` | *Optional[str]* | :heavy_minus_sign: | Proxy error | +| `error_text` | *Optional[str]* | :heavy_minus_sign: | Proxy error | +| `headers` | Dict[str, List[*str*]] | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/proxyoptionsproxyrequest.md b/docs/models/proxyoptionsproxyrequest.md index 542ead39..c9854573 100644 --- a/docs/models/proxyoptionsproxyrequest.md +++ b/docs/models/proxyoptionsproxyrequest.md @@ -3,12 +3,13 @@ ## Fields -| Field | Type | Required | Description | Example | -| --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | -| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | -| `service_id` | *str* | :heavy_check_mark: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | close | -| `unified_api` | *Optional[str]* | :heavy_minus_sign: | Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. | hris | -| `downstream_url` | *str* | :heavy_check_mark: | Downstream URL | https://api.close.com/api/v1/lead | -| `downstream_authorization` | *Optional[str]* | :heavy_minus_sign: | Downstream authorization header. This will skip the Vault token injection. | Bearer | -| `timeout` | *Optional[int]* | :heavy_minus_sign: | Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). | 30000 | \ No newline at end of file +| Field | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *str* | :heavy_check_mark: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | close | +| `unified_api` | *Optional[str]* | :heavy_minus_sign: | Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. | hris | +| `downstream_url` | *str* | :heavy_check_mark: | Downstream URL | https://api.close.com/api/v1/lead | +| `downstream_authorization` | *Optional[str]* | :heavy_minus_sign: | Downstream authorization header. This will skip the Vault token injection. | Bearer | +| `timeout` | *Optional[int]* | :heavy_minus_sign: | Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). | 30000 | +| `follow_redirects` | *Optional[bool]* | :heavy_minus_sign: | Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. | false | \ No newline at end of file diff --git a/docs/models/proxyoptionsproxyresponse.md b/docs/models/proxyoptionsproxyresponse.md index 33a1fe37..162a2b32 100644 --- a/docs/models/proxyoptionsproxyresponse.md +++ b/docs/models/proxyoptionsproxyresponse.md @@ -3,17 +3,17 @@ ## Fields -| Field | Type | Required | Description | -| ------------------------------------------------ | ------------------------------------------------ | ------------------------------------------------ | ------------------------------------------------ | -| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | -| `response_json` | Dict[str, *Any*] | :heavy_minus_sign: | Ok | -| `response_binary` | *Optional[httpx.Response]* | :heavy_minus_sign: | Ok | -| `response_pdf` | *Optional[httpx.Response]* | :heavy_minus_sign: | Ok | -| `response_xml` | *Optional[str]* | :heavy_minus_sign: | Ok | -| `response_csv` | *Optional[str]* | :heavy_minus_sign: | Ok | -| `response_text` | *Optional[str]* | :heavy_minus_sign: | Ok | -| `error_json` | Dict[str, *Any*] | :heavy_minus_sign: | Proxy error | -| `error_xml` | *Optional[str]* | :heavy_minus_sign: | Proxy error | -| `error_html` | *Optional[str]* | :heavy_minus_sign: | Proxy error | -| `error_text` | *Optional[str]* | :heavy_minus_sign: | Proxy error | -| `headers` | Dict[str, List[*str*]] | :heavy_check_mark: | N/A | \ No newline at end of file +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | +| `response_json` | Dict[str, *Any*] | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_binary` | *Optional[httpx.Response]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_pdf` | *Optional[httpx.Response]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_xml` | *Optional[str]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_csv` | *Optional[str]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_text` | *Optional[str]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `error_json` | Dict[str, *Any*] | :heavy_minus_sign: | Proxy error | +| `error_xml` | *Optional[str]* | :heavy_minus_sign: | Proxy error | +| `error_html` | *Optional[str]* | :heavy_minus_sign: | Proxy error | +| `error_text` | *Optional[str]* | :heavy_minus_sign: | Proxy error | +| `headers` | Dict[str, List[*str*]] | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/proxypatchproxyrequest.md b/docs/models/proxypatchproxyrequest.md index 3c2b8d11..63ee9bed 100644 --- a/docs/models/proxypatchproxyrequest.md +++ b/docs/models/proxypatchproxyrequest.md @@ -3,13 +3,14 @@ ## Fields -| Field | Type | Required | Description | Example | -| --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | -| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | -| `service_id` | *str* | :heavy_check_mark: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | close | -| `unified_api` | *Optional[str]* | :heavy_minus_sign: | Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. | hris | -| `downstream_url` | *str* | :heavy_check_mark: | Downstream URL | https://api.close.com/api/v1/lead | -| `downstream_authorization` | *Optional[str]* | :heavy_minus_sign: | Downstream authorization header. This will skip the Vault token injection. | Bearer | -| `timeout` | *Optional[int]* | :heavy_minus_sign: | Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). | 30000 | -| `request_body` | *Optional[Union[bytes, IO[bytes], io.BufferedReader]]* | :heavy_minus_sign: | Depending on the verb/method of the request this will contain the request body you want to POST/PATCH/PUT. | | \ No newline at end of file +| Field | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *str* | :heavy_check_mark: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | close | +| `unified_api` | *Optional[str]* | :heavy_minus_sign: | Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. | hris | +| `downstream_url` | *str* | :heavy_check_mark: | Downstream URL | https://api.close.com/api/v1/lead | +| `downstream_authorization` | *Optional[str]* | :heavy_minus_sign: | Downstream authorization header. This will skip the Vault token injection. | Bearer | +| `timeout` | *Optional[int]* | :heavy_minus_sign: | Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). | 30000 | +| `follow_redirects` | *Optional[bool]* | :heavy_minus_sign: | Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. | false | +| `request_body` | *Optional[Union[bytes, IO[bytes], io.BufferedReader]]* | :heavy_minus_sign: | Depending on the verb/method of the request this will contain the request body you want to POST/PATCH/PUT. | | \ No newline at end of file diff --git a/docs/models/proxypatchproxyresponse.md b/docs/models/proxypatchproxyresponse.md index 3f4e97f8..c0d74de7 100644 --- a/docs/models/proxypatchproxyresponse.md +++ b/docs/models/proxypatchproxyresponse.md @@ -3,17 +3,17 @@ ## Fields -| Field | Type | Required | Description | -| ------------------------------------------------ | ------------------------------------------------ | ------------------------------------------------ | ------------------------------------------------ | -| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | -| `response_json` | Dict[str, *Any*] | :heavy_minus_sign: | Ok | -| `response_binary` | *Optional[httpx.Response]* | :heavy_minus_sign: | Ok | -| `response_pdf` | *Optional[httpx.Response]* | :heavy_minus_sign: | Ok | -| `response_xml` | *Optional[str]* | :heavy_minus_sign: | Ok | -| `response_csv` | *Optional[str]* | :heavy_minus_sign: | Ok | -| `response_text` | *Optional[str]* | :heavy_minus_sign: | Ok | -| `error_json` | Dict[str, *Any*] | :heavy_minus_sign: | Proxy error | -| `error_xml` | *Optional[str]* | :heavy_minus_sign: | Proxy error | -| `error_html` | *Optional[str]* | :heavy_minus_sign: | Proxy error | -| `error_text` | *Optional[str]* | :heavy_minus_sign: | Proxy error | -| `headers` | Dict[str, List[*str*]] | :heavy_check_mark: | N/A | \ No newline at end of file +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | +| `response_json` | Dict[str, *Any*] | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_binary` | *Optional[httpx.Response]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_pdf` | *Optional[httpx.Response]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_xml` | *Optional[str]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_csv` | *Optional[str]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_text` | *Optional[str]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `error_json` | Dict[str, *Any*] | :heavy_minus_sign: | Proxy error | +| `error_xml` | *Optional[str]* | :heavy_minus_sign: | Proxy error | +| `error_html` | *Optional[str]* | :heavy_minus_sign: | Proxy error | +| `error_text` | *Optional[str]* | :heavy_minus_sign: | Proxy error | +| `headers` | Dict[str, List[*str*]] | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/proxypostproxyrequest.md b/docs/models/proxypostproxyrequest.md index 2aa71558..c3a62901 100644 --- a/docs/models/proxypostproxyrequest.md +++ b/docs/models/proxypostproxyrequest.md @@ -3,13 +3,14 @@ ## Fields -| Field | Type | Required | Description | Example | -| --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | -| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | -| `service_id` | *str* | :heavy_check_mark: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | close | -| `unified_api` | *Optional[str]* | :heavy_minus_sign: | Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. | hris | -| `downstream_url` | *str* | :heavy_check_mark: | Downstream URL | https://api.close.com/api/v1/lead | -| `downstream_authorization` | *Optional[str]* | :heavy_minus_sign: | Downstream authorization header. This will skip the Vault token injection. | Bearer | -| `timeout` | *Optional[int]* | :heavy_minus_sign: | Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). | 30000 | -| `request_body` | *Optional[Union[bytes, IO[bytes], io.BufferedReader]]* | :heavy_minus_sign: | Depending on the verb/method of the request this will contain the request body you want to POST/PATCH/PUT. | | \ No newline at end of file +| Field | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *str* | :heavy_check_mark: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | close | +| `unified_api` | *Optional[str]* | :heavy_minus_sign: | Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. | hris | +| `downstream_url` | *str* | :heavy_check_mark: | Downstream URL | https://api.close.com/api/v1/lead | +| `downstream_authorization` | *Optional[str]* | :heavy_minus_sign: | Downstream authorization header. This will skip the Vault token injection. | Bearer | +| `timeout` | *Optional[int]* | :heavy_minus_sign: | Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). | 30000 | +| `follow_redirects` | *Optional[bool]* | :heavy_minus_sign: | Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. | false | +| `request_body` | *Optional[Union[bytes, IO[bytes], io.BufferedReader]]* | :heavy_minus_sign: | Depending on the verb/method of the request this will contain the request body you want to POST/PATCH/PUT. | | \ No newline at end of file diff --git a/docs/models/proxypostproxyresponse.md b/docs/models/proxypostproxyresponse.md index d4614a9c..81f86435 100644 --- a/docs/models/proxypostproxyresponse.md +++ b/docs/models/proxypostproxyresponse.md @@ -3,17 +3,17 @@ ## Fields -| Field | Type | Required | Description | -| ------------------------------------------------ | ------------------------------------------------ | ------------------------------------------------ | ------------------------------------------------ | -| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | -| `response_json` | Dict[str, *Any*] | :heavy_minus_sign: | Ok | -| `response_binary` | *Optional[httpx.Response]* | :heavy_minus_sign: | Ok | -| `response_pdf` | *Optional[httpx.Response]* | :heavy_minus_sign: | Ok | -| `response_xml` | *Optional[str]* | :heavy_minus_sign: | Ok | -| `response_csv` | *Optional[str]* | :heavy_minus_sign: | Ok | -| `response_text` | *Optional[str]* | :heavy_minus_sign: | Ok | -| `error_json` | Dict[str, *Any*] | :heavy_minus_sign: | Proxy error | -| `error_xml` | *Optional[str]* | :heavy_minus_sign: | Proxy error | -| `error_html` | *Optional[str]* | :heavy_minus_sign: | Proxy error | -| `error_text` | *Optional[str]* | :heavy_minus_sign: | Proxy error | -| `headers` | Dict[str, List[*str*]] | :heavy_check_mark: | N/A | \ No newline at end of file +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | +| `response_json` | Dict[str, *Any*] | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_binary` | *Optional[httpx.Response]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_pdf` | *Optional[httpx.Response]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_xml` | *Optional[str]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_csv` | *Optional[str]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_text` | *Optional[str]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `error_json` | Dict[str, *Any*] | :heavy_minus_sign: | Proxy error | +| `error_xml` | *Optional[str]* | :heavy_minus_sign: | Proxy error | +| `error_html` | *Optional[str]* | :heavy_minus_sign: | Proxy error | +| `error_text` | *Optional[str]* | :heavy_minus_sign: | Proxy error | +| `headers` | Dict[str, List[*str*]] | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/proxyputproxyrequest.md b/docs/models/proxyputproxyrequest.md index bee8d011..230f73cd 100644 --- a/docs/models/proxyputproxyrequest.md +++ b/docs/models/proxyputproxyrequest.md @@ -3,13 +3,14 @@ ## Fields -| Field | Type | Required | Description | Example | -| --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | -| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | -| `service_id` | *str* | :heavy_check_mark: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | close | -| `unified_api` | *Optional[str]* | :heavy_minus_sign: | Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. | hris | -| `downstream_url` | *str* | :heavy_check_mark: | Downstream URL | https://api.close.com/api/v1/lead | -| `downstream_authorization` | *Optional[str]* | :heavy_minus_sign: | Downstream authorization header. This will skip the Vault token injection. | Bearer | -| `timeout` | *Optional[int]* | :heavy_minus_sign: | Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). | 30000 | -| `request_body` | *Optional[Union[bytes, IO[bytes], io.BufferedReader]]* | :heavy_minus_sign: | Depending on the verb/method of the request this will contain the request body you want to POST/PATCH/PUT. | | \ No newline at end of file +| Field | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *str* | :heavy_check_mark: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | close | +| `unified_api` | *Optional[str]* | :heavy_minus_sign: | Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. | hris | +| `downstream_url` | *str* | :heavy_check_mark: | Downstream URL | https://api.close.com/api/v1/lead | +| `downstream_authorization` | *Optional[str]* | :heavy_minus_sign: | Downstream authorization header. This will skip the Vault token injection. | Bearer | +| `timeout` | *Optional[int]* | :heavy_minus_sign: | Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). | 30000 | +| `follow_redirects` | *Optional[bool]* | :heavy_minus_sign: | Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. | false | +| `request_body` | *Optional[Union[bytes, IO[bytes], io.BufferedReader]]* | :heavy_minus_sign: | Depending on the verb/method of the request this will contain the request body you want to POST/PATCH/PUT. | | \ No newline at end of file diff --git a/docs/models/proxyputproxyresponse.md b/docs/models/proxyputproxyresponse.md index 42568807..8f22e30f 100644 --- a/docs/models/proxyputproxyresponse.md +++ b/docs/models/proxyputproxyresponse.md @@ -3,17 +3,17 @@ ## Fields -| Field | Type | Required | Description | -| ------------------------------------------------ | ------------------------------------------------ | ------------------------------------------------ | ------------------------------------------------ | -| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | -| `response_json` | Dict[str, *Any*] | :heavy_minus_sign: | Ok | -| `response_binary` | *Optional[httpx.Response]* | :heavy_minus_sign: | Ok | -| `response_pdf` | *Optional[httpx.Response]* | :heavy_minus_sign: | Ok | -| `response_xml` | *Optional[str]* | :heavy_minus_sign: | Ok | -| `response_csv` | *Optional[str]* | :heavy_minus_sign: | Ok | -| `response_text` | *Optional[str]* | :heavy_minus_sign: | Ok | -| `error_json` | Dict[str, *Any*] | :heavy_minus_sign: | Proxy error | -| `error_xml` | *Optional[str]* | :heavy_minus_sign: | Proxy error | -| `error_html` | *Optional[str]* | :heavy_minus_sign: | Proxy error | -| `error_text` | *Optional[str]* | :heavy_minus_sign: | Proxy error | -| `headers` | Dict[str, List[*str*]] | :heavy_check_mark: | N/A | \ No newline at end of file +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `http_meta` | [models.HTTPMetadata](../models/httpmetadata.md) | :heavy_check_mark: | N/A | +| `response_json` | Dict[str, *Any*] | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_binary` | *Optional[httpx.Response]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_pdf` | *Optional[httpx.Response]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_xml` | *Optional[str]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_csv` | *Optional[str]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `response_text` | *Optional[str]* | :heavy_minus_sign: | Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload. | +| `error_json` | Dict[str, *Any*] | :heavy_minus_sign: | Proxy error | +| `error_xml` | *Optional[str]* | :heavy_minus_sign: | Proxy error | +| `error_html` | *Optional[str]* | :heavy_minus_sign: | Proxy error | +| `error_text` | *Optional[str]* | :heavy_minus_sign: | Proxy error | +| `headers` | Dict[str, List[*str*]] | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/salesreceipt.md b/docs/models/salesreceipt.md new file mode 100644 index 00000000..6d455940 --- /dev/null +++ b/docs/models/salesreceipt.md @@ -0,0 +1,40 @@ +# SalesReceipt + + +## Fields + +| Field | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `id` | *str* | :heavy_check_mark: | Unique identifier representing the sales receipt | 123456 | +| `number` | *OptionalNullable[str]* | :heavy_minus_sign: | Reference number for the sales receipt. | SR-00001 | +| `customer` | [OptionalNullable[models.LinkedCustomer]](../models/linkedcustomer.md) | :heavy_minus_sign: | The customer this entity is linked to. | | +| `currency` | [OptionalNullable[models.Currency]](../models/currency.md) | :heavy_minus_sign: | Indicates the associated currency for an amount of money. Values correspond to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217). | USD | +| `currency_rate` | *OptionalNullable[float]* | :heavy_minus_sign: | Currency Exchange Rate at the time entity was recorded/generated. | 0.69 | +| `tax_inclusive` | *OptionalNullable[bool]* | :heavy_minus_sign: | Amounts are including tax | true | +| `sub_total` | *OptionalNullable[float]* | :heavy_minus_sign: | Subtotal amount, normally before tax. | 250 | +| `total_amount` | *Nullable[float]* | :heavy_check_mark: | The total amount of the transaction or record | 49.99 | +| `total_tax` | *OptionalNullable[float]* | :heavy_minus_sign: | Total tax amount applied to this transaction. | 25 | +| `transaction_date` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_minus_sign: | The date of the sales receipt transaction - YYYY-MM-DDThh:mm:ss.sTZD | 2021-05-01T12:00:00.000Z | +| `payment_method` | *OptionalNullable[str]* | :heavy_minus_sign: | Payment method used for the transaction, such as cash, credit card, bank transfer, or check | cash | +| `payment_method_reference` | *OptionalNullable[str]* | :heavy_minus_sign: | Optional reference message returned by payment method on processing | 123456 | +| `payment_method_id` | *OptionalNullable[str]* | :heavy_minus_sign: | A unique identifier for an object. | 12345 | +| `account` | [OptionalNullable[models.LinkedLedgerAccount]](../models/linkedledgeraccount.md) | :heavy_minus_sign: | N/A | | +| `line_items` | List[[models.InvoiceLineItem](../models/invoicelineitem.md)] | :heavy_minus_sign: | Line items for itemized sales receipts. Used when the sales receipt includes product/service details with quantities and pricing. | | +| `tax_code` | *OptionalNullable[str]* | :heavy_minus_sign: | Applicable tax id/code override if tax is not supplied on a line item basis. | 1234 | +| `discount_percentage` | *OptionalNullable[float]* | :heavy_minus_sign: | Discount percentage applied to this sales receipt. | 5.5 | +| `discount_amount` | *OptionalNullable[float]* | :heavy_minus_sign: | Discount amount applied to this sales receipt. | 25 | +| `note` | *OptionalNullable[str]* | :heavy_minus_sign: | Optional note to be associated with the sales receipt. | Thank you for your purchase | +| `customer_memo` | *OptionalNullable[str]* | :heavy_minus_sign: | Customer memo | Thank you for your business and have a great day! | +| `reference` | *OptionalNullable[str]* | :heavy_minus_sign: | Optional reference message for the sales receipt. | REF-123456 | +| `billing_address` | [Optional[models.Address]](../models/address.md) | :heavy_minus_sign: | N/A | | +| `shipping_address` | [Optional[models.Address]](../models/address.md) | :heavy_minus_sign: | N/A | | +| `department` | [OptionalNullable[models.LinkedDepartment]](../models/linkeddepartment.md) | :heavy_minus_sign: | N/A | | +| `tracking_categories` | List[[Nullable[models.LinkedTrackingCategory]](../models/linkedtrackingcategory.md)] | :heavy_minus_sign: | A list of linked tracking categories. | | +| `custom_mappings` | Dict[str, *Any*] | :heavy_minus_sign: | When custom mappings are configured on the resource, the result is included here. | | +| `custom_fields` | List[[models.CustomField](../models/customfield.md)] | :heavy_minus_sign: | N/A | | +| `row_version` | *OptionalNullable[str]* | :heavy_minus_sign: | A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object. | 1-12345 | +| `updated_by` | *OptionalNullable[str]* | :heavy_minus_sign: | The user who last updated the object. | 12345 | +| `created_by` | *OptionalNullable[str]* | :heavy_minus_sign: | The user who created the object. | 12345 | +| `updated_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_minus_sign: | The date and time when the object was last updated. | 2020-09-30T07:43:32.000Z | +| `created_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_minus_sign: | The date and time when the object was created. | 2020-09-30T07:43:32.000Z | +| `pass_through` | List[[models.PassThroughBody](../models/passthroughbody.md)] | :heavy_minus_sign: | The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources. | | \ No newline at end of file diff --git a/docs/models/salesreceiptinput.md b/docs/models/salesreceiptinput.md new file mode 100644 index 00000000..78546bb8 --- /dev/null +++ b/docs/models/salesreceiptinput.md @@ -0,0 +1,34 @@ +# SalesReceiptInput + + +## Fields + +| Field | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `number` | *OptionalNullable[str]* | :heavy_minus_sign: | Reference number for the sales receipt. | SR-00001 | +| `customer` | [OptionalNullable[models.LinkedCustomerInput]](../models/linkedcustomerinput.md) | :heavy_minus_sign: | The customer this entity is linked to. | | +| `currency` | [OptionalNullable[models.Currency]](../models/currency.md) | :heavy_minus_sign: | Indicates the associated currency for an amount of money. Values correspond to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217). | USD | +| `currency_rate` | *OptionalNullable[float]* | :heavy_minus_sign: | Currency Exchange Rate at the time entity was recorded/generated. | 0.69 | +| `tax_inclusive` | *OptionalNullable[bool]* | :heavy_minus_sign: | Amounts are including tax | true | +| `sub_total` | *OptionalNullable[float]* | :heavy_minus_sign: | Subtotal amount, normally before tax. | 250 | +| `total_amount` | *Nullable[float]* | :heavy_check_mark: | The total amount of the transaction or record | 49.99 | +| `total_tax` | *OptionalNullable[float]* | :heavy_minus_sign: | Total tax amount applied to this transaction. | 25 | +| `transaction_date` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_minus_sign: | The date of the sales receipt transaction - YYYY-MM-DDThh:mm:ss.sTZD | 2021-05-01T12:00:00.000Z | +| `payment_method` | *OptionalNullable[str]* | :heavy_minus_sign: | Payment method used for the transaction, such as cash, credit card, bank transfer, or check | cash | +| `payment_method_reference` | *OptionalNullable[str]* | :heavy_minus_sign: | Optional reference message returned by payment method on processing | 123456 | +| `payment_method_id` | *OptionalNullable[str]* | :heavy_minus_sign: | A unique identifier for an object. | 12345 | +| `account` | [OptionalNullable[models.LinkedLedgerAccount]](../models/linkedledgeraccount.md) | :heavy_minus_sign: | N/A | | +| `line_items` | List[[models.InvoiceLineItemInput](../models/invoicelineiteminput.md)] | :heavy_minus_sign: | Line items for itemized sales receipts. Used when the sales receipt includes product/service details with quantities and pricing. | | +| `tax_code` | *OptionalNullable[str]* | :heavy_minus_sign: | Applicable tax id/code override if tax is not supplied on a line item basis. | 1234 | +| `discount_percentage` | *OptionalNullable[float]* | :heavy_minus_sign: | Discount percentage applied to this sales receipt. | 5.5 | +| `discount_amount` | *OptionalNullable[float]* | :heavy_minus_sign: | Discount amount applied to this sales receipt. | 25 | +| `note` | *OptionalNullable[str]* | :heavy_minus_sign: | Optional note to be associated with the sales receipt. | Thank you for your purchase | +| `customer_memo` | *OptionalNullable[str]* | :heavy_minus_sign: | Customer memo | Thank you for your business and have a great day! | +| `reference` | *OptionalNullable[str]* | :heavy_minus_sign: | Optional reference message for the sales receipt. | REF-123456 | +| `billing_address` | [Optional[models.Address]](../models/address.md) | :heavy_minus_sign: | N/A | | +| `shipping_address` | [Optional[models.Address]](../models/address.md) | :heavy_minus_sign: | N/A | | +| `department` | [OptionalNullable[models.LinkedDepartmentInput]](../models/linkeddepartmentinput.md) | :heavy_minus_sign: | N/A | | +| `tracking_categories` | List[[Nullable[models.LinkedTrackingCategory]](../models/linkedtrackingcategory.md)] | :heavy_minus_sign: | A list of linked tracking categories. | | +| `custom_fields` | List[[models.CustomField](../models/customfield.md)] | :heavy_minus_sign: | N/A | | +| `row_version` | *OptionalNullable[str]* | :heavy_minus_sign: | A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object. | 1-12345 | +| `pass_through` | List[[models.PassThroughBody](../models/passthroughbody.md)] | :heavy_minus_sign: | The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources. | | \ No newline at end of file diff --git a/docs/models/salesreceiptsfilter.md b/docs/models/salesreceiptsfilter.md new file mode 100644 index 00000000..cf11fa53 --- /dev/null +++ b/docs/models/salesreceiptsfilter.md @@ -0,0 +1,9 @@ +# SalesReceiptsFilter + + +## Fields + +| Field | Type | Required | Description | Example | +| -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | +| `updated_since` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_minus_sign: | N/A | 2020-09-30T07:43:32.000Z | +| `customer_id` | *Optional[str]* | :heavy_minus_sign: | Filter by customer id | 123abc | \ No newline at end of file diff --git a/docs/models/salesreceiptssort.md b/docs/models/salesreceiptssort.md new file mode 100644 index 00000000..3275d359 --- /dev/null +++ b/docs/models/salesreceiptssort.md @@ -0,0 +1,9 @@ +# SalesReceiptsSort + + +## Fields + +| Field | Type | Required | Description | Example | +| ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | +| `by` | [Optional[models.SalesReceiptsSortBy]](../models/salesreceiptssortby.md) | :heavy_minus_sign: | The field on which to sort the Sales Receipts. | updated_at | +| `direction` | [Optional[models.SortDirection]](../models/sortdirection.md) | :heavy_minus_sign: | The direction in which to sort the results | | \ No newline at end of file diff --git a/docs/models/salesreceiptssortby.md b/docs/models/salesreceiptssortby.md new file mode 100644 index 00000000..e9021ff9 --- /dev/null +++ b/docs/models/salesreceiptssortby.md @@ -0,0 +1,11 @@ +# SalesReceiptsSortBy + +The field on which to sort the Sales Receipts. + + +## Values + +| Name | Value | +| ------------ | ------------ | +| `UPDATED_AT` | updated_at | +| `CREATED_AT` | created_at | \ No newline at end of file diff --git a/docs/models/transactions.md b/docs/models/transactions.md index 9e86c87d..1c5d10aa 100644 --- a/docs/models/transactions.md +++ b/docs/models/transactions.md @@ -3,13 +3,14 @@ ## Fields -| Field | Type | Required | Description | Example | -| -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | -| `posted_date` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_check_mark: | The date of the transaction - YYYY:MM::DDThh:mm:ss.sTZD | 2025-01-15T12:00:00.000Z | -| `description` | *Optional[str]* | :heavy_minus_sign: | A description of the transaction. | Payment received from ACME Corp | -| `amount` | *float* | :heavy_check_mark: | The amount of the transaction. | 250 | -| `credit_or_debit` | [models.CreditOrDebit](../models/creditordebit.md) | :heavy_check_mark: | Whether the amount is a credit or debit. | debit | -| `source_transaction_id` | *str* | :heavy_check_mark: | The ID of the source transaction. | txn_987 | -| `counterparty` | *Optional[str]* | :heavy_minus_sign: | The counterparty of the transaction. | ACME Corp | -| `reference` | *Optional[str]* | :heavy_minus_sign: | The reference of the transaction. | INV-2025-01 | -| `transaction_type` | [Optional[models.BankFeedStatementTransactionType]](../models/bankfeedstatementtransactiontype.md) | :heavy_minus_sign: | Type of transaction. | payment | \ No newline at end of file +| Field | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `posted_date` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_check_mark: | The date of the transaction - YYYY:MM::DDThh:mm:ss.sTZD | 2025-01-15T12:00:00.000Z | +| `description` | *Optional[str]* | :heavy_minus_sign: | A description of the transaction. | Payment received from ACME Corp | +| `amount` | *float* | :heavy_check_mark: | The amount of the transaction. | 250 | +| `credit_or_debit` | [models.CreditOrDebit](../models/creditordebit.md) | :heavy_check_mark: | Whether the amount is a credit or debit. | debit | +| `source_transaction_id` | *str* | :heavy_check_mark: | The ID of the source transaction. | txn_987 | +| `counterparty` | *Optional[str]* | :heavy_minus_sign: | The counterparty of the transaction. | ACME Corp | +| `reference` | *Optional[str]* | :heavy_minus_sign: | The reference of the transaction. | INV-2025-01 | +| `transaction_type` | [Optional[models.BankFeedStatementTransactionType]](../models/bankfeedstatementtransactiontype.md) | :heavy_minus_sign: | Type of transaction. | payment | +| `merchant_category_code` | *OptionalNullable[str]* | :heavy_minus_sign: | The ISO 18245 merchant category code (MCC) classifying the merchant for this transaction, expected as a four-digit code such as `5812`. The format is not enforced by the API, matching the other bank identifier fields. | 5812 | \ No newline at end of file diff --git a/docs/models/updatepaymentmethodresponse.md b/docs/models/updatepaymentmethodresponse.md new file mode 100644 index 00000000..1da2ebe9 --- /dev/null +++ b/docs/models/updatepaymentmethodresponse.md @@ -0,0 +1,16 @@ +# UpdatePaymentMethodResponse + +Payment Methods + + +## Fields + +| Field | Type | Required | Description | Example | +| ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | +| `status_code` | *int* | :heavy_check_mark: | HTTP Response Status Code | 200 | +| `status` | *str* | :heavy_check_mark: | HTTP Response Status | OK | +| `service` | *str* | :heavy_check_mark: | Apideck ID of service provider | quickbooks | +| `resource` | *str* | :heavy_check_mark: | Unified API resource name | PaymentMethods | +| `operation` | *str* | :heavy_check_mark: | Operation performed | update | +| `data` | [models.UnifiedID](../models/unifiedid.md) | :heavy_check_mark: | A object containing a unique identifier for the resource that was created, updated, or deleted. | | +| `raw` | Dict[str, *Any*] | :heavy_minus_sign: | Raw response from the integration when raw=true query param is provided | | \ No newline at end of file diff --git a/docs/models/updatesalesreceiptresponse.md b/docs/models/updatesalesreceiptresponse.md new file mode 100644 index 00000000..0fe729ae --- /dev/null +++ b/docs/models/updatesalesreceiptresponse.md @@ -0,0 +1,16 @@ +# UpdateSalesReceiptResponse + +SalesReceipt updated + + +## Fields + +| Field | Type | Required | Description | Example | +| ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | +| `status_code` | *int* | :heavy_check_mark: | HTTP Response Status Code | 200 | +| `status` | *str* | :heavy_check_mark: | HTTP Response Status | OK | +| `service` | *str* | :heavy_check_mark: | Apideck ID of service provider | quickbooks | +| `resource` | *str* | :heavy_check_mark: | Unified API resource name | sales-receipts | +| `operation` | *str* | :heavy_check_mark: | Operation performed | update | +| `data` | [models.UnifiedID](../models/unifiedid.md) | :heavy_check_mark: | A object containing a unique identifier for the resource that was created, updated, or deleted. | | +| `raw` | Dict[str, *Any*] | :heavy_minus_sign: | Raw response from the integration when raw=true query param is provided | | \ No newline at end of file diff --git a/docs/sdks/attachments/README.md b/docs/sdks/attachments/README.md index 73837a1e..3cd291f2 100644 --- a/docs/sdks/attachments/README.md +++ b/docs/sdks/attachments/README.md @@ -264,7 +264,7 @@ with Apideck( api_key=os.getenv("APIDECK_API_KEY", ""), ) as apideck: - res = apideck.accounting.attachments.download(reference_type=apideck_unify.AttachmentReferenceType.INVOICE, reference_id="123456", id="", service_id="salesforce", company_id="12345", fields="id,updated_at") + res = apideck.accounting.attachments.download(reference_type=apideck_unify.AttachmentReferenceType.INVOICE, reference_id="123456", id="", service_id="salesforce", company_id="12345", fields="id,updated_at", follow_redirects=False) assert res.get_attachment_download_response is not None @@ -285,6 +285,7 @@ with Apideck( | `service_id` | *Optional[str]* | :heavy_minus_sign: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | salesforce | | `company_id` | *Optional[str]* | :heavy_minus_sign: | The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings. | 12345 | | `fields` | *OptionalNullable[str]* | :heavy_minus_sign: | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. | id,updated_at | +| `follow_redirects` | *Optional[bool]* | :heavy_minus_sign: | Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. | false | | `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | ### Response diff --git a/docs/sdks/bankfeedaccounts/README.md b/docs/sdks/bankfeedaccounts/README.md index e3e10366..c39d994e 100644 --- a/docs/sdks/bankfeedaccounts/README.md +++ b/docs/sdks/bankfeedaccounts/README.md @@ -89,7 +89,7 @@ with Apideck( api_key=os.getenv("APIDECK_API_KEY", ""), ) as apideck: - res = apideck.accounting.bank_feed_accounts.create(raw=False, service_id="salesforce", bank_account_type=apideck_unify.BankAccountType.BANK, source_account_id="src_456", target_account_id="tgt_789", target_account_name="Main Company Checking", target_account_number="NL91ABNA0417164300", currency=apideck_unify.Currency.USD, feed_status=apideck_unify.FeedStatus.PENDING, country="US", custom_fields=[ + res = apideck.accounting.bank_feed_accounts.create(raw=False, service_id="salesforce", bank_account_type=apideck_unify.BankAccountType.BANK, source_account_id="src_456", source_routing_number="021000021", source_account_number="123465", target_account_id="tgt_789", target_account_name="Main Company Checking", target_account_number="NL91ABNA0417164300", balance=25000, available_balance=24500, currency=apideck_unify.Currency.USD, feed_status=apideck_unify.FeedStatus.PENDING, country="US", custom_fields=[ { "id": "2389328923893298", "name": "employee_level", @@ -127,9 +127,13 @@ with Apideck( | `service_id` | *Optional[str]* | :heavy_minus_sign: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | salesforce | | `bank_account_type` | [Optional[models.BankAccountType]](../../models/bankaccounttype.md) | :heavy_minus_sign: | Type of the bank account. | bank | | `source_account_id` | *Optional[str]* | :heavy_minus_sign: | The source account's unique identifier. | src_456 | +| `source_routing_number` | *OptionalNullable[str]* | :heavy_minus_sign: | Bank routing number (US) | 021000021 | +| `source_account_number` | *OptionalNullable[str]* | :heavy_minus_sign: | The bank account number | 123465 | | `target_account_id` | *Optional[str]* | :heavy_minus_sign: | The target account's unique identifier in the accounting connector. | tgt_789 | | `target_account_name` | *Optional[str]* | :heavy_minus_sign: | Name associated with the target account. | Main Company Checking | | `target_account_number` | *Optional[str]* | :heavy_minus_sign: | Account number of the destination bank account. | NL91ABNA0417164300 | +| `balance` | *OptionalNullable[float]* | :heavy_minus_sign: | The current balance of the source bank account. | 25000 | +| `available_balance` | *OptionalNullable[float]* | :heavy_minus_sign: | The available balance of the source bank account (considering pending transactions and overdraft). | 24500 | | `currency` | [OptionalNullable[models.Currency]](../../models/currency.md) | :heavy_minus_sign: | Indicates the associated currency for an amount of money. Values correspond to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217). | USD | | `feed_status` | [Optional[models.FeedStatus]](../../models/feedstatus.md) | :heavy_minus_sign: | Current status of the bank feed. | pending | | `country` | *OptionalNullable[str]* | :heavy_minus_sign: | Country code according to ISO 3166-1 alpha-2. | US | @@ -225,7 +229,7 @@ with Apideck( api_key=os.getenv("APIDECK_API_KEY", ""), ) as apideck: - res = apideck.accounting.bank_feed_accounts.update(id="", service_id="salesforce", raw=False, bank_account_type=apideck_unify.BankAccountType.BANK, source_account_id="src_456", target_account_id="tgt_789", target_account_name="Main Company Checking", target_account_number="NL91ABNA0417164300", currency=apideck_unify.Currency.USD, feed_status=apideck_unify.FeedStatus.PENDING, country="US", custom_fields=[ + res = apideck.accounting.bank_feed_accounts.update(id="", service_id="salesforce", raw=False, bank_account_type=apideck_unify.BankAccountType.BANK, source_account_id="src_456", source_routing_number="021000021", source_account_number="123465", target_account_id="tgt_789", target_account_name="Main Company Checking", target_account_number="NL91ABNA0417164300", balance=25000, available_balance=24500, currency=apideck_unify.Currency.USD, feed_status=apideck_unify.FeedStatus.PENDING, country="US", custom_fields=[ { "id": "2389328923893298", "name": "employee_level", @@ -258,9 +262,13 @@ with Apideck( | `raw` | *Optional[bool]* | :heavy_minus_sign: | Include raw response. Mostly used for debugging purposes | | | `bank_account_type` | [Optional[models.BankAccountType]](../../models/bankaccounttype.md) | :heavy_minus_sign: | Type of the bank account. | bank | | `source_account_id` | *Optional[str]* | :heavy_minus_sign: | The source account's unique identifier. | src_456 | +| `source_routing_number` | *OptionalNullable[str]* | :heavy_minus_sign: | Bank routing number (US) | 021000021 | +| `source_account_number` | *OptionalNullable[str]* | :heavy_minus_sign: | The bank account number | 123465 | | `target_account_id` | *Optional[str]* | :heavy_minus_sign: | The target account's unique identifier in the accounting connector. | tgt_789 | | `target_account_name` | *Optional[str]* | :heavy_minus_sign: | Name associated with the target account. | Main Company Checking | | `target_account_number` | *Optional[str]* | :heavy_minus_sign: | Account number of the destination bank account. | NL91ABNA0417164300 | +| `balance` | *OptionalNullable[float]* | :heavy_minus_sign: | The current balance of the source bank account. | 25000 | +| `available_balance` | *OptionalNullable[float]* | :heavy_minus_sign: | The available balance of the source bank account (considering pending transactions and overdraft). | 24500 | | `currency` | [OptionalNullable[models.Currency]](../../models/currency.md) | :heavy_minus_sign: | Indicates the associated currency for an amount of money. Values correspond to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217). | USD | | `feed_status` | [Optional[models.FeedStatus]](../../models/feedstatus.md) | :heavy_minus_sign: | Current status of the bank feed. | pending | | `country` | *OptionalNullable[str]* | :heavy_minus_sign: | Country code according to ISO 3166-1 alpha-2. | US | diff --git a/docs/sdks/files/README.md b/docs/sdks/files/README.md index faf833aa..0b1dc2ac 100644 --- a/docs/sdks/files/README.md +++ b/docs/sdks/files/README.md @@ -357,7 +357,7 @@ with Apideck( api_key=os.getenv("APIDECK_API_KEY", ""), ) as apideck: - res = apideck.file_storage.files.download(id="", service_id="salesforce", fields="id,updated_at") + res = apideck.file_storage.files.download(id="", service_id="salesforce", fields="id,updated_at", follow_redirects=False) assert res.get_file_download_response is not None @@ -375,6 +375,7 @@ with Apideck( | `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | | `service_id` | *Optional[str]* | :heavy_minus_sign: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | salesforce | | `fields` | *OptionalNullable[str]* | :heavy_minus_sign: | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. | id,updated_at | +| `follow_redirects` | *Optional[bool]* | :heavy_minus_sign: | Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. | false | | `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | ### Response diff --git a/docs/sdks/paymentmethods/README.md b/docs/sdks/paymentmethods/README.md new file mode 100644 index 00000000..7e143a04 --- /dev/null +++ b/docs/sdks/paymentmethods/README.md @@ -0,0 +1,322 @@ +# PaymentMethods +(*accounting.payment_methods*) + +## Overview + +### Available Operations + +* [list](#list) - List Payment Methods +* [create](#create) - Create Payment Method +* [get](#get) - Get Payment Method +* [update](#update) - Update Payment Method +* [delete](#delete) - Delete Payment Method + +## list + +List Payment Methods + +### Example Usage + + +```python +from apideck_unify import Apideck +import os + + +with Apideck( + consumer_id="test-consumer", + app_id="dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX", + api_key=os.getenv("APIDECK_API_KEY", ""), +) as apideck: + + res = apideck.accounting.payment_methods.list(raw=False, service_id="salesforce", limit=20, fields="id,updated_at", pass_through={ + "search": "San Francisco", + }) + + while res is not None: + # Handle items + + res = res.next() + +``` + +### Parameters + +| Parameter | Type | Required | Description | Example | +| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `raw` | *Optional[bool]* | :heavy_minus_sign: | Include raw response. Mostly used for debugging purposes | | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *Optional[str]* | :heavy_minus_sign: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | salesforce | +| `cursor` | *OptionalNullable[str]* | :heavy_minus_sign: | Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. | | +| `limit` | *Optional[int]* | :heavy_minus_sign: | Number of results to return. Minimum 1, Maximum 200, Default 20 | | +| `fields` | *OptionalNullable[str]* | :heavy_minus_sign: | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. | id,updated_at | +| `pass_through` | Dict[str, *Any*] | :heavy_minus_sign: | Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads | {
"search": "San Francisco"
} | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | + +### Response + +**[models.AccountingPaymentMethodsAllResponse](../../models/accountingpaymentmethodsallresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| ------------------------------ | ------------------------------ | ------------------------------ | +| models.BadRequestResponse | 400 | application/json | +| models.UnauthorizedResponse | 401 | application/json | +| models.PaymentRequiredResponse | 402 | application/json | +| models.NotFoundResponse | 404 | application/json | +| models.UnprocessableResponse | 422 | application/json | +| models.APIError | 4XX, 5XX | \*/\* | + +## create + +Create Payment Method + +### Example Usage + + +```python +import apideck_unify +from apideck_unify import Apideck +import os + + +with Apideck( + consumer_id="test-consumer", + app_id="dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX", + api_key=os.getenv("APIDECK_API_KEY", ""), +) as apideck: + + res = apideck.accounting.payment_methods.create(raw=False, service_id="salesforce", name="Cash", type_=apideck_unify.AccountingPaymentMethodType.CASH, status=apideck_unify.AccountingPaymentMethodStatus.ACTIVE, row_version="1-12345", pass_through=[ + { + "service_id": "", + "extend_paths": [ + { + "path": "$.nested.property", + "value": { + "TaxClassificationRef": { + "value": "EUC-99990201-V1-00020000", + }, + }, + }, + ], + }, + ]) + + assert res.create_payment_method_response is not None + + # Handle response + print(res.create_payment_method_response) + +``` + +### Parameters + +| Parameter | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `raw` | *Optional[bool]* | :heavy_minus_sign: | Include raw response. Mostly used for debugging purposes | | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *Optional[str]* | :heavy_minus_sign: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | salesforce | +| `name` | *Optional[str]* | :heavy_minus_sign: | The name of the payment method. | Cash | +| `type` | [OptionalNullable[models.AccountingPaymentMethodType]](../../models/accountingpaymentmethodtype.md) | :heavy_minus_sign: | The type of payment method. | cash | +| `status` | [OptionalNullable[models.AccountingPaymentMethodStatus]](../../models/accountingpaymentmethodstatus.md) | :heavy_minus_sign: | The status of the payment method. | active | +| `row_version` | *OptionalNullable[str]* | :heavy_minus_sign: | A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object. | 1-12345 | +| `pass_through` | List[[models.PassThroughBody](../../models/passthroughbody.md)] | :heavy_minus_sign: | The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources. | | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | + +### Response + +**[models.AccountingPaymentMethodsAddResponse](../../models/accountingpaymentmethodsaddresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| ------------------------------ | ------------------------------ | ------------------------------ | +| models.BadRequestResponse | 400 | application/json | +| models.UnauthorizedResponse | 401 | application/json | +| models.PaymentRequiredResponse | 402 | application/json | +| models.NotFoundResponse | 404 | application/json | +| models.UnprocessableResponse | 422 | application/json | +| models.APIError | 4XX, 5XX | \*/\* | + +## get + +Get Payment Method + +### Example Usage + + +```python +from apideck_unify import Apideck +import os + + +with Apideck( + consumer_id="test-consumer", + app_id="dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX", + api_key=os.getenv("APIDECK_API_KEY", ""), +) as apideck: + + res = apideck.accounting.payment_methods.get(id="", service_id="salesforce", raw=False, fields="id,updated_at") + + assert res.get_payment_method_response is not None + + # Handle response + print(res.get_payment_method_response) + +``` + +### Parameters + +| Parameter | Type | Required | Description | Example | +| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `id` | *str* | :heavy_check_mark: | ID of the record you are acting upon. | | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *Optional[str]* | :heavy_minus_sign: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | salesforce | +| `raw` | *Optional[bool]* | :heavy_minus_sign: | Include raw response. Mostly used for debugging purposes | | +| `fields` | *OptionalNullable[str]* | :heavy_minus_sign: | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. | id,updated_at | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | + +### Response + +**[models.AccountingPaymentMethodsOneResponse](../../models/accountingpaymentmethodsoneresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| ------------------------------ | ------------------------------ | ------------------------------ | +| models.BadRequestResponse | 400 | application/json | +| models.UnauthorizedResponse | 401 | application/json | +| models.PaymentRequiredResponse | 402 | application/json | +| models.NotFoundResponse | 404 | application/json | +| models.UnprocessableResponse | 422 | application/json | +| models.APIError | 4XX, 5XX | \*/\* | + +## update + +Update Payment Method + +### Example Usage + + +```python +import apideck_unify +from apideck_unify import Apideck +import os + + +with Apideck( + consumer_id="test-consumer", + app_id="dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX", + api_key=os.getenv("APIDECK_API_KEY", ""), +) as apideck: + + res = apideck.accounting.payment_methods.update(id="", service_id="salesforce", raw=False, name="Cash", type_=apideck_unify.AccountingPaymentMethodType.CASH, status=apideck_unify.AccountingPaymentMethodStatus.ACTIVE, row_version="1-12345", pass_through=[ + { + "service_id": "", + "extend_paths": [ + { + "path": "$.nested.property", + "value": { + "TaxClassificationRef": { + "value": "EUC-99990201-V1-00020000", + }, + }, + }, + ], + }, + ]) + + assert res.update_payment_method_response is not None + + # Handle response + print(res.update_payment_method_response) + +``` + +### Parameters + +| Parameter | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `id` | *str* | :heavy_check_mark: | ID of the record you are acting upon. | | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *Optional[str]* | :heavy_minus_sign: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | salesforce | +| `raw` | *Optional[bool]* | :heavy_minus_sign: | Include raw response. Mostly used for debugging purposes | | +| `name` | *Optional[str]* | :heavy_minus_sign: | The name of the payment method. | Cash | +| `type` | [OptionalNullable[models.AccountingPaymentMethodType]](../../models/accountingpaymentmethodtype.md) | :heavy_minus_sign: | The type of payment method. | cash | +| `status` | [OptionalNullable[models.AccountingPaymentMethodStatus]](../../models/accountingpaymentmethodstatus.md) | :heavy_minus_sign: | The status of the payment method. | active | +| `row_version` | *OptionalNullable[str]* | :heavy_minus_sign: | A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object. | 1-12345 | +| `pass_through` | List[[models.PassThroughBody](../../models/passthroughbody.md)] | :heavy_minus_sign: | The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources. | | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | + +### Response + +**[models.AccountingPaymentMethodsUpdateResponse](../../models/accountingpaymentmethodsupdateresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| ------------------------------ | ------------------------------ | ------------------------------ | +| models.BadRequestResponse | 400 | application/json | +| models.UnauthorizedResponse | 401 | application/json | +| models.PaymentRequiredResponse | 402 | application/json | +| models.NotFoundResponse | 404 | application/json | +| models.UnprocessableResponse | 422 | application/json | +| models.APIError | 4XX, 5XX | \*/\* | + +## delete + +Delete Payment Method + +### Example Usage + + +```python +from apideck_unify import Apideck +import os + + +with Apideck( + consumer_id="test-consumer", + app_id="dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX", + api_key=os.getenv("APIDECK_API_KEY", ""), +) as apideck: + + res = apideck.accounting.payment_methods.delete(id="", service_id="salesforce", raw=False) + + assert res.delete_payment_method_response is not None + + # Handle response + print(res.delete_payment_method_response) + +``` + +### Parameters + +| Parameter | Type | Required | Description | Example | +| --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- | +| `id` | *str* | :heavy_check_mark: | ID of the record you are acting upon. | | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *Optional[str]* | :heavy_minus_sign: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | salesforce | +| `raw` | *Optional[bool]* | :heavy_minus_sign: | Include raw response. Mostly used for debugging purposes | | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | + +### Response + +**[models.AccountingPaymentMethodsDeleteResponse](../../models/accountingpaymentmethodsdeleteresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| ------------------------------ | ------------------------------ | ------------------------------ | +| models.BadRequestResponse | 400 | application/json | +| models.UnauthorizedResponse | 401 | application/json | +| models.PaymentRequiredResponse | 402 | application/json | +| models.NotFoundResponse | 404 | application/json | +| models.UnprocessableResponse | 422 | application/json | +| models.APIError | 4XX, 5XX | \*/\* | \ No newline at end of file diff --git a/docs/sdks/proxy/README.md b/docs/sdks/proxy/README.md index 5fa9d25a..b9e81f21 100644 --- a/docs/sdks/proxy/README.md +++ b/docs/sdks/proxy/README.md @@ -32,7 +32,7 @@ with Apideck( api_key=os.getenv("APIDECK_API_KEY", ""), ) as apideck: - res = apideck.proxy.get(service_id="close", downstream_url="https://api.close.com/api/v1/lead", unified_api="hris", downstream_authorization="Bearer ", timeout=30000) + res = apideck.proxy.get(service_id="close", downstream_url="https://api.close.com/api/v1/lead", unified_api="hris", downstream_authorization="Bearer ", timeout=30000, follow_redirects=False) assert res.response_json is not None @@ -43,16 +43,17 @@ with Apideck( ### Parameters -| Parameter | Type | Required | Description | Example | -| --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `service_id` | *str* | :heavy_check_mark: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | close | -| `downstream_url` | *str* | :heavy_check_mark: | Downstream URL | https://api.close.com/api/v1/lead | -| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | -| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | -| `unified_api` | *Optional[str]* | :heavy_minus_sign: | Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. | hris | -| `downstream_authorization` | *Optional[str]* | :heavy_minus_sign: | Downstream authorization header. This will skip the Vault token injection. | Bearer | -| `timeout` | *Optional[int]* | :heavy_minus_sign: | Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). | 30000 | -| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | +| Parameter | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `service_id` | *str* | :heavy_check_mark: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | close | +| `downstream_url` | *str* | :heavy_check_mark: | Downstream URL | https://api.close.com/api/v1/lead | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `unified_api` | *Optional[str]* | :heavy_minus_sign: | Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. | hris | +| `downstream_authorization` | *Optional[str]* | :heavy_minus_sign: | Downstream authorization header. This will skip the Vault token injection. | Bearer | +| `timeout` | *Optional[int]* | :heavy_minus_sign: | Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). | 30000 | +| `follow_redirects` | *Optional[bool]* | :heavy_minus_sign: | Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. | false | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | ### Response @@ -85,7 +86,7 @@ with Apideck( api_key=os.getenv("APIDECK_API_KEY", ""), ) as apideck: - res = apideck.proxy.options(service_id="close", downstream_url="https://api.close.com/api/v1/lead", unified_api="hris", downstream_authorization="Bearer ", timeout=30000) + res = apideck.proxy.options(service_id="close", downstream_url="https://api.close.com/api/v1/lead", unified_api="hris", downstream_authorization="Bearer ", timeout=30000, follow_redirects=False) assert res.response_json is not None @@ -96,16 +97,17 @@ with Apideck( ### Parameters -| Parameter | Type | Required | Description | Example | -| --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `service_id` | *str* | :heavy_check_mark: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | close | -| `downstream_url` | *str* | :heavy_check_mark: | Downstream URL | https://api.close.com/api/v1/lead | -| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | -| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | -| `unified_api` | *Optional[str]* | :heavy_minus_sign: | Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. | hris | -| `downstream_authorization` | *Optional[str]* | :heavy_minus_sign: | Downstream authorization header. This will skip the Vault token injection. | Bearer | -| `timeout` | *Optional[int]* | :heavy_minus_sign: | Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). | 30000 | -| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | +| Parameter | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `service_id` | *str* | :heavy_check_mark: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | close | +| `downstream_url` | *str* | :heavy_check_mark: | Downstream URL | https://api.close.com/api/v1/lead | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `unified_api` | *Optional[str]* | :heavy_minus_sign: | Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. | hris | +| `downstream_authorization` | *Optional[str]* | :heavy_minus_sign: | Downstream authorization header. This will skip the Vault token injection. | Bearer | +| `timeout` | *Optional[int]* | :heavy_minus_sign: | Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). | 30000 | +| `follow_redirects` | *Optional[bool]* | :heavy_minus_sign: | Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. | false | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | ### Response @@ -138,7 +140,7 @@ with Apideck( api_key=os.getenv("APIDECK_API_KEY", ""), ) as apideck: - res = apideck.proxy.post(service_id="close", downstream_url="https://api.close.com/api/v1/lead", unified_api="hris", downstream_authorization="Bearer ", timeout=30000) + res = apideck.proxy.post(service_id="close", downstream_url="https://api.close.com/api/v1/lead", unified_api="hris", downstream_authorization="Bearer ", timeout=30000, follow_redirects=False) assert res.response_json is not None @@ -149,17 +151,18 @@ with Apideck( ### Parameters -| Parameter | Type | Required | Description | Example | -| --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `service_id` | *str* | :heavy_check_mark: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | close | -| `downstream_url` | *str* | :heavy_check_mark: | Downstream URL | https://api.close.com/api/v1/lead | -| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | -| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | -| `unified_api` | *Optional[str]* | :heavy_minus_sign: | Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. | hris | -| `downstream_authorization` | *Optional[str]* | :heavy_minus_sign: | Downstream authorization header. This will skip the Vault token injection. | Bearer | -| `timeout` | *Optional[int]* | :heavy_minus_sign: | Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). | 30000 | -| `request_body` | *Optional[Union[bytes, IO[bytes], io.BufferedReader]]* | :heavy_minus_sign: | Depending on the verb/method of the request this will contain the request body you want to POST/PATCH/PUT. | | -| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | +| Parameter | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `service_id` | *str* | :heavy_check_mark: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | close | +| `downstream_url` | *str* | :heavy_check_mark: | Downstream URL | https://api.close.com/api/v1/lead | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `unified_api` | *Optional[str]* | :heavy_minus_sign: | Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. | hris | +| `downstream_authorization` | *Optional[str]* | :heavy_minus_sign: | Downstream authorization header. This will skip the Vault token injection. | Bearer | +| `timeout` | *Optional[int]* | :heavy_minus_sign: | Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). | 30000 | +| `follow_redirects` | *Optional[bool]* | :heavy_minus_sign: | Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. | false | +| `request_body` | *Optional[Union[bytes, IO[bytes], io.BufferedReader]]* | :heavy_minus_sign: | Depending on the verb/method of the request this will contain the request body you want to POST/PATCH/PUT. | | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | ### Response @@ -192,7 +195,7 @@ with Apideck( api_key=os.getenv("APIDECK_API_KEY", ""), ) as apideck: - res = apideck.proxy.put(service_id="close", downstream_url="https://api.close.com/api/v1/lead", unified_api="hris", downstream_authorization="Bearer ", timeout=30000) + res = apideck.proxy.put(service_id="close", downstream_url="https://api.close.com/api/v1/lead", unified_api="hris", downstream_authorization="Bearer ", timeout=30000, follow_redirects=False) assert res.response_json is not None @@ -203,17 +206,18 @@ with Apideck( ### Parameters -| Parameter | Type | Required | Description | Example | -| --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `service_id` | *str* | :heavy_check_mark: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | close | -| `downstream_url` | *str* | :heavy_check_mark: | Downstream URL | https://api.close.com/api/v1/lead | -| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | -| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | -| `unified_api` | *Optional[str]* | :heavy_minus_sign: | Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. | hris | -| `downstream_authorization` | *Optional[str]* | :heavy_minus_sign: | Downstream authorization header. This will skip the Vault token injection. | Bearer | -| `timeout` | *Optional[int]* | :heavy_minus_sign: | Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). | 30000 | -| `request_body` | *Optional[Union[bytes, IO[bytes], io.BufferedReader]]* | :heavy_minus_sign: | Depending on the verb/method of the request this will contain the request body you want to POST/PATCH/PUT. | | -| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | +| Parameter | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `service_id` | *str* | :heavy_check_mark: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | close | +| `downstream_url` | *str* | :heavy_check_mark: | Downstream URL | https://api.close.com/api/v1/lead | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `unified_api` | *Optional[str]* | :heavy_minus_sign: | Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. | hris | +| `downstream_authorization` | *Optional[str]* | :heavy_minus_sign: | Downstream authorization header. This will skip the Vault token injection. | Bearer | +| `timeout` | *Optional[int]* | :heavy_minus_sign: | Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). | 30000 | +| `follow_redirects` | *Optional[bool]* | :heavy_minus_sign: | Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. | false | +| `request_body` | *Optional[Union[bytes, IO[bytes], io.BufferedReader]]* | :heavy_minus_sign: | Depending on the verb/method of the request this will contain the request body you want to POST/PATCH/PUT. | | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | ### Response @@ -246,7 +250,7 @@ with Apideck( api_key=os.getenv("APIDECK_API_KEY", ""), ) as apideck: - res = apideck.proxy.patch(service_id="close", downstream_url="https://api.close.com/api/v1/lead", unified_api="hris", downstream_authorization="Bearer ", timeout=30000) + res = apideck.proxy.patch(service_id="close", downstream_url="https://api.close.com/api/v1/lead", unified_api="hris", downstream_authorization="Bearer ", timeout=30000, follow_redirects=False) assert res.response_json is not None @@ -257,17 +261,18 @@ with Apideck( ### Parameters -| Parameter | Type | Required | Description | Example | -| --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `service_id` | *str* | :heavy_check_mark: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | close | -| `downstream_url` | *str* | :heavy_check_mark: | Downstream URL | https://api.close.com/api/v1/lead | -| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | -| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | -| `unified_api` | *Optional[str]* | :heavy_minus_sign: | Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. | hris | -| `downstream_authorization` | *Optional[str]* | :heavy_minus_sign: | Downstream authorization header. This will skip the Vault token injection. | Bearer | -| `timeout` | *Optional[int]* | :heavy_minus_sign: | Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). | 30000 | -| `request_body` | *Optional[Union[bytes, IO[bytes], io.BufferedReader]]* | :heavy_minus_sign: | Depending on the verb/method of the request this will contain the request body you want to POST/PATCH/PUT. | | -| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | +| Parameter | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `service_id` | *str* | :heavy_check_mark: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | close | +| `downstream_url` | *str* | :heavy_check_mark: | Downstream URL | https://api.close.com/api/v1/lead | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `unified_api` | *Optional[str]* | :heavy_minus_sign: | Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. | hris | +| `downstream_authorization` | *Optional[str]* | :heavy_minus_sign: | Downstream authorization header. This will skip the Vault token injection. | Bearer | +| `timeout` | *Optional[int]* | :heavy_minus_sign: | Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). | 30000 | +| `follow_redirects` | *Optional[bool]* | :heavy_minus_sign: | Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. | false | +| `request_body` | *Optional[Union[bytes, IO[bytes], io.BufferedReader]]* | :heavy_minus_sign: | Depending on the verb/method of the request this will contain the request body you want to POST/PATCH/PUT. | | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | ### Response @@ -300,7 +305,7 @@ with Apideck( api_key=os.getenv("APIDECK_API_KEY", ""), ) as apideck: - res = apideck.proxy.delete(service_id="close", downstream_url="https://api.close.com/api/v1/lead", unified_api="hris", downstream_authorization="Bearer ", timeout=30000) + res = apideck.proxy.delete(service_id="close", downstream_url="https://api.close.com/api/v1/lead", unified_api="hris", downstream_authorization="Bearer ", timeout=30000, follow_redirects=False) assert res.response_json is not None @@ -311,16 +316,17 @@ with Apideck( ### Parameters -| Parameter | Type | Required | Description | Example | -| --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `service_id` | *str* | :heavy_check_mark: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | close | -| `downstream_url` | *str* | :heavy_check_mark: | Downstream URL | https://api.close.com/api/v1/lead | -| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | -| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | -| `unified_api` | *Optional[str]* | :heavy_minus_sign: | Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. | hris | -| `downstream_authorization` | *Optional[str]* | :heavy_minus_sign: | Downstream authorization header. This will skip the Vault token injection. | Bearer | -| `timeout` | *Optional[int]* | :heavy_minus_sign: | Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). | 30000 | -| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | +| Parameter | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `service_id` | *str* | :heavy_check_mark: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | close | +| `downstream_url` | *str* | :heavy_check_mark: | Downstream URL | https://api.close.com/api/v1/lead | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `unified_api` | *Optional[str]* | :heavy_minus_sign: | Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. | hris | +| `downstream_authorization` | *Optional[str]* | :heavy_minus_sign: | Downstream authorization header. This will skip the Vault token injection. | Bearer | +| `timeout` | *Optional[int]* | :heavy_minus_sign: | Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). | 30000 | +| `follow_redirects` | *Optional[bool]* | :heavy_minus_sign: | Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. | false | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | ### Response diff --git a/docs/sdks/salesreceipts/README.md b/docs/sdks/salesreceipts/README.md new file mode 100644 index 00000000..4be03e95 --- /dev/null +++ b/docs/sdks/salesreceipts/README.md @@ -0,0 +1,689 @@ +# SalesReceipts +(*accounting.sales_receipts*) + +## Overview + +### Available Operations + +* [list](#list) - List Sales Receipts +* [create](#create) - Create Sales Receipt +* [get](#get) - Get Sales Receipt +* [update](#update) - Update Sales Receipt +* [delete](#delete) - Delete Sales Receipt + +## list + +List Sales Receipts + +### Example Usage + + +```python +import apideck_unify +from apideck_unify import Apideck +from apideck_unify.utils import parse_datetime +import os + + +with Apideck( + consumer_id="test-consumer", + app_id="dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX", + api_key=os.getenv("APIDECK_API_KEY", ""), +) as apideck: + + res = apideck.accounting.sales_receipts.list(raw=False, service_id="salesforce", company_id="12345", limit=20, filter_={ + "updated_since": parse_datetime("2020-09-30T07:43:32.000Z"), + "customer_id": "123abc", + }, sort={ + "by": apideck_unify.SalesReceiptsSortBy.UPDATED_AT, + "direction": apideck_unify.SortDirection.DESC, + }, pass_through={ + "search": "San Francisco", + }, fields="id,updated_at") + + while res is not None: + # Handle items + + res = res.next() + +``` + +### Parameters + +| Parameter | Type | Required | Description | Example | +| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `raw` | *Optional[bool]* | :heavy_minus_sign: | Include raw response. Mostly used for debugging purposes | | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *Optional[str]* | :heavy_minus_sign: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | salesforce | +| `company_id` | *Optional[str]* | :heavy_minus_sign: | The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings. | 12345 | +| `cursor` | *OptionalNullable[str]* | :heavy_minus_sign: | Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. | | +| `limit` | *Optional[int]* | :heavy_minus_sign: | Number of results to return. Minimum 1, Maximum 200, Default 20 | | +| `filter_` | [Optional[models.SalesReceiptsFilter]](../../models/salesreceiptsfilter.md) | :heavy_minus_sign: | Apply filters | {
"updated_since": "2020-09-30T07:43:32.000Z",
"customer_id": "123abc"
} | +| `sort` | [Optional[models.SalesReceiptsSort]](../../models/salesreceiptssort.md) | :heavy_minus_sign: | Apply sorting | {
"by": "updated_at",
"direction": "desc"
} | +| `pass_through` | Dict[str, *Any*] | :heavy_minus_sign: | Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads | {
"search": "San Francisco"
} | +| `fields` | *OptionalNullable[str]* | :heavy_minus_sign: | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. | id,updated_at | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | + +### Response + +**[models.AccountingSalesReceiptsAllResponse](../../models/accountingsalesreceiptsallresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| ------------------------------ | ------------------------------ | ------------------------------ | +| models.BadRequestResponse | 400 | application/json | +| models.UnauthorizedResponse | 401 | application/json | +| models.PaymentRequiredResponse | 402 | application/json | +| models.NotFoundResponse | 404 | application/json | +| models.UnprocessableResponse | 422 | application/json | +| models.APIError | 4XX, 5XX | \*/\* | + +## create + +Create Sales Receipt + +### Example Usage + + +```python +import apideck_unify +from apideck_unify import Apideck +from apideck_unify.utils import parse_datetime +from datetime import date +import os + + +with Apideck( + consumer_id="test-consumer", + app_id="dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX", + api_key=os.getenv("APIDECK_API_KEY", ""), +) as apideck: + + res = apideck.accounting.sales_receipts.create(total_amount=49.99, raw=False, service_id="salesforce", company_id="12345", number="SR-00001", customer={ + "id": "12345", + "display_name": "Windsurf Shop", + "email": "boring@boring.com", + }, currency=apideck_unify.Currency.USD, currency_rate=0.69, tax_inclusive=True, sub_total=250, total_tax=25, transaction_date=parse_datetime("2021-05-01T12:00:00.000Z"), payment_method="cash", payment_method_reference="123456", payment_method_id="12345", account={ + "id": "123456", + "name": "Bank account", + "nominal_code": "N091", + "code": "453", + "parent_id": "123456", + "display_id": "123456", + }, line_items=[ + { + "id": "12345", + "row_id": "12345", + "code": "120-C", + "line_number": 1, + "description": "Model Y is a fully electric, mid-size SUV, with seating for up to seven, dual motor AWD and unparalleled protection.", + "type": apideck_unify.InvoiceLineItemType.SALES_ITEM, + "tax_amount": 27500, + "total_amount": 27500, + "quantity": 1, + "unit_price": 27500.5, + "unit_of_measure": "pc.", + "discount_percentage": 0.01, + "discount_amount": 19.99, + "service_date": date.fromisoformat("2024-01-15"), + "category_id": "12345", + "location_id": "12345", + "department_id": "12345", + "subsidiary_id": "12345", + "shipping_id": "12345", + "memo": "Some memo", + "prepaid": True, + "item": { + "id": "12344", + "code": "120-C", + "name": "Model Y", + }, + "tax_applicable_on": "Domestic_Purchase_of_Goods_and_Services", + "tax_recoverability": "Fully_Recoverable", + "tax_method": "Due_to_Supplier", + "worktags": [ + { + "id": "123456", + "value": "New York", + }, + ], + "tax_rate": { + "id": "123456", + "code": "N-T", + "rate": 10, + }, + "tracking_categories": [ + { + "id": "123456", + "code": "100", + "name": "New York", + "parent_id": "123456", + "parent_name": "New York", + }, + ], + "ledger_account": { + "id": "123456", + "name": "Bank account", + "nominal_code": "N091", + "code": "453", + "parent_id": "123456", + "display_id": "123456", + }, + "custom_fields": [ + { + "id": "2389328923893298", + "name": "employee_level", + "ref_name": "Marketing", + "description": "Employee Level", + "value": "Uses Salesforce and Marketo", + }, + ], + "row_version": "1-12345", + }, + ], tax_code="1234", discount_percentage=5.5, discount_amount=25, note="Thank you for your purchase", customer_memo="Thank you for your business and have a great day!", reference="REF-123456", billing_address={ + "id": "123", + "type": apideck_unify.Type.PRIMARY, + "string": "25 Spring Street, Blackburn, VIC 3130", + "name": "HQ US", + "line1": "Main street", + "line2": "apt #", + "line3": "Suite #", + "line4": "delivery instructions", + "line5": "Attention: Finance Dept", + "street_number": "25", + "city": "San Francisco", + "state": "CA", + "postal_code": "94104", + "country": "US", + "latitude": "40.759211", + "longitude": "-73.984638", + "county": "Santa Clara", + "contact_name": "Elon Musk", + "salutation": "Mr", + "phone_number": "111-111-1111", + "fax": "122-111-1111", + "email": "elon@musk.com", + "website": "https://elonmusk.com", + "notes": "Address notes or delivery instructions.", + "row_version": "1-12345", + }, shipping_address={ + "id": "123", + "type": apideck_unify.Type.PRIMARY, + "string": "25 Spring Street, Blackburn, VIC 3130", + "name": "HQ US", + "line1": "Main street", + "line2": "apt #", + "line3": "Suite #", + "line4": "delivery instructions", + "line5": "Attention: Finance Dept", + "street_number": "25", + "city": "San Francisco", + "state": "CA", + "postal_code": "94104", + "country": "US", + "latitude": "40.759211", + "longitude": "-73.984638", + "county": "Santa Clara", + "contact_name": "Elon Musk", + "salutation": "Mr", + "phone_number": "111-111-1111", + "fax": "122-111-1111", + "email": "elon@musk.com", + "website": "https://elonmusk.com", + "notes": "Address notes or delivery instructions.", + "row_version": "1-12345", + }, department={ + "display_id": "123456", + "name": "Acme Inc.", + }, tracking_categories=[ + { + "id": "123456", + "code": "100", + "name": "New York", + "parent_id": "123456", + "parent_name": "New York", + }, + ], custom_fields=[ + { + "id": "2389328923893298", + "name": "employee_level", + "ref_name": "Marketing", + "description": "Employee Level", + "value": "Uses Salesforce and Marketo", + }, + ], row_version="1-12345", pass_through=[ + { + "service_id": "", + "extend_paths": [ + { + "path": "$.nested.property", + "value": { + "TaxClassificationRef": { + "value": "EUC-99990201-V1-00020000", + }, + }, + }, + ], + }, + ]) + + assert res.create_sales_receipt_response is not None + + # Handle response + print(res.create_sales_receipt_response) + +``` + +### Parameters + +| Parameter | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | +| `total_amount` | *Nullable[float]* | :heavy_check_mark: | The total amount of the transaction or record | 49.99 | +| `raw` | *Optional[bool]* | :heavy_minus_sign: | Include raw response. Mostly used for debugging purposes | | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *Optional[str]* | :heavy_minus_sign: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | salesforce | +| `company_id` | *Optional[str]* | :heavy_minus_sign: | The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings. | 12345 | +| `number` | *OptionalNullable[str]* | :heavy_minus_sign: | Reference number for the sales receipt. | SR-00001 | +| `customer` | [OptionalNullable[models.LinkedCustomerInput]](../../models/linkedcustomerinput.md) | :heavy_minus_sign: | The customer this entity is linked to. | | +| `currency` | [OptionalNullable[models.Currency]](../../models/currency.md) | :heavy_minus_sign: | Indicates the associated currency for an amount of money. Values correspond to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217). | USD | +| `currency_rate` | *OptionalNullable[float]* | :heavy_minus_sign: | Currency Exchange Rate at the time entity was recorded/generated. | 0.69 | +| `tax_inclusive` | *OptionalNullable[bool]* | :heavy_minus_sign: | Amounts are including tax | true | +| `sub_total` | *OptionalNullable[float]* | :heavy_minus_sign: | Subtotal amount, normally before tax. | 250 | +| `total_tax` | *OptionalNullable[float]* | :heavy_minus_sign: | Total tax amount applied to this transaction. | 25 | +| `transaction_date` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_minus_sign: | The date of the sales receipt transaction - YYYY-MM-DDThh:mm:ss.sTZD | 2021-05-01T12:00:00.000Z | +| `payment_method` | *OptionalNullable[str]* | :heavy_minus_sign: | Payment method used for the transaction, such as cash, credit card, bank transfer, or check | cash | +| `payment_method_reference` | *OptionalNullable[str]* | :heavy_minus_sign: | Optional reference message returned by payment method on processing | 123456 | +| `payment_method_id` | *OptionalNullable[str]* | :heavy_minus_sign: | A unique identifier for an object. | 12345 | +| `account` | [OptionalNullable[models.LinkedLedgerAccount]](../../models/linkedledgeraccount.md) | :heavy_minus_sign: | N/A | | +| `line_items` | List[[models.InvoiceLineItemInput](../../models/invoicelineiteminput.md)] | :heavy_minus_sign: | Line items for itemized sales receipts. Used when the sales receipt includes product/service details with quantities and pricing. | | +| `tax_code` | *OptionalNullable[str]* | :heavy_minus_sign: | Applicable tax id/code override if tax is not supplied on a line item basis. | 1234 | +| `discount_percentage` | *OptionalNullable[float]* | :heavy_minus_sign: | Discount percentage applied to this sales receipt. | 5.5 | +| `discount_amount` | *OptionalNullable[float]* | :heavy_minus_sign: | Discount amount applied to this sales receipt. | 25 | +| `note` | *OptionalNullable[str]* | :heavy_minus_sign: | Optional note to be associated with the sales receipt. | Thank you for your purchase | +| `customer_memo` | *OptionalNullable[str]* | :heavy_minus_sign: | Customer memo | Thank you for your business and have a great day! | +| `reference` | *OptionalNullable[str]* | :heavy_minus_sign: | Optional reference message for the sales receipt. | REF-123456 | +| `billing_address` | [Optional[models.Address]](../../models/address.md) | :heavy_minus_sign: | N/A | | +| `shipping_address` | [Optional[models.Address]](../../models/address.md) | :heavy_minus_sign: | N/A | | +| `department` | [OptionalNullable[models.LinkedDepartmentInput]](../../models/linkeddepartmentinput.md) | :heavy_minus_sign: | N/A | | +| `tracking_categories` | List[[Nullable[models.LinkedTrackingCategory]](../../models/linkedtrackingcategory.md)] | :heavy_minus_sign: | A list of linked tracking categories. | | +| `custom_fields` | List[[models.CustomField](../../models/customfield.md)] | :heavy_minus_sign: | N/A | | +| `row_version` | *OptionalNullable[str]* | :heavy_minus_sign: | A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object. | 1-12345 | +| `pass_through` | List[[models.PassThroughBody](../../models/passthroughbody.md)] | :heavy_minus_sign: | The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources. | | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | + +### Response + +**[models.AccountingSalesReceiptsAddResponse](../../models/accountingsalesreceiptsaddresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| ------------------------------ | ------------------------------ | ------------------------------ | +| models.BadRequestResponse | 400 | application/json | +| models.UnauthorizedResponse | 401 | application/json | +| models.PaymentRequiredResponse | 402 | application/json | +| models.NotFoundResponse | 404 | application/json | +| models.UnprocessableResponse | 422 | application/json | +| models.APIError | 4XX, 5XX | \*/\* | + +## get + +Get Sales Receipt + +### Example Usage + + +```python +from apideck_unify import Apideck +import os + + +with Apideck( + consumer_id="test-consumer", + app_id="dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX", + api_key=os.getenv("APIDECK_API_KEY", ""), +) as apideck: + + res = apideck.accounting.sales_receipts.get(id="", service_id="salesforce", company_id="12345", raw=False, fields="id,updated_at") + + assert res.get_sales_receipt_response is not None + + # Handle response + print(res.get_sales_receipt_response) + +``` + +### Parameters + +| Parameter | Type | Required | Description | Example | +| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `id` | *str* | :heavy_check_mark: | ID of the record you are acting upon. | | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *Optional[str]* | :heavy_minus_sign: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | salesforce | +| `company_id` | *Optional[str]* | :heavy_minus_sign: | The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings. | 12345 | +| `raw` | *Optional[bool]* | :heavy_minus_sign: | Include raw response. Mostly used for debugging purposes | | +| `fields` | *OptionalNullable[str]* | :heavy_minus_sign: | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. | id,updated_at | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | + +### Response + +**[models.AccountingSalesReceiptsOneResponse](../../models/accountingsalesreceiptsoneresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| ------------------------------ | ------------------------------ | ------------------------------ | +| models.BadRequestResponse | 400 | application/json | +| models.UnauthorizedResponse | 401 | application/json | +| models.PaymentRequiredResponse | 402 | application/json | +| models.NotFoundResponse | 404 | application/json | +| models.UnprocessableResponse | 422 | application/json | +| models.APIError | 4XX, 5XX | \*/\* | + +## update + +Update Sales Receipt + +### Example Usage + + +```python +import apideck_unify +from apideck_unify import Apideck +from apideck_unify.utils import parse_datetime +from datetime import date +import os + + +with Apideck( + consumer_id="test-consumer", + app_id="dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX", + api_key=os.getenv("APIDECK_API_KEY", ""), +) as apideck: + + res = apideck.accounting.sales_receipts.update(id="", total_amount=49.99, service_id="salesforce", raw=False, company_id="12345", number="SR-00001", customer={ + "id": "12345", + "display_name": "Windsurf Shop", + "email": "boring@boring.com", + }, currency=apideck_unify.Currency.USD, currency_rate=0.69, tax_inclusive=True, sub_total=250, total_tax=25, transaction_date=parse_datetime("2021-05-01T12:00:00.000Z"), payment_method="cash", payment_method_reference="123456", payment_method_id="12345", account={ + "id": "123456", + "name": "Bank account", + "nominal_code": "N091", + "code": "453", + "parent_id": "123456", + "display_id": "123456", + }, line_items=[ + { + "id": "12345", + "row_id": "12345", + "code": "120-C", + "line_number": 1, + "description": "Model Y is a fully electric, mid-size SUV, with seating for up to seven, dual motor AWD and unparalleled protection.", + "type": apideck_unify.InvoiceLineItemType.SALES_ITEM, + "tax_amount": 27500, + "total_amount": 27500, + "quantity": 1, + "unit_price": 27500.5, + "unit_of_measure": "pc.", + "discount_percentage": 0.01, + "discount_amount": 19.99, + "service_date": date.fromisoformat("2024-01-15"), + "category_id": "12345", + "location_id": "12345", + "department_id": "12345", + "subsidiary_id": "12345", + "shipping_id": "12345", + "memo": "Some memo", + "prepaid": True, + "item": { + "id": "12344", + "code": "120-C", + "name": "Model Y", + }, + "tax_applicable_on": "Domestic_Purchase_of_Goods_and_Services", + "tax_recoverability": "Fully_Recoverable", + "tax_method": "Due_to_Supplier", + "worktags": [ + { + "id": "123456", + "value": "New York", + }, + ], + "tax_rate": { + "id": "123456", + "code": "N-T", + "rate": 10, + }, + "tracking_categories": [ + { + "id": "123456", + "code": "100", + "name": "New York", + "parent_id": "123456", + "parent_name": "New York", + }, + ], + "ledger_account": { + "id": "123456", + "name": "Bank account", + "nominal_code": "N091", + "code": "453", + "parent_id": "123456", + "display_id": "123456", + }, + "custom_fields": [ + { + "id": "2389328923893298", + "name": "employee_level", + "ref_name": "Marketing", + "description": "Employee Level", + "value": "Uses Salesforce and Marketo", + }, + ], + "row_version": "1-12345", + }, + ], tax_code="1234", discount_percentage=5.5, discount_amount=25, note="Thank you for your purchase", customer_memo="Thank you for your business and have a great day!", reference="REF-123456", billing_address={ + "id": "123", + "type": apideck_unify.Type.PRIMARY, + "string": "25 Spring Street, Blackburn, VIC 3130", + "name": "HQ US", + "line1": "Main street", + "line2": "apt #", + "line3": "Suite #", + "line4": "delivery instructions", + "line5": "Attention: Finance Dept", + "street_number": "25", + "city": "San Francisco", + "state": "CA", + "postal_code": "94104", + "country": "US", + "latitude": "40.759211", + "longitude": "-73.984638", + "county": "Santa Clara", + "contact_name": "Elon Musk", + "salutation": "Mr", + "phone_number": "111-111-1111", + "fax": "122-111-1111", + "email": "elon@musk.com", + "website": "https://elonmusk.com", + "notes": "Address notes or delivery instructions.", + "row_version": "1-12345", + }, shipping_address={ + "id": "123", + "type": apideck_unify.Type.PRIMARY, + "string": "25 Spring Street, Blackburn, VIC 3130", + "name": "HQ US", + "line1": "Main street", + "line2": "apt #", + "line3": "Suite #", + "line4": "delivery instructions", + "line5": "Attention: Finance Dept", + "street_number": "25", + "city": "San Francisco", + "state": "CA", + "postal_code": "94104", + "country": "US", + "latitude": "40.759211", + "longitude": "-73.984638", + "county": "Santa Clara", + "contact_name": "Elon Musk", + "salutation": "Mr", + "phone_number": "111-111-1111", + "fax": "122-111-1111", + "email": "elon@musk.com", + "website": "https://elonmusk.com", + "notes": "Address notes or delivery instructions.", + "row_version": "1-12345", + }, department={ + "display_id": "123456", + "name": "Acme Inc.", + }, tracking_categories=[ + { + "id": "123456", + "code": "100", + "name": "New York", + "parent_id": "123456", + "parent_name": "New York", + }, + ], custom_fields=[ + { + "id": "2389328923893298", + "name": "employee_level", + "ref_name": "Marketing", + "description": "Employee Level", + "value": "Uses Salesforce and Marketo", + }, + ], row_version="1-12345", pass_through=[ + { + "service_id": "", + "extend_paths": [ + { + "path": "$.nested.property", + "value": { + "TaxClassificationRef": { + "value": "EUC-99990201-V1-00020000", + }, + }, + }, + ], + }, + ]) + + assert res.update_sales_receipt_response is not None + + # Handle response + print(res.update_sales_receipt_response) + +``` + +### Parameters + +| Parameter | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | +| `id` | *str* | :heavy_check_mark: | ID of the record you are acting upon. | | +| `total_amount` | *Nullable[float]* | :heavy_check_mark: | The total amount of the transaction or record | 49.99 | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *Optional[str]* | :heavy_minus_sign: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | salesforce | +| `raw` | *Optional[bool]* | :heavy_minus_sign: | Include raw response. Mostly used for debugging purposes | | +| `company_id` | *Optional[str]* | :heavy_minus_sign: | The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings. | 12345 | +| `number` | *OptionalNullable[str]* | :heavy_minus_sign: | Reference number for the sales receipt. | SR-00001 | +| `customer` | [OptionalNullable[models.LinkedCustomerInput]](../../models/linkedcustomerinput.md) | :heavy_minus_sign: | The customer this entity is linked to. | | +| `currency` | [OptionalNullable[models.Currency]](../../models/currency.md) | :heavy_minus_sign: | Indicates the associated currency for an amount of money. Values correspond to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217). | USD | +| `currency_rate` | *OptionalNullable[float]* | :heavy_minus_sign: | Currency Exchange Rate at the time entity was recorded/generated. | 0.69 | +| `tax_inclusive` | *OptionalNullable[bool]* | :heavy_minus_sign: | Amounts are including tax | true | +| `sub_total` | *OptionalNullable[float]* | :heavy_minus_sign: | Subtotal amount, normally before tax. | 250 | +| `total_tax` | *OptionalNullable[float]* | :heavy_minus_sign: | Total tax amount applied to this transaction. | 25 | +| `transaction_date` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_minus_sign: | The date of the sales receipt transaction - YYYY-MM-DDThh:mm:ss.sTZD | 2021-05-01T12:00:00.000Z | +| `payment_method` | *OptionalNullable[str]* | :heavy_minus_sign: | Payment method used for the transaction, such as cash, credit card, bank transfer, or check | cash | +| `payment_method_reference` | *OptionalNullable[str]* | :heavy_minus_sign: | Optional reference message returned by payment method on processing | 123456 | +| `payment_method_id` | *OptionalNullable[str]* | :heavy_minus_sign: | A unique identifier for an object. | 12345 | +| `account` | [OptionalNullable[models.LinkedLedgerAccount]](../../models/linkedledgeraccount.md) | :heavy_minus_sign: | N/A | | +| `line_items` | List[[models.InvoiceLineItemInput](../../models/invoicelineiteminput.md)] | :heavy_minus_sign: | Line items for itemized sales receipts. Used when the sales receipt includes product/service details with quantities and pricing. | | +| `tax_code` | *OptionalNullable[str]* | :heavy_minus_sign: | Applicable tax id/code override if tax is not supplied on a line item basis. | 1234 | +| `discount_percentage` | *OptionalNullable[float]* | :heavy_minus_sign: | Discount percentage applied to this sales receipt. | 5.5 | +| `discount_amount` | *OptionalNullable[float]* | :heavy_minus_sign: | Discount amount applied to this sales receipt. | 25 | +| `note` | *OptionalNullable[str]* | :heavy_minus_sign: | Optional note to be associated with the sales receipt. | Thank you for your purchase | +| `customer_memo` | *OptionalNullable[str]* | :heavy_minus_sign: | Customer memo | Thank you for your business and have a great day! | +| `reference` | *OptionalNullable[str]* | :heavy_minus_sign: | Optional reference message for the sales receipt. | REF-123456 | +| `billing_address` | [Optional[models.Address]](../../models/address.md) | :heavy_minus_sign: | N/A | | +| `shipping_address` | [Optional[models.Address]](../../models/address.md) | :heavy_minus_sign: | N/A | | +| `department` | [OptionalNullable[models.LinkedDepartmentInput]](../../models/linkeddepartmentinput.md) | :heavy_minus_sign: | N/A | | +| `tracking_categories` | List[[Nullable[models.LinkedTrackingCategory]](../../models/linkedtrackingcategory.md)] | :heavy_minus_sign: | A list of linked tracking categories. | | +| `custom_fields` | List[[models.CustomField](../../models/customfield.md)] | :heavy_minus_sign: | N/A | | +| `row_version` | *OptionalNullable[str]* | :heavy_minus_sign: | A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object. | 1-12345 | +| `pass_through` | List[[models.PassThroughBody](../../models/passthroughbody.md)] | :heavy_minus_sign: | The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources. | | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | + +### Response + +**[models.AccountingSalesReceiptsUpdateResponse](../../models/accountingsalesreceiptsupdateresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| ------------------------------ | ------------------------------ | ------------------------------ | +| models.BadRequestResponse | 400 | application/json | +| models.UnauthorizedResponse | 401 | application/json | +| models.PaymentRequiredResponse | 402 | application/json | +| models.NotFoundResponse | 404 | application/json | +| models.UnprocessableResponse | 422 | application/json | +| models.APIError | 4XX, 5XX | \*/\* | + +## delete + +Delete Sales Receipt + +### Example Usage + + +```python +from apideck_unify import Apideck +import os + + +with Apideck( + consumer_id="test-consumer", + app_id="dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX", + api_key=os.getenv("APIDECK_API_KEY", ""), +) as apideck: + + res = apideck.accounting.sales_receipts.delete(id="", service_id="salesforce", raw=False, company_id="12345") + + assert res.delete_sales_receipt_response is not None + + # Handle response + print(res.delete_sales_receipt_response) + +``` + +### Parameters + +| Parameter | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | +| `id` | *str* | :heavy_check_mark: | ID of the record you are acting upon. | | +| `consumer_id` | *Optional[str]* | :heavy_minus_sign: | ID of the consumer which you want to get or push data from | test-consumer | +| `app_id` | *Optional[str]* | :heavy_minus_sign: | The ID of your Unify application | dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX | +| `service_id` | *Optional[str]* | :heavy_minus_sign: | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | salesforce | +| `raw` | *Optional[bool]* | :heavy_minus_sign: | Include raw response. Mostly used for debugging purposes | | +| `company_id` | *Optional[str]* | :heavy_minus_sign: | The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings. | 12345 | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | + +### Response + +**[models.AccountingSalesReceiptsDeleteResponse](../../models/accountingsalesreceiptsdeleteresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| ------------------------------ | ------------------------------ | ------------------------------ | +| models.BadRequestResponse | 400 | application/json | +| models.UnauthorizedResponse | 401 | application/json | +| models.PaymentRequiredResponse | 402 | application/json | +| models.NotFoundResponse | 404 | application/json | +| models.UnprocessableResponse | 422 | application/json | +| models.APIError | 4XX, 5XX | \*/\* | \ No newline at end of file diff --git a/pyproject.toml b/pyproject.toml index a9211300..3250ae55 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,7 +1,7 @@ [project] name = "apideck-unify" -version = "0.36.0" +version = "0.37.0" description = "Python Client SDK Generated by Speakeasy." authors = [{ name = "Speakeasy" },] readme = "README-PYPI.md" diff --git a/src/apideck_unify/_version.py b/src/apideck_unify/_version.py index 58518d0e..c43d2db7 100644 --- a/src/apideck_unify/_version.py +++ b/src/apideck_unify/_version.py @@ -3,10 +3,10 @@ import importlib.metadata __title__: str = "apideck-unify" -__version__: str = "0.36.0" -__openapi_doc_version__: str = "10.32.0" +__version__: str = "0.37.0" +__openapi_doc_version__: str = "10.38.0" __gen_version__: str = "2.753.1" -__user_agent__: str = "speakeasy-sdk/python 0.36.0 2.753.1 10.32.0 apideck-unify" +__user_agent__: str = "speakeasy-sdk/python 0.37.0 2.753.1 10.38.0 apideck-unify" try: if __package__ is not None: diff --git a/src/apideck_unify/accounting.py b/src/apideck_unify/accounting.py index 985058f8..26ec1b84 100644 --- a/src/apideck_unify/accounting.py +++ b/src/apideck_unify/accounting.py @@ -27,12 +27,14 @@ from apideck_unify.journalentries import JournalEntries from apideck_unify.ledgeraccounts import LedgerAccounts from apideck_unify.locations import Locations +from apideck_unify.paymentmethods import PaymentMethods from apideck_unify.payments import Payments from apideck_unify.profitandloss_sdk import ProfitAndLossSDK from apideck_unify.projects import Projects from apideck_unify.purchaseorders import PurchaseOrders from apideck_unify.quotes import Quotes from apideck_unify.refunds import Refunds +from apideck_unify.salesreceipts import SalesReceipts from apideck_unify.subsidiaries import Subsidiaries from apideck_unify.suppliers import Suppliers from apideck_unify.taxrates import TaxRates @@ -57,6 +59,7 @@ class Accounting(BaseSDK): profit_and_loss: ProfitAndLossSDK journal_entries: JournalEntries general_ledger_transactions: GeneralLedgerTransactions + sales_receipts: SalesReceipts purchase_orders: PurchaseOrders subsidiaries: Subsidiaries locations: Locations @@ -75,6 +78,7 @@ class Accounting(BaseSDK): projects: Projects employees: Employees expense_categories: ExpenseCategories + payment_methods: PaymentMethods expense_reports: ExpenseReports def __init__( @@ -117,6 +121,9 @@ def _init_sdks(self): self.general_ledger_transactions = GeneralLedgerTransactions( self.sdk_configuration, parent_ref=self.parent_ref ) + self.sales_receipts = SalesReceipts( + self.sdk_configuration, parent_ref=self.parent_ref + ) self.purchase_orders = PurchaseOrders( self.sdk_configuration, parent_ref=self.parent_ref ) @@ -159,6 +166,9 @@ def _init_sdks(self): self.expense_categories = ExpenseCategories( self.sdk_configuration, parent_ref=self.parent_ref ) + self.payment_methods = PaymentMethods( + self.sdk_configuration, parent_ref=self.parent_ref + ) self.expense_reports = ExpenseReports( self.sdk_configuration, parent_ref=self.parent_ref ) diff --git a/src/apideck_unify/attachments.py b/src/apideck_unify/attachments.py index b6e915c8..1588886e 100644 --- a/src/apideck_unify/attachments.py +++ b/src/apideck_unify/attachments.py @@ -1317,6 +1317,7 @@ def download( service_id: Optional[str] = None, company_id: Optional[str] = None, fields: OptionalNullable[str] = UNSET, + follow_redirects: Optional[bool] = True, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, @@ -1335,6 +1336,7 @@ def download( :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. :param company_id: The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings. :param fields: The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields \"name\", \"email\" and \"addresses.city\". If any other fields are available, they will be excluded. + :param follow_redirects: Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds @@ -1360,6 +1362,7 @@ def download( service_id=service_id, company_id=company_id, fields=fields, + follow_redirects=follow_redirects, ) req = self._build_request( @@ -1477,6 +1480,7 @@ async def download_async( service_id: Optional[str] = None, company_id: Optional[str] = None, fields: OptionalNullable[str] = UNSET, + follow_redirects: Optional[bool] = True, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, @@ -1495,6 +1499,7 @@ async def download_async( :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. :param company_id: The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings. :param fields: The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields \"name\", \"email\" and \"addresses.city\". If any other fields are available, they will be excluded. + :param follow_redirects: Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds @@ -1520,6 +1525,7 @@ async def download_async( service_id=service_id, company_id=company_id, fields=fields, + follow_redirects=follow_redirects, ) req = self._build_request_async( diff --git a/src/apideck_unify/bankfeedaccounts.py b/src/apideck_unify/bankfeedaccounts.py index e95dd8cc..0a46f39e 100644 --- a/src/apideck_unify/bankfeedaccounts.py +++ b/src/apideck_unify/bankfeedaccounts.py @@ -378,9 +378,13 @@ def create( service_id: Optional[str] = None, bank_account_type: Optional[models.BankAccountType] = None, source_account_id: Optional[str] = None, + source_routing_number: OptionalNullable[str] = UNSET, + source_account_number: OptionalNullable[str] = UNSET, target_account_id: Optional[str] = None, target_account_name: Optional[str] = None, target_account_number: Optional[str] = None, + balance: OptionalNullable[float] = UNSET, + available_balance: OptionalNullable[float] = UNSET, currency: OptionalNullable[models.Currency] = UNSET, feed_status: Optional[models.FeedStatus] = None, country: OptionalNullable[str] = UNSET, @@ -402,9 +406,13 @@ def create( :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. :param bank_account_type: Type of the bank account. :param source_account_id: The source account's unique identifier. + :param source_routing_number: Bank routing number (US) + :param source_account_number: The bank account number :param target_account_id: The target account's unique identifier in the accounting connector. :param target_account_name: Name associated with the target account. :param target_account_number: Account number of the destination bank account. + :param balance: The current balance of the source bank account. + :param available_balance: The available balance of the source bank account (considering pending transactions and overdraft). :param currency: Indicates the associated currency for an amount of money. Values correspond to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217). :param feed_status: Current status of the bank feed. :param country: Country code according to ISO 3166-1 alpha-2. @@ -432,9 +440,13 @@ def create( bank_feed_account=models.BankFeedAccountInput( bank_account_type=bank_account_type, source_account_id=source_account_id, + source_routing_number=source_routing_number, + source_account_number=source_account_number, target_account_id=target_account_id, target_account_name=target_account_name, target_account_number=target_account_number, + balance=balance, + available_balance=available_balance, currency=currency, feed_status=feed_status, country=country, @@ -556,9 +568,13 @@ async def create_async( service_id: Optional[str] = None, bank_account_type: Optional[models.BankAccountType] = None, source_account_id: Optional[str] = None, + source_routing_number: OptionalNullable[str] = UNSET, + source_account_number: OptionalNullable[str] = UNSET, target_account_id: Optional[str] = None, target_account_name: Optional[str] = None, target_account_number: Optional[str] = None, + balance: OptionalNullable[float] = UNSET, + available_balance: OptionalNullable[float] = UNSET, currency: OptionalNullable[models.Currency] = UNSET, feed_status: Optional[models.FeedStatus] = None, country: OptionalNullable[str] = UNSET, @@ -580,9 +596,13 @@ async def create_async( :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. :param bank_account_type: Type of the bank account. :param source_account_id: The source account's unique identifier. + :param source_routing_number: Bank routing number (US) + :param source_account_number: The bank account number :param target_account_id: The target account's unique identifier in the accounting connector. :param target_account_name: Name associated with the target account. :param target_account_number: Account number of the destination bank account. + :param balance: The current balance of the source bank account. + :param available_balance: The available balance of the source bank account (considering pending transactions and overdraft). :param currency: Indicates the associated currency for an amount of money. Values correspond to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217). :param feed_status: Current status of the bank feed. :param country: Country code according to ISO 3166-1 alpha-2. @@ -610,9 +630,13 @@ async def create_async( bank_feed_account=models.BankFeedAccountInput( bank_account_type=bank_account_type, source_account_id=source_account_id, + source_routing_number=source_routing_number, + source_account_number=source_account_number, target_account_id=target_account_id, target_account_name=target_account_name, target_account_number=target_account_number, + balance=balance, + available_balance=available_balance, currency=currency, feed_status=feed_status, country=country, @@ -1029,9 +1053,13 @@ def update( raw: Optional[bool] = False, bank_account_type: Optional[models.BankAccountType] = None, source_account_id: Optional[str] = None, + source_routing_number: OptionalNullable[str] = UNSET, + source_account_number: OptionalNullable[str] = UNSET, target_account_id: Optional[str] = None, target_account_name: Optional[str] = None, target_account_number: Optional[str] = None, + balance: OptionalNullable[float] = UNSET, + available_balance: OptionalNullable[float] = UNSET, currency: OptionalNullable[models.Currency] = UNSET, feed_status: Optional[models.FeedStatus] = None, country: OptionalNullable[str] = UNSET, @@ -1054,9 +1082,13 @@ def update( :param raw: Include raw response. Mostly used for debugging purposes :param bank_account_type: Type of the bank account. :param source_account_id: The source account's unique identifier. + :param source_routing_number: Bank routing number (US) + :param source_account_number: The bank account number :param target_account_id: The target account's unique identifier in the accounting connector. :param target_account_name: Name associated with the target account. :param target_account_number: Account number of the destination bank account. + :param balance: The current balance of the source bank account. + :param available_balance: The available balance of the source bank account (considering pending transactions and overdraft). :param currency: Indicates the associated currency for an amount of money. Values correspond to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217). :param feed_status: Current status of the bank feed. :param country: Country code according to ISO 3166-1 alpha-2. @@ -1085,9 +1117,13 @@ def update( bank_feed_account=models.BankFeedAccountInput( bank_account_type=bank_account_type, source_account_id=source_account_id, + source_routing_number=source_routing_number, + source_account_number=source_account_number, target_account_id=target_account_id, target_account_name=target_account_name, target_account_number=target_account_number, + balance=balance, + available_balance=available_balance, currency=currency, feed_status=feed_status, country=country, @@ -1210,9 +1246,13 @@ async def update_async( raw: Optional[bool] = False, bank_account_type: Optional[models.BankAccountType] = None, source_account_id: Optional[str] = None, + source_routing_number: OptionalNullable[str] = UNSET, + source_account_number: OptionalNullable[str] = UNSET, target_account_id: Optional[str] = None, target_account_name: Optional[str] = None, target_account_number: Optional[str] = None, + balance: OptionalNullable[float] = UNSET, + available_balance: OptionalNullable[float] = UNSET, currency: OptionalNullable[models.Currency] = UNSET, feed_status: Optional[models.FeedStatus] = None, country: OptionalNullable[str] = UNSET, @@ -1235,9 +1275,13 @@ async def update_async( :param raw: Include raw response. Mostly used for debugging purposes :param bank_account_type: Type of the bank account. :param source_account_id: The source account's unique identifier. + :param source_routing_number: Bank routing number (US) + :param source_account_number: The bank account number :param target_account_id: The target account's unique identifier in the accounting connector. :param target_account_name: Name associated with the target account. :param target_account_number: Account number of the destination bank account. + :param balance: The current balance of the source bank account. + :param available_balance: The available balance of the source bank account (considering pending transactions and overdraft). :param currency: Indicates the associated currency for an amount of money. Values correspond to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217). :param feed_status: Current status of the bank feed. :param country: Country code according to ISO 3166-1 alpha-2. @@ -1266,9 +1310,13 @@ async def update_async( bank_feed_account=models.BankFeedAccountInput( bank_account_type=bank_account_type, source_account_id=source_account_id, + source_routing_number=source_routing_number, + source_account_number=source_account_number, target_account_id=target_account_id, target_account_name=target_account_name, target_account_number=target_account_number, + balance=balance, + available_balance=available_balance, currency=currency, feed_status=feed_status, country=country, diff --git a/src/apideck_unify/files.py b/src/apideck_unify/files.py index cc0e20c8..d240c286 100644 --- a/src/apideck_unify/files.py +++ b/src/apideck_unify/files.py @@ -1648,6 +1648,7 @@ def download( app_id: Optional[str] = None, service_id: Optional[str] = None, fields: OptionalNullable[str] = UNSET, + follow_redirects: Optional[bool] = True, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, @@ -1663,6 +1664,7 @@ def download( :param app_id: The ID of your Unify application :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. :param fields: The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields \"name\", \"email\" and \"addresses.city\". If any other fields are available, they will be excluded. + :param follow_redirects: Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds @@ -1685,6 +1687,7 @@ def download( app_id=app_id, service_id=service_id, fields=fields, + follow_redirects=follow_redirects, ) req = self._build_request( @@ -1799,6 +1802,7 @@ async def download_async( app_id: Optional[str] = None, service_id: Optional[str] = None, fields: OptionalNullable[str] = UNSET, + follow_redirects: Optional[bool] = True, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, @@ -1814,6 +1818,7 @@ async def download_async( :param app_id: The ID of your Unify application :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. :param fields: The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields \"name\", \"email\" and \"addresses.city\". If any other fields are available, they will be excluded. + :param follow_redirects: Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds @@ -1836,6 +1841,7 @@ async def download_async( app_id=app_id, service_id=service_id, fields=fields, + follow_redirects=follow_redirects, ) req = self._build_request_async( diff --git a/src/apideck_unify/models/__init__.py b/src/apideck_unify/models/__init__.py index afa8f1f8..6880815a 100644 --- a/src/apideck_unify/models/__init__.py +++ b/src/apideck_unify/models/__init__.py @@ -800,6 +800,46 @@ AccountingLocationsUpdateResponse, AccountingLocationsUpdateResponseTypedDict, ) + from .accounting_paymentmethodsaddop import ( + AccountingPaymentMethodsAddGlobals, + AccountingPaymentMethodsAddGlobalsTypedDict, + AccountingPaymentMethodsAddRequest, + AccountingPaymentMethodsAddRequestTypedDict, + AccountingPaymentMethodsAddResponse, + AccountingPaymentMethodsAddResponseTypedDict, + ) + from .accounting_paymentmethodsallop import ( + AccountingPaymentMethodsAllGlobals, + AccountingPaymentMethodsAllGlobalsTypedDict, + AccountingPaymentMethodsAllRequest, + AccountingPaymentMethodsAllRequestTypedDict, + AccountingPaymentMethodsAllResponse, + AccountingPaymentMethodsAllResponseTypedDict, + ) + from .accounting_paymentmethodsdeleteop import ( + AccountingPaymentMethodsDeleteGlobals, + AccountingPaymentMethodsDeleteGlobalsTypedDict, + AccountingPaymentMethodsDeleteRequest, + AccountingPaymentMethodsDeleteRequestTypedDict, + AccountingPaymentMethodsDeleteResponse, + AccountingPaymentMethodsDeleteResponseTypedDict, + ) + from .accounting_paymentmethodsoneop import ( + AccountingPaymentMethodsOneGlobals, + AccountingPaymentMethodsOneGlobalsTypedDict, + AccountingPaymentMethodsOneRequest, + AccountingPaymentMethodsOneRequestTypedDict, + AccountingPaymentMethodsOneResponse, + AccountingPaymentMethodsOneResponseTypedDict, + ) + from .accounting_paymentmethodsupdateop import ( + AccountingPaymentMethodsUpdateGlobals, + AccountingPaymentMethodsUpdateGlobalsTypedDict, + AccountingPaymentMethodsUpdateRequest, + AccountingPaymentMethodsUpdateRequestTypedDict, + AccountingPaymentMethodsUpdateResponse, + AccountingPaymentMethodsUpdateResponseTypedDict, + ) from .accounting_paymentsaddop import ( AccountingPaymentsAddGlobals, AccountingPaymentsAddGlobalsTypedDict, @@ -1008,6 +1048,46 @@ AccountingRefundsUpdateResponse, AccountingRefundsUpdateResponseTypedDict, ) + from .accounting_salesreceiptsaddop import ( + AccountingSalesReceiptsAddGlobals, + AccountingSalesReceiptsAddGlobalsTypedDict, + AccountingSalesReceiptsAddRequest, + AccountingSalesReceiptsAddRequestTypedDict, + AccountingSalesReceiptsAddResponse, + AccountingSalesReceiptsAddResponseTypedDict, + ) + from .accounting_salesreceiptsallop import ( + AccountingSalesReceiptsAllGlobals, + AccountingSalesReceiptsAllGlobalsTypedDict, + AccountingSalesReceiptsAllRequest, + AccountingSalesReceiptsAllRequestTypedDict, + AccountingSalesReceiptsAllResponse, + AccountingSalesReceiptsAllResponseTypedDict, + ) + from .accounting_salesreceiptsdeleteop import ( + AccountingSalesReceiptsDeleteGlobals, + AccountingSalesReceiptsDeleteGlobalsTypedDict, + AccountingSalesReceiptsDeleteRequest, + AccountingSalesReceiptsDeleteRequestTypedDict, + AccountingSalesReceiptsDeleteResponse, + AccountingSalesReceiptsDeleteResponseTypedDict, + ) + from .accounting_salesreceiptsoneop import ( + AccountingSalesReceiptsOneGlobals, + AccountingSalesReceiptsOneGlobalsTypedDict, + AccountingSalesReceiptsOneRequest, + AccountingSalesReceiptsOneRequestTypedDict, + AccountingSalesReceiptsOneResponse, + AccountingSalesReceiptsOneResponseTypedDict, + ) + from .accounting_salesreceiptsupdateop import ( + AccountingSalesReceiptsUpdateGlobals, + AccountingSalesReceiptsUpdateGlobalsTypedDict, + AccountingSalesReceiptsUpdateRequest, + AccountingSalesReceiptsUpdateRequestTypedDict, + AccountingSalesReceiptsUpdateResponse, + AccountingSalesReceiptsUpdateResponseTypedDict, + ) from .accounting_subsidiariesaddop import ( AccountingSubsidiariesAddGlobals, AccountingSubsidiariesAddGlobalsTypedDict, @@ -1216,6 +1296,14 @@ AccountingLocationsFilter, AccountingLocationsFilterTypedDict, ) + from .accountingpaymentmethod import ( + AccountingPaymentMethod, + AccountingPaymentMethodInput, + AccountingPaymentMethodInputTypedDict, + AccountingPaymentMethodStatus, + AccountingPaymentMethodType, + AccountingPaymentMethodTypedDict, + ) from .activitiesfilter import ActivitiesFilter, ActivitiesFilterTypedDict from .activitiessort import ( ActivitiesSort, @@ -1882,6 +1970,10 @@ CreateOpportunityResponse, CreateOpportunityResponseTypedDict, ) + from .createpaymentmethodresponse import ( + CreatePaymentMethodResponse, + CreatePaymentMethodResponseTypedDict, + ) from .createpaymentresponse import ( CreatePaymentResponse, CreatePaymentResponseTypedDict, @@ -1903,6 +1995,10 @@ CreateRefundResponse, CreateRefundResponseTypedDict, ) + from .createsalesreceiptresponse import ( + CreateSalesReceiptResponse, + CreateSalesReceiptResponseTypedDict, + ) from .createsessionresponse import ( CreateSessionResponse, CreateSessionResponseData, @@ -2591,6 +2687,10 @@ DeleteOpportunityResponse, DeleteOpportunityResponseTypedDict, ) + from .deletepaymentmethodresponse import ( + DeletePaymentMethodResponse, + DeletePaymentMethodResponseTypedDict, + ) from .deletepaymentresponse import ( DeletePaymentResponse, DeletePaymentResponseTypedDict, @@ -2612,6 +2712,10 @@ DeleteRefundResponse, DeleteRefundResponseTypedDict, ) + from .deletesalesreceiptresponse import ( + DeleteSalesReceiptResponse, + DeleteSalesReceiptResponseTypedDict, + ) from .deletesharedlinkresponse import ( DeleteSharedLinkResponse, DeleteSharedLinkResponseTypedDict, @@ -3531,6 +3635,14 @@ GetOpportunityResponse, GetOpportunityResponseTypedDict, ) + from .getpaymentmethodresponse import ( + GetPaymentMethodResponse, + GetPaymentMethodResponseTypedDict, + ) + from .getpaymentmethodsresponse import ( + GetPaymentMethodsResponse, + GetPaymentMethodsResponseTypedDict, + ) from .getpaymentresponse import GetPaymentResponse, GetPaymentResponseTypedDict from .getpaymentsresponse import GetPaymentsResponse, GetPaymentsResponseTypedDict from .getpayrollresponse import GetPayrollResponse, GetPayrollResponseTypedDict @@ -3560,6 +3672,14 @@ from .getquotesresponse import GetQuotesResponse, GetQuotesResponseTypedDict from .getrefundresponse import GetRefundResponse, GetRefundResponseTypedDict from .getrefundsresponse import GetRefundsResponse, GetRefundsResponseTypedDict + from .getsalesreceiptresponse import ( + GetSalesReceiptResponse, + GetSalesReceiptResponseTypedDict, + ) + from .getsalesreceiptsresponse import ( + GetSalesReceiptsResponse, + GetSalesReceiptsResponseTypedDict, + ) from .getsharedlinkresponse import ( GetSharedLinkResponse, GetSharedLinkResponseTypedDict, @@ -4396,6 +4516,14 @@ ) from .resourcestatus import ResourceStatus from .responsevalidationerror import ResponseValidationError + from .salesreceipt import SalesReceipt, SalesReceiptTypedDict + from .salesreceipt_input import SalesReceiptInput, SalesReceiptInputTypedDict + from .salesreceiptsfilter import SalesReceiptsFilter, SalesReceiptsFilterTypedDict + from .salesreceiptssort import ( + SalesReceiptsSort, + SalesReceiptsSortBy, + SalesReceiptsSortTypedDict, + ) from .schedule import ( EvenWeeks, EvenWeeksTypedDict, @@ -4753,6 +4881,10 @@ UpdateOpportunityResponse, UpdateOpportunityResponseTypedDict, ) + from .updatepaymentmethodresponse import ( + UpdatePaymentMethodResponse, + UpdatePaymentMethodResponseTypedDict, + ) from .updatepaymentresponse import ( UpdatePaymentResponse, UpdatePaymentResponseTypedDict, @@ -4774,6 +4906,10 @@ UpdateRefundResponse, UpdateRefundResponseTypedDict, ) + from .updatesalesreceiptresponse import ( + UpdateSalesReceiptResponse, + UpdateSalesReceiptResponseTypedDict, + ) from .updatesharedlinkresponse import ( UpdateSharedLinkResponse, UpdateSharedLinkResponseTypedDict, @@ -5739,6 +5875,42 @@ "AccountingLocationsUpdateResponse", "AccountingLocationsUpdateResponseTypedDict", "AccountingMethod", + "AccountingPaymentMethod", + "AccountingPaymentMethodInput", + "AccountingPaymentMethodInputTypedDict", + "AccountingPaymentMethodStatus", + "AccountingPaymentMethodType", + "AccountingPaymentMethodTypedDict", + "AccountingPaymentMethodsAddGlobals", + "AccountingPaymentMethodsAddGlobalsTypedDict", + "AccountingPaymentMethodsAddRequest", + "AccountingPaymentMethodsAddRequestTypedDict", + "AccountingPaymentMethodsAddResponse", + "AccountingPaymentMethodsAddResponseTypedDict", + "AccountingPaymentMethodsAllGlobals", + "AccountingPaymentMethodsAllGlobalsTypedDict", + "AccountingPaymentMethodsAllRequest", + "AccountingPaymentMethodsAllRequestTypedDict", + "AccountingPaymentMethodsAllResponse", + "AccountingPaymentMethodsAllResponseTypedDict", + "AccountingPaymentMethodsDeleteGlobals", + "AccountingPaymentMethodsDeleteGlobalsTypedDict", + "AccountingPaymentMethodsDeleteRequest", + "AccountingPaymentMethodsDeleteRequestTypedDict", + "AccountingPaymentMethodsDeleteResponse", + "AccountingPaymentMethodsDeleteResponseTypedDict", + "AccountingPaymentMethodsOneGlobals", + "AccountingPaymentMethodsOneGlobalsTypedDict", + "AccountingPaymentMethodsOneRequest", + "AccountingPaymentMethodsOneRequestTypedDict", + "AccountingPaymentMethodsOneResponse", + "AccountingPaymentMethodsOneResponseTypedDict", + "AccountingPaymentMethodsUpdateGlobals", + "AccountingPaymentMethodsUpdateGlobalsTypedDict", + "AccountingPaymentMethodsUpdateRequest", + "AccountingPaymentMethodsUpdateRequestTypedDict", + "AccountingPaymentMethodsUpdateResponse", + "AccountingPaymentMethodsUpdateResponseTypedDict", "AccountingPaymentsAddGlobals", "AccountingPaymentsAddGlobalsTypedDict", "AccountingPaymentsAddRequest", @@ -5897,6 +6069,36 @@ "AccountingRefundsUpdateRequestTypedDict", "AccountingRefundsUpdateResponse", "AccountingRefundsUpdateResponseTypedDict", + "AccountingSalesReceiptsAddGlobals", + "AccountingSalesReceiptsAddGlobalsTypedDict", + "AccountingSalesReceiptsAddRequest", + "AccountingSalesReceiptsAddRequestTypedDict", + "AccountingSalesReceiptsAddResponse", + "AccountingSalesReceiptsAddResponseTypedDict", + "AccountingSalesReceiptsAllGlobals", + "AccountingSalesReceiptsAllGlobalsTypedDict", + "AccountingSalesReceiptsAllRequest", + "AccountingSalesReceiptsAllRequestTypedDict", + "AccountingSalesReceiptsAllResponse", + "AccountingSalesReceiptsAllResponseTypedDict", + "AccountingSalesReceiptsDeleteGlobals", + "AccountingSalesReceiptsDeleteGlobalsTypedDict", + "AccountingSalesReceiptsDeleteRequest", + "AccountingSalesReceiptsDeleteRequestTypedDict", + "AccountingSalesReceiptsDeleteResponse", + "AccountingSalesReceiptsDeleteResponseTypedDict", + "AccountingSalesReceiptsOneGlobals", + "AccountingSalesReceiptsOneGlobalsTypedDict", + "AccountingSalesReceiptsOneRequest", + "AccountingSalesReceiptsOneRequestTypedDict", + "AccountingSalesReceiptsOneResponse", + "AccountingSalesReceiptsOneResponseTypedDict", + "AccountingSalesReceiptsUpdateGlobals", + "AccountingSalesReceiptsUpdateGlobalsTypedDict", + "AccountingSalesReceiptsUpdateRequest", + "AccountingSalesReceiptsUpdateRequestTypedDict", + "AccountingSalesReceiptsUpdateResponse", + "AccountingSalesReceiptsUpdateResponseTypedDict", "AccountingSubsidiariesAddGlobals", "AccountingSubsidiariesAddGlobalsTypedDict", "AccountingSubsidiariesAddRequest", @@ -6512,6 +6714,8 @@ "CreateNoteResponseTypedDict", "CreateOpportunityResponse", "CreateOpportunityResponseTypedDict", + "CreatePaymentMethodResponse", + "CreatePaymentMethodResponseTypedDict", "CreatePaymentResponse", "CreatePaymentResponseTypedDict", "CreatePipelineResponse", @@ -6524,6 +6728,8 @@ "CreateQuoteResponseTypedDict", "CreateRefundResponse", "CreateRefundResponseTypedDict", + "CreateSalesReceiptResponse", + "CreateSalesReceiptResponseTypedDict", "CreateSessionResponse", "CreateSessionResponseData", "CreateSessionResponseDataTypedDict", @@ -7027,6 +7233,8 @@ "DeleteNoteResponseTypedDict", "DeleteOpportunityResponse", "DeleteOpportunityResponseTypedDict", + "DeletePaymentMethodResponse", + "DeletePaymentMethodResponseTypedDict", "DeletePaymentResponse", "DeletePaymentResponseTypedDict", "DeletePipelineResponse", @@ -7039,6 +7247,8 @@ "DeleteQuoteResponseTypedDict", "DeleteRefundResponse", "DeleteRefundResponseTypedDict", + "DeleteSalesReceiptResponse", + "DeleteSalesReceiptResponseTypedDict", "DeleteSharedLinkResponse", "DeleteSharedLinkResponseTypedDict", "DeleteSubsidiaryResponse", @@ -7723,6 +7933,10 @@ "GetOpportunitiesResponseTypedDict", "GetOpportunityResponse", "GetOpportunityResponseTypedDict", + "GetPaymentMethodResponse", + "GetPaymentMethodResponseTypedDict", + "GetPaymentMethodsResponse", + "GetPaymentMethodsResponseTypedDict", "GetPaymentResponse", "GetPaymentResponseTypedDict", "GetPaymentsResponse", @@ -7757,6 +7971,10 @@ "GetRefundResponseTypedDict", "GetRefundsResponse", "GetRefundsResponseTypedDict", + "GetSalesReceiptResponse", + "GetSalesReceiptResponseTypedDict", + "GetSalesReceiptsResponse", + "GetSalesReceiptsResponseTypedDict", "GetSharedLinkResponse", "GetSharedLinkResponseTypedDict", "GetSharedLinksResponse", @@ -8468,6 +8686,15 @@ "SalaryTypedDict", "SalesDetails", "SalesDetailsTypedDict", + "SalesReceipt", + "SalesReceiptInput", + "SalesReceiptInputTypedDict", + "SalesReceiptTypedDict", + "SalesReceiptsFilter", + "SalesReceiptsFilterTypedDict", + "SalesReceiptsSort", + "SalesReceiptsSortBy", + "SalesReceiptsSortTypedDict", "Schedule", "ScheduleStatus", "ScheduleTypedDict", @@ -8729,6 +8956,8 @@ "UpdateNoteResponseTypedDict", "UpdateOpportunityResponse", "UpdateOpportunityResponseTypedDict", + "UpdatePaymentMethodResponse", + "UpdatePaymentMethodResponseTypedDict", "UpdatePaymentResponse", "UpdatePaymentResponseTypedDict", "UpdatePipelineResponse", @@ -8741,6 +8970,8 @@ "UpdateQuoteResponseTypedDict", "UpdateRefundResponse", "UpdateRefundResponseTypedDict", + "UpdateSalesReceiptResponse", + "UpdateSalesReceiptResponseTypedDict", "UpdateSharedLinkResponse", "UpdateSharedLinkResponseTypedDict", "UpdateSubsidiaryResponse", @@ -9592,6 +9823,36 @@ "AccountingLocationsUpdateRequestTypedDict": ".accounting_locationsupdateop", "AccountingLocationsUpdateResponse": ".accounting_locationsupdateop", "AccountingLocationsUpdateResponseTypedDict": ".accounting_locationsupdateop", + "AccountingPaymentMethodsAddGlobals": ".accounting_paymentmethodsaddop", + "AccountingPaymentMethodsAddGlobalsTypedDict": ".accounting_paymentmethodsaddop", + "AccountingPaymentMethodsAddRequest": ".accounting_paymentmethodsaddop", + "AccountingPaymentMethodsAddRequestTypedDict": ".accounting_paymentmethodsaddop", + "AccountingPaymentMethodsAddResponse": ".accounting_paymentmethodsaddop", + "AccountingPaymentMethodsAddResponseTypedDict": ".accounting_paymentmethodsaddop", + "AccountingPaymentMethodsAllGlobals": ".accounting_paymentmethodsallop", + "AccountingPaymentMethodsAllGlobalsTypedDict": ".accounting_paymentmethodsallop", + "AccountingPaymentMethodsAllRequest": ".accounting_paymentmethodsallop", + "AccountingPaymentMethodsAllRequestTypedDict": ".accounting_paymentmethodsallop", + "AccountingPaymentMethodsAllResponse": ".accounting_paymentmethodsallop", + "AccountingPaymentMethodsAllResponseTypedDict": ".accounting_paymentmethodsallop", + "AccountingPaymentMethodsDeleteGlobals": ".accounting_paymentmethodsdeleteop", + "AccountingPaymentMethodsDeleteGlobalsTypedDict": ".accounting_paymentmethodsdeleteop", + "AccountingPaymentMethodsDeleteRequest": ".accounting_paymentmethodsdeleteop", + "AccountingPaymentMethodsDeleteRequestTypedDict": ".accounting_paymentmethodsdeleteop", + "AccountingPaymentMethodsDeleteResponse": ".accounting_paymentmethodsdeleteop", + "AccountingPaymentMethodsDeleteResponseTypedDict": ".accounting_paymentmethodsdeleteop", + "AccountingPaymentMethodsOneGlobals": ".accounting_paymentmethodsoneop", + "AccountingPaymentMethodsOneGlobalsTypedDict": ".accounting_paymentmethodsoneop", + "AccountingPaymentMethodsOneRequest": ".accounting_paymentmethodsoneop", + "AccountingPaymentMethodsOneRequestTypedDict": ".accounting_paymentmethodsoneop", + "AccountingPaymentMethodsOneResponse": ".accounting_paymentmethodsoneop", + "AccountingPaymentMethodsOneResponseTypedDict": ".accounting_paymentmethodsoneop", + "AccountingPaymentMethodsUpdateGlobals": ".accounting_paymentmethodsupdateop", + "AccountingPaymentMethodsUpdateGlobalsTypedDict": ".accounting_paymentmethodsupdateop", + "AccountingPaymentMethodsUpdateRequest": ".accounting_paymentmethodsupdateop", + "AccountingPaymentMethodsUpdateRequestTypedDict": ".accounting_paymentmethodsupdateop", + "AccountingPaymentMethodsUpdateResponse": ".accounting_paymentmethodsupdateop", + "AccountingPaymentMethodsUpdateResponseTypedDict": ".accounting_paymentmethodsupdateop", "AccountingPaymentsAddGlobals": ".accounting_paymentsaddop", "AccountingPaymentsAddGlobalsTypedDict": ".accounting_paymentsaddop", "AccountingPaymentsAddRequest": ".accounting_paymentsaddop", @@ -9748,6 +10009,36 @@ "AccountingRefundsUpdateRequestTypedDict": ".accounting_refundsupdateop", "AccountingRefundsUpdateResponse": ".accounting_refundsupdateop", "AccountingRefundsUpdateResponseTypedDict": ".accounting_refundsupdateop", + "AccountingSalesReceiptsAddGlobals": ".accounting_salesreceiptsaddop", + "AccountingSalesReceiptsAddGlobalsTypedDict": ".accounting_salesreceiptsaddop", + "AccountingSalesReceiptsAddRequest": ".accounting_salesreceiptsaddop", + "AccountingSalesReceiptsAddRequestTypedDict": ".accounting_salesreceiptsaddop", + "AccountingSalesReceiptsAddResponse": ".accounting_salesreceiptsaddop", + "AccountingSalesReceiptsAddResponseTypedDict": ".accounting_salesreceiptsaddop", + "AccountingSalesReceiptsAllGlobals": ".accounting_salesreceiptsallop", + "AccountingSalesReceiptsAllGlobalsTypedDict": ".accounting_salesreceiptsallop", + "AccountingSalesReceiptsAllRequest": ".accounting_salesreceiptsallop", + "AccountingSalesReceiptsAllRequestTypedDict": ".accounting_salesreceiptsallop", + "AccountingSalesReceiptsAllResponse": ".accounting_salesreceiptsallop", + "AccountingSalesReceiptsAllResponseTypedDict": ".accounting_salesreceiptsallop", + "AccountingSalesReceiptsDeleteGlobals": ".accounting_salesreceiptsdeleteop", + "AccountingSalesReceiptsDeleteGlobalsTypedDict": ".accounting_salesreceiptsdeleteop", + "AccountingSalesReceiptsDeleteRequest": ".accounting_salesreceiptsdeleteop", + "AccountingSalesReceiptsDeleteRequestTypedDict": ".accounting_salesreceiptsdeleteop", + "AccountingSalesReceiptsDeleteResponse": ".accounting_salesreceiptsdeleteop", + "AccountingSalesReceiptsDeleteResponseTypedDict": ".accounting_salesreceiptsdeleteop", + "AccountingSalesReceiptsOneGlobals": ".accounting_salesreceiptsoneop", + "AccountingSalesReceiptsOneGlobalsTypedDict": ".accounting_salesreceiptsoneop", + "AccountingSalesReceiptsOneRequest": ".accounting_salesreceiptsoneop", + "AccountingSalesReceiptsOneRequestTypedDict": ".accounting_salesreceiptsoneop", + "AccountingSalesReceiptsOneResponse": ".accounting_salesreceiptsoneop", + "AccountingSalesReceiptsOneResponseTypedDict": ".accounting_salesreceiptsoneop", + "AccountingSalesReceiptsUpdateGlobals": ".accounting_salesreceiptsupdateop", + "AccountingSalesReceiptsUpdateGlobalsTypedDict": ".accounting_salesreceiptsupdateop", + "AccountingSalesReceiptsUpdateRequest": ".accounting_salesreceiptsupdateop", + "AccountingSalesReceiptsUpdateRequestTypedDict": ".accounting_salesreceiptsupdateop", + "AccountingSalesReceiptsUpdateResponse": ".accounting_salesreceiptsupdateop", + "AccountingSalesReceiptsUpdateResponseTypedDict": ".accounting_salesreceiptsupdateop", "AccountingSubsidiariesAddGlobals": ".accounting_subsidiariesaddop", "AccountingSubsidiariesAddGlobalsTypedDict": ".accounting_subsidiariesaddop", "AccountingSubsidiariesAddRequest": ".accounting_subsidiariesaddop", @@ -9900,6 +10191,12 @@ "LocationStatus": ".accountinglocation", "AccountingLocationsFilter": ".accountinglocationsfilter", "AccountingLocationsFilterTypedDict": ".accountinglocationsfilter", + "AccountingPaymentMethod": ".accountingpaymentmethod", + "AccountingPaymentMethodInput": ".accountingpaymentmethod", + "AccountingPaymentMethodInputTypedDict": ".accountingpaymentmethod", + "AccountingPaymentMethodStatus": ".accountingpaymentmethod", + "AccountingPaymentMethodType": ".accountingpaymentmethod", + "AccountingPaymentMethodTypedDict": ".accountingpaymentmethod", "ActivitiesFilter": ".activitiesfilter", "ActivitiesFilterTypedDict": ".activitiesfilter", "ActivitiesSort": ".activitiessort", @@ -10440,6 +10737,8 @@ "CreateNoteResponseTypedDict": ".createnoteresponse", "CreateOpportunityResponse": ".createopportunityresponse", "CreateOpportunityResponseTypedDict": ".createopportunityresponse", + "CreatePaymentMethodResponse": ".createpaymentmethodresponse", + "CreatePaymentMethodResponseTypedDict": ".createpaymentmethodresponse", "CreatePaymentResponse": ".createpaymentresponse", "CreatePaymentResponseTypedDict": ".createpaymentresponse", "CreatePipelineResponse": ".createpipelineresponse", @@ -10452,6 +10751,8 @@ "CreateQuoteResponseTypedDict": ".createquoteresponse", "CreateRefundResponse": ".createrefundresponse", "CreateRefundResponseTypedDict": ".createrefundresponse", + "CreateSalesReceiptResponse": ".createsalesreceiptresponse", + "CreateSalesReceiptResponseTypedDict": ".createsalesreceiptresponse", "CreateSessionResponse": ".createsessionresponse", "CreateSessionResponseData": ".createsessionresponse", "CreateSessionResponseDataTypedDict": ".createsessionresponse", @@ -10946,6 +11247,8 @@ "DeleteNoteResponseTypedDict": ".deletenoteresponse", "DeleteOpportunityResponse": ".deleteopportunityresponse", "DeleteOpportunityResponseTypedDict": ".deleteopportunityresponse", + "DeletePaymentMethodResponse": ".deletepaymentmethodresponse", + "DeletePaymentMethodResponseTypedDict": ".deletepaymentmethodresponse", "DeletePaymentResponse": ".deletepaymentresponse", "DeletePaymentResponseTypedDict": ".deletepaymentresponse", "DeletePipelineResponse": ".deletepipelineresponse", @@ -10958,6 +11261,8 @@ "DeleteQuoteResponseTypedDict": ".deletequoteresponse", "DeleteRefundResponse": ".deleterefundresponse", "DeleteRefundResponseTypedDict": ".deleterefundresponse", + "DeleteSalesReceiptResponse": ".deletesalesreceiptresponse", + "DeleteSalesReceiptResponseTypedDict": ".deletesalesreceiptresponse", "DeleteSharedLinkResponse": ".deletesharedlinkresponse", "DeleteSharedLinkResponseTypedDict": ".deletesharedlinkresponse", "DeleteSubsidiaryResponse": ".deletesubsidiaryresponse", @@ -11625,6 +11930,10 @@ "GetOpportunitiesResponseTypedDict": ".getopportunitiesresponse", "GetOpportunityResponse": ".getopportunityresponse", "GetOpportunityResponseTypedDict": ".getopportunityresponse", + "GetPaymentMethodResponse": ".getpaymentmethodresponse", + "GetPaymentMethodResponseTypedDict": ".getpaymentmethodresponse", + "GetPaymentMethodsResponse": ".getpaymentmethodsresponse", + "GetPaymentMethodsResponseTypedDict": ".getpaymentmethodsresponse", "GetPaymentResponse": ".getpaymentresponse", "GetPaymentResponseTypedDict": ".getpaymentresponse", "GetPaymentsResponse": ".getpaymentsresponse", @@ -11659,6 +11968,10 @@ "GetRefundResponseTypedDict": ".getrefundresponse", "GetRefundsResponse": ".getrefundsresponse", "GetRefundsResponseTypedDict": ".getrefundsresponse", + "GetSalesReceiptResponse": ".getsalesreceiptresponse", + "GetSalesReceiptResponseTypedDict": ".getsalesreceiptresponse", + "GetSalesReceiptsResponse": ".getsalesreceiptsresponse", + "GetSalesReceiptsResponseTypedDict": ".getsalesreceiptsresponse", "GetSharedLinkResponse": ".getsharedlinkresponse", "GetSharedLinkResponseTypedDict": ".getsharedlinkresponse", "GetSharedLinksResponse": ".getsharedlinksresponse", @@ -12364,6 +12677,15 @@ "RequestCountAllocationTypedDict": ".requestcountallocation", "ResourceStatus": ".resourcestatus", "ResponseValidationError": ".responsevalidationerror", + "SalesReceipt": ".salesreceipt", + "SalesReceiptTypedDict": ".salesreceipt", + "SalesReceiptInput": ".salesreceipt_input", + "SalesReceiptInputTypedDict": ".salesreceipt_input", + "SalesReceiptsFilter": ".salesreceiptsfilter", + "SalesReceiptsFilterTypedDict": ".salesreceiptsfilter", + "SalesReceiptsSort": ".salesreceiptssort", + "SalesReceiptsSortBy": ".salesreceiptssort", + "SalesReceiptsSortTypedDict": ".salesreceiptssort", "EvenWeeks": ".schedule", "EvenWeeksTypedDict": ".schedule", "OddWeeks": ".schedule", @@ -12626,6 +12948,8 @@ "UpdateNoteResponseTypedDict": ".updatenoteresponse", "UpdateOpportunityResponse": ".updateopportunityresponse", "UpdateOpportunityResponseTypedDict": ".updateopportunityresponse", + "UpdatePaymentMethodResponse": ".updatepaymentmethodresponse", + "UpdatePaymentMethodResponseTypedDict": ".updatepaymentmethodresponse", "UpdatePaymentResponse": ".updatepaymentresponse", "UpdatePaymentResponseTypedDict": ".updatepaymentresponse", "UpdatePipelineResponse": ".updatepipelineresponse", @@ -12638,6 +12962,8 @@ "UpdateQuoteResponseTypedDict": ".updatequoteresponse", "UpdateRefundResponse": ".updaterefundresponse", "UpdateRefundResponseTypedDict": ".updaterefundresponse", + "UpdateSalesReceiptResponse": ".updatesalesreceiptresponse", + "UpdateSalesReceiptResponseTypedDict": ".updatesalesreceiptresponse", "UpdateSharedLinkResponse": ".updatesharedlinkresponse", "UpdateSharedLinkResponseTypedDict": ".updatesharedlinkresponse", "UpdateSubsidiaryResponse": ".updatesubsidiaryresponse", diff --git a/src/apideck_unify/models/accounting_attachmentsdownloadop.py b/src/apideck_unify/models/accounting_attachmentsdownloadop.py index 24055266..7917f2c5 100644 --- a/src/apideck_unify/models/accounting_attachmentsdownloadop.py +++ b/src/apideck_unify/models/accounting_attachmentsdownloadop.py @@ -70,6 +70,8 @@ class AccountingAttachmentsDownloadRequestTypedDict(TypedDict): r"""The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings.""" fields: NotRequired[Nullable[str]] r"""The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields \"name\", \"email\" and \"addresses.city\". If any other fields are available, they will be excluded.""" + follow_redirects: NotRequired[bool] + r"""Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior.""" class AccountingAttachmentsDownloadRequest(BaseModel): @@ -123,6 +125,13 @@ class AccountingAttachmentsDownloadRequest(BaseModel): ] = UNSET r"""The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields \"name\", \"email\" and \"addresses.city\". If any other fields are available, they will be excluded.""" + follow_redirects: Annotated[ + Optional[bool], + pydantic.Field(alias="x-apideck-follow-redirects"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = True + r"""Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior.""" + @field_serializer("reference_type") def serialize_reference_type(self, value): if isinstance(value, str): @@ -134,7 +143,14 @@ def serialize_reference_type(self, value): @model_serializer(mode="wrap") def serialize_model(self, handler): - optional_fields = ["consumerId", "appId", "serviceId", "companyId", "fields"] + optional_fields = [ + "consumerId", + "appId", + "serviceId", + "companyId", + "fields", + "followRedirects", + ] nullable_fields = ["fields"] null_default_fields = [] @@ -166,7 +182,7 @@ def serialize_model(self, handler): class AccountingAttachmentsDownloadResponseTypedDict(TypedDict): http_meta: HTTPMetadataTypedDict get_attachment_download_response: NotRequired[httpx.Response] - r"""Attachment Download""" + r"""Attachment Download. When the request includes `x-apideck-follow-redirects: false` and the download would otherwise redirect to a presigned URL, the response body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the attachment.""" unexpected_error_response: NotRequired[UnexpectedErrorResponseTypedDict] r"""Unexpected error""" @@ -175,7 +191,7 @@ class AccountingAttachmentsDownloadResponse(BaseModel): http_meta: Annotated[Optional[HTTPMetadata], pydantic.Field(exclude=True)] = None get_attachment_download_response: Optional[httpx.Response] = None - r"""Attachment Download""" + r"""Attachment Download. When the request includes `x-apideck-follow-redirects: false` and the download would otherwise redirect to a presigned URL, the response body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the attachment.""" unexpected_error_response: Optional[UnexpectedErrorResponse] = None r"""Unexpected error""" diff --git a/src/apideck_unify/models/accounting_paymentmethodsaddop.py b/src/apideck_unify/models/accounting_paymentmethodsaddop.py new file mode 100644 index 00000000..fb348a5f --- /dev/null +++ b/src/apideck_unify/models/accounting_paymentmethodsaddop.py @@ -0,0 +1,113 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .accountingpaymentmethod import ( + AccountingPaymentMethodInput, + AccountingPaymentMethodInputTypedDict, +) +from .createpaymentmethodresponse import ( + CreatePaymentMethodResponse, + CreatePaymentMethodResponseTypedDict, +) +from .httpmetadata import HTTPMetadata, HTTPMetadataTypedDict +from .unexpectederrorresponse import ( + UnexpectedErrorResponse, + UnexpectedErrorResponseTypedDict, +) +from apideck_unify.types import BaseModel +from apideck_unify.utils import ( + FieldMetadata, + HeaderMetadata, + QueryParamMetadata, + RequestMetadata, +) +import pydantic +from typing import Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class AccountingPaymentMethodsAddGlobalsTypedDict(TypedDict): + consumer_id: NotRequired[str] + r"""ID of the consumer which you want to get or push data from""" + app_id: NotRequired[str] + r"""The ID of your Unify application""" + + +class AccountingPaymentMethodsAddGlobals(BaseModel): + consumer_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-consumer-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""ID of the consumer which you want to get or push data from""" + + app_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-app-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""The ID of your Unify application""" + + +class AccountingPaymentMethodsAddRequestTypedDict(TypedDict): + accounting_payment_method: AccountingPaymentMethodInputTypedDict + raw: NotRequired[bool] + r"""Include raw response. Mostly used for debugging purposes""" + consumer_id: NotRequired[str] + r"""ID of the consumer which you want to get or push data from""" + app_id: NotRequired[str] + r"""The ID of your Unify application""" + service_id: NotRequired[str] + r"""Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.""" + + +class AccountingPaymentMethodsAddRequest(BaseModel): + accounting_payment_method: Annotated[ + AccountingPaymentMethodInput, + FieldMetadata(request=RequestMetadata(media_type="application/json")), + ] + + raw: Annotated[ + Optional[bool], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = False + r"""Include raw response. Mostly used for debugging purposes""" + + consumer_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-consumer-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""ID of the consumer which you want to get or push data from""" + + app_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-app-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""The ID of your Unify application""" + + service_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-service-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.""" + + +class AccountingPaymentMethodsAddResponseTypedDict(TypedDict): + http_meta: HTTPMetadataTypedDict + create_payment_method_response: NotRequired[CreatePaymentMethodResponseTypedDict] + r"""Payment Methods""" + unexpected_error_response: NotRequired[UnexpectedErrorResponseTypedDict] + r"""Unexpected error""" + + +class AccountingPaymentMethodsAddResponse(BaseModel): + http_meta: Annotated[Optional[HTTPMetadata], pydantic.Field(exclude=True)] = None + + create_payment_method_response: Optional[CreatePaymentMethodResponse] = None + r"""Payment Methods""" + + unexpected_error_response: Optional[UnexpectedErrorResponse] = None + r"""Unexpected error""" diff --git a/src/apideck_unify/models/accounting_paymentmethodsallop.py b/src/apideck_unify/models/accounting_paymentmethodsallop.py new file mode 100644 index 00000000..328ea5d9 --- /dev/null +++ b/src/apideck_unify/models/accounting_paymentmethodsallop.py @@ -0,0 +1,178 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .getpaymentmethodsresponse import ( + GetPaymentMethodsResponse, + GetPaymentMethodsResponseTypedDict, +) +from .httpmetadata import HTTPMetadata, HTTPMetadataTypedDict +from .unexpectederrorresponse import ( + UnexpectedErrorResponse, + UnexpectedErrorResponseTypedDict, +) +from apideck_unify.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +from apideck_unify.utils import FieldMetadata, HeaderMetadata, QueryParamMetadata +import pydantic +from pydantic import model_serializer +from typing import Any, Callable, Dict, Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class AccountingPaymentMethodsAllGlobalsTypedDict(TypedDict): + consumer_id: NotRequired[str] + r"""ID of the consumer which you want to get or push data from""" + app_id: NotRequired[str] + r"""The ID of your Unify application""" + + +class AccountingPaymentMethodsAllGlobals(BaseModel): + consumer_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-consumer-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""ID of the consumer which you want to get or push data from""" + + app_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-app-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""The ID of your Unify application""" + + +class AccountingPaymentMethodsAllRequestTypedDict(TypedDict): + raw: NotRequired[bool] + r"""Include raw response. Mostly used for debugging purposes""" + consumer_id: NotRequired[str] + r"""ID of the consumer which you want to get or push data from""" + app_id: NotRequired[str] + r"""The ID of your Unify application""" + service_id: NotRequired[str] + r"""Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.""" + cursor: NotRequired[Nullable[str]] + r"""Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response.""" + limit: NotRequired[int] + r"""Number of results to return. Minimum 1, Maximum 200, Default 20""" + fields: NotRequired[Nullable[str]] + r"""The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields \"name\", \"email\" and \"addresses.city\". If any other fields are available, they will be excluded.""" + pass_through: NotRequired[Dict[str, Any]] + r"""Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads""" + + +class AccountingPaymentMethodsAllRequest(BaseModel): + raw: Annotated[ + Optional[bool], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = False + r"""Include raw response. Mostly used for debugging purposes""" + + consumer_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-consumer-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""ID of the consumer which you want to get or push data from""" + + app_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-app-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""The ID of your Unify application""" + + service_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-service-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.""" + + cursor: Annotated[ + OptionalNullable[str], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = UNSET + r"""Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response.""" + + limit: Annotated[ + Optional[int], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = 20 + r"""Number of results to return. Minimum 1, Maximum 200, Default 20""" + + fields: Annotated[ + OptionalNullable[str], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = UNSET + r"""The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields \"name\", \"email\" and \"addresses.city\". If any other fields are available, they will be excluded.""" + + pass_through: Annotated[ + Optional[Dict[str, Any]], + FieldMetadata(query=QueryParamMetadata(style="deepObject", explode=True)), + ] = None + r"""Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = [ + "raw", + "consumerId", + "appId", + "serviceId", + "cursor", + "limit", + "fields", + "pass_through", + ] + nullable_fields = ["cursor", "fields"] + null_default_fields = [] + + serialized = handler(self) + + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k) + serialized.pop(k, None) + + optional_nullable = k in optional_fields and k in nullable_fields + is_set = ( + self.__pydantic_fields_set__.intersection({n}) + or k in null_default_fields + ) # pylint: disable=no-member + + if val is not None and val != UNSET_SENTINEL: + m[k] = val + elif val != UNSET_SENTINEL and ( + not k in optional_fields or (optional_nullable and is_set) + ): + m[k] = val + + return m + + +class AccountingPaymentMethodsAllResponseTypedDict(TypedDict): + http_meta: HTTPMetadataTypedDict + get_payment_methods_response: NotRequired[GetPaymentMethodsResponseTypedDict] + r"""Payment Methods""" + unexpected_error_response: NotRequired[UnexpectedErrorResponseTypedDict] + r"""Unexpected error""" + + +class AccountingPaymentMethodsAllResponse(BaseModel): + next: Callable[[], Optional[AccountingPaymentMethodsAllResponse]] + + http_meta: Annotated[Optional[HTTPMetadata], pydantic.Field(exclude=True)] = None + + get_payment_methods_response: Optional[GetPaymentMethodsResponse] = None + r"""Payment Methods""" + + unexpected_error_response: Optional[UnexpectedErrorResponse] = None + r"""Unexpected error""" diff --git a/src/apideck_unify/models/accounting_paymentmethodsdeleteop.py b/src/apideck_unify/models/accounting_paymentmethodsdeleteop.py new file mode 100644 index 00000000..5b478868 --- /dev/null +++ b/src/apideck_unify/models/accounting_paymentmethodsdeleteop.py @@ -0,0 +1,110 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .deletepaymentmethodresponse import ( + DeletePaymentMethodResponse, + DeletePaymentMethodResponseTypedDict, +) +from .httpmetadata import HTTPMetadata, HTTPMetadataTypedDict +from .unexpectederrorresponse import ( + UnexpectedErrorResponse, + UnexpectedErrorResponseTypedDict, +) +from apideck_unify.types import BaseModel +from apideck_unify.utils import ( + FieldMetadata, + HeaderMetadata, + PathParamMetadata, + QueryParamMetadata, +) +import pydantic +from typing import Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class AccountingPaymentMethodsDeleteGlobalsTypedDict(TypedDict): + consumer_id: NotRequired[str] + r"""ID of the consumer which you want to get or push data from""" + app_id: NotRequired[str] + r"""The ID of your Unify application""" + + +class AccountingPaymentMethodsDeleteGlobals(BaseModel): + consumer_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-consumer-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""ID of the consumer which you want to get or push data from""" + + app_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-app-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""The ID of your Unify application""" + + +class AccountingPaymentMethodsDeleteRequestTypedDict(TypedDict): + id: str + r"""ID of the record you are acting upon.""" + consumer_id: NotRequired[str] + r"""ID of the consumer which you want to get or push data from""" + app_id: NotRequired[str] + r"""The ID of your Unify application""" + service_id: NotRequired[str] + r"""Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.""" + raw: NotRequired[bool] + r"""Include raw response. Mostly used for debugging purposes""" + + +class AccountingPaymentMethodsDeleteRequest(BaseModel): + id: Annotated[ + str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False)) + ] + r"""ID of the record you are acting upon.""" + + consumer_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-consumer-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""ID of the consumer which you want to get or push data from""" + + app_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-app-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""The ID of your Unify application""" + + service_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-service-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.""" + + raw: Annotated[ + Optional[bool], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = False + r"""Include raw response. Mostly used for debugging purposes""" + + +class AccountingPaymentMethodsDeleteResponseTypedDict(TypedDict): + http_meta: HTTPMetadataTypedDict + delete_payment_method_response: NotRequired[DeletePaymentMethodResponseTypedDict] + r"""Payment Methods""" + unexpected_error_response: NotRequired[UnexpectedErrorResponseTypedDict] + r"""Unexpected error""" + + +class AccountingPaymentMethodsDeleteResponse(BaseModel): + http_meta: Annotated[Optional[HTTPMetadata], pydantic.Field(exclude=True)] = None + + delete_payment_method_response: Optional[DeletePaymentMethodResponse] = None + r"""Payment Methods""" + + unexpected_error_response: Optional[UnexpectedErrorResponse] = None + r"""Unexpected error""" diff --git a/src/apideck_unify/models/accounting_paymentmethodsoneop.py b/src/apideck_unify/models/accounting_paymentmethodsoneop.py new file mode 100644 index 00000000..7ccce7a9 --- /dev/null +++ b/src/apideck_unify/models/accounting_paymentmethodsoneop.py @@ -0,0 +1,155 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .getpaymentmethodresponse import ( + GetPaymentMethodResponse, + GetPaymentMethodResponseTypedDict, +) +from .httpmetadata import HTTPMetadata, HTTPMetadataTypedDict +from .unexpectederrorresponse import ( + UnexpectedErrorResponse, + UnexpectedErrorResponseTypedDict, +) +from apideck_unify.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +from apideck_unify.utils import ( + FieldMetadata, + HeaderMetadata, + PathParamMetadata, + QueryParamMetadata, +) +import pydantic +from pydantic import model_serializer +from typing import Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class AccountingPaymentMethodsOneGlobalsTypedDict(TypedDict): + consumer_id: NotRequired[str] + r"""ID of the consumer which you want to get or push data from""" + app_id: NotRequired[str] + r"""The ID of your Unify application""" + + +class AccountingPaymentMethodsOneGlobals(BaseModel): + consumer_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-consumer-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""ID of the consumer which you want to get or push data from""" + + app_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-app-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""The ID of your Unify application""" + + +class AccountingPaymentMethodsOneRequestTypedDict(TypedDict): + id: str + r"""ID of the record you are acting upon.""" + consumer_id: NotRequired[str] + r"""ID of the consumer which you want to get or push data from""" + app_id: NotRequired[str] + r"""The ID of your Unify application""" + service_id: NotRequired[str] + r"""Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.""" + raw: NotRequired[bool] + r"""Include raw response. Mostly used for debugging purposes""" + fields: NotRequired[Nullable[str]] + r"""The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields \"name\", \"email\" and \"addresses.city\". If any other fields are available, they will be excluded.""" + + +class AccountingPaymentMethodsOneRequest(BaseModel): + id: Annotated[ + str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False)) + ] + r"""ID of the record you are acting upon.""" + + consumer_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-consumer-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""ID of the consumer which you want to get or push data from""" + + app_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-app-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""The ID of your Unify application""" + + service_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-service-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.""" + + raw: Annotated[ + Optional[bool], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = False + r"""Include raw response. Mostly used for debugging purposes""" + + fields: Annotated[ + OptionalNullable[str], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = UNSET + r"""The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields \"name\", \"email\" and \"addresses.city\". If any other fields are available, they will be excluded.""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = ["consumerId", "appId", "serviceId", "raw", "fields"] + nullable_fields = ["fields"] + null_default_fields = [] + + serialized = handler(self) + + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k) + serialized.pop(k, None) + + optional_nullable = k in optional_fields and k in nullable_fields + is_set = ( + self.__pydantic_fields_set__.intersection({n}) + or k in null_default_fields + ) # pylint: disable=no-member + + if val is not None and val != UNSET_SENTINEL: + m[k] = val + elif val != UNSET_SENTINEL and ( + not k in optional_fields or (optional_nullable and is_set) + ): + m[k] = val + + return m + + +class AccountingPaymentMethodsOneResponseTypedDict(TypedDict): + http_meta: HTTPMetadataTypedDict + get_payment_method_response: NotRequired[GetPaymentMethodResponseTypedDict] + r"""Payment Methods""" + unexpected_error_response: NotRequired[UnexpectedErrorResponseTypedDict] + r"""Unexpected error""" + + +class AccountingPaymentMethodsOneResponse(BaseModel): + http_meta: Annotated[Optional[HTTPMetadata], pydantic.Field(exclude=True)] = None + + get_payment_method_response: Optional[GetPaymentMethodResponse] = None + r"""Payment Methods""" + + unexpected_error_response: Optional[UnexpectedErrorResponse] = None + r"""Unexpected error""" diff --git a/src/apideck_unify/models/accounting_paymentmethodsupdateop.py b/src/apideck_unify/models/accounting_paymentmethodsupdateop.py new file mode 100644 index 00000000..b9f0b0c6 --- /dev/null +++ b/src/apideck_unify/models/accounting_paymentmethodsupdateop.py @@ -0,0 +1,121 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .accountingpaymentmethod import ( + AccountingPaymentMethodInput, + AccountingPaymentMethodInputTypedDict, +) +from .httpmetadata import HTTPMetadata, HTTPMetadataTypedDict +from .unexpectederrorresponse import ( + UnexpectedErrorResponse, + UnexpectedErrorResponseTypedDict, +) +from .updatepaymentmethodresponse import ( + UpdatePaymentMethodResponse, + UpdatePaymentMethodResponseTypedDict, +) +from apideck_unify.types import BaseModel +from apideck_unify.utils import ( + FieldMetadata, + HeaderMetadata, + PathParamMetadata, + QueryParamMetadata, + RequestMetadata, +) +import pydantic +from typing import Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class AccountingPaymentMethodsUpdateGlobalsTypedDict(TypedDict): + consumer_id: NotRequired[str] + r"""ID of the consumer which you want to get or push data from""" + app_id: NotRequired[str] + r"""The ID of your Unify application""" + + +class AccountingPaymentMethodsUpdateGlobals(BaseModel): + consumer_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-consumer-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""ID of the consumer which you want to get or push data from""" + + app_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-app-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""The ID of your Unify application""" + + +class AccountingPaymentMethodsUpdateRequestTypedDict(TypedDict): + id: str + r"""ID of the record you are acting upon.""" + accounting_payment_method: AccountingPaymentMethodInputTypedDict + consumer_id: NotRequired[str] + r"""ID of the consumer which you want to get or push data from""" + app_id: NotRequired[str] + r"""The ID of your Unify application""" + service_id: NotRequired[str] + r"""Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.""" + raw: NotRequired[bool] + r"""Include raw response. Mostly used for debugging purposes""" + + +class AccountingPaymentMethodsUpdateRequest(BaseModel): + id: Annotated[ + str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False)) + ] + r"""ID of the record you are acting upon.""" + + accounting_payment_method: Annotated[ + AccountingPaymentMethodInput, + FieldMetadata(request=RequestMetadata(media_type="application/json")), + ] + + consumer_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-consumer-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""ID of the consumer which you want to get or push data from""" + + app_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-app-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""The ID of your Unify application""" + + service_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-service-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.""" + + raw: Annotated[ + Optional[bool], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = False + r"""Include raw response. Mostly used for debugging purposes""" + + +class AccountingPaymentMethodsUpdateResponseTypedDict(TypedDict): + http_meta: HTTPMetadataTypedDict + update_payment_method_response: NotRequired[UpdatePaymentMethodResponseTypedDict] + r"""Payment Methods""" + unexpected_error_response: NotRequired[UnexpectedErrorResponseTypedDict] + r"""Unexpected error""" + + +class AccountingPaymentMethodsUpdateResponse(BaseModel): + http_meta: Annotated[Optional[HTTPMetadata], pydantic.Field(exclude=True)] = None + + update_payment_method_response: Optional[UpdatePaymentMethodResponse] = None + r"""Payment Methods""" + + unexpected_error_response: Optional[UnexpectedErrorResponse] = None + r"""Unexpected error""" diff --git a/src/apideck_unify/models/accounting_salesreceiptsaddop.py b/src/apideck_unify/models/accounting_salesreceiptsaddop.py new file mode 100644 index 00000000..1b426395 --- /dev/null +++ b/src/apideck_unify/models/accounting_salesreceiptsaddop.py @@ -0,0 +1,119 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .createsalesreceiptresponse import ( + CreateSalesReceiptResponse, + CreateSalesReceiptResponseTypedDict, +) +from .httpmetadata import HTTPMetadata, HTTPMetadataTypedDict +from .salesreceipt_input import SalesReceiptInput, SalesReceiptInputTypedDict +from .unexpectederrorresponse import ( + UnexpectedErrorResponse, + UnexpectedErrorResponseTypedDict, +) +from apideck_unify.types import BaseModel +from apideck_unify.utils import ( + FieldMetadata, + HeaderMetadata, + QueryParamMetadata, + RequestMetadata, +) +import pydantic +from typing import Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class AccountingSalesReceiptsAddGlobalsTypedDict(TypedDict): + consumer_id: NotRequired[str] + r"""ID of the consumer which you want to get or push data from""" + app_id: NotRequired[str] + r"""The ID of your Unify application""" + + +class AccountingSalesReceiptsAddGlobals(BaseModel): + consumer_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-consumer-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""ID of the consumer which you want to get or push data from""" + + app_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-app-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""The ID of your Unify application""" + + +class AccountingSalesReceiptsAddRequestTypedDict(TypedDict): + sales_receipt: SalesReceiptInputTypedDict + raw: NotRequired[bool] + r"""Include raw response. Mostly used for debugging purposes""" + consumer_id: NotRequired[str] + r"""ID of the consumer which you want to get or push data from""" + app_id: NotRequired[str] + r"""The ID of your Unify application""" + service_id: NotRequired[str] + r"""Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.""" + company_id: NotRequired[str] + r"""The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings.""" + + +class AccountingSalesReceiptsAddRequest(BaseModel): + sales_receipt: Annotated[ + SalesReceiptInput, + FieldMetadata(request=RequestMetadata(media_type="application/json")), + ] + + raw: Annotated[ + Optional[bool], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = False + r"""Include raw response. Mostly used for debugging purposes""" + + consumer_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-consumer-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""ID of the consumer which you want to get or push data from""" + + app_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-app-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""The ID of your Unify application""" + + service_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-service-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.""" + + company_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-company-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings.""" + + +class AccountingSalesReceiptsAddResponseTypedDict(TypedDict): + http_meta: HTTPMetadataTypedDict + create_sales_receipt_response: NotRequired[CreateSalesReceiptResponseTypedDict] + r"""SalesReceipt created""" + unexpected_error_response: NotRequired[UnexpectedErrorResponseTypedDict] + r"""Unexpected error""" + + +class AccountingSalesReceiptsAddResponse(BaseModel): + http_meta: Annotated[Optional[HTTPMetadata], pydantic.Field(exclude=True)] = None + + create_sales_receipt_response: Optional[CreateSalesReceiptResponse] = None + r"""SalesReceipt created""" + + unexpected_error_response: Optional[UnexpectedErrorResponse] = None + r"""Unexpected error""" diff --git a/src/apideck_unify/models/accounting_salesreceiptsallop.py b/src/apideck_unify/models/accounting_salesreceiptsallop.py new file mode 100644 index 00000000..b63df650 --- /dev/null +++ b/src/apideck_unify/models/accounting_salesreceiptsallop.py @@ -0,0 +1,209 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .getsalesreceiptsresponse import ( + GetSalesReceiptsResponse, + GetSalesReceiptsResponseTypedDict, +) +from .httpmetadata import HTTPMetadata, HTTPMetadataTypedDict +from .salesreceiptsfilter import SalesReceiptsFilter, SalesReceiptsFilterTypedDict +from .salesreceiptssort import SalesReceiptsSort, SalesReceiptsSortTypedDict +from .unexpectederrorresponse import ( + UnexpectedErrorResponse, + UnexpectedErrorResponseTypedDict, +) +from apideck_unify.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +from apideck_unify.utils import FieldMetadata, HeaderMetadata, QueryParamMetadata +import pydantic +from pydantic import model_serializer +from typing import Any, Callable, Dict, Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class AccountingSalesReceiptsAllGlobalsTypedDict(TypedDict): + consumer_id: NotRequired[str] + r"""ID of the consumer which you want to get or push data from""" + app_id: NotRequired[str] + r"""The ID of your Unify application""" + + +class AccountingSalesReceiptsAllGlobals(BaseModel): + consumer_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-consumer-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""ID of the consumer which you want to get or push data from""" + + app_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-app-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""The ID of your Unify application""" + + +class AccountingSalesReceiptsAllRequestTypedDict(TypedDict): + raw: NotRequired[bool] + r"""Include raw response. Mostly used for debugging purposes""" + consumer_id: NotRequired[str] + r"""ID of the consumer which you want to get or push data from""" + app_id: NotRequired[str] + r"""The ID of your Unify application""" + service_id: NotRequired[str] + r"""Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.""" + company_id: NotRequired[str] + r"""The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings.""" + cursor: NotRequired[Nullable[str]] + r"""Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response.""" + limit: NotRequired[int] + r"""Number of results to return. Minimum 1, Maximum 200, Default 20""" + filter_: NotRequired[SalesReceiptsFilterTypedDict] + r"""Apply filters""" + sort: NotRequired[SalesReceiptsSortTypedDict] + r"""Apply sorting""" + pass_through: NotRequired[Dict[str, Any]] + r"""Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads""" + fields: NotRequired[Nullable[str]] + r"""The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields \"name\", \"email\" and \"addresses.city\". If any other fields are available, they will be excluded.""" + + +class AccountingSalesReceiptsAllRequest(BaseModel): + raw: Annotated[ + Optional[bool], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = False + r"""Include raw response. Mostly used for debugging purposes""" + + consumer_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-consumer-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""ID of the consumer which you want to get or push data from""" + + app_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-app-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""The ID of your Unify application""" + + service_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-service-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.""" + + company_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-company-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings.""" + + cursor: Annotated[ + OptionalNullable[str], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = UNSET + r"""Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response.""" + + limit: Annotated[ + Optional[int], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = 20 + r"""Number of results to return. Minimum 1, Maximum 200, Default 20""" + + filter_: Annotated[ + Optional[SalesReceiptsFilter], + pydantic.Field(alias="filter"), + FieldMetadata(query=QueryParamMetadata(style="deepObject", explode=True)), + ] = None + r"""Apply filters""" + + sort: Annotated[ + Optional[SalesReceiptsSort], + FieldMetadata(query=QueryParamMetadata(style="deepObject", explode=True)), + ] = None + r"""Apply sorting""" + + pass_through: Annotated[ + Optional[Dict[str, Any]], + FieldMetadata(query=QueryParamMetadata(style="deepObject", explode=True)), + ] = None + r"""Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads""" + + fields: Annotated[ + OptionalNullable[str], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = UNSET + r"""The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields \"name\", \"email\" and \"addresses.city\". If any other fields are available, they will be excluded.""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = [ + "raw", + "consumerId", + "appId", + "serviceId", + "companyId", + "cursor", + "limit", + "filter", + "sort", + "pass_through", + "fields", + ] + nullable_fields = ["cursor", "fields"] + null_default_fields = [] + + serialized = handler(self) + + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k) + serialized.pop(k, None) + + optional_nullable = k in optional_fields and k in nullable_fields + is_set = ( + self.__pydantic_fields_set__.intersection({n}) + or k in null_default_fields + ) # pylint: disable=no-member + + if val is not None and val != UNSET_SENTINEL: + m[k] = val + elif val != UNSET_SENTINEL and ( + not k in optional_fields or (optional_nullable and is_set) + ): + m[k] = val + + return m + + +class AccountingSalesReceiptsAllResponseTypedDict(TypedDict): + http_meta: HTTPMetadataTypedDict + get_sales_receipts_response: NotRequired[GetSalesReceiptsResponseTypedDict] + r"""SalesReceipts""" + unexpected_error_response: NotRequired[UnexpectedErrorResponseTypedDict] + r"""Unexpected error""" + + +class AccountingSalesReceiptsAllResponse(BaseModel): + next: Callable[[], Optional[AccountingSalesReceiptsAllResponse]] + + http_meta: Annotated[Optional[HTTPMetadata], pydantic.Field(exclude=True)] = None + + get_sales_receipts_response: Optional[GetSalesReceiptsResponse] = None + r"""SalesReceipts""" + + unexpected_error_response: Optional[UnexpectedErrorResponse] = None + r"""Unexpected error""" diff --git a/src/apideck_unify/models/accounting_salesreceiptsdeleteop.py b/src/apideck_unify/models/accounting_salesreceiptsdeleteop.py new file mode 100644 index 00000000..1be56dbf --- /dev/null +++ b/src/apideck_unify/models/accounting_salesreceiptsdeleteop.py @@ -0,0 +1,119 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .deletesalesreceiptresponse import ( + DeleteSalesReceiptResponse, + DeleteSalesReceiptResponseTypedDict, +) +from .httpmetadata import HTTPMetadata, HTTPMetadataTypedDict +from .unexpectederrorresponse import ( + UnexpectedErrorResponse, + UnexpectedErrorResponseTypedDict, +) +from apideck_unify.types import BaseModel +from apideck_unify.utils import ( + FieldMetadata, + HeaderMetadata, + PathParamMetadata, + QueryParamMetadata, +) +import pydantic +from typing import Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class AccountingSalesReceiptsDeleteGlobalsTypedDict(TypedDict): + consumer_id: NotRequired[str] + r"""ID of the consumer which you want to get or push data from""" + app_id: NotRequired[str] + r"""The ID of your Unify application""" + + +class AccountingSalesReceiptsDeleteGlobals(BaseModel): + consumer_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-consumer-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""ID of the consumer which you want to get or push data from""" + + app_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-app-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""The ID of your Unify application""" + + +class AccountingSalesReceiptsDeleteRequestTypedDict(TypedDict): + id: str + r"""ID of the record you are acting upon.""" + consumer_id: NotRequired[str] + r"""ID of the consumer which you want to get or push data from""" + app_id: NotRequired[str] + r"""The ID of your Unify application""" + service_id: NotRequired[str] + r"""Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.""" + raw: NotRequired[bool] + r"""Include raw response. Mostly used for debugging purposes""" + company_id: NotRequired[str] + r"""The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings.""" + + +class AccountingSalesReceiptsDeleteRequest(BaseModel): + id: Annotated[ + str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False)) + ] + r"""ID of the record you are acting upon.""" + + consumer_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-consumer-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""ID of the consumer which you want to get or push data from""" + + app_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-app-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""The ID of your Unify application""" + + service_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-service-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.""" + + raw: Annotated[ + Optional[bool], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = False + r"""Include raw response. Mostly used for debugging purposes""" + + company_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-company-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings.""" + + +class AccountingSalesReceiptsDeleteResponseTypedDict(TypedDict): + http_meta: HTTPMetadataTypedDict + delete_sales_receipt_response: NotRequired[DeleteSalesReceiptResponseTypedDict] + r"""SalesReceipt deleted""" + unexpected_error_response: NotRequired[UnexpectedErrorResponseTypedDict] + r"""Unexpected error""" + + +class AccountingSalesReceiptsDeleteResponse(BaseModel): + http_meta: Annotated[Optional[HTTPMetadata], pydantic.Field(exclude=True)] = None + + delete_sales_receipt_response: Optional[DeleteSalesReceiptResponse] = None + r"""SalesReceipt deleted""" + + unexpected_error_response: Optional[UnexpectedErrorResponse] = None + r"""Unexpected error""" diff --git a/src/apideck_unify/models/accounting_salesreceiptsoneop.py b/src/apideck_unify/models/accounting_salesreceiptsoneop.py new file mode 100644 index 00000000..9c94ff8c --- /dev/null +++ b/src/apideck_unify/models/accounting_salesreceiptsoneop.py @@ -0,0 +1,171 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .getsalesreceiptresponse import ( + GetSalesReceiptResponse, + GetSalesReceiptResponseTypedDict, +) +from .httpmetadata import HTTPMetadata, HTTPMetadataTypedDict +from .unexpectederrorresponse import ( + UnexpectedErrorResponse, + UnexpectedErrorResponseTypedDict, +) +from apideck_unify.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +from apideck_unify.utils import ( + FieldMetadata, + HeaderMetadata, + PathParamMetadata, + QueryParamMetadata, +) +import pydantic +from pydantic import model_serializer +from typing import Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class AccountingSalesReceiptsOneGlobalsTypedDict(TypedDict): + consumer_id: NotRequired[str] + r"""ID of the consumer which you want to get or push data from""" + app_id: NotRequired[str] + r"""The ID of your Unify application""" + + +class AccountingSalesReceiptsOneGlobals(BaseModel): + consumer_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-consumer-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""ID of the consumer which you want to get or push data from""" + + app_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-app-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""The ID of your Unify application""" + + +class AccountingSalesReceiptsOneRequestTypedDict(TypedDict): + id: str + r"""ID of the record you are acting upon.""" + consumer_id: NotRequired[str] + r"""ID of the consumer which you want to get or push data from""" + app_id: NotRequired[str] + r"""The ID of your Unify application""" + service_id: NotRequired[str] + r"""Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.""" + company_id: NotRequired[str] + r"""The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings.""" + raw: NotRequired[bool] + r"""Include raw response. Mostly used for debugging purposes""" + fields: NotRequired[Nullable[str]] + r"""The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields \"name\", \"email\" and \"addresses.city\". If any other fields are available, they will be excluded.""" + + +class AccountingSalesReceiptsOneRequest(BaseModel): + id: Annotated[ + str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False)) + ] + r"""ID of the record you are acting upon.""" + + consumer_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-consumer-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""ID of the consumer which you want to get or push data from""" + + app_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-app-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""The ID of your Unify application""" + + service_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-service-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.""" + + company_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-company-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings.""" + + raw: Annotated[ + Optional[bool], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = False + r"""Include raw response. Mostly used for debugging purposes""" + + fields: Annotated[ + OptionalNullable[str], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = UNSET + r"""The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields \"name\", \"email\" and \"addresses.city\". If any other fields are available, they will be excluded.""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = [ + "consumerId", + "appId", + "serviceId", + "companyId", + "raw", + "fields", + ] + nullable_fields = ["fields"] + null_default_fields = [] + + serialized = handler(self) + + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k) + serialized.pop(k, None) + + optional_nullable = k in optional_fields and k in nullable_fields + is_set = ( + self.__pydantic_fields_set__.intersection({n}) + or k in null_default_fields + ) # pylint: disable=no-member + + if val is not None and val != UNSET_SENTINEL: + m[k] = val + elif val != UNSET_SENTINEL and ( + not k in optional_fields or (optional_nullable and is_set) + ): + m[k] = val + + return m + + +class AccountingSalesReceiptsOneResponseTypedDict(TypedDict): + http_meta: HTTPMetadataTypedDict + get_sales_receipt_response: NotRequired[GetSalesReceiptResponseTypedDict] + r"""SalesReceipt""" + unexpected_error_response: NotRequired[UnexpectedErrorResponseTypedDict] + r"""Unexpected error""" + + +class AccountingSalesReceiptsOneResponse(BaseModel): + http_meta: Annotated[Optional[HTTPMetadata], pydantic.Field(exclude=True)] = None + + get_sales_receipt_response: Optional[GetSalesReceiptResponse] = None + r"""SalesReceipt""" + + unexpected_error_response: Optional[UnexpectedErrorResponse] = None + r"""Unexpected error""" diff --git a/src/apideck_unify/models/accounting_salesreceiptsupdateop.py b/src/apideck_unify/models/accounting_salesreceiptsupdateop.py new file mode 100644 index 00000000..6c524601 --- /dev/null +++ b/src/apideck_unify/models/accounting_salesreceiptsupdateop.py @@ -0,0 +1,127 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .httpmetadata import HTTPMetadata, HTTPMetadataTypedDict +from .salesreceipt_input import SalesReceiptInput, SalesReceiptInputTypedDict +from .unexpectederrorresponse import ( + UnexpectedErrorResponse, + UnexpectedErrorResponseTypedDict, +) +from .updatesalesreceiptresponse import ( + UpdateSalesReceiptResponse, + UpdateSalesReceiptResponseTypedDict, +) +from apideck_unify.types import BaseModel +from apideck_unify.utils import ( + FieldMetadata, + HeaderMetadata, + PathParamMetadata, + QueryParamMetadata, + RequestMetadata, +) +import pydantic +from typing import Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class AccountingSalesReceiptsUpdateGlobalsTypedDict(TypedDict): + consumer_id: NotRequired[str] + r"""ID of the consumer which you want to get or push data from""" + app_id: NotRequired[str] + r"""The ID of your Unify application""" + + +class AccountingSalesReceiptsUpdateGlobals(BaseModel): + consumer_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-consumer-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""ID of the consumer which you want to get or push data from""" + + app_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-app-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""The ID of your Unify application""" + + +class AccountingSalesReceiptsUpdateRequestTypedDict(TypedDict): + id: str + r"""ID of the record you are acting upon.""" + sales_receipt: SalesReceiptInputTypedDict + consumer_id: NotRequired[str] + r"""ID of the consumer which you want to get or push data from""" + app_id: NotRequired[str] + r"""The ID of your Unify application""" + service_id: NotRequired[str] + r"""Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.""" + raw: NotRequired[bool] + r"""Include raw response. Mostly used for debugging purposes""" + company_id: NotRequired[str] + r"""The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings.""" + + +class AccountingSalesReceiptsUpdateRequest(BaseModel): + id: Annotated[ + str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False)) + ] + r"""ID of the record you are acting upon.""" + + sales_receipt: Annotated[ + SalesReceiptInput, + FieldMetadata(request=RequestMetadata(media_type="application/json")), + ] + + consumer_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-consumer-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""ID of the consumer which you want to get or push data from""" + + app_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-app-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""The ID of your Unify application""" + + service_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-service-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.""" + + raw: Annotated[ + Optional[bool], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = False + r"""Include raw response. Mostly used for debugging purposes""" + + company_id: Annotated[ + Optional[str], + pydantic.Field(alias="x-apideck-company-id"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = None + r"""The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings.""" + + +class AccountingSalesReceiptsUpdateResponseTypedDict(TypedDict): + http_meta: HTTPMetadataTypedDict + update_sales_receipt_response: NotRequired[UpdateSalesReceiptResponseTypedDict] + r"""SalesReceipt updated""" + unexpected_error_response: NotRequired[UnexpectedErrorResponseTypedDict] + r"""Unexpected error""" + + +class AccountingSalesReceiptsUpdateResponse(BaseModel): + http_meta: Annotated[Optional[HTTPMetadata], pydantic.Field(exclude=True)] = None + + update_sales_receipt_response: Optional[UpdateSalesReceiptResponse] = None + r"""SalesReceipt updated""" + + unexpected_error_response: Optional[UnexpectedErrorResponse] = None + r"""Unexpected error""" diff --git a/src/apideck_unify/models/accountingpaymentmethod.py b/src/apideck_unify/models/accountingpaymentmethod.py new file mode 100644 index 00000000..73840542 --- /dev/null +++ b/src/apideck_unify/models/accountingpaymentmethod.py @@ -0,0 +1,265 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .passthroughbody import PassThroughBody, PassThroughBodyTypedDict +from apideck_unify import models, utils +from apideck_unify.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +from apideck_unify.utils import validate_open_enum +from datetime import datetime +from enum import Enum +from pydantic import field_serializer, model_serializer +from pydantic.functional_validators import PlainValidator +from typing import Any, Dict, List, Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class AccountingPaymentMethodType(str, Enum, metaclass=utils.OpenEnumMeta): + r"""The type of payment method.""" + + CASH = "cash" + CHECK = "check" + CREDIT_CARD = "credit_card" + DEBIT_CARD = "debit_card" + BANK_TRANSFER = "bank_transfer" + ELECTRONIC = "electronic" + OTHER = "other" + UNKNOWN = "unknown" + + +class AccountingPaymentMethodStatus(str, Enum, metaclass=utils.OpenEnumMeta): + r"""The status of the payment method.""" + + ACTIVE = "active" + INACTIVE = "inactive" + + +class AccountingPaymentMethodTypedDict(TypedDict): + id: NotRequired[str] + r"""A unique identifier for an object.""" + name: NotRequired[str] + r"""The name of the payment method.""" + type: NotRequired[Nullable[AccountingPaymentMethodType]] + r"""The type of payment method.""" + status: NotRequired[Nullable[AccountingPaymentMethodStatus]] + r"""The status of the payment method.""" + custom_mappings: NotRequired[Nullable[Dict[str, Any]]] + r"""When custom mappings are configured on the resource, the result is included here.""" + downstream_id: NotRequired[Nullable[str]] + r"""The third-party API ID of original entity""" + row_version: NotRequired[Nullable[str]] + r"""A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object.""" + updated_by: NotRequired[Nullable[str]] + r"""The user who last updated the object.""" + created_by: NotRequired[Nullable[str]] + r"""The user who created the object.""" + updated_at: NotRequired[Nullable[datetime]] + r"""The date and time when the object was last updated.""" + created_at: NotRequired[Nullable[datetime]] + r"""The date and time when the object was created.""" + pass_through: NotRequired[List[PassThroughBodyTypedDict]] + r"""The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources.""" + + +class AccountingPaymentMethod(BaseModel): + id: Optional[str] = None + r"""A unique identifier for an object.""" + + name: Optional[str] = None + r"""The name of the payment method.""" + + type: Annotated[ + OptionalNullable[AccountingPaymentMethodType], + PlainValidator(validate_open_enum(False)), + ] = UNSET + r"""The type of payment method.""" + + status: Annotated[ + OptionalNullable[AccountingPaymentMethodStatus], + PlainValidator(validate_open_enum(False)), + ] = UNSET + r"""The status of the payment method.""" + + custom_mappings: OptionalNullable[Dict[str, Any]] = UNSET + r"""When custom mappings are configured on the resource, the result is included here.""" + + downstream_id: OptionalNullable[str] = UNSET + r"""The third-party API ID of original entity""" + + row_version: OptionalNullable[str] = UNSET + r"""A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object.""" + + updated_by: OptionalNullable[str] = UNSET + r"""The user who last updated the object.""" + + created_by: OptionalNullable[str] = UNSET + r"""The user who created the object.""" + + updated_at: OptionalNullable[datetime] = UNSET + r"""The date and time when the object was last updated.""" + + created_at: OptionalNullable[datetime] = UNSET + r"""The date and time when the object was created.""" + + pass_through: Optional[List[PassThroughBody]] = None + r"""The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources.""" + + @field_serializer("type") + def serialize_type(self, value): + if isinstance(value, str): + try: + return models.AccountingPaymentMethodType(value) + except ValueError: + return value + return value + + @field_serializer("status") + def serialize_status(self, value): + if isinstance(value, str): + try: + return models.AccountingPaymentMethodStatus(value) + except ValueError: + return value + return value + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = [ + "id", + "name", + "type", + "status", + "custom_mappings", + "downstream_id", + "row_version", + "updated_by", + "created_by", + "updated_at", + "created_at", + "pass_through", + ] + nullable_fields = [ + "type", + "status", + "custom_mappings", + "downstream_id", + "row_version", + "updated_by", + "created_by", + "updated_at", + "created_at", + ] + null_default_fields = [] + + serialized = handler(self) + + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k) + serialized.pop(k, None) + + optional_nullable = k in optional_fields and k in nullable_fields + is_set = ( + self.__pydantic_fields_set__.intersection({n}) + or k in null_default_fields + ) # pylint: disable=no-member + + if val is not None and val != UNSET_SENTINEL: + m[k] = val + elif val != UNSET_SENTINEL and ( + not k in optional_fields or (optional_nullable and is_set) + ): + m[k] = val + + return m + + +class AccountingPaymentMethodInputTypedDict(TypedDict): + name: NotRequired[str] + r"""The name of the payment method.""" + type: NotRequired[Nullable[AccountingPaymentMethodType]] + r"""The type of payment method.""" + status: NotRequired[Nullable[AccountingPaymentMethodStatus]] + r"""The status of the payment method.""" + row_version: NotRequired[Nullable[str]] + r"""A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object.""" + pass_through: NotRequired[List[PassThroughBodyTypedDict]] + r"""The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources.""" + + +class AccountingPaymentMethodInput(BaseModel): + name: Optional[str] = None + r"""The name of the payment method.""" + + type: Annotated[ + OptionalNullable[AccountingPaymentMethodType], + PlainValidator(validate_open_enum(False)), + ] = UNSET + r"""The type of payment method.""" + + status: Annotated[ + OptionalNullable[AccountingPaymentMethodStatus], + PlainValidator(validate_open_enum(False)), + ] = UNSET + r"""The status of the payment method.""" + + row_version: OptionalNullable[str] = UNSET + r"""A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object.""" + + pass_through: Optional[List[PassThroughBody]] = None + r"""The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources.""" + + @field_serializer("type") + def serialize_type(self, value): + if isinstance(value, str): + try: + return models.AccountingPaymentMethodType(value) + except ValueError: + return value + return value + + @field_serializer("status") + def serialize_status(self, value): + if isinstance(value, str): + try: + return models.AccountingPaymentMethodStatus(value) + except ValueError: + return value + return value + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = ["name", "type", "status", "row_version", "pass_through"] + nullable_fields = ["type", "status", "row_version"] + null_default_fields = [] + + serialized = handler(self) + + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k) + serialized.pop(k, None) + + optional_nullable = k in optional_fields and k in nullable_fields + is_set = ( + self.__pydantic_fields_set__.intersection({n}) + or k in null_default_fields + ) # pylint: disable=no-member + + if val is not None and val != UNSET_SENTINEL: + m[k] = val + elif val != UNSET_SENTINEL and ( + not k in optional_fields or (optional_nullable and is_set) + ): + m[k] = val + + return m diff --git a/src/apideck_unify/models/attachment.py b/src/apideck_unify/models/attachment.py index c27a37c0..67dee5a6 100644 --- a/src/apideck_unify/models/attachment.py +++ b/src/apideck_unify/models/attachment.py @@ -30,6 +30,8 @@ class AttachmentTypedDict(TypedDict): reference: NotRequired[AttachmentReferenceTypedDict] description: NotRequired[Nullable[str]] r"""Optional description of the file""" + file_url: NotRequired[Nullable[str]] + r"""The URL to download or preview the file""" parent_folder_id: NotRequired[Nullable[str]] r"""The folder id where this attachment belong to""" updated_by: NotRequired[Nullable[str]] @@ -65,6 +67,9 @@ class Attachment(BaseModel): description: OptionalNullable[str] = UNSET r"""Optional description of the file""" + file_url: OptionalNullable[str] = UNSET + r"""The URL to download or preview the file""" + parent_folder_id: OptionalNullable[str] = UNSET r"""The folder id where this attachment belong to""" @@ -93,6 +98,7 @@ def serialize_model(self, handler): "size", "reference", "description", + "file_url", "parent_folder_id", "updated_by", "created_by", @@ -106,6 +112,7 @@ def serialize_model(self, handler): "mime_type", "size", "description", + "file_url", "parent_folder_id", "updated_by", "created_by", diff --git a/src/apideck_unify/models/bankfeedaccount.py b/src/apideck_unify/models/bankfeedaccount.py index e179f397..0be6b979 100644 --- a/src/apideck_unify/models/bankfeedaccount.py +++ b/src/apideck_unify/models/bankfeedaccount.py @@ -41,12 +41,20 @@ class BankFeedAccountTypedDict(TypedDict): r"""Type of the bank account.""" source_account_id: NotRequired[str] r"""The source account's unique identifier.""" + source_routing_number: NotRequired[Nullable[str]] + r"""Bank routing number (US)""" + source_account_number: NotRequired[Nullable[str]] + r"""The bank account number""" target_account_id: NotRequired[str] r"""The target account's unique identifier in the accounting connector.""" target_account_name: NotRequired[str] r"""Name associated with the target account.""" target_account_number: NotRequired[str] r"""Account number of the destination bank account.""" + balance: NotRequired[Nullable[float]] + r"""The current balance of the source bank account.""" + available_balance: NotRequired[Nullable[float]] + r"""The available balance of the source bank account (considering pending transactions and overdraft).""" currency: NotRequired[Nullable[Currency]] r"""Indicates the associated currency for an amount of money. Values correspond to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217).""" feed_status: NotRequired[FeedStatus] @@ -78,6 +86,12 @@ class BankFeedAccount(BaseModel): source_account_id: Optional[str] = None r"""The source account's unique identifier.""" + source_routing_number: OptionalNullable[str] = UNSET + r"""Bank routing number (US)""" + + source_account_number: OptionalNullable[str] = UNSET + r"""The bank account number""" + target_account_id: Optional[str] = None r"""The target account's unique identifier in the accounting connector.""" @@ -87,6 +101,12 @@ class BankFeedAccount(BaseModel): target_account_number: Optional[str] = None r"""Account number of the destination bank account.""" + balance: OptionalNullable[float] = UNSET + r"""The current balance of the source bank account.""" + + available_balance: OptionalNullable[float] = UNSET + r"""The available balance of the source bank account (considering pending transactions and overdraft).""" + currency: Annotated[ OptionalNullable[Currency], PlainValidator(validate_open_enum(False)) ] = UNSET @@ -149,9 +169,13 @@ def serialize_model(self, handler): optional_fields = [ "bank_account_type", "source_account_id", + "source_routing_number", + "source_account_number", "target_account_id", "target_account_name", "target_account_number", + "balance", + "available_balance", "currency", "feed_status", "country", @@ -163,6 +187,10 @@ def serialize_model(self, handler): "created_by", ] nullable_fields = [ + "source_routing_number", + "source_account_number", + "balance", + "available_balance", "currency", "country", "custom_mappings", @@ -203,12 +231,20 @@ class BankFeedAccountInputTypedDict(TypedDict): r"""Type of the bank account.""" source_account_id: NotRequired[str] r"""The source account's unique identifier.""" + source_routing_number: NotRequired[Nullable[str]] + r"""Bank routing number (US)""" + source_account_number: NotRequired[Nullable[str]] + r"""The bank account number""" target_account_id: NotRequired[str] r"""The target account's unique identifier in the accounting connector.""" target_account_name: NotRequired[str] r"""Name associated with the target account.""" target_account_number: NotRequired[str] r"""Account number of the destination bank account.""" + balance: NotRequired[Nullable[float]] + r"""The current balance of the source bank account.""" + available_balance: NotRequired[Nullable[float]] + r"""The available balance of the source bank account (considering pending transactions and overdraft).""" currency: NotRequired[Nullable[Currency]] r"""Indicates the associated currency for an amount of money. Values correspond to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217).""" feed_status: NotRequired[FeedStatus] @@ -227,6 +263,12 @@ class BankFeedAccountInput(BaseModel): source_account_id: Optional[str] = None r"""The source account's unique identifier.""" + source_routing_number: OptionalNullable[str] = UNSET + r"""Bank routing number (US)""" + + source_account_number: OptionalNullable[str] = UNSET + r"""The bank account number""" + target_account_id: Optional[str] = None r"""The target account's unique identifier in the accounting connector.""" @@ -236,6 +278,12 @@ class BankFeedAccountInput(BaseModel): target_account_number: Optional[str] = None r"""Account number of the destination bank account.""" + balance: OptionalNullable[float] = UNSET + r"""The current balance of the source bank account.""" + + available_balance: OptionalNullable[float] = UNSET + r"""The available balance of the source bank account (considering pending transactions and overdraft).""" + currency: Annotated[ OptionalNullable[Currency], PlainValidator(validate_open_enum(False)) ] = UNSET @@ -283,15 +331,26 @@ def serialize_model(self, handler): optional_fields = [ "bank_account_type", "source_account_id", + "source_routing_number", + "source_account_number", "target_account_id", "target_account_name", "target_account_number", + "balance", + "available_balance", "currency", "feed_status", "country", "custom_fields", ] - nullable_fields = ["currency", "country"] + nullable_fields = [ + "source_routing_number", + "source_account_number", + "balance", + "available_balance", + "currency", + "country", + ] null_default_fields = [] serialized = handler(self) diff --git a/src/apideck_unify/models/bankfeedstatement.py b/src/apideck_unify/models/bankfeedstatement.py index 0258971d..ee171c90 100644 --- a/src/apideck_unify/models/bankfeedstatement.py +++ b/src/apideck_unify/models/bankfeedstatement.py @@ -55,6 +55,8 @@ class TransactionsTypedDict(TypedDict): r"""The reference of the transaction.""" transaction_type: NotRequired[BankFeedStatementTransactionType] r"""Type of transaction.""" + merchant_category_code: NotRequired[Nullable[str]] + r"""The ISO 18245 merchant category code (MCC) classifying the merchant for this transaction, expected as a four-digit code such as `5812`. The format is not enforced by the API, matching the other bank identifier fields.""" class Transactions(BaseModel): @@ -85,6 +87,9 @@ class Transactions(BaseModel): ] = None r"""Type of transaction.""" + merchant_category_code: OptionalNullable[str] = UNSET + r"""The ISO 18245 merchant category code (MCC) classifying the merchant for this transaction, expected as a four-digit code such as `5812`. The format is not enforced by the API, matching the other bank identifier fields.""" + @field_serializer("credit_or_debit") def serialize_credit_or_debit(self, value): if isinstance(value, str): @@ -103,6 +108,42 @@ def serialize_transaction_type(self, value): return value return value + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = [ + "description", + "counterparty", + "reference", + "transaction_type", + "merchant_category_code", + ] + nullable_fields = ["merchant_category_code"] + null_default_fields = [] + + serialized = handler(self) + + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k) + serialized.pop(k, None) + + optional_nullable = k in optional_fields and k in nullable_fields + is_set = ( + self.__pydantic_fields_set__.intersection({n}) + or k in null_default_fields + ) # pylint: disable=no-member + + if val is not None and val != UNSET_SENTINEL: + m[k] = val + elif val != UNSET_SENTINEL and ( + not k in optional_fields or (optional_nullable and is_set) + ): + m[k] = val + + return m + class BankFeedStatementTypedDict(TypedDict): id: str diff --git a/src/apideck_unify/models/createpaymentmethodresponse.py b/src/apideck_unify/models/createpaymentmethodresponse.py new file mode 100644 index 00000000..c59e3894 --- /dev/null +++ b/src/apideck_unify/models/createpaymentmethodresponse.py @@ -0,0 +1,91 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .unifiedid import UnifiedID, UnifiedIDTypedDict +from apideck_unify.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import model_serializer +from typing import Any, Dict +from typing_extensions import Annotated, NotRequired, TypedDict + + +class CreatePaymentMethodResponseTypedDict(TypedDict): + r"""Payment Methods""" + + status_code: int + r"""HTTP Response Status Code""" + status: str + r"""HTTP Response Status""" + service: str + r"""Apideck ID of service provider""" + resource: str + r"""Unified API resource name""" + operation: str + r"""Operation performed""" + data: UnifiedIDTypedDict + r"""A object containing a unique identifier for the resource that was created, updated, or deleted.""" + raw: NotRequired[Nullable[Dict[str, Any]]] + r"""Raw response from the integration when raw=true query param is provided""" + + +class CreatePaymentMethodResponse(BaseModel): + r"""Payment Methods""" + + status_code: int + r"""HTTP Response Status Code""" + + status: str + r"""HTTP Response Status""" + + service: str + r"""Apideck ID of service provider""" + + resource: str + r"""Unified API resource name""" + + operation: str + r"""Operation performed""" + + data: UnifiedID + r"""A object containing a unique identifier for the resource that was created, updated, or deleted.""" + + raw: Annotated[OptionalNullable[Dict[str, Any]], pydantic.Field(alias="_raw")] = ( + UNSET + ) + r"""Raw response from the integration when raw=true query param is provided""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = ["_raw"] + nullable_fields = ["_raw"] + null_default_fields = [] + + serialized = handler(self) + + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k) + serialized.pop(k, None) + + optional_nullable = k in optional_fields and k in nullable_fields + is_set = ( + self.__pydantic_fields_set__.intersection({n}) + or k in null_default_fields + ) # pylint: disable=no-member + + if val is not None and val != UNSET_SENTINEL: + m[k] = val + elif val != UNSET_SENTINEL and ( + not k in optional_fields or (optional_nullable and is_set) + ): + m[k] = val + + return m diff --git a/src/apideck_unify/models/createsalesreceiptresponse.py b/src/apideck_unify/models/createsalesreceiptresponse.py new file mode 100644 index 00000000..00c96c80 --- /dev/null +++ b/src/apideck_unify/models/createsalesreceiptresponse.py @@ -0,0 +1,91 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .unifiedid import UnifiedID, UnifiedIDTypedDict +from apideck_unify.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import model_serializer +from typing import Any, Dict +from typing_extensions import Annotated, NotRequired, TypedDict + + +class CreateSalesReceiptResponseTypedDict(TypedDict): + r"""SalesReceipt created""" + + status_code: int + r"""HTTP Response Status Code""" + status: str + r"""HTTP Response Status""" + service: str + r"""Apideck ID of service provider""" + resource: str + r"""Unified API resource name""" + operation: str + r"""Operation performed""" + data: UnifiedIDTypedDict + r"""A object containing a unique identifier for the resource that was created, updated, or deleted.""" + raw: NotRequired[Nullable[Dict[str, Any]]] + r"""Raw response from the integration when raw=true query param is provided""" + + +class CreateSalesReceiptResponse(BaseModel): + r"""SalesReceipt created""" + + status_code: int + r"""HTTP Response Status Code""" + + status: str + r"""HTTP Response Status""" + + service: str + r"""Apideck ID of service provider""" + + resource: str + r"""Unified API resource name""" + + operation: str + r"""Operation performed""" + + data: UnifiedID + r"""A object containing a unique identifier for the resource that was created, updated, or deleted.""" + + raw: Annotated[OptionalNullable[Dict[str, Any]], pydantic.Field(alias="_raw")] = ( + UNSET + ) + r"""Raw response from the integration when raw=true query param is provided""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = ["_raw"] + nullable_fields = ["_raw"] + null_default_fields = [] + + serialized = handler(self) + + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k) + serialized.pop(k, None) + + optional_nullable = k in optional_fields and k in nullable_fields + is_set = ( + self.__pydantic_fields_set__.intersection({n}) + or k in null_default_fields + ) # pylint: disable=no-member + + if val is not None and val != UNSET_SENTINEL: + m[k] = val + elif val != UNSET_SENTINEL and ( + not k in optional_fields or (optional_nullable and is_set) + ): + m[k] = val + + return m diff --git a/src/apideck_unify/models/customfield.py b/src/apideck_unify/models/customfield.py index 366946be..e511b598 100644 --- a/src/apideck_unify/models/customfield.py +++ b/src/apideck_unify/models/customfield.py @@ -42,6 +42,8 @@ class CustomField2TypedDict(TypedDict): r"""Name of the custom field.""" id: NotRequired[Nullable[str]] r"""Unique identifier for the custom field.""" + ref_name: NotRequired[Nullable[str]] + r"""Display name of the record a reference-type custom field points at. `value` carries that record's id; this carries its human-readable name, so a consumer does not need a second lookup to render it.""" description: NotRequired[Nullable[str]] r"""More information about the custom field""" value: NotRequired[Nullable[CustomFieldValueTypedDict]] @@ -54,6 +56,9 @@ class CustomField2(BaseModel): id: OptionalNullable[str] = UNSET r"""Unique identifier for the custom field.""" + ref_name: OptionalNullable[str] = UNSET + r"""Display name of the record a reference-type custom field points at. `value` carries that record's id; this carries its human-readable name, so a consumer does not need a second lookup to render it.""" + description: OptionalNullable[str] = UNSET r"""More information about the custom field""" @@ -61,8 +66,8 @@ class CustomField2(BaseModel): @model_serializer(mode="wrap") def serialize_model(self, handler): - optional_fields = ["id", "description", "value"] - nullable_fields = ["id", "name", "description", "value"] + optional_fields = ["id", "ref_name", "description", "value"] + nullable_fields = ["id", "name", "ref_name", "description", "value"] null_default_fields = [] serialized = handler(self) @@ -117,6 +122,8 @@ class CustomField1TypedDict(TypedDict): r"""Unique identifier for the custom field.""" name: NotRequired[Nullable[str]] r"""Name of the custom field.""" + ref_name: NotRequired[Nullable[str]] + r"""Display name of the record a reference-type custom field points at. `value` carries that record's id; this carries its human-readable name, so a consumer does not need a second lookup to render it.""" description: NotRequired[Nullable[str]] r"""More information about the custom field""" value: NotRequired[Nullable[CustomField1ValueTypedDict]] @@ -129,6 +136,9 @@ class CustomField1(BaseModel): name: OptionalNullable[str] = UNSET r"""Name of the custom field.""" + ref_name: OptionalNullable[str] = UNSET + r"""Display name of the record a reference-type custom field points at. `value` carries that record's id; this carries its human-readable name, so a consumer does not need a second lookup to render it.""" + description: OptionalNullable[str] = UNSET r"""More information about the custom field""" @@ -136,8 +146,8 @@ class CustomField1(BaseModel): @model_serializer(mode="wrap") def serialize_model(self, handler): - optional_fields = ["name", "description", "value"] - nullable_fields = ["id", "name", "description", "value"] + optional_fields = ["name", "ref_name", "description", "value"] + nullable_fields = ["id", "name", "ref_name", "description", "value"] null_default_fields = [] serialized = handler(self) diff --git a/src/apideck_unify/models/deletepaymentmethodresponse.py b/src/apideck_unify/models/deletepaymentmethodresponse.py new file mode 100644 index 00000000..e575273d --- /dev/null +++ b/src/apideck_unify/models/deletepaymentmethodresponse.py @@ -0,0 +1,91 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .unifiedid import UnifiedID, UnifiedIDTypedDict +from apideck_unify.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import model_serializer +from typing import Any, Dict +from typing_extensions import Annotated, NotRequired, TypedDict + + +class DeletePaymentMethodResponseTypedDict(TypedDict): + r"""Payment Methods""" + + status_code: int + r"""HTTP Response Status Code""" + status: str + r"""HTTP Response Status""" + service: str + r"""Apideck ID of service provider""" + resource: str + r"""Unified API resource name""" + operation: str + r"""Operation performed""" + data: UnifiedIDTypedDict + r"""A object containing a unique identifier for the resource that was created, updated, or deleted.""" + raw: NotRequired[Nullable[Dict[str, Any]]] + r"""Raw response from the integration when raw=true query param is provided""" + + +class DeletePaymentMethodResponse(BaseModel): + r"""Payment Methods""" + + status_code: int + r"""HTTP Response Status Code""" + + status: str + r"""HTTP Response Status""" + + service: str + r"""Apideck ID of service provider""" + + resource: str + r"""Unified API resource name""" + + operation: str + r"""Operation performed""" + + data: UnifiedID + r"""A object containing a unique identifier for the resource that was created, updated, or deleted.""" + + raw: Annotated[OptionalNullable[Dict[str, Any]], pydantic.Field(alias="_raw")] = ( + UNSET + ) + r"""Raw response from the integration when raw=true query param is provided""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = ["_raw"] + nullable_fields = ["_raw"] + null_default_fields = [] + + serialized = handler(self) + + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k) + serialized.pop(k, None) + + optional_nullable = k in optional_fields and k in nullable_fields + is_set = ( + self.__pydantic_fields_set__.intersection({n}) + or k in null_default_fields + ) # pylint: disable=no-member + + if val is not None and val != UNSET_SENTINEL: + m[k] = val + elif val != UNSET_SENTINEL and ( + not k in optional_fields or (optional_nullable and is_set) + ): + m[k] = val + + return m diff --git a/src/apideck_unify/models/deletesalesreceiptresponse.py b/src/apideck_unify/models/deletesalesreceiptresponse.py new file mode 100644 index 00000000..b63ad38b --- /dev/null +++ b/src/apideck_unify/models/deletesalesreceiptresponse.py @@ -0,0 +1,91 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .unifiedid import UnifiedID, UnifiedIDTypedDict +from apideck_unify.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import model_serializer +from typing import Any, Dict +from typing_extensions import Annotated, NotRequired, TypedDict + + +class DeleteSalesReceiptResponseTypedDict(TypedDict): + r"""SalesReceipt deleted""" + + status_code: int + r"""HTTP Response Status Code""" + status: str + r"""HTTP Response Status""" + service: str + r"""Apideck ID of service provider""" + resource: str + r"""Unified API resource name""" + operation: str + r"""Operation performed""" + data: UnifiedIDTypedDict + r"""A object containing a unique identifier for the resource that was created, updated, or deleted.""" + raw: NotRequired[Nullable[Dict[str, Any]]] + r"""Raw response from the integration when raw=true query param is provided""" + + +class DeleteSalesReceiptResponse(BaseModel): + r"""SalesReceipt deleted""" + + status_code: int + r"""HTTP Response Status Code""" + + status: str + r"""HTTP Response Status""" + + service: str + r"""Apideck ID of service provider""" + + resource: str + r"""Unified API resource name""" + + operation: str + r"""Operation performed""" + + data: UnifiedID + r"""A object containing a unique identifier for the resource that was created, updated, or deleted.""" + + raw: Annotated[OptionalNullable[Dict[str, Any]], pydantic.Field(alias="_raw")] = ( + UNSET + ) + r"""Raw response from the integration when raw=true query param is provided""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = ["_raw"] + nullable_fields = ["_raw"] + null_default_fields = [] + + serialized = handler(self) + + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k) + serialized.pop(k, None) + + optional_nullable = k in optional_fields and k in nullable_fields + is_set = ( + self.__pydantic_fields_set__.intersection({n}) + or k in null_default_fields + ) # pylint: disable=no-member + + if val is not None and val != UNSET_SENTINEL: + m[k] = val + elif val != UNSET_SENTINEL and ( + not k in optional_fields or (optional_nullable and is_set) + ): + m[k] = val + + return m diff --git a/src/apideck_unify/models/filestorage_filesdownloadop.py b/src/apideck_unify/models/filestorage_filesdownloadop.py index 7ca9c0ea..f6d41b23 100644 --- a/src/apideck_unify/models/filestorage_filesdownloadop.py +++ b/src/apideck_unify/models/filestorage_filesdownloadop.py @@ -60,6 +60,8 @@ class FileStorageFilesDownloadRequestTypedDict(TypedDict): r"""Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.""" fields: NotRequired[Nullable[str]] r"""The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields \"name\", \"email\" and \"addresses.city\". If any other fields are available, they will be excluded.""" + follow_redirects: NotRequired[bool] + r"""Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior.""" class FileStorageFilesDownloadRequest(BaseModel): @@ -95,9 +97,22 @@ class FileStorageFilesDownloadRequest(BaseModel): ] = UNSET r"""The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields \"name\", \"email\" and \"addresses.city\". If any other fields are available, they will be excluded.""" + follow_redirects: Annotated[ + Optional[bool], + pydantic.Field(alias="x-apideck-follow-redirects"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = True + r"""Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior.""" + @model_serializer(mode="wrap") def serialize_model(self, handler): - optional_fields = ["consumerId", "appId", "serviceId", "fields"] + optional_fields = [ + "consumerId", + "appId", + "serviceId", + "fields", + "followRedirects", + ] nullable_fields = ["fields"] null_default_fields = [] @@ -129,7 +144,7 @@ def serialize_model(self, handler): class FileStorageFilesDownloadResponseTypedDict(TypedDict): http_meta: HTTPMetadataTypedDict get_file_download_response: NotRequired[httpx.Response] - r"""File Download""" + r"""File Download. When the request includes `x-apideck-follow-redirects: false` and the download would otherwise redirect to a presigned URL, the response body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the file.""" unexpected_error_response: NotRequired[UnexpectedErrorResponseTypedDict] r"""Unexpected error""" @@ -138,7 +153,7 @@ class FileStorageFilesDownloadResponse(BaseModel): http_meta: Annotated[Optional[HTTPMetadata], pydantic.Field(exclude=True)] = None get_file_download_response: Optional[httpx.Response] = None - r"""File Download""" + r"""File Download. When the request includes `x-apideck-follow-redirects: false` and the download would otherwise redirect to a presigned URL, the response body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the file.""" unexpected_error_response: Optional[UnexpectedErrorResponse] = None r"""Unexpected error""" diff --git a/src/apideck_unify/models/filestorage_filesexportop.py b/src/apideck_unify/models/filestorage_filesexportop.py index 5683fb23..07e3a086 100644 --- a/src/apideck_unify/models/filestorage_filesexportop.py +++ b/src/apideck_unify/models/filestorage_filesexportop.py @@ -138,7 +138,7 @@ def serialize_model(self, handler): class FileStorageFilesExportResponseTypedDict(TypedDict): http_meta: HTTPMetadataTypedDict get_file_download_response: NotRequired[httpx.Response] - r"""File Download""" + r"""File Download. When the request includes `x-apideck-follow-redirects: false` and the download would otherwise redirect to a presigned URL, the response body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the file.""" unexpected_error_response: NotRequired[UnexpectedErrorResponseTypedDict] r"""Unexpected error""" @@ -147,7 +147,7 @@ class FileStorageFilesExportResponse(BaseModel): http_meta: Annotated[Optional[HTTPMetadata], pydantic.Field(exclude=True)] = None get_file_download_response: Optional[httpx.Response] = None - r"""File Download""" + r"""File Download. When the request includes `x-apideck-follow-redirects: false` and the download would otherwise redirect to a presigned URL, the response body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the file.""" unexpected_error_response: Optional[UnexpectedErrorResponse] = None r"""Unexpected error""" diff --git a/src/apideck_unify/models/getpaymentmethodresponse.py b/src/apideck_unify/models/getpaymentmethodresponse.py new file mode 100644 index 00000000..b85fd63c --- /dev/null +++ b/src/apideck_unify/models/getpaymentmethodresponse.py @@ -0,0 +1,98 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .accountingpaymentmethod import ( + AccountingPaymentMethod, + AccountingPaymentMethodTypedDict, +) +from .meta import Meta, MetaTypedDict +from apideck_unify.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import model_serializer +from typing import Any, Dict, Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class GetPaymentMethodResponseTypedDict(TypedDict): + r"""Payment Methods""" + + status_code: int + r"""HTTP Response Status Code""" + status: str + r"""HTTP Response Status""" + service: str + r"""Apideck ID of service provider""" + resource: str + r"""Unified API resource name""" + operation: str + r"""Operation performed""" + data: AccountingPaymentMethodTypedDict + meta: NotRequired[MetaTypedDict] + r"""Response metadata""" + raw: NotRequired[Nullable[Dict[str, Any]]] + r"""Raw response from the integration when raw=true query param is provided""" + + +class GetPaymentMethodResponse(BaseModel): + r"""Payment Methods""" + + status_code: int + r"""HTTP Response Status Code""" + + status: str + r"""HTTP Response Status""" + + service: str + r"""Apideck ID of service provider""" + + resource: str + r"""Unified API resource name""" + + operation: str + r"""Operation performed""" + + data: AccountingPaymentMethod + + meta: Optional[Meta] = None + r"""Response metadata""" + + raw: Annotated[OptionalNullable[Dict[str, Any]], pydantic.Field(alias="_raw")] = ( + UNSET + ) + r"""Raw response from the integration when raw=true query param is provided""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = ["meta", "_raw"] + nullable_fields = ["_raw"] + null_default_fields = [] + + serialized = handler(self) + + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k) + serialized.pop(k, None) + + optional_nullable = k in optional_fields and k in nullable_fields + is_set = ( + self.__pydantic_fields_set__.intersection({n}) + or k in null_default_fields + ) # pylint: disable=no-member + + if val is not None and val != UNSET_SENTINEL: + m[k] = val + elif val != UNSET_SENTINEL and ( + not k in optional_fields or (optional_nullable and is_set) + ): + m[k] = val + + return m diff --git a/src/apideck_unify/models/getpaymentmethodsresponse.py b/src/apideck_unify/models/getpaymentmethodsresponse.py new file mode 100644 index 00000000..e260332b --- /dev/null +++ b/src/apideck_unify/models/getpaymentmethodsresponse.py @@ -0,0 +1,104 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .accountingpaymentmethod import ( + AccountingPaymentMethod, + AccountingPaymentMethodTypedDict, +) +from .links import Links, LinksTypedDict +from .meta import Meta, MetaTypedDict +from apideck_unify.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import model_serializer +from typing import Any, Dict, List, Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class GetPaymentMethodsResponseTypedDict(TypedDict): + r"""Payment Methods""" + + status_code: int + r"""HTTP Response Status Code""" + status: str + r"""HTTP Response Status""" + service: str + r"""Apideck ID of service provider""" + resource: str + r"""Unified API resource name""" + operation: str + r"""Operation performed""" + data: List[AccountingPaymentMethodTypedDict] + meta: NotRequired[MetaTypedDict] + r"""Response metadata""" + links: NotRequired[LinksTypedDict] + r"""Links to navigate to previous or next pages through the API""" + raw: NotRequired[Nullable[Dict[str, Any]]] + r"""Raw response from the integration when raw=true query param is provided""" + + +class GetPaymentMethodsResponse(BaseModel): + r"""Payment Methods""" + + status_code: int + r"""HTTP Response Status Code""" + + status: str + r"""HTTP Response Status""" + + service: str + r"""Apideck ID of service provider""" + + resource: str + r"""Unified API resource name""" + + operation: str + r"""Operation performed""" + + data: List[AccountingPaymentMethod] + + meta: Optional[Meta] = None + r"""Response metadata""" + + links: Optional[Links] = None + r"""Links to navigate to previous or next pages through the API""" + + raw: Annotated[OptionalNullable[Dict[str, Any]], pydantic.Field(alias="_raw")] = ( + UNSET + ) + r"""Raw response from the integration when raw=true query param is provided""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = ["meta", "links", "_raw"] + nullable_fields = ["_raw"] + null_default_fields = [] + + serialized = handler(self) + + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k) + serialized.pop(k, None) + + optional_nullable = k in optional_fields and k in nullable_fields + is_set = ( + self.__pydantic_fields_set__.intersection({n}) + or k in null_default_fields + ) # pylint: disable=no-member + + if val is not None and val != UNSET_SENTINEL: + m[k] = val + elif val != UNSET_SENTINEL and ( + not k in optional_fields or (optional_nullable and is_set) + ): + m[k] = val + + return m diff --git a/src/apideck_unify/models/getsalesreceiptresponse.py b/src/apideck_unify/models/getsalesreceiptresponse.py new file mode 100644 index 00000000..86224919 --- /dev/null +++ b/src/apideck_unify/models/getsalesreceiptresponse.py @@ -0,0 +1,95 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .meta import Meta, MetaTypedDict +from .salesreceipt import SalesReceipt, SalesReceiptTypedDict +from apideck_unify.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import model_serializer +from typing import Any, Dict, Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class GetSalesReceiptResponseTypedDict(TypedDict): + r"""SalesReceipt""" + + status_code: int + r"""HTTP Response Status Code""" + status: str + r"""HTTP Response Status""" + service: str + r"""Apideck ID of service provider""" + resource: str + r"""Unified API resource name""" + operation: str + r"""Operation performed""" + data: SalesReceiptTypedDict + meta: NotRequired[MetaTypedDict] + r"""Response metadata""" + raw: NotRequired[Nullable[Dict[str, Any]]] + r"""Raw response from the integration when raw=true query param is provided""" + + +class GetSalesReceiptResponse(BaseModel): + r"""SalesReceipt""" + + status_code: int + r"""HTTP Response Status Code""" + + status: str + r"""HTTP Response Status""" + + service: str + r"""Apideck ID of service provider""" + + resource: str + r"""Unified API resource name""" + + operation: str + r"""Operation performed""" + + data: SalesReceipt + + meta: Optional[Meta] = None + r"""Response metadata""" + + raw: Annotated[OptionalNullable[Dict[str, Any]], pydantic.Field(alias="_raw")] = ( + UNSET + ) + r"""Raw response from the integration when raw=true query param is provided""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = ["meta", "_raw"] + nullable_fields = ["_raw"] + null_default_fields = [] + + serialized = handler(self) + + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k) + serialized.pop(k, None) + + optional_nullable = k in optional_fields and k in nullable_fields + is_set = ( + self.__pydantic_fields_set__.intersection({n}) + or k in null_default_fields + ) # pylint: disable=no-member + + if val is not None and val != UNSET_SENTINEL: + m[k] = val + elif val != UNSET_SENTINEL and ( + not k in optional_fields or (optional_nullable and is_set) + ): + m[k] = val + + return m diff --git a/src/apideck_unify/models/getsalesreceiptsresponse.py b/src/apideck_unify/models/getsalesreceiptsresponse.py new file mode 100644 index 00000000..be85fad7 --- /dev/null +++ b/src/apideck_unify/models/getsalesreceiptsresponse.py @@ -0,0 +1,101 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .links import Links, LinksTypedDict +from .meta import Meta, MetaTypedDict +from .salesreceipt import SalesReceipt, SalesReceiptTypedDict +from apideck_unify.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import model_serializer +from typing import Any, Dict, List, Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class GetSalesReceiptsResponseTypedDict(TypedDict): + r"""SalesReceipts""" + + status_code: int + r"""HTTP Response Status Code""" + status: str + r"""HTTP Response Status""" + service: str + r"""Apideck ID of service provider""" + resource: str + r"""Unified API resource name""" + operation: str + r"""Operation performed""" + data: List[SalesReceiptTypedDict] + meta: NotRequired[MetaTypedDict] + r"""Response metadata""" + links: NotRequired[LinksTypedDict] + r"""Links to navigate to previous or next pages through the API""" + raw: NotRequired[Nullable[Dict[str, Any]]] + r"""Raw response from the integration when raw=true query param is provided""" + + +class GetSalesReceiptsResponse(BaseModel): + r"""SalesReceipts""" + + status_code: int + r"""HTTP Response Status Code""" + + status: str + r"""HTTP Response Status""" + + service: str + r"""Apideck ID of service provider""" + + resource: str + r"""Unified API resource name""" + + operation: str + r"""Operation performed""" + + data: List[SalesReceipt] + + meta: Optional[Meta] = None + r"""Response metadata""" + + links: Optional[Links] = None + r"""Links to navigate to previous or next pages through the API""" + + raw: Annotated[OptionalNullable[Dict[str, Any]], pydantic.Field(alias="_raw")] = ( + UNSET + ) + r"""Raw response from the integration when raw=true query param is provided""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = ["meta", "links", "_raw"] + nullable_fields = ["_raw"] + null_default_fields = [] + + serialized = handler(self) + + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k) + serialized.pop(k, None) + + optional_nullable = k in optional_fields and k in nullable_fields + is_set = ( + self.__pydantic_fields_set__.intersection({n}) + or k in null_default_fields + ) # pylint: disable=no-member + + if val is not None and val != UNSET_SENTINEL: + m[k] = val + elif val != UNSET_SENTINEL and ( + not k in optional_fields or (optional_nullable and is_set) + ): + m[k] = val + + return m diff --git a/src/apideck_unify/models/proxy_deleteproxyop.py b/src/apideck_unify/models/proxy_deleteproxyop.py index b6b7b12b..066a220c 100644 --- a/src/apideck_unify/models/proxy_deleteproxyop.py +++ b/src/apideck_unify/models/proxy_deleteproxyop.py @@ -48,6 +48,8 @@ class ProxyDeleteProxyRequestTypedDict(TypedDict): r"""Downstream authorization header. This will skip the Vault token injection.""" timeout: NotRequired[int] r"""Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds).""" + follow_redirects: NotRequired[bool] + r"""Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior.""" class ProxyDeleteProxyRequest(BaseModel): @@ -100,22 +102,29 @@ class ProxyDeleteProxyRequest(BaseModel): ] = 28000 r"""Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds).""" + follow_redirects: Annotated[ + Optional[bool], + pydantic.Field(alias="x-apideck-follow-redirects"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = True + r"""Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior.""" + class ProxyDeleteProxyResponseTypedDict(TypedDict): http_meta: HTTPMetadataTypedDict headers: Dict[str, List[str]] response_json: NotRequired[Dict[str, Any]] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_binary: NotRequired[httpx.Response] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_pdf: NotRequired[httpx.Response] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_xml: NotRequired[str] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_csv: NotRequired[str] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_text: NotRequired[str] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" error_json: NotRequired[Dict[str, Any]] r"""Proxy error""" error_xml: NotRequired[str] @@ -132,22 +141,22 @@ class ProxyDeleteProxyResponse(BaseModel): headers: Dict[str, List[str]] response_json: Optional[Dict[str, Any]] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_binary: Optional[httpx.Response] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_pdf: Optional[httpx.Response] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_xml: Optional[str] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_csv: Optional[str] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_text: Optional[str] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" error_json: Optional[Dict[str, Any]] = None r"""Proxy error""" diff --git a/src/apideck_unify/models/proxy_getproxyop.py b/src/apideck_unify/models/proxy_getproxyop.py index 34d0ed8c..3769e673 100644 --- a/src/apideck_unify/models/proxy_getproxyop.py +++ b/src/apideck_unify/models/proxy_getproxyop.py @@ -48,6 +48,8 @@ class ProxyGetProxyRequestTypedDict(TypedDict): r"""Downstream authorization header. This will skip the Vault token injection.""" timeout: NotRequired[int] r"""Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds).""" + follow_redirects: NotRequired[bool] + r"""Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior.""" class ProxyGetProxyRequest(BaseModel): @@ -100,22 +102,29 @@ class ProxyGetProxyRequest(BaseModel): ] = 28000 r"""Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds).""" + follow_redirects: Annotated[ + Optional[bool], + pydantic.Field(alias="x-apideck-follow-redirects"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = True + r"""Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior.""" + class ProxyGetProxyResponseTypedDict(TypedDict): http_meta: HTTPMetadataTypedDict headers: Dict[str, List[str]] response_json: NotRequired[Dict[str, Any]] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_binary: NotRequired[httpx.Response] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_pdf: NotRequired[httpx.Response] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_xml: NotRequired[str] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_csv: NotRequired[str] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_text: NotRequired[str] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" error_json: NotRequired[Dict[str, Any]] r"""Proxy error""" error_xml: NotRequired[str] @@ -132,22 +141,22 @@ class ProxyGetProxyResponse(BaseModel): headers: Dict[str, List[str]] response_json: Optional[Dict[str, Any]] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_binary: Optional[httpx.Response] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_pdf: Optional[httpx.Response] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_xml: Optional[str] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_csv: Optional[str] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_text: Optional[str] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" error_json: Optional[Dict[str, Any]] = None r"""Proxy error""" diff --git a/src/apideck_unify/models/proxy_optionsproxyop.py b/src/apideck_unify/models/proxy_optionsproxyop.py index 9cb729f0..c3ff54be 100644 --- a/src/apideck_unify/models/proxy_optionsproxyop.py +++ b/src/apideck_unify/models/proxy_optionsproxyop.py @@ -48,6 +48,8 @@ class ProxyOptionsProxyRequestTypedDict(TypedDict): r"""Downstream authorization header. This will skip the Vault token injection.""" timeout: NotRequired[int] r"""Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds).""" + follow_redirects: NotRequired[bool] + r"""Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior.""" class ProxyOptionsProxyRequest(BaseModel): @@ -100,22 +102,29 @@ class ProxyOptionsProxyRequest(BaseModel): ] = 28000 r"""Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds).""" + follow_redirects: Annotated[ + Optional[bool], + pydantic.Field(alias="x-apideck-follow-redirects"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = True + r"""Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior.""" + class ProxyOptionsProxyResponseTypedDict(TypedDict): http_meta: HTTPMetadataTypedDict headers: Dict[str, List[str]] response_json: NotRequired[Dict[str, Any]] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_binary: NotRequired[httpx.Response] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_pdf: NotRequired[httpx.Response] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_xml: NotRequired[str] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_csv: NotRequired[str] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_text: NotRequired[str] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" error_json: NotRequired[Dict[str, Any]] r"""Proxy error""" error_xml: NotRequired[str] @@ -132,22 +141,22 @@ class ProxyOptionsProxyResponse(BaseModel): headers: Dict[str, List[str]] response_json: Optional[Dict[str, Any]] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_binary: Optional[httpx.Response] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_pdf: Optional[httpx.Response] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_xml: Optional[str] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_csv: Optional[str] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_text: Optional[str] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" error_json: Optional[Dict[str, Any]] = None r"""Proxy error""" diff --git a/src/apideck_unify/models/proxy_patchproxyop.py b/src/apideck_unify/models/proxy_patchproxyop.py index 4ee50691..355200c9 100644 --- a/src/apideck_unify/models/proxy_patchproxyop.py +++ b/src/apideck_unify/models/proxy_patchproxyop.py @@ -65,6 +65,8 @@ class ProxyPatchProxyRequestTypedDict(TypedDict): r"""Downstream authorization header. This will skip the Vault token injection.""" timeout: NotRequired[int] r"""Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds).""" + follow_redirects: NotRequired[bool] + r"""Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior.""" request_body: NotRequired[Union[bytes, IO[bytes], io.BufferedReader]] r"""Depending on the verb/method of the request this will contain the request body you want to POST/PATCH/PUT.""" @@ -119,6 +121,13 @@ class ProxyPatchProxyRequest(BaseModel): ] = 28000 r"""Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds).""" + follow_redirects: Annotated[ + Optional[bool], + pydantic.Field(alias="x-apideck-follow-redirects"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = True + r"""Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior.""" + request_body: Annotated[ Optional[Union[bytes, IO[bytes], io.BufferedReader]], FieldMetadata(request=RequestMetadata(media_type="*/*")), @@ -130,17 +139,17 @@ class ProxyPatchProxyResponseTypedDict(TypedDict): http_meta: HTTPMetadataTypedDict headers: Dict[str, List[str]] response_json: NotRequired[Dict[str, Any]] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_binary: NotRequired[httpx.Response] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_pdf: NotRequired[httpx.Response] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_xml: NotRequired[str] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_csv: NotRequired[str] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_text: NotRequired[str] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" error_json: NotRequired[Dict[str, Any]] r"""Proxy error""" error_xml: NotRequired[str] @@ -157,22 +166,22 @@ class ProxyPatchProxyResponse(BaseModel): headers: Dict[str, List[str]] response_json: Optional[Dict[str, Any]] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_binary: Optional[httpx.Response] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_pdf: Optional[httpx.Response] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_xml: Optional[str] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_csv: Optional[str] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_text: Optional[str] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" error_json: Optional[Dict[str, Any]] = None r"""Proxy error""" diff --git a/src/apideck_unify/models/proxy_postproxyop.py b/src/apideck_unify/models/proxy_postproxyop.py index a61f740e..aaf896cd 100644 --- a/src/apideck_unify/models/proxy_postproxyop.py +++ b/src/apideck_unify/models/proxy_postproxyop.py @@ -65,6 +65,8 @@ class ProxyPostProxyRequestTypedDict(TypedDict): r"""Downstream authorization header. This will skip the Vault token injection.""" timeout: NotRequired[int] r"""Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds).""" + follow_redirects: NotRequired[bool] + r"""Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior.""" request_body: NotRequired[Union[bytes, IO[bytes], io.BufferedReader]] r"""Depending on the verb/method of the request this will contain the request body you want to POST/PATCH/PUT.""" @@ -119,6 +121,13 @@ class ProxyPostProxyRequest(BaseModel): ] = 28000 r"""Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds).""" + follow_redirects: Annotated[ + Optional[bool], + pydantic.Field(alias="x-apideck-follow-redirects"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = True + r"""Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior.""" + request_body: Annotated[ Optional[Union[bytes, IO[bytes], io.BufferedReader]], FieldMetadata(request=RequestMetadata(media_type="*/*")), @@ -130,17 +139,17 @@ class ProxyPostProxyResponseTypedDict(TypedDict): http_meta: HTTPMetadataTypedDict headers: Dict[str, List[str]] response_json: NotRequired[Dict[str, Any]] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_binary: NotRequired[httpx.Response] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_pdf: NotRequired[httpx.Response] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_xml: NotRequired[str] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_csv: NotRequired[str] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_text: NotRequired[str] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" error_json: NotRequired[Dict[str, Any]] r"""Proxy error""" error_xml: NotRequired[str] @@ -157,22 +166,22 @@ class ProxyPostProxyResponse(BaseModel): headers: Dict[str, List[str]] response_json: Optional[Dict[str, Any]] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_binary: Optional[httpx.Response] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_pdf: Optional[httpx.Response] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_xml: Optional[str] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_csv: Optional[str] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_text: Optional[str] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" error_json: Optional[Dict[str, Any]] = None r"""Proxy error""" diff --git a/src/apideck_unify/models/proxy_putproxyop.py b/src/apideck_unify/models/proxy_putproxyop.py index b4226383..3b53bdea 100644 --- a/src/apideck_unify/models/proxy_putproxyop.py +++ b/src/apideck_unify/models/proxy_putproxyop.py @@ -65,6 +65,8 @@ class ProxyPutProxyRequestTypedDict(TypedDict): r"""Downstream authorization header. This will skip the Vault token injection.""" timeout: NotRequired[int] r"""Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds).""" + follow_redirects: NotRequired[bool] + r"""Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior.""" request_body: NotRequired[Union[bytes, IO[bytes], io.BufferedReader]] r"""Depending on the verb/method of the request this will contain the request body you want to POST/PATCH/PUT.""" @@ -119,6 +121,13 @@ class ProxyPutProxyRequest(BaseModel): ] = 28000 r"""Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds).""" + follow_redirects: Annotated[ + Optional[bool], + pydantic.Field(alias="x-apideck-follow-redirects"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] = True + r"""Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior.""" + request_body: Annotated[ Optional[Union[bytes, IO[bytes], io.BufferedReader]], FieldMetadata(request=RequestMetadata(media_type="*/*")), @@ -130,17 +139,17 @@ class ProxyPutProxyResponseTypedDict(TypedDict): http_meta: HTTPMetadataTypedDict headers: Dict[str, List[str]] response_json: NotRequired[Dict[str, Any]] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_binary: NotRequired[httpx.Response] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_pdf: NotRequired[httpx.Response] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_xml: NotRequired[str] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_csv: NotRequired[str] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_text: NotRequired[str] - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" error_json: NotRequired[Dict[str, Any]] r"""Proxy error""" error_xml: NotRequired[str] @@ -157,22 +166,22 @@ class ProxyPutProxyResponse(BaseModel): headers: Dict[str, List[str]] response_json: Optional[Dict[str, Any]] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_binary: Optional[httpx.Response] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_pdf: Optional[httpx.Response] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_xml: Optional[str] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_csv: Optional[str] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" response_text: Optional[str] = None - r"""Ok""" + r"""Ok. When the request includes `x-apideck-follow-redirects: false` and the downstream response would otherwise redirect to a presigned URL (oversized responses), the body is instead an `application/json` object `{ url, expires_at }` — fetch `url` explicitly (without the Authorization header) to retrieve the payload.""" error_json: Optional[Dict[str, Any]] = None r"""Proxy error""" diff --git a/src/apideck_unify/models/salesreceipt.py b/src/apideck_unify/models/salesreceipt.py new file mode 100644 index 00000000..fca3ce21 --- /dev/null +++ b/src/apideck_unify/models/salesreceipt.py @@ -0,0 +1,294 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .address import Address, AddressTypedDict +from .currency import Currency +from .customfield import CustomField, CustomFieldTypedDict +from .invoicelineitem import InvoiceLineItem, InvoiceLineItemTypedDict +from .linkedcustomer import LinkedCustomer, LinkedCustomerTypedDict +from .linkeddepartment import LinkedDepartment, LinkedDepartmentTypedDict +from .linkedledgeraccount import LinkedLedgerAccount, LinkedLedgerAccountTypedDict +from .linkedtrackingcategory import ( + LinkedTrackingCategory, + LinkedTrackingCategoryTypedDict, +) +from .passthroughbody import PassThroughBody, PassThroughBodyTypedDict +from apideck_unify import models +from apideck_unify.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +from apideck_unify.utils import validate_open_enum +from datetime import datetime +from pydantic import field_serializer, model_serializer +from pydantic.functional_validators import PlainValidator +from typing import Any, Dict, List, Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class SalesReceiptTypedDict(TypedDict): + id: str + r"""Unique identifier representing the sales receipt""" + total_amount: Nullable[float] + r"""The total amount of the transaction or record""" + number: NotRequired[Nullable[str]] + r"""Reference number for the sales receipt.""" + customer: NotRequired[Nullable[LinkedCustomerTypedDict]] + r"""The customer this entity is linked to.""" + currency: NotRequired[Nullable[Currency]] + r"""Indicates the associated currency for an amount of money. Values correspond to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217).""" + currency_rate: NotRequired[Nullable[float]] + r"""Currency Exchange Rate at the time entity was recorded/generated.""" + tax_inclusive: NotRequired[Nullable[bool]] + r"""Amounts are including tax""" + sub_total: NotRequired[Nullable[float]] + r"""Subtotal amount, normally before tax.""" + total_tax: NotRequired[Nullable[float]] + r"""Total tax amount applied to this transaction.""" + transaction_date: NotRequired[Nullable[datetime]] + r"""The date of the sales receipt transaction - YYYY-MM-DDThh:mm:ss.sTZD""" + payment_method: NotRequired[Nullable[str]] + r"""Payment method used for the transaction, such as cash, credit card, bank transfer, or check""" + payment_method_reference: NotRequired[Nullable[str]] + r"""Optional reference message returned by payment method on processing""" + payment_method_id: NotRequired[Nullable[str]] + r"""A unique identifier for an object.""" + account: NotRequired[Nullable[LinkedLedgerAccountTypedDict]] + line_items: NotRequired[List[InvoiceLineItemTypedDict]] + r"""Line items for itemized sales receipts. Used when the sales receipt includes product/service details with quantities and pricing.""" + tax_code: NotRequired[Nullable[str]] + r"""Applicable tax id/code override if tax is not supplied on a line item basis.""" + discount_percentage: NotRequired[Nullable[float]] + r"""Discount percentage applied to this sales receipt.""" + discount_amount: NotRequired[Nullable[float]] + r"""Discount amount applied to this sales receipt.""" + note: NotRequired[Nullable[str]] + r"""Optional note to be associated with the sales receipt.""" + customer_memo: NotRequired[Nullable[str]] + r"""Customer memo""" + reference: NotRequired[Nullable[str]] + r"""Optional reference message for the sales receipt.""" + billing_address: NotRequired[AddressTypedDict] + shipping_address: NotRequired[AddressTypedDict] + department: NotRequired[Nullable[LinkedDepartmentTypedDict]] + tracking_categories: NotRequired[ + Nullable[List[Nullable[LinkedTrackingCategoryTypedDict]]] + ] + r"""A list of linked tracking categories.""" + custom_mappings: NotRequired[Nullable[Dict[str, Any]]] + r"""When custom mappings are configured on the resource, the result is included here.""" + custom_fields: NotRequired[List[CustomFieldTypedDict]] + row_version: NotRequired[Nullable[str]] + r"""A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object.""" + updated_by: NotRequired[Nullable[str]] + r"""The user who last updated the object.""" + created_by: NotRequired[Nullable[str]] + r"""The user who created the object.""" + updated_at: NotRequired[Nullable[datetime]] + r"""The date and time when the object was last updated.""" + created_at: NotRequired[Nullable[datetime]] + r"""The date and time when the object was created.""" + pass_through: NotRequired[List[PassThroughBodyTypedDict]] + r"""The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources.""" + + +class SalesReceipt(BaseModel): + id: str + r"""Unique identifier representing the sales receipt""" + + total_amount: Nullable[float] + r"""The total amount of the transaction or record""" + + number: OptionalNullable[str] = UNSET + r"""Reference number for the sales receipt.""" + + customer: OptionalNullable[LinkedCustomer] = UNSET + r"""The customer this entity is linked to.""" + + currency: Annotated[ + OptionalNullable[Currency], PlainValidator(validate_open_enum(False)) + ] = UNSET + r"""Indicates the associated currency for an amount of money. Values correspond to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217).""" + + currency_rate: OptionalNullable[float] = UNSET + r"""Currency Exchange Rate at the time entity was recorded/generated.""" + + tax_inclusive: OptionalNullable[bool] = UNSET + r"""Amounts are including tax""" + + sub_total: OptionalNullable[float] = UNSET + r"""Subtotal amount, normally before tax.""" + + total_tax: OptionalNullable[float] = UNSET + r"""Total tax amount applied to this transaction.""" + + transaction_date: OptionalNullable[datetime] = UNSET + r"""The date of the sales receipt transaction - YYYY-MM-DDThh:mm:ss.sTZD""" + + payment_method: OptionalNullable[str] = UNSET + r"""Payment method used for the transaction, such as cash, credit card, bank transfer, or check""" + + payment_method_reference: OptionalNullable[str] = UNSET + r"""Optional reference message returned by payment method on processing""" + + payment_method_id: OptionalNullable[str] = UNSET + r"""A unique identifier for an object.""" + + account: OptionalNullable[LinkedLedgerAccount] = UNSET + + line_items: Optional[List[InvoiceLineItem]] = None + r"""Line items for itemized sales receipts. Used when the sales receipt includes product/service details with quantities and pricing.""" + + tax_code: OptionalNullable[str] = UNSET + r"""Applicable tax id/code override if tax is not supplied on a line item basis.""" + + discount_percentage: OptionalNullable[float] = UNSET + r"""Discount percentage applied to this sales receipt.""" + + discount_amount: OptionalNullable[float] = UNSET + r"""Discount amount applied to this sales receipt.""" + + note: OptionalNullable[str] = UNSET + r"""Optional note to be associated with the sales receipt.""" + + customer_memo: OptionalNullable[str] = UNSET + r"""Customer memo""" + + reference: OptionalNullable[str] = UNSET + r"""Optional reference message for the sales receipt.""" + + billing_address: Optional[Address] = None + + shipping_address: Optional[Address] = None + + department: OptionalNullable[LinkedDepartment] = UNSET + + tracking_categories: OptionalNullable[List[Nullable[LinkedTrackingCategory]]] = ( + UNSET + ) + r"""A list of linked tracking categories.""" + + custom_mappings: OptionalNullable[Dict[str, Any]] = UNSET + r"""When custom mappings are configured on the resource, the result is included here.""" + + custom_fields: Optional[List[CustomField]] = None + + row_version: OptionalNullable[str] = UNSET + r"""A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object.""" + + updated_by: OptionalNullable[str] = UNSET + r"""The user who last updated the object.""" + + created_by: OptionalNullable[str] = UNSET + r"""The user who created the object.""" + + updated_at: OptionalNullable[datetime] = UNSET + r"""The date and time when the object was last updated.""" + + created_at: OptionalNullable[datetime] = UNSET + r"""The date and time when the object was created.""" + + pass_through: Optional[List[PassThroughBody]] = None + r"""The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources.""" + + @field_serializer("currency") + def serialize_currency(self, value): + if isinstance(value, str): + try: + return models.Currency(value) + except ValueError: + return value + return value + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = [ + "number", + "customer", + "currency", + "currency_rate", + "tax_inclusive", + "sub_total", + "total_tax", + "transaction_date", + "payment_method", + "payment_method_reference", + "payment_method_id", + "account", + "line_items", + "tax_code", + "discount_percentage", + "discount_amount", + "note", + "customer_memo", + "reference", + "billing_address", + "shipping_address", + "department", + "tracking_categories", + "custom_mappings", + "custom_fields", + "row_version", + "updated_by", + "created_by", + "updated_at", + "created_at", + "pass_through", + ] + nullable_fields = [ + "number", + "customer", + "currency", + "currency_rate", + "tax_inclusive", + "sub_total", + "total_amount", + "total_tax", + "transaction_date", + "payment_method", + "payment_method_reference", + "payment_method_id", + "account", + "tax_code", + "discount_percentage", + "discount_amount", + "note", + "customer_memo", + "reference", + "department", + "tracking_categories", + "custom_mappings", + "row_version", + "updated_by", + "created_by", + "updated_at", + "created_at", + ] + null_default_fields = [] + + serialized = handler(self) + + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k) + serialized.pop(k, None) + + optional_nullable = k in optional_fields and k in nullable_fields + is_set = ( + self.__pydantic_fields_set__.intersection({n}) + or k in null_default_fields + ) # pylint: disable=no-member + + if val is not None and val != UNSET_SENTINEL: + m[k] = val + elif val != UNSET_SENTINEL and ( + not k in optional_fields or (optional_nullable and is_set) + ): + m[k] = val + + return m diff --git a/src/apideck_unify/models/salesreceipt_input.py b/src/apideck_unify/models/salesreceipt_input.py new file mode 100644 index 00000000..6ccf5f6f --- /dev/null +++ b/src/apideck_unify/models/salesreceipt_input.py @@ -0,0 +1,257 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .address import Address, AddressTypedDict +from .currency import Currency +from .customfield import CustomField, CustomFieldTypedDict +from .invoicelineitem import InvoiceLineItemInput, InvoiceLineItemInputTypedDict +from .linkedcustomer_input import LinkedCustomerInput, LinkedCustomerInputTypedDict +from .linkeddepartment_input import ( + LinkedDepartmentInput, + LinkedDepartmentInputTypedDict, +) +from .linkedledgeraccount import LinkedLedgerAccount, LinkedLedgerAccountTypedDict +from .linkedtrackingcategory import ( + LinkedTrackingCategory, + LinkedTrackingCategoryTypedDict, +) +from .passthroughbody import PassThroughBody, PassThroughBodyTypedDict +from apideck_unify import models +from apideck_unify.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +from apideck_unify.utils import validate_open_enum +from datetime import datetime +from pydantic import field_serializer, model_serializer +from pydantic.functional_validators import PlainValidator +from typing import List, Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class SalesReceiptInputTypedDict(TypedDict): + total_amount: Nullable[float] + r"""The total amount of the transaction or record""" + number: NotRequired[Nullable[str]] + r"""Reference number for the sales receipt.""" + customer: NotRequired[Nullable[LinkedCustomerInputTypedDict]] + r"""The customer this entity is linked to.""" + currency: NotRequired[Nullable[Currency]] + r"""Indicates the associated currency for an amount of money. Values correspond to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217).""" + currency_rate: NotRequired[Nullable[float]] + r"""Currency Exchange Rate at the time entity was recorded/generated.""" + tax_inclusive: NotRequired[Nullable[bool]] + r"""Amounts are including tax""" + sub_total: NotRequired[Nullable[float]] + r"""Subtotal amount, normally before tax.""" + total_tax: NotRequired[Nullable[float]] + r"""Total tax amount applied to this transaction.""" + transaction_date: NotRequired[Nullable[datetime]] + r"""The date of the sales receipt transaction - YYYY-MM-DDThh:mm:ss.sTZD""" + payment_method: NotRequired[Nullable[str]] + r"""Payment method used for the transaction, such as cash, credit card, bank transfer, or check""" + payment_method_reference: NotRequired[Nullable[str]] + r"""Optional reference message returned by payment method on processing""" + payment_method_id: NotRequired[Nullable[str]] + r"""A unique identifier for an object.""" + account: NotRequired[Nullable[LinkedLedgerAccountTypedDict]] + line_items: NotRequired[List[InvoiceLineItemInputTypedDict]] + r"""Line items for itemized sales receipts. Used when the sales receipt includes product/service details with quantities and pricing.""" + tax_code: NotRequired[Nullable[str]] + r"""Applicable tax id/code override if tax is not supplied on a line item basis.""" + discount_percentage: NotRequired[Nullable[float]] + r"""Discount percentage applied to this sales receipt.""" + discount_amount: NotRequired[Nullable[float]] + r"""Discount amount applied to this sales receipt.""" + note: NotRequired[Nullable[str]] + r"""Optional note to be associated with the sales receipt.""" + customer_memo: NotRequired[Nullable[str]] + r"""Customer memo""" + reference: NotRequired[Nullable[str]] + r"""Optional reference message for the sales receipt.""" + billing_address: NotRequired[AddressTypedDict] + shipping_address: NotRequired[AddressTypedDict] + department: NotRequired[Nullable[LinkedDepartmentInputTypedDict]] + tracking_categories: NotRequired[ + Nullable[List[Nullable[LinkedTrackingCategoryTypedDict]]] + ] + r"""A list of linked tracking categories.""" + custom_fields: NotRequired[List[CustomFieldTypedDict]] + row_version: NotRequired[Nullable[str]] + r"""A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object.""" + pass_through: NotRequired[List[PassThroughBodyTypedDict]] + r"""The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources.""" + + +class SalesReceiptInput(BaseModel): + total_amount: Nullable[float] + r"""The total amount of the transaction or record""" + + number: OptionalNullable[str] = UNSET + r"""Reference number for the sales receipt.""" + + customer: OptionalNullable[LinkedCustomerInput] = UNSET + r"""The customer this entity is linked to.""" + + currency: Annotated[ + OptionalNullable[Currency], PlainValidator(validate_open_enum(False)) + ] = UNSET + r"""Indicates the associated currency for an amount of money. Values correspond to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217).""" + + currency_rate: OptionalNullable[float] = UNSET + r"""Currency Exchange Rate at the time entity was recorded/generated.""" + + tax_inclusive: OptionalNullable[bool] = UNSET + r"""Amounts are including tax""" + + sub_total: OptionalNullable[float] = UNSET + r"""Subtotal amount, normally before tax.""" + + total_tax: OptionalNullable[float] = UNSET + r"""Total tax amount applied to this transaction.""" + + transaction_date: OptionalNullable[datetime] = UNSET + r"""The date of the sales receipt transaction - YYYY-MM-DDThh:mm:ss.sTZD""" + + payment_method: OptionalNullable[str] = UNSET + r"""Payment method used for the transaction, such as cash, credit card, bank transfer, or check""" + + payment_method_reference: OptionalNullable[str] = UNSET + r"""Optional reference message returned by payment method on processing""" + + payment_method_id: OptionalNullable[str] = UNSET + r"""A unique identifier for an object.""" + + account: OptionalNullable[LinkedLedgerAccount] = UNSET + + line_items: Optional[List[InvoiceLineItemInput]] = None + r"""Line items for itemized sales receipts. Used when the sales receipt includes product/service details with quantities and pricing.""" + + tax_code: OptionalNullable[str] = UNSET + r"""Applicable tax id/code override if tax is not supplied on a line item basis.""" + + discount_percentage: OptionalNullable[float] = UNSET + r"""Discount percentage applied to this sales receipt.""" + + discount_amount: OptionalNullable[float] = UNSET + r"""Discount amount applied to this sales receipt.""" + + note: OptionalNullable[str] = UNSET + r"""Optional note to be associated with the sales receipt.""" + + customer_memo: OptionalNullable[str] = UNSET + r"""Customer memo""" + + reference: OptionalNullable[str] = UNSET + r"""Optional reference message for the sales receipt.""" + + billing_address: Optional[Address] = None + + shipping_address: Optional[Address] = None + + department: OptionalNullable[LinkedDepartmentInput] = UNSET + + tracking_categories: OptionalNullable[List[Nullable[LinkedTrackingCategory]]] = ( + UNSET + ) + r"""A list of linked tracking categories.""" + + custom_fields: Optional[List[CustomField]] = None + + row_version: OptionalNullable[str] = UNSET + r"""A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object.""" + + pass_through: Optional[List[PassThroughBody]] = None + r"""The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources.""" + + @field_serializer("currency") + def serialize_currency(self, value): + if isinstance(value, str): + try: + return models.Currency(value) + except ValueError: + return value + return value + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = [ + "number", + "customer", + "currency", + "currency_rate", + "tax_inclusive", + "sub_total", + "total_tax", + "transaction_date", + "payment_method", + "payment_method_reference", + "payment_method_id", + "account", + "line_items", + "tax_code", + "discount_percentage", + "discount_amount", + "note", + "customer_memo", + "reference", + "billing_address", + "shipping_address", + "department", + "tracking_categories", + "custom_fields", + "row_version", + "pass_through", + ] + nullable_fields = [ + "number", + "customer", + "currency", + "currency_rate", + "tax_inclusive", + "sub_total", + "total_amount", + "total_tax", + "transaction_date", + "payment_method", + "payment_method_reference", + "payment_method_id", + "account", + "tax_code", + "discount_percentage", + "discount_amount", + "note", + "customer_memo", + "reference", + "department", + "tracking_categories", + "row_version", + ] + null_default_fields = [] + + serialized = handler(self) + + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k) + serialized.pop(k, None) + + optional_nullable = k in optional_fields and k in nullable_fields + is_set = ( + self.__pydantic_fields_set__.intersection({n}) + or k in null_default_fields + ) # pylint: disable=no-member + + if val is not None and val != UNSET_SENTINEL: + m[k] = val + elif val != UNSET_SENTINEL and ( + not k in optional_fields or (optional_nullable and is_set) + ): + m[k] = val + + return m diff --git a/src/apideck_unify/models/salesreceiptsfilter.py b/src/apideck_unify/models/salesreceiptsfilter.py new file mode 100644 index 00000000..5cf2c27d --- /dev/null +++ b/src/apideck_unify/models/salesreceiptsfilter.py @@ -0,0 +1,21 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from apideck_unify.types import BaseModel +from apideck_unify.utils import FieldMetadata +from datetime import datetime +from typing import Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class SalesReceiptsFilterTypedDict(TypedDict): + updated_since: NotRequired[datetime] + customer_id: NotRequired[str] + r"""Filter by customer id""" + + +class SalesReceiptsFilter(BaseModel): + updated_since: Annotated[Optional[datetime], FieldMetadata(query=True)] = None + + customer_id: Annotated[Optional[str], FieldMetadata(query=True)] = None + r"""Filter by customer id""" diff --git a/src/apideck_unify/models/salesreceiptssort.py b/src/apideck_unify/models/salesreceiptssort.py new file mode 100644 index 00000000..d65b6f16 --- /dev/null +++ b/src/apideck_unify/models/salesreceiptssort.py @@ -0,0 +1,60 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .sortdirection import SortDirection +from apideck_unify import models, utils +from apideck_unify.types import BaseModel +from apideck_unify.utils import FieldMetadata, validate_open_enum +from enum import Enum +from pydantic import field_serializer +from pydantic.functional_validators import PlainValidator +from typing import Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class SalesReceiptsSortBy(str, Enum, metaclass=utils.OpenEnumMeta): + r"""The field on which to sort the Sales Receipts.""" + + UPDATED_AT = "updated_at" + CREATED_AT = "created_at" + + +class SalesReceiptsSortTypedDict(TypedDict): + by: NotRequired[SalesReceiptsSortBy] + r"""The field on which to sort the Sales Receipts.""" + direction: NotRequired[SortDirection] + r"""The direction in which to sort the results""" + + +class SalesReceiptsSort(BaseModel): + by: Annotated[ + Annotated[ + Optional[SalesReceiptsSortBy], PlainValidator(validate_open_enum(False)) + ], + FieldMetadata(query=True), + ] = None + r"""The field on which to sort the Sales Receipts.""" + + direction: Annotated[ + Annotated[Optional[SortDirection], PlainValidator(validate_open_enum(False))], + FieldMetadata(query=True), + ] = SortDirection.ASC + r"""The direction in which to sort the results""" + + @field_serializer("by") + def serialize_by(self, value): + if isinstance(value, str): + try: + return models.SalesReceiptsSortBy(value) + except ValueError: + return value + return value + + @field_serializer("direction") + def serialize_direction(self, value): + if isinstance(value, str): + try: + return models.SortDirection(value) + except ValueError: + return value + return value diff --git a/src/apideck_unify/models/updatepaymentmethodresponse.py b/src/apideck_unify/models/updatepaymentmethodresponse.py new file mode 100644 index 00000000..f6fb25f3 --- /dev/null +++ b/src/apideck_unify/models/updatepaymentmethodresponse.py @@ -0,0 +1,91 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .unifiedid import UnifiedID, UnifiedIDTypedDict +from apideck_unify.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import model_serializer +from typing import Any, Dict +from typing_extensions import Annotated, NotRequired, TypedDict + + +class UpdatePaymentMethodResponseTypedDict(TypedDict): + r"""Payment Methods""" + + status_code: int + r"""HTTP Response Status Code""" + status: str + r"""HTTP Response Status""" + service: str + r"""Apideck ID of service provider""" + resource: str + r"""Unified API resource name""" + operation: str + r"""Operation performed""" + data: UnifiedIDTypedDict + r"""A object containing a unique identifier for the resource that was created, updated, or deleted.""" + raw: NotRequired[Nullable[Dict[str, Any]]] + r"""Raw response from the integration when raw=true query param is provided""" + + +class UpdatePaymentMethodResponse(BaseModel): + r"""Payment Methods""" + + status_code: int + r"""HTTP Response Status Code""" + + status: str + r"""HTTP Response Status""" + + service: str + r"""Apideck ID of service provider""" + + resource: str + r"""Unified API resource name""" + + operation: str + r"""Operation performed""" + + data: UnifiedID + r"""A object containing a unique identifier for the resource that was created, updated, or deleted.""" + + raw: Annotated[OptionalNullable[Dict[str, Any]], pydantic.Field(alias="_raw")] = ( + UNSET + ) + r"""Raw response from the integration when raw=true query param is provided""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = ["_raw"] + nullable_fields = ["_raw"] + null_default_fields = [] + + serialized = handler(self) + + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k) + serialized.pop(k, None) + + optional_nullable = k in optional_fields and k in nullable_fields + is_set = ( + self.__pydantic_fields_set__.intersection({n}) + or k in null_default_fields + ) # pylint: disable=no-member + + if val is not None and val != UNSET_SENTINEL: + m[k] = val + elif val != UNSET_SENTINEL and ( + not k in optional_fields or (optional_nullable and is_set) + ): + m[k] = val + + return m diff --git a/src/apideck_unify/models/updatesalesreceiptresponse.py b/src/apideck_unify/models/updatesalesreceiptresponse.py new file mode 100644 index 00000000..1683424d --- /dev/null +++ b/src/apideck_unify/models/updatesalesreceiptresponse.py @@ -0,0 +1,91 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .unifiedid import UnifiedID, UnifiedIDTypedDict +from apideck_unify.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import model_serializer +from typing import Any, Dict +from typing_extensions import Annotated, NotRequired, TypedDict + + +class UpdateSalesReceiptResponseTypedDict(TypedDict): + r"""SalesReceipt updated""" + + status_code: int + r"""HTTP Response Status Code""" + status: str + r"""HTTP Response Status""" + service: str + r"""Apideck ID of service provider""" + resource: str + r"""Unified API resource name""" + operation: str + r"""Operation performed""" + data: UnifiedIDTypedDict + r"""A object containing a unique identifier for the resource that was created, updated, or deleted.""" + raw: NotRequired[Nullable[Dict[str, Any]]] + r"""Raw response from the integration when raw=true query param is provided""" + + +class UpdateSalesReceiptResponse(BaseModel): + r"""SalesReceipt updated""" + + status_code: int + r"""HTTP Response Status Code""" + + status: str + r"""HTTP Response Status""" + + service: str + r"""Apideck ID of service provider""" + + resource: str + r"""Unified API resource name""" + + operation: str + r"""Operation performed""" + + data: UnifiedID + r"""A object containing a unique identifier for the resource that was created, updated, or deleted.""" + + raw: Annotated[OptionalNullable[Dict[str, Any]], pydantic.Field(alias="_raw")] = ( + UNSET + ) + r"""Raw response from the integration when raw=true query param is provided""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = ["_raw"] + nullable_fields = ["_raw"] + null_default_fields = [] + + serialized = handler(self) + + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k) + serialized.pop(k, None) + + optional_nullable = k in optional_fields and k in nullable_fields + is_set = ( + self.__pydantic_fields_set__.intersection({n}) + or k in null_default_fields + ) # pylint: disable=no-member + + if val is not None and val != UNSET_SENTINEL: + m[k] = val + elif val != UNSET_SENTINEL and ( + not k in optional_fields or (optional_nullable and is_set) + ): + m[k] = val + + return m diff --git a/src/apideck_unify/paymentmethods.py b/src/apideck_unify/paymentmethods.py new file mode 100644 index 00000000..5fd5033f --- /dev/null +++ b/src/apideck_unify/paymentmethods.py @@ -0,0 +1,1602 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from .basesdk import BaseSDK +from apideck_unify import models, utils +from apideck_unify._hooks import HookContext +from apideck_unify.types import OptionalNullable, UNSET +from apideck_unify.utils import get_security_from_env +from apideck_unify.utils.unmarshal_json_response import unmarshal_json_response +from jsonpath import JSONPath +from typing import Any, Dict, List, Mapping, Optional, Union + + +class PaymentMethods(BaseSDK): + def list( + self, + *, + raw: Optional[bool] = False, + consumer_id: Optional[str] = None, + app_id: Optional[str] = None, + service_id: Optional[str] = None, + cursor: OptionalNullable[str] = UNSET, + limit: Optional[int] = 20, + fields: OptionalNullable[str] = UNSET, + pass_through: Optional[Dict[str, Any]] = None, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> Optional[models.AccountingPaymentMethodsAllResponse]: + r"""List Payment Methods + + List Payment Methods + + :param raw: Include raw response. Mostly used for debugging purposes + :param consumer_id: ID of the consumer which you want to get or push data from + :param app_id: The ID of your Unify application + :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. + :param cursor: Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. + :param limit: Number of results to return. Minimum 1, Maximum 200, Default 20 + :param fields: The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields \"name\", \"email\" and \"addresses.city\". If any other fields are available, they will be excluded. + :param pass_through: Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.AccountingPaymentMethodsAllRequest( + raw=raw, + consumer_id=consumer_id, + app_id=app_id, + service_id=service_id, + cursor=cursor, + limit=limit, + fields=fields, + pass_through=pass_through, + ) + + req = self._build_request( + method="GET", + path="/accounting/payment-methods", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=False, + request_has_path_params=False, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + _globals=models.AccountingPaymentMethodsAllGlobals( + consumer_id=self.sdk_configuration.globals.consumer_id, + app_id=self.sdk_configuration.globals.app_id, + ), + security=self.sdk_configuration.security, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + else: + retries = utils.RetryConfig( + "backoff", utils.BackoffStrategy(500, 60000, 1.5, 900000), True + ) + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["408", "500", "502", "503", "504"]) + + http_res = self.do_request( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="accounting.paymentMethodsAll", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + request=req, + error_status_codes=["400", "401", "402", "404", "422", "4XX", "5XX"], + retry_config=retry_config, + ) + + def next_func() -> Optional[models.AccountingPaymentMethodsAllResponse]: + body = utils.unmarshal_json(http_res.text, Union[Dict[Any, Any], List[Any]]) + next_cursor = JSONPath("$.meta.cursors.next").parse(body) + + if len(next_cursor) == 0: + return None + + next_cursor = next_cursor[0] + if next_cursor is None or str(next_cursor).strip() == "": + return None + + return self.list( + raw=raw, + consumer_id=consumer_id, + app_id=app_id, + service_id=service_id, + cursor=next_cursor, + limit=limit, + fields=fields, + pass_through=pass_through, + retries=retries, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return models.AccountingPaymentMethodsAllResponse( + get_payment_methods_response=unmarshal_json_response( + Optional[models.GetPaymentMethodsResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + next=next_func, + ) + if utils.match_response(http_res, "400", "application/json"): + response_data = unmarshal_json_response( + models.BadRequestResponseData, http_res + ) + raise models.BadRequestResponse(response_data, http_res) + if utils.match_response(http_res, "401", "application/json"): + response_data = unmarshal_json_response( + models.UnauthorizedResponseData, http_res + ) + raise models.UnauthorizedResponse(response_data, http_res) + if utils.match_response(http_res, "402", "application/json"): + response_data = unmarshal_json_response( + models.PaymentRequiredResponseData, http_res + ) + raise models.PaymentRequiredResponse(response_data, http_res) + if utils.match_response(http_res, "404", "application/json"): + response_data = unmarshal_json_response( + models.NotFoundResponseData, http_res + ) + raise models.NotFoundResponse(response_data, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + models.UnprocessableResponseData, http_res + ) + raise models.UnprocessableResponse(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "default", "application/json"): + return models.AccountingPaymentMethodsAllResponse( + unexpected_error_response=unmarshal_json_response( + Optional[models.UnexpectedErrorResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + next=next_func, + ) + + raise models.APIError("Unexpected response received", http_res) + + async def list_async( + self, + *, + raw: Optional[bool] = False, + consumer_id: Optional[str] = None, + app_id: Optional[str] = None, + service_id: Optional[str] = None, + cursor: OptionalNullable[str] = UNSET, + limit: Optional[int] = 20, + fields: OptionalNullable[str] = UNSET, + pass_through: Optional[Dict[str, Any]] = None, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> Optional[models.AccountingPaymentMethodsAllResponse]: + r"""List Payment Methods + + List Payment Methods + + :param raw: Include raw response. Mostly used for debugging purposes + :param consumer_id: ID of the consumer which you want to get or push data from + :param app_id: The ID of your Unify application + :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. + :param cursor: Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. + :param limit: Number of results to return. Minimum 1, Maximum 200, Default 20 + :param fields: The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields \"name\", \"email\" and \"addresses.city\". If any other fields are available, they will be excluded. + :param pass_through: Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.AccountingPaymentMethodsAllRequest( + raw=raw, + consumer_id=consumer_id, + app_id=app_id, + service_id=service_id, + cursor=cursor, + limit=limit, + fields=fields, + pass_through=pass_through, + ) + + req = self._build_request_async( + method="GET", + path="/accounting/payment-methods", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=False, + request_has_path_params=False, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + _globals=models.AccountingPaymentMethodsAllGlobals( + consumer_id=self.sdk_configuration.globals.consumer_id, + app_id=self.sdk_configuration.globals.app_id, + ), + security=self.sdk_configuration.security, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + else: + retries = utils.RetryConfig( + "backoff", utils.BackoffStrategy(500, 60000, 1.5, 900000), True + ) + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["408", "500", "502", "503", "504"]) + + http_res = await self.do_request_async( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="accounting.paymentMethodsAll", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + request=req, + error_status_codes=["400", "401", "402", "404", "422", "4XX", "5XX"], + retry_config=retry_config, + ) + + def next_func() -> Optional[models.AccountingPaymentMethodsAllResponse]: + body = utils.unmarshal_json(http_res.text, Union[Dict[Any, Any], List[Any]]) + next_cursor = JSONPath("$.meta.cursors.next").parse(body) + + if len(next_cursor) == 0: + return None + + next_cursor = next_cursor[0] + if next_cursor is None or str(next_cursor).strip() == "": + return None + + return self.list( + raw=raw, + consumer_id=consumer_id, + app_id=app_id, + service_id=service_id, + cursor=next_cursor, + limit=limit, + fields=fields, + pass_through=pass_through, + retries=retries, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return models.AccountingPaymentMethodsAllResponse( + get_payment_methods_response=unmarshal_json_response( + Optional[models.GetPaymentMethodsResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + next=next_func, + ) + if utils.match_response(http_res, "400", "application/json"): + response_data = unmarshal_json_response( + models.BadRequestResponseData, http_res + ) + raise models.BadRequestResponse(response_data, http_res) + if utils.match_response(http_res, "401", "application/json"): + response_data = unmarshal_json_response( + models.UnauthorizedResponseData, http_res + ) + raise models.UnauthorizedResponse(response_data, http_res) + if utils.match_response(http_res, "402", "application/json"): + response_data = unmarshal_json_response( + models.PaymentRequiredResponseData, http_res + ) + raise models.PaymentRequiredResponse(response_data, http_res) + if utils.match_response(http_res, "404", "application/json"): + response_data = unmarshal_json_response( + models.NotFoundResponseData, http_res + ) + raise models.NotFoundResponse(response_data, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + models.UnprocessableResponseData, http_res + ) + raise models.UnprocessableResponse(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "default", "application/json"): + return models.AccountingPaymentMethodsAllResponse( + unexpected_error_response=unmarshal_json_response( + Optional[models.UnexpectedErrorResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + next=next_func, + ) + + raise models.APIError("Unexpected response received", http_res) + + def create( + self, + *, + raw: Optional[bool] = False, + consumer_id: Optional[str] = None, + app_id: Optional[str] = None, + service_id: Optional[str] = None, + name: Optional[str] = None, + type_: OptionalNullable[models.AccountingPaymentMethodType] = UNSET, + status: OptionalNullable[models.AccountingPaymentMethodStatus] = UNSET, + row_version: OptionalNullable[str] = UNSET, + pass_through: Optional[ + Union[List[models.PassThroughBody], List[models.PassThroughBodyTypedDict]] + ] = None, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.AccountingPaymentMethodsAddResponse: + r"""Create Payment Method + + Create Payment Method + + :param raw: Include raw response. Mostly used for debugging purposes + :param consumer_id: ID of the consumer which you want to get or push data from + :param app_id: The ID of your Unify application + :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. + :param name: The name of the payment method. + :param type: The type of payment method. + :param status: The status of the payment method. + :param row_version: A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object. + :param pass_through: The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.AccountingPaymentMethodsAddRequest( + raw=raw, + consumer_id=consumer_id, + app_id=app_id, + service_id=service_id, + accounting_payment_method=models.AccountingPaymentMethodInput( + name=name, + type=type_, + status=status, + row_version=row_version, + pass_through=utils.get_pydantic_model( + pass_through, Optional[List[models.PassThroughBody]] + ), + ), + ) + + req = self._build_request( + method="POST", + path="/accounting/payment-methods", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=True, + request_has_path_params=False, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + _globals=models.AccountingPaymentMethodsAddGlobals( + consumer_id=self.sdk_configuration.globals.consumer_id, + app_id=self.sdk_configuration.globals.app_id, + ), + security=self.sdk_configuration.security, + get_serialized_body=lambda: utils.serialize_request_body( + request.accounting_payment_method, + False, + False, + "json", + models.AccountingPaymentMethodInput, + ), + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + else: + retries = utils.RetryConfig( + "backoff", utils.BackoffStrategy(500, 60000, 1.5, 900000), True + ) + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["408", "500", "502", "503", "504"]) + + http_res = self.do_request( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="accounting.paymentMethodsAdd", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + request=req, + error_status_codes=["400", "401", "402", "404", "422", "4XX", "5XX"], + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "201", "application/json"): + return models.AccountingPaymentMethodsAddResponse( + create_payment_method_response=unmarshal_json_response( + Optional[models.CreatePaymentMethodResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + if utils.match_response(http_res, "400", "application/json"): + response_data = unmarshal_json_response( + models.BadRequestResponseData, http_res + ) + raise models.BadRequestResponse(response_data, http_res) + if utils.match_response(http_res, "401", "application/json"): + response_data = unmarshal_json_response( + models.UnauthorizedResponseData, http_res + ) + raise models.UnauthorizedResponse(response_data, http_res) + if utils.match_response(http_res, "402", "application/json"): + response_data = unmarshal_json_response( + models.PaymentRequiredResponseData, http_res + ) + raise models.PaymentRequiredResponse(response_data, http_res) + if utils.match_response(http_res, "404", "application/json"): + response_data = unmarshal_json_response( + models.NotFoundResponseData, http_res + ) + raise models.NotFoundResponse(response_data, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + models.UnprocessableResponseData, http_res + ) + raise models.UnprocessableResponse(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "default", "application/json"): + return models.AccountingPaymentMethodsAddResponse( + unexpected_error_response=unmarshal_json_response( + Optional[models.UnexpectedErrorResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + + raise models.APIError("Unexpected response received", http_res) + + async def create_async( + self, + *, + raw: Optional[bool] = False, + consumer_id: Optional[str] = None, + app_id: Optional[str] = None, + service_id: Optional[str] = None, + name: Optional[str] = None, + type_: OptionalNullable[models.AccountingPaymentMethodType] = UNSET, + status: OptionalNullable[models.AccountingPaymentMethodStatus] = UNSET, + row_version: OptionalNullable[str] = UNSET, + pass_through: Optional[ + Union[List[models.PassThroughBody], List[models.PassThroughBodyTypedDict]] + ] = None, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.AccountingPaymentMethodsAddResponse: + r"""Create Payment Method + + Create Payment Method + + :param raw: Include raw response. Mostly used for debugging purposes + :param consumer_id: ID of the consumer which you want to get or push data from + :param app_id: The ID of your Unify application + :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. + :param name: The name of the payment method. + :param type: The type of payment method. + :param status: The status of the payment method. + :param row_version: A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object. + :param pass_through: The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.AccountingPaymentMethodsAddRequest( + raw=raw, + consumer_id=consumer_id, + app_id=app_id, + service_id=service_id, + accounting_payment_method=models.AccountingPaymentMethodInput( + name=name, + type=type_, + status=status, + row_version=row_version, + pass_through=utils.get_pydantic_model( + pass_through, Optional[List[models.PassThroughBody]] + ), + ), + ) + + req = self._build_request_async( + method="POST", + path="/accounting/payment-methods", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=True, + request_has_path_params=False, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + _globals=models.AccountingPaymentMethodsAddGlobals( + consumer_id=self.sdk_configuration.globals.consumer_id, + app_id=self.sdk_configuration.globals.app_id, + ), + security=self.sdk_configuration.security, + get_serialized_body=lambda: utils.serialize_request_body( + request.accounting_payment_method, + False, + False, + "json", + models.AccountingPaymentMethodInput, + ), + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + else: + retries = utils.RetryConfig( + "backoff", utils.BackoffStrategy(500, 60000, 1.5, 900000), True + ) + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["408", "500", "502", "503", "504"]) + + http_res = await self.do_request_async( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="accounting.paymentMethodsAdd", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + request=req, + error_status_codes=["400", "401", "402", "404", "422", "4XX", "5XX"], + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "201", "application/json"): + return models.AccountingPaymentMethodsAddResponse( + create_payment_method_response=unmarshal_json_response( + Optional[models.CreatePaymentMethodResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + if utils.match_response(http_res, "400", "application/json"): + response_data = unmarshal_json_response( + models.BadRequestResponseData, http_res + ) + raise models.BadRequestResponse(response_data, http_res) + if utils.match_response(http_res, "401", "application/json"): + response_data = unmarshal_json_response( + models.UnauthorizedResponseData, http_res + ) + raise models.UnauthorizedResponse(response_data, http_res) + if utils.match_response(http_res, "402", "application/json"): + response_data = unmarshal_json_response( + models.PaymentRequiredResponseData, http_res + ) + raise models.PaymentRequiredResponse(response_data, http_res) + if utils.match_response(http_res, "404", "application/json"): + response_data = unmarshal_json_response( + models.NotFoundResponseData, http_res + ) + raise models.NotFoundResponse(response_data, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + models.UnprocessableResponseData, http_res + ) + raise models.UnprocessableResponse(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "default", "application/json"): + return models.AccountingPaymentMethodsAddResponse( + unexpected_error_response=unmarshal_json_response( + Optional[models.UnexpectedErrorResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + + raise models.APIError("Unexpected response received", http_res) + + def get( + self, + *, + id: str, + consumer_id: Optional[str] = None, + app_id: Optional[str] = None, + service_id: Optional[str] = None, + raw: Optional[bool] = False, + fields: OptionalNullable[str] = UNSET, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.AccountingPaymentMethodsOneResponse: + r"""Get Payment Method + + Get Payment Method + + :param id: ID of the record you are acting upon. + :param consumer_id: ID of the consumer which you want to get or push data from + :param app_id: The ID of your Unify application + :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. + :param raw: Include raw response. Mostly used for debugging purposes + :param fields: The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields \"name\", \"email\" and \"addresses.city\". If any other fields are available, they will be excluded. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.AccountingPaymentMethodsOneRequest( + id=id, + consumer_id=consumer_id, + app_id=app_id, + service_id=service_id, + raw=raw, + fields=fields, + ) + + req = self._build_request( + method="GET", + path="/accounting/payment-methods/{id}", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=False, + request_has_path_params=True, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + _globals=models.AccountingPaymentMethodsOneGlobals( + consumer_id=self.sdk_configuration.globals.consumer_id, + app_id=self.sdk_configuration.globals.app_id, + ), + security=self.sdk_configuration.security, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + else: + retries = utils.RetryConfig( + "backoff", utils.BackoffStrategy(500, 60000, 1.5, 900000), True + ) + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["408", "500", "502", "503", "504"]) + + http_res = self.do_request( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="accounting.paymentMethodsOne", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + request=req, + error_status_codes=["400", "401", "402", "404", "422", "4XX", "5XX"], + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return models.AccountingPaymentMethodsOneResponse( + get_payment_method_response=unmarshal_json_response( + Optional[models.GetPaymentMethodResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + if utils.match_response(http_res, "400", "application/json"): + response_data = unmarshal_json_response( + models.BadRequestResponseData, http_res + ) + raise models.BadRequestResponse(response_data, http_res) + if utils.match_response(http_res, "401", "application/json"): + response_data = unmarshal_json_response( + models.UnauthorizedResponseData, http_res + ) + raise models.UnauthorizedResponse(response_data, http_res) + if utils.match_response(http_res, "402", "application/json"): + response_data = unmarshal_json_response( + models.PaymentRequiredResponseData, http_res + ) + raise models.PaymentRequiredResponse(response_data, http_res) + if utils.match_response(http_res, "404", "application/json"): + response_data = unmarshal_json_response( + models.NotFoundResponseData, http_res + ) + raise models.NotFoundResponse(response_data, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + models.UnprocessableResponseData, http_res + ) + raise models.UnprocessableResponse(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "default", "application/json"): + return models.AccountingPaymentMethodsOneResponse( + unexpected_error_response=unmarshal_json_response( + Optional[models.UnexpectedErrorResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + + raise models.APIError("Unexpected response received", http_res) + + async def get_async( + self, + *, + id: str, + consumer_id: Optional[str] = None, + app_id: Optional[str] = None, + service_id: Optional[str] = None, + raw: Optional[bool] = False, + fields: OptionalNullable[str] = UNSET, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.AccountingPaymentMethodsOneResponse: + r"""Get Payment Method + + Get Payment Method + + :param id: ID of the record you are acting upon. + :param consumer_id: ID of the consumer which you want to get or push data from + :param app_id: The ID of your Unify application + :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. + :param raw: Include raw response. Mostly used for debugging purposes + :param fields: The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields \"name\", \"email\" and \"addresses.city\". If any other fields are available, they will be excluded. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.AccountingPaymentMethodsOneRequest( + id=id, + consumer_id=consumer_id, + app_id=app_id, + service_id=service_id, + raw=raw, + fields=fields, + ) + + req = self._build_request_async( + method="GET", + path="/accounting/payment-methods/{id}", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=False, + request_has_path_params=True, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + _globals=models.AccountingPaymentMethodsOneGlobals( + consumer_id=self.sdk_configuration.globals.consumer_id, + app_id=self.sdk_configuration.globals.app_id, + ), + security=self.sdk_configuration.security, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + else: + retries = utils.RetryConfig( + "backoff", utils.BackoffStrategy(500, 60000, 1.5, 900000), True + ) + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["408", "500", "502", "503", "504"]) + + http_res = await self.do_request_async( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="accounting.paymentMethodsOne", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + request=req, + error_status_codes=["400", "401", "402", "404", "422", "4XX", "5XX"], + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return models.AccountingPaymentMethodsOneResponse( + get_payment_method_response=unmarshal_json_response( + Optional[models.GetPaymentMethodResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + if utils.match_response(http_res, "400", "application/json"): + response_data = unmarshal_json_response( + models.BadRequestResponseData, http_res + ) + raise models.BadRequestResponse(response_data, http_res) + if utils.match_response(http_res, "401", "application/json"): + response_data = unmarshal_json_response( + models.UnauthorizedResponseData, http_res + ) + raise models.UnauthorizedResponse(response_data, http_res) + if utils.match_response(http_res, "402", "application/json"): + response_data = unmarshal_json_response( + models.PaymentRequiredResponseData, http_res + ) + raise models.PaymentRequiredResponse(response_data, http_res) + if utils.match_response(http_res, "404", "application/json"): + response_data = unmarshal_json_response( + models.NotFoundResponseData, http_res + ) + raise models.NotFoundResponse(response_data, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + models.UnprocessableResponseData, http_res + ) + raise models.UnprocessableResponse(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "default", "application/json"): + return models.AccountingPaymentMethodsOneResponse( + unexpected_error_response=unmarshal_json_response( + Optional[models.UnexpectedErrorResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + + raise models.APIError("Unexpected response received", http_res) + + def update( + self, + *, + id: str, + consumer_id: Optional[str] = None, + app_id: Optional[str] = None, + service_id: Optional[str] = None, + raw: Optional[bool] = False, + name: Optional[str] = None, + type_: OptionalNullable[models.AccountingPaymentMethodType] = UNSET, + status: OptionalNullable[models.AccountingPaymentMethodStatus] = UNSET, + row_version: OptionalNullable[str] = UNSET, + pass_through: Optional[ + Union[List[models.PassThroughBody], List[models.PassThroughBodyTypedDict]] + ] = None, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.AccountingPaymentMethodsUpdateResponse: + r"""Update Payment Method + + Update Payment Method + + :param id: ID of the record you are acting upon. + :param consumer_id: ID of the consumer which you want to get or push data from + :param app_id: The ID of your Unify application + :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. + :param raw: Include raw response. Mostly used for debugging purposes + :param name: The name of the payment method. + :param type: The type of payment method. + :param status: The status of the payment method. + :param row_version: A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object. + :param pass_through: The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.AccountingPaymentMethodsUpdateRequest( + id=id, + consumer_id=consumer_id, + app_id=app_id, + service_id=service_id, + raw=raw, + accounting_payment_method=models.AccountingPaymentMethodInput( + name=name, + type=type_, + status=status, + row_version=row_version, + pass_through=utils.get_pydantic_model( + pass_through, Optional[List[models.PassThroughBody]] + ), + ), + ) + + req = self._build_request( + method="PATCH", + path="/accounting/payment-methods/{id}", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=True, + request_has_path_params=True, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + _globals=models.AccountingPaymentMethodsUpdateGlobals( + consumer_id=self.sdk_configuration.globals.consumer_id, + app_id=self.sdk_configuration.globals.app_id, + ), + security=self.sdk_configuration.security, + get_serialized_body=lambda: utils.serialize_request_body( + request.accounting_payment_method, + False, + False, + "json", + models.AccountingPaymentMethodInput, + ), + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + else: + retries = utils.RetryConfig( + "backoff", utils.BackoffStrategy(500, 60000, 1.5, 900000), True + ) + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["408", "500", "502", "503", "504"]) + + http_res = self.do_request( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="accounting.paymentMethodsUpdate", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + request=req, + error_status_codes=["400", "401", "402", "404", "422", "4XX", "5XX"], + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return models.AccountingPaymentMethodsUpdateResponse( + update_payment_method_response=unmarshal_json_response( + Optional[models.UpdatePaymentMethodResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + if utils.match_response(http_res, "400", "application/json"): + response_data = unmarshal_json_response( + models.BadRequestResponseData, http_res + ) + raise models.BadRequestResponse(response_data, http_res) + if utils.match_response(http_res, "401", "application/json"): + response_data = unmarshal_json_response( + models.UnauthorizedResponseData, http_res + ) + raise models.UnauthorizedResponse(response_data, http_res) + if utils.match_response(http_res, "402", "application/json"): + response_data = unmarshal_json_response( + models.PaymentRequiredResponseData, http_res + ) + raise models.PaymentRequiredResponse(response_data, http_res) + if utils.match_response(http_res, "404", "application/json"): + response_data = unmarshal_json_response( + models.NotFoundResponseData, http_res + ) + raise models.NotFoundResponse(response_data, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + models.UnprocessableResponseData, http_res + ) + raise models.UnprocessableResponse(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "default", "application/json"): + return models.AccountingPaymentMethodsUpdateResponse( + unexpected_error_response=unmarshal_json_response( + Optional[models.UnexpectedErrorResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + + raise models.APIError("Unexpected response received", http_res) + + async def update_async( + self, + *, + id: str, + consumer_id: Optional[str] = None, + app_id: Optional[str] = None, + service_id: Optional[str] = None, + raw: Optional[bool] = False, + name: Optional[str] = None, + type_: OptionalNullable[models.AccountingPaymentMethodType] = UNSET, + status: OptionalNullable[models.AccountingPaymentMethodStatus] = UNSET, + row_version: OptionalNullable[str] = UNSET, + pass_through: Optional[ + Union[List[models.PassThroughBody], List[models.PassThroughBodyTypedDict]] + ] = None, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.AccountingPaymentMethodsUpdateResponse: + r"""Update Payment Method + + Update Payment Method + + :param id: ID of the record you are acting upon. + :param consumer_id: ID of the consumer which you want to get or push data from + :param app_id: The ID of your Unify application + :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. + :param raw: Include raw response. Mostly used for debugging purposes + :param name: The name of the payment method. + :param type: The type of payment method. + :param status: The status of the payment method. + :param row_version: A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object. + :param pass_through: The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.AccountingPaymentMethodsUpdateRequest( + id=id, + consumer_id=consumer_id, + app_id=app_id, + service_id=service_id, + raw=raw, + accounting_payment_method=models.AccountingPaymentMethodInput( + name=name, + type=type_, + status=status, + row_version=row_version, + pass_through=utils.get_pydantic_model( + pass_through, Optional[List[models.PassThroughBody]] + ), + ), + ) + + req = self._build_request_async( + method="PATCH", + path="/accounting/payment-methods/{id}", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=True, + request_has_path_params=True, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + _globals=models.AccountingPaymentMethodsUpdateGlobals( + consumer_id=self.sdk_configuration.globals.consumer_id, + app_id=self.sdk_configuration.globals.app_id, + ), + security=self.sdk_configuration.security, + get_serialized_body=lambda: utils.serialize_request_body( + request.accounting_payment_method, + False, + False, + "json", + models.AccountingPaymentMethodInput, + ), + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + else: + retries = utils.RetryConfig( + "backoff", utils.BackoffStrategy(500, 60000, 1.5, 900000), True + ) + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["408", "500", "502", "503", "504"]) + + http_res = await self.do_request_async( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="accounting.paymentMethodsUpdate", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + request=req, + error_status_codes=["400", "401", "402", "404", "422", "4XX", "5XX"], + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return models.AccountingPaymentMethodsUpdateResponse( + update_payment_method_response=unmarshal_json_response( + Optional[models.UpdatePaymentMethodResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + if utils.match_response(http_res, "400", "application/json"): + response_data = unmarshal_json_response( + models.BadRequestResponseData, http_res + ) + raise models.BadRequestResponse(response_data, http_res) + if utils.match_response(http_res, "401", "application/json"): + response_data = unmarshal_json_response( + models.UnauthorizedResponseData, http_res + ) + raise models.UnauthorizedResponse(response_data, http_res) + if utils.match_response(http_res, "402", "application/json"): + response_data = unmarshal_json_response( + models.PaymentRequiredResponseData, http_res + ) + raise models.PaymentRequiredResponse(response_data, http_res) + if utils.match_response(http_res, "404", "application/json"): + response_data = unmarshal_json_response( + models.NotFoundResponseData, http_res + ) + raise models.NotFoundResponse(response_data, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + models.UnprocessableResponseData, http_res + ) + raise models.UnprocessableResponse(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "default", "application/json"): + return models.AccountingPaymentMethodsUpdateResponse( + unexpected_error_response=unmarshal_json_response( + Optional[models.UnexpectedErrorResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + + raise models.APIError("Unexpected response received", http_res) + + def delete( + self, + *, + id: str, + consumer_id: Optional[str] = None, + app_id: Optional[str] = None, + service_id: Optional[str] = None, + raw: Optional[bool] = False, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.AccountingPaymentMethodsDeleteResponse: + r"""Delete Payment Method + + Delete Payment Method + + :param id: ID of the record you are acting upon. + :param consumer_id: ID of the consumer which you want to get or push data from + :param app_id: The ID of your Unify application + :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. + :param raw: Include raw response. Mostly used for debugging purposes + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.AccountingPaymentMethodsDeleteRequest( + id=id, + consumer_id=consumer_id, + app_id=app_id, + service_id=service_id, + raw=raw, + ) + + req = self._build_request( + method="DELETE", + path="/accounting/payment-methods/{id}", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=False, + request_has_path_params=True, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + _globals=models.AccountingPaymentMethodsDeleteGlobals( + consumer_id=self.sdk_configuration.globals.consumer_id, + app_id=self.sdk_configuration.globals.app_id, + ), + security=self.sdk_configuration.security, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + else: + retries = utils.RetryConfig( + "backoff", utils.BackoffStrategy(500, 60000, 1.5, 900000), True + ) + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["408", "500", "502", "503", "504"]) + + http_res = self.do_request( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="accounting.paymentMethodsDelete", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + request=req, + error_status_codes=["400", "401", "402", "404", "422", "4XX", "5XX"], + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return models.AccountingPaymentMethodsDeleteResponse( + delete_payment_method_response=unmarshal_json_response( + Optional[models.DeletePaymentMethodResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + if utils.match_response(http_res, "400", "application/json"): + response_data = unmarshal_json_response( + models.BadRequestResponseData, http_res + ) + raise models.BadRequestResponse(response_data, http_res) + if utils.match_response(http_res, "401", "application/json"): + response_data = unmarshal_json_response( + models.UnauthorizedResponseData, http_res + ) + raise models.UnauthorizedResponse(response_data, http_res) + if utils.match_response(http_res, "402", "application/json"): + response_data = unmarshal_json_response( + models.PaymentRequiredResponseData, http_res + ) + raise models.PaymentRequiredResponse(response_data, http_res) + if utils.match_response(http_res, "404", "application/json"): + response_data = unmarshal_json_response( + models.NotFoundResponseData, http_res + ) + raise models.NotFoundResponse(response_data, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + models.UnprocessableResponseData, http_res + ) + raise models.UnprocessableResponse(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "default", "application/json"): + return models.AccountingPaymentMethodsDeleteResponse( + unexpected_error_response=unmarshal_json_response( + Optional[models.UnexpectedErrorResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + + raise models.APIError("Unexpected response received", http_res) + + async def delete_async( + self, + *, + id: str, + consumer_id: Optional[str] = None, + app_id: Optional[str] = None, + service_id: Optional[str] = None, + raw: Optional[bool] = False, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.AccountingPaymentMethodsDeleteResponse: + r"""Delete Payment Method + + Delete Payment Method + + :param id: ID of the record you are acting upon. + :param consumer_id: ID of the consumer which you want to get or push data from + :param app_id: The ID of your Unify application + :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. + :param raw: Include raw response. Mostly used for debugging purposes + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.AccountingPaymentMethodsDeleteRequest( + id=id, + consumer_id=consumer_id, + app_id=app_id, + service_id=service_id, + raw=raw, + ) + + req = self._build_request_async( + method="DELETE", + path="/accounting/payment-methods/{id}", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=False, + request_has_path_params=True, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + _globals=models.AccountingPaymentMethodsDeleteGlobals( + consumer_id=self.sdk_configuration.globals.consumer_id, + app_id=self.sdk_configuration.globals.app_id, + ), + security=self.sdk_configuration.security, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + else: + retries = utils.RetryConfig( + "backoff", utils.BackoffStrategy(500, 60000, 1.5, 900000), True + ) + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["408", "500", "502", "503", "504"]) + + http_res = await self.do_request_async( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="accounting.paymentMethodsDelete", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + request=req, + error_status_codes=["400", "401", "402", "404", "422", "4XX", "5XX"], + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return models.AccountingPaymentMethodsDeleteResponse( + delete_payment_method_response=unmarshal_json_response( + Optional[models.DeletePaymentMethodResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + if utils.match_response(http_res, "400", "application/json"): + response_data = unmarshal_json_response( + models.BadRequestResponseData, http_res + ) + raise models.BadRequestResponse(response_data, http_res) + if utils.match_response(http_res, "401", "application/json"): + response_data = unmarshal_json_response( + models.UnauthorizedResponseData, http_res + ) + raise models.UnauthorizedResponse(response_data, http_res) + if utils.match_response(http_res, "402", "application/json"): + response_data = unmarshal_json_response( + models.PaymentRequiredResponseData, http_res + ) + raise models.PaymentRequiredResponse(response_data, http_res) + if utils.match_response(http_res, "404", "application/json"): + response_data = unmarshal_json_response( + models.NotFoundResponseData, http_res + ) + raise models.NotFoundResponse(response_data, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + models.UnprocessableResponseData, http_res + ) + raise models.UnprocessableResponse(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "default", "application/json"): + return models.AccountingPaymentMethodsDeleteResponse( + unexpected_error_response=unmarshal_json_response( + Optional[models.UnexpectedErrorResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + + raise models.APIError("Unexpected response received", http_res) diff --git a/src/apideck_unify/proxy.py b/src/apideck_unify/proxy.py index 2e152598..6b9982c9 100644 --- a/src/apideck_unify/proxy.py +++ b/src/apideck_unify/proxy.py @@ -82,6 +82,7 @@ def get( unified_api: Optional[str] = None, downstream_authorization: Optional[str] = None, timeout: Optional[int] = 28000, + follow_redirects: Optional[bool] = True, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, @@ -101,6 +102,7 @@ def get( :param unified_api: Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. :param downstream_authorization: Downstream authorization header. This will skip the Vault token injection. :param timeout: Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). + :param follow_redirects: Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds @@ -125,6 +127,7 @@ def get( downstream_url=downstream_url, downstream_authorization=downstream_authorization, timeout=timeout, + follow_redirects=follow_redirects, ) req = self._build_request( @@ -276,6 +279,7 @@ async def get_async( unified_api: Optional[str] = None, downstream_authorization: Optional[str] = None, timeout: Optional[int] = 28000, + follow_redirects: Optional[bool] = True, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, @@ -295,6 +299,7 @@ async def get_async( :param unified_api: Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. :param downstream_authorization: Downstream authorization header. This will skip the Vault token injection. :param timeout: Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). + :param follow_redirects: Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds @@ -319,6 +324,7 @@ async def get_async( downstream_url=downstream_url, downstream_authorization=downstream_authorization, timeout=timeout, + follow_redirects=follow_redirects, ) req = self._build_request_async( @@ -470,6 +476,7 @@ def options( unified_api: Optional[str] = None, downstream_authorization: Optional[str] = None, timeout: Optional[int] = 28000, + follow_redirects: Optional[bool] = True, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, @@ -489,6 +496,7 @@ def options( :param unified_api: Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. :param downstream_authorization: Downstream authorization header. This will skip the Vault token injection. :param timeout: Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). + :param follow_redirects: Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds @@ -513,6 +521,7 @@ def options( downstream_url=downstream_url, downstream_authorization=downstream_authorization, timeout=timeout, + follow_redirects=follow_redirects, ) req = self._build_request( @@ -664,6 +673,7 @@ async def options_async( unified_api: Optional[str] = None, downstream_authorization: Optional[str] = None, timeout: Optional[int] = 28000, + follow_redirects: Optional[bool] = True, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, @@ -683,6 +693,7 @@ async def options_async( :param unified_api: Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. :param downstream_authorization: Downstream authorization header. This will skip the Vault token injection. :param timeout: Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). + :param follow_redirects: Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds @@ -707,6 +718,7 @@ async def options_async( downstream_url=downstream_url, downstream_authorization=downstream_authorization, timeout=timeout, + follow_redirects=follow_redirects, ) req = self._build_request_async( @@ -858,6 +870,7 @@ def post( unified_api: Optional[str] = None, downstream_authorization: Optional[str] = None, timeout: Optional[int] = 28000, + follow_redirects: Optional[bool] = True, request_body: Optional[Union[bytes, IO[bytes], io.BufferedReader]] = None, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, @@ -878,6 +891,7 @@ def post( :param unified_api: Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. :param downstream_authorization: Downstream authorization header. This will skip the Vault token injection. :param timeout: Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). + :param follow_redirects: Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. :param request_body: Depending on the verb/method of the request this will contain the request body you want to POST/PATCH/PUT. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method @@ -903,6 +917,7 @@ def post( downstream_url=downstream_url, downstream_authorization=downstream_authorization, timeout=timeout, + follow_redirects=follow_redirects, request_body=request_body, ) @@ -1062,6 +1077,7 @@ async def post_async( unified_api: Optional[str] = None, downstream_authorization: Optional[str] = None, timeout: Optional[int] = 28000, + follow_redirects: Optional[bool] = True, request_body: Optional[Union[bytes, IO[bytes], io.BufferedReader]] = None, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, @@ -1082,6 +1098,7 @@ async def post_async( :param unified_api: Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. :param downstream_authorization: Downstream authorization header. This will skip the Vault token injection. :param timeout: Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). + :param follow_redirects: Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. :param request_body: Depending on the verb/method of the request this will contain the request body you want to POST/PATCH/PUT. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method @@ -1107,6 +1124,7 @@ async def post_async( downstream_url=downstream_url, downstream_authorization=downstream_authorization, timeout=timeout, + follow_redirects=follow_redirects, request_body=request_body, ) @@ -1266,6 +1284,7 @@ def put( unified_api: Optional[str] = None, downstream_authorization: Optional[str] = None, timeout: Optional[int] = 28000, + follow_redirects: Optional[bool] = True, request_body: Optional[Union[bytes, IO[bytes], io.BufferedReader]] = None, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, @@ -1286,6 +1305,7 @@ def put( :param unified_api: Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. :param downstream_authorization: Downstream authorization header. This will skip the Vault token injection. :param timeout: Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). + :param follow_redirects: Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. :param request_body: Depending on the verb/method of the request this will contain the request body you want to POST/PATCH/PUT. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method @@ -1311,6 +1331,7 @@ def put( downstream_url=downstream_url, downstream_authorization=downstream_authorization, timeout=timeout, + follow_redirects=follow_redirects, request_body=request_body, ) @@ -1470,6 +1491,7 @@ async def put_async( unified_api: Optional[str] = None, downstream_authorization: Optional[str] = None, timeout: Optional[int] = 28000, + follow_redirects: Optional[bool] = True, request_body: Optional[Union[bytes, IO[bytes], io.BufferedReader]] = None, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, @@ -1490,6 +1512,7 @@ async def put_async( :param unified_api: Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. :param downstream_authorization: Downstream authorization header. This will skip the Vault token injection. :param timeout: Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). + :param follow_redirects: Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. :param request_body: Depending on the verb/method of the request this will contain the request body you want to POST/PATCH/PUT. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method @@ -1515,6 +1538,7 @@ async def put_async( downstream_url=downstream_url, downstream_authorization=downstream_authorization, timeout=timeout, + follow_redirects=follow_redirects, request_body=request_body, ) @@ -1674,6 +1698,7 @@ def patch( unified_api: Optional[str] = None, downstream_authorization: Optional[str] = None, timeout: Optional[int] = 28000, + follow_redirects: Optional[bool] = True, request_body: Optional[Union[bytes, IO[bytes], io.BufferedReader]] = None, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, @@ -1694,6 +1719,7 @@ def patch( :param unified_api: Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. :param downstream_authorization: Downstream authorization header. This will skip the Vault token injection. :param timeout: Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). + :param follow_redirects: Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. :param request_body: Depending on the verb/method of the request this will contain the request body you want to POST/PATCH/PUT. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method @@ -1719,6 +1745,7 @@ def patch( downstream_url=downstream_url, downstream_authorization=downstream_authorization, timeout=timeout, + follow_redirects=follow_redirects, request_body=request_body, ) @@ -1878,6 +1905,7 @@ async def patch_async( unified_api: Optional[str] = None, downstream_authorization: Optional[str] = None, timeout: Optional[int] = 28000, + follow_redirects: Optional[bool] = True, request_body: Optional[Union[bytes, IO[bytes], io.BufferedReader]] = None, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, @@ -1898,6 +1926,7 @@ async def patch_async( :param unified_api: Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. :param downstream_authorization: Downstream authorization header. This will skip the Vault token injection. :param timeout: Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). + :param follow_redirects: Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. :param request_body: Depending on the verb/method of the request this will contain the request body you want to POST/PATCH/PUT. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method @@ -1923,6 +1952,7 @@ async def patch_async( downstream_url=downstream_url, downstream_authorization=downstream_authorization, timeout=timeout, + follow_redirects=follow_redirects, request_body=request_body, ) @@ -2082,6 +2112,7 @@ def delete( unified_api: Optional[str] = None, downstream_authorization: Optional[str] = None, timeout: Optional[int] = 28000, + follow_redirects: Optional[bool] = True, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, @@ -2101,6 +2132,7 @@ def delete( :param unified_api: Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. :param downstream_authorization: Downstream authorization header. This will skip the Vault token injection. :param timeout: Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). + :param follow_redirects: Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds @@ -2125,6 +2157,7 @@ def delete( downstream_url=downstream_url, downstream_authorization=downstream_authorization, timeout=timeout, + follow_redirects=follow_redirects, ) req = self._build_request( @@ -2276,6 +2309,7 @@ async def delete_async( unified_api: Optional[str] = None, downstream_authorization: Optional[str] = None, timeout: Optional[int] = 28000, + follow_redirects: Optional[bool] = True, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, @@ -2295,6 +2329,7 @@ async def delete_async( :param unified_api: Specify which unified API to use for the connection lookup. Required for multi-API connectors (e.g., Workday) to ensure the correct credentials are used. :param downstream_authorization: Downstream authorization header. This will skip the Vault token injection. :param timeout: Override the default downstream request timeout in milliseconds. The default is 28000 (28 seconds). + :param follow_redirects: Set to `false` to opt out of the redirect to the presigned download URL. Instead of a `30x` response, you receive a `200` JSON body `{ url, expires_at }` containing the URL and its expiry, which you can fetch explicitly. Use this if your client automatically forwards the `Authorization` header onto redirects, since the downstream storage provider will reject that request. Any value other than `false` (or omitting the header) preserves the default redirect behavior. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds @@ -2319,6 +2354,7 @@ async def delete_async( downstream_url=downstream_url, downstream_authorization=downstream_authorization, timeout=timeout, + follow_redirects=follow_redirects, ) req = self._build_request_async( diff --git a/src/apideck_unify/salesreceipts.py b/src/apideck_unify/salesreceipts.py new file mode 100644 index 00000000..54673c24 --- /dev/null +++ b/src/apideck_unify/salesreceipts.py @@ -0,0 +1,2067 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from .basesdk import BaseSDK +from apideck_unify import models, utils +from apideck_unify._hooks import HookContext +from apideck_unify.types import Nullable, OptionalNullable, UNSET +from apideck_unify.utils import get_security_from_env +from apideck_unify.utils.unmarshal_json_response import unmarshal_json_response +from datetime import datetime +from jsonpath import JSONPath +from typing import Any, Dict, List, Mapping, Optional, Union + + +class SalesReceipts(BaseSDK): + def list( + self, + *, + raw: Optional[bool] = False, + consumer_id: Optional[str] = None, + app_id: Optional[str] = None, + service_id: Optional[str] = None, + company_id: Optional[str] = None, + cursor: OptionalNullable[str] = UNSET, + limit: Optional[int] = 20, + filter_: Optional[ + Union[models.SalesReceiptsFilter, models.SalesReceiptsFilterTypedDict] + ] = None, + sort: Optional[ + Union[models.SalesReceiptsSort, models.SalesReceiptsSortTypedDict] + ] = None, + pass_through: Optional[Dict[str, Any]] = None, + fields: OptionalNullable[str] = UNSET, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> Optional[models.AccountingSalesReceiptsAllResponse]: + r"""List Sales Receipts + + List Sales Receipts + + :param raw: Include raw response. Mostly used for debugging purposes + :param consumer_id: ID of the consumer which you want to get or push data from + :param app_id: The ID of your Unify application + :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. + :param company_id: The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings. + :param cursor: Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. + :param limit: Number of results to return. Minimum 1, Maximum 200, Default 20 + :param filter_: Apply filters + :param sort: Apply sorting + :param pass_through: Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads + :param fields: The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields \"name\", \"email\" and \"addresses.city\". If any other fields are available, they will be excluded. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.AccountingSalesReceiptsAllRequest( + raw=raw, + consumer_id=consumer_id, + app_id=app_id, + service_id=service_id, + company_id=company_id, + cursor=cursor, + limit=limit, + filter_=utils.get_pydantic_model( + filter_, Optional[models.SalesReceiptsFilter] + ), + sort=utils.get_pydantic_model(sort, Optional[models.SalesReceiptsSort]), + pass_through=pass_through, + fields=fields, + ) + + req = self._build_request( + method="GET", + path="/accounting/sales-receipts", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=False, + request_has_path_params=False, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + _globals=models.AccountingSalesReceiptsAllGlobals( + consumer_id=self.sdk_configuration.globals.consumer_id, + app_id=self.sdk_configuration.globals.app_id, + ), + security=self.sdk_configuration.security, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + else: + retries = utils.RetryConfig( + "backoff", utils.BackoffStrategy(500, 60000, 1.5, 900000), True + ) + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["408", "500", "502", "503", "504"]) + + http_res = self.do_request( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="accounting.salesReceiptsAll", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + request=req, + error_status_codes=["400", "401", "402", "404", "422", "4XX", "5XX"], + retry_config=retry_config, + ) + + def next_func() -> Optional[models.AccountingSalesReceiptsAllResponse]: + body = utils.unmarshal_json(http_res.text, Union[Dict[Any, Any], List[Any]]) + next_cursor = JSONPath("$.meta.cursors.next").parse(body) + + if len(next_cursor) == 0: + return None + + next_cursor = next_cursor[0] + if next_cursor is None or str(next_cursor).strip() == "": + return None + + return self.list( + raw=raw, + consumer_id=consumer_id, + app_id=app_id, + service_id=service_id, + company_id=company_id, + cursor=next_cursor, + limit=limit, + filter_=filter_, + sort=sort, + pass_through=pass_through, + fields=fields, + retries=retries, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return models.AccountingSalesReceiptsAllResponse( + get_sales_receipts_response=unmarshal_json_response( + Optional[models.GetSalesReceiptsResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + next=next_func, + ) + if utils.match_response(http_res, "400", "application/json"): + response_data = unmarshal_json_response( + models.BadRequestResponseData, http_res + ) + raise models.BadRequestResponse(response_data, http_res) + if utils.match_response(http_res, "401", "application/json"): + response_data = unmarshal_json_response( + models.UnauthorizedResponseData, http_res + ) + raise models.UnauthorizedResponse(response_data, http_res) + if utils.match_response(http_res, "402", "application/json"): + response_data = unmarshal_json_response( + models.PaymentRequiredResponseData, http_res + ) + raise models.PaymentRequiredResponse(response_data, http_res) + if utils.match_response(http_res, "404", "application/json"): + response_data = unmarshal_json_response( + models.NotFoundResponseData, http_res + ) + raise models.NotFoundResponse(response_data, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + models.UnprocessableResponseData, http_res + ) + raise models.UnprocessableResponse(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "default", "application/json"): + return models.AccountingSalesReceiptsAllResponse( + unexpected_error_response=unmarshal_json_response( + Optional[models.UnexpectedErrorResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + next=next_func, + ) + + raise models.APIError("Unexpected response received", http_res) + + async def list_async( + self, + *, + raw: Optional[bool] = False, + consumer_id: Optional[str] = None, + app_id: Optional[str] = None, + service_id: Optional[str] = None, + company_id: Optional[str] = None, + cursor: OptionalNullable[str] = UNSET, + limit: Optional[int] = 20, + filter_: Optional[ + Union[models.SalesReceiptsFilter, models.SalesReceiptsFilterTypedDict] + ] = None, + sort: Optional[ + Union[models.SalesReceiptsSort, models.SalesReceiptsSortTypedDict] + ] = None, + pass_through: Optional[Dict[str, Any]] = None, + fields: OptionalNullable[str] = UNSET, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> Optional[models.AccountingSalesReceiptsAllResponse]: + r"""List Sales Receipts + + List Sales Receipts + + :param raw: Include raw response. Mostly used for debugging purposes + :param consumer_id: ID of the consumer which you want to get or push data from + :param app_id: The ID of your Unify application + :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. + :param company_id: The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings. + :param cursor: Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. + :param limit: Number of results to return. Minimum 1, Maximum 200, Default 20 + :param filter_: Apply filters + :param sort: Apply sorting + :param pass_through: Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads + :param fields: The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields \"name\", \"email\" and \"addresses.city\". If any other fields are available, they will be excluded. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.AccountingSalesReceiptsAllRequest( + raw=raw, + consumer_id=consumer_id, + app_id=app_id, + service_id=service_id, + company_id=company_id, + cursor=cursor, + limit=limit, + filter_=utils.get_pydantic_model( + filter_, Optional[models.SalesReceiptsFilter] + ), + sort=utils.get_pydantic_model(sort, Optional[models.SalesReceiptsSort]), + pass_through=pass_through, + fields=fields, + ) + + req = self._build_request_async( + method="GET", + path="/accounting/sales-receipts", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=False, + request_has_path_params=False, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + _globals=models.AccountingSalesReceiptsAllGlobals( + consumer_id=self.sdk_configuration.globals.consumer_id, + app_id=self.sdk_configuration.globals.app_id, + ), + security=self.sdk_configuration.security, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + else: + retries = utils.RetryConfig( + "backoff", utils.BackoffStrategy(500, 60000, 1.5, 900000), True + ) + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["408", "500", "502", "503", "504"]) + + http_res = await self.do_request_async( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="accounting.salesReceiptsAll", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + request=req, + error_status_codes=["400", "401", "402", "404", "422", "4XX", "5XX"], + retry_config=retry_config, + ) + + def next_func() -> Optional[models.AccountingSalesReceiptsAllResponse]: + body = utils.unmarshal_json(http_res.text, Union[Dict[Any, Any], List[Any]]) + next_cursor = JSONPath("$.meta.cursors.next").parse(body) + + if len(next_cursor) == 0: + return None + + next_cursor = next_cursor[0] + if next_cursor is None or str(next_cursor).strip() == "": + return None + + return self.list( + raw=raw, + consumer_id=consumer_id, + app_id=app_id, + service_id=service_id, + company_id=company_id, + cursor=next_cursor, + limit=limit, + filter_=filter_, + sort=sort, + pass_through=pass_through, + fields=fields, + retries=retries, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return models.AccountingSalesReceiptsAllResponse( + get_sales_receipts_response=unmarshal_json_response( + Optional[models.GetSalesReceiptsResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + next=next_func, + ) + if utils.match_response(http_res, "400", "application/json"): + response_data = unmarshal_json_response( + models.BadRequestResponseData, http_res + ) + raise models.BadRequestResponse(response_data, http_res) + if utils.match_response(http_res, "401", "application/json"): + response_data = unmarshal_json_response( + models.UnauthorizedResponseData, http_res + ) + raise models.UnauthorizedResponse(response_data, http_res) + if utils.match_response(http_res, "402", "application/json"): + response_data = unmarshal_json_response( + models.PaymentRequiredResponseData, http_res + ) + raise models.PaymentRequiredResponse(response_data, http_res) + if utils.match_response(http_res, "404", "application/json"): + response_data = unmarshal_json_response( + models.NotFoundResponseData, http_res + ) + raise models.NotFoundResponse(response_data, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + models.UnprocessableResponseData, http_res + ) + raise models.UnprocessableResponse(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "default", "application/json"): + return models.AccountingSalesReceiptsAllResponse( + unexpected_error_response=unmarshal_json_response( + Optional[models.UnexpectedErrorResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + next=next_func, + ) + + raise models.APIError("Unexpected response received", http_res) + + def create( + self, + *, + total_amount: Nullable[float], + raw: Optional[bool] = False, + consumer_id: Optional[str] = None, + app_id: Optional[str] = None, + service_id: Optional[str] = None, + company_id: Optional[str] = None, + number: OptionalNullable[str] = UNSET, + customer: OptionalNullable[ + Union[models.LinkedCustomerInput, models.LinkedCustomerInputTypedDict] + ] = UNSET, + currency: OptionalNullable[models.Currency] = UNSET, + currency_rate: OptionalNullable[float] = UNSET, + tax_inclusive: OptionalNullable[bool] = UNSET, + sub_total: OptionalNullable[float] = UNSET, + total_tax: OptionalNullable[float] = UNSET, + transaction_date: OptionalNullable[datetime] = UNSET, + payment_method: OptionalNullable[str] = UNSET, + payment_method_reference: OptionalNullable[str] = UNSET, + payment_method_id: OptionalNullable[str] = UNSET, + account: OptionalNullable[ + Union[models.LinkedLedgerAccount, models.LinkedLedgerAccountTypedDict] + ] = UNSET, + line_items: Optional[ + Union[ + List[models.InvoiceLineItemInput], + List[models.InvoiceLineItemInputTypedDict], + ] + ] = None, + tax_code: OptionalNullable[str] = UNSET, + discount_percentage: OptionalNullable[float] = UNSET, + discount_amount: OptionalNullable[float] = UNSET, + note: OptionalNullable[str] = UNSET, + customer_memo: OptionalNullable[str] = UNSET, + reference: OptionalNullable[str] = UNSET, + billing_address: Optional[ + Union[models.Address, models.AddressTypedDict] + ] = None, + shipping_address: Optional[ + Union[models.Address, models.AddressTypedDict] + ] = None, + department: OptionalNullable[ + Union[models.LinkedDepartmentInput, models.LinkedDepartmentInputTypedDict] + ] = UNSET, + tracking_categories: OptionalNullable[ + Union[ + List[Nullable[models.LinkedTrackingCategory]], + List[Nullable[models.LinkedTrackingCategoryTypedDict]], + ] + ] = UNSET, + custom_fields: Optional[ + Union[List[models.CustomField], List[models.CustomFieldTypedDict]] + ] = None, + row_version: OptionalNullable[str] = UNSET, + pass_through: Optional[ + Union[List[models.PassThroughBody], List[models.PassThroughBodyTypedDict]] + ] = None, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.AccountingSalesReceiptsAddResponse: + r"""Create Sales Receipt + + Create Sales Receipt + + :param total_amount: The total amount of the transaction or record + :param raw: Include raw response. Mostly used for debugging purposes + :param consumer_id: ID of the consumer which you want to get or push data from + :param app_id: The ID of your Unify application + :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. + :param company_id: The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings. + :param number: Reference number for the sales receipt. + :param customer: The customer this entity is linked to. + :param currency: Indicates the associated currency for an amount of money. Values correspond to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217). + :param currency_rate: Currency Exchange Rate at the time entity was recorded/generated. + :param tax_inclusive: Amounts are including tax + :param sub_total: Subtotal amount, normally before tax. + :param total_tax: Total tax amount applied to this transaction. + :param transaction_date: The date of the sales receipt transaction - YYYY-MM-DDThh:mm:ss.sTZD + :param payment_method: Payment method used for the transaction, such as cash, credit card, bank transfer, or check + :param payment_method_reference: Optional reference message returned by payment method on processing + :param payment_method_id: A unique identifier for an object. + :param account: + :param line_items: Line items for itemized sales receipts. Used when the sales receipt includes product/service details with quantities and pricing. + :param tax_code: Applicable tax id/code override if tax is not supplied on a line item basis. + :param discount_percentage: Discount percentage applied to this sales receipt. + :param discount_amount: Discount amount applied to this sales receipt. + :param note: Optional note to be associated with the sales receipt. + :param customer_memo: Customer memo + :param reference: Optional reference message for the sales receipt. + :param billing_address: + :param shipping_address: + :param department: + :param tracking_categories: A list of linked tracking categories. + :param custom_fields: + :param row_version: A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object. + :param pass_through: The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.AccountingSalesReceiptsAddRequest( + raw=raw, + consumer_id=consumer_id, + app_id=app_id, + service_id=service_id, + company_id=company_id, + sales_receipt=models.SalesReceiptInput( + number=number, + customer=utils.get_pydantic_model( + customer, OptionalNullable[models.LinkedCustomerInput] + ), + currency=currency, + currency_rate=currency_rate, + tax_inclusive=tax_inclusive, + sub_total=sub_total, + total_amount=total_amount, + total_tax=total_tax, + transaction_date=transaction_date, + payment_method=payment_method, + payment_method_reference=payment_method_reference, + payment_method_id=payment_method_id, + account=utils.get_pydantic_model( + account, OptionalNullable[models.LinkedLedgerAccount] + ), + line_items=utils.get_pydantic_model( + line_items, Optional[List[models.InvoiceLineItemInput]] + ), + tax_code=tax_code, + discount_percentage=discount_percentage, + discount_amount=discount_amount, + note=note, + customer_memo=customer_memo, + reference=reference, + billing_address=utils.get_pydantic_model( + billing_address, Optional[models.Address] + ), + shipping_address=utils.get_pydantic_model( + shipping_address, Optional[models.Address] + ), + department=utils.get_pydantic_model( + department, OptionalNullable[models.LinkedDepartmentInput] + ), + tracking_categories=utils.get_pydantic_model( + tracking_categories, + OptionalNullable[List[Nullable[models.LinkedTrackingCategory]]], + ), + custom_fields=utils.get_pydantic_model( + custom_fields, Optional[List[models.CustomField]] + ), + row_version=row_version, + pass_through=utils.get_pydantic_model( + pass_through, Optional[List[models.PassThroughBody]] + ), + ), + ) + + req = self._build_request( + method="POST", + path="/accounting/sales-receipts", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=True, + request_has_path_params=False, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + _globals=models.AccountingSalesReceiptsAddGlobals( + consumer_id=self.sdk_configuration.globals.consumer_id, + app_id=self.sdk_configuration.globals.app_id, + ), + security=self.sdk_configuration.security, + get_serialized_body=lambda: utils.serialize_request_body( + request.sales_receipt, False, False, "json", models.SalesReceiptInput + ), + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + else: + retries = utils.RetryConfig( + "backoff", utils.BackoffStrategy(500, 60000, 1.5, 900000), True + ) + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["408", "500", "502", "503", "504"]) + + http_res = self.do_request( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="accounting.salesReceiptsAdd", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + request=req, + error_status_codes=["400", "401", "402", "404", "422", "4XX", "5XX"], + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "201", "application/json"): + return models.AccountingSalesReceiptsAddResponse( + create_sales_receipt_response=unmarshal_json_response( + Optional[models.CreateSalesReceiptResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + if utils.match_response(http_res, "400", "application/json"): + response_data = unmarshal_json_response( + models.BadRequestResponseData, http_res + ) + raise models.BadRequestResponse(response_data, http_res) + if utils.match_response(http_res, "401", "application/json"): + response_data = unmarshal_json_response( + models.UnauthorizedResponseData, http_res + ) + raise models.UnauthorizedResponse(response_data, http_res) + if utils.match_response(http_res, "402", "application/json"): + response_data = unmarshal_json_response( + models.PaymentRequiredResponseData, http_res + ) + raise models.PaymentRequiredResponse(response_data, http_res) + if utils.match_response(http_res, "404", "application/json"): + response_data = unmarshal_json_response( + models.NotFoundResponseData, http_res + ) + raise models.NotFoundResponse(response_data, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + models.UnprocessableResponseData, http_res + ) + raise models.UnprocessableResponse(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "default", "application/json"): + return models.AccountingSalesReceiptsAddResponse( + unexpected_error_response=unmarshal_json_response( + Optional[models.UnexpectedErrorResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + + raise models.APIError("Unexpected response received", http_res) + + async def create_async( + self, + *, + total_amount: Nullable[float], + raw: Optional[bool] = False, + consumer_id: Optional[str] = None, + app_id: Optional[str] = None, + service_id: Optional[str] = None, + company_id: Optional[str] = None, + number: OptionalNullable[str] = UNSET, + customer: OptionalNullable[ + Union[models.LinkedCustomerInput, models.LinkedCustomerInputTypedDict] + ] = UNSET, + currency: OptionalNullable[models.Currency] = UNSET, + currency_rate: OptionalNullable[float] = UNSET, + tax_inclusive: OptionalNullable[bool] = UNSET, + sub_total: OptionalNullable[float] = UNSET, + total_tax: OptionalNullable[float] = UNSET, + transaction_date: OptionalNullable[datetime] = UNSET, + payment_method: OptionalNullable[str] = UNSET, + payment_method_reference: OptionalNullable[str] = UNSET, + payment_method_id: OptionalNullable[str] = UNSET, + account: OptionalNullable[ + Union[models.LinkedLedgerAccount, models.LinkedLedgerAccountTypedDict] + ] = UNSET, + line_items: Optional[ + Union[ + List[models.InvoiceLineItemInput], + List[models.InvoiceLineItemInputTypedDict], + ] + ] = None, + tax_code: OptionalNullable[str] = UNSET, + discount_percentage: OptionalNullable[float] = UNSET, + discount_amount: OptionalNullable[float] = UNSET, + note: OptionalNullable[str] = UNSET, + customer_memo: OptionalNullable[str] = UNSET, + reference: OptionalNullable[str] = UNSET, + billing_address: Optional[ + Union[models.Address, models.AddressTypedDict] + ] = None, + shipping_address: Optional[ + Union[models.Address, models.AddressTypedDict] + ] = None, + department: OptionalNullable[ + Union[models.LinkedDepartmentInput, models.LinkedDepartmentInputTypedDict] + ] = UNSET, + tracking_categories: OptionalNullable[ + Union[ + List[Nullable[models.LinkedTrackingCategory]], + List[Nullable[models.LinkedTrackingCategoryTypedDict]], + ] + ] = UNSET, + custom_fields: Optional[ + Union[List[models.CustomField], List[models.CustomFieldTypedDict]] + ] = None, + row_version: OptionalNullable[str] = UNSET, + pass_through: Optional[ + Union[List[models.PassThroughBody], List[models.PassThroughBodyTypedDict]] + ] = None, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.AccountingSalesReceiptsAddResponse: + r"""Create Sales Receipt + + Create Sales Receipt + + :param total_amount: The total amount of the transaction or record + :param raw: Include raw response. Mostly used for debugging purposes + :param consumer_id: ID of the consumer which you want to get or push data from + :param app_id: The ID of your Unify application + :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. + :param company_id: The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings. + :param number: Reference number for the sales receipt. + :param customer: The customer this entity is linked to. + :param currency: Indicates the associated currency for an amount of money. Values correspond to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217). + :param currency_rate: Currency Exchange Rate at the time entity was recorded/generated. + :param tax_inclusive: Amounts are including tax + :param sub_total: Subtotal amount, normally before tax. + :param total_tax: Total tax amount applied to this transaction. + :param transaction_date: The date of the sales receipt transaction - YYYY-MM-DDThh:mm:ss.sTZD + :param payment_method: Payment method used for the transaction, such as cash, credit card, bank transfer, or check + :param payment_method_reference: Optional reference message returned by payment method on processing + :param payment_method_id: A unique identifier for an object. + :param account: + :param line_items: Line items for itemized sales receipts. Used when the sales receipt includes product/service details with quantities and pricing. + :param tax_code: Applicable tax id/code override if tax is not supplied on a line item basis. + :param discount_percentage: Discount percentage applied to this sales receipt. + :param discount_amount: Discount amount applied to this sales receipt. + :param note: Optional note to be associated with the sales receipt. + :param customer_memo: Customer memo + :param reference: Optional reference message for the sales receipt. + :param billing_address: + :param shipping_address: + :param department: + :param tracking_categories: A list of linked tracking categories. + :param custom_fields: + :param row_version: A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object. + :param pass_through: The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.AccountingSalesReceiptsAddRequest( + raw=raw, + consumer_id=consumer_id, + app_id=app_id, + service_id=service_id, + company_id=company_id, + sales_receipt=models.SalesReceiptInput( + number=number, + customer=utils.get_pydantic_model( + customer, OptionalNullable[models.LinkedCustomerInput] + ), + currency=currency, + currency_rate=currency_rate, + tax_inclusive=tax_inclusive, + sub_total=sub_total, + total_amount=total_amount, + total_tax=total_tax, + transaction_date=transaction_date, + payment_method=payment_method, + payment_method_reference=payment_method_reference, + payment_method_id=payment_method_id, + account=utils.get_pydantic_model( + account, OptionalNullable[models.LinkedLedgerAccount] + ), + line_items=utils.get_pydantic_model( + line_items, Optional[List[models.InvoiceLineItemInput]] + ), + tax_code=tax_code, + discount_percentage=discount_percentage, + discount_amount=discount_amount, + note=note, + customer_memo=customer_memo, + reference=reference, + billing_address=utils.get_pydantic_model( + billing_address, Optional[models.Address] + ), + shipping_address=utils.get_pydantic_model( + shipping_address, Optional[models.Address] + ), + department=utils.get_pydantic_model( + department, OptionalNullable[models.LinkedDepartmentInput] + ), + tracking_categories=utils.get_pydantic_model( + tracking_categories, + OptionalNullable[List[Nullable[models.LinkedTrackingCategory]]], + ), + custom_fields=utils.get_pydantic_model( + custom_fields, Optional[List[models.CustomField]] + ), + row_version=row_version, + pass_through=utils.get_pydantic_model( + pass_through, Optional[List[models.PassThroughBody]] + ), + ), + ) + + req = self._build_request_async( + method="POST", + path="/accounting/sales-receipts", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=True, + request_has_path_params=False, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + _globals=models.AccountingSalesReceiptsAddGlobals( + consumer_id=self.sdk_configuration.globals.consumer_id, + app_id=self.sdk_configuration.globals.app_id, + ), + security=self.sdk_configuration.security, + get_serialized_body=lambda: utils.serialize_request_body( + request.sales_receipt, False, False, "json", models.SalesReceiptInput + ), + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + else: + retries = utils.RetryConfig( + "backoff", utils.BackoffStrategy(500, 60000, 1.5, 900000), True + ) + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["408", "500", "502", "503", "504"]) + + http_res = await self.do_request_async( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="accounting.salesReceiptsAdd", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + request=req, + error_status_codes=["400", "401", "402", "404", "422", "4XX", "5XX"], + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "201", "application/json"): + return models.AccountingSalesReceiptsAddResponse( + create_sales_receipt_response=unmarshal_json_response( + Optional[models.CreateSalesReceiptResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + if utils.match_response(http_res, "400", "application/json"): + response_data = unmarshal_json_response( + models.BadRequestResponseData, http_res + ) + raise models.BadRequestResponse(response_data, http_res) + if utils.match_response(http_res, "401", "application/json"): + response_data = unmarshal_json_response( + models.UnauthorizedResponseData, http_res + ) + raise models.UnauthorizedResponse(response_data, http_res) + if utils.match_response(http_res, "402", "application/json"): + response_data = unmarshal_json_response( + models.PaymentRequiredResponseData, http_res + ) + raise models.PaymentRequiredResponse(response_data, http_res) + if utils.match_response(http_res, "404", "application/json"): + response_data = unmarshal_json_response( + models.NotFoundResponseData, http_res + ) + raise models.NotFoundResponse(response_data, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + models.UnprocessableResponseData, http_res + ) + raise models.UnprocessableResponse(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "default", "application/json"): + return models.AccountingSalesReceiptsAddResponse( + unexpected_error_response=unmarshal_json_response( + Optional[models.UnexpectedErrorResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + + raise models.APIError("Unexpected response received", http_res) + + def get( + self, + *, + id: str, + consumer_id: Optional[str] = None, + app_id: Optional[str] = None, + service_id: Optional[str] = None, + company_id: Optional[str] = None, + raw: Optional[bool] = False, + fields: OptionalNullable[str] = UNSET, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.AccountingSalesReceiptsOneResponse: + r"""Get Sales Receipt + + Get Sales Receipt + + :param id: ID of the record you are acting upon. + :param consumer_id: ID of the consumer which you want to get or push data from + :param app_id: The ID of your Unify application + :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. + :param company_id: The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings. + :param raw: Include raw response. Mostly used for debugging purposes + :param fields: The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields \"name\", \"email\" and \"addresses.city\". If any other fields are available, they will be excluded. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.AccountingSalesReceiptsOneRequest( + id=id, + consumer_id=consumer_id, + app_id=app_id, + service_id=service_id, + company_id=company_id, + raw=raw, + fields=fields, + ) + + req = self._build_request( + method="GET", + path="/accounting/sales-receipts/{id}", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=False, + request_has_path_params=True, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + _globals=models.AccountingSalesReceiptsOneGlobals( + consumer_id=self.sdk_configuration.globals.consumer_id, + app_id=self.sdk_configuration.globals.app_id, + ), + security=self.sdk_configuration.security, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + else: + retries = utils.RetryConfig( + "backoff", utils.BackoffStrategy(500, 60000, 1.5, 900000), True + ) + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["408", "500", "502", "503", "504"]) + + http_res = self.do_request( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="accounting.salesReceiptsOne", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + request=req, + error_status_codes=["400", "401", "402", "404", "422", "4XX", "5XX"], + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return models.AccountingSalesReceiptsOneResponse( + get_sales_receipt_response=unmarshal_json_response( + Optional[models.GetSalesReceiptResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + if utils.match_response(http_res, "400", "application/json"): + response_data = unmarshal_json_response( + models.BadRequestResponseData, http_res + ) + raise models.BadRequestResponse(response_data, http_res) + if utils.match_response(http_res, "401", "application/json"): + response_data = unmarshal_json_response( + models.UnauthorizedResponseData, http_res + ) + raise models.UnauthorizedResponse(response_data, http_res) + if utils.match_response(http_res, "402", "application/json"): + response_data = unmarshal_json_response( + models.PaymentRequiredResponseData, http_res + ) + raise models.PaymentRequiredResponse(response_data, http_res) + if utils.match_response(http_res, "404", "application/json"): + response_data = unmarshal_json_response( + models.NotFoundResponseData, http_res + ) + raise models.NotFoundResponse(response_data, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + models.UnprocessableResponseData, http_res + ) + raise models.UnprocessableResponse(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "default", "application/json"): + return models.AccountingSalesReceiptsOneResponse( + unexpected_error_response=unmarshal_json_response( + Optional[models.UnexpectedErrorResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + + raise models.APIError("Unexpected response received", http_res) + + async def get_async( + self, + *, + id: str, + consumer_id: Optional[str] = None, + app_id: Optional[str] = None, + service_id: Optional[str] = None, + company_id: Optional[str] = None, + raw: Optional[bool] = False, + fields: OptionalNullable[str] = UNSET, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.AccountingSalesReceiptsOneResponse: + r"""Get Sales Receipt + + Get Sales Receipt + + :param id: ID of the record you are acting upon. + :param consumer_id: ID of the consumer which you want to get or push data from + :param app_id: The ID of your Unify application + :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. + :param company_id: The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings. + :param raw: Include raw response. Mostly used for debugging purposes + :param fields: The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation.

Example: `fields=name,email,addresses.city`

In the example above, the response will only include the fields \"name\", \"email\" and \"addresses.city\". If any other fields are available, they will be excluded. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.AccountingSalesReceiptsOneRequest( + id=id, + consumer_id=consumer_id, + app_id=app_id, + service_id=service_id, + company_id=company_id, + raw=raw, + fields=fields, + ) + + req = self._build_request_async( + method="GET", + path="/accounting/sales-receipts/{id}", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=False, + request_has_path_params=True, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + _globals=models.AccountingSalesReceiptsOneGlobals( + consumer_id=self.sdk_configuration.globals.consumer_id, + app_id=self.sdk_configuration.globals.app_id, + ), + security=self.sdk_configuration.security, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + else: + retries = utils.RetryConfig( + "backoff", utils.BackoffStrategy(500, 60000, 1.5, 900000), True + ) + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["408", "500", "502", "503", "504"]) + + http_res = await self.do_request_async( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="accounting.salesReceiptsOne", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + request=req, + error_status_codes=["400", "401", "402", "404", "422", "4XX", "5XX"], + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return models.AccountingSalesReceiptsOneResponse( + get_sales_receipt_response=unmarshal_json_response( + Optional[models.GetSalesReceiptResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + if utils.match_response(http_res, "400", "application/json"): + response_data = unmarshal_json_response( + models.BadRequestResponseData, http_res + ) + raise models.BadRequestResponse(response_data, http_res) + if utils.match_response(http_res, "401", "application/json"): + response_data = unmarshal_json_response( + models.UnauthorizedResponseData, http_res + ) + raise models.UnauthorizedResponse(response_data, http_res) + if utils.match_response(http_res, "402", "application/json"): + response_data = unmarshal_json_response( + models.PaymentRequiredResponseData, http_res + ) + raise models.PaymentRequiredResponse(response_data, http_res) + if utils.match_response(http_res, "404", "application/json"): + response_data = unmarshal_json_response( + models.NotFoundResponseData, http_res + ) + raise models.NotFoundResponse(response_data, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + models.UnprocessableResponseData, http_res + ) + raise models.UnprocessableResponse(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "default", "application/json"): + return models.AccountingSalesReceiptsOneResponse( + unexpected_error_response=unmarshal_json_response( + Optional[models.UnexpectedErrorResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + + raise models.APIError("Unexpected response received", http_res) + + def update( + self, + *, + id: str, + total_amount: Nullable[float], + consumer_id: Optional[str] = None, + app_id: Optional[str] = None, + service_id: Optional[str] = None, + raw: Optional[bool] = False, + company_id: Optional[str] = None, + number: OptionalNullable[str] = UNSET, + customer: OptionalNullable[ + Union[models.LinkedCustomerInput, models.LinkedCustomerInputTypedDict] + ] = UNSET, + currency: OptionalNullable[models.Currency] = UNSET, + currency_rate: OptionalNullable[float] = UNSET, + tax_inclusive: OptionalNullable[bool] = UNSET, + sub_total: OptionalNullable[float] = UNSET, + total_tax: OptionalNullable[float] = UNSET, + transaction_date: OptionalNullable[datetime] = UNSET, + payment_method: OptionalNullable[str] = UNSET, + payment_method_reference: OptionalNullable[str] = UNSET, + payment_method_id: OptionalNullable[str] = UNSET, + account: OptionalNullable[ + Union[models.LinkedLedgerAccount, models.LinkedLedgerAccountTypedDict] + ] = UNSET, + line_items: Optional[ + Union[ + List[models.InvoiceLineItemInput], + List[models.InvoiceLineItemInputTypedDict], + ] + ] = None, + tax_code: OptionalNullable[str] = UNSET, + discount_percentage: OptionalNullable[float] = UNSET, + discount_amount: OptionalNullable[float] = UNSET, + note: OptionalNullable[str] = UNSET, + customer_memo: OptionalNullable[str] = UNSET, + reference: OptionalNullable[str] = UNSET, + billing_address: Optional[ + Union[models.Address, models.AddressTypedDict] + ] = None, + shipping_address: Optional[ + Union[models.Address, models.AddressTypedDict] + ] = None, + department: OptionalNullable[ + Union[models.LinkedDepartmentInput, models.LinkedDepartmentInputTypedDict] + ] = UNSET, + tracking_categories: OptionalNullable[ + Union[ + List[Nullable[models.LinkedTrackingCategory]], + List[Nullable[models.LinkedTrackingCategoryTypedDict]], + ] + ] = UNSET, + custom_fields: Optional[ + Union[List[models.CustomField], List[models.CustomFieldTypedDict]] + ] = None, + row_version: OptionalNullable[str] = UNSET, + pass_through: Optional[ + Union[List[models.PassThroughBody], List[models.PassThroughBodyTypedDict]] + ] = None, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.AccountingSalesReceiptsUpdateResponse: + r"""Update Sales Receipt + + Update Sales Receipt + + :param id: ID of the record you are acting upon. + :param total_amount: The total amount of the transaction or record + :param consumer_id: ID of the consumer which you want to get or push data from + :param app_id: The ID of your Unify application + :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. + :param raw: Include raw response. Mostly used for debugging purposes + :param company_id: The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings. + :param number: Reference number for the sales receipt. + :param customer: The customer this entity is linked to. + :param currency: Indicates the associated currency for an amount of money. Values correspond to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217). + :param currency_rate: Currency Exchange Rate at the time entity was recorded/generated. + :param tax_inclusive: Amounts are including tax + :param sub_total: Subtotal amount, normally before tax. + :param total_tax: Total tax amount applied to this transaction. + :param transaction_date: The date of the sales receipt transaction - YYYY-MM-DDThh:mm:ss.sTZD + :param payment_method: Payment method used for the transaction, such as cash, credit card, bank transfer, or check + :param payment_method_reference: Optional reference message returned by payment method on processing + :param payment_method_id: A unique identifier for an object. + :param account: + :param line_items: Line items for itemized sales receipts. Used when the sales receipt includes product/service details with quantities and pricing. + :param tax_code: Applicable tax id/code override if tax is not supplied on a line item basis. + :param discount_percentage: Discount percentage applied to this sales receipt. + :param discount_amount: Discount amount applied to this sales receipt. + :param note: Optional note to be associated with the sales receipt. + :param customer_memo: Customer memo + :param reference: Optional reference message for the sales receipt. + :param billing_address: + :param shipping_address: + :param department: + :param tracking_categories: A list of linked tracking categories. + :param custom_fields: + :param row_version: A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object. + :param pass_through: The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.AccountingSalesReceiptsUpdateRequest( + id=id, + consumer_id=consumer_id, + app_id=app_id, + service_id=service_id, + raw=raw, + company_id=company_id, + sales_receipt=models.SalesReceiptInput( + number=number, + customer=utils.get_pydantic_model( + customer, OptionalNullable[models.LinkedCustomerInput] + ), + currency=currency, + currency_rate=currency_rate, + tax_inclusive=tax_inclusive, + sub_total=sub_total, + total_amount=total_amount, + total_tax=total_tax, + transaction_date=transaction_date, + payment_method=payment_method, + payment_method_reference=payment_method_reference, + payment_method_id=payment_method_id, + account=utils.get_pydantic_model( + account, OptionalNullable[models.LinkedLedgerAccount] + ), + line_items=utils.get_pydantic_model( + line_items, Optional[List[models.InvoiceLineItemInput]] + ), + tax_code=tax_code, + discount_percentage=discount_percentage, + discount_amount=discount_amount, + note=note, + customer_memo=customer_memo, + reference=reference, + billing_address=utils.get_pydantic_model( + billing_address, Optional[models.Address] + ), + shipping_address=utils.get_pydantic_model( + shipping_address, Optional[models.Address] + ), + department=utils.get_pydantic_model( + department, OptionalNullable[models.LinkedDepartmentInput] + ), + tracking_categories=utils.get_pydantic_model( + tracking_categories, + OptionalNullable[List[Nullable[models.LinkedTrackingCategory]]], + ), + custom_fields=utils.get_pydantic_model( + custom_fields, Optional[List[models.CustomField]] + ), + row_version=row_version, + pass_through=utils.get_pydantic_model( + pass_through, Optional[List[models.PassThroughBody]] + ), + ), + ) + + req = self._build_request( + method="PATCH", + path="/accounting/sales-receipts/{id}", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=True, + request_has_path_params=True, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + _globals=models.AccountingSalesReceiptsUpdateGlobals( + consumer_id=self.sdk_configuration.globals.consumer_id, + app_id=self.sdk_configuration.globals.app_id, + ), + security=self.sdk_configuration.security, + get_serialized_body=lambda: utils.serialize_request_body( + request.sales_receipt, False, False, "json", models.SalesReceiptInput + ), + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + else: + retries = utils.RetryConfig( + "backoff", utils.BackoffStrategy(500, 60000, 1.5, 900000), True + ) + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["408", "500", "502", "503", "504"]) + + http_res = self.do_request( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="accounting.salesReceiptsUpdate", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + request=req, + error_status_codes=["400", "401", "402", "404", "422", "4XX", "5XX"], + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return models.AccountingSalesReceiptsUpdateResponse( + update_sales_receipt_response=unmarshal_json_response( + Optional[models.UpdateSalesReceiptResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + if utils.match_response(http_res, "400", "application/json"): + response_data = unmarshal_json_response( + models.BadRequestResponseData, http_res + ) + raise models.BadRequestResponse(response_data, http_res) + if utils.match_response(http_res, "401", "application/json"): + response_data = unmarshal_json_response( + models.UnauthorizedResponseData, http_res + ) + raise models.UnauthorizedResponse(response_data, http_res) + if utils.match_response(http_res, "402", "application/json"): + response_data = unmarshal_json_response( + models.PaymentRequiredResponseData, http_res + ) + raise models.PaymentRequiredResponse(response_data, http_res) + if utils.match_response(http_res, "404", "application/json"): + response_data = unmarshal_json_response( + models.NotFoundResponseData, http_res + ) + raise models.NotFoundResponse(response_data, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + models.UnprocessableResponseData, http_res + ) + raise models.UnprocessableResponse(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "default", "application/json"): + return models.AccountingSalesReceiptsUpdateResponse( + unexpected_error_response=unmarshal_json_response( + Optional[models.UnexpectedErrorResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + + raise models.APIError("Unexpected response received", http_res) + + async def update_async( + self, + *, + id: str, + total_amount: Nullable[float], + consumer_id: Optional[str] = None, + app_id: Optional[str] = None, + service_id: Optional[str] = None, + raw: Optional[bool] = False, + company_id: Optional[str] = None, + number: OptionalNullable[str] = UNSET, + customer: OptionalNullable[ + Union[models.LinkedCustomerInput, models.LinkedCustomerInputTypedDict] + ] = UNSET, + currency: OptionalNullable[models.Currency] = UNSET, + currency_rate: OptionalNullable[float] = UNSET, + tax_inclusive: OptionalNullable[bool] = UNSET, + sub_total: OptionalNullable[float] = UNSET, + total_tax: OptionalNullable[float] = UNSET, + transaction_date: OptionalNullable[datetime] = UNSET, + payment_method: OptionalNullable[str] = UNSET, + payment_method_reference: OptionalNullable[str] = UNSET, + payment_method_id: OptionalNullable[str] = UNSET, + account: OptionalNullable[ + Union[models.LinkedLedgerAccount, models.LinkedLedgerAccountTypedDict] + ] = UNSET, + line_items: Optional[ + Union[ + List[models.InvoiceLineItemInput], + List[models.InvoiceLineItemInputTypedDict], + ] + ] = None, + tax_code: OptionalNullable[str] = UNSET, + discount_percentage: OptionalNullable[float] = UNSET, + discount_amount: OptionalNullable[float] = UNSET, + note: OptionalNullable[str] = UNSET, + customer_memo: OptionalNullable[str] = UNSET, + reference: OptionalNullable[str] = UNSET, + billing_address: Optional[ + Union[models.Address, models.AddressTypedDict] + ] = None, + shipping_address: Optional[ + Union[models.Address, models.AddressTypedDict] + ] = None, + department: OptionalNullable[ + Union[models.LinkedDepartmentInput, models.LinkedDepartmentInputTypedDict] + ] = UNSET, + tracking_categories: OptionalNullable[ + Union[ + List[Nullable[models.LinkedTrackingCategory]], + List[Nullable[models.LinkedTrackingCategoryTypedDict]], + ] + ] = UNSET, + custom_fields: Optional[ + Union[List[models.CustomField], List[models.CustomFieldTypedDict]] + ] = None, + row_version: OptionalNullable[str] = UNSET, + pass_through: Optional[ + Union[List[models.PassThroughBody], List[models.PassThroughBodyTypedDict]] + ] = None, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.AccountingSalesReceiptsUpdateResponse: + r"""Update Sales Receipt + + Update Sales Receipt + + :param id: ID of the record you are acting upon. + :param total_amount: The total amount of the transaction or record + :param consumer_id: ID of the consumer which you want to get or push data from + :param app_id: The ID of your Unify application + :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. + :param raw: Include raw response. Mostly used for debugging purposes + :param company_id: The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings. + :param number: Reference number for the sales receipt. + :param customer: The customer this entity is linked to. + :param currency: Indicates the associated currency for an amount of money. Values correspond to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217). + :param currency_rate: Currency Exchange Rate at the time entity was recorded/generated. + :param tax_inclusive: Amounts are including tax + :param sub_total: Subtotal amount, normally before tax. + :param total_tax: Total tax amount applied to this transaction. + :param transaction_date: The date of the sales receipt transaction - YYYY-MM-DDThh:mm:ss.sTZD + :param payment_method: Payment method used for the transaction, such as cash, credit card, bank transfer, or check + :param payment_method_reference: Optional reference message returned by payment method on processing + :param payment_method_id: A unique identifier for an object. + :param account: + :param line_items: Line items for itemized sales receipts. Used when the sales receipt includes product/service details with quantities and pricing. + :param tax_code: Applicable tax id/code override if tax is not supplied on a line item basis. + :param discount_percentage: Discount percentage applied to this sales receipt. + :param discount_amount: Discount amount applied to this sales receipt. + :param note: Optional note to be associated with the sales receipt. + :param customer_memo: Customer memo + :param reference: Optional reference message for the sales receipt. + :param billing_address: + :param shipping_address: + :param department: + :param tracking_categories: A list of linked tracking categories. + :param custom_fields: + :param row_version: A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object. + :param pass_through: The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.AccountingSalesReceiptsUpdateRequest( + id=id, + consumer_id=consumer_id, + app_id=app_id, + service_id=service_id, + raw=raw, + company_id=company_id, + sales_receipt=models.SalesReceiptInput( + number=number, + customer=utils.get_pydantic_model( + customer, OptionalNullable[models.LinkedCustomerInput] + ), + currency=currency, + currency_rate=currency_rate, + tax_inclusive=tax_inclusive, + sub_total=sub_total, + total_amount=total_amount, + total_tax=total_tax, + transaction_date=transaction_date, + payment_method=payment_method, + payment_method_reference=payment_method_reference, + payment_method_id=payment_method_id, + account=utils.get_pydantic_model( + account, OptionalNullable[models.LinkedLedgerAccount] + ), + line_items=utils.get_pydantic_model( + line_items, Optional[List[models.InvoiceLineItemInput]] + ), + tax_code=tax_code, + discount_percentage=discount_percentage, + discount_amount=discount_amount, + note=note, + customer_memo=customer_memo, + reference=reference, + billing_address=utils.get_pydantic_model( + billing_address, Optional[models.Address] + ), + shipping_address=utils.get_pydantic_model( + shipping_address, Optional[models.Address] + ), + department=utils.get_pydantic_model( + department, OptionalNullable[models.LinkedDepartmentInput] + ), + tracking_categories=utils.get_pydantic_model( + tracking_categories, + OptionalNullable[List[Nullable[models.LinkedTrackingCategory]]], + ), + custom_fields=utils.get_pydantic_model( + custom_fields, Optional[List[models.CustomField]] + ), + row_version=row_version, + pass_through=utils.get_pydantic_model( + pass_through, Optional[List[models.PassThroughBody]] + ), + ), + ) + + req = self._build_request_async( + method="PATCH", + path="/accounting/sales-receipts/{id}", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=True, + request_has_path_params=True, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + _globals=models.AccountingSalesReceiptsUpdateGlobals( + consumer_id=self.sdk_configuration.globals.consumer_id, + app_id=self.sdk_configuration.globals.app_id, + ), + security=self.sdk_configuration.security, + get_serialized_body=lambda: utils.serialize_request_body( + request.sales_receipt, False, False, "json", models.SalesReceiptInput + ), + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + else: + retries = utils.RetryConfig( + "backoff", utils.BackoffStrategy(500, 60000, 1.5, 900000), True + ) + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["408", "500", "502", "503", "504"]) + + http_res = await self.do_request_async( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="accounting.salesReceiptsUpdate", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + request=req, + error_status_codes=["400", "401", "402", "404", "422", "4XX", "5XX"], + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return models.AccountingSalesReceiptsUpdateResponse( + update_sales_receipt_response=unmarshal_json_response( + Optional[models.UpdateSalesReceiptResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + if utils.match_response(http_res, "400", "application/json"): + response_data = unmarshal_json_response( + models.BadRequestResponseData, http_res + ) + raise models.BadRequestResponse(response_data, http_res) + if utils.match_response(http_res, "401", "application/json"): + response_data = unmarshal_json_response( + models.UnauthorizedResponseData, http_res + ) + raise models.UnauthorizedResponse(response_data, http_res) + if utils.match_response(http_res, "402", "application/json"): + response_data = unmarshal_json_response( + models.PaymentRequiredResponseData, http_res + ) + raise models.PaymentRequiredResponse(response_data, http_res) + if utils.match_response(http_res, "404", "application/json"): + response_data = unmarshal_json_response( + models.NotFoundResponseData, http_res + ) + raise models.NotFoundResponse(response_data, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + models.UnprocessableResponseData, http_res + ) + raise models.UnprocessableResponse(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "default", "application/json"): + return models.AccountingSalesReceiptsUpdateResponse( + unexpected_error_response=unmarshal_json_response( + Optional[models.UnexpectedErrorResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + + raise models.APIError("Unexpected response received", http_res) + + def delete( + self, + *, + id: str, + consumer_id: Optional[str] = None, + app_id: Optional[str] = None, + service_id: Optional[str] = None, + raw: Optional[bool] = False, + company_id: Optional[str] = None, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.AccountingSalesReceiptsDeleteResponse: + r"""Delete Sales Receipt + + Delete Sales Receipt + + :param id: ID of the record you are acting upon. + :param consumer_id: ID of the consumer which you want to get or push data from + :param app_id: The ID of your Unify application + :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. + :param raw: Include raw response. Mostly used for debugging purposes + :param company_id: The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.AccountingSalesReceiptsDeleteRequest( + id=id, + consumer_id=consumer_id, + app_id=app_id, + service_id=service_id, + raw=raw, + company_id=company_id, + ) + + req = self._build_request( + method="DELETE", + path="/accounting/sales-receipts/{id}", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=False, + request_has_path_params=True, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + _globals=models.AccountingSalesReceiptsDeleteGlobals( + consumer_id=self.sdk_configuration.globals.consumer_id, + app_id=self.sdk_configuration.globals.app_id, + ), + security=self.sdk_configuration.security, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + else: + retries = utils.RetryConfig( + "backoff", utils.BackoffStrategy(500, 60000, 1.5, 900000), True + ) + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["408", "500", "502", "503", "504"]) + + http_res = self.do_request( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="accounting.salesReceiptsDelete", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + request=req, + error_status_codes=["400", "401", "402", "404", "422", "4XX", "5XX"], + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return models.AccountingSalesReceiptsDeleteResponse( + delete_sales_receipt_response=unmarshal_json_response( + Optional[models.DeleteSalesReceiptResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + if utils.match_response(http_res, "400", "application/json"): + response_data = unmarshal_json_response( + models.BadRequestResponseData, http_res + ) + raise models.BadRequestResponse(response_data, http_res) + if utils.match_response(http_res, "401", "application/json"): + response_data = unmarshal_json_response( + models.UnauthorizedResponseData, http_res + ) + raise models.UnauthorizedResponse(response_data, http_res) + if utils.match_response(http_res, "402", "application/json"): + response_data = unmarshal_json_response( + models.PaymentRequiredResponseData, http_res + ) + raise models.PaymentRequiredResponse(response_data, http_res) + if utils.match_response(http_res, "404", "application/json"): + response_data = unmarshal_json_response( + models.NotFoundResponseData, http_res + ) + raise models.NotFoundResponse(response_data, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + models.UnprocessableResponseData, http_res + ) + raise models.UnprocessableResponse(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "default", "application/json"): + return models.AccountingSalesReceiptsDeleteResponse( + unexpected_error_response=unmarshal_json_response( + Optional[models.UnexpectedErrorResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + + raise models.APIError("Unexpected response received", http_res) + + async def delete_async( + self, + *, + id: str, + consumer_id: Optional[str] = None, + app_id: Optional[str] = None, + service_id: Optional[str] = None, + raw: Optional[bool] = False, + company_id: Optional[str] = None, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.AccountingSalesReceiptsDeleteResponse: + r"""Delete Sales Receipt + + Delete Sales Receipt + + :param id: ID of the record you are acting upon. + :param consumer_id: ID of the consumer which you want to get or push data from + :param app_id: The ID of your Unify application + :param service_id: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. + :param raw: Include raw response. Mostly used for debugging purposes + :param company_id: The ID of the company to scope requests to. For connectors that support multi-company, this overrides the default company configured in connection settings. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.AccountingSalesReceiptsDeleteRequest( + id=id, + consumer_id=consumer_id, + app_id=app_id, + service_id=service_id, + raw=raw, + company_id=company_id, + ) + + req = self._build_request_async( + method="DELETE", + path="/accounting/sales-receipts/{id}", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=False, + request_has_path_params=True, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + _globals=models.AccountingSalesReceiptsDeleteGlobals( + consumer_id=self.sdk_configuration.globals.consumer_id, + app_id=self.sdk_configuration.globals.app_id, + ), + security=self.sdk_configuration.security, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + else: + retries = utils.RetryConfig( + "backoff", utils.BackoffStrategy(500, 60000, 1.5, 900000), True + ) + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["408", "500", "502", "503", "504"]) + + http_res = await self.do_request_async( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="accounting.salesReceiptsDelete", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + request=req, + error_status_codes=["400", "401", "402", "404", "422", "4XX", "5XX"], + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return models.AccountingSalesReceiptsDeleteResponse( + delete_sales_receipt_response=unmarshal_json_response( + Optional[models.DeleteSalesReceiptResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + if utils.match_response(http_res, "400", "application/json"): + response_data = unmarshal_json_response( + models.BadRequestResponseData, http_res + ) + raise models.BadRequestResponse(response_data, http_res) + if utils.match_response(http_res, "401", "application/json"): + response_data = unmarshal_json_response( + models.UnauthorizedResponseData, http_res + ) + raise models.UnauthorizedResponse(response_data, http_res) + if utils.match_response(http_res, "402", "application/json"): + response_data = unmarshal_json_response( + models.PaymentRequiredResponseData, http_res + ) + raise models.PaymentRequiredResponse(response_data, http_res) + if utils.match_response(http_res, "404", "application/json"): + response_data = unmarshal_json_response( + models.NotFoundResponseData, http_res + ) + raise models.NotFoundResponse(response_data, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + models.UnprocessableResponseData, http_res + ) + raise models.UnprocessableResponse(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise models.APIError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "default", "application/json"): + return models.AccountingSalesReceiptsDeleteResponse( + unexpected_error_response=unmarshal_json_response( + Optional[models.UnexpectedErrorResponse], http_res + ), + http_meta=models.HTTPMetadata(request=req, response=http_res), + ) + + raise models.APIError("Unexpected response received", http_res) From 0967cbd5443d7865c0e75dd533b131e449599ab2 Mon Sep 17 00:00:00 2001 From: "speakeasy-github[bot]" <128539517+speakeasy-github[bot]@users.noreply.github.com> Date: Thu, 13 Aug 2026 00:31:11 +0000 Subject: [PATCH 2/2] empty commit to trigger [run-tests] workflow