@scenario-labs/sdk 0.1.2
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 +33 -0
- package/LICENSE +201 -0
- package/README.md +358 -0
- 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/client.d.mts +208 -0
- package/client.d.mts.map +1 -0
- package/client.d.ts +208 -0
- package/client.d.ts.map +1 -0
- package/client.js +492 -0
- package/client.js.map +1 -0
- package/client.mjs +488 -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/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 +2 -0
- package/error.d.ts.map +1 -0
- package/error.js +6 -0
- package/error.js.map +1 -0
- package/error.mjs +2 -0
- package/error.mjs.map +1 -0
- package/index.d.mts +6 -0
- package/index.d.mts.map +1 -0
- package/index.d.ts +6 -0
- package/index.d.ts.map +1 -0
- package/index.js +30 -0
- package/index.js.map +1 -0
- package/index.mjs +7 -0
- package/index.mjs.map +1 -0
- 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 +20 -0
- package/internal/headers.d.mts.map +1 -0
- package/internal/headers.d.ts +20 -0
- package/internal/headers.d.ts.map +1 -0
- package/internal/headers.js +79 -0
- package/internal/headers.js.map +1 -0
- package/internal/headers.mjs +74 -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 +40 -0
- package/internal/parse.js.map +1 -0
- package/internal/parse.mjs +37 -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 +7 -0
- package/internal/qs/formats.d.ts.map +1 -0
- package/internal/qs/formats.js +13 -0
- package/internal/qs/formats.js.map +1 -0
- package/internal/qs/formats.mjs +9 -0
- package/internal/qs/formats.mjs.map +1 -0
- package/internal/qs/index.d.mts +10 -0
- package/internal/qs/index.d.mts.map +1 -0
- package/internal/qs/index.d.ts +10 -0
- package/internal/qs/index.d.ts.map +1 -0
- package/internal/qs/index.js +14 -0
- package/internal/qs/index.js.map +1 -0
- package/internal/qs/index.mjs +10 -0
- package/internal/qs/index.mjs.map +1 -0
- package/internal/qs/stringify.d.mts +3 -0
- package/internal/qs/stringify.d.mts.map +1 -0
- package/internal/qs/stringify.d.ts +3 -0
- package/internal/qs/stringify.d.ts.map +1 -0
- package/internal/qs/stringify.js +277 -0
- package/internal/qs/stringify.js.map +1 -0
- package/internal/qs/stringify.mjs +274 -0
- package/internal/qs/stringify.mjs.map +1 -0
- package/internal/qs/types.d.mts +57 -0
- package/internal/qs/types.d.mts.map +1 -0
- package/internal/qs/types.d.ts +57 -0
- package/internal/qs/types.d.ts.map +1 -0
- package/internal/qs/types.js +3 -0
- package/internal/qs/types.js.map +1 -0
- package/internal/qs/types.mjs +2 -0
- package/internal/qs/types.mjs.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 +15 -0
- package/internal/qs/utils.d.ts.map +1 -0
- package/internal/qs/utils.js +230 -0
- package/internal/qs/utils.js.map +1 -0
- package/internal/qs/utils.mjs +217 -0
- package/internal/qs/utils.mjs.map +1 -0
- 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/query.d.mts +2 -0
- package/internal/utils/query.d.mts.map +1 -0
- package/internal/utils/query.d.ts +2 -0
- package/internal/utils/query.d.ts.map +1 -0
- package/internal/utils/query.js +10 -0
- package/internal/utils/query.js.map +1 -0
- package/internal/utils/query.mjs +6 -0
- package/internal/utils/query.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 +8 -0
- package/internal/utils.d.mts.map +1 -0
- package/internal/utils.d.ts +8 -0
- package/internal/utils.d.ts.map +1 -0
- package/internal/utils.js +12 -0
- package/internal/utils.js.map +1 -0
- package/internal/utils.mjs +9 -0
- package/internal/utils.mjs.map +1 -0
- package/package.json +143 -0
- package/resource.d.mts +2 -0
- package/resource.d.mts.map +1 -0
- package/resource.d.ts +2 -0
- package/resource.d.ts.map +1 -0
- package/resource.js +6 -0
- package/resource.js.map +1 -0
- package/resource.mjs +2 -0
- package/resource.mjs.map +1 -0
- package/resources/assets/assets.d.mts +6397 -0
- package/resources/assets/assets.d.mts.map +1 -0
- package/resources/assets/assets.d.ts +6397 -0
- package/resources/assets/assets.d.ts.map +1 -0
- package/resources/assets/assets.js +98 -0
- package/resources/assets/assets.js.map +1 -0
- package/resources/assets/assets.mjs +93 -0
- package/resources/assets/assets.mjs.map +1 -0
- package/resources/assets/download.d.mts +87 -0
- package/resources/assets/download.d.mts.map +1 -0
- package/resources/assets/download.d.ts +87 -0
- package/resources/assets/download.d.ts.map +1 -0
- package/resources/assets/download.js +28 -0
- package/resources/assets/download.js.map +1 -0
- package/resources/assets/download.mjs +24 -0
- package/resources/assets/download.mjs.map +1 -0
- package/resources/assets/index.d.mts +4 -0
- package/resources/assets/index.d.mts.map +1 -0
- package/resources/assets/index.d.ts +4 -0
- package/resources/assets/index.d.ts.map +1 -0
- package/resources/assets/index.js +11 -0
- package/resources/assets/index.js.map +1 -0
- package/resources/assets/index.mjs +5 -0
- package/resources/assets/index.mjs.map +1 -0
- package/resources/assets/public.d.mts +1535 -0
- package/resources/assets/public.d.mts.map +1 -0
- package/resources/assets/public.d.ts +1535 -0
- package/resources/assets/public.d.ts.map +1 -0
- package/resources/assets/public.js +28 -0
- package/resources/assets/public.js.map +1 -0
- package/resources/assets/public.mjs +24 -0
- package/resources/assets/public.mjs.map +1 -0
- package/resources/assets.d.mts +2 -0
- package/resources/assets.d.mts.map +1 -0
- package/resources/assets.d.ts +2 -0
- package/resources/assets.d.ts.map +1 -0
- package/resources/assets.js +6 -0
- package/resources/assets.js.map +1 -0
- package/resources/assets.mjs +3 -0
- package/resources/assets.mjs.map +1 -0
- package/resources/collections/assets.d.mts +119 -0
- package/resources/collections/assets.d.mts.map +1 -0
- package/resources/collections/assets.d.ts +119 -0
- package/resources/collections/assets.d.ts.map +1 -0
- package/resources/collections/assets.js +22 -0
- package/resources/collections/assets.js.map +1 -0
- package/resources/collections/assets.mjs +18 -0
- package/resources/collections/assets.mjs.map +1 -0
- package/resources/collections/collections.d.mts +250 -0
- package/resources/collections/collections.d.mts.map +1 -0
- package/resources/collections/collections.d.ts +250 -0
- package/resources/collections/collections.d.ts.map +1 -0
- package/resources/collections/collections.js +52 -0
- package/resources/collections/collections.js.map +1 -0
- package/resources/collections/collections.mjs +47 -0
- package/resources/collections/collections.mjs.map +1 -0
- package/resources/collections/index.d.mts +4 -0
- package/resources/collections/index.d.mts.map +1 -0
- package/resources/collections/index.d.ts +4 -0
- package/resources/collections/index.d.ts.map +1 -0
- package/resources/collections/index.js +11 -0
- package/resources/collections/index.js.map +1 -0
- package/resources/collections/index.mjs +5 -0
- package/resources/collections/index.mjs.map +1 -0
- package/resources/collections/models.d.mts +119 -0
- package/resources/collections/models.d.mts.map +1 -0
- package/resources/collections/models.d.ts +119 -0
- package/resources/collections/models.d.ts.map +1 -0
- package/resources/collections/models.js +22 -0
- package/resources/collections/models.js.map +1 -0
- package/resources/collections/models.mjs +18 -0
- package/resources/collections/models.mjs.map +1 -0
- package/resources/collections.d.mts +2 -0
- package/resources/collections.d.mts.map +1 -0
- package/resources/collections.d.ts +2 -0
- package/resources/collections.d.ts.map +1 -0
- package/resources/collections.js +6 -0
- package/resources/collections.js.map +1 -0
- package/resources/collections.mjs +3 -0
- package/resources/collections.mjs.map +1 -0
- package/resources/generate.d.mts +3804 -0
- package/resources/generate.d.mts.map +1 -0
- package/resources/generate.d.ts +3804 -0
- package/resources/generate.d.ts.map +1 -0
- package/resources/generate.js +70 -0
- package/resources/generate.js.map +1 -0
- package/resources/generate.mjs +66 -0
- package/resources/generate.mjs.map +1 -0
- package/resources/index.d.mts +12 -0
- package/resources/index.d.mts.map +1 -0
- package/resources/index.d.ts +12 -0
- package/resources/index.d.ts.map +1 -0
- package/resources/index.js +27 -0
- package/resources/index.js.map +1 -0
- package/resources/index.mjs +13 -0
- package/resources/index.mjs.map +1 -0
- package/resources/jobs.d.mts +1191 -0
- package/resources/jobs.d.mts.map +1 -0
- package/resources/jobs.d.ts +1191 -0
- package/resources/jobs.d.ts.map +1 -0
- package/resources/jobs.js +31 -0
- package/resources/jobs.js.map +1 -0
- package/resources/jobs.mjs +27 -0
- package/resources/jobs.mjs.map +1 -0
- package/resources/models/description.d.mts +490 -0
- package/resources/models/description.d.mts.map +1 -0
- package/resources/models/description.d.ts +490 -0
- package/resources/models/description.d.ts.map +1 -0
- package/resources/models/description.js +27 -0
- package/resources/models/description.js.map +1 -0
- package/resources/models/description.mjs +23 -0
- package/resources/models/description.mjs.map +1 -0
- package/resources/models/examples.d.mts +2819 -0
- package/resources/models/examples.d.mts.map +1 -0
- package/resources/models/examples.d.ts +2819 -0
- package/resources/models/examples.d.ts.map +1 -0
- package/resources/models/examples.js +27 -0
- package/resources/models/examples.js.map +1 -0
- package/resources/models/examples.mjs +23 -0
- package/resources/models/examples.mjs.map +1 -0
- package/resources/models/index.d.mts +6 -0
- package/resources/models/index.d.mts.map +1 -0
- package/resources/models/index.d.ts +6 -0
- package/resources/models/index.d.ts.map +1 -0
- package/resources/models/index.js +15 -0
- package/resources/models/index.js.map +1 -0
- package/resources/models/index.mjs +7 -0
- package/resources/models/index.mjs.map +1 -0
- package/resources/models/models.d.mts +6676 -0
- package/resources/models/models.d.mts.map +1 -0
- package/resources/models/models.d.ts +6676 -0
- package/resources/models/models.d.ts.map +1 -0
- package/resources/models/models.js +107 -0
- package/resources/models/models.js.map +1 -0
- package/resources/models/models.mjs +102 -0
- package/resources/models/models.mjs.map +1 -0
- package/resources/models/train.d.mts +2334 -0
- package/resources/models/train.d.mts.map +1 -0
- package/resources/models/train.d.ts +2334 -0
- package/resources/models/train.d.ts.map +1 -0
- package/resources/models/train.js +27 -0
- package/resources/models/train.js.map +1 -0
- package/resources/models/train.mjs +23 -0
- package/resources/models/train.mjs.map +1 -0
- package/resources/models/training-images.d.mts +214 -0
- package/resources/models/training-images.d.mts.map +1 -0
- package/resources/models/training-images.d.ts +214 -0
- package/resources/models/training-images.d.ts.map +1 -0
- package/resources/models/training-images.js +46 -0
- package/resources/models/training-images.js.map +1 -0
- package/resources/models/training-images.mjs +42 -0
- package/resources/models/training-images.mjs.map +1 -0
- package/resources/models.d.mts +2 -0
- package/resources/models.d.mts.map +1 -0
- package/resources/models.d.ts +2 -0
- package/resources/models.d.ts.map +1 -0
- package/resources/models.js +6 -0
- package/resources/models.js.map +1 -0
- package/resources/models.mjs +3 -0
- package/resources/models.mjs.map +1 -0
- package/resources/oscu.d.mts +25 -0
- package/resources/oscu.d.mts.map +1 -0
- package/resources/oscu.d.ts +25 -0
- package/resources/oscu.d.ts.map +1 -0
- package/resources/oscu.js +16 -0
- package/resources/oscu.js.map +1 -0
- package/resources/oscu.mjs +12 -0
- package/resources/oscu.mjs.map +1 -0
- package/resources/search.d.mts +595 -0
- package/resources/search.d.mts.map +1 -0
- package/resources/search.d.ts +595 -0
- package/resources/search.d.ts.map +1 -0
- package/resources/search.js +29 -0
- package/resources/search.js.map +1 -0
- package/resources/search.mjs +25 -0
- package/resources/search.mjs.map +1 -0
- package/resources/tags.d.mts +55 -0
- package/resources/tags.d.mts.map +1 -0
- package/resources/tags.d.ts +55 -0
- package/resources/tags.d.ts.map +1 -0
- package/resources/tags.js +15 -0
- package/resources/tags.js.map +1 -0
- package/resources/tags.mjs +11 -0
- package/resources/tags.mjs.map +1 -0
- package/resources/uploads.d.mts +250 -0
- package/resources/uploads.d.mts.map +1 -0
- package/resources/uploads.d.ts +250 -0
- package/resources/uploads.d.ts.map +1 -0
- package/resources/uploads.js +29 -0
- package/resources/uploads.js.map +1 -0
- package/resources/uploads.mjs +25 -0
- package/resources/uploads.mjs.map +1 -0
- package/resources/usages.d.mts +760 -0
- package/resources/usages.d.mts.map +1 -0
- package/resources/usages.d.ts +760 -0
- package/resources/usages.d.ts.map +1 -0
- package/resources/usages.js +17 -0
- package/resources/usages.js.map +1 -0
- package/resources/usages.mjs +13 -0
- package/resources/usages.mjs.map +1 -0
- package/resources/workflows.d.mts +4539 -0
- package/resources/workflows.d.mts.map +1 -0
- package/resources/workflows.d.ts +4539 -0
- package/resources/workflows.d.ts.map +1 -0
- package/resources/workflows.js +64 -0
- package/resources/workflows.js.map +1 -0
- package/resources/workflows.mjs +60 -0
- package/resources/workflows.mjs.map +1 -0
- package/resources.d.mts +2 -0
- package/resources.d.mts.map +1 -0
- package/resources.d.ts +2 -0
- package/resources.d.ts.map +1 -0
- package/resources.js +5 -0
- package/resources.js.map +1 -0
- package/resources.mjs +2 -0
- package/resources.mjs.map +1 -0
- package/src/api-promise.ts +2 -0
- package/src/client.ts +999 -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/resource.ts +11 -0
- package/src/core/uploads.ts +2 -0
- package/src/error.ts +2 -0
- package/src/index.ts +22 -0
- 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 +97 -0
- package/src/internal/parse.ts +56 -0
- package/src/internal/qs/LICENSE.md +13 -0
- package/src/internal/qs/README.md +3 -0
- package/src/internal/qs/formats.ts +10 -0
- package/src/internal/qs/index.ts +13 -0
- package/src/internal/qs/stringify.ts +385 -0
- package/src/internal/qs/types.ts +71 -0
- package/src/internal/qs/utils.ts +265 -0
- 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/query.ts +7 -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 +9 -0
- package/src/lib/.keep +4 -0
- package/src/resource.ts +2 -0
- package/src/resources/assets/assets.ts +9939 -0
- package/src/resources/assets/download.ts +138 -0
- package/src/resources/assets/index.ts +41 -0
- package/src/resources/assets/public.ts +2329 -0
- package/src/resources/assets.ts +3 -0
- package/src/resources/collections/assets.ts +163 -0
- package/src/resources/collections/collections.ts +357 -0
- package/src/resources/collections/index.ts +27 -0
- package/src/resources/collections/models.ts +163 -0
- package/src/resources/collections.ts +3 -0
- package/src/resources/generate.ts +5478 -0
- package/src/resources/index.ts +122 -0
- package/src/resources/jobs.ts +1712 -0
- package/src/resources/models/description.ts +800 -0
- package/src/resources/models/examples.ts +4125 -0
- package/src/resources/models/index.ts +58 -0
- package/src/resources/models/models.ts +8619 -0
- package/src/resources/models/train.ts +3034 -0
- package/src/resources/models/training-images.ts +304 -0
- package/src/resources/models.ts +3 -0
- package/src/resources/oscu.ts +35 -0
- package/src/resources/search.ts +731 -0
- package/src/resources/tags.ts +69 -0
- package/src/resources/uploads.ts +369 -0
- package/src/resources/usages.ts +1242 -0
- package/src/resources/workflows.ts +6019 -0
- package/src/resources.ts +1 -0
- package/src/tsconfig.json +11 -0
- package/src/uploads.ts +2 -0
- package/src/version.ts +1 -0
- package/uploads.d.mts +2 -0
- package/uploads.d.mts.map +1 -0
- package/uploads.d.ts +2 -0
- package/uploads.d.ts.map +1 -0
- package/uploads.js +6 -0
- package/uploads.js.map +1 -0
- package/uploads.mjs +2 -0
- package/uploads.mjs.map +1 -0
- package/version.d.mts +2 -0
- package/version.d.mts.map +1 -0
- package/version.d.ts +2 -0
- package/version.d.ts.map +1 -0
- package/version.js +5 -0
- package/version.js.map +1 -0
- package/version.mjs +2 -0
- package/version.mjs.map +1 -0
|
@@ -0,0 +1,250 @@
|
|
|
1
|
+
import { APIResource } from "../../core/resource.mjs";
|
|
2
|
+
import * as AssetsAPI from "./assets.mjs";
|
|
3
|
+
import { AssetAddParams, AssetAddResponse, AssetRemoveParams, AssetRemoveResponse, Assets } from "./assets.mjs";
|
|
4
|
+
import * as ModelsAPI from "./models.mjs";
|
|
5
|
+
import { ModelAddParams, ModelAddResponse, ModelRemoveParams, ModelRemoveResponse, Models } from "./models.mjs";
|
|
6
|
+
import { APIPromise } from "../../core/api-promise.mjs";
|
|
7
|
+
import { RequestOptions } from "../../internal/request-options.mjs";
|
|
8
|
+
export declare class Collections extends APIResource {
|
|
9
|
+
assets: AssetsAPI.Assets;
|
|
10
|
+
models: ModelsAPI.Models;
|
|
11
|
+
/**
|
|
12
|
+
* Create a new collection
|
|
13
|
+
*/
|
|
14
|
+
create(body: CollectionCreateParams, options?: RequestOptions): APIPromise<CollectionCreateResponse>;
|
|
15
|
+
/**
|
|
16
|
+
* Get the details of a collection
|
|
17
|
+
*/
|
|
18
|
+
retrieve(collectionID: string, options?: RequestOptions): APIPromise<CollectionRetrieveResponse>;
|
|
19
|
+
/**
|
|
20
|
+
* Update the name and/or thumbnail of a Collection
|
|
21
|
+
*/
|
|
22
|
+
update(collectionID: string, body: CollectionUpdateParams, options?: RequestOptions): APIPromise<CollectionUpdateResponse>;
|
|
23
|
+
/**
|
|
24
|
+
* List collections of a team
|
|
25
|
+
*/
|
|
26
|
+
list(query?: CollectionListParams | null | undefined, options?: RequestOptions): APIPromise<CollectionListResponse>;
|
|
27
|
+
/**
|
|
28
|
+
* Delete a collection
|
|
29
|
+
*/
|
|
30
|
+
delete(collectionID: string, options?: RequestOptions): APIPromise<unknown>;
|
|
31
|
+
}
|
|
32
|
+
export interface CollectionCreateResponse {
|
|
33
|
+
collection: CollectionCreateResponse.Collection;
|
|
34
|
+
}
|
|
35
|
+
export declare namespace CollectionCreateResponse {
|
|
36
|
+
interface Collection {
|
|
37
|
+
/**
|
|
38
|
+
* The collection ID (example: "asset_GTrL3mq4SXWyMxkOHRxlpw")
|
|
39
|
+
*/
|
|
40
|
+
id: string;
|
|
41
|
+
assetCount: number;
|
|
42
|
+
/**
|
|
43
|
+
* The collection creation date as an ISO string (example:
|
|
44
|
+
* "2023-02-03T11:19:41.579Z")
|
|
45
|
+
*/
|
|
46
|
+
createdAt: string;
|
|
47
|
+
itemCount: number;
|
|
48
|
+
modelCount: number;
|
|
49
|
+
/**
|
|
50
|
+
* The collection name
|
|
51
|
+
*/
|
|
52
|
+
name: string;
|
|
53
|
+
/**
|
|
54
|
+
* The owner ID (example: "dcf121faaa1a0a0bbbd9ca1b73d62aea")
|
|
55
|
+
*/
|
|
56
|
+
ownerId: string;
|
|
57
|
+
/**
|
|
58
|
+
* The collection last update date as an ISO string (example:
|
|
59
|
+
* "2023-02-03T11:19:41.579Z")
|
|
60
|
+
*/
|
|
61
|
+
updatedAt: string;
|
|
62
|
+
/**
|
|
63
|
+
* The thumbnail for the collection (if any)
|
|
64
|
+
*/
|
|
65
|
+
thumbnail?: Collection.Thumbnail;
|
|
66
|
+
}
|
|
67
|
+
namespace Collection {
|
|
68
|
+
/**
|
|
69
|
+
* The thumbnail for the collection (if any)
|
|
70
|
+
*/
|
|
71
|
+
interface Thumbnail {
|
|
72
|
+
assetId: string;
|
|
73
|
+
url: string;
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
export interface CollectionRetrieveResponse {
|
|
78
|
+
collection: CollectionRetrieveResponse.Collection;
|
|
79
|
+
}
|
|
80
|
+
export declare namespace CollectionRetrieveResponse {
|
|
81
|
+
interface Collection {
|
|
82
|
+
/**
|
|
83
|
+
* The collection ID (example: "asset_GTrL3mq4SXWyMxkOHRxlpw")
|
|
84
|
+
*/
|
|
85
|
+
id: string;
|
|
86
|
+
assetCount: number;
|
|
87
|
+
/**
|
|
88
|
+
* The collection creation date as an ISO string (example:
|
|
89
|
+
* "2023-02-03T11:19:41.579Z")
|
|
90
|
+
*/
|
|
91
|
+
createdAt: string;
|
|
92
|
+
itemCount: number;
|
|
93
|
+
modelCount: number;
|
|
94
|
+
/**
|
|
95
|
+
* The collection name
|
|
96
|
+
*/
|
|
97
|
+
name: string;
|
|
98
|
+
/**
|
|
99
|
+
* The owner ID (example: "dcf121faaa1a0a0bbbd9ca1b73d62aea")
|
|
100
|
+
*/
|
|
101
|
+
ownerId: string;
|
|
102
|
+
/**
|
|
103
|
+
* The collection last update date as an ISO string (example:
|
|
104
|
+
* "2023-02-03T11:19:41.579Z")
|
|
105
|
+
*/
|
|
106
|
+
updatedAt: string;
|
|
107
|
+
/**
|
|
108
|
+
* The thumbnail for the collection (if any)
|
|
109
|
+
*/
|
|
110
|
+
thumbnail?: Collection.Thumbnail;
|
|
111
|
+
}
|
|
112
|
+
namespace Collection {
|
|
113
|
+
/**
|
|
114
|
+
* The thumbnail for the collection (if any)
|
|
115
|
+
*/
|
|
116
|
+
interface Thumbnail {
|
|
117
|
+
assetId: string;
|
|
118
|
+
url: string;
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
export interface CollectionUpdateResponse {
|
|
123
|
+
collection: CollectionUpdateResponse.Collection;
|
|
124
|
+
}
|
|
125
|
+
export declare namespace CollectionUpdateResponse {
|
|
126
|
+
interface Collection {
|
|
127
|
+
/**
|
|
128
|
+
* The collection ID (example: "asset_GTrL3mq4SXWyMxkOHRxlpw")
|
|
129
|
+
*/
|
|
130
|
+
id: string;
|
|
131
|
+
assetCount: number;
|
|
132
|
+
/**
|
|
133
|
+
* The collection creation date as an ISO string (example:
|
|
134
|
+
* "2023-02-03T11:19:41.579Z")
|
|
135
|
+
*/
|
|
136
|
+
createdAt: string;
|
|
137
|
+
itemCount: number;
|
|
138
|
+
modelCount: number;
|
|
139
|
+
/**
|
|
140
|
+
* The collection name
|
|
141
|
+
*/
|
|
142
|
+
name: string;
|
|
143
|
+
/**
|
|
144
|
+
* The owner ID (example: "dcf121faaa1a0a0bbbd9ca1b73d62aea")
|
|
145
|
+
*/
|
|
146
|
+
ownerId: string;
|
|
147
|
+
/**
|
|
148
|
+
* The collection last update date as an ISO string (example:
|
|
149
|
+
* "2023-02-03T11:19:41.579Z")
|
|
150
|
+
*/
|
|
151
|
+
updatedAt: string;
|
|
152
|
+
/**
|
|
153
|
+
* The thumbnail for the collection (if any)
|
|
154
|
+
*/
|
|
155
|
+
thumbnail?: Collection.Thumbnail;
|
|
156
|
+
}
|
|
157
|
+
namespace Collection {
|
|
158
|
+
/**
|
|
159
|
+
* The thumbnail for the collection (if any)
|
|
160
|
+
*/
|
|
161
|
+
interface Thumbnail {
|
|
162
|
+
assetId: string;
|
|
163
|
+
url: string;
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
export interface CollectionListResponse {
|
|
168
|
+
collections: Array<CollectionListResponse.Collection>;
|
|
169
|
+
/**
|
|
170
|
+
* A token to query the next page of collections
|
|
171
|
+
*/
|
|
172
|
+
nextPaginationToken?: string;
|
|
173
|
+
}
|
|
174
|
+
export declare namespace CollectionListResponse {
|
|
175
|
+
interface Collection {
|
|
176
|
+
/**
|
|
177
|
+
* The collection ID (example: "asset_GTrL3mq4SXWyMxkOHRxlpw")
|
|
178
|
+
*/
|
|
179
|
+
id: string;
|
|
180
|
+
assetCount: number;
|
|
181
|
+
/**
|
|
182
|
+
* The collection creation date as an ISO string (example:
|
|
183
|
+
* "2023-02-03T11:19:41.579Z")
|
|
184
|
+
*/
|
|
185
|
+
createdAt: string;
|
|
186
|
+
itemCount: number;
|
|
187
|
+
modelCount: number;
|
|
188
|
+
/**
|
|
189
|
+
* The collection name
|
|
190
|
+
*/
|
|
191
|
+
name: string;
|
|
192
|
+
/**
|
|
193
|
+
* The owner ID (example: "dcf121faaa1a0a0bbbd9ca1b73d62aea")
|
|
194
|
+
*/
|
|
195
|
+
ownerId: string;
|
|
196
|
+
/**
|
|
197
|
+
* The collection last update date as an ISO string (example:
|
|
198
|
+
* "2023-02-03T11:19:41.579Z")
|
|
199
|
+
*/
|
|
200
|
+
updatedAt: string;
|
|
201
|
+
/**
|
|
202
|
+
* The thumbnail for the collection (if any)
|
|
203
|
+
*/
|
|
204
|
+
thumbnail?: Collection.Thumbnail;
|
|
205
|
+
}
|
|
206
|
+
namespace Collection {
|
|
207
|
+
/**
|
|
208
|
+
* The thumbnail for the collection (if any)
|
|
209
|
+
*/
|
|
210
|
+
interface Thumbnail {
|
|
211
|
+
assetId: string;
|
|
212
|
+
url: string;
|
|
213
|
+
}
|
|
214
|
+
}
|
|
215
|
+
}
|
|
216
|
+
export type CollectionDeleteResponse = unknown;
|
|
217
|
+
export interface CollectionCreateParams {
|
|
218
|
+
/**
|
|
219
|
+
* The name of the collection.
|
|
220
|
+
*/
|
|
221
|
+
name: string;
|
|
222
|
+
}
|
|
223
|
+
export interface CollectionUpdateParams {
|
|
224
|
+
/**
|
|
225
|
+
* The new name for the Collection
|
|
226
|
+
*/
|
|
227
|
+
name?: string;
|
|
228
|
+
/**
|
|
229
|
+
* The AssetId of the image you want to use as a thumbnail for the collection. Set
|
|
230
|
+
* to null to unset the thumbnail.
|
|
231
|
+
*/
|
|
232
|
+
thumbnail?: string;
|
|
233
|
+
}
|
|
234
|
+
export interface CollectionListParams {
|
|
235
|
+
/**
|
|
236
|
+
* The number of items to return in the response. The default value is 10, maximum
|
|
237
|
+
* value is 100, minimum value is 1
|
|
238
|
+
*/
|
|
239
|
+
pageSize?: string;
|
|
240
|
+
/**
|
|
241
|
+
* A token you received in a previous request to query the next page of items
|
|
242
|
+
*/
|
|
243
|
+
paginationToken?: string;
|
|
244
|
+
}
|
|
245
|
+
export declare namespace Collections {
|
|
246
|
+
export { type CollectionCreateResponse as CollectionCreateResponse, type CollectionRetrieveResponse as CollectionRetrieveResponse, type CollectionUpdateResponse as CollectionUpdateResponse, type CollectionListResponse as CollectionListResponse, type CollectionDeleteResponse as CollectionDeleteResponse, type CollectionCreateParams as CollectionCreateParams, type CollectionUpdateParams as CollectionUpdateParams, type CollectionListParams as CollectionListParams, };
|
|
247
|
+
export { Assets as Assets, type AssetAddResponse as AssetAddResponse, type AssetRemoveResponse as AssetRemoveResponse, type AssetAddParams as AssetAddParams, type AssetRemoveParams as AssetRemoveParams, };
|
|
248
|
+
export { Models as Models, type ModelAddResponse as ModelAddResponse, type ModelRemoveResponse as ModelRemoveResponse, type ModelAddParams as ModelAddParams, type ModelRemoveParams as ModelRemoveParams, };
|
|
249
|
+
}
|
|
250
|
+
//# sourceMappingURL=collections.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"collections.d.mts","sourceRoot":"","sources":["../../src/resources/collections/collections.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,SAAS;OACd,EAAE,cAAc,EAAE,gBAAgB,EAAE,iBAAiB,EAAE,mBAAmB,EAAE,MAAM,EAAE;OACpF,KAAK,SAAS;OACd,EAAE,cAAc,EAAE,gBAAgB,EAAE,iBAAiB,EAAE,mBAAmB,EAAE,MAAM,EAAE;OACpF,EAAE,UAAU,EAAE;OACd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AC,EAAE,MAAM,CAAC;CAC1B;AAKD,MAAM,CAAC,OAAO,WAAW,WAAW,CAAC;IACnC,OAAO,EACL,KAAK,wBAAwB,IAAI,wBAAwB,EACzD,KAAK,0BAA0B,IAAI,0BAA0B,EAC7D,KAAK,wBAAwB,IAAI,wBAAwB,EACzD,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,wBAAwB,IAAI,wBAAwB,EACzD,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,oBAAoB,IAAI,oBAAoB,GAClD,CAAC;IAEF,OAAO,EACL,MAAM,IAAI,MAAM,EAChB,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,cAAc,IAAI,cAAc,EACrC,KAAK,iBAAiB,IAAI,iBAAiB,GAC5C,CAAC;IAEF,OAAO,EACL,MAAM,IAAI,MAAM,EAChB,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,cAAc,IAAI,cAAc,EACrC,KAAK,iBAAiB,IAAI,iBAAiB,GAC5C,CAAC;CACH"}
|
|
@@ -0,0 +1,250 @@
|
|
|
1
|
+
import { APIResource } from "../../core/resource.js";
|
|
2
|
+
import * as AssetsAPI from "./assets.js";
|
|
3
|
+
import { AssetAddParams, AssetAddResponse, AssetRemoveParams, AssetRemoveResponse, Assets } from "./assets.js";
|
|
4
|
+
import * as ModelsAPI from "./models.js";
|
|
5
|
+
import { ModelAddParams, ModelAddResponse, ModelRemoveParams, ModelRemoveResponse, Models } from "./models.js";
|
|
6
|
+
import { APIPromise } from "../../core/api-promise.js";
|
|
7
|
+
import { RequestOptions } from "../../internal/request-options.js";
|
|
8
|
+
export declare class Collections extends APIResource {
|
|
9
|
+
assets: AssetsAPI.Assets;
|
|
10
|
+
models: ModelsAPI.Models;
|
|
11
|
+
/**
|
|
12
|
+
* Create a new collection
|
|
13
|
+
*/
|
|
14
|
+
create(body: CollectionCreateParams, options?: RequestOptions): APIPromise<CollectionCreateResponse>;
|
|
15
|
+
/**
|
|
16
|
+
* Get the details of a collection
|
|
17
|
+
*/
|
|
18
|
+
retrieve(collectionID: string, options?: RequestOptions): APIPromise<CollectionRetrieveResponse>;
|
|
19
|
+
/**
|
|
20
|
+
* Update the name and/or thumbnail of a Collection
|
|
21
|
+
*/
|
|
22
|
+
update(collectionID: string, body: CollectionUpdateParams, options?: RequestOptions): APIPromise<CollectionUpdateResponse>;
|
|
23
|
+
/**
|
|
24
|
+
* List collections of a team
|
|
25
|
+
*/
|
|
26
|
+
list(query?: CollectionListParams | null | undefined, options?: RequestOptions): APIPromise<CollectionListResponse>;
|
|
27
|
+
/**
|
|
28
|
+
* Delete a collection
|
|
29
|
+
*/
|
|
30
|
+
delete(collectionID: string, options?: RequestOptions): APIPromise<unknown>;
|
|
31
|
+
}
|
|
32
|
+
export interface CollectionCreateResponse {
|
|
33
|
+
collection: CollectionCreateResponse.Collection;
|
|
34
|
+
}
|
|
35
|
+
export declare namespace CollectionCreateResponse {
|
|
36
|
+
interface Collection {
|
|
37
|
+
/**
|
|
38
|
+
* The collection ID (example: "asset_GTrL3mq4SXWyMxkOHRxlpw")
|
|
39
|
+
*/
|
|
40
|
+
id: string;
|
|
41
|
+
assetCount: number;
|
|
42
|
+
/**
|
|
43
|
+
* The collection creation date as an ISO string (example:
|
|
44
|
+
* "2023-02-03T11:19:41.579Z")
|
|
45
|
+
*/
|
|
46
|
+
createdAt: string;
|
|
47
|
+
itemCount: number;
|
|
48
|
+
modelCount: number;
|
|
49
|
+
/**
|
|
50
|
+
* The collection name
|
|
51
|
+
*/
|
|
52
|
+
name: string;
|
|
53
|
+
/**
|
|
54
|
+
* The owner ID (example: "dcf121faaa1a0a0bbbd9ca1b73d62aea")
|
|
55
|
+
*/
|
|
56
|
+
ownerId: string;
|
|
57
|
+
/**
|
|
58
|
+
* The collection last update date as an ISO string (example:
|
|
59
|
+
* "2023-02-03T11:19:41.579Z")
|
|
60
|
+
*/
|
|
61
|
+
updatedAt: string;
|
|
62
|
+
/**
|
|
63
|
+
* The thumbnail for the collection (if any)
|
|
64
|
+
*/
|
|
65
|
+
thumbnail?: Collection.Thumbnail;
|
|
66
|
+
}
|
|
67
|
+
namespace Collection {
|
|
68
|
+
/**
|
|
69
|
+
* The thumbnail for the collection (if any)
|
|
70
|
+
*/
|
|
71
|
+
interface Thumbnail {
|
|
72
|
+
assetId: string;
|
|
73
|
+
url: string;
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
export interface CollectionRetrieveResponse {
|
|
78
|
+
collection: CollectionRetrieveResponse.Collection;
|
|
79
|
+
}
|
|
80
|
+
export declare namespace CollectionRetrieveResponse {
|
|
81
|
+
interface Collection {
|
|
82
|
+
/**
|
|
83
|
+
* The collection ID (example: "asset_GTrL3mq4SXWyMxkOHRxlpw")
|
|
84
|
+
*/
|
|
85
|
+
id: string;
|
|
86
|
+
assetCount: number;
|
|
87
|
+
/**
|
|
88
|
+
* The collection creation date as an ISO string (example:
|
|
89
|
+
* "2023-02-03T11:19:41.579Z")
|
|
90
|
+
*/
|
|
91
|
+
createdAt: string;
|
|
92
|
+
itemCount: number;
|
|
93
|
+
modelCount: number;
|
|
94
|
+
/**
|
|
95
|
+
* The collection name
|
|
96
|
+
*/
|
|
97
|
+
name: string;
|
|
98
|
+
/**
|
|
99
|
+
* The owner ID (example: "dcf121faaa1a0a0bbbd9ca1b73d62aea")
|
|
100
|
+
*/
|
|
101
|
+
ownerId: string;
|
|
102
|
+
/**
|
|
103
|
+
* The collection last update date as an ISO string (example:
|
|
104
|
+
* "2023-02-03T11:19:41.579Z")
|
|
105
|
+
*/
|
|
106
|
+
updatedAt: string;
|
|
107
|
+
/**
|
|
108
|
+
* The thumbnail for the collection (if any)
|
|
109
|
+
*/
|
|
110
|
+
thumbnail?: Collection.Thumbnail;
|
|
111
|
+
}
|
|
112
|
+
namespace Collection {
|
|
113
|
+
/**
|
|
114
|
+
* The thumbnail for the collection (if any)
|
|
115
|
+
*/
|
|
116
|
+
interface Thumbnail {
|
|
117
|
+
assetId: string;
|
|
118
|
+
url: string;
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
export interface CollectionUpdateResponse {
|
|
123
|
+
collection: CollectionUpdateResponse.Collection;
|
|
124
|
+
}
|
|
125
|
+
export declare namespace CollectionUpdateResponse {
|
|
126
|
+
interface Collection {
|
|
127
|
+
/**
|
|
128
|
+
* The collection ID (example: "asset_GTrL3mq4SXWyMxkOHRxlpw")
|
|
129
|
+
*/
|
|
130
|
+
id: string;
|
|
131
|
+
assetCount: number;
|
|
132
|
+
/**
|
|
133
|
+
* The collection creation date as an ISO string (example:
|
|
134
|
+
* "2023-02-03T11:19:41.579Z")
|
|
135
|
+
*/
|
|
136
|
+
createdAt: string;
|
|
137
|
+
itemCount: number;
|
|
138
|
+
modelCount: number;
|
|
139
|
+
/**
|
|
140
|
+
* The collection name
|
|
141
|
+
*/
|
|
142
|
+
name: string;
|
|
143
|
+
/**
|
|
144
|
+
* The owner ID (example: "dcf121faaa1a0a0bbbd9ca1b73d62aea")
|
|
145
|
+
*/
|
|
146
|
+
ownerId: string;
|
|
147
|
+
/**
|
|
148
|
+
* The collection last update date as an ISO string (example:
|
|
149
|
+
* "2023-02-03T11:19:41.579Z")
|
|
150
|
+
*/
|
|
151
|
+
updatedAt: string;
|
|
152
|
+
/**
|
|
153
|
+
* The thumbnail for the collection (if any)
|
|
154
|
+
*/
|
|
155
|
+
thumbnail?: Collection.Thumbnail;
|
|
156
|
+
}
|
|
157
|
+
namespace Collection {
|
|
158
|
+
/**
|
|
159
|
+
* The thumbnail for the collection (if any)
|
|
160
|
+
*/
|
|
161
|
+
interface Thumbnail {
|
|
162
|
+
assetId: string;
|
|
163
|
+
url: string;
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
export interface CollectionListResponse {
|
|
168
|
+
collections: Array<CollectionListResponse.Collection>;
|
|
169
|
+
/**
|
|
170
|
+
* A token to query the next page of collections
|
|
171
|
+
*/
|
|
172
|
+
nextPaginationToken?: string;
|
|
173
|
+
}
|
|
174
|
+
export declare namespace CollectionListResponse {
|
|
175
|
+
interface Collection {
|
|
176
|
+
/**
|
|
177
|
+
* The collection ID (example: "asset_GTrL3mq4SXWyMxkOHRxlpw")
|
|
178
|
+
*/
|
|
179
|
+
id: string;
|
|
180
|
+
assetCount: number;
|
|
181
|
+
/**
|
|
182
|
+
* The collection creation date as an ISO string (example:
|
|
183
|
+
* "2023-02-03T11:19:41.579Z")
|
|
184
|
+
*/
|
|
185
|
+
createdAt: string;
|
|
186
|
+
itemCount: number;
|
|
187
|
+
modelCount: number;
|
|
188
|
+
/**
|
|
189
|
+
* The collection name
|
|
190
|
+
*/
|
|
191
|
+
name: string;
|
|
192
|
+
/**
|
|
193
|
+
* The owner ID (example: "dcf121faaa1a0a0bbbd9ca1b73d62aea")
|
|
194
|
+
*/
|
|
195
|
+
ownerId: string;
|
|
196
|
+
/**
|
|
197
|
+
* The collection last update date as an ISO string (example:
|
|
198
|
+
* "2023-02-03T11:19:41.579Z")
|
|
199
|
+
*/
|
|
200
|
+
updatedAt: string;
|
|
201
|
+
/**
|
|
202
|
+
* The thumbnail for the collection (if any)
|
|
203
|
+
*/
|
|
204
|
+
thumbnail?: Collection.Thumbnail;
|
|
205
|
+
}
|
|
206
|
+
namespace Collection {
|
|
207
|
+
/**
|
|
208
|
+
* The thumbnail for the collection (if any)
|
|
209
|
+
*/
|
|
210
|
+
interface Thumbnail {
|
|
211
|
+
assetId: string;
|
|
212
|
+
url: string;
|
|
213
|
+
}
|
|
214
|
+
}
|
|
215
|
+
}
|
|
216
|
+
export type CollectionDeleteResponse = unknown;
|
|
217
|
+
export interface CollectionCreateParams {
|
|
218
|
+
/**
|
|
219
|
+
* The name of the collection.
|
|
220
|
+
*/
|
|
221
|
+
name: string;
|
|
222
|
+
}
|
|
223
|
+
export interface CollectionUpdateParams {
|
|
224
|
+
/**
|
|
225
|
+
* The new name for the Collection
|
|
226
|
+
*/
|
|
227
|
+
name?: string;
|
|
228
|
+
/**
|
|
229
|
+
* The AssetId of the image you want to use as a thumbnail for the collection. Set
|
|
230
|
+
* to null to unset the thumbnail.
|
|
231
|
+
*/
|
|
232
|
+
thumbnail?: string;
|
|
233
|
+
}
|
|
234
|
+
export interface CollectionListParams {
|
|
235
|
+
/**
|
|
236
|
+
* The number of items to return in the response. The default value is 10, maximum
|
|
237
|
+
* value is 100, minimum value is 1
|
|
238
|
+
*/
|
|
239
|
+
pageSize?: string;
|
|
240
|
+
/**
|
|
241
|
+
* A token you received in a previous request to query the next page of items
|
|
242
|
+
*/
|
|
243
|
+
paginationToken?: string;
|
|
244
|
+
}
|
|
245
|
+
export declare namespace Collections {
|
|
246
|
+
export { type CollectionCreateResponse as CollectionCreateResponse, type CollectionRetrieveResponse as CollectionRetrieveResponse, type CollectionUpdateResponse as CollectionUpdateResponse, type CollectionListResponse as CollectionListResponse, type CollectionDeleteResponse as CollectionDeleteResponse, type CollectionCreateParams as CollectionCreateParams, type CollectionUpdateParams as CollectionUpdateParams, type CollectionListParams as CollectionListParams, };
|
|
247
|
+
export { Assets as Assets, type AssetAddResponse as AssetAddResponse, type AssetRemoveResponse as AssetRemoveResponse, type AssetAddParams as AssetAddParams, type AssetRemoveParams as AssetRemoveParams, };
|
|
248
|
+
export { Models as Models, type ModelAddResponse as ModelAddResponse, type ModelRemoveResponse as ModelRemoveResponse, type ModelAddParams as ModelAddParams, type ModelRemoveParams as ModelRemoveParams, };
|
|
249
|
+
}
|
|
250
|
+
//# sourceMappingURL=collections.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"collections.d.ts","sourceRoot":"","sources":["../../src/resources/collections/collections.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,SAAS;OACd,EAAE,cAA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IAAI,CAAC,EAAE,MAAM,CAAC;IAEd;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,oBAAoB;IACnC;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAElB;;OAEG;IACH,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B;AAKD,MAAM,CAAC,OAAO,WAAW,WAAW,CAAC;IACnC,OAAO,EACL,KAAK,wBAAwB,IAAI,wBAAwB,EACzD,KAAK,0BAA0B,IAAI,0BAA0B,EAC7D,KAAK,wBAAwB,IAAI,wBAAwB,EACzD,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,wBAAwB,IAAI,wBAAwB,EACzD,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,oBAAoB,IAAI,oBAAoB,GAClD,CAAC;IAEF,OAAO,EACL,MAAM,IAAI,MAAM,EAChB,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,cAAc,IAAI,cAAc,EACrC,KAAK,iBAAiB,IAAI,iBAAiB,GAC5C,CAAC;IAEF,OAAO,EACL,MAAM,IAAI,MAAM,EAChB,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,cAAc,IAAI,cAAc,EACrC,KAAK,iBAAiB,IAAI,iBAAiB,GAC5C,CAAC;CACH"}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.Collections = void 0;
|
|
5
|
+
const tslib_1 = require("../../internal/tslib.js");
|
|
6
|
+
const resource_1 = require("../../core/resource.js");
|
|
7
|
+
const AssetsAPI = tslib_1.__importStar(require("./assets.js"));
|
|
8
|
+
const assets_1 = require("./assets.js");
|
|
9
|
+
const ModelsAPI = tslib_1.__importStar(require("./models.js"));
|
|
10
|
+
const models_1 = require("./models.js");
|
|
11
|
+
const path_1 = require("../../internal/utils/path.js");
|
|
12
|
+
class Collections extends resource_1.APIResource {
|
|
13
|
+
constructor() {
|
|
14
|
+
super(...arguments);
|
|
15
|
+
this.assets = new AssetsAPI.Assets(this._client);
|
|
16
|
+
this.models = new ModelsAPI.Models(this._client);
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* Create a new collection
|
|
20
|
+
*/
|
|
21
|
+
create(body, options) {
|
|
22
|
+
return this._client.post('/collections', { body, ...options });
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* Get the details of a collection
|
|
26
|
+
*/
|
|
27
|
+
retrieve(collectionID, options) {
|
|
28
|
+
return this._client.get((0, path_1.path) `/collections/${collectionID}`, options);
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* Update the name and/or thumbnail of a Collection
|
|
32
|
+
*/
|
|
33
|
+
update(collectionID, body, options) {
|
|
34
|
+
return this._client.put((0, path_1.path) `/collections/${collectionID}`, { body, ...options });
|
|
35
|
+
}
|
|
36
|
+
/**
|
|
37
|
+
* List collections of a team
|
|
38
|
+
*/
|
|
39
|
+
list(query = {}, options) {
|
|
40
|
+
return this._client.get('/collections', { query, ...options });
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* Delete a collection
|
|
44
|
+
*/
|
|
45
|
+
delete(collectionID, options) {
|
|
46
|
+
return this._client.delete((0, path_1.path) `/collections/${collectionID}`, options);
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
exports.Collections = Collections;
|
|
50
|
+
Collections.Assets = assets_1.Assets;
|
|
51
|
+
Collections.Models = models_1.Models;
|
|
52
|
+
//# sourceMappingURL=collections.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"collections.js","sourceRoot":"","sources":["../../src/resources/collections/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AAC,CAAC;IAC1E,CAAC;CACF;AA7CD,kCA6CC;AA8QD,WAAW,CAAC,MAAM,GAAG,eAAM,CAAC;AAC5B,WAAW,CAAC,MAAM,GAAG,eAAM,CAAC"}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
import { APIResource } from "../../core/resource.mjs";
|
|
3
|
+
import * as AssetsAPI from "./assets.mjs";
|
|
4
|
+
import { Assets } from "./assets.mjs";
|
|
5
|
+
import * as ModelsAPI from "./models.mjs";
|
|
6
|
+
import { Models } from "./models.mjs";
|
|
7
|
+
import { path } from "../../internal/utils/path.mjs";
|
|
8
|
+
export class Collections extends APIResource {
|
|
9
|
+
constructor() {
|
|
10
|
+
super(...arguments);
|
|
11
|
+
this.assets = new AssetsAPI.Assets(this._client);
|
|
12
|
+
this.models = new ModelsAPI.Models(this._client);
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* Create a new collection
|
|
16
|
+
*/
|
|
17
|
+
create(body, options) {
|
|
18
|
+
return this._client.post('/collections', { body, ...options });
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* Get the details of a collection
|
|
22
|
+
*/
|
|
23
|
+
retrieve(collectionID, options) {
|
|
24
|
+
return this._client.get(path `/collections/${collectionID}`, options);
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* Update the name and/or thumbnail of a Collection
|
|
28
|
+
*/
|
|
29
|
+
update(collectionID, body, options) {
|
|
30
|
+
return this._client.put(path `/collections/${collectionID}`, { body, ...options });
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* List collections of a team
|
|
34
|
+
*/
|
|
35
|
+
list(query = {}, options) {
|
|
36
|
+
return this._client.get('/collections', { query, ...options });
|
|
37
|
+
}
|
|
38
|
+
/**
|
|
39
|
+
* Delete a collection
|
|
40
|
+
*/
|
|
41
|
+
delete(collectionID, options) {
|
|
42
|
+
return this._client.delete(path `/collections/${collectionID}`, options);
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
Collections.Assets = Assets;
|
|
46
|
+
Collections.Models = Models;
|
|
47
|
+
//# sourceMappingURL=collections.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"collections.mjs","sourceRoot":"","sources":["../../src/resources/collections/collections.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OACf,KAAK,SAAS;OACd,EAA4E,MAAM,EAAE;OACpF,KAAK,SAAS;OACd,EAA4E,MAAM,EAAE;OAGpF,EAAE,IAAI,EAAE;AAEf,MAAM,OAAO,WAAY,SAAQ,WAAW;IAA5C;;QACE,WAAM,GAAqB,IAAI,SAAS,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;QAC9D,WAAM,GAAqB,IAAI,SAAS,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IA2ChE,CAAC;IAzCC;;OAEG;IACH,MAAM,CAAC,IAA4B,EAAE,OAAwB;QAC3D,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,cAAc,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACjE,CAAC;IAED;;OAEG;IACH,QAAQ,CAAC,YAAoB,EAAE,OAAwB;QACrD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAA,gBAAgB,YAAY,EAAE,EAAE,OAAO,CAAC,CAAC;IACvE,CAAC;IAED;;OAEG;IACH,MAAM,CACJ,YAAoB,EACpB,IAA4B,EAC5B,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAA,gBAAgB,YAAY,EAAE,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACpF,CAAC;IAED;;OAEG;IACH,IAAI,CACF,QAAiD,EAAE,EACnD,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,cAAc,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACjE,CAAC;IAED;;OAEG;IACH,MAAM,CAAC,YAAoB,EAAE,OAAwB;QACnD,OAAO,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,IAAI,CAAA,gBAAgB,YAAY,EAAE,EAAE,OAAO,CAAC,CAAC;IAC1E,CAAC;CACF;AA8QD,WAAW,CAAC,MAAM,GAAG,MAAM,CAAC;AAC5B,WAAW,CAAC,MAAM,GAAG,MAAM,CAAC"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export { Assets, type AssetAddResponse, type AssetRemoveResponse, type AssetAddParams, type AssetRemoveParams, } from "./assets.mjs";
|
|
2
|
+
export { Collections, type CollectionCreateResponse, type CollectionRetrieveResponse, type CollectionUpdateResponse, type CollectionListResponse, type CollectionDeleteResponse, type CollectionCreateParams, type CollectionUpdateParams, type CollectionListParams, } from "./collections.mjs";
|
|
3
|
+
export { Models, type ModelAddResponse, type ModelRemoveResponse, type ModelAddParams, type ModelRemoveParams, } from "./models.mjs";
|
|
4
|
+
//# sourceMappingURL=index.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../../src/resources/collections/index.ts"],"names":[],"mappings":"OAEO,EACL,MAAM,EACN,KAAK,gBAAgB,EACrB,KAAK,mBAAmB,EACxB,KAAK,cAAc,EACnB,KAAK,iBAAiB,GACvB;OACM,EACL,WAAW,EACX,KAAK,wBAAwB,EAC7B,KAAK,0BAA0B,EAC/B,KAAK,wBAAwB,EAC7B,KAAK,sBAAsB,EAC3B,KAAK,wBAAwB,EAC7B,KAAK,sBAAsB,EAC3B,KAAK,sBAAsB,EAC3B,KAAK,oBAAoB,GAC1B;OACM,EACL,MAAM,EACN,KAAK,gBAAgB,EACrB,KAAK,mBAAmB,EACxB,KAAK,cAAc,EACnB,KAAK,iBAAiB,GACvB"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export { Assets, type AssetAddResponse, type AssetRemoveResponse, type AssetAddParams, type AssetRemoveParams, } from "./assets.js";
|
|
2
|
+
export { Collections, type CollectionCreateResponse, type CollectionRetrieveResponse, type CollectionUpdateResponse, type CollectionListResponse, type CollectionDeleteResponse, type CollectionCreateParams, type CollectionUpdateParams, type CollectionListParams, } from "./collections.js";
|
|
3
|
+
export { Models, type ModelAddResponse, type ModelRemoveResponse, type ModelAddParams, type ModelRemoveParams, } from "./models.js";
|
|
4
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/resources/collections/index.ts"],"names":[],"mappings":"OAEO,EACL,MAAM,EACN,KAAK,gBAAgB,EACrB,KAAK,mBAAmB,EACxB,KAAK,cAAc,EACnB,KAAK,iBAAiB,GACvB;OACM,EACL,WAAW,EACX,KAAK,wBAAwB,EAC7B,KAAK,0BAA0B,EAC/B,KAAK,wBAAwB,EAC7B,KAAK,sBAAsB,EAC3B,KAAK,wBAAwB,EAC7B,KAAK,sBAAsB,EAC3B,KAAK,sBAAsB,EAC3B,KAAK,oBAAoB,GAC1B;OACM,EACL,MAAM,EACN,KAAK,gBAAgB,EACrB,KAAK,mBAAmB,EACxB,KAAK,cAAc,EACnB,KAAK,iBAAiB,GACvB"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.Models = exports.Collections = exports.Assets = void 0;
|
|
5
|
+
var assets_1 = require("./assets.js");
|
|
6
|
+
Object.defineProperty(exports, "Assets", { enumerable: true, get: function () { return assets_1.Assets; } });
|
|
7
|
+
var collections_1 = require("./collections.js");
|
|
8
|
+
Object.defineProperty(exports, "Collections", { enumerable: true, get: function () { return collections_1.Collections; } });
|
|
9
|
+
var models_1 = require("./models.js");
|
|
10
|
+
Object.defineProperty(exports, "Models", { enumerable: true, get: function () { return models_1.Models; } });
|
|
11
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/resources/collections/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,sCAMkB;AALhB,gGAAA,MAAM,OAAA;AAMR,gDAUuB;AATrB,0GAAA,WAAW,OAAA;AAUb,sCAMkB;AALhB,gGAAA,MAAM,OAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../src/resources/collections/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EACL,MAAM,GAKP;OACM,EACL,WAAW,GASZ;OACM,EACL,MAAM,GAKP"}
|