Skip to content

Commit cfca6fd

Browse files
refactor: AITags to singular AITag schema with array items pattern
1 parent cf8b59a commit cfca6fd

4 files changed

Lines changed: 27 additions & 23 deletions

File tree

.stats.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 47
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/imagekit-inc%2Fimagekit-7c4c23556be689ded6bcafd05e1645b82239521c9c841c0f7e76336e2eefcffa.yml
3-
openapi_spec_hash: eca5b039a0066c6536296248c3a80854
4-
config_hash: f914ebc9670f6e7c7751660caa4e5556
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/imagekit-inc%2Fimagekit-70c42eda2bee929830b2537f758400a58dded1f1ef5686a286e2469c35a041a0.yml
3+
openapi_spec_hash: cdaeed824e91657b45092765cf55eb42
4+
config_hash: e3c2679d25f6235381dfb11962fbf3d9

src/resources/beta/v2/files.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -66,9 +66,7 @@ export class Files extends APIResource {
6666
*/
6767
export interface FileUploadResponse {
6868
/**
69-
* Array of `AITags` associated with the image. If no `AITags` are set, it will be
70-
* null. These tags can be added using the `google-auto-tagging` or
71-
* `aws-auto-tagging` extensions.
69+
* An array of tags assigned to the uploaded file by auto tagging.
7270
*/
7371
AITags?: Array<FileUploadResponse.AITag> | null;
7472

@@ -227,6 +225,10 @@ export interface FileUploadResponse {
227225
}
228226

229227
export namespace FileUploadResponse {
228+
/**
229+
* AI-generated tag associated with an image. These tags can be added using the
230+
* `google-auto-tagging` or `aws-auto-tagging` extensions.
231+
*/
230232
export interface AITag {
231233
/**
232234
* Confidence score of the tag.

src/resources/files/files.ts

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -196,9 +196,8 @@ export class Files extends APIResource {
196196
*/
197197
export interface File {
198198
/**
199-
* Array of `AITags` associated with the image. If no `AITags` are set, it will be
200-
* null. These tags can be added using the `google-auto-tagging` or
201-
* `aws-auto-tagging` extensions.
199+
* Array of AI-generated tags associated with the image. If no AITags are set, it
200+
* will be null.
202201
*/
203202
AITags?: Array<File.AITag> | null;
204203

@@ -224,11 +223,7 @@ export interface File {
224223
customCoordinates?: string | null;
225224

226225
/**
227-
* A key-value data associated with the asset. Use `responseField` in API request
228-
* to get `customMetadata` in the upload API response. Before setting any custom
229-
* metadata on an asset, you have to create the field using custom metadata fields
230-
* API. Send `customMetadata` in `responseFields` in API request to get the value
231-
* of this field.
226+
* An object with custom metadata for the file.
232227
*/
233228
customMetadata?: { [key: string]: unknown };
234229

@@ -245,8 +240,7 @@ export interface File {
245240

246241
/**
247242
* Consolidated embedded metadata associated with the file. It includes exif, iptc,
248-
* and xmp data. Send `embeddedMetadata` in `responseFields` in API request to get
249-
* embeddedMetadata in the upload API response.
243+
* and xmp data.
250244
*/
251245
embeddedMetadata?: { [key: string]: unknown };
252246

@@ -343,7 +337,7 @@ export interface File {
343337
url?: string;
344338

345339
/**
346-
* An object containing the file or file version's `id` (versionId) and `name`.
340+
* An object with details of the file version.
347341
*/
348342
versionInfo?: File.VersionInfo;
349343

@@ -359,6 +353,10 @@ export interface File {
359353
}
360354

361355
export namespace File {
356+
/**
357+
* AI-generated tag associated with an image. These tags can be added using the
358+
* `google-auto-tagging` or `aws-auto-tagging` extensions.
359+
*/
362360
export interface AITag {
363361
/**
364362
* Confidence score of the tag.
@@ -842,9 +840,7 @@ export interface FileRenameResponse {
842840
*/
843841
export interface FileUploadResponse {
844842
/**
845-
* Array of `AITags` associated with the image. If no `AITags` are set, it will be
846-
* null. These tags can be added using the `google-auto-tagging` or
847-
* `aws-auto-tagging` extensions.
843+
* An array of tags assigned to the uploaded file by auto tagging.
848844
*/
849845
AITags?: Array<FileUploadResponse.AITag> | null;
850846

@@ -1003,6 +999,10 @@ export interface FileUploadResponse {
1003999
}
10041000

10051001
export namespace FileUploadResponse {
1002+
/**
1003+
* AI-generated tag associated with an image. These tags can be added using the
1004+
* `google-auto-tagging` or `aws-auto-tagging` extensions.
1005+
*/
10061006
export interface AITag {
10071007
/**
10081008
* Confidence score of the tag.

src/resources/webhooks.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -391,9 +391,7 @@ export namespace UploadPreTransformSuccessEvent {
391391
*/
392392
export interface Data {
393393
/**
394-
* Array of `AITags` associated with the image. If no `AITags` are set, it will be
395-
* null. These tags can be added using the `google-auto-tagging` or
396-
* `aws-auto-tagging` extensions.
394+
* An array of tags assigned to the uploaded file by auto tagging.
397395
*/
398396
AITags?: Array<Data.AITag> | null;
399397

@@ -552,6 +550,10 @@ export namespace UploadPreTransformSuccessEvent {
552550
}
553551

554552
export namespace Data {
553+
/**
554+
* AI-generated tag associated with an image. These tags can be added using the
555+
* `google-auto-tagging` or `aws-auto-tagging` extensions.
556+
*/
555557
export interface AITag {
556558
/**
557559
* Confidence score of the tag.

0 commit comments

Comments
 (0)