@calmlens/js-sdk 0.0.0 → 0.0.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.
Files changed (69) hide show
  1. package/README.md +190 -22
  2. package/cjs/ApiKey.d.ts +31 -0
  3. package/cjs/ApiKey.js +59 -0
  4. package/cjs/Asset.d.ts +83 -3
  5. package/cjs/Asset.js +198 -28
  6. package/cjs/Auth.d.ts +95 -0
  7. package/cjs/Auth.js +2 -0
  8. package/cjs/CalmLensClient.d.ts +28 -11
  9. package/cjs/CalmLensClient.js +138 -77
  10. package/cjs/CalmLensTypes.d.ts +2 -0
  11. package/cjs/Classification.js +40 -7
  12. package/cjs/DocMetaTypes.d.ts +7 -0
  13. package/cjs/DocMetaTypes.js +7 -0
  14. package/cjs/Page.d.ts +42 -0
  15. package/cjs/Page.js +94 -0
  16. package/cjs/PublicApiSchemas.d.ts +1593 -0
  17. package/cjs/PublicApiSchemas.js +334 -0
  18. package/cjs/RequestInfo.d.ts +23 -0
  19. package/cjs/RequestInfo.js +2 -0
  20. package/cjs/Roles.d.ts +21 -0
  21. package/cjs/Roles.js +84 -0
  22. package/cjs/SharedConstants.d.ts +134 -0
  23. package/cjs/SharedConstants.js +125 -0
  24. package/cjs/SharedTypes.d.ts +6 -1
  25. package/cjs/User.d.ts +17 -0
  26. package/cjs/User.js +51 -0
  27. package/cjs/UtilTypes.d.ts +30 -0
  28. package/cjs/UtilTypes.js +4 -0
  29. package/cjs/Workflow.d.ts +58 -0
  30. package/cjs/Workflow.js +83 -0
  31. package/cjs/ZodUtils.d.ts +39 -0
  32. package/cjs/ZodUtils.js +328 -0
  33. package/cjs/index.js +4 -1
  34. package/esm/ApiKey.d.ts +31 -0
  35. package/esm/ApiKey.js +23 -0
  36. package/esm/Asset.d.ts +83 -3
  37. package/esm/Asset.js +148 -12
  38. package/esm/Auth.d.ts +95 -0
  39. package/esm/Auth.js +1 -0
  40. package/esm/CalmLensClient.d.ts +28 -11
  41. package/esm/CalmLensClient.js +104 -55
  42. package/esm/CalmLensTypes.d.ts +2 -0
  43. package/esm/Classification.js +1 -1
  44. package/esm/DocMetaTypes.d.ts +7 -0
  45. package/esm/DocMetaTypes.js +4 -0
  46. package/esm/Page.d.ts +42 -0
  47. package/esm/Page.js +55 -0
  48. package/esm/PublicApiSchemas.d.ts +1593 -0
  49. package/esm/PublicApiSchemas.js +298 -0
  50. package/esm/RequestInfo.d.ts +23 -0
  51. package/esm/RequestInfo.js +1 -0
  52. package/esm/Roles.d.ts +21 -0
  53. package/esm/Roles.js +45 -0
  54. package/esm/SharedConstants.d.ts +134 -0
  55. package/esm/SharedConstants.js +122 -0
  56. package/esm/SharedTypes.d.ts +6 -1
  57. package/esm/User.d.ts +17 -0
  58. package/esm/User.js +15 -0
  59. package/esm/UtilTypes.d.ts +30 -0
  60. package/esm/UtilTypes.js +1 -0
  61. package/esm/Workflow.d.ts +58 -0
  62. package/esm/Workflow.js +46 -0
  63. package/esm/ZodUtils.d.ts +39 -0
  64. package/esm/ZodUtils.js +266 -0
  65. package/package.json +10 -10
  66. package/cjs/SchemaUtils.d.ts +0 -11
  67. package/cjs/SchemaUtils.js +0 -63
  68. package/esm/SchemaUtils.d.ts +0 -11
  69. package/esm/SchemaUtils.js +0 -46
package/README.md CHANGED
@@ -1,37 +1,205 @@
1
- # [api-def](https://github.com/Censkh/api-def/) · [![GitHub license](https://img.shields.io/badge/license-MIT-blue.svg)](https://github.com/Censkh/api-def/blob/master/LICENSE) [![npm version](https://img.shields.io/npm/v/api-def.svg?style=flat)](https://www.npmjs.com/package/api-def) [![build status](https://img.shields.io/github/actions/workflow/status/censkh/api-def/workflow.yml)](https://github.com/Censkh/api-def/actions)
1
+ # @calmlens/js-sdk
2
2
 
3
- Typed APIs with middleware support
3
+ Official JavaScript/TypeScript SDK for CalmLens API
4
4
 
5
- API def provides a unified way to type your endpoints allowing for compile time checking of query, body, response and even url parameters
5
+ CalmLens provides content moderation and classification services for images, videos, audio, documents, and websites. This SDK makes it easy to integrate CalmLens into your JavaScript/TypeScript applications.
6
+
7
+ ## Installation
6
8
 
7
9
  ```bash
8
- npm i api-def
10
+ npm install @calmlens/js-sdk
9
11
  ```
10
12
 
11
- - [Documentation](https://censkh.github.io/api-def/)
13
+ ## Quick Start
12
14
 
13
15
  ```typescript
14
- import { Api } from "api-def";
16
+ import CalmLensClient from "@calmlens/js-sdk";
15
17
 
16
- const api = new Api({
17
- baseUrl: "https://my-api/",
18
- name: "My API",
18
+ const client = new CalmLensClient({
19
+ apiKey: "your-api-key",
20
+ projectId: "your-project-id",
19
21
  });
20
22
 
21
- const fetchData = api
22
- .endpoint()
23
- .queryOf<{ includeAwesome: boolean }>()
24
- .responseOf<{ data: { awesome: boolean } }>()
25
- .build({
26
- id: "fetch_data",
27
- method: "get",
28
- path: "/data",
29
- });
23
+ // Submit an asset for processing
24
+ const asset = await client.submitAsset({
25
+ name: "my-image.jpg",
26
+ file: "data:image/jpeg;base64,/9j/4AAQSkZJRgABAQAAAQ...", // base64 encoded file
27
+ fileType: "image/jpeg",
28
+ description: "User uploaded image",
29
+ visibility: "private"
30
+ });
31
+
32
+ console.log(asset.id); // Asset ID for future reference
33
+ console.log(asset.status); // "pending", "approved", "rejected", or "error"
34
+ ```
35
+
36
+ ## API Reference
37
+
38
+ ### CalmLensClient
39
+
40
+ The main client class for interacting with the CalmLens API.
41
+
42
+ #### Constructor
43
+
44
+ ```typescript
45
+ new CalmLensClient(options: CalmLensClientOptions)
46
+ ```
47
+
48
+ **Options:**
49
+ - `apiKey` (string, required): Your CalmLens API key
50
+ - `projectId` (string, required): Your CalmLens project ID
51
+ - `baseUrl` (string, optional): API base URL (defaults to "https://api.calmlens.com")
52
+
53
+ #### Methods
54
+
55
+ ##### submitAsset(options)
56
+
57
+ Submit an asset for processing and classification.
58
+
59
+ ```typescript
60
+ async submitAsset(options: SubmitAssetOptions): Promise<Asset>
61
+ ```
62
+
63
+ **Options:**
64
+ - `name` (string, required): Name of the asset
65
+ - `file` (string, optional): Base64 encoded file content or data URL
66
+ - `fileType` (string, optional): MIME type or file extension (required if using `file`)
67
+ - `url` (string, optional): External URL to the asset (alternative to `file`)
68
+ - `description` (string, optional): Description of the asset
69
+ - `keepAfterProcessing` (boolean, optional): Whether to keep the asset after processing
70
+ - `visibility` (string, optional): "public" or "private"
71
+
72
+ **Example:**
73
+ ```typescript
74
+ // Submit from file content
75
+ const asset = await client.submitAsset({
76
+ name: "document.pdf",
77
+ file: "data:application/pdf;base64,JVBERi0xLjQKJcfs...",
78
+ fileType: "application/pdf",
79
+ description: "Important document",
80
+ visibility: "private"
81
+ });
82
+
83
+ // Submit from URL
84
+ const asset = await client.submitAsset({
85
+ name: "website-content",
86
+ url: "https://example.com/page",
87
+ description: "Web page to analyze"
88
+ });
89
+ ```
90
+
91
+ ##### getAsset(assetId)
92
+
93
+ Retrieve details of a specific asset.
94
+
95
+ ```typescript
96
+ async getAsset(assetId: string): Promise<Asset>
97
+ ```
98
+
99
+ **Example:**
100
+ ```typescript
101
+ const asset = await client.getAsset("asset-uuid-here");
102
+ console.log(asset.status);
103
+ console.log(asset.report); // Classification results
104
+ ```
105
+
106
+ ##### listAssets(options)
107
+
108
+ List assets in your project with pagination.
30
109
 
31
- // calls GET https://my-api/data?includeAwesome=true
32
- const res = await fetchData.submit({
33
- query: { includeAwesome: true },
110
+ ```typescript
111
+ async listAssets(options?: {
112
+ pageIndex?: number;
113
+ pageSize?: number;
114
+ }): Promise<{
115
+ items: Asset[];
116
+ total: number;
117
+ pageIndex: number;
118
+ pageSize: number;
119
+ }>
120
+ ```
121
+
122
+ **Example:**
123
+ ```typescript
124
+ const result = await client.listAssets({
125
+ pageIndex: 0,
126
+ pageSize: 20
34
127
  });
35
128
 
36
- console.log(res.data); // { data: { awesome: true } }
129
+ console.log(`Found ${result.total} assets`);
130
+ result.items.forEach(asset => {
131
+ console.log(`${asset.name}: ${asset.status}`);
132
+ });
37
133
  ```
134
+
135
+ #### Static Methods
136
+
137
+ ##### verifyWebhookSignature(payload, signature, secret)
138
+
139
+ Verify webhook signatures to ensure authenticity.
140
+
141
+ ```typescript
142
+ static async verifyWebhookSignature(
143
+ payload: string | object,
144
+ signatureHex: string,
145
+ secret: string
146
+ ): Promise<boolean>
147
+ ```
148
+
149
+ **Example:**
150
+ ```typescript
151
+ // In your webhook handler
152
+ const signature = req.headers['x-calmlens-signature'];
153
+ const payload = req.body;
154
+ const isValid = await CalmLensClient.verifyWebhookSignature(
155
+ payload,
156
+ signature,
157
+ WEBHOOK_SECRET
158
+ );
159
+
160
+ if (!isValid) {
161
+ return res.status(401).send('Unauthorized');
162
+ }
163
+ ```
164
+
165
+ ## Asset Types
166
+
167
+ Assets can be of the following types:
168
+ - `image` - Images (JPEG, PNG, GIF, WebP, etc.)
169
+ - `video` - Video files (MP4, WebM, etc.)
170
+ - `audio` - Audio files (MP3, WAV, etc.)
171
+ - `document` - Documents (PDF, DOC, TXT, etc.)
172
+ - `website` - Web pages and URLs
173
+
174
+ ## Asset Status
175
+
176
+ Assets progress through these statuses:
177
+ - `pending` - Asset is being processed
178
+ - `approved` - Asset passed moderation
179
+ - `rejected` - Asset failed moderation
180
+ - `error` - Processing failed
181
+
182
+ ## Asset Visibility
183
+
184
+ - `public` - Asset is publicly accessible
185
+ - `private` - Asset is only accessible to your project
186
+
187
+ ## Error Handling
188
+
189
+ The SDK throws errors for common issues:
190
+
191
+ ```typescript
192
+ try {
193
+ const asset = await client.submitAsset({
194
+ name: "test.jpg"
195
+ // Missing required file or url
196
+ });
197
+ } catch (error) {
198
+ console.error(error.message); // "Either file content or URL is required"
199
+ }
200
+ ```
201
+
202
+ ## Webhooks
203
+
204
+ CalmLens can send webhooks when asset processing is complete. Use `verifyWebhookSignature` to verify the authenticity of incoming webhooks.
205
+
@@ -0,0 +1,31 @@
1
+ import * as zod from "zod/v4";
2
+ export declare const API_KEY_STATUS_SCHEMA: zod.ZodEnum<{
3
+ active: "active";
4
+ revoked: "revoked";
5
+ expired: "expired";
6
+ }>;
7
+ export type ApiKeyStatus = zod.infer<typeof API_KEY_STATUS_SCHEMA>;
8
+ export declare const API_KEY_SCHEMA: zod.ZodObject<{
9
+ id: zod.ZodString;
10
+ projectId: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
11
+ userId: zod.ZodOptional<zod.ZodNullable<zod.ZodPipe<zod.ZodString, zod.ZodTransform<string, string>>>>;
12
+ createdAt: zod.ZodNumber;
13
+ updatedAt: zod.ZodOptional<zod.ZodNumber>;
14
+ name: zod.ZodPipe<zod.ZodString, zod.ZodTransform<string, string>>;
15
+ description: zod.ZodOptional<zod.ZodNullable<zod.ZodPipe<zod.ZodString, zod.ZodTransform<string, string>>>>;
16
+ keyHash: zod.ZodPipe<zod.ZodString, zod.ZodTransform<string, string>>;
17
+ keyPrefix: zod.ZodPipe<zod.ZodString, zod.ZodTransform<string, string>>;
18
+ roles: zod.ZodOptional<zod.ZodNullable<zod.ZodArray<zod.ZodEnum<{
19
+ "system:super-admin": "system:super-admin";
20
+ "system:banned": "system:banned";
21
+ "assets:view-all": "assets:view-all";
22
+ }>>>>;
23
+ status: zod.ZodEnum<{
24
+ active: "active";
25
+ revoked: "revoked";
26
+ expired: "expired";
27
+ }>;
28
+ expiresAt: zod.ZodOptional<zod.ZodNullable<zod.ZodNumber>>;
29
+ lastUsedAt: zod.ZodOptional<zod.ZodNullable<zod.ZodNumber>>;
30
+ }, zod.z.core.$strip>;
31
+ export type ApiKey = zod.infer<typeof API_KEY_SCHEMA>;
package/cjs/ApiKey.js ADDED
@@ -0,0 +1,59 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __importStar = (this && this.__importStar) || (function () {
19
+ var ownKeys = function(o) {
20
+ ownKeys = Object.getOwnPropertyNames || function (o) {
21
+ var ar = [];
22
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
+ return ar;
24
+ };
25
+ return ownKeys(o);
26
+ };
27
+ return function (mod) {
28
+ if (mod && mod.__esModule) return mod;
29
+ var result = {};
30
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
+ __setModuleDefault(result, mod);
32
+ return result;
33
+ };
34
+ })();
35
+ Object.defineProperty(exports, "__esModule", { value: true });
36
+ exports.API_KEY_SCHEMA = exports.API_KEY_STATUS_SCHEMA = void 0;
37
+ var zod = __importStar(require("zod/v4"));
38
+ var Roles_1 = require("./Roles");
39
+ var ZodUtils_1 = require("./ZodUtils");
40
+ exports.API_KEY_STATUS_SCHEMA = zod.enum(["active", "revoked", "expired"]);
41
+ exports.API_KEY_SCHEMA = zod.object({
42
+ id: (0, ZodUtils_1.primaryUuidField)(),
43
+ projectId: (0, ZodUtils_1.uuidField)().nullish(),
44
+ userId: (0, ZodUtils_1.saneStringField)().nullish(),
45
+ createdAt: (0, ZodUtils_1.createdAtField)(),
46
+ updatedAt: (0, ZodUtils_1.updatedAtField)(),
47
+ name: (0, ZodUtils_1.saneStringField)({
48
+ type: "medium",
49
+ }),
50
+ description: (0, ZodUtils_1.saneStringField)({
51
+ type: "large",
52
+ }).nullish(),
53
+ keyHash: (0, ZodUtils_1.saneStringField)(), // Store hashed version of the key for security
54
+ keyPrefix: (0, ZodUtils_1.saneStringField)(), // Store first few characters for identification
55
+ roles: zod.array(Roles_1.ROLE_SCHEMA).nullish(),
56
+ status: exports.API_KEY_STATUS_SCHEMA,
57
+ expiresAt: zod.number().nullish(), // Unix timestamp
58
+ lastUsedAt: zod.number().nullish(), // Unix timestamp
59
+ });
package/cjs/Asset.d.ts CHANGED
@@ -7,18 +7,56 @@ export declare const ASSET_STATUS_SCHEMA: zod.ZodEnum<{
7
7
  }>;
8
8
  export type AssetStatus = zod.infer<typeof ASSET_STATUS_SCHEMA>;
9
9
  export declare const ASSET_TYPE_SCHEMA: zod.ZodEnum<{
10
+ file: "file";
10
11
  image: "image";
11
12
  video: "video";
12
13
  audio: "audio";
13
- document: "document";
14
+ "plaintext-document": "plaintext-document";
15
+ "multimedia-document": "multimedia-document";
14
16
  website: "website";
15
17
  }>;
16
18
  export type AssetType = zod.infer<typeof ASSET_TYPE_SCHEMA>;
19
+ /**
20
+ * MIME types that are considered multimedia documents
21
+ * (documents that contain both text and embedded images/media)
22
+ */
23
+ export declare const MULTIMEDIA_DOCUMENT_MIME_TYPES: readonly ["application/pdf", "application/vnd.openxmlformats-officedocument.wordprocessingml.document", "application/msword", "application/rtf", "application/vnd.oasis.opendocument.text"];
24
+ /**
25
+ * Checks if a MIME type is a multimedia document
26
+ */
27
+ export declare const isMultimediaDocumentMimeType: (mimeType: string) => boolean;
17
28
  export declare const ASSET_VISIBILITY_SCHEMA: zod.ZodEnum<{
18
29
  public: "public";
19
30
  private: "private";
20
31
  }>;
21
32
  export type AssetVisibility = zod.infer<typeof ASSET_VISIBILITY_SCHEMA>;
33
+ export interface CheckSums {
34
+ readonly md5?: string;
35
+ readonly sha1?: string;
36
+ readonly sha256?: string;
37
+ readonly sha384?: string;
38
+ readonly sha512?: string;
39
+ }
40
+ export declare const CHECKSUMS_SCHEMA: zod.ZodObject<{
41
+ md5: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
42
+ sha1: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
43
+ sha256: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
44
+ sha384: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
45
+ sha512: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
46
+ }, zod.z.core.$strip>;
47
+ export declare const IMAGE_DATA_SCHEMA: zod.ZodObject<{
48
+ perceptualHash: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
49
+ }, zod.z.core.$strip>;
50
+ export type ImageData = zod.infer<typeof IMAGE_DATA_SCHEMA>;
51
+ export declare const DOCUMENT_DATA_SCHEMA: zod.ZodObject<{}, zod.z.core.$strip>;
52
+ export type DocumentData = zod.infer<typeof DOCUMENT_DATA_SCHEMA>;
53
+ export declare const PROCESSING_OPTIONS_SCHEMA: zod.ZodOptional<zod.ZodNullable<zod.ZodObject<{
54
+ keepAfterProcessing: zod.ZodOptional<zod.ZodNullable<zod.ZodBoolean>>;
55
+ image: zod.ZodOptional<zod.ZodNullable<zod.ZodObject<{
56
+ ocrEnabled: zod.ZodOptional<zod.ZodNullable<zod.ZodBoolean>>;
57
+ }, zod.z.core.$strip>>>;
58
+ }, zod.z.core.$strip>>>;
59
+ export type ProcessingOptions = zod.infer<typeof PROCESSING_OPTIONS_SCHEMA>;
22
60
  export declare const ASSET_SCHEMA: zod.ZodObject<{
23
61
  id: zod.ZodString;
24
62
  projectId: zod.ZodString;
@@ -27,6 +65,17 @@ export declare const ASSET_SCHEMA: zod.ZodObject<{
27
65
  parentId: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
28
66
  createdAt: zod.ZodNumber;
29
67
  updatedAt: zod.ZodOptional<zod.ZodNumber>;
68
+ checksums: zod.ZodOptional<zod.ZodNullable<zod.ZodObject<{
69
+ md5: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
70
+ sha1: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
71
+ sha256: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
72
+ sha384: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
73
+ sha512: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
74
+ }, zod.z.core.$strip>>>;
75
+ imageData: zod.ZodOptional<zod.ZodNullable<zod.ZodObject<{
76
+ perceptualHash: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
77
+ }, zod.z.core.$strip>>>;
78
+ documentData: zod.ZodOptional<zod.ZodNullable<zod.ZodObject<{}, zod.z.core.$strip>>>;
30
79
  name: zod.ZodPipe<zod.ZodString, zod.ZodTransform<string, string>>;
31
80
  fileFormat: zod.ZodOptional<zod.ZodNullable<zod.ZodPipe<zod.ZodString, zod.ZodTransform<string, string>>>>;
32
81
  fileExtension: zod.ZodOptional<zod.ZodNullable<zod.ZodPipe<zod.ZodString, zod.ZodTransform<string, string>>>>;
@@ -37,10 +86,12 @@ export declare const ASSET_SCHEMA: zod.ZodObject<{
37
86
  storageId: zod.ZodOptional<zod.ZodNullable<zod.ZodPipe<zod.ZodString, zod.ZodTransform<string, string>>>>;
38
87
  averageColor: zod.ZodOptional<zod.ZodNullable<zod.ZodPipe<zod.ZodString, zod.ZodTransform<string, string>>>>;
39
88
  type: zod.ZodEnum<{
89
+ file: "file";
40
90
  image: "image";
41
91
  video: "video";
42
92
  audio: "audio";
43
- document: "document";
93
+ "plaintext-document": "plaintext-document";
94
+ "multimedia-document": "multimedia-document";
44
95
  website: "website";
45
96
  }>;
46
97
  previewHash: zod.ZodOptional<zod.ZodNullable<zod.ZodPipe<zod.ZodString, zod.ZodTransform<string, string>>>>;
@@ -100,10 +151,39 @@ export declare const ASSET_SCHEMA: zod.ZodObject<{
100
151
  approved: "approved";
101
152
  rejected: "rejected";
102
153
  }>;
103
- keepAfterProcessing: zod.ZodOptional<zod.ZodNullable<zod.ZodBoolean>>;
154
+ extractedTextId: zod.ZodOptional<zod.ZodNullable<zod.ZodPipe<zod.ZodString, zod.ZodTransform<string, string>>>>;
155
+ processingOptions: zod.ZodOptional<zod.ZodNullable<zod.ZodObject<{
156
+ keepAfterProcessing: zod.ZodOptional<zod.ZodNullable<zod.ZodBoolean>>;
157
+ image: zod.ZodOptional<zod.ZodNullable<zod.ZodObject<{
158
+ ocrEnabled: zod.ZodOptional<zod.ZodNullable<zod.ZodBoolean>>;
159
+ }, zod.z.core.$strip>>>;
160
+ }, zod.z.core.$strip>>>;
104
161
  visibility: zod.ZodOptional<zod.ZodNullable<zod.ZodEnum<{
105
162
  public: "public";
106
163
  private: "private";
107
164
  }>>>;
165
+ storageDeletedAt: zod.ZodOptional<zod.ZodNullable<zod.ZodNumber>>;
166
+ classificationWorkflow: zod.ZodOptional<zod.ZodNullable<zod.ZodObject<{
167
+ id: zod.ZodString;
168
+ name: zod.ZodString;
169
+ steps: zod.ZodArray<zod.ZodObject<{
170
+ id: zod.ZodString;
171
+ label: zod.ZodString;
172
+ status: zod.ZodEnum<{
173
+ error: "error";
174
+ pending: "pending";
175
+ in_progress: "in_progress";
176
+ completed: "completed";
177
+ skipped: "skipped";
178
+ }>;
179
+ optional: zod.ZodOptional<zod.ZodBoolean>;
180
+ startedAt: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
181
+ completedAt: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
182
+ error: zod.ZodOptional<zod.ZodNullable<zod.ZodString>>;
183
+ }, zod.z.core.$strip>>;
184
+ createdAt: zod.ZodString;
185
+ updatedAt: zod.ZodString;
186
+ }, zod.z.core.$strip>>>;
108
187
  }, zod.z.core.$strip>;
109
188
  export type Asset = zod.infer<typeof ASSET_SCHEMA>;
189
+ export type AssetInput = Omit<zod.input<typeof ASSET_SCHEMA>, "createdAt" | "status">;