@rippling/rippling-sdk 0.2.0-alpha.85 → 0.2.0-alpha.87
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/client.d.mts +15 -0
- package/client.d.mts.map +1 -1
- package/client.d.ts +15 -0
- package/client.d.ts.map +1 -1
- package/client.js +15 -0
- package/client.js.map +1 -1
- package/client.mjs +15 -0
- package/client.mjs.map +1 -1
- package/core/platform/custom-objects/category.d.mts +125 -0
- package/core/platform/custom-objects/category.d.mts.map +1 -0
- package/core/platform/custom-objects/category.d.ts +125 -0
- package/core/platform/custom-objects/category.d.ts.map +1 -0
- package/core/platform/custom-objects/category.js +188 -0
- package/core/platform/custom-objects/category.js.map +1 -0
- package/core/platform/custom-objects/category.mjs +178 -0
- package/core/platform/custom-objects/category.mjs.map +1 -0
- package/core/platform/custom-objects/definition.d.mts +147 -0
- package/core/platform/custom-objects/definition.d.mts.map +1 -0
- package/core/platform/custom-objects/definition.d.ts +147 -0
- package/core/platform/custom-objects/definition.d.ts.map +1 -0
- package/core/platform/custom-objects/definition.js +200 -0
- package/core/platform/custom-objects/definition.js.map +1 -0
- package/core/platform/custom-objects/definition.mjs +190 -0
- package/core/platform/custom-objects/definition.mjs.map +1 -0
- package/core/platform/custom-objects/fields.d.mts +302 -0
- package/core/platform/custom-objects/fields.d.mts.map +1 -0
- package/core/platform/custom-objects/fields.d.ts +302 -0
- package/core/platform/custom-objects/fields.d.ts.map +1 -0
- package/core/platform/custom-objects/fields.js +369 -0
- package/core/platform/custom-objects/fields.js.map +1 -0
- package/core/platform/custom-objects/fields.mjs +347 -0
- package/core/platform/custom-objects/fields.mjs.map +1 -0
- package/core/platform/custom-objects/function-runtime.d.mts +42 -0
- package/core/platform/custom-objects/function-runtime.d.mts.map +1 -0
- package/core/platform/custom-objects/function-runtime.d.ts +42 -0
- package/core/platform/custom-objects/function-runtime.d.ts.map +1 -0
- package/core/platform/custom-objects/function-runtime.js +38 -0
- package/core/platform/custom-objects/function-runtime.js.map +1 -0
- package/core/platform/custom-objects/function-runtime.mjs +35 -0
- package/core/platform/custom-objects/function-runtime.mjs.map +1 -0
- package/core/platform/custom-objects/lifecycle.d.mts +83 -0
- package/core/platform/custom-objects/lifecycle.d.mts.map +1 -0
- package/core/platform/custom-objects/lifecycle.d.ts +83 -0
- package/core/platform/custom-objects/lifecycle.d.ts.map +1 -0
- package/core/platform/custom-objects/lifecycle.js +372 -0
- package/core/platform/custom-objects/lifecycle.js.map +1 -0
- package/core/platform/custom-objects/lifecycle.mjs +367 -0
- package/core/platform/custom-objects/lifecycle.mjs.map +1 -0
- package/core/platform/custom-objects/manager.d.mts +354 -0
- package/core/platform/custom-objects/manager.d.mts.map +1 -0
- package/core/platform/custom-objects/manager.d.ts +354 -0
- package/core/platform/custom-objects/manager.d.ts.map +1 -0
- package/core/platform/custom-objects/manager.js +646 -0
- package/core/platform/custom-objects/manager.js.map +1 -0
- package/core/platform/custom-objects/manager.mjs +637 -0
- package/core/platform/custom-objects/manager.mjs.map +1 -0
- package/core/platform/custom-objects/provisioning.d.mts +138 -0
- package/core/platform/custom-objects/provisioning.d.mts.map +1 -0
- package/core/platform/custom-objects/provisioning.d.ts +138 -0
- package/core/platform/custom-objects/provisioning.d.ts.map +1 -0
- package/core/platform/custom-objects/provisioning.js +455 -0
- package/core/platform/custom-objects/provisioning.js.map +1 -0
- package/core/platform/custom-objects/provisioning.mjs +447 -0
- package/core/platform/custom-objects/provisioning.mjs.map +1 -0
- package/core/platform/custom-objects/rql.d.mts +122 -0
- package/core/platform/custom-objects/rql.d.mts.map +1 -0
- package/core/platform/custom-objects/rql.d.ts +122 -0
- package/core/platform/custom-objects/rql.d.ts.map +1 -0
- package/core/platform/custom-objects/rql.js +225 -0
- package/core/platform/custom-objects/rql.js.map +1 -0
- package/core/platform/custom-objects/rql.mjs +222 -0
- package/core/platform/custom-objects/rql.mjs.map +1 -0
- package/core/platform/custom-objects/schema-manager.d.mts +203 -0
- package/core/platform/custom-objects/schema-manager.d.mts.map +1 -0
- package/core/platform/custom-objects/schema-manager.d.ts +203 -0
- package/core/platform/custom-objects/schema-manager.d.ts.map +1 -0
- package/core/platform/custom-objects/schema-manager.js +256 -0
- package/core/platform/custom-objects/schema-manager.js.map +1 -0
- package/core/platform/custom-objects/schema-manager.mjs +249 -0
- package/core/platform/custom-objects/schema-manager.mjs.map +1 -0
- package/core/platform/custom-objects/typed-rql.d.mts +157 -0
- package/core/platform/custom-objects/typed-rql.d.mts.map +1 -0
- package/core/platform/custom-objects/typed-rql.d.ts +157 -0
- package/core/platform/custom-objects/typed-rql.d.ts.map +1 -0
- package/core/platform/custom-objects/typed-rql.js +583 -0
- package/core/platform/custom-objects/typed-rql.js.map +1 -0
- package/core/platform/custom-objects/typed-rql.mjs +580 -0
- package/core/platform/custom-objects/typed-rql.mjs.map +1 -0
- package/core/platform/custom-objects/types.d.mts +549 -0
- package/core/platform/custom-objects/types.d.mts.map +1 -0
- package/core/platform/custom-objects/types.d.ts +549 -0
- package/core/platform/custom-objects/types.d.ts.map +1 -0
- package/core/platform/custom-objects/types.js +20 -0
- package/core/platform/custom-objects/types.js.map +1 -0
- package/core/platform/custom-objects/types.mjs +17 -0
- package/core/platform/custom-objects/types.mjs.map +1 -0
- package/core/platform/custom-objects/validation.d.mts +97 -0
- package/core/platform/custom-objects/validation.d.mts.map +1 -0
- package/core/platform/custom-objects/validation.d.ts +97 -0
- package/core/platform/custom-objects/validation.d.ts.map +1 -0
- package/core/platform/custom-objects/validation.js +477 -0
- package/core/platform/custom-objects/validation.js.map +1 -0
- package/core/platform/custom-objects/validation.mjs +465 -0
- package/core/platform/custom-objects/validation.mjs.map +1 -0
- package/core/platform/custom-objects.d.mts +67 -0
- package/core/platform/custom-objects.d.mts.map +1 -0
- package/core/platform/custom-objects.d.ts +67 -0
- package/core/platform/custom-objects.d.ts.map +1 -0
- package/core/platform/custom-objects.js +118 -0
- package/core/platform/custom-objects.js.map +1 -0
- package/core/platform/custom-objects.mjs +45 -0
- package/core/platform/custom-objects.mjs.map +1 -0
- package/lib/leave-programs/advanced.d.mts +5 -0
- package/lib/leave-programs/advanced.d.mts.map +1 -0
- package/lib/leave-programs/advanced.d.ts +5 -0
- package/lib/leave-programs/advanced.d.ts.map +1 -0
- package/lib/leave-programs/advanced.js +13 -0
- package/lib/leave-programs/advanced.js.map +1 -0
- package/lib/leave-programs/advanced.mjs +4 -0
- package/lib/leave-programs/advanced.mjs.map +1 -0
- package/lib/leave-programs/context.d.mts +3 -0
- package/lib/leave-programs/context.d.mts.map +1 -0
- package/lib/leave-programs/context.d.ts +3 -0
- package/lib/leave-programs/context.d.ts.map +1 -0
- package/lib/leave-programs/context.js +89 -0
- package/lib/leave-programs/context.js.map +1 -0
- package/lib/leave-programs/context.mjs +86 -0
- package/lib/leave-programs/context.mjs.map +1 -0
- package/lib/leave-programs/define-company-leave-program.d.mts +3 -0
- package/lib/leave-programs/define-company-leave-program.d.mts.map +1 -0
- package/lib/leave-programs/define-company-leave-program.d.ts +3 -0
- package/lib/leave-programs/define-company-leave-program.d.ts.map +1 -0
- package/lib/leave-programs/define-company-leave-program.js +47 -0
- package/lib/leave-programs/define-company-leave-program.js.map +1 -0
- package/lib/leave-programs/define-company-leave-program.mjs +44 -0
- package/lib/leave-programs/define-company-leave-program.mjs.map +1 -0
- package/lib/leave-programs/duration.d.mts +5 -0
- package/lib/leave-programs/duration.d.mts.map +1 -0
- package/lib/leave-programs/duration.d.ts +5 -0
- package/lib/leave-programs/duration.d.ts.map +1 -0
- package/lib/leave-programs/duration.js +21 -0
- package/lib/leave-programs/duration.js.map +1 -0
- package/lib/leave-programs/duration.mjs +16 -0
- package/lib/leave-programs/duration.mjs.map +1 -0
- package/lib/leave-programs/pay.d.mts +4 -0
- package/lib/leave-programs/pay.d.mts.map +1 -0
- package/lib/leave-programs/pay.d.ts +4 -0
- package/lib/leave-programs/pay.d.ts.map +1 -0
- package/lib/leave-programs/pay.js +20 -0
- package/lib/leave-programs/pay.js.map +1 -0
- package/lib/leave-programs/pay.mjs +16 -0
- package/lib/leave-programs/pay.mjs.map +1 -0
- package/lib/leave-programs/policy-builder.d.mts +20 -0
- package/lib/leave-programs/policy-builder.d.mts.map +1 -0
- package/lib/leave-programs/policy-builder.d.ts +20 -0
- package/lib/leave-programs/policy-builder.d.ts.map +1 -0
- package/lib/leave-programs/policy-builder.js +89 -0
- package/lib/leave-programs/policy-builder.js.map +1 -0
- package/lib/leave-programs/policy-builder.mjs +85 -0
- package/lib/leave-programs/policy-builder.mjs.map +1 -0
- package/lib/leave-programs/recipes/parental-top-up-policy.d.mts +25 -0
- package/lib/leave-programs/recipes/parental-top-up-policy.d.mts.map +1 -0
- package/lib/leave-programs/recipes/parental-top-up-policy.d.ts +25 -0
- package/lib/leave-programs/recipes/parental-top-up-policy.d.ts.map +1 -0
- package/lib/leave-programs/recipes/parental-top-up-policy.js +56 -0
- package/lib/leave-programs/recipes/parental-top-up-policy.js.map +1 -0
- package/lib/leave-programs/recipes/parental-top-up-policy.mjs +53 -0
- package/lib/leave-programs/recipes/parental-top-up-policy.mjs.map +1 -0
- package/lib/leave-programs/testing.d.mts +8 -0
- package/lib/leave-programs/testing.d.mts.map +1 -0
- package/lib/leave-programs/testing.d.ts +8 -0
- package/lib/leave-programs/testing.d.ts.map +1 -0
- package/lib/leave-programs/testing.js +11 -0
- package/lib/leave-programs/testing.js.map +1 -0
- package/lib/leave-programs/testing.mjs +7 -0
- package/lib/leave-programs/testing.mjs.map +1 -0
- package/lib/leave-programs/types.d.mts +223 -0
- package/lib/leave-programs/types.d.mts.map +1 -0
- package/lib/leave-programs/types.d.ts +223 -0
- package/lib/leave-programs/types.d.ts.map +1 -0
- package/lib/leave-programs/types.js +10 -0
- package/lib/leave-programs/types.js.map +1 -0
- package/lib/leave-programs/types.mjs +7 -0
- package/lib/leave-programs/types.mjs.map +1 -0
- package/lib/leave-programs.d.mts +7 -0
- package/lib/leave-programs.d.mts.map +1 -0
- package/lib/leave-programs.d.ts +7 -0
- package/lib/leave-programs.d.ts.map +1 -0
- package/lib/leave-programs.js +19 -0
- package/lib/leave-programs.js.map +1 -0
- package/lib/leave-programs.mjs +7 -0
- package/lib/leave-programs.mjs.map +1 -0
- package/package.json +1 -1
- package/resources/agents/agents.d.mts +208 -0
- package/resources/agents/agents.d.mts.map +1 -0
- package/resources/agents/agents.d.ts +208 -0
- package/resources/agents/agents.d.ts.map +1 -0
- package/resources/agents/agents.js +64 -0
- package/resources/agents/agents.js.map +1 -0
- package/resources/agents/agents.mjs +59 -0
- package/resources/agents/agents.mjs.map +1 -0
- package/resources/agents/deployments.d.mts +180 -0
- package/resources/agents/deployments.d.mts.map +1 -0
- package/resources/agents/deployments.d.ts +180 -0
- package/resources/agents/deployments.d.ts.map +1 -0
- package/resources/agents/deployments.js +32 -0
- package/resources/agents/deployments.js.map +1 -0
- package/resources/agents/deployments.mjs +28 -0
- package/resources/agents/deployments.mjs.map +1 -0
- package/resources/agents/index.d.mts +5 -0
- package/resources/agents/index.d.mts.map +1 -0
- package/resources/agents/index.d.ts +5 -0
- package/resources/agents/index.d.ts.map +1 -0
- package/resources/agents/index.js +13 -0
- package/resources/agents/index.js.map +1 -0
- package/resources/agents/index.mjs +6 -0
- package/resources/agents/index.mjs.map +1 -0
- package/resources/agents/sessions/events.d.mts +80 -0
- package/resources/agents/sessions/events.d.mts.map +1 -0
- package/resources/agents/sessions/events.d.ts +80 -0
- package/resources/agents/sessions/events.d.ts.map +1 -0
- package/resources/agents/sessions/events.js +19 -0
- package/resources/agents/sessions/events.js.map +1 -0
- package/resources/agents/sessions/events.mjs +15 -0
- package/resources/agents/sessions/events.mjs.map +1 -0
- package/resources/agents/sessions/index.d.mts +3 -0
- package/resources/agents/sessions/index.d.mts.map +1 -0
- package/resources/agents/sessions/index.d.ts +3 -0
- package/resources/agents/sessions/index.d.ts.map +1 -0
- package/resources/agents/sessions/index.js +9 -0
- package/resources/agents/sessions/index.js.map +1 -0
- package/resources/agents/sessions/index.mjs +4 -0
- package/resources/agents/sessions/index.mjs.map +1 -0
- package/resources/agents/sessions/sessions.d.mts +153 -0
- package/resources/agents/sessions/sessions.d.mts.map +1 -0
- package/resources/agents/sessions/sessions.d.ts +153 -0
- package/resources/agents/sessions/sessions.d.ts.map +1 -0
- package/resources/agents/sessions/sessions.js +44 -0
- package/resources/agents/sessions/sessions.js.map +1 -0
- package/resources/agents/sessions/sessions.mjs +39 -0
- package/resources/agents/sessions/sessions.mjs.map +1 -0
- package/resources/agents/sessions.d.mts +2 -0
- package/resources/agents/sessions.d.mts.map +1 -0
- package/resources/agents/sessions.d.ts +2 -0
- package/resources/agents/sessions.d.ts.map +1 -0
- package/resources/agents/sessions.js +6 -0
- package/resources/agents/sessions.js.map +1 -0
- package/resources/agents/sessions.mjs +3 -0
- package/resources/agents/sessions.mjs.map +1 -0
- package/resources/agents/source-revisions.d.mts +195 -0
- package/resources/agents/source-revisions.d.mts.map +1 -0
- package/resources/agents/source-revisions.d.ts +195 -0
- package/resources/agents/source-revisions.d.ts.map +1 -0
- package/resources/agents/source-revisions.js +32 -0
- package/resources/agents/source-revisions.js.map +1 -0
- package/resources/agents/source-revisions.mjs +28 -0
- package/resources/agents/source-revisions.mjs.map +1 -0
- package/resources/agents.d.mts +2 -0
- package/resources/agents.d.mts.map +1 -0
- package/resources/agents.d.ts +2 -0
- package/resources/agents.d.ts.map +1 -0
- package/resources/agents.js +6 -0
- package/resources/agents.js.map +1 -0
- package/resources/agents.mjs +3 -0
- package/resources/agents.mjs.map +1 -0
- package/resources/break-policies.d.mts +1 -1
- package/resources/break-policies.d.ts +1 -1
- package/resources/break-policies.js +1 -1
- package/resources/break-policies.mjs +1 -1
- package/resources/break-types.d.mts +1 -1
- package/resources/break-types.d.ts +1 -1
- package/resources/break-types.js +1 -1
- package/resources/break-types.mjs +1 -1
- package/resources/business-structure-paths.d.mts +1 -1
- package/resources/business-structure-paths.d.ts +1 -1
- package/resources/business-structure-paths.js +1 -1
- package/resources/business-structure-paths.mjs +1 -1
- package/resources/candidate-applications.d.mts +1 -1
- package/resources/candidate-applications.d.ts +1 -1
- package/resources/candidate-applications.js +1 -1
- package/resources/candidate-applications.mjs +1 -1
- package/resources/candidates.d.mts +1 -1
- package/resources/candidates.d.ts +1 -1
- package/resources/candidates.js +1 -1
- package/resources/candidates.mjs +1 -1
- package/resources/company-legal-entities.d.mts +1 -1
- package/resources/company-legal-entities.d.ts +1 -1
- package/resources/company-legal-entities.js +1 -1
- package/resources/company-legal-entities.mjs +1 -1
- package/resources/company-legal-entity-workers.d.mts +1 -1
- package/resources/company-legal-entity-workers.d.ts +1 -1
- package/resources/company-legal-entity-workers.js +1 -1
- package/resources/company-legal-entity-workers.mjs +1 -1
- package/resources/compensation-bands-details.d.mts +1 -1
- package/resources/compensation-bands-details.d.ts +1 -1
- package/resources/compensation-bands-details.js +1 -1
- package/resources/compensation-bands-details.mjs +1 -1
- package/resources/compensations.d.mts +1 -1
- package/resources/compensations.d.ts +1 -1
- package/resources/compensations.js +1 -1
- package/resources/compensations.mjs +1 -1
- package/resources/custom-objects/custom-objects.d.mts +7 -0
- package/resources/custom-objects/custom-objects.d.mts.map +1 -1
- package/resources/custom-objects/custom-objects.d.ts +7 -0
- package/resources/custom-objects/custom-objects.d.ts.map +1 -1
- package/resources/custom-objects/custom-objects.js.map +1 -1
- package/resources/custom-objects/custom-objects.mjs.map +1 -1
- package/resources/custom-objects/fields.d.mts +129 -54
- package/resources/custom-objects/fields.d.mts.map +1 -1
- package/resources/custom-objects/fields.d.ts +129 -54
- package/resources/custom-objects/fields.d.ts.map +1 -1
- package/resources/device-orders.d.mts +1 -1
- package/resources/device-orders.d.ts +1 -1
- package/resources/device-orders.js +1 -1
- package/resources/device-orders.mjs +1 -1
- package/resources/devices.d.mts +1 -1
- package/resources/devices.d.ts +1 -1
- package/resources/devices.js +1 -1
- package/resources/devices.mjs +1 -1
- package/resources/functions/deployments.d.mts +2 -2
- package/resources/functions/deployments.d.ts +2 -2
- package/resources/functions/deployments.js +2 -2
- package/resources/functions/deployments.mjs +2 -2
- package/resources/functions/executions.d.mts +2 -2
- package/resources/functions/executions.d.ts +2 -2
- package/resources/functions/executions.js +2 -2
- package/resources/functions/executions.mjs +2 -2
- package/resources/functions/functions.d.mts +1 -1
- package/resources/functions/functions.d.ts +1 -1
- package/resources/functions/functions.js +1 -1
- package/resources/functions/functions.mjs +1 -1
- package/resources/headcount-positions.d.mts +1 -1
- package/resources/headcount-positions.d.ts +1 -1
- package/resources/headcount-positions.js +1 -1
- package/resources/headcount-positions.mjs +1 -1
- package/resources/headcount-priorities.d.mts +1 -1
- package/resources/headcount-priorities.d.ts +1 -1
- package/resources/headcount-priorities.js +1 -1
- package/resources/headcount-priorities.mjs +1 -1
- package/resources/index.d.mts +3 -0
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +3 -0
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +8 -2
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +3 -0
- package/resources/index.mjs.map +1 -1
- package/resources/job-assignments.d.mts +2 -2
- package/resources/job-assignments.d.ts +2 -2
- package/resources/job-assignments.js +2 -2
- package/resources/job-assignments.mjs +2 -2
- package/resources/job-codes.d.mts +2 -2
- package/resources/job-codes.d.ts +2 -2
- package/resources/job-codes.js +2 -2
- package/resources/job-codes.mjs +2 -2
- package/resources/job-dimensions.d.mts +1 -1
- package/resources/job-dimensions.d.ts +1 -1
- package/resources/job-dimensions.js +1 -1
- package/resources/job-dimensions.mjs +1 -1
- package/resources/job-pay-rate-exceptions.d.mts +2 -2
- package/resources/job-pay-rate-exceptions.d.ts +2 -2
- package/resources/job-pay-rate-exceptions.js +2 -2
- package/resources/job-pay-rate-exceptions.mjs +2 -2
- package/resources/job-requisitions.d.mts +1 -1
- package/resources/job-requisitions.d.ts +1 -1
- package/resources/job-requisitions.js +1 -1
- package/resources/job-requisitions.mjs +1 -1
- package/resources/kiosk-badges.d.mts +1 -1
- package/resources/kiosk-badges.d.ts +1 -1
- package/resources/kiosk-badges.js +1 -1
- package/resources/kiosk-badges.mjs +1 -1
- package/resources/leave-accruals.d.mts +1 -1
- package/resources/leave-accruals.d.ts +1 -1
- package/resources/leave-accruals.js +1 -1
- package/resources/leave-accruals.mjs +1 -1
- package/resources/leave-balances.d.mts +1 -1
- package/resources/leave-balances.d.ts +1 -1
- package/resources/leave-balances.js +1 -1
- package/resources/leave-balances.mjs +1 -1
- package/resources/leave-requests.d.mts +1 -1
- package/resources/leave-requests.d.ts +1 -1
- package/resources/leave-requests.js +1 -1
- package/resources/leave-requests.mjs +1 -1
- package/resources/leave-types.d.mts +1 -1
- package/resources/leave-types.d.ts +1 -1
- package/resources/leave-types.js +1 -1
- package/resources/leave-types.mjs +1 -1
- package/resources/legal-entities.d.mts +1 -1
- package/resources/legal-entities.d.ts +1 -1
- package/resources/legal-entities.js +1 -1
- package/resources/legal-entities.mjs +1 -1
- package/resources/levels.d.mts +26 -5
- package/resources/levels.d.mts.map +1 -1
- package/resources/levels.d.ts +26 -5
- package/resources/levels.d.ts.map +1 -1
- package/resources/levels.js +1 -1
- package/resources/levels.mjs +1 -1
- package/resources/location-factors.d.mts +1 -1
- package/resources/location-factors.d.ts +1 -1
- package/resources/location-factors.js +1 -1
- package/resources/location-factors.mjs +1 -1
- package/resources/packages/index.d.mts +3 -0
- package/resources/packages/index.d.mts.map +1 -0
- package/resources/packages/index.d.ts +3 -0
- package/resources/packages/index.d.ts.map +1 -0
- package/resources/packages/index.js +9 -0
- package/resources/packages/index.js.map +1 -0
- package/resources/packages/index.mjs +4 -0
- package/resources/packages/index.mjs.map +1 -0
- package/resources/packages/packages.d.mts +239 -0
- package/resources/packages/packages.d.mts.map +1 -0
- package/resources/packages/packages.d.ts +239 -0
- package/resources/packages/packages.d.ts.map +1 -0
- package/resources/packages/packages.js +60 -0
- package/resources/packages/packages.js.map +1 -0
- package/resources/packages/packages.mjs +55 -0
- package/resources/packages/packages.mjs.map +1 -0
- package/resources/packages/versions.d.mts +72 -0
- package/resources/packages/versions.d.mts.map +1 -0
- package/resources/packages/versions.d.ts +72 -0
- package/resources/packages/versions.d.ts.map +1 -0
- package/resources/packages/versions.js +19 -0
- package/resources/packages/versions.js.map +1 -0
- package/resources/packages/versions.mjs +15 -0
- package/resources/packages/versions.mjs.map +1 -0
- package/resources/packages.d.mts +2 -0
- package/resources/packages.d.mts.map +1 -0
- package/resources/packages.d.ts +2 -0
- package/resources/packages.d.ts.map +1 -0
- package/resources/packages.js +6 -0
- package/resources/packages.js.map +1 -0
- package/resources/packages.mjs +3 -0
- package/resources/packages.mjs.map +1 -0
- package/resources/scheduled-job-assignments.d.mts +1 -1
- package/resources/scheduled-job-assignments.d.ts +1 -1
- package/resources/scheduled-job-assignments.js +1 -1
- package/resources/scheduled-job-assignments.mjs +1 -1
- package/resources/schedules.d.mts +1 -1
- package/resources/schedules.d.ts +1 -1
- package/resources/schedules.js +1 -1
- package/resources/schedules.mjs +1 -1
- package/resources/shift-assignments.d.mts +1 -1
- package/resources/shift-assignments.d.ts +1 -1
- package/resources/shift-assignments.js +1 -1
- package/resources/shift-assignments.mjs +1 -1
- package/resources/shift-inputs.d.mts +1 -1
- package/resources/shift-inputs.d.ts +1 -1
- package/resources/shift-inputs.js +1 -1
- package/resources/shift-inputs.mjs +1 -1
- package/resources/shiftassignments.d.mts +1 -1
- package/resources/shiftassignments.d.ts +1 -1
- package/resources/shiftassignments.js +1 -1
- package/resources/shiftassignments.mjs +1 -1
- package/resources/sites.d.mts +572 -0
- package/resources/sites.d.mts.map +1 -0
- package/resources/sites.d.ts +572 -0
- package/resources/sites.d.ts.map +1 -0
- package/resources/sites.js +154 -0
- package/resources/sites.js.map +1 -0
- package/resources/sites.mjs +150 -0
- package/resources/sites.mjs.map +1 -0
- package/resources/software-deployments.d.mts +1 -1
- package/resources/software-deployments.d.ts +1 -1
- package/resources/software-deployments.js +1 -1
- package/resources/software-deployments.mjs +1 -1
- package/resources/time-cards.d.mts +1 -1
- package/resources/time-cards.d.ts +1 -1
- package/resources/time-cards.js +1 -1
- package/resources/time-cards.mjs +1 -1
- package/resources/time-entries.d.mts +1 -1
- package/resources/time-entries.d.ts +1 -1
- package/resources/time-entries.js +1 -1
- package/resources/time-entries.mjs +1 -1
- package/resources/tracks.d.mts +1 -1
- package/resources/tracks.d.ts +1 -1
- package/resources/tracks.js +1 -1
- package/resources/tracks.mjs +1 -1
- package/resources/unassigned-shifts.d.mts +2 -2
- package/resources/unassigned-shifts.d.ts +2 -2
- package/resources/unassigned-shifts.js +2 -2
- package/resources/unassigned-shifts.mjs +2 -2
- package/resources/unassignedshifts.d.mts +1 -1
- package/resources/unassignedshifts.d.ts +1 -1
- package/resources/unassignedshifts.js +1 -1
- package/resources/unassignedshifts.mjs +1 -1
- package/resources/worker-time-splits.d.mts +1 -1
- package/resources/worker-time-splits.d.ts +1 -1
- package/resources/worker-time-splits.js +1 -1
- package/resources/worker-time-splits.mjs +1 -1
- package/src/client.ts +91 -0
- package/src/core/platform/custom-objects/category.ts +294 -0
- package/src/core/platform/custom-objects/definition.ts +373 -0
- package/src/core/platform/custom-objects/fields.ts +653 -0
- package/src/core/platform/custom-objects/function-runtime.ts +76 -0
- package/src/core/platform/custom-objects/lifecycle.ts +557 -0
- package/src/core/platform/custom-objects/manager.ts +959 -0
- package/src/core/platform/custom-objects/provisioning.ts +672 -0
- package/src/core/platform/custom-objects/rql.ts +375 -0
- package/src/core/platform/custom-objects/schema-manager.ts +351 -0
- package/src/core/platform/custom-objects/typed-rql.ts +1273 -0
- package/src/core/platform/custom-objects/types.ts +753 -0
- package/src/core/platform/custom-objects/validation.ts +573 -0
- package/src/core/platform/custom-objects.ts +269 -0
- package/src/lib/leave-programs/README.md +160 -0
- package/src/lib/leave-programs/advanced.ts +11 -0
- package/src/lib/leave-programs/context.ts +101 -0
- package/src/lib/leave-programs/define-company-leave-program.ts +58 -0
- package/src/lib/leave-programs/duration.ts +20 -0
- package/src/lib/leave-programs/pay.ts +18 -0
- package/src/lib/leave-programs/policy-builder.ts +113 -0
- package/src/lib/leave-programs/recipes/parental-top-up-policy.ts +85 -0
- package/src/lib/leave-programs/testing.ts +16 -0
- package/src/lib/leave-programs/types.ts +274 -0
- package/src/lib/leave-programs.ts +35 -0
- package/src/resources/agents/agents.ts +340 -0
- package/src/resources/agents/deployments.ts +249 -0
- package/src/resources/agents/index.ts +40 -0
- package/src/resources/agents/sessions/events.ts +107 -0
- package/src/resources/agents/sessions/index.ts +12 -0
- package/src/resources/agents/sessions/sessions.ts +216 -0
- package/src/resources/agents/sessions.ts +3 -0
- package/src/resources/agents/source-revisions.ts +267 -0
- package/src/resources/agents.ts +3 -0
- package/src/resources/break-policies.ts +1 -1
- package/src/resources/break-types.ts +1 -1
- package/src/resources/business-structure-paths.ts +1 -1
- package/src/resources/candidate-applications.ts +1 -1
- package/src/resources/candidates.ts +1 -1
- package/src/resources/company-legal-entities.ts +1 -1
- package/src/resources/company-legal-entity-workers.ts +1 -1
- package/src/resources/compensation-bands-details.ts +1 -1
- package/src/resources/compensations.ts +1 -1
- package/src/resources/custom-objects/custom-objects.ts +8 -0
- package/src/resources/custom-objects/fields.ts +192 -59
- package/src/resources/device-orders.ts +1 -1
- package/src/resources/devices.ts +1 -1
- package/src/resources/functions/deployments.ts +2 -2
- package/src/resources/functions/executions.ts +2 -2
- package/src/resources/functions/functions.ts +1 -1
- package/src/resources/headcount-positions.ts +1 -1
- package/src/resources/headcount-priorities.ts +1 -1
- package/src/resources/index.ts +38 -0
- package/src/resources/job-assignments.ts +2 -2
- package/src/resources/job-codes.ts +2 -2
- package/src/resources/job-dimensions.ts +1 -1
- package/src/resources/job-pay-rate-exceptions.ts +2 -2
- package/src/resources/job-requisitions.ts +1 -1
- package/src/resources/kiosk-badges.ts +1 -1
- package/src/resources/leave-accruals.ts +1 -1
- package/src/resources/leave-balances.ts +1 -1
- package/src/resources/leave-requests.ts +1 -1
- package/src/resources/leave-types.ts +1 -1
- package/src/resources/legal-entities.ts +1 -1
- package/src/resources/levels.ts +29 -5
- package/src/resources/location-factors.ts +1 -1
- package/src/resources/packages/index.ts +14 -0
- package/src/resources/packages/packages.ts +329 -0
- package/src/resources/packages/versions.ts +98 -0
- package/src/resources/packages.ts +3 -0
- package/src/resources/scheduled-job-assignments.ts +1 -1
- package/src/resources/schedules.ts +1 -1
- package/src/resources/shift-assignments.ts +1 -1
- package/src/resources/shift-inputs.ts +1 -1
- package/src/resources/shiftassignments.ts +1 -1
- package/src/resources/sites.ts +736 -0
- package/src/resources/software-deployments.ts +1 -1
- package/src/resources/time-cards.ts +1 -1
- package/src/resources/time-entries.ts +1 -1
- package/src/resources/tracks.ts +1 -1
- package/src/resources/unassigned-shifts.ts +2 -2
- package/src/resources/unassignedshifts.ts +1 -1
- package/src/resources/worker-time-splits.ts +1 -1
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
package/src/client.ts
CHANGED
|
@@ -432,6 +432,22 @@ import {
|
|
|
432
432
|
ShiftassignmentUpdateResponse,
|
|
433
433
|
Shiftassignments,
|
|
434
434
|
} from './resources/shiftassignments';
|
|
435
|
+
import {
|
|
436
|
+
SiteCreateParams,
|
|
437
|
+
SiteCreateResponse,
|
|
438
|
+
SiteFileOperationsParams,
|
|
439
|
+
SiteFileOperationsResponse,
|
|
440
|
+
SiteFilesParams,
|
|
441
|
+
SiteFilesResponse,
|
|
442
|
+
SiteListResponse,
|
|
443
|
+
SiteListResponsesPageCursorURL,
|
|
444
|
+
SiteRetrieveResponse,
|
|
445
|
+
SiteUpdateParams,
|
|
446
|
+
SiteUpdateResponse,
|
|
447
|
+
SiteUploadBatchesParams,
|
|
448
|
+
SiteUploadBatchesResponse,
|
|
449
|
+
Sites,
|
|
450
|
+
} from './resources/sites';
|
|
435
451
|
import {
|
|
436
452
|
SoftwareDeploymentCreateParams,
|
|
437
453
|
SoftwareDeploymentCreateResponse,
|
|
@@ -564,6 +580,17 @@ import {
|
|
|
564
580
|
WorkflowActionExecutionCreateResponse,
|
|
565
581
|
WorkflowActionExecutions,
|
|
566
582
|
} from './resources/workflow-action-executions';
|
|
583
|
+
import {
|
|
584
|
+
AgentCreateParams,
|
|
585
|
+
AgentCreateResponse,
|
|
586
|
+
AgentListParams,
|
|
587
|
+
AgentListResponse,
|
|
588
|
+
AgentListResponsesPageCursorURL,
|
|
589
|
+
AgentRetrieveResponse,
|
|
590
|
+
AgentUpdateParams,
|
|
591
|
+
AgentUpdateResponse,
|
|
592
|
+
Agents,
|
|
593
|
+
} from './resources/agents/agents';
|
|
567
594
|
import {
|
|
568
595
|
CustomObject,
|
|
569
596
|
CustomObjectCreateParams,
|
|
@@ -581,6 +608,17 @@ import {
|
|
|
581
608
|
Functions,
|
|
582
609
|
FunctionsPageCursorURL,
|
|
583
610
|
} from './resources/functions/functions';
|
|
611
|
+
import {
|
|
612
|
+
PackageCreateParams,
|
|
613
|
+
PackageCreateResponse,
|
|
614
|
+
PackageListParams,
|
|
615
|
+
PackageListResponse,
|
|
616
|
+
PackageListResponsesPageCursorURL,
|
|
617
|
+
PackageRetrieveResponse,
|
|
618
|
+
PackageUpdateParams,
|
|
619
|
+
PackageUpdateResponse,
|
|
620
|
+
Packages,
|
|
621
|
+
} from './resources/packages/packages';
|
|
584
622
|
import {
|
|
585
623
|
PayrollRunListParams,
|
|
586
624
|
PayrollRunListResponse,
|
|
@@ -1461,6 +1499,10 @@ export class RipplingSDK {
|
|
|
1461
1499
|
* Job related information for the company
|
|
1462
1500
|
*/
|
|
1463
1501
|
jobPayRateExceptions: API.JobPayRateExceptions = new API.JobPayRateExceptions(this);
|
|
1502
|
+
/**
|
|
1503
|
+
* Agents defined by the company
|
|
1504
|
+
*/
|
|
1505
|
+
agents: API.Agents = new API.Agents(this);
|
|
1464
1506
|
/**
|
|
1465
1507
|
* Mappings between Rippling workers and their user accounts in third-party apps
|
|
1466
1508
|
*/
|
|
@@ -1564,6 +1606,10 @@ export class RipplingSDK {
|
|
|
1564
1606
|
* Geographic compensation adjustment factors that modify base compensation based on location-specific market conditions and cost of living
|
|
1565
1607
|
*/
|
|
1566
1608
|
locationFactors: API.LocationFactors = new API.LocationFactors(this);
|
|
1609
|
+
/**
|
|
1610
|
+
* Author, publish, and install Unity Packages V2 packages
|
|
1611
|
+
*/
|
|
1612
|
+
packages: API.Packages = new API.Packages(this);
|
|
1567
1613
|
/**
|
|
1568
1614
|
* Payroll runs for the company
|
|
1569
1615
|
*/
|
|
@@ -1592,6 +1638,7 @@ export class RipplingSDK {
|
|
|
1592
1638
|
* Shift assignments assigned to workers
|
|
1593
1639
|
*/
|
|
1594
1640
|
shiftassignments: API.Shiftassignments = new API.Shiftassignments(this);
|
|
1641
|
+
sites: API.Sites = new API.Sites(this);
|
|
1595
1642
|
/**
|
|
1596
1643
|
* Software deployed to company devices
|
|
1597
1644
|
*/
|
|
@@ -1660,6 +1707,7 @@ RipplingSDK.BusinessPartnerGroups = BusinessPartnerGroups;
|
|
|
1660
1707
|
RipplingSDK.Functions = Functions;
|
|
1661
1708
|
RipplingSDK.JobAssignments = JobAssignments;
|
|
1662
1709
|
RipplingSDK.JobPayRateExceptions = JobPayRateExceptions;
|
|
1710
|
+
RipplingSDK.Agents = Agents;
|
|
1663
1711
|
RipplingSDK.AppUsers = AppUsers;
|
|
1664
1712
|
RipplingSDK.BreakPolicies = BreakPolicies;
|
|
1665
1713
|
RipplingSDK.BreakTypes = BreakTypes;
|
|
@@ -1688,6 +1736,7 @@ RipplingSDK.JobRequisitionsWrite = JobRequisitionsWrite;
|
|
|
1688
1736
|
RipplingSDK.LeaveAccruals = LeaveAccruals;
|
|
1689
1737
|
RipplingSDK.LeaveProgramEvaluations = LeaveProgramEvaluations;
|
|
1690
1738
|
RipplingSDK.LocationFactors = LocationFactors;
|
|
1739
|
+
RipplingSDK.Packages = Packages;
|
|
1691
1740
|
RipplingSDK.PayrollRuns = PayrollRuns;
|
|
1692
1741
|
RipplingSDK.PlatformCapabilities = PlatformCapabilities;
|
|
1693
1742
|
RipplingSDK.Reports = Reports;
|
|
@@ -1695,6 +1744,7 @@ RipplingSDK.ReportRuns = ReportRuns;
|
|
|
1695
1744
|
RipplingSDK.Schedules = Schedules;
|
|
1696
1745
|
RipplingSDK.ScheduledJobAssignments = ScheduledJobAssignments;
|
|
1697
1746
|
RipplingSDK.Shiftassignments = Shiftassignments;
|
|
1747
|
+
RipplingSDK.Sites = Sites;
|
|
1698
1748
|
RipplingSDK.SoftwareDeployments = SoftwareDeployments;
|
|
1699
1749
|
RipplingSDK.Titles = Titles;
|
|
1700
1750
|
RipplingSDK.Unassignedshifts = Unassignedshifts;
|
|
@@ -2011,6 +2061,18 @@ export declare namespace RipplingSDK {
|
|
|
2011
2061
|
type JobPayRateExceptionListChangeLogParams as JobPayRateExceptionListChangeLogParams,
|
|
2012
2062
|
};
|
|
2013
2063
|
|
|
2064
|
+
export {
|
|
2065
|
+
Agents as Agents,
|
|
2066
|
+
type AgentListResponse as AgentListResponse,
|
|
2067
|
+
type AgentCreateResponse as AgentCreateResponse,
|
|
2068
|
+
type AgentRetrieveResponse as AgentRetrieveResponse,
|
|
2069
|
+
type AgentUpdateResponse as AgentUpdateResponse,
|
|
2070
|
+
type AgentListResponsesPageCursorURL as AgentListResponsesPageCursorURL,
|
|
2071
|
+
type AgentListParams as AgentListParams,
|
|
2072
|
+
type AgentCreateParams as AgentCreateParams,
|
|
2073
|
+
type AgentUpdateParams as AgentUpdateParams,
|
|
2074
|
+
};
|
|
2075
|
+
|
|
2014
2076
|
export {
|
|
2015
2077
|
AppUsers as AppUsers,
|
|
2016
2078
|
type AppUserListResponse as AppUserListResponse,
|
|
@@ -2239,6 +2301,18 @@ export declare namespace RipplingSDK {
|
|
|
2239
2301
|
type LocationFactorListParams as LocationFactorListParams,
|
|
2240
2302
|
};
|
|
2241
2303
|
|
|
2304
|
+
export {
|
|
2305
|
+
Packages as Packages,
|
|
2306
|
+
type PackageListResponse as PackageListResponse,
|
|
2307
|
+
type PackageCreateResponse as PackageCreateResponse,
|
|
2308
|
+
type PackageRetrieveResponse as PackageRetrieveResponse,
|
|
2309
|
+
type PackageUpdateResponse as PackageUpdateResponse,
|
|
2310
|
+
type PackageListResponsesPageCursorURL as PackageListResponsesPageCursorURL,
|
|
2311
|
+
type PackageListParams as PackageListParams,
|
|
2312
|
+
type PackageCreateParams as PackageCreateParams,
|
|
2313
|
+
type PackageUpdateParams as PackageUpdateParams,
|
|
2314
|
+
};
|
|
2315
|
+
|
|
2242
2316
|
export {
|
|
2243
2317
|
PayrollRuns as PayrollRuns,
|
|
2244
2318
|
type PayrollRunListResponse as PayrollRunListResponse,
|
|
@@ -2296,6 +2370,23 @@ export declare namespace RipplingSDK {
|
|
|
2296
2370
|
type ShiftassignmentUpdateParams as ShiftassignmentUpdateParams,
|
|
2297
2371
|
};
|
|
2298
2372
|
|
|
2373
|
+
export {
|
|
2374
|
+
Sites as Sites,
|
|
2375
|
+
type SiteListResponse as SiteListResponse,
|
|
2376
|
+
type SiteCreateResponse as SiteCreateResponse,
|
|
2377
|
+
type SiteRetrieveResponse as SiteRetrieveResponse,
|
|
2378
|
+
type SiteUpdateResponse as SiteUpdateResponse,
|
|
2379
|
+
type SiteUploadBatchesResponse as SiteUploadBatchesResponse,
|
|
2380
|
+
type SiteFilesResponse as SiteFilesResponse,
|
|
2381
|
+
type SiteFileOperationsResponse as SiteFileOperationsResponse,
|
|
2382
|
+
type SiteListResponsesPageCursorURL as SiteListResponsesPageCursorURL,
|
|
2383
|
+
type SiteCreateParams as SiteCreateParams,
|
|
2384
|
+
type SiteUpdateParams as SiteUpdateParams,
|
|
2385
|
+
type SiteUploadBatchesParams as SiteUploadBatchesParams,
|
|
2386
|
+
type SiteFilesParams as SiteFilesParams,
|
|
2387
|
+
type SiteFileOperationsParams as SiteFileOperationsParams,
|
|
2388
|
+
};
|
|
2389
|
+
|
|
2299
2390
|
export {
|
|
2300
2391
|
SoftwareDeployments as SoftwareDeployments,
|
|
2301
2392
|
type SoftwareDeploymentListResponse as SoftwareDeploymentListResponse,
|
|
@@ -0,0 +1,294 @@
|
|
|
1
|
+
import type { RipplingSDK } from '../../../client';
|
|
2
|
+
import type {
|
|
3
|
+
ObjectCategory,
|
|
4
|
+
ObjectCategoryCreateParams,
|
|
5
|
+
ObjectCategoryUpdateParams,
|
|
6
|
+
} from '../../../resources/object-categories';
|
|
7
|
+
import type { CategoryApiName, LogicalCategoryName } from './types';
|
|
8
|
+
import { toCustomCategoryApiName } from './definition';
|
|
9
|
+
import { validateLogicalCategoryName } from './validation';
|
|
10
|
+
|
|
11
|
+
/**
|
|
12
|
+
* Author input accepted by {@link defineCustomObjectCategory}.
|
|
13
|
+
*
|
|
14
|
+
* @typeParam TName - Logical category name supplied by the caller.
|
|
15
|
+
*/
|
|
16
|
+
interface CustomObjectCategoryDefinitionInput<TName extends string> {
|
|
17
|
+
/** Logical unsuffixed snake_case category name. */
|
|
18
|
+
readonly name: LogicalCategoryName<TName>;
|
|
19
|
+
/** Human-readable display name applied after creation. */
|
|
20
|
+
readonly displayName: string;
|
|
21
|
+
/** Optional category description. */
|
|
22
|
+
readonly description?: string;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
/** Immutable typed category definition used by provisioning and lifecycle helpers. */
|
|
26
|
+
export interface CustomObjectCategoryDefinition<TName extends LogicalCategoryName = LogicalCategoryName> {
|
|
27
|
+
/** Logical unsuffixed snake_case category name. */
|
|
28
|
+
readonly name: TName;
|
|
29
|
+
/** Compiled wire-level category api name. */
|
|
30
|
+
readonly apiName: CategoryApiName<TName>;
|
|
31
|
+
/** Human-readable display name. */
|
|
32
|
+
readonly displayName: string;
|
|
33
|
+
/** Optional category description. */
|
|
34
|
+
readonly description?: string;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
/** Result returned by category provisioning helpers. */
|
|
38
|
+
export interface ProvisionedCustomObjectCategory<TName extends LogicalCategoryName = LogicalCategoryName> {
|
|
39
|
+
/** Source typed category definition. */
|
|
40
|
+
readonly definition: CustomObjectCategoryDefinition<TName>;
|
|
41
|
+
/** Response returned by `client.objectCategories.create(...)`. */
|
|
42
|
+
readonly createdCategory: ObjectCategory;
|
|
43
|
+
/** Response returned by `client.objectCategories.update(...)`. */
|
|
44
|
+
readonly updatedCategory: ObjectCategory;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
/** Lifecycle action emitted by category reconciliation helpers. */
|
|
48
|
+
export type CustomObjectCategoryLifecycleAction = 'created' | 'updated' | 'unchanged';
|
|
49
|
+
|
|
50
|
+
/** Result returned by category reconciliation helpers. */
|
|
51
|
+
export interface ReconciledCustomObjectCategory<TName extends LogicalCategoryName = LogicalCategoryName> {
|
|
52
|
+
/** Source typed category definition. */
|
|
53
|
+
readonly definition: CustomObjectCategoryDefinition<TName>;
|
|
54
|
+
/** Whether the remote category was created, updated, or already matched. */
|
|
55
|
+
readonly action: CustomObjectCategoryLifecycleAction;
|
|
56
|
+
/** Remote category after reconciliation. */
|
|
57
|
+
readonly category: ObjectCategory;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
/** Options for category provisioning and reconciliation helpers. */
|
|
61
|
+
export interface CustomObjectCategoryMutationOptions {
|
|
62
|
+
/** Whether to apply the follow-up display-metadata update. Defaults to `true`. */
|
|
63
|
+
readonly updateDisplayMetadata?: boolean;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
/**
|
|
67
|
+
* Creates an immutable typed custom-object category definition.
|
|
68
|
+
*
|
|
69
|
+
* @param definition - Logical category metadata to normalize and freeze.
|
|
70
|
+
* @returns Immutable typed category definition with compiled API name.
|
|
71
|
+
* @typeParam TName - Logical category name supplied by the caller.
|
|
72
|
+
*/
|
|
73
|
+
export function defineCustomObjectCategory<TName extends string>(
|
|
74
|
+
definition: CustomObjectCategoryDefinitionInput<TName>,
|
|
75
|
+
): Readonly<CustomObjectCategoryDefinition<LogicalCategoryName<TName>>> {
|
|
76
|
+
validateLogicalCategoryName(definition.name);
|
|
77
|
+
return Object.freeze({
|
|
78
|
+
name: definition.name,
|
|
79
|
+
apiName: toCustomCategoryApiName(definition.name),
|
|
80
|
+
displayName: definition.displayName,
|
|
81
|
+
...(definition.description != null ? { description: definition.description } : {}),
|
|
82
|
+
}) as Readonly<CustomObjectCategoryDefinition<LogicalCategoryName<TName>>>;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
/**
|
|
86
|
+
* Builds the low-level create payload for an object category.
|
|
87
|
+
*
|
|
88
|
+
* @param definition - Typed category definition to compile.
|
|
89
|
+
* @returns REST create payload using the logical category name.
|
|
90
|
+
* @typeParam TName - Logical category name carried by the definition.
|
|
91
|
+
*/
|
|
92
|
+
export function buildObjectCategoryCreateParams<TName extends LogicalCategoryName>(
|
|
93
|
+
definition: CustomObjectCategoryDefinition<TName>,
|
|
94
|
+
): ObjectCategoryCreateParams {
|
|
95
|
+
return {
|
|
96
|
+
name: definition.name,
|
|
97
|
+
...(definition.description != null ? { description: definition.description } : {}),
|
|
98
|
+
};
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
/**
|
|
102
|
+
* Builds the low-level update payload for an object category.
|
|
103
|
+
*
|
|
104
|
+
* @param definition - Typed category definition to compile.
|
|
105
|
+
* @returns REST update payload using human-facing display metadata.
|
|
106
|
+
* @typeParam TName - Logical category name carried by the definition.
|
|
107
|
+
*/
|
|
108
|
+
export function buildObjectCategoryUpdateParams<TName extends LogicalCategoryName>(
|
|
109
|
+
definition: CustomObjectCategoryDefinition<TName>,
|
|
110
|
+
): ObjectCategoryUpdateParams {
|
|
111
|
+
return {
|
|
112
|
+
name: definition.displayName,
|
|
113
|
+
...(definition.description != null ? { description: definition.description } : {}),
|
|
114
|
+
};
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
/**
|
|
118
|
+
* Returns whether one public category DTO matches the typed category definition by currently visible names.
|
|
119
|
+
*
|
|
120
|
+
* @param category - Public category DTO returned by the REST API.
|
|
121
|
+
* @param definition - Typed category definition being matched.
|
|
122
|
+
* @returns Whether the visible name matches either the logical or display name.
|
|
123
|
+
* @typeParam TName - Logical category name carried by the definition.
|
|
124
|
+
*/
|
|
125
|
+
function isMatchingCategoryName<TName extends LogicalCategoryName>(
|
|
126
|
+
category: ObjectCategory,
|
|
127
|
+
definition: CustomObjectCategoryDefinition<TName>,
|
|
128
|
+
): boolean {
|
|
129
|
+
return category.name === definition.name || category.name === definition.displayName;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
/**
|
|
133
|
+
* Lists all public category DTOs that ambiguously or exactly match one typed definition.
|
|
134
|
+
*
|
|
135
|
+
* @param client - SDK client used to enumerate categories.
|
|
136
|
+
* @param definition - Typed category definition being matched.
|
|
137
|
+
* @returns Frozen list of public categories whose visible names match.
|
|
138
|
+
* @typeParam TName - Logical category name carried by the definition.
|
|
139
|
+
*/
|
|
140
|
+
async function listMatchingCategories<TName extends LogicalCategoryName>(
|
|
141
|
+
client: RipplingSDK,
|
|
142
|
+
definition: CustomObjectCategoryDefinition<TName>,
|
|
143
|
+
): Promise<readonly ObjectCategory[]> {
|
|
144
|
+
const matches: ObjectCategory[] = [];
|
|
145
|
+
for await (const category of client.objectCategories.list()) {
|
|
146
|
+
if (isMatchingCategoryName(category, definition)) {
|
|
147
|
+
matches.push(category);
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
return Object.freeze(matches);
|
|
151
|
+
}
|
|
152
|
+
|
|
153
|
+
/**
|
|
154
|
+
* Returns the single public category matching one typed definition or throws when the match is ambiguous.
|
|
155
|
+
*
|
|
156
|
+
* @param client - SDK client used to enumerate categories.
|
|
157
|
+
* @param definition - Typed category definition being matched.
|
|
158
|
+
* @returns Matching public category, if any.
|
|
159
|
+
* @throws Error when multiple public categories match the visible names.
|
|
160
|
+
* @typeParam TName - Logical category name carried by the definition.
|
|
161
|
+
*/
|
|
162
|
+
async function getSingleMatchingCategory<TName extends LogicalCategoryName>(
|
|
163
|
+
client: RipplingSDK,
|
|
164
|
+
definition: CustomObjectCategoryDefinition<TName>,
|
|
165
|
+
): Promise<ObjectCategory | undefined> {
|
|
166
|
+
const matches = await listMatchingCategories(client, definition);
|
|
167
|
+
if (matches.length <= 1) return matches[0];
|
|
168
|
+
|
|
169
|
+
throw new Error(
|
|
170
|
+
`Ambiguous category match for "${definition.name}" / "${definition.displayName}". ` +
|
|
171
|
+
`Matched ids: ${matches.map((category) => category.id).join(', ')}.`,
|
|
172
|
+
);
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
/**
|
|
176
|
+
* Creates one typed custom-object category through the REST SDK.
|
|
177
|
+
*
|
|
178
|
+
* @param client - SDK client used to call the category APIs.
|
|
179
|
+
* @param definition - Typed category definition to provision.
|
|
180
|
+
* @param options - Provisioning behavior flags for display-metadata updates.
|
|
181
|
+
* @returns Frozen summary of the created and updated backend category DTOs.
|
|
182
|
+
* @typeParam TName - Logical category name carried by the definition.
|
|
183
|
+
*/
|
|
184
|
+
export async function provisionCustomObjectCategoryDefinition<TName extends LogicalCategoryName>(
|
|
185
|
+
client: RipplingSDK,
|
|
186
|
+
definition: CustomObjectCategoryDefinition<TName>,
|
|
187
|
+
options: CustomObjectCategoryMutationOptions = {},
|
|
188
|
+
): Promise<ProvisionedCustomObjectCategory<TName>> {
|
|
189
|
+
const createdCategory = await client.objectCategories.create(buildObjectCategoryCreateParams(definition));
|
|
190
|
+
const updatedCategory =
|
|
191
|
+
options.updateDisplayMetadata ?? true ?
|
|
192
|
+
await client.objectCategories.update(createdCategory.id, buildObjectCategoryUpdateParams(definition))
|
|
193
|
+
: createdCategory;
|
|
194
|
+
|
|
195
|
+
return Object.freeze({ definition, createdCategory, updatedCategory });
|
|
196
|
+
}
|
|
197
|
+
|
|
198
|
+
/**
|
|
199
|
+
* Creates multiple typed custom-object categories through the REST SDK.
|
|
200
|
+
*
|
|
201
|
+
* @param client - SDK client used to call the category APIs.
|
|
202
|
+
* @param definitions - Typed category definitions to provision.
|
|
203
|
+
* @param options - Provisioning behavior flags shared across the batch.
|
|
204
|
+
* @returns Frozen batch of provisioning results in input order.
|
|
205
|
+
*/
|
|
206
|
+
export async function provisionCustomObjectCategoryDefinitions(
|
|
207
|
+
client: RipplingSDK,
|
|
208
|
+
definitions: readonly CustomObjectCategoryDefinition[],
|
|
209
|
+
options: CustomObjectCategoryMutationOptions = {},
|
|
210
|
+
): Promise<readonly ProvisionedCustomObjectCategory[]> {
|
|
211
|
+
const results: ProvisionedCustomObjectCategory[] = [];
|
|
212
|
+
for (const definition of definitions) {
|
|
213
|
+
results.push(await provisionCustomObjectCategoryDefinition(client, definition, options));
|
|
214
|
+
}
|
|
215
|
+
return Object.freeze(results);
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
/**
|
|
219
|
+
* Reconciles one typed category definition against the backend by name.
|
|
220
|
+
*
|
|
221
|
+
* @param client - SDK client used to call the category APIs.
|
|
222
|
+
* @param definition - Typed category definition to reconcile.
|
|
223
|
+
* @param options - Reconciliation behavior flags for display-metadata updates.
|
|
224
|
+
* @returns Frozen reconciliation result describing the final backend category state.
|
|
225
|
+
* @typeParam TName - Logical category name carried by the definition.
|
|
226
|
+
*/
|
|
227
|
+
export async function reconcileCustomObjectCategoryDefinition<TName extends LogicalCategoryName>(
|
|
228
|
+
client: RipplingSDK,
|
|
229
|
+
definition: CustomObjectCategoryDefinition<TName>,
|
|
230
|
+
options: CustomObjectCategoryMutationOptions = {},
|
|
231
|
+
): Promise<ReconciledCustomObjectCategory<TName>> {
|
|
232
|
+
const existing = await getSingleMatchingCategory(client, definition);
|
|
233
|
+
if (existing == null) {
|
|
234
|
+
const provisioned = await provisionCustomObjectCategoryDefinition(client, definition, options);
|
|
235
|
+
return Object.freeze({
|
|
236
|
+
definition,
|
|
237
|
+
action: 'created' as const,
|
|
238
|
+
category: provisioned.updatedCategory,
|
|
239
|
+
});
|
|
240
|
+
}
|
|
241
|
+
|
|
242
|
+
const shouldUpdate =
|
|
243
|
+
(options.updateDisplayMetadata ?? true) &&
|
|
244
|
+
(existing.name !== definition.displayName ||
|
|
245
|
+
(existing.description ?? '') !== (definition.description ?? ''));
|
|
246
|
+
|
|
247
|
+
if (!shouldUpdate) {
|
|
248
|
+
return Object.freeze({ definition, action: 'unchanged', category: existing });
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
const updated = await client.objectCategories.update(
|
|
252
|
+
existing.id,
|
|
253
|
+
buildObjectCategoryUpdateParams(definition),
|
|
254
|
+
);
|
|
255
|
+
return Object.freeze({ definition, action: 'updated', category: updated });
|
|
256
|
+
}
|
|
257
|
+
|
|
258
|
+
/**
|
|
259
|
+
* Reconciles multiple typed category definitions against the backend by name.
|
|
260
|
+
*
|
|
261
|
+
* @param client - SDK client used to call the category APIs.
|
|
262
|
+
* @param definitions - Typed category definitions to reconcile.
|
|
263
|
+
* @param options - Reconciliation behavior flags shared across the batch.
|
|
264
|
+
* @returns Frozen batch of reconciliation results in input order.
|
|
265
|
+
*/
|
|
266
|
+
export async function reconcileCustomObjectCategoryDefinitions(
|
|
267
|
+
client: RipplingSDK,
|
|
268
|
+
definitions: readonly CustomObjectCategoryDefinition[],
|
|
269
|
+
options: CustomObjectCategoryMutationOptions = {},
|
|
270
|
+
): Promise<readonly ReconciledCustomObjectCategory[]> {
|
|
271
|
+
const results: ReconciledCustomObjectCategory[] = [];
|
|
272
|
+
for (const definition of definitions) {
|
|
273
|
+
results.push(await reconcileCustomObjectCategoryDefinition(client, definition, options));
|
|
274
|
+
}
|
|
275
|
+
return Object.freeze(results);
|
|
276
|
+
}
|
|
277
|
+
|
|
278
|
+
/**
|
|
279
|
+
* Deletes a category that matches the typed definition's logical or display name.
|
|
280
|
+
*
|
|
281
|
+
* @param client - SDK client used to call the category APIs.
|
|
282
|
+
* @param definition - Typed category definition used to find the category to delete.
|
|
283
|
+
* @returns Whether a matching category existed and was deleted.
|
|
284
|
+
* @typeParam TName - Logical category name carried by the definition.
|
|
285
|
+
*/
|
|
286
|
+
export async function deleteCustomObjectCategoryDefinition<TName extends LogicalCategoryName>(
|
|
287
|
+
client: RipplingSDK,
|
|
288
|
+
definition: CustomObjectCategoryDefinition<TName>,
|
|
289
|
+
): Promise<boolean> {
|
|
290
|
+
const existing = await getSingleMatchingCategory(client, definition);
|
|
291
|
+
if (existing == null) return false;
|
|
292
|
+
await client.objectCategories.delete(existing.id);
|
|
293
|
+
return true;
|
|
294
|
+
}
|