@calmlens/sdk 0.16.0 → 0.16.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -1
- package/cjs/{CalmLensConnection-CPdx_acA.js → CalmLensConnection-BNUHp_AQ.js} +2 -2
- package/cjs/{CalmLensUtils-DvhY8-cU.js → CalmLensUtils-o171ownK.js} +7 -7
- package/cjs/{CalmLensVersion-CrlGk2gX.js → CalmLensVersion-DwhgxQK5.js} +1 -1
- package/cjs/{CalmLensWebhooks-C2VrleZm.js → CalmLensWebhooks-BKrq30Yp.js} +5 -5
- package/cjs/{Classification-DJU_DfOO.d.ts → Classification-BNhgwGEm-DmA9VEuE.d.ts} +497 -256
- package/cjs/{TestTriggers-CxFZ-3uz.d.ts → TestTriggers-CRKtulyp-vrzEq2wm.d.ts} +3 -2
- package/cjs/{WebhookPayload-BfUmVu2y.d.ts → WebhookPayload-CJoIkGBD.d.ts} +943 -479
- package/cjs/app.d.ts +3 -3
- package/cjs/app.js +3 -3
- package/cjs/{index-VxklV9OQ.d.ts → index-C9Xw1aid.d.ts} +137 -142
- package/cjs/index.d.ts +3 -3
- package/cjs/index.js +1 -1
- package/cjs/server.d.ts +3 -3
- package/cjs/server.js +4 -5
- package/cjs/test-inputs.d.ts +1 -1
- package/cjs/test-inputs.js +1 -1
- package/cjs/testing.d.ts +5 -3
- package/cjs/testing.js +7956 -135
- package/esm/{CalmLensConnection-DYo5U2L0.js → CalmLensConnection-XTqmlwzG.js} +2 -2
- package/esm/{CalmLensUtils-BDtpOfho.js → CalmLensUtils-DsF8Aa_x.js} +7 -7
- package/esm/{CalmLensVersion-CchG7NWy.js → CalmLensVersion-DcifRKsx.js} +1 -1
- package/esm/{CalmLensWebhooks-B7nQMCHx.js → CalmLensWebhooks-BvGyk5d3.js} +5 -5
- package/esm/{Classification-DJU_DfOO.d.ts → Classification-BNhgwGEm-DmA9VEuE.d.ts} +497 -256
- package/esm/{TestTriggers-CxFZ-3uz.d.ts → TestTriggers-CRKtulyp-vrzEq2wm.d.ts} +3 -2
- package/esm/{WebhookPayload-BfUmVu2y.d.ts → WebhookPayload-CJoIkGBD.d.ts} +943 -479
- package/esm/app.d.ts +3 -3
- package/esm/app.js +3 -3
- package/esm/{index-VxklV9OQ.d.ts → index-C9Xw1aid.d.ts} +137 -142
- package/esm/index.d.ts +3 -3
- package/esm/index.js +1 -1
- package/esm/server.d.ts +3 -3
- package/esm/server.js +4 -5
- package/esm/test-inputs.d.ts +1 -1
- package/esm/test-inputs.js +1 -1
- package/esm/testing.d.ts +5 -3
- package/esm/testing.js +7927 -106
- package/package.json +7 -6
package/cjs/app.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { $ as SearchAssetsOptions, A as DeleteAssetContentOptions, At as AssetSearchQuery, B as Lens, C as CdnAssetUrlOptions, Ct as EventType, D as CreateAssetSignedUrlOptions, Dt as Order, E as ConnectionOptions, Et as CursorPage, F as IdempotencyOptions, Ft as ImageData, G as ModerateTextOptions, H as ListAssetChildrenOptions, I as ImageTransform, It as MetadataItem, J as MultipartUploadOptions, K as MoveAssetOptions, L as ImageTransformOptions, Lt as PreviewImage, M as EnsureLensOptions, Mt as AssetSafetyHold, N as EnsureLensesOptions, Nt as AssetSafetyHoldReason, O as CreateFolderOptions, Ot as LensType, P as FolderIdOptions, Pt as ExtractedText, Q as RetryAssetOptions, R as IterateAssetChildrenOptions, Rt as ProcessingOptions, S as CalmLensServerClientOptions, St as EventSeverity, T as CdnTransform, Tt as Folder, U as ListAssetsOptions, V as LensTransform, W as ListEventsOptions, X as RequestOptions, Y as MultipartUploadPartOptions, Z as RetrieveAssetOptions, _ as AssetSearchResponse, _t as TypedEvent, a as AssetChildrenPage, at as UpdateFolderOptions, b as AssetVisibility, bt as EventFactValues, c as AssetContentRemovalReason, ct as UploadedAsset, d as AssetModerationAction, dt as WebhookHeadersInput, et as SignUploadTokenOptions, f as AssetModerationStatus, ft as WebhookPayloadInput, g as AssetReviewerAction, gt as EventAsset, h as AssetProcessingStatus, i as AssetChecksums, it as UpdateAssetOptions, j as DeleteAssetOptions, k as CreateMultipartUploadPartOptions, kt as AssetSearchMatchField, l as AssetContentStatus, lt as VerifyWebhookSignatureOptions, m as AssetProcessing, nt as SignedUrl, o as AssetContent, ot as UploadAssetPartOptions, p as AssetPage, pt as GetEventsResponse, q as MoveFolderOptions, r as Asset, rt as SubmitAssetOptions, s as AssetContentOptions, st as UploadPresetSubmitAssetOptions, t as ReceivedWebhookEventPayload, tt as SignedUploadToken, u as AssetModeration, ut as WaitForAssetDecisionOptions, v as AssetSearchResult, vt as EventCategory, w as CdnServeOptions, x as CalmLensAppClientOptions, xt as EventFacts, y as AssetType, yt as EventFact, z as IterateAssetsOptions } from "./WebhookPayload-
|
|
2
|
-
import { a as
|
|
3
|
-
import {
|
|
1
|
+
import { $ as SearchAssetsOptions, A as DeleteAssetContentOptions, At as AssetSearchQuery, B as Lens, C as CdnAssetUrlOptions, Ct as EventType, D as CreateAssetSignedUrlOptions, Dt as Order, E as ConnectionOptions, Et as CursorPage, F as IdempotencyOptions, Ft as ImageData, G as ModerateTextOptions, H as ListAssetChildrenOptions, I as ImageTransform, It as MetadataItem, J as MultipartUploadOptions, K as MoveAssetOptions, L as ImageTransformOptions, Lt as PreviewImage, M as EnsureLensOptions, Mt as AssetSafetyHold, N as EnsureLensesOptions, Nt as AssetSafetyHoldReason, O as CreateFolderOptions, Ot as LensType, P as FolderIdOptions, Pt as ExtractedText, Q as RetryAssetOptions, R as IterateAssetChildrenOptions, Rt as ProcessingOptions, S as CalmLensServerClientOptions, St as EventSeverity, T as CdnTransform, Tt as Folder, U as ListAssetsOptions, V as LensTransform, W as ListEventsOptions, X as RequestOptions, Y as MultipartUploadPartOptions, Z as RetrieveAssetOptions, _ as AssetSearchResponse, _t as TypedEvent, a as AssetChildrenPage, at as UpdateFolderOptions, b as AssetVisibility, bt as EventFactValues, c as AssetContentRemovalReason, ct as UploadedAsset, d as AssetModerationAction, dt as WebhookHeadersInput, et as SignUploadTokenOptions, f as AssetModerationStatus, ft as WebhookPayloadInput, g as AssetReviewerAction, gt as EventAsset, h as AssetProcessingStatus, i as AssetChecksums, it as UpdateAssetOptions, j as DeleteAssetOptions, k as CreateMultipartUploadPartOptions, kt as AssetSearchMatchField, l as AssetContentStatus, lt as VerifyWebhookSignatureOptions, m as AssetProcessing, nt as SignedUrl, o as AssetContent, ot as UploadAssetPartOptions, p as AssetPage, pt as GetEventsResponse, q as MoveFolderOptions, r as Asset, rt as SubmitAssetOptions, s as AssetContentOptions, st as UploadPresetSubmitAssetOptions, t as ReceivedWebhookEventPayload, tt as SignedUploadToken, u as AssetModeration, ut as WaitForAssetDecisionOptions, v as AssetSearchResult, vt as EventCategory, w as CdnServeOptions, x as CalmLensAppClientOptions, xt as EventFacts, y as AssetType, yt as EventFact, z as IterateAssetsOptions } from "./WebhookPayload-CJoIkGBD.js";
|
|
2
|
+
import { _ as ApiErrorCode, a as DetectedPerson, c as ProcessingFeatureStage, d as CALMLENS_ERROR_CODES, f as CalmLensError, g as SdkErrorCode, h as CalmLensErrorOptions, i as DetectedFace, l as ProcessingFeatures, m as CalmLensErrorDetails, n as AgeRange, o as ProcessingFeatureId, p as CalmLensErrorCode, r as BoundingBox, s as ProcessingFeatureResults, t as FlaggedContentPolicy, u as SDK_VERSION } from "./index-C9Xw1aid.js";
|
|
3
|
+
import { a as ClassificationNotEvaluatedReason, c as FlaggedContentAction, i as ClassificationLabel, l as Likelihood, n as ClassificationCategory, o as ClassificationQualifierResults, r as ClassificationCategoryReport, s as ClassificationReport, t as ClassificationCategories, u as ModerationQualifier } from "./Classification-BNhgwGEm-DmA9VEuE.js";
|
|
4
4
|
//#region src/client/CalmLensAppClient.d.ts
|
|
5
5
|
declare const inspectSymbol: unique symbol;
|
|
6
6
|
/**
|
package/cjs/app.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_CalmLensVersion = require("./CalmLensVersion-
|
|
2
|
+
const require_CalmLensVersion = require("./CalmLensVersion-DwhgxQK5.js");
|
|
3
3
|
require("./index.js");
|
|
4
|
-
const require_CalmLensUtils = require("./CalmLensUtils-
|
|
5
|
-
const require_CalmLensConnection = require("./CalmLensConnection-
|
|
4
|
+
const require_CalmLensUtils = require("./CalmLensUtils-o171ownK.js");
|
|
5
|
+
const require_CalmLensConnection = require("./CalmLensConnection-BNUHp_AQ.js");
|
|
6
6
|
//#region src/client/CalmLensAppClient.ts
|
|
7
7
|
const inspectSymbol = Symbol.for("nodejs.util.inspect.custom");
|
|
8
8
|
/**
|
|
@@ -1,145 +1,6 @@
|
|
|
1
|
-
import "./WebhookPayload-
|
|
2
|
-
import "./Classification-
|
|
1
|
+
import "./WebhookPayload-CJoIkGBD.js";
|
|
2
|
+
import "./Classification-BNhgwGEm-DmA9VEuE.js";
|
|
3
3
|
import * as zod from "zod";
|
|
4
|
-
//#region ../shared/src/ProcessingFeatures.d.ts
|
|
5
|
-
/**
|
|
6
|
-
* Optional analyses a request can turn on with `processingOptions.features.<id>`. The catalog is
|
|
7
|
-
* the single source for the request and result schemas, cache keys and metering. Features are
|
|
8
|
-
* chosen per request only; there is no project-level default.
|
|
9
|
-
*/
|
|
10
|
-
/** How mature a feature is. Beta results may change shape. */
|
|
11
|
-
declare const PROCESSING_FEATURE_STAGES: readonly ["beta", "ga"];
|
|
12
|
-
type ProcessingFeatureStage = (typeof PROCESSING_FEATURE_STAGES)[number];
|
|
13
|
-
declare const PROCESSING_FEATURE_IDS: readonly ["ocr", "personDetection", "faceDetection"];
|
|
14
|
-
type ProcessingFeatureId = (typeof PROCESSING_FEATURE_IDS)[number];
|
|
15
|
-
declare const PROCESSING_FEATURES_SCHEMA: zod.ZodObject<{
|
|
16
|
-
ocr: zod.ZodOptional<zod.ZodNullable<zod.ZodObject<{
|
|
17
|
-
enabled: zod.ZodBoolean;
|
|
18
|
-
}, zod.core.$strict>>>;
|
|
19
|
-
personDetection: zod.ZodOptional<zod.ZodNullable<zod.ZodObject<{
|
|
20
|
-
enabled: zod.ZodBoolean;
|
|
21
|
-
}, zod.core.$strict>>>;
|
|
22
|
-
faceDetection: zod.ZodOptional<zod.ZodNullable<zod.ZodObject<{
|
|
23
|
-
enabled: zod.ZodBoolean;
|
|
24
|
-
ageEstimation: zod.ZodOptional<zod.ZodBoolean>;
|
|
25
|
-
}, zod.core.$strict>>>;
|
|
26
|
-
}, zod.core.$strict>;
|
|
27
|
-
type ProcessingFeatures = zod.infer<typeof PROCESSING_FEATURES_SCHEMA>;
|
|
28
|
-
/** Position and size as fractions of the image width and height, from 0 to 1. */
|
|
29
|
-
declare const BOUNDING_BOX_SCHEMA: zod.ZodObject<{
|
|
30
|
-
left: zod.ZodNumber;
|
|
31
|
-
top: zod.ZodNumber;
|
|
32
|
-
width: zod.ZodNumber;
|
|
33
|
-
height: zod.ZodNumber;
|
|
34
|
-
}, zod.core.$strict>;
|
|
35
|
-
type BoundingBox = zod.infer<typeof BOUNDING_BOX_SCHEMA>;
|
|
36
|
-
declare const AGE_RANGE_SCHEMA: zod.ZodObject<{
|
|
37
|
-
low: zod.ZodNumber;
|
|
38
|
-
high: zod.ZodNumber;
|
|
39
|
-
}, zod.core.$strict>;
|
|
40
|
-
type AgeRange = zod.infer<typeof AGE_RANGE_SCHEMA>;
|
|
41
|
-
declare const DETECTED_PERSON_SCHEMA: zod.ZodObject<{
|
|
42
|
-
box: zod.ZodObject<{
|
|
43
|
-
left: zod.ZodNumber;
|
|
44
|
-
top: zod.ZodNumber;
|
|
45
|
-
width: zod.ZodNumber;
|
|
46
|
-
height: zod.ZodNumber;
|
|
47
|
-
}, zod.core.$strict>;
|
|
48
|
-
confidence: zod.ZodNumber;
|
|
49
|
-
}, zod.core.$strict>;
|
|
50
|
-
type DetectedPerson = zod.infer<typeof DETECTED_PERSON_SCHEMA>;
|
|
51
|
-
declare const DETECTED_FACE_SCHEMA: zod.ZodObject<{
|
|
52
|
-
box: zod.ZodObject<{
|
|
53
|
-
left: zod.ZodNumber;
|
|
54
|
-
top: zod.ZodNumber;
|
|
55
|
-
width: zod.ZodNumber;
|
|
56
|
-
height: zod.ZodNumber;
|
|
57
|
-
}, zod.core.$strict>;
|
|
58
|
-
confidence: zod.ZodNumber;
|
|
59
|
-
ageRange: zod.ZodOptional<zod.ZodObject<{
|
|
60
|
-
low: zod.ZodNumber;
|
|
61
|
-
high: zod.ZodNumber;
|
|
62
|
-
}, zod.core.$strict>>;
|
|
63
|
-
}, zod.core.$strict>;
|
|
64
|
-
type DetectedFace = zod.infer<typeof DETECTED_FACE_SCHEMA>;
|
|
65
|
-
declare const PROCESSING_FEATURE_RESULTS_SCHEMA: zod.ZodObject<{
|
|
66
|
-
personDetection: zod.ZodOptional<zod.ZodDiscriminatedUnion<[zod.ZodObject<{
|
|
67
|
-
status: zod.ZodLiteral<"evaluated">;
|
|
68
|
-
stage: zod.ZodEnum<{
|
|
69
|
-
beta: "beta";
|
|
70
|
-
ga: "ga";
|
|
71
|
-
}>;
|
|
72
|
-
people: zod.ZodArray<zod.ZodObject<{
|
|
73
|
-
box: zod.ZodObject<{
|
|
74
|
-
left: zod.ZodNumber;
|
|
75
|
-
top: zod.ZodNumber;
|
|
76
|
-
width: zod.ZodNumber;
|
|
77
|
-
height: zod.ZodNumber;
|
|
78
|
-
}, zod.core.$strict>;
|
|
79
|
-
confidence: zod.ZodNumber;
|
|
80
|
-
}, zod.core.$strict>>;
|
|
81
|
-
}, zod.core.$strict>, zod.ZodObject<{
|
|
82
|
-
status: zod.ZodLiteral<"not-evaluated">;
|
|
83
|
-
stage: zod.ZodEnum<{
|
|
84
|
-
beta: "beta";
|
|
85
|
-
ga: "ga";
|
|
86
|
-
}>;
|
|
87
|
-
reason: zod.ZodEnum<{
|
|
88
|
-
"not-supported": "not-supported";
|
|
89
|
-
unavailable: "unavailable";
|
|
90
|
-
}>;
|
|
91
|
-
}, zod.core.$strict>], "status">>;
|
|
92
|
-
faceDetection: zod.ZodOptional<zod.ZodDiscriminatedUnion<[zod.ZodObject<{
|
|
93
|
-
status: zod.ZodLiteral<"evaluated">;
|
|
94
|
-
stage: zod.ZodEnum<{
|
|
95
|
-
beta: "beta";
|
|
96
|
-
ga: "ga";
|
|
97
|
-
}>;
|
|
98
|
-
faces: zod.ZodArray<zod.ZodObject<{
|
|
99
|
-
box: zod.ZodObject<{
|
|
100
|
-
left: zod.ZodNumber;
|
|
101
|
-
top: zod.ZodNumber;
|
|
102
|
-
width: zod.ZodNumber;
|
|
103
|
-
height: zod.ZodNumber;
|
|
104
|
-
}, zod.core.$strict>;
|
|
105
|
-
confidence: zod.ZodNumber;
|
|
106
|
-
ageRange: zod.ZodOptional<zod.ZodObject<{
|
|
107
|
-
low: zod.ZodNumber;
|
|
108
|
-
high: zod.ZodNumber;
|
|
109
|
-
}, zod.core.$strict>>;
|
|
110
|
-
}, zod.core.$strict>>;
|
|
111
|
-
}, zod.core.$strict>, zod.ZodObject<{
|
|
112
|
-
status: zod.ZodLiteral<"not-evaluated">;
|
|
113
|
-
stage: zod.ZodEnum<{
|
|
114
|
-
beta: "beta";
|
|
115
|
-
ga: "ga";
|
|
116
|
-
}>;
|
|
117
|
-
reason: zod.ZodEnum<{
|
|
118
|
-
"not-supported": "not-supported";
|
|
119
|
-
unavailable: "unavailable";
|
|
120
|
-
}>;
|
|
121
|
-
}, zod.core.$strict>], "status">>;
|
|
122
|
-
}, zod.core.$strict>;
|
|
123
|
-
type ProcessingFeatureResults = zod.infer<typeof PROCESSING_FEATURE_RESULTS_SCHEMA>;
|
|
124
|
-
//#endregion
|
|
125
|
-
//#region ../shared/src/Project.d.ts
|
|
126
|
-
declare const FLAGGED_CONTENT_ACTION_SCHEMA: zod.ZodEnum<{
|
|
127
|
-
alert: "alert";
|
|
128
|
-
hide: "hide";
|
|
129
|
-
ignore: "ignore";
|
|
130
|
-
purge: "purge";
|
|
131
|
-
}>;
|
|
132
|
-
type FlaggedContentAction = zod.infer<typeof FLAGGED_CONTENT_ACTION_SCHEMA>;
|
|
133
|
-
declare const FLAGGED_CONTENT_POLICY_SCHEMA: zod.ZodObject<{
|
|
134
|
-
action: zod.ZodEnum<{
|
|
135
|
-
alert: "alert";
|
|
136
|
-
hide: "hide";
|
|
137
|
-
ignore: "ignore";
|
|
138
|
-
purge: "purge";
|
|
139
|
-
}>;
|
|
140
|
-
}, zod.core.$strip>;
|
|
141
|
-
type FlaggedContentPolicy = zod.infer<typeof FLAGGED_CONTENT_POLICY_SCHEMA>;
|
|
142
|
-
//#endregion
|
|
143
4
|
//#region src/client/CalmLensErrorCodes.d.ts
|
|
144
5
|
/** Error codes the CalmLens API documents, by name. */
|
|
145
6
|
declare const API_ERROR_CODES: {
|
|
@@ -378,4 +239,138 @@ declare class CalmLensError extends Error {
|
|
|
378
239
|
/** This SDK's version, from its package.json. */
|
|
379
240
|
declare const SDK_VERSION: string;
|
|
380
241
|
//#endregion
|
|
381
|
-
|
|
242
|
+
//#region src/contract/ProcessingFeatures.d.ts
|
|
243
|
+
//#region packages/shared/src/ProcessingFeatures.d.ts
|
|
244
|
+
/**
|
|
245
|
+
* Optional analyses a request can turn on with `processingOptions.features.<id>`. The catalog is
|
|
246
|
+
* the single source for the request and result schemas, cache keys and metering. Features are
|
|
247
|
+
* chosen per request only; there is no project-level default.
|
|
248
|
+
*/
|
|
249
|
+
/** How mature a feature is. Beta results may change shape. */
|
|
250
|
+
declare const PROCESSING_FEATURE_STAGES: readonly ["beta", "ga"];
|
|
251
|
+
type ProcessingFeatureStage = (typeof PROCESSING_FEATURE_STAGES)[number];
|
|
252
|
+
declare const PROCESSING_FEATURE_IDS: readonly ["ocr", "personDetection", "faceDetection"];
|
|
253
|
+
type ProcessingFeatureId = (typeof PROCESSING_FEATURE_IDS)[number];
|
|
254
|
+
declare const PROCESSING_FEATURES_SCHEMA: zod.ZodObject<{
|
|
255
|
+
ocr: zod.ZodOptional<zod.ZodNullable<zod.ZodObject<{
|
|
256
|
+
enabled: zod.ZodBoolean;
|
|
257
|
+
}, zod.core.$strict>>>;
|
|
258
|
+
personDetection: zod.ZodOptional<zod.ZodNullable<zod.ZodObject<{
|
|
259
|
+
enabled: zod.ZodBoolean;
|
|
260
|
+
}, zod.core.$strict>>>;
|
|
261
|
+
faceDetection: zod.ZodOptional<zod.ZodNullable<zod.ZodObject<{
|
|
262
|
+
enabled: zod.ZodBoolean;
|
|
263
|
+
ageEstimation: zod.ZodOptional<zod.ZodBoolean>;
|
|
264
|
+
}, zod.core.$strict>>>;
|
|
265
|
+
}, zod.core.$strict>;
|
|
266
|
+
type ProcessingFeatures = zod.infer<typeof PROCESSING_FEATURES_SCHEMA>;
|
|
267
|
+
/** Position and size as fractions of the image width and height, from 0 to 1. */
|
|
268
|
+
declare const BOUNDING_BOX_SCHEMA: zod.ZodObject<{
|
|
269
|
+
left: zod.ZodNumber;
|
|
270
|
+
top: zod.ZodNumber;
|
|
271
|
+
width: zod.ZodNumber;
|
|
272
|
+
height: zod.ZodNumber;
|
|
273
|
+
}, zod.core.$strict>;
|
|
274
|
+
type BoundingBox = zod.infer<typeof BOUNDING_BOX_SCHEMA>;
|
|
275
|
+
declare const AGE_RANGE_SCHEMA: zod.ZodObject<{
|
|
276
|
+
low: zod.ZodNumber;
|
|
277
|
+
high: zod.ZodNumber;
|
|
278
|
+
}, zod.core.$strict>;
|
|
279
|
+
type AgeRange = zod.infer<typeof AGE_RANGE_SCHEMA>;
|
|
280
|
+
declare const DETECTED_PERSON_SCHEMA: zod.ZodObject<{
|
|
281
|
+
box: zod.ZodObject<{
|
|
282
|
+
left: zod.ZodNumber;
|
|
283
|
+
top: zod.ZodNumber;
|
|
284
|
+
width: zod.ZodNumber;
|
|
285
|
+
height: zod.ZodNumber;
|
|
286
|
+
}, zod.core.$strict>;
|
|
287
|
+
confidence: zod.ZodNumber;
|
|
288
|
+
}, zod.core.$strict>;
|
|
289
|
+
type DetectedPerson = zod.infer<typeof DETECTED_PERSON_SCHEMA>;
|
|
290
|
+
declare const DETECTED_FACE_SCHEMA: zod.ZodObject<{
|
|
291
|
+
box: zod.ZodObject<{
|
|
292
|
+
left: zod.ZodNumber;
|
|
293
|
+
top: zod.ZodNumber;
|
|
294
|
+
width: zod.ZodNumber;
|
|
295
|
+
height: zod.ZodNumber;
|
|
296
|
+
}, zod.core.$strict>;
|
|
297
|
+
confidence: zod.ZodNumber;
|
|
298
|
+
ageRange: zod.ZodOptional<zod.ZodObject<{
|
|
299
|
+
low: zod.ZodNumber;
|
|
300
|
+
high: zod.ZodNumber;
|
|
301
|
+
}, zod.core.$strict>>;
|
|
302
|
+
}, zod.core.$strict>;
|
|
303
|
+
type DetectedFace = zod.infer<typeof DETECTED_FACE_SCHEMA>;
|
|
304
|
+
declare const PROCESSING_FEATURE_RESULTS_SCHEMA: zod.ZodObject<{
|
|
305
|
+
personDetection: zod.ZodOptional<zod.ZodDiscriminatedUnion<[zod.ZodObject<{
|
|
306
|
+
status: zod.ZodLiteral<"evaluated">;
|
|
307
|
+
stage: zod.ZodEnum<{
|
|
308
|
+
beta: "beta";
|
|
309
|
+
ga: "ga";
|
|
310
|
+
}>;
|
|
311
|
+
people: zod.ZodArray<zod.ZodObject<{
|
|
312
|
+
box: zod.ZodObject<{
|
|
313
|
+
left: zod.ZodNumber;
|
|
314
|
+
top: zod.ZodNumber;
|
|
315
|
+
width: zod.ZodNumber;
|
|
316
|
+
height: zod.ZodNumber;
|
|
317
|
+
}, zod.core.$strict>;
|
|
318
|
+
confidence: zod.ZodNumber;
|
|
319
|
+
}, zod.core.$strict>>;
|
|
320
|
+
}, zod.core.$strict>, zod.ZodObject<{
|
|
321
|
+
status: zod.ZodLiteral<"not-evaluated">;
|
|
322
|
+
stage: zod.ZodEnum<{
|
|
323
|
+
beta: "beta";
|
|
324
|
+
ga: "ga";
|
|
325
|
+
}>;
|
|
326
|
+
reason: zod.ZodEnum<{
|
|
327
|
+
"not-supported": "not-supported";
|
|
328
|
+
unavailable: "unavailable";
|
|
329
|
+
}>;
|
|
330
|
+
}, zod.core.$strict>], "status">>;
|
|
331
|
+
faceDetection: zod.ZodOptional<zod.ZodDiscriminatedUnion<[zod.ZodObject<{
|
|
332
|
+
status: zod.ZodLiteral<"evaluated">;
|
|
333
|
+
stage: zod.ZodEnum<{
|
|
334
|
+
beta: "beta";
|
|
335
|
+
ga: "ga";
|
|
336
|
+
}>;
|
|
337
|
+
faces: zod.ZodArray<zod.ZodObject<{
|
|
338
|
+
box: zod.ZodObject<{
|
|
339
|
+
left: zod.ZodNumber;
|
|
340
|
+
top: zod.ZodNumber;
|
|
341
|
+
width: zod.ZodNumber;
|
|
342
|
+
height: zod.ZodNumber;
|
|
343
|
+
}, zod.core.$strict>;
|
|
344
|
+
confidence: zod.ZodNumber;
|
|
345
|
+
ageRange: zod.ZodOptional<zod.ZodObject<{
|
|
346
|
+
low: zod.ZodNumber;
|
|
347
|
+
high: zod.ZodNumber;
|
|
348
|
+
}, zod.core.$strict>>;
|
|
349
|
+
}, zod.core.$strict>>;
|
|
350
|
+
}, zod.core.$strict>, zod.ZodObject<{
|
|
351
|
+
status: zod.ZodLiteral<"not-evaluated">;
|
|
352
|
+
stage: zod.ZodEnum<{
|
|
353
|
+
beta: "beta";
|
|
354
|
+
ga: "ga";
|
|
355
|
+
}>;
|
|
356
|
+
reason: zod.ZodEnum<{
|
|
357
|
+
"not-supported": "not-supported";
|
|
358
|
+
unavailable: "unavailable";
|
|
359
|
+
}>;
|
|
360
|
+
}, zod.core.$strict>], "status">>;
|
|
361
|
+
}, zod.core.$strict>;
|
|
362
|
+
type ProcessingFeatureResults = zod.infer<typeof PROCESSING_FEATURE_RESULTS_SCHEMA>;
|
|
363
|
+
//#endregion
|
|
364
|
+
//#region src/contract/Project.d.ts
|
|
365
|
+
//#region packages/shared/src/Project.d.ts
|
|
366
|
+
declare const FLAGGED_CONTENT_POLICY_SCHEMA: zod.ZodObject<{
|
|
367
|
+
action: zod.ZodEnum<{
|
|
368
|
+
alert: "alert";
|
|
369
|
+
hide: "hide";
|
|
370
|
+
ignore: "ignore";
|
|
371
|
+
purge: "purge";
|
|
372
|
+
}>;
|
|
373
|
+
}, zod.core.$strip>;
|
|
374
|
+
type FlaggedContentPolicy = zod.infer<typeof FLAGGED_CONTENT_POLICY_SCHEMA>;
|
|
375
|
+
//#endregion
|
|
376
|
+
export { ApiErrorCode as _, DetectedPerson as a, ProcessingFeatureStage as c, CALMLENS_ERROR_CODES as d, CalmLensError as f, SdkErrorCode as g, CalmLensErrorOptions as h, DetectedFace as i, ProcessingFeatures as l, CalmLensErrorDetails as m, AgeRange as n, ProcessingFeatureId as o, CalmLensErrorCode as p, BoundingBox as r, ProcessingFeatureResults as s, FlaggedContentPolicy as t, SDK_VERSION as u };
|
package/cjs/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { $ as SearchAssetsOptions, A as DeleteAssetContentOptions, At as AssetSearchQuery, B as Lens, C as CdnAssetUrlOptions, Ct as EventType, D as CreateAssetSignedUrlOptions, Dt as Order, E as ConnectionOptions, Et as CursorPage, F as IdempotencyOptions, Ft as ImageData, G as ModerateTextOptions, H as ListAssetChildrenOptions, I as ImageTransform, It as MetadataItem, J as MultipartUploadOptions, K as MoveAssetOptions, L as ImageTransformOptions, Lt as PreviewImage, M as EnsureLensOptions, Mt as AssetSafetyHold, N as EnsureLensesOptions, Nt as AssetSafetyHoldReason, O as CreateFolderOptions, Ot as LensType, P as FolderIdOptions, Pt as ExtractedText, Q as RetryAssetOptions, R as IterateAssetChildrenOptions, Rt as ProcessingOptions, S as CalmLensServerClientOptions, St as EventSeverity, T as CdnTransform, Tt as Folder, U as ListAssetsOptions, V as LensTransform, W as ListEventsOptions, X as RequestOptions, Y as MultipartUploadPartOptions, Z as RetrieveAssetOptions, _ as AssetSearchResponse, _t as TypedEvent, a as AssetChildrenPage, at as UpdateFolderOptions, b as AssetVisibility, bt as EventFactValues, c as AssetContentRemovalReason, ct as UploadedAsset, d as AssetModerationAction, dt as WebhookHeadersInput, et as SignUploadTokenOptions, f as AssetModerationStatus, ft as WebhookPayloadInput, g as AssetReviewerAction, gt as EventAsset, h as AssetProcessingStatus, i as AssetChecksums, it as UpdateAssetOptions, j as DeleteAssetOptions, k as CreateMultipartUploadPartOptions, kt as AssetSearchMatchField, l as AssetContentStatus, lt as VerifyWebhookSignatureOptions, m as AssetProcessing, nt as SignedUrl, o as AssetContent, ot as UploadAssetPartOptions, p as AssetPage, pt as GetEventsResponse, q as MoveFolderOptions, r as Asset, rt as SubmitAssetOptions, s as AssetContentOptions, st as UploadPresetSubmitAssetOptions, t as ReceivedWebhookEventPayload, tt as SignedUploadToken, u as AssetModeration, ut as WaitForAssetDecisionOptions, v as AssetSearchResult, vt as EventCategory, w as CdnServeOptions, x as CalmLensAppClientOptions, xt as EventFacts, y as AssetType, yt as EventFact, z as IterateAssetsOptions } from "./WebhookPayload-
|
|
2
|
-
import { a as
|
|
3
|
-
import {
|
|
1
|
+
import { $ as SearchAssetsOptions, A as DeleteAssetContentOptions, At as AssetSearchQuery, B as Lens, C as CdnAssetUrlOptions, Ct as EventType, D as CreateAssetSignedUrlOptions, Dt as Order, E as ConnectionOptions, Et as CursorPage, F as IdempotencyOptions, Ft as ImageData, G as ModerateTextOptions, H as ListAssetChildrenOptions, I as ImageTransform, It as MetadataItem, J as MultipartUploadOptions, K as MoveAssetOptions, L as ImageTransformOptions, Lt as PreviewImage, M as EnsureLensOptions, Mt as AssetSafetyHold, N as EnsureLensesOptions, Nt as AssetSafetyHoldReason, O as CreateFolderOptions, Ot as LensType, P as FolderIdOptions, Pt as ExtractedText, Q as RetryAssetOptions, R as IterateAssetChildrenOptions, Rt as ProcessingOptions, S as CalmLensServerClientOptions, St as EventSeverity, T as CdnTransform, Tt as Folder, U as ListAssetsOptions, V as LensTransform, W as ListEventsOptions, X as RequestOptions, Y as MultipartUploadPartOptions, Z as RetrieveAssetOptions, _ as AssetSearchResponse, _t as TypedEvent, a as AssetChildrenPage, at as UpdateFolderOptions, b as AssetVisibility, bt as EventFactValues, c as AssetContentRemovalReason, ct as UploadedAsset, d as AssetModerationAction, dt as WebhookHeadersInput, et as SignUploadTokenOptions, f as AssetModerationStatus, ft as WebhookPayloadInput, g as AssetReviewerAction, gt as EventAsset, h as AssetProcessingStatus, i as AssetChecksums, it as UpdateAssetOptions, j as DeleteAssetOptions, k as CreateMultipartUploadPartOptions, kt as AssetSearchMatchField, l as AssetContentStatus, lt as VerifyWebhookSignatureOptions, m as AssetProcessing, nt as SignedUrl, o as AssetContent, ot as UploadAssetPartOptions, p as AssetPage, pt as GetEventsResponse, q as MoveFolderOptions, r as Asset, rt as SubmitAssetOptions, s as AssetContentOptions, st as UploadPresetSubmitAssetOptions, t as ReceivedWebhookEventPayload, tt as SignedUploadToken, u as AssetModeration, ut as WaitForAssetDecisionOptions, v as AssetSearchResult, vt as EventCategory, w as CdnServeOptions, x as CalmLensAppClientOptions, xt as EventFacts, y as AssetType, yt as EventFact, z as IterateAssetsOptions } from "./WebhookPayload-CJoIkGBD.js";
|
|
2
|
+
import { _ as ApiErrorCode, a as DetectedPerson, c as ProcessingFeatureStage, d as CALMLENS_ERROR_CODES, f as CalmLensError, g as SdkErrorCode, h as CalmLensErrorOptions, i as DetectedFace, l as ProcessingFeatures, m as CalmLensErrorDetails, n as AgeRange, o as ProcessingFeatureId, p as CalmLensErrorCode, r as BoundingBox, s as ProcessingFeatureResults, t as FlaggedContentPolicy, u as SDK_VERSION } from "./index-C9Xw1aid.js";
|
|
3
|
+
import { a as ClassificationNotEvaluatedReason, c as FlaggedContentAction, i as ClassificationLabel, l as Likelihood, n as ClassificationCategory, o as ClassificationQualifierResults, r as ClassificationCategoryReport, s as ClassificationReport, t as ClassificationCategories, u as ModerationQualifier } from "./Classification-BNhgwGEm-DmA9VEuE.js";
|
|
4
4
|
export { type AgeRange, type ApiErrorCode, type Asset, type AssetChecksums, type AssetChildrenPage, type AssetContent, type AssetContentOptions, type AssetContentRemovalReason, type AssetContentStatus, type AssetModeration, type AssetModerationAction, type AssetModerationStatus, type AssetPage, type AssetProcessing, type AssetProcessingStatus, type AssetReviewerAction, type AssetSafetyHold, type AssetSafetyHoldReason, type AssetSearchMatchField, type AssetSearchQuery, type AssetSearchResponse, type AssetSearchResult, type AssetType, type AssetVisibility, type BoundingBox, CALMLENS_ERROR_CODES, type CalmLensAppClientOptions, CalmLensError, type CalmLensErrorCode, type CalmLensErrorDetails, type CalmLensErrorOptions, type CalmLensServerClientOptions, type CdnAssetUrlOptions, type CdnServeOptions, type CdnTransform, type ClassificationCategories, type ClassificationCategory, type ClassificationCategoryReport, type ClassificationLabel, type ClassificationNotEvaluatedReason, type ClassificationQualifierResults, type ClassificationReport, type ConnectionOptions, type CreateAssetSignedUrlOptions, type CreateFolderOptions, type CreateMultipartUploadPartOptions, type CursorPage, type DeleteAssetContentOptions, type DeleteAssetOptions, type DetectedFace, type DetectedPerson, type EnsureLensOptions, type EnsureLensesOptions, type EventAsset, type EventCategory, type EventFact, type EventFactValues, type EventFacts, type EventSeverity, type EventType, type GetEventsResponse as EventsPage, type ExtractedText, type FlaggedContentAction, type FlaggedContentPolicy, type Folder, type FolderIdOptions, type IdempotencyOptions, type ImageData, type ImageTransform, type ImageTransformOptions, type IterateAssetChildrenOptions, type IterateAssetsOptions, type Lens, type LensTransform, type LensType, type Likelihood, type ListAssetChildrenOptions, type ListAssetsOptions, type ListEventsOptions, type MetadataItem, type ModerateTextOptions, type ModerationQualifier, type MoveAssetOptions, type MoveFolderOptions, type MultipartUploadOptions, type MultipartUploadPartOptions, type Order, type PreviewImage, type ProcessingFeatureId, type ProcessingFeatureResults, type ProcessingFeatureStage, type ProcessingFeatures, type ProcessingOptions, type RequestOptions, type RetrieveAssetOptions, type RetryAssetOptions, SDK_VERSION, type SdkErrorCode, type SearchAssetsOptions, type SignUploadTokenOptions, type SignedUploadToken, type SignedUrl, type SubmitAssetOptions, type TypedEvent, type UpdateAssetOptions, type UpdateFolderOptions, type UploadAssetPartOptions, type UploadPresetSubmitAssetOptions, type UploadedAsset, type VerifyWebhookSignatureOptions, type WaitForAssetDecisionOptions, type ReceivedWebhookEventPayload as WebhookEventPayload, type WebhookHeadersInput, type WebhookPayloadInput };
|
package/cjs/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_CalmLensVersion = require("./CalmLensVersion-
|
|
2
|
+
const require_CalmLensVersion = require("./CalmLensVersion-DwhgxQK5.js");
|
|
3
3
|
exports.CALMLENS_ERROR_CODES = require_CalmLensVersion.CALMLENS_ERROR_CODES;
|
|
4
4
|
exports.CalmLensError = require_CalmLensVersion.CalmLensError;
|
|
5
5
|
exports.SDK_VERSION = require_CalmLensVersion.SDK_VERSION;
|
package/cjs/server.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { $ as SearchAssetsOptions, A as DeleteAssetContentOptions, At as AssetSearchQuery, B as Lens, C as CdnAssetUrlOptions, Ct as EventType, D as CreateAssetSignedUrlOptions, Dt as Order, E as ConnectionOptions, Et as CursorPage, F as IdempotencyOptions, Ft as ImageData, G as ModerateTextOptions, H as ListAssetChildrenOptions, I as ImageTransform, It as MetadataItem, J as MultipartUploadOptions, K as MoveAssetOptions, L as ImageTransformOptions, Lt as PreviewImage, M as EnsureLensOptions, Mt as AssetSafetyHold, N as EnsureLensesOptions, Nt as AssetSafetyHoldReason, O as CreateFolderOptions, Ot as LensType, P as FolderIdOptions, Pt as ExtractedText, Q as RetryAssetOptions, R as IterateAssetChildrenOptions, Rt as ProcessingOptions, S as CalmLensServerClientOptions, St as EventSeverity, T as CdnTransform, Tt as Folder, U as ListAssetsOptions, V as LensTransform, W as ListEventsOptions, X as RequestOptions, Y as MultipartUploadPartOptions, Z as RetrieveAssetOptions, _ as AssetSearchResponse, _t as TypedEvent, a as AssetChildrenPage, at as UpdateFolderOptions, b as AssetVisibility, bt as EventFactValues, c as AssetContentRemovalReason, ct as UploadedAsset, d as AssetModerationAction, dt as WebhookHeadersInput, et as SignUploadTokenOptions, f as AssetModerationStatus, ft as WebhookPayloadInput, g as AssetReviewerAction, gt as EventAsset, h as AssetProcessingStatus, i as AssetChecksums, it as UpdateAssetOptions, j as DeleteAssetOptions, k as CreateMultipartUploadPartOptions, kt as AssetSearchMatchField, l as AssetContentStatus, lt as VerifyWebhookSignatureOptions, m as AssetProcessing, mt as PostAssetSignedUrlResponse, nt as SignedUrl, o as AssetContent, ot as UploadAssetPartOptions, p as AssetPage, pt as GetEventsResponse, q as MoveFolderOptions, r as Asset, rt as SubmitAssetOptions, s as AssetContentOptions, st as UploadPresetSubmitAssetOptions, t as ReceivedWebhookEventPayload, tt as SignedUploadToken, u as AssetModeration, ut as WaitForAssetDecisionOptions, v as AssetSearchResult, vt as EventCategory, w as CdnServeOptions, x as CalmLensAppClientOptions, xt as EventFacts, y as AssetType, yt as EventFact, z as IterateAssetsOptions } from "./WebhookPayload-
|
|
2
|
-
import { a as
|
|
3
|
-
import {
|
|
1
|
+
import { $ as SearchAssetsOptions, A as DeleteAssetContentOptions, At as AssetSearchQuery, B as Lens, C as CdnAssetUrlOptions, Ct as EventType, D as CreateAssetSignedUrlOptions, Dt as Order, E as ConnectionOptions, Et as CursorPage, F as IdempotencyOptions, Ft as ImageData, G as ModerateTextOptions, H as ListAssetChildrenOptions, I as ImageTransform, It as MetadataItem, J as MultipartUploadOptions, K as MoveAssetOptions, L as ImageTransformOptions, Lt as PreviewImage, M as EnsureLensOptions, Mt as AssetSafetyHold, N as EnsureLensesOptions, Nt as AssetSafetyHoldReason, O as CreateFolderOptions, Ot as LensType, P as FolderIdOptions, Pt as ExtractedText, Q as RetryAssetOptions, R as IterateAssetChildrenOptions, Rt as ProcessingOptions, S as CalmLensServerClientOptions, St as EventSeverity, T as CdnTransform, Tt as Folder, U as ListAssetsOptions, V as LensTransform, W as ListEventsOptions, X as RequestOptions, Y as MultipartUploadPartOptions, Z as RetrieveAssetOptions, _ as AssetSearchResponse, _t as TypedEvent, a as AssetChildrenPage, at as UpdateFolderOptions, b as AssetVisibility, bt as EventFactValues, c as AssetContentRemovalReason, ct as UploadedAsset, d as AssetModerationAction, dt as WebhookHeadersInput, et as SignUploadTokenOptions, f as AssetModerationStatus, ft as WebhookPayloadInput, g as AssetReviewerAction, gt as EventAsset, h as AssetProcessingStatus, i as AssetChecksums, it as UpdateAssetOptions, j as DeleteAssetOptions, k as CreateMultipartUploadPartOptions, kt as AssetSearchMatchField, l as AssetContentStatus, lt as VerifyWebhookSignatureOptions, m as AssetProcessing, mt as PostAssetSignedUrlResponse, nt as SignedUrl, o as AssetContent, ot as UploadAssetPartOptions, p as AssetPage, pt as GetEventsResponse, q as MoveFolderOptions, r as Asset, rt as SubmitAssetOptions, s as AssetContentOptions, st as UploadPresetSubmitAssetOptions, t as ReceivedWebhookEventPayload, tt as SignedUploadToken, u as AssetModeration, ut as WaitForAssetDecisionOptions, v as AssetSearchResult, vt as EventCategory, w as CdnServeOptions, x as CalmLensAppClientOptions, xt as EventFacts, y as AssetType, yt as EventFact, z as IterateAssetsOptions } from "./WebhookPayload-CJoIkGBD.js";
|
|
2
|
+
import { _ as ApiErrorCode, a as DetectedPerson, c as ProcessingFeatureStage, d as CALMLENS_ERROR_CODES, f as CalmLensError, g as SdkErrorCode, h as CalmLensErrorOptions, i as DetectedFace, l as ProcessingFeatures, m as CalmLensErrorDetails, n as AgeRange, o as ProcessingFeatureId, p as CalmLensErrorCode, r as BoundingBox, s as ProcessingFeatureResults, t as FlaggedContentPolicy, u as SDK_VERSION } from "./index-C9Xw1aid.js";
|
|
3
|
+
import { a as ClassificationNotEvaluatedReason, c as FlaggedContentAction, i as ClassificationLabel, l as Likelihood, n as ClassificationCategory, o as ClassificationQualifierResults, r as ClassificationCategoryReport, s as ClassificationReport, t as ClassificationCategories, u as ModerationQualifier } from "./Classification-BNhgwGEm-DmA9VEuE.js";
|
|
4
4
|
//#region src/client/CalmLensServerClient.d.ts
|
|
5
5
|
interface LensCache {
|
|
6
6
|
readonly ensuredLenses: Map<string, Lens>;
|
package/cjs/server.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_CalmLensVersion = require("./CalmLensVersion-
|
|
2
|
+
const require_CalmLensVersion = require("./CalmLensVersion-DwhgxQK5.js");
|
|
3
3
|
require("./index.js");
|
|
4
|
-
const require_CalmLensWebhooks = require("./CalmLensWebhooks-
|
|
5
|
-
const require_CalmLensUtils = require("./CalmLensUtils-
|
|
6
|
-
const require_CalmLensConnection = require("./CalmLensConnection-
|
|
4
|
+
const require_CalmLensWebhooks = require("./CalmLensWebhooks-BKrq30Yp.js");
|
|
5
|
+
const require_CalmLensUtils = require("./CalmLensUtils-o171ownK.js");
|
|
6
|
+
const require_CalmLensConnection = require("./CalmLensConnection-BNUHp_AQ.js");
|
|
7
7
|
const getEnsureLensCacheKey = (options) => require_CalmLensWebhooks.stringifyJsonCanonical({
|
|
8
8
|
identifier: options.identifier,
|
|
9
9
|
name: options.name,
|
|
@@ -219,7 +219,6 @@ sign: async (options) => {
|
|
|
219
219
|
*/
|
|
220
220
|
createSignedUrl: async ({ assetId, ...options }) => {
|
|
221
221
|
const encodedAssetId = requireId(assetId, "Asset ID");
|
|
222
|
-
if (options.lens && options.transform) throw require_CalmLensVersion.invalidArgument("Specify either a lens or a transform, not both");
|
|
223
222
|
return this.request("POST", `/assets/${encodedAssetId}/signed-url`, { body: {
|
|
224
223
|
resource: options.resource ?? "content",
|
|
225
224
|
expiresInSeconds: options.expiresInSeconds ?? 900,
|
package/cjs/test-inputs.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as detectTestImage, c as getImageTestCategories, d as paintTestImage, i as TestImageKeyCell, l as getTestImageKeyCells, n as TEST_IMAGE_PALETTES, o as detectTestTrigger, r as TEST_INPUT_KEY_PATTERN, s as generateTestTextCode, t as ClassificationTestSignal, u as getTestImageKeyColors } from "./TestTriggers-
|
|
1
|
+
import { a as detectTestImage, c as getImageTestCategories, d as paintTestImage, i as TestImageKeyCell, l as getTestImageKeyCells, n as TEST_IMAGE_PALETTES, o as detectTestTrigger, r as TEST_INPUT_KEY_PATTERN, s as generateTestTextCode, t as ClassificationTestSignal, u as getTestImageKeyColors } from "./TestTriggers-CRKtulyp-vrzEq2wm.js";
|
|
2
2
|
export { type ClassificationTestSignal, TEST_IMAGE_PALETTES, TEST_INPUT_KEY_PATTERN, type TestImageKeyCell, detectTestImage, detectTestTrigger, generateTestTextCode, getImageTestCategories, getTestImageKeyCells, getTestImageKeyColors, paintTestImage };
|
package/cjs/test-inputs.js
CHANGED
package/cjs/testing.d.ts
CHANGED
|
@@ -1,10 +1,12 @@
|
|
|
1
|
-
import { $ as SearchAssetsOptions, A as DeleteAssetContentOptions, B as Lens, C as CdnAssetUrlOptions, D as CreateAssetSignedUrlOptions, G as ModerateTextOptions, H as ListAssetChildrenOptions, K as MoveAssetOptions, M as EnsureLensOptions, N as EnsureLensesOptions, O as CreateFolderOptions, P as FolderIdOptions, Q as RetryAssetOptions, R as IterateAssetChildrenOptions, S as CalmLensServerClientOptions, Tt as Folder, U as ListAssetsOptions, W as ListEventsOptions, Z as RetrieveAssetOptions, _ as AssetSearchResponse, _t as TypedEvent, a as AssetChildrenPage, at as UpdateFolderOptions, et as SignUploadTokenOptions, ht as Event, it as UpdateAssetOptions, j as DeleteAssetOptions, jt as AssetBinaryPayloadInput, mt as PostAssetSignedUrlResponse, n as WebhookEventPayload, ot as UploadAssetPartOptions, p as AssetPage, pt as GetEventsResponse, q as MoveFolderOptions, r as Asset, rt as SubmitAssetOptions, tt as SignedUploadToken, ut as WaitForAssetDecisionOptions, w as CdnServeOptions, wt as PermissionGrant, z as IterateAssetsOptions } from "./WebhookPayload-
|
|
2
|
-
import { t as ClassificationTestSignal } from "./TestTriggers-
|
|
3
|
-
//#region
|
|
1
|
+
import { $ as SearchAssetsOptions, A as DeleteAssetContentOptions, B as Lens, C as CdnAssetUrlOptions, D as CreateAssetSignedUrlOptions, G as ModerateTextOptions, H as ListAssetChildrenOptions, K as MoveAssetOptions, M as EnsureLensOptions, N as EnsureLensesOptions, O as CreateFolderOptions, P as FolderIdOptions, Q as RetryAssetOptions, R as IterateAssetChildrenOptions, S as CalmLensServerClientOptions, Tt as Folder, U as ListAssetsOptions, W as ListEventsOptions, Z as RetrieveAssetOptions, _ as AssetSearchResponse, _t as TypedEvent, a as AssetChildrenPage, at as UpdateFolderOptions, et as SignUploadTokenOptions, ht as Event, it as UpdateAssetOptions, j as DeleteAssetOptions, jt as AssetBinaryPayloadInput, mt as PostAssetSignedUrlResponse, n as WebhookEventPayload, ot as UploadAssetPartOptions, p as AssetPage, pt as GetEventsResponse, q as MoveFolderOptions, r as Asset, rt as SubmitAssetOptions, tt as SignedUploadToken, ut as WaitForAssetDecisionOptions, w as CdnServeOptions, wt as PermissionGrant, z as IterateAssetsOptions } from "./WebhookPayload-CJoIkGBD.js";
|
|
2
|
+
import { t as ClassificationTestSignal } from "./TestTriggers-CRKtulyp-vrzEq2wm.js";
|
|
3
|
+
//#region src/contract/MediaTestTriggers.d.ts
|
|
4
|
+
//#region packages/shared/src/MediaTestTriggers.d.ts
|
|
4
5
|
export declare const MEDIA_TEST_SIGNALS: readonly ["sexual", "violence", "self-harm", "harassment", "hate", "criminal-activity", "violence.graphic"];
|
|
5
6
|
/** Read this aloud, or render it as large, high-contrast text in a video frame. */
|
|
6
7
|
export declare function generateMediaTestCode(signal: ClassificationTestSignal, testInputKey: string): string;
|
|
7
8
|
//#endregion
|
|
9
|
+
//#endregion
|
|
8
10
|
//#region src/testing/MockApiKey.d.ts
|
|
9
11
|
export declare const MOCK_API_KEY_PREFIX = "sk_test_";
|
|
10
12
|
export declare const createMockApiKey: (grants?: PermissionGrant[]) => string;
|