@tryfinch/finch-api 6.31.0 → 8.0.0
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/CHANGELOG.md +330 -0
- package/README.md +129 -68
- package/api-promise.d.mts +2 -0
- package/api-promise.d.mts.map +1 -0
- package/api-promise.d.ts +2 -0
- package/api-promise.d.ts.map +1 -0
- package/api-promise.js +6 -0
- package/api-promise.js.map +1 -0
- package/api-promise.mjs +2 -0
- package/api-promise.mjs.map +1 -0
- package/bin/cli +53 -0
- package/bin/migration-config.json +6 -0
- package/client.d.mts +258 -0
- package/client.d.mts.map +1 -0
- package/client.d.ts +258 -0
- package/client.d.ts.map +1 -0
- package/client.js +553 -0
- package/client.js.map +1 -0
- package/client.mjs +549 -0
- package/client.mjs.map +1 -0
- package/core/api-promise.d.mts +46 -0
- package/core/api-promise.d.mts.map +1 -0
- package/core/api-promise.d.ts +46 -0
- package/core/api-promise.d.ts.map +1 -0
- package/core/api-promise.js +74 -0
- package/core/api-promise.js.map +1 -0
- package/core/api-promise.mjs +70 -0
- package/core/api-promise.mjs.map +1 -0
- package/core/error.d.mts +46 -0
- package/core/error.d.mts.map +1 -0
- package/core/error.d.ts +46 -0
- package/core/error.d.ts.map +1 -0
- package/core/error.js +113 -0
- package/core/error.js.map +1 -0
- package/core/error.mjs +97 -0
- package/core/error.mjs.map +1 -0
- package/core/pagination.d.mts +105 -0
- package/core/pagination.d.mts.map +1 -0
- package/core/pagination.d.ts +105 -0
- package/core/pagination.d.ts.map +1 -0
- package/core/pagination.js +163 -0
- package/core/pagination.js.map +1 -0
- package/core/pagination.mjs +154 -0
- package/core/pagination.mjs.map +1 -0
- package/core/resource.d.mts +6 -0
- package/core/resource.d.mts.map +1 -0
- package/core/resource.d.ts +6 -0
- package/core/resource.d.ts.map +1 -0
- package/core/resource.js +11 -0
- package/core/resource.js.map +1 -0
- package/core/resource.mjs +7 -0
- package/core/resource.mjs.map +1 -0
- package/core/uploads.d.mts +3 -0
- package/core/uploads.d.mts.map +1 -0
- package/core/uploads.d.ts +3 -0
- package/core/uploads.d.ts.map +1 -0
- package/core/uploads.js +6 -0
- package/core/uploads.js.map +1 -0
- package/core/uploads.mjs +2 -0
- package/core/uploads.mjs.map +1 -0
- package/error.d.mts +2 -0
- package/error.d.mts.map +1 -0
- package/error.d.ts +1 -46
- package/error.d.ts.map +1 -1
- package/error.js +3 -110
- package/error.js.map +1 -1
- package/error.mjs +1 -96
- package/error.mjs.map +1 -1
- package/index.d.mts +7 -197
- package/index.d.mts.map +1 -0
- package/index.d.ts +6 -196
- package/index.d.ts.map +1 -1
- package/index.js +14 -235
- package/index.js.map +1 -1
- package/index.mjs +6 -208
- package/index.mjs.map +1 -1
- package/internal/builtin-types.d.mts +73 -0
- package/internal/builtin-types.d.mts.map +1 -0
- package/internal/builtin-types.d.ts +73 -0
- package/internal/builtin-types.d.ts.map +1 -0
- package/internal/builtin-types.js +4 -0
- package/internal/builtin-types.js.map +1 -0
- package/internal/builtin-types.mjs +3 -0
- package/internal/builtin-types.mjs.map +1 -0
- package/internal/detect-platform.d.mts +15 -0
- package/internal/detect-platform.d.mts.map +1 -0
- package/internal/detect-platform.d.ts +15 -0
- package/internal/detect-platform.d.ts.map +1 -0
- package/internal/detect-platform.js +162 -0
- package/internal/detect-platform.js.map +1 -0
- package/internal/detect-platform.mjs +157 -0
- package/internal/detect-platform.mjs.map +1 -0
- package/internal/errors.d.mts +3 -0
- package/internal/errors.d.mts.map +1 -0
- package/internal/errors.d.ts +3 -0
- package/internal/errors.d.ts.map +1 -0
- package/internal/errors.js +41 -0
- package/internal/errors.js.map +1 -0
- package/internal/errors.mjs +36 -0
- package/internal/errors.mjs.map +1 -0
- package/internal/headers.d.mts +26 -0
- package/internal/headers.d.mts.map +1 -0
- package/internal/headers.d.ts +26 -0
- package/internal/headers.d.ts.map +1 -0
- package/internal/headers.js +120 -0
- package/internal/headers.js.map +1 -0
- package/internal/headers.mjs +112 -0
- package/internal/headers.mjs.map +1 -0
- package/internal/parse.d.mts +12 -0
- package/internal/parse.d.mts.map +1 -0
- package/internal/parse.d.ts +12 -0
- package/internal/parse.d.ts.map +1 -0
- package/internal/parse.js +35 -0
- package/internal/parse.js.map +1 -0
- package/internal/parse.mjs +32 -0
- package/internal/parse.mjs.map +1 -0
- package/internal/qs/formats.d.mts +7 -0
- package/internal/qs/formats.d.mts.map +1 -0
- package/internal/qs/formats.d.ts +1 -0
- package/internal/qs/formats.d.ts.map +1 -1
- package/internal/qs/formats.js +4 -2
- package/internal/qs/formats.js.map +1 -1
- package/internal/qs/formats.mjs +2 -1
- package/internal/qs/formats.mjs.map +1 -1
- package/internal/qs/index.d.mts +10 -0
- package/internal/qs/index.d.mts.map +1 -0
- package/internal/qs/index.d.ts.map +1 -1
- package/internal/qs/stringify.d.mts +3 -0
- package/internal/qs/stringify.d.mts.map +1 -0
- package/internal/qs/stringify.d.ts.map +1 -1
- package/internal/qs/stringify.js +16 -19
- package/internal/qs/stringify.js.map +1 -1
- package/internal/qs/stringify.mjs +17 -19
- package/internal/qs/stringify.mjs.map +1 -1
- package/internal/qs/types.d.mts +57 -0
- package/internal/qs/types.d.mts.map +1 -0
- package/internal/qs/utils.d.mts +15 -0
- package/internal/qs/utils.d.mts.map +1 -0
- package/internal/qs/utils.d.ts +1 -0
- package/internal/qs/utils.d.ts.map +1 -1
- package/internal/qs/utils.js +22 -21
- package/internal/qs/utils.js.map +1 -1
- package/internal/qs/utils.mjs +12 -12
- package/internal/qs/utils.mjs.map +1 -1
- package/internal/request-options.d.mts +75 -0
- package/internal/request-options.d.mts.map +1 -0
- package/internal/request-options.d.ts +75 -0
- package/internal/request-options.d.ts.map +1 -0
- package/internal/request-options.js +14 -0
- package/internal/request-options.js.map +1 -0
- package/internal/request-options.mjs +10 -0
- package/internal/request-options.mjs.map +1 -0
- package/internal/shim-types.d.mts +17 -0
- package/internal/shim-types.d.mts.map +1 -0
- package/internal/shim-types.d.ts +17 -0
- package/internal/shim-types.d.ts.map +1 -0
- package/internal/shim-types.js +4 -0
- package/internal/shim-types.js.map +1 -0
- package/internal/shim-types.mjs +3 -0
- package/internal/shim-types.mjs.map +1 -0
- package/internal/shims.d.mts +20 -0
- package/internal/shims.d.mts.map +1 -0
- package/internal/shims.d.ts +20 -0
- package/internal/shims.d.ts.map +1 -0
- package/internal/shims.js +92 -0
- package/internal/shims.js.map +1 -0
- package/internal/shims.mjs +85 -0
- package/internal/shims.mjs.map +1 -0
- package/internal/to-file.d.mts +45 -0
- package/internal/to-file.d.mts.map +1 -0
- package/internal/to-file.d.ts +45 -0
- package/internal/to-file.d.ts.map +1 -0
- package/internal/to-file.js +91 -0
- package/internal/to-file.js.map +1 -0
- package/internal/to-file.mjs +88 -0
- package/internal/to-file.mjs.map +1 -0
- package/internal/tslib.js +81 -0
- package/internal/tslib.mjs +17 -0
- package/internal/types.d.mts +69 -0
- package/internal/types.d.mts.map +1 -0
- package/internal/types.d.ts +69 -0
- package/internal/types.d.ts.map +1 -0
- package/internal/types.js +4 -0
- package/internal/types.js.map +1 -0
- package/internal/types.mjs +3 -0
- package/internal/types.mjs.map +1 -0
- package/internal/uploads.d.mts +42 -0
- package/internal/uploads.d.mts.map +1 -0
- package/internal/uploads.d.ts +42 -0
- package/internal/uploads.d.ts.map +1 -0
- package/internal/uploads.js +141 -0
- package/internal/uploads.js.map +1 -0
- package/internal/uploads.mjs +131 -0
- package/internal/uploads.mjs.map +1 -0
- package/internal/utils/base64.d.mts +3 -0
- package/internal/utils/base64.d.mts.map +1 -0
- package/internal/utils/base64.d.ts +3 -0
- package/internal/utils/base64.d.ts.map +1 -0
- package/internal/utils/base64.js +38 -0
- package/internal/utils/base64.js.map +1 -0
- package/internal/utils/base64.mjs +33 -0
- package/internal/utils/base64.mjs.map +1 -0
- package/internal/utils/bytes.d.mts +4 -0
- package/internal/utils/bytes.d.mts.map +1 -0
- package/internal/utils/bytes.d.ts +4 -0
- package/internal/utils/bytes.d.ts.map +1 -0
- package/internal/utils/bytes.js +31 -0
- package/internal/utils/bytes.js.map +1 -0
- package/internal/utils/bytes.mjs +26 -0
- package/internal/utils/bytes.mjs.map +1 -0
- package/internal/utils/env.d.mts +9 -0
- package/internal/utils/env.d.mts.map +1 -0
- package/internal/utils/env.d.ts +9 -0
- package/internal/utils/env.d.ts.map +1 -0
- package/internal/utils/env.js +22 -0
- package/internal/utils/env.js.map +1 -0
- package/internal/utils/env.mjs +18 -0
- package/internal/utils/env.mjs.map +1 -0
- package/internal/utils/log.d.mts +37 -0
- package/internal/utils/log.d.mts.map +1 -0
- package/internal/utils/log.d.ts +37 -0
- package/internal/utils/log.d.ts.map +1 -0
- package/internal/utils/log.js +85 -0
- package/internal/utils/log.js.map +1 -0
- package/internal/utils/log.mjs +79 -0
- package/internal/utils/log.mjs.map +1 -0
- package/internal/utils/path.d.mts +15 -0
- package/internal/utils/path.d.mts.map +1 -0
- package/internal/utils/path.d.ts +15 -0
- package/internal/utils/path.d.ts.map +1 -0
- package/internal/utils/path.js +79 -0
- package/internal/utils/path.js.map +1 -0
- package/internal/utils/path.mjs +74 -0
- package/internal/utils/path.mjs.map +1 -0
- package/internal/utils/sleep.d.mts +2 -0
- package/internal/utils/sleep.d.mts.map +1 -0
- package/internal/utils/sleep.d.ts +2 -0
- package/internal/utils/sleep.d.ts.map +1 -0
- package/internal/utils/sleep.js +7 -0
- package/internal/utils/sleep.js.map +1 -0
- package/internal/utils/sleep.mjs +3 -0
- package/internal/utils/sleep.mjs.map +1 -0
- package/internal/utils/uuid.d.mts +5 -0
- package/internal/utils/uuid.d.mts.map +1 -0
- package/internal/utils/uuid.d.ts +5 -0
- package/internal/utils/uuid.d.ts.map +1 -0
- package/internal/utils/uuid.js +19 -0
- package/internal/utils/uuid.js.map +1 -0
- package/internal/utils/uuid.mjs +15 -0
- package/internal/utils/uuid.mjs.map +1 -0
- package/internal/utils/values.d.mts +18 -0
- package/internal/utils/values.d.mts.map +1 -0
- package/internal/utils/values.d.ts +18 -0
- package/internal/utils/values.d.ts.map +1 -0
- package/internal/utils/values.js +112 -0
- package/internal/utils/values.js.map +1 -0
- package/internal/utils/values.mjs +94 -0
- package/internal/utils/values.mjs.map +1 -0
- package/internal/utils.d.mts +7 -0
- package/internal/utils.d.mts.map +1 -0
- package/internal/utils.d.ts +7 -0
- package/internal/utils.d.ts.map +1 -0
- package/internal/utils.js +11 -0
- package/internal/utils.js.map +1 -0
- package/internal/utils.mjs +8 -0
- package/internal/utils.mjs.map +1 -0
- package/package.json +116 -67
- package/pagination.d.mts +2 -0
- package/pagination.d.mts.map +1 -0
- package/pagination.d.ts +1 -79
- package/pagination.d.ts.map +1 -1
- package/pagination.js +3 -123
- package/pagination.js.map +1 -1
- package/pagination.mjs +1 -118
- package/pagination.mjs.map +1 -1
- package/resource.d.mts +2 -0
- package/resource.d.mts.map +1 -0
- package/resource.d.ts +1 -5
- package/resource.d.ts.map +1 -1
- package/resource.js +3 -8
- package/resource.js.map +1 -1
- package/resource.mjs +1 -6
- package/resource.mjs.map +1 -1
- package/resources/access-tokens.d.mts +83 -0
- package/resources/access-tokens.d.mts.map +1 -0
- package/resources/access-tokens.d.ts +42 -33
- package/resources/access-tokens.d.ts.map +1 -1
- package/resources/access-tokens.js +2 -10
- package/resources/access-tokens.js.map +1 -1
- package/resources/access-tokens.mjs +2 -10
- package/resources/access-tokens.mjs.map +1 -1
- package/resources/account.d.mts +149 -0
- package/resources/account.d.mts.map +1 -0
- package/resources/account.d.ts +73 -49
- package/resources/account.d.ts.map +1 -1
- package/resources/account.js +1 -1
- package/resources/account.js.map +1 -1
- package/resources/account.mjs +1 -1
- package/resources/account.mjs.map +1 -1
- package/resources/connect/connect.d.mts +10 -0
- package/resources/connect/connect.d.mts.map +1 -0
- package/resources/connect/connect.d.ts +1 -1
- package/resources/connect/connect.d.ts.map +1 -1
- package/resources/connect/connect.js +3 -25
- package/resources/connect/connect.js.map +1 -1
- package/resources/connect/connect.mjs +1 -1
- package/resources/connect/index.d.mts +3 -0
- package/resources/connect/index.d.mts.map +1 -0
- package/resources/connect/index.d.ts.map +1 -1
- package/resources/connect/sessions.d.mts +110 -0
- package/resources/connect/sessions.d.mts.map +1 -0
- package/resources/connect/sessions.d.ts +44 -10
- package/resources/connect/sessions.d.ts.map +1 -1
- package/resources/connect/sessions.js +1 -1
- package/resources/connect/sessions.js.map +1 -1
- package/resources/connect/sessions.mjs +1 -1
- package/resources/connect/sessions.mjs.map +1 -1
- package/resources/connect.d.mts +2 -0
- package/resources/connect.d.mts.map +1 -0
- package/resources/connect.d.ts.map +1 -1
- package/resources/connect.js +2 -15
- package/resources/connect.js.map +1 -1
- package/resources/hris/benefits/benefits.d.mts +298 -0
- package/resources/hris/benefits/benefits.d.mts.map +1 -0
- package/resources/hris/benefits/benefits.d.ts +103 -115
- package/resources/hris/benefits/benefits.d.ts.map +1 -1
- package/resources/hris/benefits/benefits.js +45 -54
- package/resources/hris/benefits/benefits.js.map +1 -1
- package/resources/hris/benefits/benefits.mjs +43 -28
- package/resources/hris/benefits/benefits.mjs.map +1 -1
- package/resources/hris/benefits/index.d.mts +3 -0
- package/resources/hris/benefits/index.d.mts.map +1 -0
- package/resources/hris/benefits/index.d.ts +2 -2
- package/resources/hris/benefits/index.d.ts.map +1 -1
- package/resources/hris/benefits/index.js +1 -4
- package/resources/hris/benefits/index.js.map +1 -1
- package/resources/hris/benefits/index.mjs +2 -2
- package/resources/hris/benefits/index.mjs.map +1 -1
- package/resources/hris/benefits/individuals.d.mts +288 -0
- package/resources/hris/benefits/individuals.d.mts.map +1 -0
- package/resources/hris/benefits/individuals.d.ts +145 -27
- package/resources/hris/benefits/individuals.d.ts.map +1 -1
- package/resources/hris/benefits/individuals.js +61 -26
- package/resources/hris/benefits/individuals.js.map +1 -1
- package/resources/hris/benefits/individuals.mjs +60 -24
- package/resources/hris/benefits/individuals.mjs.map +1 -1
- package/resources/hris/benefits.d.mts +2 -0
- package/resources/hris/benefits.d.mts.map +1 -0
- package/resources/hris/benefits.d.ts.map +1 -1
- package/resources/hris/benefits.js +2 -15
- package/resources/hris/benefits.js.map +1 -1
- package/resources/hris/company/company.d.mts +124 -0
- package/resources/hris/company/company.d.mts.map +1 -0
- package/resources/hris/company/company.d.ts +12 -5
- package/resources/hris/company/company.d.ts.map +1 -1
- package/resources/hris/company/company.js +5 -28
- package/resources/hris/company/company.js.map +1 -1
- package/resources/hris/company/company.mjs +4 -5
- package/resources/hris/company/company.mjs.map +1 -1
- package/resources/hris/company/index.d.mts +3 -0
- package/resources/hris/company/index.d.mts.map +1 -0
- package/resources/hris/company/index.d.ts +2 -2
- package/resources/hris/company/index.d.ts.map +1 -1
- package/resources/hris/company/index.js +1 -2
- package/resources/hris/company/index.js.map +1 -1
- package/resources/hris/company/index.mjs +1 -1
- package/resources/hris/company/index.mjs.map +1 -1
- package/resources/hris/company/pay-statement-item/index.d.mts +3 -0
- package/resources/hris/company/pay-statement-item/index.d.mts.map +1 -0
- package/resources/hris/company/pay-statement-item/index.d.ts +2 -2
- package/resources/hris/company/pay-statement-item/index.d.ts.map +1 -1
- package/resources/hris/company/pay-statement-item/index.js +1 -3
- package/resources/hris/company/pay-statement-item/index.js.map +1 -1
- package/resources/hris/company/pay-statement-item/index.mjs +2 -2
- package/resources/hris/company/pay-statement-item/index.mjs.map +1 -1
- package/resources/hris/company/pay-statement-item/pay-statement-item.d.mts +99 -0
- package/resources/hris/company/pay-statement-item/pay-statement-item.d.mts.map +1 -0
- package/resources/hris/company/pay-statement-item/pay-statement-item.d.ts +22 -18
- package/resources/hris/company/pay-statement-item/pay-statement-item.d.ts.map +1 -1
- package/resources/hris/company/pay-statement-item/pay-statement-item.js +19 -40
- package/resources/hris/company/pay-statement-item/pay-statement-item.js.map +1 -1
- package/resources/hris/company/pay-statement-item/pay-statement-item.mjs +17 -15
- package/resources/hris/company/pay-statement-item/pay-statement-item.mjs.map +1 -1
- package/resources/hris/company/pay-statement-item/rules.d.mts +398 -0
- package/resources/hris/company/pay-statement-item/rules.d.mts.map +1 -0
- package/resources/hris/company/pay-statement-item/rules.d.ts +56 -21
- package/resources/hris/company/pay-statement-item/rules.d.ts.map +1 -1
- package/resources/hris/company/pay-statement-item/rules.js +55 -22
- package/resources/hris/company/pay-statement-item/rules.js.map +1 -1
- package/resources/hris/company/pay-statement-item/rules.mjs +54 -20
- package/resources/hris/company/pay-statement-item/rules.mjs.map +1 -1
- package/resources/hris/company/pay-statement-item.d.mts +2 -0
- package/resources/hris/company/pay-statement-item.d.mts.map +1 -0
- package/resources/hris/company/pay-statement-item.d.ts.map +1 -1
- package/resources/hris/company/pay-statement-item.js +2 -15
- package/resources/hris/company/pay-statement-item.js.map +1 -1
- package/resources/hris/company.d.mts +2 -0
- package/resources/hris/company.d.mts.map +1 -0
- package/resources/hris/company.d.ts.map +1 -1
- package/resources/hris/company.js +2 -15
- package/resources/hris/company.js.map +1 -1
- package/resources/hris/directory.d.mts +87 -0
- package/resources/hris/directory.d.mts.map +1 -0
- package/resources/hris/directory.d.ts +13 -9
- package/resources/hris/directory.d.ts.map +1 -1
- package/resources/hris/directory.js +17 -7
- package/resources/hris/directory.js.map +1 -1
- package/resources/hris/directory.mjs +17 -7
- package/resources/hris/directory.mjs.map +1 -1
- package/resources/hris/documents.d.mts +198 -0
- package/resources/hris/documents.d.mts.map +1 -0
- package/resources/hris/documents.d.ts +40 -30
- package/resources/hris/documents.d.ts.map +1 -1
- package/resources/hris/documents.js +13 -7
- package/resources/hris/documents.js.map +1 -1
- package/resources/hris/documents.mjs +13 -7
- package/resources/hris/documents.mjs.map +1 -1
- package/resources/hris/employments.d.mts +175 -0
- package/resources/hris/employments.d.mts.map +1 -0
- package/resources/hris/employments.d.ts +23 -20
- package/resources/hris/employments.d.ts.map +1 -1
- package/resources/hris/employments.js +7 -9
- package/resources/hris/employments.js.map +1 -1
- package/resources/hris/employments.mjs +6 -7
- package/resources/hris/employments.mjs.map +1 -1
- package/resources/hris/hris.d.mts +98 -0
- package/resources/hris/hris.d.mts.map +1 -0
- package/resources/hris/hris.d.ts +14 -14
- package/resources/hris/hris.d.ts.map +1 -1
- package/resources/hris/hris.js +10 -38
- package/resources/hris/hris.js.map +1 -1
- package/resources/hris/hris.mjs +6 -12
- package/resources/hris/hris.mjs.map +1 -1
- package/resources/hris/index.d.mts +10 -0
- package/resources/hris/index.d.mts.map +1 -0
- package/resources/hris/index.d.ts +7 -7
- package/resources/hris/index.d.ts.map +1 -1
- package/resources/hris/index.js +1 -7
- package/resources/hris/index.js.map +1 -1
- package/resources/hris/index.mjs +5 -5
- package/resources/hris/index.mjs.map +1 -1
- package/resources/hris/individuals.d.mts +116 -0
- package/resources/hris/individuals.d.mts.map +1 -0
- package/resources/hris/individuals.d.ts +16 -8
- package/resources/hris/individuals.d.ts.map +1 -1
- package/resources/hris/individuals.js +18 -13
- package/resources/hris/individuals.js.map +1 -1
- package/resources/hris/individuals.mjs +17 -11
- package/resources/hris/individuals.mjs.map +1 -1
- package/resources/hris/pay-statements.d.mts +268 -0
- package/resources/hris/pay-statements.d.mts.map +1 -0
- package/resources/hris/pay-statements.d.ts +113 -100
- package/resources/hris/pay-statements.d.ts.map +1 -1
- package/resources/hris/pay-statements.js +7 -9
- package/resources/hris/pay-statements.js.map +1 -1
- package/resources/hris/pay-statements.mjs +6 -7
- package/resources/hris/pay-statements.mjs.map +1 -1
- package/resources/hris/payments.d.mts +80 -0
- package/resources/hris/payments.d.mts.map +1 -0
- package/resources/hris/payments.d.ts +24 -21
- package/resources/hris/payments.d.ts.map +1 -1
- package/resources/hris/payments.js +4 -8
- package/resources/hris/payments.js.map +1 -1
- package/resources/hris/payments.mjs +3 -6
- package/resources/hris/payments.mjs.map +1 -1
- package/resources/hris.d.mts +2 -0
- package/resources/hris.d.mts.map +1 -0
- package/resources/hris.d.ts.map +1 -1
- package/resources/hris.js +2 -15
- package/resources/hris.js.map +1 -1
- package/resources/index.d.mts +12 -0
- package/resources/index.d.mts.map +1 -0
- package/resources/index.d.ts +1 -1
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +3 -17
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +1 -1
- package/resources/index.mjs.map +1 -1
- package/resources/jobs/automated.d.mts +174 -0
- package/resources/jobs/automated.d.mts.map +1 -0
- package/resources/jobs/automated.d.ts +15 -11
- package/resources/jobs/automated.d.ts.map +1 -1
- package/resources/jobs/automated.js +9 -7
- package/resources/jobs/automated.js.map +1 -1
- package/resources/jobs/automated.mjs +9 -7
- package/resources/jobs/automated.mjs.map +1 -1
- package/resources/jobs/index.d.mts +4 -0
- package/resources/jobs/index.d.mts.map +1 -0
- package/resources/jobs/index.d.ts.map +1 -1
- package/resources/jobs/jobs.d.mts +14 -0
- package/resources/jobs/jobs.d.mts.map +1 -0
- package/resources/jobs/jobs.d.ts +1 -1
- package/resources/jobs/jobs.d.ts.map +1 -1
- package/resources/jobs/jobs.js +4 -26
- package/resources/jobs/jobs.js.map +1 -1
- package/resources/jobs/jobs.mjs +1 -1
- package/resources/jobs/manual.d.mts +22 -0
- package/resources/jobs/manual.d.mts.map +1 -0
- package/resources/jobs/manual.d.ts +4 -3
- package/resources/jobs/manual.d.ts.map +1 -1
- package/resources/jobs/manual.js +4 -3
- package/resources/jobs/manual.js.map +1 -1
- package/resources/jobs/manual.mjs +4 -3
- package/resources/jobs/manual.mjs.map +1 -1
- package/resources/jobs.d.mts +2 -0
- package/resources/jobs.d.mts.map +1 -0
- package/resources/jobs.d.ts.map +1 -1
- package/resources/jobs.js +2 -15
- package/resources/jobs.js.map +1 -1
- package/resources/payroll/index.d.mts +3 -0
- package/resources/payroll/index.d.mts.map +1 -0
- package/resources/payroll/index.d.ts +1 -1
- package/resources/payroll/index.d.ts.map +1 -1
- package/resources/payroll/index.js +1 -2
- package/resources/payroll/index.js.map +1 -1
- package/resources/payroll/index.mjs +1 -1
- package/resources/payroll/index.mjs.map +1 -1
- package/resources/payroll/pay-groups.d.mts +62 -0
- package/resources/payroll/pay-groups.d.mts.map +1 -0
- package/resources/payroll/pay-groups.d.ts +22 -13
- package/resources/payroll/pay-groups.d.ts.map +1 -1
- package/resources/payroll/pay-groups.js +10 -14
- package/resources/payroll/pay-groups.js.map +1 -1
- package/resources/payroll/pay-groups.mjs +9 -12
- package/resources/payroll/pay-groups.mjs.map +1 -1
- package/resources/payroll/payroll.d.mts +10 -0
- package/resources/payroll/payroll.d.mts.map +1 -0
- package/resources/payroll/payroll.d.ts +3 -3
- package/resources/payroll/payroll.d.ts.map +1 -1
- package/resources/payroll/payroll.js +3 -26
- package/resources/payroll/payroll.js.map +1 -1
- package/resources/payroll/payroll.mjs +2 -3
- package/resources/payroll/payroll.mjs.map +1 -1
- package/resources/payroll.d.mts +2 -0
- package/resources/payroll.d.mts.map +1 -0
- package/resources/payroll.d.ts.map +1 -1
- package/resources/payroll.js +2 -15
- package/resources/payroll.js.map +1 -1
- package/resources/providers.d.mts +142 -0
- package/resources/providers.d.mts.map +1 -0
- package/resources/providers.d.ts +90 -258
- package/resources/providers.d.ts.map +1 -1
- package/resources/providers.js +4 -8
- package/resources/providers.js.map +1 -1
- package/resources/providers.mjs +3 -6
- package/resources/providers.mjs.map +1 -1
- package/resources/request-forwarding.d.mts +109 -0
- package/resources/request-forwarding.d.mts.map +1 -0
- package/resources/request-forwarding.d.ts +48 -49
- package/resources/request-forwarding.d.ts.map +1 -1
- package/resources/request-forwarding.js +3 -13
- package/resources/request-forwarding.js.map +1 -1
- package/resources/request-forwarding.mjs +3 -13
- package/resources/request-forwarding.mjs.map +1 -1
- package/resources/sandbox/company.d.mts +219 -0
- package/resources/sandbox/company.d.mts.map +1 -0
- package/resources/sandbox/company.d.ts +4 -3
- package/resources/sandbox/company.d.ts.map +1 -1
- package/resources/sandbox/company.js +1 -1
- package/resources/sandbox/company.js.map +1 -1
- package/resources/sandbox/company.mjs +1 -1
- package/resources/sandbox/company.mjs.map +1 -1
- package/resources/sandbox/connections/accounts.d.mts +97 -0
- package/resources/sandbox/connections/accounts.d.mts.map +1 -0
- package/resources/sandbox/connections/accounts.d.ts +5 -5
- package/resources/sandbox/connections/accounts.d.ts.map +1 -1
- package/resources/sandbox/connections/accounts.js +13 -5
- package/resources/sandbox/connections/accounts.js.map +1 -1
- package/resources/sandbox/connections/accounts.mjs +13 -5
- package/resources/sandbox/connections/accounts.mjs.map +1 -1
- package/resources/sandbox/connections/connections.d.mts +62 -0
- package/resources/sandbox/connections/connections.d.mts.map +1 -0
- package/resources/sandbox/connections/connections.d.ts +4 -3
- package/resources/sandbox/connections/connections.d.ts.map +1 -1
- package/resources/sandbox/connections/connections.js +3 -25
- package/resources/sandbox/connections/connections.js.map +1 -1
- package/resources/sandbox/connections/connections.mjs +1 -1
- package/resources/sandbox/connections/connections.mjs.map +1 -1
- package/resources/sandbox/connections/index.d.mts +3 -0
- package/resources/sandbox/connections/index.d.mts.map +1 -0
- package/resources/sandbox/connections/index.d.ts.map +1 -1
- package/resources/sandbox/connections.d.mts +2 -0
- package/resources/sandbox/connections.d.mts.map +1 -0
- package/resources/sandbox/connections.d.ts.map +1 -1
- package/resources/sandbox/connections.js +2 -15
- package/resources/sandbox/connections.js.map +1 -1
- package/resources/sandbox/directory.d.mts +174 -0
- package/resources/sandbox/directory.d.mts.map +1 -0
- package/resources/sandbox/directory.d.ts +12 -8
- package/resources/sandbox/directory.d.ts.map +1 -1
- package/resources/sandbox/directory.js +12 -7
- package/resources/sandbox/directory.js.map +1 -1
- package/resources/sandbox/directory.mjs +12 -7
- package/resources/sandbox/directory.mjs.map +1 -1
- package/resources/sandbox/employment.d.mts +235 -0
- package/resources/sandbox/employment.d.mts.map +1 -0
- package/resources/sandbox/employment.d.ts +4 -4
- package/resources/sandbox/employment.d.ts.map +1 -1
- package/resources/sandbox/employment.js +14 -7
- package/resources/sandbox/employment.js.map +1 -1
- package/resources/sandbox/employment.mjs +14 -7
- package/resources/sandbox/employment.mjs.map +1 -1
- package/resources/sandbox/index.d.mts +9 -0
- package/resources/sandbox/index.d.mts.map +1 -0
- package/resources/sandbox/index.d.ts.map +1 -1
- package/resources/sandbox/individual.d.mts +131 -0
- package/resources/sandbox/individual.d.mts.map +1 -0
- package/resources/sandbox/individual.d.ts +4 -4
- package/resources/sandbox/individual.d.ts.map +1 -1
- package/resources/sandbox/individual.js +14 -7
- package/resources/sandbox/individual.js.map +1 -1
- package/resources/sandbox/individual.mjs +14 -7
- package/resources/sandbox/individual.mjs.map +1 -1
- package/resources/sandbox/jobs/configuration.d.mts +41 -0
- package/resources/sandbox/jobs/configuration.d.mts.map +1 -0
- package/resources/sandbox/jobs/configuration.d.ts +5 -4
- package/resources/sandbox/jobs/configuration.d.ts.map +1 -1
- package/resources/sandbox/jobs/configuration.js +1 -1
- package/resources/sandbox/jobs/configuration.js.map +1 -1
- package/resources/sandbox/jobs/configuration.mjs +1 -1
- package/resources/sandbox/jobs/configuration.mjs.map +1 -1
- package/resources/sandbox/jobs/index.d.mts +3 -0
- package/resources/sandbox/jobs/index.d.mts.map +1 -0
- package/resources/sandbox/jobs/index.d.ts.map +1 -1
- package/resources/sandbox/jobs/jobs.d.mts +48 -0
- package/resources/sandbox/jobs/jobs.d.mts.map +1 -0
- package/resources/sandbox/jobs/jobs.d.ts +4 -3
- package/resources/sandbox/jobs/jobs.d.ts.map +1 -1
- package/resources/sandbox/jobs/jobs.js +3 -25
- package/resources/sandbox/jobs/jobs.js.map +1 -1
- package/resources/sandbox/jobs/jobs.mjs +1 -1
- package/resources/sandbox/jobs/jobs.mjs.map +1 -1
- package/resources/sandbox/jobs.d.mts +2 -0
- package/resources/sandbox/jobs.d.mts.map +1 -0
- package/resources/sandbox/jobs.d.ts.map +1 -1
- package/resources/sandbox/jobs.js +2 -15
- package/resources/sandbox/jobs.js.map +1 -1
- package/resources/sandbox/payment.d.mts +81 -0
- package/resources/sandbox/payment.d.mts.map +1 -0
- package/resources/sandbox/payment.d.ts +34 -188
- package/resources/sandbox/payment.d.ts.map +1 -1
- package/resources/sandbox/payment.js +9 -5
- package/resources/sandbox/payment.js.map +1 -1
- package/resources/sandbox/payment.mjs +9 -5
- package/resources/sandbox/payment.mjs.map +1 -1
- package/resources/sandbox/sandbox.d.mts +34 -0
- package/resources/sandbox/sandbox.d.mts.map +1 -0
- package/resources/sandbox/sandbox.d.ts +1 -1
- package/resources/sandbox/sandbox.d.ts.map +1 -1
- package/resources/sandbox/sandbox.js +9 -31
- package/resources/sandbox/sandbox.js.map +1 -1
- package/resources/sandbox/sandbox.mjs +1 -1
- package/resources/sandbox.d.mts +2 -0
- package/resources/sandbox.d.mts.map +1 -0
- package/resources/sandbox.d.ts.map +1 -1
- package/resources/sandbox.js +2 -15
- package/resources/sandbox.js.map +1 -1
- package/resources/shared.d.mts +64 -0
- package/resources/shared.d.mts.map +1 -0
- package/resources/top-level.d.mts +2 -0
- package/resources/top-level.d.mts.map +1 -0
- package/resources/webhooks.d.mts +396 -0
- package/resources/webhooks.d.mts.map +1 -0
- package/resources/webhooks.d.ts +5 -3
- package/resources/webhooks.d.ts.map +1 -1
- package/resources/webhooks.js +9 -8
- package/resources/webhooks.js.map +1 -1
- package/resources/webhooks.mjs +3 -2
- package/resources/webhooks.mjs.map +1 -1
- package/resources.d.mts +2 -0
- package/resources.d.mts.map +1 -0
- package/resources.d.ts.map +1 -1
- package/resources.js +2 -15
- package/resources.js.map +1 -1
- package/src/api-promise.ts +2 -0
- package/src/client.ts +967 -0
- package/src/core/README.md +3 -0
- package/src/core/api-promise.ts +92 -0
- package/src/core/error.ts +130 -0
- package/src/core/pagination.ts +292 -0
- package/src/core/resource.ts +11 -0
- package/src/core/uploads.ts +2 -0
- package/src/error.ts +2 -130
- package/src/index.ts +6 -432
- package/src/internal/README.md +3 -0
- package/src/internal/builtin-types.ts +93 -0
- package/src/internal/detect-platform.ts +196 -0
- package/src/internal/errors.ts +33 -0
- package/src/internal/headers.ts +144 -0
- package/src/internal/parse.ts +50 -0
- package/src/internal/qs/formats.ts +3 -2
- package/src/internal/qs/index.ts +3 -3
- package/src/internal/qs/stringify.ts +18 -21
- package/src/internal/qs/utils.ts +16 -16
- package/src/internal/request-options.ts +91 -0
- package/src/internal/shim-types.ts +26 -0
- package/src/internal/shims.ts +107 -0
- package/src/internal/to-file.ts +154 -0
- package/src/internal/types.ts +95 -0
- package/src/internal/uploads.ts +187 -0
- package/src/internal/utils/base64.ts +40 -0
- package/src/internal/utils/bytes.ts +32 -0
- package/src/internal/utils/env.ts +18 -0
- package/src/internal/utils/log.ts +126 -0
- package/src/internal/utils/path.ts +88 -0
- package/src/internal/utils/sleep.ts +3 -0
- package/src/internal/utils/uuid.ts +17 -0
- package/src/internal/utils/values.ts +105 -0
- package/src/internal/utils.ts +8 -0
- package/src/pagination.ts +2 -221
- package/src/resource.ts +2 -11
- package/src/resources/access-tokens.ts +46 -39
- package/src/resources/account.ts +86 -57
- package/src/resources/connect/connect.ts +3 -3
- package/src/resources/connect/index.ts +2 -2
- package/src/resources/connect/sessions.ts +52 -18
- package/src/resources/connect.ts +1 -1
- package/src/resources/hris/benefits/benefits.ts +163 -173
- package/src/resources/hris/benefits/index.ts +9 -6
- package/src/resources/hris/benefits/individuals.ts +202 -79
- package/src/resources/hris/benefits.ts +1 -1
- package/src/resources/hris/company/company.ts +20 -10
- package/src/resources/hris/company/index.ts +3 -3
- package/src/resources/hris/company/pay-statement-item/index.ts +6 -4
- package/src/resources/hris/company/pay-statement-item/pay-statement-item.ts +34 -37
- package/src/resources/hris/company/pay-statement-item/rules.ts +85 -43
- package/src/resources/hris/company/pay-statement-item.ts +1 -1
- package/src/resources/hris/company.ts +1 -1
- package/src/resources/hris/directory.ts +22 -18
- package/src/resources/hris/documents.ts +51 -38
- package/src/resources/hris/employments.ts +33 -28
- package/src/resources/hris/hris.ts +41 -35
- package/src/resources/hris/index.ts +19 -15
- package/src/resources/hris/individuals.ts +23 -21
- package/src/resources/hris/pay-statements.ts +130 -116
- package/src/resources/hris/payments.ts +32 -32
- package/src/resources/hris.ts +1 -1
- package/src/resources/index.ts +16 -11
- package/src/resources/jobs/automated.ts +20 -22
- package/src/resources/jobs/index.ts +3 -3
- package/src/resources/jobs/jobs.ts +5 -5
- package/src/resources/jobs/manual.ts +6 -4
- package/src/resources/jobs.ts +1 -1
- package/src/resources/payroll/index.ts +4 -3
- package/src/resources/payroll/pay-groups.ts +43 -37
- package/src/resources/payroll/payroll.ts +6 -5
- package/src/resources/payroll.ts +1 -1
- package/src/resources/providers.ts +91 -397
- package/src/resources/request-forwarding.ts +38 -51
- package/src/resources/sandbox/company.ts +5 -4
- package/src/resources/sandbox/connections/accounts.ts +8 -13
- package/src/resources/sandbox/connections/connections.ts +6 -8
- package/src/resources/sandbox/connections/index.ts +2 -2
- package/src/resources/sandbox/connections.ts +1 -1
- package/src/resources/sandbox/directory.ts +17 -20
- package/src/resources/sandbox/employment.ts +10 -18
- package/src/resources/sandbox/index.ts +8 -8
- package/src/resources/sandbox/individual.ts +10 -18
- package/src/resources/sandbox/jobs/configuration.ts +5 -7
- package/src/resources/sandbox/jobs/index.ts +2 -2
- package/src/resources/sandbox/jobs/jobs.ts +6 -5
- package/src/resources/sandbox/jobs.ts +1 -1
- package/src/resources/sandbox/payment.ts +82 -220
- package/src/resources/sandbox/sandbox.ts +15 -15
- package/src/resources/sandbox.ts +1 -1
- package/src/resources/webhooks.ts +7 -5
- package/src/resources.ts +1 -1
- package/src/tsconfig.json +2 -2
- package/src/uploads.ts +2 -255
- package/src/version.ts +1 -1
- package/uploads.d.mts +2 -0
- package/uploads.d.mts.map +1 -0
- package/uploads.d.ts +1 -74
- package/uploads.d.ts.map +1 -1
- package/uploads.js +3 -168
- package/uploads.js.map +1 -1
- package/uploads.mjs +1 -157
- package/uploads.mjs.map +1 -1
- package/version.d.mts +2 -0
- package/version.d.mts.map +1 -0
- package/version.d.ts +1 -1
- package/version.d.ts.map +1 -1
- package/version.js +1 -1
- package/version.js.map +1 -1
- package/version.mjs +1 -1
- package/version.mjs.map +1 -1
- package/_shims/MultipartBody.d.ts +0 -9
- package/_shims/MultipartBody.d.ts.map +0 -1
- package/_shims/MultipartBody.js +0 -16
- package/_shims/MultipartBody.js.map +0 -1
- package/_shims/MultipartBody.mjs +0 -12
- package/_shims/MultipartBody.mjs.map +0 -1
- package/_shims/README.md +0 -46
- package/_shims/auto/runtime-bun.d.ts +0 -5
- package/_shims/auto/runtime-bun.d.ts.map +0 -1
- package/_shims/auto/runtime-bun.js +0 -21
- package/_shims/auto/runtime-bun.js.map +0 -1
- package/_shims/auto/runtime-bun.mjs +0 -2
- package/_shims/auto/runtime-bun.mjs.map +0 -1
- package/_shims/auto/runtime-node.d.ts +0 -5
- package/_shims/auto/runtime-node.d.ts.map +0 -1
- package/_shims/auto/runtime-node.js +0 -21
- package/_shims/auto/runtime-node.js.map +0 -1
- package/_shims/auto/runtime-node.mjs +0 -2
- package/_shims/auto/runtime-node.mjs.map +0 -1
- package/_shims/auto/runtime.d.ts +0 -5
- package/_shims/auto/runtime.d.ts.map +0 -1
- package/_shims/auto/runtime.js +0 -21
- package/_shims/auto/runtime.js.map +0 -1
- package/_shims/auto/runtime.mjs +0 -2
- package/_shims/auto/runtime.mjs.map +0 -1
- package/_shims/auto/types-node.d.ts +0 -5
- package/_shims/auto/types-node.d.ts.map +0 -1
- package/_shims/auto/types-node.js +0 -21
- package/_shims/auto/types-node.js.map +0 -1
- package/_shims/auto/types-node.mjs +0 -2
- package/_shims/auto/types-node.mjs.map +0 -1
- package/_shims/auto/types.d.ts +0 -101
- package/_shims/auto/types.js +0 -3
- package/_shims/auto/types.mjs +0 -3
- package/_shims/bun-runtime.d.ts +0 -6
- package/_shims/bun-runtime.d.ts.map +0 -1
- package/_shims/bun-runtime.js +0 -14
- package/_shims/bun-runtime.js.map +0 -1
- package/_shims/bun-runtime.mjs +0 -10
- package/_shims/bun-runtime.mjs.map +0 -1
- package/_shims/index.d.ts +0 -83
- package/_shims/index.js +0 -17
- package/_shims/index.mjs +0 -11
- package/_shims/manual-types.d.ts +0 -12
- package/_shims/manual-types.js +0 -3
- package/_shims/manual-types.mjs +0 -3
- package/_shims/node-runtime.d.ts +0 -3
- package/_shims/node-runtime.d.ts.map +0 -1
- package/_shims/node-runtime.js +0 -89
- package/_shims/node-runtime.js.map +0 -1
- package/_shims/node-runtime.mjs +0 -56
- package/_shims/node-runtime.mjs.map +0 -1
- package/_shims/node-types.d.ts +0 -42
- package/_shims/node-types.js +0 -3
- package/_shims/node-types.mjs +0 -3
- package/_shims/registry.d.ts +0 -37
- package/_shims/registry.d.ts.map +0 -1
- package/_shims/registry.js +0 -41
- package/_shims/registry.js.map +0 -1
- package/_shims/registry.mjs +0 -37
- package/_shims/registry.mjs.map +0 -1
- package/_shims/web-runtime.d.ts +0 -5
- package/_shims/web-runtime.d.ts.map +0 -1
- package/_shims/web-runtime.js +0 -78
- package/_shims/web-runtime.js.map +0 -1
- package/_shims/web-runtime.mjs +0 -71
- package/_shims/web-runtime.mjs.map +0 -1
- package/_shims/web-types.d.ts +0 -83
- package/_shims/web-types.js +0 -3
- package/_shims/web-types.mjs +0 -3
- package/core.d.ts +0 -253
- package/core.d.ts.map +0 -1
- package/core.js +0 -932
- package/core.js.map +0 -1
- package/core.mjs +0 -899
- package/core.mjs.map +0 -1
- package/shims/node.d.ts +0 -30
- package/shims/node.d.ts.map +0 -1
- package/shims/node.js +0 -31
- package/shims/node.js.map +0 -1
- package/shims/node.mjs +0 -5
- package/shims/node.mjs.map +0 -1
- package/shims/web.d.ts +0 -26
- package/shims/web.d.ts.map +0 -1
- package/shims/web.js +0 -31
- package/shims/web.js.map +0 -1
- package/shims/web.mjs +0 -5
- package/shims/web.mjs.map +0 -1
- package/src/_shims/MultipartBody.ts +0 -9
- package/src/_shims/README.md +0 -46
- package/src/_shims/auto/runtime-bun.ts +0 -4
- package/src/_shims/auto/runtime-node.ts +0 -4
- package/src/_shims/auto/runtime.ts +0 -4
- package/src/_shims/auto/types-node.ts +0 -4
- package/src/_shims/auto/types.d.ts +0 -101
- package/src/_shims/auto/types.js +0 -3
- package/src/_shims/auto/types.mjs +0 -3
- package/src/_shims/bun-runtime.ts +0 -14
- package/src/_shims/index.d.ts +0 -83
- package/src/_shims/index.js +0 -17
- package/src/_shims/index.mjs +0 -11
- package/src/_shims/manual-types.d.ts +0 -12
- package/src/_shims/manual-types.js +0 -3
- package/src/_shims/manual-types.mjs +0 -3
- package/src/_shims/node-runtime.ts +0 -81
- package/src/_shims/node-types.d.ts +0 -42
- package/src/_shims/node-types.js +0 -3
- package/src/_shims/node-types.mjs +0 -3
- package/src/_shims/registry.ts +0 -67
- package/src/_shims/web-runtime.ts +0 -103
- package/src/_shims/web-types.d.ts +0 -83
- package/src/_shims/web-types.js +0 -3
- package/src/_shims/web-types.mjs +0 -3
- package/src/core.ts +0 -1248
- package/src/shims/node.ts +0 -50
- package/src/shims/web.ts +0 -50
package/pagination.js
CHANGED
|
@@ -1,126 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
constructor(client, response, body, options) {
|
|
8
|
-
super(client, response, body, options);
|
|
9
|
-
this.items = body || [];
|
|
10
|
-
}
|
|
11
|
-
getPaginatedItems() {
|
|
12
|
-
return this.items ?? [];
|
|
13
|
-
}
|
|
14
|
-
// @deprecated Please use `nextPageInfo()` instead
|
|
15
|
-
/**
|
|
16
|
-
* This page represents a response that isn't actually paginated at the API level
|
|
17
|
-
* so there will never be any next page params.
|
|
18
|
-
*/
|
|
19
|
-
nextPageParams() {
|
|
20
|
-
return null;
|
|
21
|
-
}
|
|
22
|
-
nextPageInfo() {
|
|
23
|
-
return null;
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
exports.SinglePage = SinglePage;
|
|
27
|
-
class ResponsesPage extends core_1.AbstractPage {
|
|
28
|
-
constructor(client, response, body, options) {
|
|
29
|
-
super(client, response, body, options);
|
|
30
|
-
this.responses = body.responses || [];
|
|
31
|
-
}
|
|
32
|
-
getPaginatedItems() {
|
|
33
|
-
return this.responses ?? [];
|
|
34
|
-
}
|
|
35
|
-
// @deprecated Please use `nextPageInfo()` instead
|
|
36
|
-
/**
|
|
37
|
-
* This page represents a response that isn't actually paginated at the API level
|
|
38
|
-
* so there will never be any next page params.
|
|
39
|
-
*/
|
|
40
|
-
nextPageParams() {
|
|
41
|
-
return null;
|
|
42
|
-
}
|
|
43
|
-
nextPageInfo() {
|
|
44
|
-
return null;
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
exports.ResponsesPage = ResponsesPage;
|
|
48
|
-
class IndividualsPage extends core_1.AbstractPage {
|
|
49
|
-
constructor(client, response, body, options) {
|
|
50
|
-
super(client, response, body, options);
|
|
51
|
-
this.individuals = body.individuals || [];
|
|
52
|
-
this.paging = body.paging;
|
|
53
|
-
}
|
|
54
|
-
getPaginatedItems() {
|
|
55
|
-
return this.individuals ?? [];
|
|
56
|
-
}
|
|
57
|
-
// @deprecated Please use `nextPageInfo()` instead
|
|
58
|
-
nextPageParams() {
|
|
59
|
-
const info = this.nextPageInfo();
|
|
60
|
-
if (!info)
|
|
61
|
-
return null;
|
|
62
|
-
if ('params' in info)
|
|
63
|
-
return info.params;
|
|
64
|
-
const params = Object.fromEntries(info.url.searchParams);
|
|
65
|
-
if (!Object.keys(params).length)
|
|
66
|
-
return null;
|
|
67
|
-
return params;
|
|
68
|
-
}
|
|
69
|
-
nextPageInfo() {
|
|
70
|
-
const offset = this.paging.offset;
|
|
71
|
-
if (!offset) {
|
|
72
|
-
return null;
|
|
73
|
-
}
|
|
74
|
-
const length = this.getPaginatedItems().length;
|
|
75
|
-
const currentCount = offset + length;
|
|
76
|
-
const totalCount = this.paging.count;
|
|
77
|
-
if (!totalCount) {
|
|
78
|
-
return null;
|
|
79
|
-
}
|
|
80
|
-
if (currentCount < totalCount) {
|
|
81
|
-
return { params: { offset: currentCount } };
|
|
82
|
-
}
|
|
83
|
-
return null;
|
|
84
|
-
}
|
|
85
|
-
}
|
|
86
|
-
exports.IndividualsPage = IndividualsPage;
|
|
87
|
-
class Page extends core_1.AbstractPage {
|
|
88
|
-
constructor(client, response, body, options) {
|
|
89
|
-
super(client, response, body, options);
|
|
90
|
-
this.data = body.data || [];
|
|
91
|
-
this.paging = body.paging;
|
|
92
|
-
}
|
|
93
|
-
getPaginatedItems() {
|
|
94
|
-
return this.data ?? [];
|
|
95
|
-
}
|
|
96
|
-
// @deprecated Please use `nextPageInfo()` instead
|
|
97
|
-
nextPageParams() {
|
|
98
|
-
const info = this.nextPageInfo();
|
|
99
|
-
if (!info)
|
|
100
|
-
return null;
|
|
101
|
-
if ('params' in info)
|
|
102
|
-
return info.params;
|
|
103
|
-
const params = Object.fromEntries(info.url.searchParams);
|
|
104
|
-
if (!Object.keys(params).length)
|
|
105
|
-
return null;
|
|
106
|
-
return params;
|
|
107
|
-
}
|
|
108
|
-
nextPageInfo() {
|
|
109
|
-
const offset = this.paging.offset;
|
|
110
|
-
if (!offset) {
|
|
111
|
-
return null;
|
|
112
|
-
}
|
|
113
|
-
const length = this.getPaginatedItems().length;
|
|
114
|
-
const currentCount = offset + length;
|
|
115
|
-
const totalCount = this.paging.count;
|
|
116
|
-
if (!totalCount) {
|
|
117
|
-
return null;
|
|
118
|
-
}
|
|
119
|
-
if (currentCount < totalCount) {
|
|
120
|
-
return { params: { offset: currentCount } };
|
|
121
|
-
}
|
|
122
|
-
return null;
|
|
123
|
-
}
|
|
124
|
-
}
|
|
125
|
-
exports.Page = Page;
|
|
3
|
+
const tslib_1 = require("./internal/tslib.js");
|
|
4
|
+
/** @deprecated Import from ./core/pagination instead */
|
|
5
|
+
tslib_1.__exportStar(require("./core/pagination.js"), exports);
|
|
126
6
|
//# sourceMappingURL=pagination.js.map
|
package/pagination.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pagination.js","sourceRoot":"","sources":["src/pagination.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"pagination.js","sourceRoot":"","sources":["src/pagination.ts"],"names":[],"mappings":";;;AAAA,wDAAwD;AACxD,+DAAkC"}
|
package/pagination.mjs
CHANGED
|
@@ -1,119 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
import { AbstractPage } from "./core.mjs";
|
|
3
|
-
export class SinglePage extends AbstractPage {
|
|
4
|
-
constructor(client, response, body, options) {
|
|
5
|
-
super(client, response, body, options);
|
|
6
|
-
this.items = body || [];
|
|
7
|
-
}
|
|
8
|
-
getPaginatedItems() {
|
|
9
|
-
return this.items ?? [];
|
|
10
|
-
}
|
|
11
|
-
// @deprecated Please use `nextPageInfo()` instead
|
|
12
|
-
/**
|
|
13
|
-
* This page represents a response that isn't actually paginated at the API level
|
|
14
|
-
* so there will never be any next page params.
|
|
15
|
-
*/
|
|
16
|
-
nextPageParams() {
|
|
17
|
-
return null;
|
|
18
|
-
}
|
|
19
|
-
nextPageInfo() {
|
|
20
|
-
return null;
|
|
21
|
-
}
|
|
22
|
-
}
|
|
23
|
-
export class ResponsesPage extends AbstractPage {
|
|
24
|
-
constructor(client, response, body, options) {
|
|
25
|
-
super(client, response, body, options);
|
|
26
|
-
this.responses = body.responses || [];
|
|
27
|
-
}
|
|
28
|
-
getPaginatedItems() {
|
|
29
|
-
return this.responses ?? [];
|
|
30
|
-
}
|
|
31
|
-
// @deprecated Please use `nextPageInfo()` instead
|
|
32
|
-
/**
|
|
33
|
-
* This page represents a response that isn't actually paginated at the API level
|
|
34
|
-
* so there will never be any next page params.
|
|
35
|
-
*/
|
|
36
|
-
nextPageParams() {
|
|
37
|
-
return null;
|
|
38
|
-
}
|
|
39
|
-
nextPageInfo() {
|
|
40
|
-
return null;
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
export class IndividualsPage extends AbstractPage {
|
|
44
|
-
constructor(client, response, body, options) {
|
|
45
|
-
super(client, response, body, options);
|
|
46
|
-
this.individuals = body.individuals || [];
|
|
47
|
-
this.paging = body.paging;
|
|
48
|
-
}
|
|
49
|
-
getPaginatedItems() {
|
|
50
|
-
return this.individuals ?? [];
|
|
51
|
-
}
|
|
52
|
-
// @deprecated Please use `nextPageInfo()` instead
|
|
53
|
-
nextPageParams() {
|
|
54
|
-
const info = this.nextPageInfo();
|
|
55
|
-
if (!info)
|
|
56
|
-
return null;
|
|
57
|
-
if ('params' in info)
|
|
58
|
-
return info.params;
|
|
59
|
-
const params = Object.fromEntries(info.url.searchParams);
|
|
60
|
-
if (!Object.keys(params).length)
|
|
61
|
-
return null;
|
|
62
|
-
return params;
|
|
63
|
-
}
|
|
64
|
-
nextPageInfo() {
|
|
65
|
-
const offset = this.paging.offset;
|
|
66
|
-
if (!offset) {
|
|
67
|
-
return null;
|
|
68
|
-
}
|
|
69
|
-
const length = this.getPaginatedItems().length;
|
|
70
|
-
const currentCount = offset + length;
|
|
71
|
-
const totalCount = this.paging.count;
|
|
72
|
-
if (!totalCount) {
|
|
73
|
-
return null;
|
|
74
|
-
}
|
|
75
|
-
if (currentCount < totalCount) {
|
|
76
|
-
return { params: { offset: currentCount } };
|
|
77
|
-
}
|
|
78
|
-
return null;
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
|
-
export class Page extends AbstractPage {
|
|
82
|
-
constructor(client, response, body, options) {
|
|
83
|
-
super(client, response, body, options);
|
|
84
|
-
this.data = body.data || [];
|
|
85
|
-
this.paging = body.paging;
|
|
86
|
-
}
|
|
87
|
-
getPaginatedItems() {
|
|
88
|
-
return this.data ?? [];
|
|
89
|
-
}
|
|
90
|
-
// @deprecated Please use `nextPageInfo()` instead
|
|
91
|
-
nextPageParams() {
|
|
92
|
-
const info = this.nextPageInfo();
|
|
93
|
-
if (!info)
|
|
94
|
-
return null;
|
|
95
|
-
if ('params' in info)
|
|
96
|
-
return info.params;
|
|
97
|
-
const params = Object.fromEntries(info.url.searchParams);
|
|
98
|
-
if (!Object.keys(params).length)
|
|
99
|
-
return null;
|
|
100
|
-
return params;
|
|
101
|
-
}
|
|
102
|
-
nextPageInfo() {
|
|
103
|
-
const offset = this.paging.offset;
|
|
104
|
-
if (!offset) {
|
|
105
|
-
return null;
|
|
106
|
-
}
|
|
107
|
-
const length = this.getPaginatedItems().length;
|
|
108
|
-
const currentCount = offset + length;
|
|
109
|
-
const totalCount = this.paging.count;
|
|
110
|
-
if (!totalCount) {
|
|
111
|
-
return null;
|
|
112
|
-
}
|
|
113
|
-
if (currentCount < totalCount) {
|
|
114
|
-
return { params: { offset: currentCount } };
|
|
115
|
-
}
|
|
116
|
-
return null;
|
|
117
|
-
}
|
|
118
|
-
}
|
|
1
|
+
export * from "./core/pagination.mjs";
|
|
119
2
|
//# sourceMappingURL=pagination.mjs.map
|
package/pagination.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pagination.mjs","sourceRoot":"","sources":["src/pagination.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"pagination.mjs","sourceRoot":"","sources":["src/pagination.ts"],"names":[],"mappings":""}
|
package/resource.d.mts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"resource.d.mts","sourceRoot":"","sources":["src/resource.ts"],"names":[],"mappings":""}
|
package/resource.d.ts
CHANGED
package/resource.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"resource.d.ts","sourceRoot":"","sources":["src/resource.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"resource.d.ts","sourceRoot":"","sources":["src/resource.ts"],"names":[],"mappings":""}
|
package/resource.js
CHANGED
|
@@ -1,11 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
this._client = client;
|
|
8
|
-
}
|
|
9
|
-
}
|
|
10
|
-
exports.APIResource = APIResource;
|
|
3
|
+
const tslib_1 = require("./internal/tslib.js");
|
|
4
|
+
/** @deprecated Import from ./core/resource instead */
|
|
5
|
+
tslib_1.__exportStar(require("./core/resource.js"), exports);
|
|
11
6
|
//# sourceMappingURL=resource.js.map
|
package/resource.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"resource.js","sourceRoot":"","sources":["src/resource.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"resource.js","sourceRoot":"","sources":["src/resource.ts"],"names":[],"mappings":";;;AAAA,sDAAsD;AACtD,6DAAgC"}
|
package/resource.mjs
CHANGED
package/resource.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"resource.mjs","sourceRoot":"","sources":["src/resource.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"resource.mjs","sourceRoot":"","sources":["src/resource.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
import type { RequestOptions } from "../internal/request-options.mjs";
|
|
2
|
+
import type { APIPromise } from "../core/api-promise.mjs";
|
|
3
|
+
import { APIResource } from "../core/resource.mjs";
|
|
4
|
+
export declare class AccessTokens extends APIResource {
|
|
5
|
+
/**
|
|
6
|
+
* Exchange the authorization code for an access token
|
|
7
|
+
*/
|
|
8
|
+
create(body: AccessTokenCreateParams, options?: RequestOptions): APIPromise<CreateAccessTokenResponse>;
|
|
9
|
+
}
|
|
10
|
+
export interface CreateAccessTokenResponse {
|
|
11
|
+
/**
|
|
12
|
+
* The access token for the connection
|
|
13
|
+
*/
|
|
14
|
+
access_token: string;
|
|
15
|
+
/**
|
|
16
|
+
* The type of application associated with a token.
|
|
17
|
+
*/
|
|
18
|
+
client_type: 'development' | 'production' | 'sandbox';
|
|
19
|
+
/**
|
|
20
|
+
* The Finch UUID of the connection associated with the `access_token`
|
|
21
|
+
*/
|
|
22
|
+
connection_id: string;
|
|
23
|
+
/**
|
|
24
|
+
* The type of the connection associated with the token.
|
|
25
|
+
*
|
|
26
|
+
* - `provider` - connection to an external provider
|
|
27
|
+
* - `finch` - finch-generated data.
|
|
28
|
+
*/
|
|
29
|
+
connection_type: 'finch' | 'provider';
|
|
30
|
+
/**
|
|
31
|
+
* An array of entity IDs that can be accessed with this access token
|
|
32
|
+
*/
|
|
33
|
+
entity_ids: Array<string>;
|
|
34
|
+
/**
|
|
35
|
+
* An array of the authorized products associated with the `access_token`
|
|
36
|
+
*/
|
|
37
|
+
products: Array<string>;
|
|
38
|
+
/**
|
|
39
|
+
* The ID of the provider associated with the `access_token`
|
|
40
|
+
*/
|
|
41
|
+
provider_id: string;
|
|
42
|
+
/**
|
|
43
|
+
* The RFC 8693 token type (Finch uses `bearer` tokens)
|
|
44
|
+
*/
|
|
45
|
+
token_type: string;
|
|
46
|
+
/**
|
|
47
|
+
* @deprecated [DEPRECATED] Use `connection_id` to identify the connection instead
|
|
48
|
+
* of this account ID
|
|
49
|
+
*/
|
|
50
|
+
account_id?: string;
|
|
51
|
+
/**
|
|
52
|
+
* @deprecated [DEPRECATED] Use `connection_id` to identify the connection instead
|
|
53
|
+
* of this company ID
|
|
54
|
+
*/
|
|
55
|
+
company_id?: string;
|
|
56
|
+
/**
|
|
57
|
+
* The ID of your customer you provided to Finch when a connect session was created
|
|
58
|
+
* for this connection
|
|
59
|
+
*/
|
|
60
|
+
customer_id?: string | null;
|
|
61
|
+
}
|
|
62
|
+
export interface AccessTokenCreateParams {
|
|
63
|
+
/**
|
|
64
|
+
* The authorization code received from the authorization server
|
|
65
|
+
*/
|
|
66
|
+
code: string;
|
|
67
|
+
/**
|
|
68
|
+
* The client ID for your application
|
|
69
|
+
*/
|
|
70
|
+
client_id?: string;
|
|
71
|
+
/**
|
|
72
|
+
* The client secret for your application
|
|
73
|
+
*/
|
|
74
|
+
client_secret?: string;
|
|
75
|
+
/**
|
|
76
|
+
* The redirect URI used in the authorization request (optional)
|
|
77
|
+
*/
|
|
78
|
+
redirect_uri?: string;
|
|
79
|
+
}
|
|
80
|
+
export declare namespace AccessTokens {
|
|
81
|
+
export { type CreateAccessTokenResponse as CreateAccessTokenResponse, type AccessTokenCreateParams as AccessTokenCreateParams, };
|
|
82
|
+
}
|
|
83
|
+
//# sourceMappingURL=access-tokens.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"access-tokens.d.mts","sourceRoot":"","sources":["../src/resources/access-tokens.ts"],"names":[],"mappings":"OAEO,KAAK,EAAE,cAAc,EAAE;OACvB,KAAK,EAAE,UAAU,EAAE;OACnB,EAAE,WAAW,EAAE;AAEtB,qBAAa,YAAa,SAAQ,WAAW;IAC3C;;OAEG;IACH,MAAM,CAAC,IAAI,EAAE,uBAAuB,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,yBAAyB,CAAC;CA0BvG;AAED,MAAM,WAAW,yBAAyB;IACxC;;OAEG;IACH,YAAY,EAAE,MAAM,CAAC;IAErB;;OAEG;IACH,WAAW,EAAE,aAAa,GAAG,YAAY,GAAG,SAAS,CAAC;IAEtD;;OAEG;IACH,aAAa,EAAE,MAAM,CAAC;IAEtB;;;;;OAKG;IACH,eAAe,EAAE,OAAO,GAAG,UAAU,CAAC;IAEtC;;OAEG;IACH,UAAU,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;IAE1B;;OAEG;IACH,QAAQ,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;IAExB;;OAEG;IACH,WAAW,EAAE,MAAM,CAAC;IAEpB;;OAEG;IACH,UAAU,EAAE,MAAM,CAAC;IAEnB;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CAC7B;AAED,MAAM,WAAW,uBAAuB;IACtC;;OAEG;IACH,IAAI,EAAE,MAAM,CAAC;IAEb;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;IAEvB;;OAEG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,MAAM,CAAC,OAAO,WAAW,YAAY,CAAC;IACpC,OAAO,EACL,KAAK,yBAAyB,IAAI,yBAAyB,EAC3D,KAAK,uBAAuB,IAAI,uBAAuB,GACxD,CAAC;CACH"}
|
|
@@ -1,40 +1,23 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
1
|
+
import type { RequestOptions } from "../internal/request-options.js";
|
|
2
|
+
import type { APIPromise } from "../core/api-promise.js";
|
|
3
|
+
import { APIResource } from "../core/resource.js";
|
|
3
4
|
export declare class AccessTokens extends APIResource {
|
|
4
5
|
/**
|
|
5
6
|
* Exchange the authorization code for an access token
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
* ```ts
|
|
9
|
-
* const createAccessTokenResponse =
|
|
10
|
-
* await client.accessTokens.create({
|
|
11
|
-
* code: '<your_authorization_code>',
|
|
12
|
-
* });
|
|
13
|
-
* ```
|
|
14
|
-
*/
|
|
15
|
-
create(body: AccessTokenCreateParams, options?: Core.RequestOptions): Core.APIPromise<CreateAccessTokenResponse>;
|
|
7
|
+
*/
|
|
8
|
+
create(body: AccessTokenCreateParams, options?: RequestOptions): APIPromise<CreateAccessTokenResponse>;
|
|
16
9
|
}
|
|
17
10
|
export interface CreateAccessTokenResponse {
|
|
18
11
|
/**
|
|
19
|
-
* The access token for the connection
|
|
12
|
+
* The access token for the connection
|
|
20
13
|
*/
|
|
21
14
|
access_token: string;
|
|
22
|
-
/**
|
|
23
|
-
* @deprecated [DEPRECATED] Use `connection_id` to identify the connection instead
|
|
24
|
-
* of this account ID.
|
|
25
|
-
*/
|
|
26
|
-
account_id: string;
|
|
27
15
|
/**
|
|
28
16
|
* The type of application associated with a token.
|
|
29
17
|
*/
|
|
30
|
-
client_type: '
|
|
31
|
-
/**
|
|
32
|
-
* @deprecated [DEPRECATED] Use `connection_id` to identify the connection instead
|
|
33
|
-
* of this company ID.
|
|
34
|
-
*/
|
|
35
|
-
company_id: string;
|
|
18
|
+
client_type: 'development' | 'production' | 'sandbox';
|
|
36
19
|
/**
|
|
37
|
-
* The Finch UUID of the connection associated with the `access_token
|
|
20
|
+
* The Finch UUID of the connection associated with the `access_token`
|
|
38
21
|
*/
|
|
39
22
|
connection_id: string;
|
|
40
23
|
/**
|
|
@@ -43,29 +26,55 @@ export interface CreateAccessTokenResponse {
|
|
|
43
26
|
* - `provider` - connection to an external provider
|
|
44
27
|
* - `finch` - finch-generated data.
|
|
45
28
|
*/
|
|
46
|
-
connection_type: '
|
|
29
|
+
connection_type: 'finch' | 'provider';
|
|
47
30
|
/**
|
|
48
|
-
* An array of
|
|
31
|
+
* An array of entity IDs that can be accessed with this access token
|
|
32
|
+
*/
|
|
33
|
+
entity_ids: Array<string>;
|
|
34
|
+
/**
|
|
35
|
+
* An array of the authorized products associated with the `access_token`
|
|
49
36
|
*/
|
|
50
37
|
products: Array<string>;
|
|
51
38
|
/**
|
|
52
|
-
* The ID of the provider associated with the `access_token
|
|
39
|
+
* The ID of the provider associated with the `access_token`
|
|
53
40
|
*/
|
|
54
41
|
provider_id: string;
|
|
55
42
|
/**
|
|
56
|
-
* The
|
|
57
|
-
* for this connection.
|
|
43
|
+
* The RFC 8693 token type (Finch uses `bearer` tokens)
|
|
58
44
|
*/
|
|
59
|
-
|
|
45
|
+
token_type: string;
|
|
60
46
|
/**
|
|
61
|
-
*
|
|
47
|
+
* @deprecated [DEPRECATED] Use `connection_id` to identify the connection instead
|
|
48
|
+
* of this account ID
|
|
62
49
|
*/
|
|
63
|
-
|
|
50
|
+
account_id?: string;
|
|
51
|
+
/**
|
|
52
|
+
* @deprecated [DEPRECATED] Use `connection_id` to identify the connection instead
|
|
53
|
+
* of this company ID
|
|
54
|
+
*/
|
|
55
|
+
company_id?: string;
|
|
56
|
+
/**
|
|
57
|
+
* The ID of your customer you provided to Finch when a connect session was created
|
|
58
|
+
* for this connection
|
|
59
|
+
*/
|
|
60
|
+
customer_id?: string | null;
|
|
64
61
|
}
|
|
65
62
|
export interface AccessTokenCreateParams {
|
|
63
|
+
/**
|
|
64
|
+
* The authorization code received from the authorization server
|
|
65
|
+
*/
|
|
66
66
|
code: string;
|
|
67
|
+
/**
|
|
68
|
+
* The client ID for your application
|
|
69
|
+
*/
|
|
67
70
|
client_id?: string;
|
|
71
|
+
/**
|
|
72
|
+
* The client secret for your application
|
|
73
|
+
*/
|
|
68
74
|
client_secret?: string;
|
|
75
|
+
/**
|
|
76
|
+
* The redirect URI used in the authorization request (optional)
|
|
77
|
+
*/
|
|
69
78
|
redirect_uri?: string;
|
|
70
79
|
}
|
|
71
80
|
export declare namespace AccessTokens {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"access-tokens.d.ts","sourceRoot":"","sources":["../src/resources/access-tokens.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"access-tokens.d.ts","sourceRoot":"","sources":["../src/resources/access-tokens.ts"],"names":[],"mappings":"OAEO,KAAK,EAAE,cAAc,EAAE;OACvB,KAAK,EAAE,UAAU,EAAE;OACnB,EAAE,WAAW,EAAE;AAEtB,qBAAa,YAAa,SAAQ,WAAW;IAC3C;;OAEG;IACH,MAAM,CAAC,IAAI,EAAE,uBAAuB,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,yBAAyB,CAAC;CA0BvG;AAED,MAAM,WAAW,yBAAyB;IACxC;;OAEG;IACH,YAAY,EAAE,MAAM,CAAC;IAErB;;OAEG;IACH,WAAW,EAAE,aAAa,GAAG,YAAY,GAAG,SAAS,CAAC;IAEtD;;OAEG;IACH,aAAa,EAAE,MAAM,CAAC;IAEtB;;;;;OAKG;IACH,eAAe,EAAE,OAAO,GAAG,UAAU,CAAC;IAEtC;;OAEG;IACH,UAAU,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;IAE1B;;OAEG;IACH,QAAQ,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;IAExB;;OAEG;IACH,WAAW,EAAE,MAAM,CAAC;IAEpB;;OAEG;IACH,UAAU,EAAE,MAAM,CAAC;IAEnB;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CAC7B;AAED,MAAM,WAAW,uBAAuB;IACtC;;OAEG;IACH,IAAI,EAAE,MAAM,CAAC;IAEb;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;IAEvB;;OAEG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,MAAM,CAAC,OAAO,WAAW,YAAY,CAAC;IACpC,OAAO,EACL,KAAK,yBAAyB,IAAI,yBAAyB,EAC3D,KAAK,uBAAuB,IAAI,uBAAuB,GACxD,CAAC;CACH"}
|
|
@@ -2,21 +2,13 @@
|
|
|
2
2
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
4
|
exports.AccessTokens = void 0;
|
|
5
|
-
const resource_1 = require("../resource.js");
|
|
5
|
+
const resource_1 = require("../core/resource.js");
|
|
6
6
|
class AccessTokens extends resource_1.APIResource {
|
|
7
7
|
/**
|
|
8
8
|
* Exchange the authorization code for an access token
|
|
9
|
-
*
|
|
10
|
-
* @example
|
|
11
|
-
* ```ts
|
|
12
|
-
* const createAccessTokenResponse =
|
|
13
|
-
* await client.accessTokens.create({
|
|
14
|
-
* code: '<your_authorization_code>',
|
|
15
|
-
* });
|
|
16
|
-
* ```
|
|
17
9
|
*/
|
|
18
10
|
create(body, options) {
|
|
19
|
-
const clientID = body.client_id || this._client.
|
|
11
|
+
const clientID = body.client_id || this._client.clientID;
|
|
20
12
|
if (!clientID)
|
|
21
13
|
throw new Error('client_id must be provided as an argument or with the FINCH_CLIENT_ID environment variable');
|
|
22
14
|
const clientSecret = body.client_secret || this._client.clientSecret;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"access-tokens.js","sourceRoot":"","sources":["../src/resources/access-tokens.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;
|
|
1
|
+
{"version":3,"file":"access-tokens.js","sourceRoot":"","sources":["../src/resources/access-tokens.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAItF,kDAA+C;AAE/C,MAAa,YAAa,SAAQ,sBAAW;IAC3C;;OAEG;IACH,MAAM,CAAC,IAA6B,EAAE,OAAwB;QAC5D,MAAM,QAAQ,GAAG,IAAI,CAAC,SAAS,IAAI,IAAI,CAAC,OAAO,CAAC,QAAQ,CAAC;QACzD,IAAI,CAAC,QAAQ;YACX,MAAM,IAAI,KAAK,CACb,4FAA4F,CAC7F,CAAC;QACJ,MAAM,YAAY,GAAG,IAAI,CAAC,aAAa,IAAI,IAAI,CAAC,OAAO,CAAC,YAAY,CAAC;QACrE,IAAI,CAAC,YAAY;YACf,MAAM,IAAI,KAAK,CACb,oGAAoG,CACrG,CAAC;QACJ,MAAM,oBAAoB,GAAG;YAC3B,GAAG,IAAI;YACP,SAAS,EAAE,QAAQ;YACnB,aAAa,EAAE,YAAY;SAC5B,CAAC;QACF,MAAM,uBAAuB,GAAG;YAC9B,GAAG,OAAO,EAAE,OAAO;YACnB,aAAa,EAAE,IAAI;SACpB,CAAC;QACF,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,aAAa,EAAE;YACtC,IAAI,EAAE,oBAAoB;YAC1B,GAAG,OAAO;YACV,OAAO,EAAE,uBAAuB;SACjC,CAAC,CAAC;IACL,CAAC;CACF;AA9BD,oCA8BC"}
|
|
@@ -1,19 +1,11 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
-
import { APIResource } from "../resource.mjs";
|
|
2
|
+
import { APIResource } from "../core/resource.mjs";
|
|
3
3
|
export class AccessTokens extends APIResource {
|
|
4
4
|
/**
|
|
5
5
|
* Exchange the authorization code for an access token
|
|
6
|
-
*
|
|
7
|
-
* @example
|
|
8
|
-
* ```ts
|
|
9
|
-
* const createAccessTokenResponse =
|
|
10
|
-
* await client.accessTokens.create({
|
|
11
|
-
* code: '<your_authorization_code>',
|
|
12
|
-
* });
|
|
13
|
-
* ```
|
|
14
6
|
*/
|
|
15
7
|
create(body, options) {
|
|
16
|
-
const clientID = body.client_id || this._client.
|
|
8
|
+
const clientID = body.client_id || this._client.clientID;
|
|
17
9
|
if (!clientID)
|
|
18
10
|
throw new Error('client_id must be provided as an argument or with the FINCH_CLIENT_ID environment variable');
|
|
19
11
|
const clientSecret = body.client_secret || this._client.clientSecret;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"access-tokens.mjs","sourceRoot":"","sources":["../src/resources/access-tokens.ts"],"names":[],"mappings":"AAAA,sFAAsF;
|
|
1
|
+
{"version":3,"file":"access-tokens.mjs","sourceRoot":"","sources":["../src/resources/access-tokens.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAI/E,EAAE,WAAW,EAAE;AAEtB,MAAM,OAAO,YAAa,SAAQ,WAAW;IAC3C;;OAEG;IACH,MAAM,CAAC,IAA6B,EAAE,OAAwB;QAC5D,MAAM,QAAQ,GAAG,IAAI,CAAC,SAAS,IAAI,IAAI,CAAC,OAAO,CAAC,QAAQ,CAAC;QACzD,IAAI,CAAC,QAAQ;YACX,MAAM,IAAI,KAAK,CACb,4FAA4F,CAC7F,CAAC;QACJ,MAAM,YAAY,GAAG,IAAI,CAAC,aAAa,IAAI,IAAI,CAAC,OAAO,CAAC,YAAY,CAAC;QACrE,IAAI,CAAC,YAAY;YACf,MAAM,IAAI,KAAK,CACb,oGAAoG,CACrG,CAAC;QACJ,MAAM,oBAAoB,GAAG;YAC3B,GAAG,IAAI;YACP,SAAS,EAAE,QAAQ;YACnB,aAAa,EAAE,YAAY;SAC5B,CAAC;QACF,MAAM,uBAAuB,GAAG;YAC9B,GAAG,OAAO,EAAE,OAAO;YACnB,aAAa,EAAE,IAAI;SACpB,CAAC;QACF,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,aAAa,EAAE;YACtC,IAAI,EAAE,oBAAoB;YAC1B,GAAG,OAAO;YACV,OAAO,EAAE,uBAAuB;SACjC,CAAC,CAAC;IACL,CAAC;CACF"}
|