magic-hour 0.55.0 → 0.56.1

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.
@@ -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.56.0"
3
+ MockServer = "https://api.sideko.dev/v1/mock/magichour/magic-hour/0.57.1"
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.56.0";
7
+ Environment["MockServer"] = "https://api.sideko.dev/v1/mock/magichour/magic-hour/0.57.1";
8
8
  })(Environment || (exports.Environment = Environment = {}));
@@ -60,7 +60,7 @@ export declare class AiFaceEditorClient extends CoreResourceClient {
60
60
  /**
61
61
  * AI Face Editor
62
62
  *
63
- * Edit facial features of an image using AI. Each edit costs 1 frame. The height/width of the output image depends on your subscription. Please refer to our [pricing](/pricing) page for more details
63
+ * Edit facial features of an image using AI. Each edit costs 1 frame. The height/width of the output image depends on your subscription. Please refer to our [pricing](https://magichour.ai/pricing) page for more details
64
64
  *
65
65
  * POST /v1/ai-face-editor
66
66
  */
@@ -96,7 +96,7 @@ class AiFaceEditorClient extends make_api_request_js_1.CoreResourceClient {
96
96
  /**
97
97
  * AI Face Editor
98
98
  *
99
- * Edit facial features of an image using AI. Each edit costs 1 frame. The height/width of the output image depends on your subscription. Please refer to our [pricing](/pricing) page for more details
99
+ * Edit facial features of an image using AI. Each edit costs 1 frame. The height/width of the output image depends on your subscription. Please refer to our [pricing](https://magichour.ai/pricing) page for more details
100
100
  *
101
101
  * POST /v1/ai-face-editor
102
102
  */
@@ -53,6 +53,17 @@ export type CreateRequest = {
53
53
  * Give your image a custom name for easy identification.
54
54
  */
55
55
  name?: string | undefined;
56
+ /**
57
+ * Maximum resolution for the generated image.
58
+ *
59
+ * **Options:**
60
+ * - `auto` - Automatic resolution (all tiers, default)
61
+ * - `2k` - Up to 2048px (requires Pro or Business tier)
62
+ * - `4k` - Up to 4096px (requires Business tier)
63
+ *
64
+ * Note: Resolution availability depends on your subscription tier. Defaults to `auto` if not specified.
65
+ */
66
+ resolution?: ("2k" | "4k" | "auto") | undefined;
56
67
  style: V1AiImageEditorCreateBodyStyle;
57
68
  };
58
69
  /**
@@ -66,6 +77,7 @@ export type External$CreateRequest = {
66
77
  image_count?: number | undefined;
67
78
  model?: ("default" | "nano-banana" | "nano-banana-2" | "nano-banana-pro" | "qwen-edit" | "seedream-v4" | "seedream-v4.5") | undefined;
68
79
  name?: string | undefined;
80
+ resolution?: ("2k" | "4k" | "auto") | undefined;
69
81
  style: External$V1AiImageEditorCreateBodyStyle;
70
82
  };
71
83
  export declare const Schemas$CreateRequest: {
@@ -60,6 +60,7 @@ const SchemaIn$CreateRequest = z
60
60
  ])
61
61
  .optional(),
62
62
  name: z.string().optional(),
63
+ resolution: z.enum(["2k", "4k", "auto"]).optional(),
63
64
  style: v1_ai_image_editor_create_body_style_1.Schemas$V1AiImageEditorCreateBodyStyle.in,
64
65
  })
65
66
  .transform((obj) => {
@@ -69,6 +70,7 @@ const SchemaIn$CreateRequest = z
69
70
  image_count: "imageCount",
70
71
  model: "model",
71
72
  name: "name",
73
+ resolution: "resolution",
72
74
  style: "style",
73
75
  });
74
76
  });
@@ -95,6 +97,7 @@ const SchemaOut$CreateRequest = z
95
97
  ])
96
98
  .optional(),
97
99
  name: z.string().optional(),
100
+ resolution: z.enum(["2k", "4k", "auto"]).optional(),
98
101
  style: v1_ai_image_editor_create_body_style_1.Schemas$V1AiImageEditorCreateBodyStyle.out,
99
102
  })
100
103
  .transform((obj) => {
@@ -104,6 +107,7 @@ const SchemaOut$CreateRequest = z
104
107
  imageCount: "image_count",
105
108
  model: "model",
106
109
  name: "name",
110
+ resolution: "resolution",
107
111
  style: "style",
108
112
  });
109
113
  });
@@ -34,11 +34,11 @@ export type CreateRequest = {
34
34
  * - Available for tiers: free, creator, pro, business
35
35
  * - Image count allowed: 1, 2, 3, 4
36
36
  * - `nano-banana-2` - 100 credits/image
37
- * - Supported resolutions: auto
37
+ * - Supported resolutions: auto, 2k, 4k
38
38
  * - Available for tiers: free, creator, pro, business
39
39
  * - Image count allowed: 1, 2, 3, 4
40
40
  * - `nano-banana-pro` - 150 credits/image
41
- * - Supported resolutions: auto
41
+ * - Supported resolutions: auto, 2k, 4k
42
42
  * - Available for tiers: creator, pro, business
43
43
  * - Image count allowed: 1, 4, 9, 16
44
44
  *
@@ -47,7 +47,7 @@ export declare class FaceDetectionClient extends CoreResourceClient {
47
47
  *
48
48
  * Detect faces in an image or video.
49
49
  *
50
- * Use this API to get the list of faces detected in the image or video to use in the [face swap photo](https://docs.magichour.ai/api-reference/face-swap-photo/face-swap-photo) or [face swap video](https://docs.magichour.ai/api-reference/face-swap/face-swap-video) API calls for multi-face swaps.
50
+ * Use this API to get the list of faces detected in the image or video to use in the [face swap photo](https://docs.magichour.ai/api-reference/image-projects/face-swap-photo) or [face swap video](https://docs.magichour.ai/api-reference/video-projects/face-swap-video) API calls for multi-face swaps.
51
51
  *
52
52
  * Note: Face detection is free to use for the near future. Pricing may change in the future.
53
53
  *
@@ -107,7 +107,7 @@ class FaceDetectionClient extends make_api_request_js_1.CoreResourceClient {
107
107
  *
108
108
  * Detect faces in an image or video.
109
109
  *
110
- * Use this API to get the list of faces detected in the image or video to use in the [face swap photo](https://docs.magichour.ai/api-reference/face-swap-photo/face-swap-photo) or [face swap video](https://docs.magichour.ai/api-reference/face-swap/face-swap-video) API calls for multi-face swaps.
110
+ * Use this API to get the list of faces detected in the image or video to use in the [face swap photo](https://docs.magichour.ai/api-reference/image-projects/face-swap-photo) or [face swap video](https://docs.magichour.ai/api-reference/video-projects/face-swap-video) API calls for multi-face swaps.
111
111
  *
112
112
  * Note: Face detection is free to use for the near future. Pricing may change in the future.
113
113
  *
@@ -78,7 +78,7 @@ export declare class FaceSwapPhotoClient extends CoreResourceClient {
78
78
  /**
79
79
  * Face Swap Photo
80
80
  *
81
- * Create a face swap photo. Each photo costs 5 credits. The height/width of the output image depends on your subscription. Please refer to our [pricing](https://magichour.ai/pricing) page for more details
81
+ * Create a face swap photo. Each photo costs 10 credits. The height/width of the output image depends on your subscription. Please refer to our [pricing](https://magichour.ai/pricing) page for more details
82
82
  *
83
83
  * POST /v1/face-swap-photo
84
84
  */
@@ -128,7 +128,7 @@ class FaceSwapPhotoClient extends make_api_request_js_1.CoreResourceClient {
128
128
  /**
129
129
  * Face Swap Photo
130
130
  *
131
- * Create a face swap photo. Each photo costs 5 credits. The height/width of the output image depends on your subscription. Please refer to our [pricing](https://magichour.ai/pricing) page for more details
131
+ * Create a face swap photo. Each photo costs 10 credits. The height/width of the output image depends on your subscription. Please refer to our [pricing](https://magichour.ai/pricing) page for more details
132
132
  *
133
133
  * POST /v1/face-swap-photo
134
134
  */
@@ -18,6 +18,7 @@ export { V1AiImageEditorCreateBody } from "./v1-ai-image-editor-create-body";
18
18
  export { V1AiImageEditorCreateBodyAspectRatioEnum } from "./v1-ai-image-editor-create-body-aspect-ratio-enum";
19
19
  export { V1AiImageEditorCreateBodyAssets } from "./v1-ai-image-editor-create-body-assets";
20
20
  export { V1AiImageEditorCreateBodyModelEnum } from "./v1-ai-image-editor-create-body-model-enum";
21
+ export { V1AiImageEditorCreateBodyResolutionEnum } from "./v1-ai-image-editor-create-body-resolution-enum";
21
22
  export { V1AiImageEditorCreateBodyStyle } from "./v1-ai-image-editor-create-body-style";
22
23
  export { V1AiImageEditorCreateBodyStyleModelEnum } from "./v1-ai-image-editor-create-body-style-model-enum";
23
24
  export { V1AiImageEditorCreateResponse } from "./v1-ai-image-editor-create-response";
@@ -0,0 +1,11 @@
1
+ /**
2
+ * Maximum resolution for the generated image.
3
+ *
4
+ * **Options:**
5
+ * - `auto` - Automatic resolution (all tiers, default)
6
+ * - `2k` - Up to 2048px (requires Pro or Business tier)
7
+ * - `4k` - Up to 4096px (requires Business tier)
8
+ *
9
+ * Note: Resolution availability depends on your subscription tier. Defaults to `auto` if not specified.
10
+ */
11
+ export type V1AiImageEditorCreateBodyResolutionEnum = "2k" | "4k" | "auto";
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -53,6 +53,17 @@ export type V1AiImageEditorCreateBody = {
53
53
  * Give your image a custom name for easy identification.
54
54
  */
55
55
  name?: string | undefined;
56
+ /**
57
+ * Maximum resolution for the generated image.
58
+ *
59
+ * **Options:**
60
+ * - `auto` - Automatic resolution (all tiers, default)
61
+ * - `2k` - Up to 2048px (requires Pro or Business tier)
62
+ * - `4k` - Up to 4096px (requires Business tier)
63
+ *
64
+ * Note: Resolution availability depends on your subscription tier. Defaults to `auto` if not specified.
65
+ */
66
+ resolution?: ("2k" | "4k" | "auto") | undefined;
56
67
  style: V1AiImageEditorCreateBodyStyle;
57
68
  };
58
69
  /**
@@ -66,6 +77,7 @@ export type External$V1AiImageEditorCreateBody = {
66
77
  image_count?: number | undefined;
67
78
  model?: ("default" | "nano-banana" | "nano-banana-2" | "nano-banana-pro" | "qwen-edit" | "seedream-v4" | "seedream-v4.5") | undefined;
68
79
  name?: string | undefined;
80
+ resolution?: ("2k" | "4k" | "auto") | undefined;
69
81
  style: External$V1AiImageEditorCreateBodyStyle;
70
82
  };
71
83
  export declare const Schemas$V1AiImageEditorCreateBody: {
@@ -60,6 +60,7 @@ const SchemaIn$V1AiImageEditorCreateBody = z
60
60
  ])
61
61
  .optional(),
62
62
  name: z.string().optional(),
63
+ resolution: z.enum(["2k", "4k", "auto"]).optional(),
63
64
  style: v1_ai_image_editor_create_body_style_1.Schemas$V1AiImageEditorCreateBodyStyle.in,
64
65
  })
65
66
  .transform((obj) => {
@@ -69,6 +70,7 @@ const SchemaIn$V1AiImageEditorCreateBody = z
69
70
  image_count: "imageCount",
70
71
  model: "model",
71
72
  name: "name",
73
+ resolution: "resolution",
72
74
  style: "style",
73
75
  });
74
76
  });
@@ -95,6 +97,7 @@ const SchemaOut$V1AiImageEditorCreateBody = z
95
97
  ])
96
98
  .optional(),
97
99
  name: z.string().optional(),
100
+ resolution: z.enum(["2k", "4k", "auto"]).optional(),
98
101
  style: v1_ai_image_editor_create_body_style_1.Schemas$V1AiImageEditorCreateBodyStyle.out,
99
102
  })
100
103
  .transform((obj) => {
@@ -104,6 +107,7 @@ const SchemaOut$V1AiImageEditorCreateBody = z
104
107
  imageCount: "image_count",
105
108
  model: "model",
106
109
  name: "name",
110
+ resolution: "resolution",
107
111
  style: "style",
108
112
  });
109
113
  });
@@ -20,11 +20,11 @@
20
20
  * - Available for tiers: free, creator, pro, business
21
21
  * - Image count allowed: 1, 2, 3, 4
22
22
  * - `nano-banana-2` - 100 credits/image
23
- * - Supported resolutions: auto
23
+ * - Supported resolutions: auto, 2k, 4k
24
24
  * - Available for tiers: free, creator, pro, business
25
25
  * - Image count allowed: 1, 2, 3, 4
26
26
  * - `nano-banana-pro` - 150 credits/image
27
- * - Supported resolutions: auto
27
+ * - Supported resolutions: auto, 2k, 4k
28
28
  * - Available for tiers: creator, pro, business
29
29
  * - Image count allowed: 1, 4, 9, 16
30
30
  *
@@ -34,11 +34,11 @@ export type V1AiImageGeneratorCreateBody = {
34
34
  * - Available for tiers: free, creator, pro, business
35
35
  * - Image count allowed: 1, 2, 3, 4
36
36
  * - `nano-banana-2` - 100 credits/image
37
- * - Supported resolutions: auto
37
+ * - Supported resolutions: auto, 2k, 4k
38
38
  * - Available for tiers: free, creator, pro, business
39
39
  * - Image count allowed: 1, 2, 3, 4
40
40
  * - `nano-banana-pro` - 150 credits/image
41
- * - Supported resolutions: auto
41
+ * - Supported resolutions: auto, 2k, 4k
42
42
  * - Available for tiers: creator, pro, business
43
43
  * - Image count allowed: 1, 4, 9, 16
44
44
  *
@@ -9,7 +9,7 @@ export type V1AiImageUpscalerCreateBodyAssets = {
9
9
  * - `file_path` field from the response of the [upload urls API](https://docs.magichour.ai/api-reference/files/generate-asset-upload-urls).
10
10
  *
11
11
  * See the [file upload guide](https://docs.magichour.ai/api-reference/files/generate-asset-upload-urls#input-file) for details.
12
- *
12
+ * . The maximum input image size is 4096x4096px.
13
13
  */
14
14
  imageFilePath: string;
15
15
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "magic-hour",
3
- "version": "0.55.0",
3
+ "version": "0.56.1",
4
4
  "main": "./dist/index.js",
5
5
  "types": "./dist/index.d.ts",
6
6
  "exports": {