magic-hour 0.98.0 → 0.99.0

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 (38) hide show
  1. package/README.md +24 -0
  2. package/dist/environment.d.ts +1 -1
  3. package/dist/environment.js +1 -1
  4. package/dist/resources/v1/ai-image-editor/request-types.d.ts +5 -0
  5. package/dist/resources/v1/ai-image-generator/request-types.d.ts +5 -0
  6. package/dist/resources/v1/estimate/image/index.d.ts +2 -0
  7. package/dist/resources/v1/estimate/image/index.js +5 -0
  8. package/dist/resources/v1/estimate/image/request-types.d.ts +47 -0
  9. package/dist/resources/v1/estimate/image/request-types.js +117 -0
  10. package/dist/resources/v1/estimate/image/resource-client.d.ts +14 -0
  11. package/dist/resources/v1/estimate/image/resource-client.js +116 -0
  12. package/dist/resources/v1/estimate/index.d.ts +2 -0
  13. package/dist/resources/v1/estimate/index.js +39 -0
  14. package/dist/resources/v1/estimate/resource-client.d.ts +7 -0
  15. package/dist/resources/v1/estimate/resource-client.js +17 -0
  16. package/dist/resources/v1/index.d.ts +1 -0
  17. package/dist/resources/v1/index.js +2 -1
  18. package/dist/resources/v1/resource-client.d.ts +3 -0
  19. package/dist/resources/v1/resource-client.js +5 -0
  20. package/dist/types/index.d.ts +4 -0
  21. package/dist/types/v1-account-list-response-auto-reload-status-enum.d.ts +11 -0
  22. package/dist/types/v1-account-list-response-auto-reload-status-enum.js +2 -0
  23. package/dist/types/v1-account-list-response-auto-reload.d.ts +29 -0
  24. package/dist/types/v1-account-list-response-auto-reload.js +79 -0
  25. package/dist/types/v1-account-list-response.d.ts +3 -0
  26. package/dist/types/v1-account-list-response.js +5 -0
  27. package/dist/types/v1-ai-image-editor-create-body-model-enum.d.ts +4 -0
  28. package/dist/types/v1-ai-image-editor-create-body-resolution-enum.d.ts +1 -0
  29. package/dist/types/v1-ai-image-editor-create-body.d.ts +5 -0
  30. package/dist/types/v1-ai-image-generator-create-body-model-enum.d.ts +4 -0
  31. package/dist/types/v1-ai-image-generator-create-body-resolution-enum.d.ts +1 -0
  32. package/dist/types/v1-ai-image-generator-create-body.d.ts +5 -0
  33. package/dist/types/v1-estimate-image-list-response.d.ts +22 -0
  34. package/dist/types/v1-estimate-image-list-response.js +67 -0
  35. package/dist/types/v1-estimate-image-list-tool-enum.d.ts +4 -0
  36. package/dist/types/v1-estimate-image-list-tool-enum.js +2 -0
  37. package/dist/types/v1-video-projects-get-response.d.ts +1 -1
  38. package/package.json +1 -1
package/README.md CHANGED
@@ -200,6 +200,26 @@ try {
200
200
  }
201
201
  ```
202
202
 
203
+ ## Idempotent Requests
204
+
205
+ Project create endpoints accept an `Idempotency-Key` header, so you can safely retry a request without creating or paying for a second project. Repeating a key within 24 hours returns the original project. Keys are shared across your account, so use a new key, such as a UUID, for each project.
206
+
207
+ ```ts
208
+ await client.v1.aiImageGenerator.create(
209
+ { imageCount: 1, style: { prompt: "Cool image" } },
210
+ { additionalHeaders: { "Idempotency-Key": "5f3c1b9e-8a41-4a0e-9d3e-2f6a1c7b9e10" } },
211
+ );
212
+ ```
213
+
214
+ With `generate()`:
215
+
216
+ ```ts
217
+ await client.v1.aiImageGenerator.generate(
218
+ { imageCount: 1, style: { prompt: "Cool image" } },
219
+ { additionalHeaders: { "Idempotency-Key": "5f3c1b9e-8a41-4a0e-9d3e-2f6a1c7b9e10" } },
220
+ );
221
+ ```
222
+
203
223
  ## Logging
204
224
 
205
225
  ### Logging Levels
@@ -345,6 +365,10 @@ Valid values are: `none`, `error`, `warn`, `info`, `debug` (case insensitive). I
345
365
  - [create](src/resources/v1/character-replace/README.md#create) - Character Replace
346
366
  - [generate](src/resources/v1/character-replace/README.md#generate) - Character Replace Generate Workflow
347
367
 
368
+ ### [v1.estimate.image](src/resources/v1/estimate/image/README.md)
369
+
370
+ - [list](src/resources/v1/estimate/image/README.md#list) - Estimate image credits
371
+
348
372
  ### [v1.faceDetection](src/resources/v1/face-detection/README.md)
349
373
 
350
374
  - [create](src/resources/v1/face-detection/README.md#create) - Face Detection
@@ -1,4 +1,4 @@
1
1
  export declare enum Environment {
2
2
  Environment = "https://api.magichour.ai",
3
- MockServer = "https://api.sideko.dev/v1/mock/magichour/magic-hour/0.103.0"
3
+ MockServer = "https://api.sideko.dev/v1/mock/magichour/magic-hour/0.105.0"
4
4
  }
@@ -4,5 +4,5 @@ exports.Environment = void 0;
4
4
  var Environment;
5
5
  (function (Environment) {
6
6
  Environment["Environment"] = "https://api.magichour.ai";
7
- Environment["MockServer"] = "https://api.sideko.dev/v1/mock/magichour/magic-hour/0.103.0";
7
+ Environment["MockServer"] = "https://api.sideko.dev/v1/mock/magichour/magic-hour/0.105.0";
8
8
  })(Environment || (exports.Environment = Environment = {}));
@@ -46,6 +46,10 @@ export type CreateRequest = {
46
46
  * - Supported resolutions: 640px, 1k
47
47
  * - Available for tiers: creator, pro, business
48
48
  * - Max additional input images: 9
49
+ * - `nano-banana-2` - from 100 credits/image
50
+ * - Supported resolutions: 640px, 1k, 2k, 4k
51
+ * - Available for tiers: creator, pro, business
52
+ * - Max additional input images: 9
49
53
  * - `nano-banana-2-lite` - from 50 credits/image
50
54
  * - Supported resolutions: 640px, 1k
51
55
  * - Available for tiers: creator, pro, business
@@ -106,6 +110,7 @@ export type CreateRequest = {
106
110
  * - `gpt-image-2.5-flare` - 640px, 1k, 2k, 4k
107
111
  * - `krea-2` - 640px, 1k
108
112
  * - `nano-banana` - 640px, 1k
113
+ * - `nano-banana-2` - 640px, 1k, 2k, 4k
109
114
  * - `nano-banana-2-lite` - 640px, 1k
110
115
  * - `nano-banana-2.1` - 640px, 1k, 2k, 4k
111
116
  * - `nano-banana-pro` - 1k, 2k, 4k
@@ -45,6 +45,10 @@ export type CreateRequest = {
45
45
  * - Supported resolutions: 640px, 1k
46
46
  * - Available for tiers: creator, pro, business
47
47
  * - Image count allowed: 1, 2, 3, 4
48
+ * - `nano-banana-2` - from 100 credits/image
49
+ * - Supported resolutions: 640px, 1k, 2k, 4k
50
+ * - Available for tiers: creator, pro, business
51
+ * - Image count allowed: 1, 4, 9, 16
48
52
  * - `nano-banana-2-lite` - from 50 credits/image
49
53
  * - Supported resolutions: 640px, 1k
50
54
  * - Available for tiers: creator, pro, business
@@ -115,6 +119,7 @@ export type CreateRequest = {
115
119
  * - `gpt-image-2.5-flare` - 640px, 1k, 2k, 4k
116
120
  * - `krea-2` - 640px, 1k
117
121
  * - `nano-banana` - 640px, 1k
122
+ * - `nano-banana-2` - 640px, 1k, 2k, 4k
118
123
  * - `nano-banana-2-lite` - 640px, 1k
119
124
  * - `nano-banana-2.1` - 640px, 1k, 2k, 4k
120
125
  * - `nano-banana-pro` - 1k, 2k, 4k
@@ -0,0 +1,2 @@
1
+ export { ListRequest } from "./request-types";
2
+ export { ImageClient } from "./resource-client";
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ImageClient = void 0;
4
+ var resource_client_1 = require("./resource-client");
5
+ Object.defineProperty(exports, "ImageClient", { enumerable: true, get: function () { return resource_client_1.ImageClient; } });
@@ -0,0 +1,47 @@
1
+ import * as z from "zod";
2
+ /**
3
+ * ListRequest
4
+ */
5
+ export type ListRequest = {
6
+ /**
7
+ * The create endpoint to price, named by its path. For example `ai-image-editor` for `POST /v1/ai-image-editor`.
8
+ */
9
+ tool: "ai-clothes-changer" | "ai-face-editor" | "ai-gif-generator" | "ai-headshot-generator" | "ai-image-editor" | "ai-image-generator" | "ai-image-upscaler" | "ai-meme-generator" | "ai-qr-code-generator" | "body-swap" | "face-swap-photo" | "head-swap" | "image-background-remover" | "photo-colorizer";
10
+ /**
11
+ * The `image_count` of the create request. Used by `ai-image-generator`, `ai-image-editor`. Defaults to 1.
12
+ */
13
+ imageCount?: number | undefined;
14
+ /**
15
+ * The `style.mode` of the create request. Used by `ai-image-upscaler`. One of `preserve`, `balanced`, `creative`. Defaults to `balanced`.
16
+ */
17
+ mode?: string | undefined;
18
+ /**
19
+ * The `model` of the create request. Used by `ai-image-generator`, `ai-image-editor`.
20
+ */
21
+ model?: string | undefined;
22
+ /**
23
+ * The `resolution` of the create request. Used by `ai-image-generator`, `ai-image-editor`, `body-swap`. One of `640px`, `1k`, `2k`, `4k`.
24
+ */
25
+ resolution?: string | undefined;
26
+ /**
27
+ * The `scale_factor` of the create request. Used by `ai-image-upscaler`. One of `2`, `4`.
28
+ */
29
+ scaleFactor?: number | undefined;
30
+ };
31
+ /**
32
+ * @internal
33
+ * ListRequest without any key transformation, this is what
34
+ * we expect to come in as network data
35
+ */
36
+ export type External$ListRequest = {
37
+ tool: "ai-clothes-changer" | "ai-face-editor" | "ai-gif-generator" | "ai-headshot-generator" | "ai-image-editor" | "ai-image-generator" | "ai-image-upscaler" | "ai-meme-generator" | "ai-qr-code-generator" | "body-swap" | "face-swap-photo" | "head-swap" | "image-background-remover" | "photo-colorizer";
38
+ image_count?: number | undefined;
39
+ mode?: string | undefined;
40
+ model?: string | undefined;
41
+ resolution?: string | undefined;
42
+ scale_factor?: number | undefined;
43
+ };
44
+ export declare const Schemas$ListRequest: {
45
+ in: z.ZodType<ListRequest, z.ZodTypeDef, unknown>;
46
+ out: z.ZodType<External$ListRequest, z.ZodTypeDef, ListRequest>;
47
+ };
@@ -0,0 +1,117 @@
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.Schemas$ListRequest = void 0;
37
+ const make_api_request_js_1 = require("make-api-request-js");
38
+ const z = __importStar(require("zod"));
39
+ /**
40
+ * Takes network data, validates it, and transforms keys to match typescript object ListRequest
41
+ */
42
+ const SchemaIn$ListRequest = z
43
+ .object({
44
+ tool: z.enum([
45
+ "ai-clothes-changer",
46
+ "ai-face-editor",
47
+ "ai-gif-generator",
48
+ "ai-headshot-generator",
49
+ "ai-image-editor",
50
+ "ai-image-generator",
51
+ "ai-image-upscaler",
52
+ "ai-meme-generator",
53
+ "ai-qr-code-generator",
54
+ "body-swap",
55
+ "face-swap-photo",
56
+ "head-swap",
57
+ "image-background-remover",
58
+ "photo-colorizer",
59
+ ]),
60
+ image_count: z.number().int().optional(),
61
+ mode: z.string().optional(),
62
+ model: z.string().optional(),
63
+ resolution: z.string().optional(),
64
+ scale_factor: z.number().optional(),
65
+ })
66
+ .transform((obj) => {
67
+ return (0, make_api_request_js_1.zodTransform)(obj, {
68
+ tool: "tool",
69
+ image_count: "imageCount",
70
+ mode: "mode",
71
+ model: "model",
72
+ resolution: "resolution",
73
+ scale_factor: "scaleFactor",
74
+ });
75
+ });
76
+ /**
77
+ * @internal
78
+ * Takes typescript data, validates it, and maps keys to match the expected external object External$ListRequest
79
+ */
80
+ const SchemaOut$ListRequest = z
81
+ .object({
82
+ tool: z.enum([
83
+ "ai-clothes-changer",
84
+ "ai-face-editor",
85
+ "ai-gif-generator",
86
+ "ai-headshot-generator",
87
+ "ai-image-editor",
88
+ "ai-image-generator",
89
+ "ai-image-upscaler",
90
+ "ai-meme-generator",
91
+ "ai-qr-code-generator",
92
+ "body-swap",
93
+ "face-swap-photo",
94
+ "head-swap",
95
+ "image-background-remover",
96
+ "photo-colorizer",
97
+ ]),
98
+ imageCount: z.number().int().optional(),
99
+ mode: z.string().optional(),
100
+ model: z.string().optional(),
101
+ resolution: z.string().optional(),
102
+ scaleFactor: z.number().optional(),
103
+ })
104
+ .transform((obj) => {
105
+ return (0, make_api_request_js_1.zodTransform)(obj, {
106
+ tool: "tool",
107
+ imageCount: "image_count",
108
+ mode: "mode",
109
+ model: "model",
110
+ resolution: "resolution",
111
+ scaleFactor: "scale_factor",
112
+ });
113
+ });
114
+ exports.Schemas$ListRequest = {
115
+ in: SchemaIn$ListRequest,
116
+ out: SchemaOut$ListRequest,
117
+ };
@@ -0,0 +1,14 @@
1
+ import { ApiPromise, CoreClient, CoreResourceClient, RequestOptions, ResourceClientOptions } from "make-api-request-js";
2
+ import * as requests from "./request-types.js";
3
+ import * as types from "../../../../types/index.js";
4
+ export declare class ImageClient extends CoreResourceClient {
5
+ constructor(coreClient: CoreClient, opts: ResourceClientOptions);
6
+ /**
7
+ * Estimate image credits
8
+ *
9
+ * Get the credits an image create request charges. Pass `tool`, then the fields below that the tool's create request uses, with the same values. Does not create a project or spend credits. It prices the fields passed here. It does not check your plan, your balance or the rest of the create request.
10
+ *
11
+ * GET /v1/estimate/image
12
+ */
13
+ list(request: requests.ListRequest, opts?: RequestOptions): ApiPromise<types.V1EstimateImageListResponse>;
14
+ }
@@ -0,0 +1,116 @@
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.ImageClient = void 0;
37
+ const make_api_request_js_1 = require("make-api-request-js");
38
+ const z = __importStar(require("zod"));
39
+ const v1_estimate_image_list_response_1 = require("../../../../types/v1-estimate-image-list-response.js");
40
+ class ImageClient extends make_api_request_js_1.CoreResourceClient {
41
+ constructor(coreClient, opts) {
42
+ super(coreClient, opts);
43
+ }
44
+ /**
45
+ * Estimate image credits
46
+ *
47
+ * Get the credits an image create request charges. Pass `tool`, then the fields below that the tool's create request uses, with the same values. Does not create a project or spend credits. It prices the fields passed here. It does not check your plan, your balance or the rest of the create request.
48
+ *
49
+ * GET /v1/estimate/image
50
+ */
51
+ list(request, opts) {
52
+ return this._client.makeRequest({
53
+ method: "get",
54
+ path: "/v1/estimate/image",
55
+ auth: ["bearerAuth"],
56
+ query: [
57
+ (0, make_api_request_js_1.encodeQueryParam)({
58
+ name: "tool",
59
+ value: z
60
+ .enum([
61
+ "ai-clothes-changer",
62
+ "ai-face-editor",
63
+ "ai-gif-generator",
64
+ "ai-headshot-generator",
65
+ "ai-image-editor",
66
+ "ai-image-generator",
67
+ "ai-image-upscaler",
68
+ "ai-meme-generator",
69
+ "ai-qr-code-generator",
70
+ "body-swap",
71
+ "face-swap-photo",
72
+ "head-swap",
73
+ "image-background-remover",
74
+ "photo-colorizer",
75
+ ])
76
+ .parse(request.tool),
77
+ style: "form",
78
+ explode: true,
79
+ }),
80
+ (0, make_api_request_js_1.encodeQueryParam)({
81
+ name: "image_count",
82
+ value: z.number().int().optional().parse(request.imageCount),
83
+ style: "form",
84
+ explode: true,
85
+ }),
86
+ (0, make_api_request_js_1.encodeQueryParam)({
87
+ name: "mode",
88
+ value: z.string().optional().parse(request.mode),
89
+ style: "form",
90
+ explode: true,
91
+ }),
92
+ (0, make_api_request_js_1.encodeQueryParam)({
93
+ name: "model",
94
+ value: z.string().optional().parse(request.model),
95
+ style: "form",
96
+ explode: true,
97
+ }),
98
+ (0, make_api_request_js_1.encodeQueryParam)({
99
+ name: "resolution",
100
+ value: z.string().optional().parse(request.resolution),
101
+ style: "form",
102
+ explode: true,
103
+ }),
104
+ (0, make_api_request_js_1.encodeQueryParam)({
105
+ name: "scale_factor",
106
+ value: z.number().optional().parse(request.scaleFactor),
107
+ style: "form",
108
+ explode: true,
109
+ }),
110
+ ],
111
+ responseSchema: v1_estimate_image_list_response_1.Schemas$V1EstimateImageListResponse.in,
112
+ opts,
113
+ });
114
+ }
115
+ }
116
+ exports.ImageClient = ImageClient;
@@ -0,0 +1,2 @@
1
+ export * as image from "./image";
2
+ export { EstimateClient } from "./resource-client";
@@ -0,0 +1,39 @@
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.EstimateClient = exports.image = void 0;
37
+ exports.image = __importStar(require("./image"));
38
+ var resource_client_1 = require("./resource-client");
39
+ Object.defineProperty(exports, "EstimateClient", { enumerable: true, get: function () { return resource_client_1.EstimateClient; } });
@@ -0,0 +1,7 @@
1
+ import { CoreClient, CoreResourceClient, ResourceClientOptions } from "make-api-request-js";
2
+ import { ImageClient } from "./image/index.js";
3
+ export declare class EstimateClient extends CoreResourceClient {
4
+ private _imageLazy?;
5
+ constructor(coreClient: CoreClient, opts: ResourceClientOptions);
6
+ get image(): ImageClient;
7
+ }
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.EstimateClient = void 0;
4
+ const make_api_request_js_1 = require("make-api-request-js");
5
+ class EstimateClient extends make_api_request_js_1.CoreResourceClient {
6
+ constructor(coreClient, opts) {
7
+ super(coreClient, opts);
8
+ if (this._opts.lazyLoad === false) {
9
+ this.image;
10
+ }
11
+ }
12
+ get image() {
13
+ var _a;
14
+ return ((_a = this._imageLazy) !== null && _a !== void 0 ? _a : (this._imageLazy = new (require("./image").ImageClient)(this._client, this._opts)));
15
+ }
16
+ }
17
+ exports.EstimateClient = EstimateClient;
@@ -22,6 +22,7 @@ export * as audioToVideo from "./audio-to-video";
22
22
  export * as autoSubtitleGenerator from "./auto-subtitle-generator";
23
23
  export * as bodySwap from "./body-swap";
24
24
  export * as characterReplace from "./character-replace";
25
+ export * as estimate from "./estimate";
25
26
  export * as faceDetection from "./face-detection";
26
27
  export * as faceSwap from "./face-swap";
27
28
  export * as faceSwapPhoto from "./face-swap-photo";
@@ -33,7 +33,7 @@ var __importStar = (this && this.__importStar) || (function () {
33
33
  };
34
34
  })();
35
35
  Object.defineProperty(exports, "__esModule", { value: true });
36
- exports.voices = exports.videoToVideo = exports.videoProjects = exports.textToVideo = exports.savedItems = exports.V1Client = exports.photoColorizer = exports.lipSync = exports.imageToVideo = exports.imageProjects = exports.imageBackgroundRemover = exports.headSwap = exports.files = exports.faceSwapPhoto = exports.faceSwap = exports.faceDetection = exports.characterReplace = exports.bodySwap = exports.autoSubtitleGenerator = exports.audioToVideo = exports.audioProjects = exports.animation = exports.aiVoiceGenerator = exports.aiVoiceCloner = exports.aiVideoUpscaler = exports.aiVideoTranslator = exports.aiVideoEditor = exports.aiUgcAd = exports.aiTalkingPhoto = exports.aiQrCodeGenerator = exports.aiMusicGenerator = exports.aiMemeGenerator = exports.aiImageUpscaler = exports.aiImageGenerator = exports.aiImageEditor = exports.aiHeadshotGenerator = exports.aiGifGenerator = exports.aiFaceEditor = exports.aiClothesChanger = exports.account = void 0;
36
+ exports.voices = exports.videoToVideo = exports.videoProjects = exports.textToVideo = exports.savedItems = exports.V1Client = exports.photoColorizer = exports.lipSync = exports.imageToVideo = exports.imageProjects = exports.imageBackgroundRemover = exports.headSwap = exports.files = exports.faceSwapPhoto = exports.faceSwap = exports.faceDetection = exports.estimate = exports.characterReplace = exports.bodySwap = exports.autoSubtitleGenerator = exports.audioToVideo = exports.audioProjects = exports.animation = exports.aiVoiceGenerator = exports.aiVoiceCloner = exports.aiVideoUpscaler = exports.aiVideoTranslator = exports.aiVideoEditor = exports.aiUgcAd = exports.aiTalkingPhoto = exports.aiQrCodeGenerator = exports.aiMusicGenerator = exports.aiMemeGenerator = exports.aiImageUpscaler = exports.aiImageGenerator = exports.aiImageEditor = exports.aiHeadshotGenerator = exports.aiGifGenerator = exports.aiFaceEditor = exports.aiClothesChanger = exports.account = void 0;
37
37
  exports.account = __importStar(require("./account"));
38
38
  exports.aiClothesChanger = __importStar(require("./ai-clothes-changer"));
39
39
  exports.aiFaceEditor = __importStar(require("./ai-face-editor"));
@@ -58,6 +58,7 @@ exports.audioToVideo = __importStar(require("./audio-to-video"));
58
58
  exports.autoSubtitleGenerator = __importStar(require("./auto-subtitle-generator"));
59
59
  exports.bodySwap = __importStar(require("./body-swap"));
60
60
  exports.characterReplace = __importStar(require("./character-replace"));
61
+ exports.estimate = __importStar(require("./estimate"));
61
62
  exports.faceDetection = __importStar(require("./face-detection"));
62
63
  exports.faceSwap = __importStar(require("./face-swap"));
63
64
  exports.faceSwapPhoto = __importStar(require("./face-swap-photo"));
@@ -23,6 +23,7 @@ import { AudioToVideoClient } from "./audio-to-video/index.js";
23
23
  import { AutoSubtitleGeneratorClient } from "./auto-subtitle-generator/index.js";
24
24
  import { BodySwapClient } from "./body-swap/index.js";
25
25
  import { CharacterReplaceClient } from "./character-replace/index.js";
26
+ import { EstimateClient } from "./estimate/index.js";
26
27
  import { FaceDetectionClient } from "./face-detection/index.js";
27
28
  import { FaceSwapClient } from "./face-swap/index.js";
28
29
  import { FaceSwapPhotoClient } from "./face-swap-photo/index.js";
@@ -39,6 +40,7 @@ import { VideoProjectsClient } from "./video-projects/index.js";
39
40
  import { VideoToVideoClient } from "./video-to-video/index.js";
40
41
  import { VoicesClient } from "./voices/index.js";
41
42
  export declare class V1Client extends CoreResourceClient {
43
+ private _estimateLazy?;
42
44
  private _voicesLazy?;
43
45
  private _aiVideoUpscalerLazy?;
44
46
  private _aiMusicGeneratorLazy?;
@@ -118,4 +120,5 @@ export declare class V1Client extends CoreResourceClient {
118
120
  get aiMusicGenerator(): AiMusicGeneratorClient;
119
121
  get aiVideoUpscaler(): AiVideoUpscalerClient;
120
122
  get voices(): VoicesClient;
123
+ get estimate(): EstimateClient;
121
124
  }
@@ -30,6 +30,7 @@ class V1Client extends make_api_request_js_1.CoreResourceClient {
30
30
  this.autoSubtitleGenerator;
31
31
  this.bodySwap;
32
32
  this.characterReplace;
33
+ this.estimate;
33
34
  this.faceDetection;
34
35
  this.faceSwap;
35
36
  this.faceSwapPhoto;
@@ -232,5 +233,9 @@ class V1Client extends make_api_request_js_1.CoreResourceClient {
232
233
  var _a;
233
234
  return ((_a = this._voicesLazy) !== null && _a !== void 0 ? _a : (this._voicesLazy = new (require("./voices").VoicesClient)(this._client, this._opts)));
234
235
  }
236
+ get estimate() {
237
+ var _a;
238
+ return ((_a = this._estimateLazy) !== null && _a !== void 0 ? _a : (this._estimateLazy = new (require("./estimate").EstimateClient)(this._client, this._opts)));
239
+ }
235
240
  }
236
241
  exports.V1Client = V1Client;
@@ -2,6 +2,8 @@ export { V1AccountCheckoutCreateBody } from "./v1-account-checkout-create-body";
2
2
  export { V1AccountCheckoutCreateBodyTypeEnum } from "./v1-account-checkout-create-body-type-enum";
3
3
  export { V1AccountCheckoutCreateResponse } from "./v1-account-checkout-create-response";
4
4
  export { V1AccountListResponse } from "./v1-account-list-response";
5
+ export { V1AccountListResponseAutoReload } from "./v1-account-list-response-auto-reload";
6
+ export { V1AccountListResponseAutoReloadStatusEnum } from "./v1-account-list-response-auto-reload-status-enum";
5
7
  export { V1AccountListResponseSubscription } from "./v1-account-list-response-subscription";
6
8
  export { V1AccountListResponseSubscriptionBillingIntervalEnum } from "./v1-account-list-response-subscription-billing-interval-enum";
7
9
  export { V1AccountListResponseSubscriptionDiscount } from "./v1-account-list-response-subscription-discount";
@@ -130,6 +132,8 @@ export { V1CharacterReplaceCreateBodyStyleModeEnum } from "./v1-character-replac
130
132
  export { V1CharacterReplaceCreateBodyStylePointsItem } from "./v1-character-replace-create-body-style-points-item";
131
133
  export { V1CharacterReplaceCreateBodyStyleSelectionModeEnum } from "./v1-character-replace-create-body-style-selection-mode-enum";
132
134
  export { V1CharacterReplaceCreateResponse } from "./v1-character-replace-create-response";
135
+ export { V1EstimateImageListResponse } from "./v1-estimate-image-list-response";
136
+ export { V1EstimateImageListToolEnum } from "./v1-estimate-image-list-tool-enum";
133
137
  export { V1FaceDetectionCreateBody } from "./v1-face-detection-create-body";
134
138
  export { V1FaceDetectionCreateBodyAssets } from "./v1-face-detection-create-body-assets";
135
139
  export { V1FaceDetectionCreateResponse } from "./v1-face-detection-create-response";
@@ -0,0 +1,11 @@
1
+ /**
2
+ * State of Auto Reload on the account.
3
+ * - `disabled`: off or never set up.
4
+ * - `active`: on, with no refill processing or blocked.
5
+ * - `auto_reload_pending`: a refill is processing. Check again shortly.
6
+ * - `payment_failed`: the last refill payment failed and paused Auto Reload until the payment method is updated.
7
+ * - `spending_limit_reached`: the monthly limit blocked the last refill.
8
+ *
9
+ * After an `insufficient_credits` rejection, resubmit the same request once `credits` reaches that rejection's `credits_required`.
10
+ */
11
+ export type V1AccountListResponseAutoReloadStatusEnum = "active" | "auto_reload_pending" | "disabled" | "payment_failed" | "spending_limit_reached";
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,29 @@
1
+ import * as z from "zod";
2
+ /**
3
+ * V1AccountListResponseAutoReload
4
+ */
5
+ export type V1AccountListResponseAutoReload = {
6
+ /**
7
+ * State of Auto Reload on the account.
8
+ * - `disabled`: off or never set up.
9
+ * - `active`: on, with no refill processing or blocked.
10
+ * - `auto_reload_pending`: a refill is processing. Check again shortly.
11
+ * - `payment_failed`: the last refill payment failed and paused Auto Reload until the payment method is updated.
12
+ * - `spending_limit_reached`: the monthly limit blocked the last refill.
13
+ *
14
+ * After an `insufficient_credits` rejection, resubmit the same request once `credits` reaches that rejection's `credits_required`.
15
+ */
16
+ status: "active" | "auto_reload_pending" | "disabled" | "payment_failed" | "spending_limit_reached";
17
+ };
18
+ /**
19
+ * @internal
20
+ * V1AccountListResponseAutoReload without any key transformation, this is what
21
+ * we expect to come in as network data
22
+ */
23
+ export type External$V1AccountListResponseAutoReload = {
24
+ status: "active" | "auto_reload_pending" | "disabled" | "payment_failed" | "spending_limit_reached";
25
+ };
26
+ export declare const Schemas$V1AccountListResponseAutoReload: {
27
+ in: z.ZodType<V1AccountListResponseAutoReload, z.ZodTypeDef, unknown>;
28
+ out: z.ZodType<External$V1AccountListResponseAutoReload, z.ZodTypeDef, V1AccountListResponseAutoReload>;
29
+ };
@@ -0,0 +1,79 @@
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.Schemas$V1AccountListResponseAutoReload = void 0;
37
+ const make_api_request_js_1 = require("make-api-request-js");
38
+ const z = __importStar(require("zod"));
39
+ /**
40
+ * Takes network data, validates it, and transforms keys to match typescript object V1AccountListResponseAutoReload
41
+ */
42
+ const SchemaIn$V1AccountListResponseAutoReload = z
43
+ .object({
44
+ status: z.enum([
45
+ "active",
46
+ "auto_reload_pending",
47
+ "disabled",
48
+ "payment_failed",
49
+ "spending_limit_reached",
50
+ ]),
51
+ })
52
+ .transform((obj) => {
53
+ return (0, make_api_request_js_1.zodTransform)(obj, {
54
+ status: "status",
55
+ });
56
+ });
57
+ /**
58
+ * @internal
59
+ * Takes typescript data, validates it, and maps keys to match the expected external object External$V1AccountListResponseAutoReload
60
+ */
61
+ const SchemaOut$V1AccountListResponseAutoReload = z
62
+ .object({
63
+ status: z.enum([
64
+ "active",
65
+ "auto_reload_pending",
66
+ "disabled",
67
+ "payment_failed",
68
+ "spending_limit_reached",
69
+ ]),
70
+ })
71
+ .transform((obj) => {
72
+ return (0, make_api_request_js_1.zodTransform)(obj, {
73
+ status: "status",
74
+ });
75
+ });
76
+ exports.Schemas$V1AccountListResponseAutoReload = {
77
+ in: SchemaIn$V1AccountListResponseAutoReload,
78
+ out: SchemaOut$V1AccountListResponseAutoReload,
79
+ };
@@ -1,9 +1,11 @@
1
1
  import * as z from "zod";
2
+ import { External$V1AccountListResponseAutoReload, V1AccountListResponseAutoReload } from "./v1-account-list-response-auto-reload";
2
3
  import { External$V1AccountListResponseSubscription, V1AccountListResponseSubscription } from "./v1-account-list-response-subscription";
3
4
  /**
4
5
  * V1AccountListResponse
5
6
  */
6
7
  export type V1AccountListResponse = {
8
+ autoReload: V1AccountListResponseAutoReload;
7
9
  /**
8
10
  * Credits currently available to spend. Includes subscription credits and any purchased credit packs.
9
11
  */
@@ -33,6 +35,7 @@ export type V1AccountListResponse = {
33
35
  * we expect to come in as network data
34
36
  */
35
37
  export type External$V1AccountListResponse = {
38
+ auto_reload: External$V1AccountListResponseAutoReload;
36
39
  credits: number;
37
40
  email: string | null;
38
41
  id: string;
@@ -36,12 +36,14 @@ Object.defineProperty(exports, "__esModule", { value: true });
36
36
  exports.Schemas$V1AccountListResponse = void 0;
37
37
  const make_api_request_js_1 = require("make-api-request-js");
38
38
  const z = __importStar(require("zod"));
39
+ const v1_account_list_response_auto_reload_1 = require("./v1-account-list-response-auto-reload");
39
40
  const v1_account_list_response_subscription_1 = require("./v1-account-list-response-subscription");
40
41
  /**
41
42
  * Takes network data, validates it, and transforms keys to match typescript object V1AccountListResponse
42
43
  */
43
44
  const SchemaIn$V1AccountListResponse = z
44
45
  .object({
46
+ auto_reload: v1_account_list_response_auto_reload_1.Schemas$V1AccountListResponseAutoReload.in,
45
47
  credits: z.number().int(),
46
48
  email: z.string().nullable(),
47
49
  id: z.string(),
@@ -50,6 +52,7 @@ const SchemaIn$V1AccountListResponse = z
50
52
  })
51
53
  .transform((obj) => {
52
54
  return (0, make_api_request_js_1.zodTransform)(obj, {
55
+ auto_reload: "autoReload",
53
56
  credits: "credits",
54
57
  email: "email",
55
58
  id: "id",
@@ -63,6 +66,7 @@ const SchemaIn$V1AccountListResponse = z
63
66
  */
64
67
  const SchemaOut$V1AccountListResponse = z
65
68
  .object({
69
+ autoReload: v1_account_list_response_auto_reload_1.Schemas$V1AccountListResponseAutoReload.out,
66
70
  credits: z.number().int(),
67
71
  email: z.string().nullable(),
68
72
  id: z.string(),
@@ -71,6 +75,7 @@ const SchemaOut$V1AccountListResponse = z
71
75
  })
72
76
  .transform((obj) => {
73
77
  return (0, make_api_request_js_1.zodTransform)(obj, {
78
+ autoReload: "auto_reload",
74
79
  credits: "credits",
75
80
  email: "email",
76
81
  id: "id",
@@ -27,6 +27,10 @@
27
27
  * - Supported resolutions: 640px, 1k
28
28
  * - Available for tiers: creator, pro, business
29
29
  * - Max additional input images: 9
30
+ * - `nano-banana-2` - from 100 credits/image
31
+ * - Supported resolutions: 640px, 1k, 2k, 4k
32
+ * - Available for tiers: creator, pro, business
33
+ * - Max additional input images: 9
30
34
  * - `nano-banana-2-lite` - from 50 credits/image
31
35
  * - Supported resolutions: 640px, 1k
32
36
  * - Available for tiers: creator, pro, business
@@ -15,6 +15,7 @@
15
15
  * - `gpt-image-2.5-flare` - 640px, 1k, 2k, 4k
16
16
  * - `krea-2` - 640px, 1k
17
17
  * - `nano-banana` - 640px, 1k
18
+ * - `nano-banana-2` - 640px, 1k, 2k, 4k
18
19
  * - `nano-banana-2-lite` - 640px, 1k
19
20
  * - `nano-banana-2.1` - 640px, 1k, 2k, 4k
20
21
  * - `nano-banana-pro` - 1k, 2k, 4k
@@ -46,6 +46,10 @@ export type V1AiImageEditorCreateBody = {
46
46
  * - Supported resolutions: 640px, 1k
47
47
  * - Available for tiers: creator, pro, business
48
48
  * - Max additional input images: 9
49
+ * - `nano-banana-2` - from 100 credits/image
50
+ * - Supported resolutions: 640px, 1k, 2k, 4k
51
+ * - Available for tiers: creator, pro, business
52
+ * - Max additional input images: 9
49
53
  * - `nano-banana-2-lite` - from 50 credits/image
50
54
  * - Supported resolutions: 640px, 1k
51
55
  * - Available for tiers: creator, pro, business
@@ -106,6 +110,7 @@ export type V1AiImageEditorCreateBody = {
106
110
  * - `gpt-image-2.5-flare` - 640px, 1k, 2k, 4k
107
111
  * - `krea-2` - 640px, 1k
108
112
  * - `nano-banana` - 640px, 1k
113
+ * - `nano-banana-2` - 640px, 1k, 2k, 4k
109
114
  * - `nano-banana-2-lite` - 640px, 1k
110
115
  * - `nano-banana-2.1` - 640px, 1k, 2k, 4k
111
116
  * - `nano-banana-pro` - 1k, 2k, 4k
@@ -31,6 +31,10 @@
31
31
  * - Supported resolutions: 640px, 1k
32
32
  * - Available for tiers: creator, pro, business
33
33
  * - Image count allowed: 1, 2, 3, 4
34
+ * - `nano-banana-2` - from 100 credits/image
35
+ * - Supported resolutions: 640px, 1k, 2k, 4k
36
+ * - Available for tiers: creator, pro, business
37
+ * - Image count allowed: 1, 4, 9, 16
34
38
  * - `nano-banana-2-lite` - from 50 credits/image
35
39
  * - Supported resolutions: 640px, 1k
36
40
  * - Available for tiers: creator, pro, business
@@ -16,6 +16,7 @@
16
16
  * - `gpt-image-2.5-flare` - 640px, 1k, 2k, 4k
17
17
  * - `krea-2` - 640px, 1k
18
18
  * - `nano-banana` - 640px, 1k
19
+ * - `nano-banana-2` - 640px, 1k, 2k, 4k
19
20
  * - `nano-banana-2-lite` - 640px, 1k
20
21
  * - `nano-banana-2.1` - 640px, 1k, 2k, 4k
21
22
  * - `nano-banana-pro` - 1k, 2k, 4k
@@ -45,6 +45,10 @@ export type V1AiImageGeneratorCreateBody = {
45
45
  * - Supported resolutions: 640px, 1k
46
46
  * - Available for tiers: creator, pro, business
47
47
  * - Image count allowed: 1, 2, 3, 4
48
+ * - `nano-banana-2` - from 100 credits/image
49
+ * - Supported resolutions: 640px, 1k, 2k, 4k
50
+ * - Available for tiers: creator, pro, business
51
+ * - Image count allowed: 1, 4, 9, 16
48
52
  * - `nano-banana-2-lite` - from 50 credits/image
49
53
  * - Supported resolutions: 640px, 1k
50
54
  * - Available for tiers: creator, pro, business
@@ -115,6 +119,7 @@ export type V1AiImageGeneratorCreateBody = {
115
119
  * - `gpt-image-2.5-flare` - 640px, 1k, 2k, 4k
116
120
  * - `krea-2` - 640px, 1k
117
121
  * - `nano-banana` - 640px, 1k
122
+ * - `nano-banana-2` - 640px, 1k, 2k, 4k
118
123
  * - `nano-banana-2-lite` - 640px, 1k
119
124
  * - `nano-banana-2.1` - 640px, 1k, 2k, 4k
120
125
  * - `nano-banana-pro` - 1k, 2k, 4k
@@ -0,0 +1,22 @@
1
+ import * as z from "zod";
2
+ /**
3
+ * Success
4
+ */
5
+ export type V1EstimateImageListResponse = {
6
+ /**
7
+ * Credits a create request with these fields charges.
8
+ */
9
+ estimatedCredits: number;
10
+ };
11
+ /**
12
+ * @internal
13
+ * V1EstimateImageListResponse without any key transformation, this is what
14
+ * we expect to come in as network data
15
+ */
16
+ export type External$V1EstimateImageListResponse = {
17
+ estimated_credits: number;
18
+ };
19
+ export declare const Schemas$V1EstimateImageListResponse: {
20
+ in: z.ZodType<V1EstimateImageListResponse, z.ZodTypeDef, unknown>;
21
+ out: z.ZodType<External$V1EstimateImageListResponse, z.ZodTypeDef, V1EstimateImageListResponse>;
22
+ };
@@ -0,0 +1,67 @@
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.Schemas$V1EstimateImageListResponse = void 0;
37
+ const make_api_request_js_1 = require("make-api-request-js");
38
+ const z = __importStar(require("zod"));
39
+ /**
40
+ * Takes network data, validates it, and transforms keys to match typescript object V1EstimateImageListResponse
41
+ */
42
+ const SchemaIn$V1EstimateImageListResponse = z
43
+ .object({
44
+ estimated_credits: z.number().int(),
45
+ })
46
+ .transform((obj) => {
47
+ return (0, make_api_request_js_1.zodTransform)(obj, {
48
+ estimated_credits: "estimatedCredits",
49
+ });
50
+ });
51
+ /**
52
+ * @internal
53
+ * Takes typescript data, validates it, and maps keys to match the expected external object External$V1EstimateImageListResponse
54
+ */
55
+ const SchemaOut$V1EstimateImageListResponse = z
56
+ .object({
57
+ estimatedCredits: z.number().int(),
58
+ })
59
+ .transform((obj) => {
60
+ return (0, make_api_request_js_1.zodTransform)(obj, {
61
+ estimatedCredits: "estimated_credits",
62
+ });
63
+ });
64
+ exports.Schemas$V1EstimateImageListResponse = {
65
+ in: SchemaIn$V1EstimateImageListResponse,
66
+ out: SchemaOut$V1EstimateImageListResponse,
67
+ };
@@ -0,0 +1,4 @@
1
+ /**
2
+ * The create endpoint to price, named by its path. For example `ai-image-editor` for `POST /v1/ai-image-editor`.
3
+ */
4
+ export type V1EstimateImageListToolEnum = "ai-clothes-changer" | "ai-face-editor" | "ai-gif-generator" | "ai-headshot-generator" | "ai-image-editor" | "ai-image-generator" | "ai-image-upscaler" | "ai-meme-generator" | "ai-qr-code-generator" | "body-swap" | "face-swap-photo" | "head-swap" | "image-background-remover" | "photo-colorizer";
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -70,7 +70,7 @@ export type V1VideoProjectsGetResponse = {
70
70
  */
71
71
  totalFrameCost: number;
72
72
  /**
73
- * The type of the video project. Possible values are ANIMATION, AUTO_SUBTITLE, VIDEO_TO_VIDEO, FACE_SWAP, TEXT_TO_VIDEO, IMAGE_TO_VIDEO, LIP_SYNC, TALKING_PHOTO, AVATAR, VIDEO_UPSCALER, VIDEO_EDITOR, CHARACTER_REPLACE, VIDEO_COLORIZER, VIDEO_WATERMARK_REMOVER, VIDEO_COLOR_GRADER, VIDEO_TRANSLATOR, MUSIC_VIDEO, EXTEND, AUDIO_TO_VIDEO, VIDEO_EXPANDER, UGC_AD
73
+ * The type of the video project. Possible values are ANIMATION, AUTO_SUBTITLE, VIDEO_TO_VIDEO, FACE_SWAP, TEXT_TO_VIDEO, IMAGE_TO_VIDEO, LIP_SYNC, TALKING_PHOTO, AVATAR, VIDEO_UPSCALER, VIDEO_EDITOR, CHARACTER_REPLACE, VIDEO_COLORIZER, VIDEO_WATERMARK_REMOVER, VIDEO_COLOR_GRADER, VIDEO_TRANSLATOR, MUSIC_VIDEO, VIDEO_REMIXER, MOTION_GRAPHICS, TRANSITIONS, EXTEND, AUDIO_TO_VIDEO, VIDEO_EXPANDER, UGC_AD
74
74
  */
75
75
  type: string;
76
76
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "magic-hour",
3
- "version": "0.98.0",
3
+ "version": "0.99.0",
4
4
  "main": "./dist/index.js",
5
5
  "types": "./dist/index.d.ts",
6
6
  "exports": {