@oatfi/oatfi-sdk-ts 0.11.65 → 0.11.66
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +27 -0
- package/dist/commonjs/funcs/billingCycleConfigsCreate.d.ts +15 -0
- package/dist/commonjs/funcs/billingCycleConfigsCreate.d.ts.map +1 -0
- package/dist/commonjs/funcs/billingCycleConfigsCreate.js +133 -0
- package/dist/commonjs/funcs/billingCycleConfigsCreate.js.map +1 -0
- package/dist/commonjs/funcs/billingCycleConfigsGet.d.ts +15 -0
- package/dist/commonjs/funcs/billingCycleConfigsGet.d.ts.map +1 -0
- package/dist/commonjs/funcs/billingCycleConfigsGet.js +133 -0
- package/dist/commonjs/funcs/billingCycleConfigsGet.js.map +1 -0
- package/dist/commonjs/funcs/billingCycleConfigsUpdate.d.ts +15 -0
- package/dist/commonjs/funcs/billingCycleConfigsUpdate.d.ts.map +1 -0
- package/dist/commonjs/funcs/billingCycleConfigsUpdate.js +136 -0
- package/dist/commonjs/funcs/billingCycleConfigsUpdate.js.map +1 -0
- package/dist/commonjs/funcs/billingCyclesGet.d.ts +15 -0
- package/dist/commonjs/funcs/billingCyclesGet.d.ts.map +1 -0
- package/dist/commonjs/funcs/billingCyclesGet.js +132 -0
- package/dist/commonjs/funcs/billingCyclesGet.js.map +1 -0
- package/dist/commonjs/funcs/billingCyclesList.d.ts +17 -0
- package/dist/commonjs/funcs/billingCyclesList.d.ts.map +1 -0
- package/dist/commonjs/funcs/billingCyclesList.js +164 -0
- package/dist/commonjs/funcs/billingCyclesList.js.map +1 -0
- package/dist/commonjs/funcs/dailyReportsCreate.d.ts +15 -0
- package/dist/commonjs/funcs/dailyReportsCreate.d.ts.map +1 -0
- package/dist/commonjs/funcs/dailyReportsCreate.js +125 -0
- package/dist/commonjs/funcs/dailyReportsCreate.js.map +1 -0
- package/dist/commonjs/funcs/dailyReportsGet.d.ts +15 -0
- package/dist/commonjs/funcs/dailyReportsGet.d.ts.map +1 -0
- package/dist/commonjs/funcs/dailyReportsGet.js +127 -0
- package/dist/commonjs/funcs/dailyReportsGet.js.map +1 -0
- package/dist/commonjs/funcs/dailyReportsList.d.ts +17 -0
- package/dist/commonjs/funcs/dailyReportsList.d.ts.map +1 -0
- package/dist/commonjs/funcs/dailyReportsList.js +158 -0
- package/dist/commonjs/funcs/dailyReportsList.js.map +1 -0
- package/dist/commonjs/funcs/dailyReportsUpdate.d.ts +15 -0
- package/dist/commonjs/funcs/dailyReportsUpdate.d.ts.map +1 -0
- package/dist/commonjs/funcs/dailyReportsUpdate.js +131 -0
- package/dist/commonjs/funcs/dailyReportsUpdate.js.map +1 -0
- package/dist/commonjs/funcs/embedExchangeToken.d.ts +2 -0
- package/dist/commonjs/funcs/embedExchangeToken.d.ts.map +1 -1
- package/dist/commonjs/funcs/embedExchangeToken.js +3 -1
- package/dist/commonjs/funcs/embedExchangeToken.js.map +1 -1
- package/dist/commonjs/funcs/embedRefreshToken.d.ts +2 -0
- package/dist/commonjs/funcs/embedRefreshToken.d.ts.map +1 -1
- package/dist/commonjs/funcs/embedRefreshToken.js +3 -1
- package/dist/commonjs/funcs/embedRefreshToken.js.map +1 -1
- package/dist/commonjs/lib/config.d.ts +3 -3
- package/dist/commonjs/lib/config.js +3 -3
- package/dist/commonjs/lib/config.js.map +1 -1
- package/dist/commonjs/lib/security.d.ts +1 -1
- package/dist/commonjs/lib/security.d.ts.map +1 -1
- package/dist/commonjs/lib/security.js +19 -8
- package/dist/commonjs/lib/security.js.map +1 -1
- package/dist/commonjs/models/billingcycleconfigsresponsedto.d.ts +67 -0
- package/dist/commonjs/models/billingcycleconfigsresponsedto.d.ts.map +1 -0
- package/dist/commonjs/models/billingcycleconfigsresponsedto.js +77 -0
- package/dist/commonjs/models/billingcycleconfigsresponsedto.js.map +1 -0
- package/dist/commonjs/models/billingcyclesresponsedto.d.ts +87 -0
- package/dist/commonjs/models/billingcyclesresponsedto.d.ts.map +1 -0
- package/dist/commonjs/models/billingcyclesresponsedto.js +91 -0
- package/dist/commonjs/models/billingcyclesresponsedto.js.map +1 -0
- package/dist/commonjs/models/createbillingcycleconfigsdto.d.ts +30 -0
- package/dist/commonjs/models/createbillingcycleconfigsdto.d.ts.map +1 -0
- package/dist/commonjs/models/createbillingcycleconfigsdto.js +59 -0
- package/dist/commonjs/models/createbillingcycleconfigsdto.js.map +1 -0
- package/dist/commonjs/models/createdailyreportdto.d.ts +45 -0
- package/dist/commonjs/models/createdailyreportdto.d.ts.map +1 -0
- package/dist/commonjs/models/createdailyreportdto.js +63 -0
- package/dist/commonjs/models/createdailyreportdto.js.map +1 -0
- package/dist/commonjs/models/createpaymentdto.d.ts +5 -0
- package/dist/commonjs/models/createpaymentdto.d.ts.map +1 -1
- package/dist/commonjs/models/createpaymentdto.js +2 -0
- package/dist/commonjs/models/createpaymentdto.js.map +1 -1
- package/dist/commonjs/models/createprogramdto.d.ts +6 -0
- package/dist/commonjs/models/createprogramdto.d.ts.map +1 -1
- package/dist/commonjs/models/createprogramdto.js +3 -0
- package/dist/commonjs/models/createprogramdto.js.map +1 -1
- package/dist/commonjs/models/dailyreportdto.d.ts +61 -0
- package/dist/commonjs/models/dailyreportdto.d.ts.map +1 -0
- package/dist/commonjs/models/dailyreportdto.js +74 -0
- package/dist/commonjs/models/dailyreportdto.js.map +1 -0
- package/dist/commonjs/models/index.d.ts +8 -0
- package/dist/commonjs/models/index.d.ts.map +1 -1
- package/dist/commonjs/models/index.js +8 -0
- package/dist/commonjs/models/index.js.map +1 -1
- package/dist/commonjs/models/onboardingsettingsdto.d.ts +55 -0
- package/dist/commonjs/models/onboardingsettingsdto.d.ts.map +1 -0
- package/dist/commonjs/models/onboardingsettingsdto.js +94 -0
- package/dist/commonjs/models/onboardingsettingsdto.js.map +1 -0
- package/dist/commonjs/models/operations/billingcycleconfigscontrollercreatebillingcycleconfig.d.ts +23 -0
- package/dist/commonjs/models/operations/billingcycleconfigscontrollercreatebillingcycleconfig.d.ts.map +1 -0
- package/dist/commonjs/models/operations/billingcycleconfigscontrollercreatebillingcycleconfig.js +59 -0
- package/dist/commonjs/models/operations/billingcycleconfigscontrollercreatebillingcycleconfig.js.map +1 -0
- package/dist/commonjs/models/operations/billingcycleconfigscontrollergetbillingcycleconfig.d.ts +20 -0
- package/dist/commonjs/models/operations/billingcycleconfigscontrollergetbillingcycleconfig.d.ts.map +1 -0
- package/dist/commonjs/models/operations/billingcycleconfigscontrollergetbillingcycleconfig.js +51 -0
- package/dist/commonjs/models/operations/billingcycleconfigscontrollergetbillingcycleconfig.js.map +1 -0
- package/dist/commonjs/models/operations/billingcycleconfigscontrollerupdatebillingcycleconfig.d.ts +23 -0
- package/dist/commonjs/models/operations/billingcycleconfigscontrollerupdatebillingcycleconfig.d.ts.map +1 -0
- package/dist/commonjs/models/operations/billingcycleconfigscontrollerupdatebillingcycleconfig.js +58 -0
- package/dist/commonjs/models/operations/billingcycleconfigscontrollerupdatebillingcycleconfig.js.map +1 -0
- package/dist/commonjs/models/operations/billingcyclescontrollergetbillingcycle.d.ts +20 -0
- package/dist/commonjs/models/operations/billingcyclescontrollergetbillingcycle.d.ts.map +1 -0
- package/dist/commonjs/models/operations/billingcyclescontrollergetbillingcycle.js +55 -0
- package/dist/commonjs/models/operations/billingcyclescontrollergetbillingcycle.js.map +1 -0
- package/dist/commonjs/models/operations/billingcyclescontrollerlistbillingcycles.d.ts +54 -0
- package/dist/commonjs/models/operations/billingcyclescontrollerlistbillingcycles.d.ts.map +1 -0
- package/dist/commonjs/models/operations/billingcyclescontrollerlistbillingcycles.js +70 -0
- package/dist/commonjs/models/operations/billingcyclescontrollerlistbillingcycles.js.map +1 -0
- package/dist/commonjs/models/operations/dailyreportscontrollercreate.d.ts +21 -0
- package/dist/commonjs/models/operations/dailyreportscontrollercreate.d.ts.map +1 -0
- package/dist/commonjs/models/operations/dailyreportscontrollercreate.js +57 -0
- package/dist/commonjs/models/operations/dailyreportscontrollercreate.js.map +1 -0
- package/dist/commonjs/models/operations/dailyreportscontrollerfindall.d.ts +35 -0
- package/dist/commonjs/models/operations/dailyreportscontrollerfindall.d.ts.map +1 -0
- package/dist/commonjs/models/operations/dailyreportscontrollerfindall.js +59 -0
- package/dist/commonjs/models/operations/dailyreportscontrollerfindall.js.map +1 -0
- package/dist/commonjs/models/operations/dailyreportscontrollerfindone.d.ts +15 -0
- package/dist/commonjs/models/operations/dailyreportscontrollerfindone.d.ts.map +1 -0
- package/dist/commonjs/models/operations/dailyreportscontrollerfindone.js +49 -0
- package/dist/commonjs/models/operations/dailyreportscontrollerfindone.js.map +1 -0
- package/dist/commonjs/models/operations/dailyreportscontrollerupdate.d.ts +26 -0
- package/dist/commonjs/models/operations/dailyreportscontrollerupdate.d.ts.map +1 -0
- package/dist/commonjs/models/operations/dailyreportscontrollerupdate.js +58 -0
- package/dist/commonjs/models/operations/dailyreportscontrollerupdate.js.map +1 -0
- package/dist/commonjs/models/operations/index.d.ts +9 -0
- package/dist/commonjs/models/operations/index.d.ts.map +1 -1
- package/dist/commonjs/models/operations/index.js +9 -0
- package/dist/commonjs/models/operations/index.js.map +1 -1
- package/dist/commonjs/models/paymentdto.d.ts +4 -0
- package/dist/commonjs/models/paymentdto.d.ts.map +1 -1
- package/dist/commonjs/models/paymentdto.js +2 -0
- package/dist/commonjs/models/paymentdto.js.map +1 -1
- package/dist/commonjs/models/paymentinformationdto.d.ts +4 -0
- package/dist/commonjs/models/paymentinformationdto.d.ts.map +1 -1
- package/dist/commonjs/models/paymentinformationdto.js +2 -0
- package/dist/commonjs/models/paymentinformationdto.js.map +1 -1
- package/dist/commonjs/models/programresponsedto.d.ts +5 -0
- package/dist/commonjs/models/programresponsedto.d.ts.map +1 -1
- package/dist/commonjs/models/programresponsedto.js +3 -0
- package/dist/commonjs/models/programresponsedto.js.map +1 -1
- package/dist/commonjs/models/updatebillingcycleconfigsdto.d.ts +25 -0
- package/dist/commonjs/models/updatebillingcycleconfigsdto.d.ts.map +1 -0
- package/dist/commonjs/models/updatebillingcycleconfigsdto.js +57 -0
- package/dist/commonjs/models/updatebillingcycleconfigsdto.js.map +1 -0
- package/dist/commonjs/models/updatedailyreportdto.d.ts +40 -0
- package/dist/commonjs/models/updatedailyreportdto.d.ts.map +1 -0
- package/dist/commonjs/models/updatedailyreportdto.js +62 -0
- package/dist/commonjs/models/updatedailyreportdto.js.map +1 -0
- package/dist/commonjs/models/updateprogramdto.d.ts +6 -0
- package/dist/commonjs/models/updateprogramdto.d.ts.map +1 -1
- package/dist/commonjs/models/updateprogramdto.js +3 -0
- package/dist/commonjs/models/updateprogramdto.js.map +1 -1
- package/dist/commonjs/sdk/billingcycleconfigs.d.ts +18 -0
- package/dist/commonjs/sdk/billingcycleconfigs.d.ts.map +1 -0
- package/dist/commonjs/sdk/billingcycleconfigs.js +33 -0
- package/dist/commonjs/sdk/billingcycleconfigs.js.map +1 -0
- package/dist/commonjs/sdk/billingcycles.d.ts +17 -0
- package/dist/commonjs/sdk/billingcycles.d.ts.map +1 -0
- package/dist/commonjs/sdk/billingcycles.js +27 -0
- package/dist/commonjs/sdk/billingcycles.js.map +1 -0
- package/dist/commonjs/sdk/dailyreports.d.ts +25 -0
- package/dist/commonjs/sdk/dailyreports.d.ts.map +1 -0
- package/dist/commonjs/sdk/dailyreports.js +41 -0
- package/dist/commonjs/sdk/dailyreports.js.map +1 -0
- package/dist/commonjs/sdk/sdk.d.ts +9 -0
- package/dist/commonjs/sdk/sdk.d.ts.map +1 -1
- package/dist/commonjs/sdk/sdk.js +12 -0
- package/dist/commonjs/sdk/sdk.js.map +1 -1
- package/dist/esm/funcs/billingCycleConfigsCreate.d.ts +15 -0
- package/dist/esm/funcs/billingCycleConfigsCreate.d.ts.map +1 -0
- package/dist/esm/funcs/billingCycleConfigsCreate.js +97 -0
- package/dist/esm/funcs/billingCycleConfigsCreate.js.map +1 -0
- package/dist/esm/funcs/billingCycleConfigsGet.d.ts +15 -0
- package/dist/esm/funcs/billingCycleConfigsGet.d.ts.map +1 -0
- package/dist/esm/funcs/billingCycleConfigsGet.js +97 -0
- package/dist/esm/funcs/billingCycleConfigsGet.js.map +1 -0
- package/dist/esm/funcs/billingCycleConfigsUpdate.d.ts +15 -0
- package/dist/esm/funcs/billingCycleConfigsUpdate.d.ts.map +1 -0
- package/dist/esm/funcs/billingCycleConfigsUpdate.js +100 -0
- package/dist/esm/funcs/billingCycleConfigsUpdate.js.map +1 -0
- package/dist/esm/funcs/billingCyclesGet.d.ts +15 -0
- package/dist/esm/funcs/billingCyclesGet.d.ts.map +1 -0
- package/dist/esm/funcs/billingCyclesGet.js +96 -0
- package/dist/esm/funcs/billingCyclesGet.js.map +1 -0
- package/dist/esm/funcs/billingCyclesList.d.ts +17 -0
- package/dist/esm/funcs/billingCyclesList.d.ts.map +1 -0
- package/dist/esm/funcs/billingCyclesList.js +128 -0
- package/dist/esm/funcs/billingCyclesList.js.map +1 -0
- package/dist/esm/funcs/dailyReportsCreate.d.ts +15 -0
- package/dist/esm/funcs/dailyReportsCreate.d.ts.map +1 -0
- package/dist/esm/funcs/dailyReportsCreate.js +89 -0
- package/dist/esm/funcs/dailyReportsCreate.js.map +1 -0
- package/dist/esm/funcs/dailyReportsGet.d.ts +15 -0
- package/dist/esm/funcs/dailyReportsGet.d.ts.map +1 -0
- package/dist/esm/funcs/dailyReportsGet.js +91 -0
- package/dist/esm/funcs/dailyReportsGet.js.map +1 -0
- package/dist/esm/funcs/dailyReportsList.d.ts +17 -0
- package/dist/esm/funcs/dailyReportsList.d.ts.map +1 -0
- package/dist/esm/funcs/dailyReportsList.js +122 -0
- package/dist/esm/funcs/dailyReportsList.js.map +1 -0
- package/dist/esm/funcs/dailyReportsUpdate.d.ts +15 -0
- package/dist/esm/funcs/dailyReportsUpdate.d.ts.map +1 -0
- package/dist/esm/funcs/dailyReportsUpdate.js +95 -0
- package/dist/esm/funcs/dailyReportsUpdate.js.map +1 -0
- package/dist/esm/funcs/embedExchangeToken.d.ts +2 -0
- package/dist/esm/funcs/embedExchangeToken.d.ts.map +1 -1
- package/dist/esm/funcs/embedExchangeToken.js +3 -1
- package/dist/esm/funcs/embedExchangeToken.js.map +1 -1
- package/dist/esm/funcs/embedRefreshToken.d.ts +2 -0
- package/dist/esm/funcs/embedRefreshToken.d.ts.map +1 -1
- package/dist/esm/funcs/embedRefreshToken.js +3 -1
- package/dist/esm/funcs/embedRefreshToken.js.map +1 -1
- package/dist/esm/lib/config.d.ts +3 -3
- package/dist/esm/lib/config.js +3 -3
- package/dist/esm/lib/config.js.map +1 -1
- package/dist/esm/lib/security.d.ts +1 -1
- package/dist/esm/lib/security.d.ts.map +1 -1
- package/dist/esm/lib/security.js +19 -8
- package/dist/esm/lib/security.js.map +1 -1
- package/dist/esm/models/billingcycleconfigsresponsedto.d.ts +67 -0
- package/dist/esm/models/billingcycleconfigsresponsedto.d.ts.map +1 -0
- package/dist/esm/models/billingcycleconfigsresponsedto.js +40 -0
- package/dist/esm/models/billingcycleconfigsresponsedto.js.map +1 -0
- package/dist/esm/models/billingcyclesresponsedto.d.ts +87 -0
- package/dist/esm/models/billingcyclesresponsedto.d.ts.map +1 -0
- package/dist/esm/models/billingcyclesresponsedto.js +54 -0
- package/dist/esm/models/billingcyclesresponsedto.js.map +1 -0
- package/dist/esm/models/createbillingcycleconfigsdto.d.ts +30 -0
- package/dist/esm/models/createbillingcycleconfigsdto.d.ts.map +1 -0
- package/dist/esm/models/createbillingcycleconfigsdto.js +22 -0
- package/dist/esm/models/createbillingcycleconfigsdto.js.map +1 -0
- package/dist/esm/models/createdailyreportdto.d.ts +45 -0
- package/dist/esm/models/createdailyreportdto.d.ts.map +1 -0
- package/dist/esm/models/createdailyreportdto.js +26 -0
- package/dist/esm/models/createdailyreportdto.js.map +1 -0
- package/dist/esm/models/createpaymentdto.d.ts +5 -0
- package/dist/esm/models/createpaymentdto.d.ts.map +1 -1
- package/dist/esm/models/createpaymentdto.js +2 -0
- package/dist/esm/models/createpaymentdto.js.map +1 -1
- package/dist/esm/models/createprogramdto.d.ts +6 -0
- package/dist/esm/models/createprogramdto.d.ts.map +1 -1
- package/dist/esm/models/createprogramdto.js +3 -0
- package/dist/esm/models/createprogramdto.js.map +1 -1
- package/dist/esm/models/dailyreportdto.d.ts +61 -0
- package/dist/esm/models/dailyreportdto.d.ts.map +1 -0
- package/dist/esm/models/dailyreportdto.js +37 -0
- package/dist/esm/models/dailyreportdto.js.map +1 -0
- package/dist/esm/models/index.d.ts +8 -0
- package/dist/esm/models/index.d.ts.map +1 -1
- package/dist/esm/models/index.js +8 -0
- package/dist/esm/models/index.js.map +1 -1
- package/dist/esm/models/onboardingsettingsdto.d.ts +55 -0
- package/dist/esm/models/onboardingsettingsdto.d.ts.map +1 -0
- package/dist/esm/models/onboardingsettingsdto.js +56 -0
- package/dist/esm/models/onboardingsettingsdto.js.map +1 -0
- package/dist/esm/models/operations/billingcycleconfigscontrollercreatebillingcycleconfig.d.ts +23 -0
- package/dist/esm/models/operations/billingcycleconfigscontrollercreatebillingcycleconfig.d.ts.map +1 -0
- package/dist/esm/models/operations/billingcycleconfigscontrollercreatebillingcycleconfig.js +22 -0
- package/dist/esm/models/operations/billingcycleconfigscontrollercreatebillingcycleconfig.js.map +1 -0
- package/dist/esm/models/operations/billingcycleconfigscontrollergetbillingcycleconfig.d.ts +20 -0
- package/dist/esm/models/operations/billingcycleconfigscontrollergetbillingcycleconfig.d.ts.map +1 -0
- package/dist/esm/models/operations/billingcycleconfigscontrollergetbillingcycleconfig.js +14 -0
- package/dist/esm/models/operations/billingcycleconfigscontrollergetbillingcycleconfig.js.map +1 -0
- package/dist/esm/models/operations/billingcycleconfigscontrollerupdatebillingcycleconfig.d.ts +23 -0
- package/dist/esm/models/operations/billingcycleconfigscontrollerupdatebillingcycleconfig.d.ts.map +1 -0
- package/dist/esm/models/operations/billingcycleconfigscontrollerupdatebillingcycleconfig.js +21 -0
- package/dist/esm/models/operations/billingcycleconfigscontrollerupdatebillingcycleconfig.js.map +1 -0
- package/dist/esm/models/operations/billingcyclescontrollergetbillingcycle.d.ts +20 -0
- package/dist/esm/models/operations/billingcyclescontrollergetbillingcycle.d.ts.map +1 -0
- package/dist/esm/models/operations/billingcyclescontrollergetbillingcycle.js +18 -0
- package/dist/esm/models/operations/billingcyclescontrollergetbillingcycle.js.map +1 -0
- package/dist/esm/models/operations/billingcyclescontrollerlistbillingcycles.d.ts +54 -0
- package/dist/esm/models/operations/billingcyclescontrollerlistbillingcycles.d.ts.map +1 -0
- package/dist/esm/models/operations/billingcyclescontrollerlistbillingcycles.js +33 -0
- package/dist/esm/models/operations/billingcyclescontrollerlistbillingcycles.js.map +1 -0
- package/dist/esm/models/operations/dailyreportscontrollercreate.d.ts +21 -0
- package/dist/esm/models/operations/dailyreportscontrollercreate.d.ts.map +1 -0
- package/dist/esm/models/operations/dailyreportscontrollercreate.js +20 -0
- package/dist/esm/models/operations/dailyreportscontrollercreate.js.map +1 -0
- package/dist/esm/models/operations/dailyreportscontrollerfindall.d.ts +35 -0
- package/dist/esm/models/operations/dailyreportscontrollerfindall.d.ts.map +1 -0
- package/dist/esm/models/operations/dailyreportscontrollerfindall.js +22 -0
- package/dist/esm/models/operations/dailyreportscontrollerfindall.js.map +1 -0
- package/dist/esm/models/operations/dailyreportscontrollerfindone.d.ts +15 -0
- package/dist/esm/models/operations/dailyreportscontrollerfindone.d.ts.map +1 -0
- package/dist/esm/models/operations/dailyreportscontrollerfindone.js +12 -0
- package/dist/esm/models/operations/dailyreportscontrollerfindone.js.map +1 -0
- package/dist/esm/models/operations/dailyreportscontrollerupdate.d.ts +26 -0
- package/dist/esm/models/operations/dailyreportscontrollerupdate.d.ts.map +1 -0
- package/dist/esm/models/operations/dailyreportscontrollerupdate.js +21 -0
- package/dist/esm/models/operations/dailyreportscontrollerupdate.js.map +1 -0
- package/dist/esm/models/operations/index.d.ts +9 -0
- package/dist/esm/models/operations/index.d.ts.map +1 -1
- package/dist/esm/models/operations/index.js +9 -0
- package/dist/esm/models/operations/index.js.map +1 -1
- package/dist/esm/models/paymentdto.d.ts +4 -0
- package/dist/esm/models/paymentdto.d.ts.map +1 -1
- package/dist/esm/models/paymentdto.js +2 -0
- package/dist/esm/models/paymentdto.js.map +1 -1
- package/dist/esm/models/paymentinformationdto.d.ts +4 -0
- package/dist/esm/models/paymentinformationdto.d.ts.map +1 -1
- package/dist/esm/models/paymentinformationdto.js +2 -0
- package/dist/esm/models/paymentinformationdto.js.map +1 -1
- package/dist/esm/models/programresponsedto.d.ts +5 -0
- package/dist/esm/models/programresponsedto.d.ts.map +1 -1
- package/dist/esm/models/programresponsedto.js +3 -0
- package/dist/esm/models/programresponsedto.js.map +1 -1
- package/dist/esm/models/updatebillingcycleconfigsdto.d.ts +25 -0
- package/dist/esm/models/updatebillingcycleconfigsdto.d.ts.map +1 -0
- package/dist/esm/models/updatebillingcycleconfigsdto.js +20 -0
- package/dist/esm/models/updatebillingcycleconfigsdto.js.map +1 -0
- package/dist/esm/models/updatedailyreportdto.d.ts +40 -0
- package/dist/esm/models/updatedailyreportdto.d.ts.map +1 -0
- package/dist/esm/models/updatedailyreportdto.js +25 -0
- package/dist/esm/models/updatedailyreportdto.js.map +1 -0
- package/dist/esm/models/updateprogramdto.d.ts +6 -0
- package/dist/esm/models/updateprogramdto.d.ts.map +1 -1
- package/dist/esm/models/updateprogramdto.js +3 -0
- package/dist/esm/models/updateprogramdto.js.map +1 -1
- package/dist/esm/sdk/billingcycleconfigs.d.ts +18 -0
- package/dist/esm/sdk/billingcycleconfigs.d.ts.map +1 -0
- package/dist/esm/sdk/billingcycleconfigs.js +29 -0
- package/dist/esm/sdk/billingcycleconfigs.js.map +1 -0
- package/dist/esm/sdk/billingcycles.d.ts +17 -0
- package/dist/esm/sdk/billingcycles.d.ts.map +1 -0
- package/dist/esm/sdk/billingcycles.js +23 -0
- package/dist/esm/sdk/billingcycles.js.map +1 -0
- package/dist/esm/sdk/dailyreports.d.ts +25 -0
- package/dist/esm/sdk/dailyreports.d.ts.map +1 -0
- package/dist/esm/sdk/dailyreports.js +37 -0
- package/dist/esm/sdk/dailyreports.js.map +1 -0
- package/dist/esm/sdk/sdk.d.ts +9 -0
- package/dist/esm/sdk/sdk.d.ts.map +1 -1
- package/dist/esm/sdk/sdk.js +12 -0
- package/dist/esm/sdk/sdk.js.map +1 -1
- package/jsr.json +1 -1
- package/package.json +1 -1
- package/src/funcs/billingCycleConfigsCreate.ts +188 -0
- package/src/funcs/billingCycleConfigsGet.ts +182 -0
- package/src/funcs/billingCycleConfigsUpdate.ts +187 -0
- package/src/funcs/billingCyclesGet.ts +181 -0
- package/src/funcs/billingCyclesList.ts +251 -0
- package/src/funcs/dailyReportsCreate.ts +178 -0
- package/src/funcs/dailyReportsGet.ts +176 -0
- package/src/funcs/dailyReportsList.ts +243 -0
- package/src/funcs/dailyReportsUpdate.ts +184 -0
- package/src/funcs/embedExchangeToken.ts +3 -1
- package/src/funcs/embedRefreshToken.ts +3 -1
- package/src/lib/config.ts +3 -3
- package/src/lib/security.ts +14 -2
- package/src/models/billingcycleconfigsresponsedto.ts +112 -0
- package/src/models/billingcyclesresponsedto.ts +146 -0
- package/src/models/createbillingcycleconfigsdto.ts +61 -0
- package/src/models/createdailyreportdto.ts +78 -0
- package/src/models/createpaymentdto.ts +7 -0
- package/src/models/createprogramdto.ts +12 -0
- package/src/models/dailyreportdto.ts +106 -0
- package/src/models/index.ts +8 -0
- package/src/models/onboardingsettingsdto.ts +125 -0
- package/src/models/operations/billingcycleconfigscontrollercreatebillingcycleconfig.ts +55 -0
- package/src/models/operations/billingcycleconfigscontrollergetbillingcycleconfig.ts +44 -0
- package/src/models/operations/billingcycleconfigscontrollerupdatebillingcycleconfig.ts +54 -0
- package/src/models/operations/billingcyclescontrollergetbillingcycle.ts +49 -0
- package/src/models/operations/billingcyclescontrollerlistbillingcycles.ts +91 -0
- package/src/models/operations/dailyreportscontrollercreate.ts +49 -0
- package/src/models/operations/dailyreportscontrollerfindall.ts +66 -0
- package/src/models/operations/dailyreportscontrollerfindone.ts +36 -0
- package/src/models/operations/dailyreportscontrollerupdate.ts +55 -0
- package/src/models/operations/index.ts +9 -0
- package/src/models/paymentdto.ts +6 -0
- package/src/models/paymentinformationdto.ts +6 -0
- package/src/models/programresponsedto.ts +10 -0
- package/src/models/updatebillingcycleconfigsdto.ts +54 -0
- package/src/models/updatedailyreportdto.ts +72 -0
- package/src/models/updateprogramdto.ts +12 -0
- package/src/sdk/billingcycleconfigs.ts +58 -0
- package/src/sdk/billingcycles.ts +41 -0
- package/src/sdk/dailyreports.ts +71 -0
- package/src/sdk/sdk.ts +20 -0
|
@@ -0,0 +1,181 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import { OatFiSDKCore } from "../core.js";
|
|
6
|
+
import { encodeSimple } from "../lib/encodings.js";
|
|
7
|
+
import * as M from "../lib/matchers.js";
|
|
8
|
+
import { compactMap } from "../lib/primitives.js";
|
|
9
|
+
import { safeParse } from "../lib/schemas.js";
|
|
10
|
+
import { RequestOptions } from "../lib/sdks.js";
|
|
11
|
+
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
12
|
+
import { pathToFunc } from "../lib/url.js";
|
|
13
|
+
import {
|
|
14
|
+
ConnectionError,
|
|
15
|
+
InvalidRequestError,
|
|
16
|
+
RequestAbortedError,
|
|
17
|
+
RequestTimeoutError,
|
|
18
|
+
UnexpectedClientError,
|
|
19
|
+
} from "../models/errors/httpclienterrors.js";
|
|
20
|
+
import { OatFiSDKError } from "../models/errors/oatfisdkerror.js";
|
|
21
|
+
import { ResponseValidationError } from "../models/errors/responsevalidationerror.js";
|
|
22
|
+
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
|
|
23
|
+
import * as models from "../models/index.js";
|
|
24
|
+
import * as operations from "../models/operations/index.js";
|
|
25
|
+
import { APICall, APIPromise } from "../types/async.js";
|
|
26
|
+
import { Result } from "../types/fp.js";
|
|
27
|
+
|
|
28
|
+
/**
|
|
29
|
+
* Get a specific billing cycle by ID
|
|
30
|
+
*/
|
|
31
|
+
export function billingCyclesGet(
|
|
32
|
+
client: OatFiSDKCore,
|
|
33
|
+
request: operations.BillingCyclesControllerGetBillingCycleRequest,
|
|
34
|
+
options?: RequestOptions,
|
|
35
|
+
): APIPromise<
|
|
36
|
+
Result<
|
|
37
|
+
models.BillingCyclesResponseDto,
|
|
38
|
+
| OatFiSDKError
|
|
39
|
+
| ResponseValidationError
|
|
40
|
+
| ConnectionError
|
|
41
|
+
| RequestAbortedError
|
|
42
|
+
| RequestTimeoutError
|
|
43
|
+
| InvalidRequestError
|
|
44
|
+
| UnexpectedClientError
|
|
45
|
+
| SDKValidationError
|
|
46
|
+
>
|
|
47
|
+
> {
|
|
48
|
+
return new APIPromise($do(
|
|
49
|
+
client,
|
|
50
|
+
request,
|
|
51
|
+
options,
|
|
52
|
+
));
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
async function $do(
|
|
56
|
+
client: OatFiSDKCore,
|
|
57
|
+
request: operations.BillingCyclesControllerGetBillingCycleRequest,
|
|
58
|
+
options?: RequestOptions,
|
|
59
|
+
): Promise<
|
|
60
|
+
[
|
|
61
|
+
Result<
|
|
62
|
+
models.BillingCyclesResponseDto,
|
|
63
|
+
| OatFiSDKError
|
|
64
|
+
| ResponseValidationError
|
|
65
|
+
| ConnectionError
|
|
66
|
+
| RequestAbortedError
|
|
67
|
+
| RequestTimeoutError
|
|
68
|
+
| InvalidRequestError
|
|
69
|
+
| UnexpectedClientError
|
|
70
|
+
| SDKValidationError
|
|
71
|
+
>,
|
|
72
|
+
APICall,
|
|
73
|
+
]
|
|
74
|
+
> {
|
|
75
|
+
const parsed = safeParse(
|
|
76
|
+
request,
|
|
77
|
+
(value) =>
|
|
78
|
+
operations.BillingCyclesControllerGetBillingCycleRequest$outboundSchema
|
|
79
|
+
.parse(value),
|
|
80
|
+
"Input validation failed",
|
|
81
|
+
);
|
|
82
|
+
if (!parsed.ok) {
|
|
83
|
+
return [parsed, { status: "invalid" }];
|
|
84
|
+
}
|
|
85
|
+
const payload = parsed.value;
|
|
86
|
+
const body = null;
|
|
87
|
+
|
|
88
|
+
const pathParams = {
|
|
89
|
+
billing_cycle: encodeSimple("billing_cycle", payload.billing_cycle, {
|
|
90
|
+
explode: false,
|
|
91
|
+
charEncoding: "percent",
|
|
92
|
+
}),
|
|
93
|
+
business: encodeSimple("business", payload.business, {
|
|
94
|
+
explode: false,
|
|
95
|
+
charEncoding: "percent",
|
|
96
|
+
}),
|
|
97
|
+
};
|
|
98
|
+
const path = pathToFunc(
|
|
99
|
+
"/v3/businesses/{business}/billing-cycles/{billing_cycle}",
|
|
100
|
+
)(pathParams);
|
|
101
|
+
|
|
102
|
+
const headers = new Headers(compactMap({
|
|
103
|
+
Accept: "application/json",
|
|
104
|
+
}));
|
|
105
|
+
|
|
106
|
+
const secConfig = await extractSecurity(client._options.bearer);
|
|
107
|
+
const securityInput = secConfig == null ? {} : { bearer: secConfig };
|
|
108
|
+
const requestSecurity = resolveGlobalSecurity(securityInput);
|
|
109
|
+
|
|
110
|
+
const context = {
|
|
111
|
+
options: client._options,
|
|
112
|
+
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
113
|
+
operationID: "BillingCyclesController_getBillingCycle",
|
|
114
|
+
oAuth2Scopes: null,
|
|
115
|
+
|
|
116
|
+
resolvedSecurity: requestSecurity,
|
|
117
|
+
|
|
118
|
+
securitySource: client._options.bearer,
|
|
119
|
+
retryConfig: options?.retries
|
|
120
|
+
|| client._options.retryConfig
|
|
121
|
+
|| {
|
|
122
|
+
strategy: "backoff",
|
|
123
|
+
backoff: {
|
|
124
|
+
initialInterval: 500,
|
|
125
|
+
maxInterval: 60000,
|
|
126
|
+
exponent: 1.5,
|
|
127
|
+
maxElapsedTime: 120000,
|
|
128
|
+
},
|
|
129
|
+
retryConnectionErrors: true,
|
|
130
|
+
}
|
|
131
|
+
|| { strategy: "none" },
|
|
132
|
+
retryCodes: options?.retryCodes || ["5XX"],
|
|
133
|
+
};
|
|
134
|
+
|
|
135
|
+
const requestRes = client._createRequest(context, {
|
|
136
|
+
security: requestSecurity,
|
|
137
|
+
method: "GET",
|
|
138
|
+
baseURL: options?.serverURL,
|
|
139
|
+
path: path,
|
|
140
|
+
headers: headers,
|
|
141
|
+
body: body,
|
|
142
|
+
userAgent: client._options.userAgent,
|
|
143
|
+
timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
|
|
144
|
+
}, options);
|
|
145
|
+
if (!requestRes.ok) {
|
|
146
|
+
return [requestRes, { status: "invalid" }];
|
|
147
|
+
}
|
|
148
|
+
const req = requestRes.value;
|
|
149
|
+
|
|
150
|
+
const doResult = await client._do(req, {
|
|
151
|
+
context,
|
|
152
|
+
errorCodes: ["400", "404", "4XX", "5XX"],
|
|
153
|
+
retryConfig: context.retryConfig,
|
|
154
|
+
retryCodes: context.retryCodes,
|
|
155
|
+
});
|
|
156
|
+
if (!doResult.ok) {
|
|
157
|
+
return [doResult, { status: "request-error", request: req }];
|
|
158
|
+
}
|
|
159
|
+
const response = doResult.value;
|
|
160
|
+
|
|
161
|
+
const [result] = await M.match<
|
|
162
|
+
models.BillingCyclesResponseDto,
|
|
163
|
+
| OatFiSDKError
|
|
164
|
+
| ResponseValidationError
|
|
165
|
+
| ConnectionError
|
|
166
|
+
| RequestAbortedError
|
|
167
|
+
| RequestTimeoutError
|
|
168
|
+
| InvalidRequestError
|
|
169
|
+
| UnexpectedClientError
|
|
170
|
+
| SDKValidationError
|
|
171
|
+
>(
|
|
172
|
+
M.json(200, models.BillingCyclesResponseDto$inboundSchema),
|
|
173
|
+
M.fail([400, 404, "4XX"]),
|
|
174
|
+
M.fail("5XX"),
|
|
175
|
+
)(response, req);
|
|
176
|
+
if (!result.ok) {
|
|
177
|
+
return [result, { status: "complete", request: req, response }];
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
return [result, { status: "complete", request: req, response }];
|
|
181
|
+
}
|
|
@@ -0,0 +1,251 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import { JsonValue, query as jpQuery } from "jsonpath-rfc9535";
|
|
6
|
+
import * as z from "zod/v3";
|
|
7
|
+
import { OatFiSDKCore } from "../core.js";
|
|
8
|
+
import { encodeFormQuery, encodeSimple } from "../lib/encodings.js";
|
|
9
|
+
import * as M from "../lib/matchers.js";
|
|
10
|
+
import { compactMap } from "../lib/primitives.js";
|
|
11
|
+
import { safeParse } from "../lib/schemas.js";
|
|
12
|
+
import { RequestOptions } from "../lib/sdks.js";
|
|
13
|
+
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
14
|
+
import { pathToFunc } from "../lib/url.js";
|
|
15
|
+
import {
|
|
16
|
+
ConnectionError,
|
|
17
|
+
InvalidRequestError,
|
|
18
|
+
RequestAbortedError,
|
|
19
|
+
RequestTimeoutError,
|
|
20
|
+
UnexpectedClientError,
|
|
21
|
+
} from "../models/errors/httpclienterrors.js";
|
|
22
|
+
import { OatFiSDKError } from "../models/errors/oatfisdkerror.js";
|
|
23
|
+
import { ResponseValidationError } from "../models/errors/responsevalidationerror.js";
|
|
24
|
+
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
|
|
25
|
+
import * as operations from "../models/operations/index.js";
|
|
26
|
+
import { APICall, APIPromise } from "../types/async.js";
|
|
27
|
+
import { Result } from "../types/fp.js";
|
|
28
|
+
import {
|
|
29
|
+
createPageIterator,
|
|
30
|
+
haltIterator,
|
|
31
|
+
PageIterator,
|
|
32
|
+
Paginator,
|
|
33
|
+
} from "../types/operations.js";
|
|
34
|
+
|
|
35
|
+
/**
|
|
36
|
+
* List billing cycles for a business
|
|
37
|
+
*/
|
|
38
|
+
export function billingCyclesList(
|
|
39
|
+
client: OatFiSDKCore,
|
|
40
|
+
request: operations.BillingCyclesControllerListBillingCyclesRequest,
|
|
41
|
+
options?: RequestOptions,
|
|
42
|
+
): APIPromise<
|
|
43
|
+
PageIterator<
|
|
44
|
+
Result<
|
|
45
|
+
void,
|
|
46
|
+
| OatFiSDKError
|
|
47
|
+
| ResponseValidationError
|
|
48
|
+
| ConnectionError
|
|
49
|
+
| RequestAbortedError
|
|
50
|
+
| RequestTimeoutError
|
|
51
|
+
| InvalidRequestError
|
|
52
|
+
| UnexpectedClientError
|
|
53
|
+
| SDKValidationError
|
|
54
|
+
>,
|
|
55
|
+
{ cursor: string }
|
|
56
|
+
>
|
|
57
|
+
> {
|
|
58
|
+
return new APIPromise($do(
|
|
59
|
+
client,
|
|
60
|
+
request,
|
|
61
|
+
options,
|
|
62
|
+
));
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
async function $do(
|
|
66
|
+
client: OatFiSDKCore,
|
|
67
|
+
request: operations.BillingCyclesControllerListBillingCyclesRequest,
|
|
68
|
+
options?: RequestOptions,
|
|
69
|
+
): Promise<
|
|
70
|
+
[
|
|
71
|
+
PageIterator<
|
|
72
|
+
Result<
|
|
73
|
+
void,
|
|
74
|
+
| OatFiSDKError
|
|
75
|
+
| ResponseValidationError
|
|
76
|
+
| ConnectionError
|
|
77
|
+
| RequestAbortedError
|
|
78
|
+
| RequestTimeoutError
|
|
79
|
+
| InvalidRequestError
|
|
80
|
+
| UnexpectedClientError
|
|
81
|
+
| SDKValidationError
|
|
82
|
+
>,
|
|
83
|
+
{ cursor: string }
|
|
84
|
+
>,
|
|
85
|
+
APICall,
|
|
86
|
+
]
|
|
87
|
+
> {
|
|
88
|
+
const parsed = safeParse(
|
|
89
|
+
request,
|
|
90
|
+
(value) =>
|
|
91
|
+
operations.BillingCyclesControllerListBillingCyclesRequest$outboundSchema
|
|
92
|
+
.parse(value),
|
|
93
|
+
"Input validation failed",
|
|
94
|
+
);
|
|
95
|
+
if (!parsed.ok) {
|
|
96
|
+
return [haltIterator(parsed), { status: "invalid" }];
|
|
97
|
+
}
|
|
98
|
+
const payload = parsed.value;
|
|
99
|
+
const body = null;
|
|
100
|
+
|
|
101
|
+
const pathParams = {
|
|
102
|
+
business: encodeSimple("business", payload.business, {
|
|
103
|
+
explode: false,
|
|
104
|
+
charEncoding: "percent",
|
|
105
|
+
}),
|
|
106
|
+
};
|
|
107
|
+
const path = pathToFunc("/v3/businesses/{business}/billing-cycles")(
|
|
108
|
+
pathParams,
|
|
109
|
+
);
|
|
110
|
+
|
|
111
|
+
const query = encodeFormQuery({
|
|
112
|
+
"ending_before": payload.ending_before,
|
|
113
|
+
"limit": payload.limit,
|
|
114
|
+
"program": payload.program,
|
|
115
|
+
"starting_after": payload.starting_after,
|
|
116
|
+
"status": payload.status,
|
|
117
|
+
});
|
|
118
|
+
|
|
119
|
+
const headers = new Headers(compactMap({
|
|
120
|
+
Accept: "*/*",
|
|
121
|
+
}));
|
|
122
|
+
|
|
123
|
+
const secConfig = await extractSecurity(client._options.bearer);
|
|
124
|
+
const securityInput = secConfig == null ? {} : { bearer: secConfig };
|
|
125
|
+
const requestSecurity = resolveGlobalSecurity(securityInput);
|
|
126
|
+
|
|
127
|
+
const context = {
|
|
128
|
+
options: client._options,
|
|
129
|
+
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
130
|
+
operationID: "BillingCyclesController_listBillingCycles",
|
|
131
|
+
oAuth2Scopes: null,
|
|
132
|
+
|
|
133
|
+
resolvedSecurity: requestSecurity,
|
|
134
|
+
|
|
135
|
+
securitySource: client._options.bearer,
|
|
136
|
+
retryConfig: options?.retries
|
|
137
|
+
|| client._options.retryConfig
|
|
138
|
+
|| {
|
|
139
|
+
strategy: "backoff",
|
|
140
|
+
backoff: {
|
|
141
|
+
initialInterval: 500,
|
|
142
|
+
maxInterval: 60000,
|
|
143
|
+
exponent: 1.5,
|
|
144
|
+
maxElapsedTime: 120000,
|
|
145
|
+
},
|
|
146
|
+
retryConnectionErrors: true,
|
|
147
|
+
}
|
|
148
|
+
|| { strategy: "none" },
|
|
149
|
+
retryCodes: options?.retryCodes || ["5XX"],
|
|
150
|
+
};
|
|
151
|
+
|
|
152
|
+
const requestRes = client._createRequest(context, {
|
|
153
|
+
security: requestSecurity,
|
|
154
|
+
method: "GET",
|
|
155
|
+
baseURL: options?.serverURL,
|
|
156
|
+
path: path,
|
|
157
|
+
headers: headers,
|
|
158
|
+
query: query,
|
|
159
|
+
body: body,
|
|
160
|
+
userAgent: client._options.userAgent,
|
|
161
|
+
timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
|
|
162
|
+
}, options);
|
|
163
|
+
if (!requestRes.ok) {
|
|
164
|
+
return [haltIterator(requestRes), { status: "invalid" }];
|
|
165
|
+
}
|
|
166
|
+
const req = requestRes.value;
|
|
167
|
+
|
|
168
|
+
const doResult = await client._do(req, {
|
|
169
|
+
context,
|
|
170
|
+
errorCodes: ["400", "404", "4XX", "5XX"],
|
|
171
|
+
retryConfig: context.retryConfig,
|
|
172
|
+
retryCodes: context.retryCodes,
|
|
173
|
+
});
|
|
174
|
+
if (!doResult.ok) {
|
|
175
|
+
return [haltIterator(doResult), { status: "request-error", request: req }];
|
|
176
|
+
}
|
|
177
|
+
const response = doResult.value;
|
|
178
|
+
|
|
179
|
+
const responseFields = {
|
|
180
|
+
HttpMeta: { Response: response, Request: req },
|
|
181
|
+
};
|
|
182
|
+
|
|
183
|
+
const [result, raw] = await M.match<
|
|
184
|
+
void,
|
|
185
|
+
| OatFiSDKError
|
|
186
|
+
| ResponseValidationError
|
|
187
|
+
| ConnectionError
|
|
188
|
+
| RequestAbortedError
|
|
189
|
+
| RequestTimeoutError
|
|
190
|
+
| InvalidRequestError
|
|
191
|
+
| UnexpectedClientError
|
|
192
|
+
| SDKValidationError
|
|
193
|
+
>(
|
|
194
|
+
M.nil(200, z.void()),
|
|
195
|
+
M.fail([400, 404, "4XX"]),
|
|
196
|
+
M.fail("5XX"),
|
|
197
|
+
)(response, req, { extraFields: responseFields });
|
|
198
|
+
if (!result.ok) {
|
|
199
|
+
return [haltIterator(result), {
|
|
200
|
+
status: "complete",
|
|
201
|
+
request: req,
|
|
202
|
+
response,
|
|
203
|
+
}];
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
const nextFunc = (
|
|
207
|
+
responseData: unknown,
|
|
208
|
+
): {
|
|
209
|
+
next: Paginator<
|
|
210
|
+
Result<
|
|
211
|
+
void,
|
|
212
|
+
| OatFiSDKError
|
|
213
|
+
| ResponseValidationError
|
|
214
|
+
| ConnectionError
|
|
215
|
+
| RequestAbortedError
|
|
216
|
+
| RequestTimeoutError
|
|
217
|
+
| InvalidRequestError
|
|
218
|
+
| UnexpectedClientError
|
|
219
|
+
| SDKValidationError
|
|
220
|
+
>
|
|
221
|
+
>;
|
|
222
|
+
"~next"?: { cursor: string };
|
|
223
|
+
} => {
|
|
224
|
+
const nextCursor = jpQuery(responseData as JsonValue, "$.data[-1].id")[0];
|
|
225
|
+
if (typeof nextCursor !== "string") {
|
|
226
|
+
return { next: () => null };
|
|
227
|
+
}
|
|
228
|
+
if (nextCursor.trim() === "") {
|
|
229
|
+
return { next: () => null };
|
|
230
|
+
}
|
|
231
|
+
|
|
232
|
+
const nextVal = () =>
|
|
233
|
+
billingCyclesList(
|
|
234
|
+
client,
|
|
235
|
+
{
|
|
236
|
+
...request,
|
|
237
|
+
startingAfter: nextCursor,
|
|
238
|
+
},
|
|
239
|
+
options,
|
|
240
|
+
);
|
|
241
|
+
|
|
242
|
+
return { next: nextVal, "~next": { cursor: nextCursor } };
|
|
243
|
+
};
|
|
244
|
+
|
|
245
|
+
const page = { ...result, ...nextFunc(raw) };
|
|
246
|
+
return [{ ...page, ...createPageIterator(page, (v) => !v.ok) }, {
|
|
247
|
+
status: "complete",
|
|
248
|
+
request: req,
|
|
249
|
+
response,
|
|
250
|
+
}];
|
|
251
|
+
}
|
|
@@ -0,0 +1,178 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import { OatFiSDKCore } from "../core.js";
|
|
6
|
+
import { encodeJSON, encodeSimple } from "../lib/encodings.js";
|
|
7
|
+
import * as M from "../lib/matchers.js";
|
|
8
|
+
import { compactMap } from "../lib/primitives.js";
|
|
9
|
+
import { safeParse } from "../lib/schemas.js";
|
|
10
|
+
import { RequestOptions } from "../lib/sdks.js";
|
|
11
|
+
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
12
|
+
import { pathToFunc } from "../lib/url.js";
|
|
13
|
+
import {
|
|
14
|
+
ConnectionError,
|
|
15
|
+
InvalidRequestError,
|
|
16
|
+
RequestAbortedError,
|
|
17
|
+
RequestTimeoutError,
|
|
18
|
+
UnexpectedClientError,
|
|
19
|
+
} from "../models/errors/httpclienterrors.js";
|
|
20
|
+
import { OatFiSDKError } from "../models/errors/oatfisdkerror.js";
|
|
21
|
+
import { ResponseValidationError } from "../models/errors/responsevalidationerror.js";
|
|
22
|
+
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
|
|
23
|
+
import * as models from "../models/index.js";
|
|
24
|
+
import * as operations from "../models/operations/index.js";
|
|
25
|
+
import { APICall, APIPromise } from "../types/async.js";
|
|
26
|
+
import { Result } from "../types/fp.js";
|
|
27
|
+
|
|
28
|
+
/**
|
|
29
|
+
* Create a daily report
|
|
30
|
+
*/
|
|
31
|
+
export function dailyReportsCreate(
|
|
32
|
+
client: OatFiSDKCore,
|
|
33
|
+
request: operations.DailyReportsControllerCreateRequest,
|
|
34
|
+
options?: RequestOptions,
|
|
35
|
+
): APIPromise<
|
|
36
|
+
Result<
|
|
37
|
+
models.DailyReportDto,
|
|
38
|
+
| OatFiSDKError
|
|
39
|
+
| ResponseValidationError
|
|
40
|
+
| ConnectionError
|
|
41
|
+
| RequestAbortedError
|
|
42
|
+
| RequestTimeoutError
|
|
43
|
+
| InvalidRequestError
|
|
44
|
+
| UnexpectedClientError
|
|
45
|
+
| SDKValidationError
|
|
46
|
+
>
|
|
47
|
+
> {
|
|
48
|
+
return new APIPromise($do(
|
|
49
|
+
client,
|
|
50
|
+
request,
|
|
51
|
+
options,
|
|
52
|
+
));
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
async function $do(
|
|
56
|
+
client: OatFiSDKCore,
|
|
57
|
+
request: operations.DailyReportsControllerCreateRequest,
|
|
58
|
+
options?: RequestOptions,
|
|
59
|
+
): Promise<
|
|
60
|
+
[
|
|
61
|
+
Result<
|
|
62
|
+
models.DailyReportDto,
|
|
63
|
+
| OatFiSDKError
|
|
64
|
+
| ResponseValidationError
|
|
65
|
+
| ConnectionError
|
|
66
|
+
| RequestAbortedError
|
|
67
|
+
| RequestTimeoutError
|
|
68
|
+
| InvalidRequestError
|
|
69
|
+
| UnexpectedClientError
|
|
70
|
+
| SDKValidationError
|
|
71
|
+
>,
|
|
72
|
+
APICall,
|
|
73
|
+
]
|
|
74
|
+
> {
|
|
75
|
+
const parsed = safeParse(
|
|
76
|
+
request,
|
|
77
|
+
(value) =>
|
|
78
|
+
operations.DailyReportsControllerCreateRequest$outboundSchema.parse(
|
|
79
|
+
value,
|
|
80
|
+
),
|
|
81
|
+
"Input validation failed",
|
|
82
|
+
);
|
|
83
|
+
if (!parsed.ok) {
|
|
84
|
+
return [parsed, { status: "invalid" }];
|
|
85
|
+
}
|
|
86
|
+
const payload = parsed.value;
|
|
87
|
+
const body = encodeJSON("body", payload.CreateDailyReportDto, {
|
|
88
|
+
explode: true,
|
|
89
|
+
});
|
|
90
|
+
|
|
91
|
+
const path = pathToFunc("/v3/daily-reports")();
|
|
92
|
+
|
|
93
|
+
const headers = new Headers(compactMap({
|
|
94
|
+
"Content-Type": "application/json",
|
|
95
|
+
Accept: "application/json",
|
|
96
|
+
"Idempotency-Key": encodeSimple(
|
|
97
|
+
"Idempotency-Key",
|
|
98
|
+
payload["Idempotency-Key"],
|
|
99
|
+
{ explode: false, charEncoding: "none" },
|
|
100
|
+
),
|
|
101
|
+
}));
|
|
102
|
+
|
|
103
|
+
const secConfig = await extractSecurity(client._options.bearer);
|
|
104
|
+
const securityInput = secConfig == null ? {} : { bearer: secConfig };
|
|
105
|
+
const requestSecurity = resolveGlobalSecurity(securityInput);
|
|
106
|
+
|
|
107
|
+
const context = {
|
|
108
|
+
options: client._options,
|
|
109
|
+
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
110
|
+
operationID: "DailyReportsController_create",
|
|
111
|
+
oAuth2Scopes: null,
|
|
112
|
+
|
|
113
|
+
resolvedSecurity: requestSecurity,
|
|
114
|
+
|
|
115
|
+
securitySource: client._options.bearer,
|
|
116
|
+
retryConfig: options?.retries
|
|
117
|
+
|| client._options.retryConfig
|
|
118
|
+
|| {
|
|
119
|
+
strategy: "backoff",
|
|
120
|
+
backoff: {
|
|
121
|
+
initialInterval: 500,
|
|
122
|
+
maxInterval: 60000,
|
|
123
|
+
exponent: 1.5,
|
|
124
|
+
maxElapsedTime: 120000,
|
|
125
|
+
},
|
|
126
|
+
retryConnectionErrors: true,
|
|
127
|
+
}
|
|
128
|
+
|| { strategy: "none" },
|
|
129
|
+
retryCodes: options?.retryCodes || ["5XX"],
|
|
130
|
+
};
|
|
131
|
+
|
|
132
|
+
const requestRes = client._createRequest(context, {
|
|
133
|
+
security: requestSecurity,
|
|
134
|
+
method: "POST",
|
|
135
|
+
baseURL: options?.serverURL,
|
|
136
|
+
path: path,
|
|
137
|
+
headers: headers,
|
|
138
|
+
body: body,
|
|
139
|
+
userAgent: client._options.userAgent,
|
|
140
|
+
timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
|
|
141
|
+
}, options);
|
|
142
|
+
if (!requestRes.ok) {
|
|
143
|
+
return [requestRes, { status: "invalid" }];
|
|
144
|
+
}
|
|
145
|
+
const req = requestRes.value;
|
|
146
|
+
|
|
147
|
+
const doResult = await client._do(req, {
|
|
148
|
+
context,
|
|
149
|
+
errorCodes: ["400", "401", "403", "409", "429", "4XX", "500", "5XX"],
|
|
150
|
+
retryConfig: context.retryConfig,
|
|
151
|
+
retryCodes: context.retryCodes,
|
|
152
|
+
});
|
|
153
|
+
if (!doResult.ok) {
|
|
154
|
+
return [doResult, { status: "request-error", request: req }];
|
|
155
|
+
}
|
|
156
|
+
const response = doResult.value;
|
|
157
|
+
|
|
158
|
+
const [result] = await M.match<
|
|
159
|
+
models.DailyReportDto,
|
|
160
|
+
| OatFiSDKError
|
|
161
|
+
| ResponseValidationError
|
|
162
|
+
| ConnectionError
|
|
163
|
+
| RequestAbortedError
|
|
164
|
+
| RequestTimeoutError
|
|
165
|
+
| InvalidRequestError
|
|
166
|
+
| UnexpectedClientError
|
|
167
|
+
| SDKValidationError
|
|
168
|
+
>(
|
|
169
|
+
M.json(201, models.DailyReportDto$inboundSchema),
|
|
170
|
+
M.fail([400, 401, 403, 409, 429, "4XX"]),
|
|
171
|
+
M.fail([500, "5XX"]),
|
|
172
|
+
)(response, req);
|
|
173
|
+
if (!result.ok) {
|
|
174
|
+
return [result, { status: "complete", request: req, response }];
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
return [result, { status: "complete", request: req, response }];
|
|
178
|
+
}
|