@acedatacloud/sdk 2026.805.0 → 2026.809.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.
- package/dist/index.d.mts +40 -0
- package/dist/index.d.ts +40 -0
- package/dist/index.js +129 -35
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +129 -35
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/client.ts +3 -0
- package/src/resources/captcha.ts +66 -0
- package/src/resources/providers/index.ts +3 -0
- package/src/resources/providers/minimax.ts +66 -0
- package/src/resources/tasks.ts +1 -0
package/dist/index.d.mts
CHANGED
|
@@ -177,6 +177,45 @@ declare class Chat {
|
|
|
177
177
|
constructor(transport: Transport);
|
|
178
178
|
}
|
|
179
179
|
|
|
180
|
+
/** Captcha resources (`/captcha/*`). */
|
|
181
|
+
|
|
182
|
+
declare class Recognition {
|
|
183
|
+
private transport;
|
|
184
|
+
constructor(transport: Transport);
|
|
185
|
+
hcaptcha(opts?: {
|
|
186
|
+
queries?: string[];
|
|
187
|
+
question?: string;
|
|
188
|
+
async?: boolean;
|
|
189
|
+
[key: string]: unknown;
|
|
190
|
+
}): Promise<Record<string, unknown>>;
|
|
191
|
+
}
|
|
192
|
+
declare class Token {
|
|
193
|
+
private transport;
|
|
194
|
+
constructor(transport: Transport);
|
|
195
|
+
hcaptcha(opts: {
|
|
196
|
+
websiteKey: string;
|
|
197
|
+
websiteUrl: string;
|
|
198
|
+
rqdata?: string;
|
|
199
|
+
proxy?: string;
|
|
200
|
+
async?: boolean;
|
|
201
|
+
[key: string]: unknown;
|
|
202
|
+
}): Promise<Record<string, unknown>>;
|
|
203
|
+
}
|
|
204
|
+
declare class Tasks$2 {
|
|
205
|
+
private transport;
|
|
206
|
+
constructor(transport: Transport);
|
|
207
|
+
retrieve(opts: {
|
|
208
|
+
taskId: string;
|
|
209
|
+
[key: string]: unknown;
|
|
210
|
+
}): Promise<Record<string, unknown>>;
|
|
211
|
+
}
|
|
212
|
+
declare class Captcha {
|
|
213
|
+
readonly recognition: Recognition;
|
|
214
|
+
readonly token: Token;
|
|
215
|
+
readonly tasks: Tasks$2;
|
|
216
|
+
constructor(transport: Transport);
|
|
217
|
+
}
|
|
218
|
+
|
|
180
219
|
/**
|
|
181
220
|
* Task polling for long-running operations.
|
|
182
221
|
*
|
|
@@ -740,6 +779,7 @@ interface AceDataCloudOptions {
|
|
|
740
779
|
declare class AceDataCloud {
|
|
741
780
|
readonly aichat: AiChat;
|
|
742
781
|
readonly chat: Chat;
|
|
782
|
+
readonly captcha: Captcha;
|
|
743
783
|
readonly images: Images$1;
|
|
744
784
|
readonly audio: Audio;
|
|
745
785
|
readonly video: Video;
|
package/dist/index.d.ts
CHANGED
|
@@ -177,6 +177,45 @@ declare class Chat {
|
|
|
177
177
|
constructor(transport: Transport);
|
|
178
178
|
}
|
|
179
179
|
|
|
180
|
+
/** Captcha resources (`/captcha/*`). */
|
|
181
|
+
|
|
182
|
+
declare class Recognition {
|
|
183
|
+
private transport;
|
|
184
|
+
constructor(transport: Transport);
|
|
185
|
+
hcaptcha(opts?: {
|
|
186
|
+
queries?: string[];
|
|
187
|
+
question?: string;
|
|
188
|
+
async?: boolean;
|
|
189
|
+
[key: string]: unknown;
|
|
190
|
+
}): Promise<Record<string, unknown>>;
|
|
191
|
+
}
|
|
192
|
+
declare class Token {
|
|
193
|
+
private transport;
|
|
194
|
+
constructor(transport: Transport);
|
|
195
|
+
hcaptcha(opts: {
|
|
196
|
+
websiteKey: string;
|
|
197
|
+
websiteUrl: string;
|
|
198
|
+
rqdata?: string;
|
|
199
|
+
proxy?: string;
|
|
200
|
+
async?: boolean;
|
|
201
|
+
[key: string]: unknown;
|
|
202
|
+
}): Promise<Record<string, unknown>>;
|
|
203
|
+
}
|
|
204
|
+
declare class Tasks$2 {
|
|
205
|
+
private transport;
|
|
206
|
+
constructor(transport: Transport);
|
|
207
|
+
retrieve(opts: {
|
|
208
|
+
taskId: string;
|
|
209
|
+
[key: string]: unknown;
|
|
210
|
+
}): Promise<Record<string, unknown>>;
|
|
211
|
+
}
|
|
212
|
+
declare class Captcha {
|
|
213
|
+
readonly recognition: Recognition;
|
|
214
|
+
readonly token: Token;
|
|
215
|
+
readonly tasks: Tasks$2;
|
|
216
|
+
constructor(transport: Transport);
|
|
217
|
+
}
|
|
218
|
+
|
|
180
219
|
/**
|
|
181
220
|
* Task polling for long-running operations.
|
|
182
221
|
*
|
|
@@ -740,6 +779,7 @@ interface AceDataCloudOptions {
|
|
|
740
779
|
declare class AceDataCloud {
|
|
741
780
|
readonly aichat: AiChat;
|
|
742
781
|
readonly chat: Chat;
|
|
782
|
+
readonly captcha: Captcha;
|
|
743
783
|
readonly images: Images$1;
|
|
744
784
|
readonly audio: Audio;
|
|
745
785
|
readonly video: Video;
|
package/dist/index.js
CHANGED
|
@@ -490,6 +490,60 @@ var Chat = class {
|
|
|
490
490
|
}
|
|
491
491
|
};
|
|
492
492
|
|
|
493
|
+
// src/resources/captcha.ts
|
|
494
|
+
var Recognition = class {
|
|
495
|
+
constructor(transport) {
|
|
496
|
+
this.transport = transport;
|
|
497
|
+
}
|
|
498
|
+
transport;
|
|
499
|
+
hcaptcha(opts = {}) {
|
|
500
|
+
const { queries, question, ...rest } = opts;
|
|
501
|
+
const body = { ...rest };
|
|
502
|
+
if (queries !== void 0) body.queries = queries;
|
|
503
|
+
if (question !== void 0) body.question = question;
|
|
504
|
+
return this.transport.request("POST", "/captcha/recognition/hcaptcha", { json: body });
|
|
505
|
+
}
|
|
506
|
+
};
|
|
507
|
+
var Token = class {
|
|
508
|
+
constructor(transport) {
|
|
509
|
+
this.transport = transport;
|
|
510
|
+
}
|
|
511
|
+
transport;
|
|
512
|
+
hcaptcha(opts) {
|
|
513
|
+
const { websiteKey, websiteUrl, rqdata, proxy, ...rest } = opts;
|
|
514
|
+
const body = {
|
|
515
|
+
website_key: websiteKey,
|
|
516
|
+
website_url: websiteUrl,
|
|
517
|
+
...rest
|
|
518
|
+
};
|
|
519
|
+
if (rqdata !== void 0) body.rqdata = rqdata;
|
|
520
|
+
if (proxy !== void 0) body.proxy = proxy;
|
|
521
|
+
return this.transport.request("POST", "/captcha/token/hcaptcha", { json: body });
|
|
522
|
+
}
|
|
523
|
+
};
|
|
524
|
+
var Tasks = class {
|
|
525
|
+
constructor(transport) {
|
|
526
|
+
this.transport = transport;
|
|
527
|
+
}
|
|
528
|
+
transport;
|
|
529
|
+
retrieve(opts) {
|
|
530
|
+
const { taskId: taskId15, ...rest } = opts;
|
|
531
|
+
return this.transport.request("POST", "/captcha/tasks", {
|
|
532
|
+
json: { task_id: taskId15, ...rest }
|
|
533
|
+
});
|
|
534
|
+
}
|
|
535
|
+
};
|
|
536
|
+
var Captcha = class {
|
|
537
|
+
recognition;
|
|
538
|
+
token;
|
|
539
|
+
tasks;
|
|
540
|
+
constructor(transport) {
|
|
541
|
+
this.recognition = new Recognition(transport);
|
|
542
|
+
this.token = new Token(transport);
|
|
543
|
+
this.tasks = new Tasks(transport);
|
|
544
|
+
}
|
|
545
|
+
};
|
|
546
|
+
|
|
493
547
|
// src/runtime/tasks.ts
|
|
494
548
|
var DONE = /* @__PURE__ */ new Set(["succeed", "succeeded", "success", "completed", "complete", "finished"]);
|
|
495
549
|
var FAILED = /* @__PURE__ */ new Set(["failed", "failure", "error", "cancelled", "canceled", "rejected"]);
|
|
@@ -583,8 +637,8 @@ var TaskHandle = class {
|
|
|
583
637
|
pollEndpoint;
|
|
584
638
|
transport;
|
|
585
639
|
_result = null;
|
|
586
|
-
constructor(
|
|
587
|
-
this.id =
|
|
640
|
+
constructor(taskId15, pollEndpoint, transport, submitted) {
|
|
641
|
+
this.id = taskId15;
|
|
588
642
|
this.pollEndpoint = pollEndpoint;
|
|
589
643
|
this.transport = transport;
|
|
590
644
|
if (submitted && artifactUrls({ response: submitted }).length > 0) {
|
|
@@ -662,9 +716,9 @@ var Images = class {
|
|
|
662
716
|
if (callbackUrl !== void 0) body.callback_url = callbackUrl;
|
|
663
717
|
const endpoint = `/${provider}/images`;
|
|
664
718
|
const result = await this.transport.request("POST", endpoint, { json: body });
|
|
665
|
-
const
|
|
666
|
-
if (!
|
|
667
|
-
const handle = new TaskHandle(
|
|
719
|
+
const taskId15 = result.task_id;
|
|
720
|
+
if (!taskId15 || result.data && !shouldWait) return result;
|
|
721
|
+
const handle = new TaskHandle(taskId15, `/${provider}/tasks`, this.transport);
|
|
668
722
|
if (shouldWait) return handle.wait({ pollInterval, maxWait });
|
|
669
723
|
return handle;
|
|
670
724
|
}
|
|
@@ -710,9 +764,9 @@ var Audio = class {
|
|
|
710
764
|
if (callbackUrl !== void 0) body.callback_url = callbackUrl;
|
|
711
765
|
result = await this.transport.request("POST", `/${provider}/audios`, { json: body });
|
|
712
766
|
}
|
|
713
|
-
const
|
|
714
|
-
if (!
|
|
715
|
-
const handle = new TaskHandle(
|
|
767
|
+
const taskId15 = result.task_id;
|
|
768
|
+
if (!taskId15 || result.data && !shouldWait) return result;
|
|
769
|
+
const handle = new TaskHandle(taskId15, `/${provider}/tasks`, this.transport);
|
|
716
770
|
if (shouldWait) return handle.wait({ pollInterval, maxWait });
|
|
717
771
|
return handle;
|
|
718
772
|
}
|
|
@@ -731,9 +785,9 @@ var Video = class {
|
|
|
731
785
|
if (imageUrl !== void 0) body.image_url = imageUrl;
|
|
732
786
|
if (callbackUrl !== void 0) body.callback_url = callbackUrl;
|
|
733
787
|
const result = await this.transport.request("POST", `/${provider}/videos`, { json: body });
|
|
734
|
-
const
|
|
735
|
-
if (!
|
|
736
|
-
const handle = new TaskHandle(
|
|
788
|
+
const taskId15 = result.task_id;
|
|
789
|
+
if (!taskId15 || result.data && !shouldWait) return result;
|
|
790
|
+
const handle = new TaskHandle(taskId15, `/${provider}/tasks`, this.transport);
|
|
737
791
|
if (shouldWait) return handle.wait({ pollInterval, maxWait });
|
|
738
792
|
return handle;
|
|
739
793
|
}
|
|
@@ -772,24 +826,25 @@ var SERVICE_TASK_ENDPOINTS = {
|
|
|
772
826
|
wan: "/wan/tasks",
|
|
773
827
|
pika: "/pika/tasks",
|
|
774
828
|
pixverse: "/pixverse/tasks",
|
|
775
|
-
webextrator: "/webextrator/tasks"
|
|
829
|
+
webextrator: "/webextrator/tasks",
|
|
830
|
+
captcha: "/captcha/tasks"
|
|
776
831
|
};
|
|
777
|
-
var
|
|
832
|
+
var Tasks2 = class {
|
|
778
833
|
constructor(transport) {
|
|
779
834
|
this.transport = transport;
|
|
780
835
|
}
|
|
781
836
|
transport;
|
|
782
|
-
async get(
|
|
837
|
+
async get(taskId15, opts = {}) {
|
|
783
838
|
const service = opts.service ?? "suno";
|
|
784
839
|
const endpoint = SERVICE_TASK_ENDPOINTS[service] ?? `/${service}/tasks`;
|
|
785
840
|
return this.transport.request("POST", endpoint, {
|
|
786
|
-
json: { id:
|
|
841
|
+
json: { id: taskId15, action: "retrieve" }
|
|
787
842
|
});
|
|
788
843
|
}
|
|
789
|
-
async wait(
|
|
844
|
+
async wait(taskId15, opts = {}) {
|
|
790
845
|
const service = opts.service ?? "suno";
|
|
791
846
|
const endpoint = SERVICE_TASK_ENDPOINTS[service] ?? `/${service}/tasks`;
|
|
792
|
-
const handle = new TaskHandle(
|
|
847
|
+
const handle = new TaskHandle(taskId15, endpoint, this.transport);
|
|
793
848
|
return handle.wait({ pollInterval: opts.pollInterval, maxWait: opts.maxWait });
|
|
794
849
|
}
|
|
795
850
|
};
|
|
@@ -977,7 +1032,7 @@ var Embeddings = class {
|
|
|
977
1032
|
return this.transport.request("POST", "/openai/embeddings", { json: body });
|
|
978
1033
|
}
|
|
979
1034
|
};
|
|
980
|
-
var
|
|
1035
|
+
var Tasks3 = class {
|
|
981
1036
|
constructor(transport) {
|
|
982
1037
|
this.transport = transport;
|
|
983
1038
|
}
|
|
@@ -1015,7 +1070,7 @@ var OpenAI = class {
|
|
|
1015
1070
|
this.responses = new Responses(transport);
|
|
1016
1071
|
this.images = new Images2(transport);
|
|
1017
1072
|
this.embeddings = new Embeddings(transport);
|
|
1018
|
-
this.tasks = new
|
|
1073
|
+
this.tasks = new Tasks3(transport);
|
|
1019
1074
|
}
|
|
1020
1075
|
};
|
|
1021
1076
|
|
|
@@ -1792,13 +1847,49 @@ var Maestro = class {
|
|
|
1792
1847
|
}
|
|
1793
1848
|
};
|
|
1794
1849
|
|
|
1795
|
-
// src/resources/providers/
|
|
1850
|
+
// src/resources/providers/minimax.ts
|
|
1796
1851
|
function taskId8(result) {
|
|
1797
1852
|
if (typeof result?.task_id === "string") return result.task_id;
|
|
1798
1853
|
const data = result?.data;
|
|
1799
1854
|
if (data && typeof data.task_id === "string") return data.task_id;
|
|
1800
1855
|
return typeof result?.id === "string" ? result.id : "";
|
|
1801
1856
|
}
|
|
1857
|
+
var Minimax = class {
|
|
1858
|
+
constructor(transport) {
|
|
1859
|
+
this.transport = transport;
|
|
1860
|
+
}
|
|
1861
|
+
transport;
|
|
1862
|
+
/** Minimax Videos */
|
|
1863
|
+
async generate(options) {
|
|
1864
|
+
const body = {};
|
|
1865
|
+
body["model"] = options.model;
|
|
1866
|
+
body["content"] = options.content;
|
|
1867
|
+
body["resolution"] = options.resolution;
|
|
1868
|
+
body["duration"] = options.duration;
|
|
1869
|
+
if (options.ratio !== void 0) body["ratio"] = options.ratio;
|
|
1870
|
+
for (const [key, value] of Object.entries(options)) {
|
|
1871
|
+
if (!["async", "callbackUrl", "content", "duration", "maxWait", "model", "pollInterval", "ratio", "resolution", "wait"].includes(key) && value !== void 0) {
|
|
1872
|
+
body[key] = value;
|
|
1873
|
+
}
|
|
1874
|
+
}
|
|
1875
|
+
if (options.callbackUrl !== void 0) body.callback_url = options.callbackUrl;
|
|
1876
|
+
body.async = options.async ?? true;
|
|
1877
|
+
const result = await this.transport.request("POST", "/minimax/videos", { json: body });
|
|
1878
|
+
const handle = new TaskHandle(taskId8(result), "/minimax/tasks", this.transport, result);
|
|
1879
|
+
if (options.wait) {
|
|
1880
|
+
await handle.wait({ pollInterval: options.pollInterval, maxWait: options.maxWait });
|
|
1881
|
+
}
|
|
1882
|
+
return handle;
|
|
1883
|
+
}
|
|
1884
|
+
};
|
|
1885
|
+
|
|
1886
|
+
// src/resources/providers/nano-banana.ts
|
|
1887
|
+
function taskId9(result) {
|
|
1888
|
+
if (typeof result?.task_id === "string") return result.task_id;
|
|
1889
|
+
const data = result?.data;
|
|
1890
|
+
if (data && typeof data.task_id === "string") return data.task_id;
|
|
1891
|
+
return typeof result?.id === "string" ? result.id : "";
|
|
1892
|
+
}
|
|
1802
1893
|
var NanoBanana = class {
|
|
1803
1894
|
constructor(transport) {
|
|
1804
1895
|
this.transport = transport;
|
|
@@ -1822,7 +1913,7 @@ var NanoBanana = class {
|
|
|
1822
1913
|
if (options.callbackUrl !== void 0) body.callback_url = options.callbackUrl;
|
|
1823
1914
|
body.async = options.async ?? true;
|
|
1824
1915
|
const result = await this.transport.request("POST", "/nano-banana/images", { json: body });
|
|
1825
|
-
const handle = new TaskHandle(
|
|
1916
|
+
const handle = new TaskHandle(taskId9(result), "/nano-banana/tasks", this.transport, result);
|
|
1826
1917
|
if (options.wait) {
|
|
1827
1918
|
await handle.wait({ pollInterval: options.pollInterval, maxWait: options.maxWait });
|
|
1828
1919
|
}
|
|
@@ -1831,7 +1922,7 @@ var NanoBanana = class {
|
|
|
1831
1922
|
};
|
|
1832
1923
|
|
|
1833
1924
|
// src/resources/providers/producer.ts
|
|
1834
|
-
function
|
|
1925
|
+
function taskId10(result) {
|
|
1835
1926
|
if (typeof result?.task_id === "string") return result.task_id;
|
|
1836
1927
|
const data = result?.data;
|
|
1837
1928
|
if (data && typeof data.task_id === "string") return data.task_id;
|
|
@@ -1904,7 +1995,7 @@ var Producer = class {
|
|
|
1904
1995
|
if (options.callbackUrl !== void 0) body.callback_url = options.callbackUrl;
|
|
1905
1996
|
body.async = options.async ?? true;
|
|
1906
1997
|
const result = await this.transport.request("POST", "/producer/audios", { json: body });
|
|
1907
|
-
const handle = new TaskHandle(
|
|
1998
|
+
const handle = new TaskHandle(taskId10(result), "/producer/tasks", this.transport, result);
|
|
1908
1999
|
if (options.wait) {
|
|
1909
2000
|
await handle.wait({ pollInterval: options.pollInterval, maxWait: options.maxWait });
|
|
1910
2001
|
}
|
|
@@ -1925,7 +2016,7 @@ var Producer = class {
|
|
|
1925
2016
|
};
|
|
1926
2017
|
|
|
1927
2018
|
// src/resources/providers/seedance.ts
|
|
1928
|
-
function
|
|
2019
|
+
function taskId11(result) {
|
|
1929
2020
|
if (typeof result?.task_id === "string") return result.task_id;
|
|
1930
2021
|
const data = result?.data;
|
|
1931
2022
|
if (data && typeof data.task_id === "string") return data.task_id;
|
|
@@ -1959,7 +2050,7 @@ var Seedance = class {
|
|
|
1959
2050
|
if (options.callbackUrl !== void 0) body.callback_url = options.callbackUrl;
|
|
1960
2051
|
body.async = options.async ?? true;
|
|
1961
2052
|
const result = await this.transport.request("POST", "/seedance/videos", { json: body });
|
|
1962
|
-
const handle = new TaskHandle(
|
|
2053
|
+
const handle = new TaskHandle(taskId11(result), "/seedance/tasks", this.transport, result);
|
|
1963
2054
|
if (options.wait) {
|
|
1964
2055
|
await handle.wait({ pollInterval: options.pollInterval, maxWait: options.maxWait });
|
|
1965
2056
|
}
|
|
@@ -1968,7 +2059,7 @@ var Seedance = class {
|
|
|
1968
2059
|
};
|
|
1969
2060
|
|
|
1970
2061
|
// src/resources/providers/seedream.ts
|
|
1971
|
-
function
|
|
2062
|
+
function taskId12(result) {
|
|
1972
2063
|
if (typeof result?.task_id === "string") return result.task_id;
|
|
1973
2064
|
const data = result?.data;
|
|
1974
2065
|
if (data && typeof data.task_id === "string") return data.task_id;
|
|
@@ -2004,7 +2095,7 @@ var Seedream = class {
|
|
|
2004
2095
|
if (options.callbackUrl !== void 0) body.callback_url = options.callbackUrl;
|
|
2005
2096
|
body.async = options.async ?? true;
|
|
2006
2097
|
const result = await this.transport.request("POST", "/seedream/images", { json: body });
|
|
2007
|
-
const handle = new TaskHandle(
|
|
2098
|
+
const handle = new TaskHandle(taskId12(result), "/seedream/tasks", this.transport, result);
|
|
2008
2099
|
if (options.wait) {
|
|
2009
2100
|
await handle.wait({ pollInterval: options.pollInterval, maxWait: options.maxWait });
|
|
2010
2101
|
}
|
|
@@ -2013,7 +2104,7 @@ var Seedream = class {
|
|
|
2013
2104
|
};
|
|
2014
2105
|
|
|
2015
2106
|
// src/resources/providers/suno.ts
|
|
2016
|
-
function
|
|
2107
|
+
function taskId13(result) {
|
|
2017
2108
|
if (typeof result?.task_id === "string") return result.task_id;
|
|
2018
2109
|
const data = result?.data;
|
|
2019
2110
|
if (data && typeof data.task_id === "string") return data.task_id;
|
|
@@ -2064,7 +2155,7 @@ var Suno = class {
|
|
|
2064
2155
|
if (options.callbackUrl !== void 0) body.callback_url = options.callbackUrl;
|
|
2065
2156
|
body.async = options.async ?? true;
|
|
2066
2157
|
const result = await this.transport.request("POST", "/suno/audios", { json: body });
|
|
2067
|
-
const handle = new TaskHandle(
|
|
2158
|
+
const handle = new TaskHandle(taskId13(result), "/suno/tasks", this.transport, result);
|
|
2068
2159
|
if (options.wait) {
|
|
2069
2160
|
await handle.wait({ pollInterval: options.pollInterval, maxWait: options.maxWait });
|
|
2070
2161
|
}
|
|
@@ -2139,7 +2230,7 @@ var Suno = class {
|
|
|
2139
2230
|
if (options.callbackUrl !== void 0) body.callback_url = options.callbackUrl;
|
|
2140
2231
|
body.async = options.async ?? true;
|
|
2141
2232
|
const result = await this.transport.request("POST", "/suno/vox", { json: body });
|
|
2142
|
-
const handle = new TaskHandle(
|
|
2233
|
+
const handle = new TaskHandle(taskId13(result), "/suno/tasks", this.transport, result);
|
|
2143
2234
|
if (options.wait) {
|
|
2144
2235
|
await handle.wait({ pollInterval: options.pollInterval, maxWait: options.maxWait });
|
|
2145
2236
|
}
|
|
@@ -2157,7 +2248,7 @@ var Suno = class {
|
|
|
2157
2248
|
if (options.callbackUrl !== void 0) body.callback_url = options.callbackUrl;
|
|
2158
2249
|
body.async = options.async ?? true;
|
|
2159
2250
|
const result = await this.transport.request("POST", "/suno/wav", { json: body });
|
|
2160
|
-
const handle = new TaskHandle(
|
|
2251
|
+
const handle = new TaskHandle(taskId13(result), "/suno/tasks", this.transport, result);
|
|
2161
2252
|
if (options.wait) {
|
|
2162
2253
|
await handle.wait({ pollInterval: options.pollInterval, maxWait: options.maxWait });
|
|
2163
2254
|
}
|
|
@@ -2175,7 +2266,7 @@ var Suno = class {
|
|
|
2175
2266
|
if (options.callbackUrl !== void 0) body.callback_url = options.callbackUrl;
|
|
2176
2267
|
body.async = options.async ?? true;
|
|
2177
2268
|
const result = await this.transport.request("POST", "/suno/midi", { json: body });
|
|
2178
|
-
const handle = new TaskHandle(
|
|
2269
|
+
const handle = new TaskHandle(taskId13(result), "/suno/tasks", this.transport, result);
|
|
2179
2270
|
if (options.wait) {
|
|
2180
2271
|
await handle.wait({ pollInterval: options.pollInterval, maxWait: options.maxWait });
|
|
2181
2272
|
}
|
|
@@ -2234,7 +2325,7 @@ var Suno = class {
|
|
|
2234
2325
|
};
|
|
2235
2326
|
|
|
2236
2327
|
// src/resources/providers/wan.ts
|
|
2237
|
-
function
|
|
2328
|
+
function taskId14(result) {
|
|
2238
2329
|
if (typeof result?.task_id === "string") return result.task_id;
|
|
2239
2330
|
const data = result?.data;
|
|
2240
2331
|
if (data && typeof data.task_id === "string") return data.task_id;
|
|
@@ -2269,7 +2360,7 @@ var Wan = class {
|
|
|
2269
2360
|
if (options.callbackUrl !== void 0) body.callback_url = options.callbackUrl;
|
|
2270
2361
|
body.async = options.async ?? true;
|
|
2271
2362
|
const result = await this.transport.request("POST", "/wan/videos", { json: body });
|
|
2272
|
-
const handle = new TaskHandle(
|
|
2363
|
+
const handle = new TaskHandle(taskId14(result), "/wan/tasks", this.transport, result);
|
|
2273
2364
|
if (options.wait) {
|
|
2274
2365
|
await handle.wait({ pollInterval: options.pollInterval, maxWait: options.maxWait });
|
|
2275
2366
|
}
|
|
@@ -2288,6 +2379,7 @@ function attachProviders(client, transport) {
|
|
|
2288
2379
|
client.localization = new Localization(transport);
|
|
2289
2380
|
client.luma = new Luma(transport);
|
|
2290
2381
|
client.maestro = new Maestro(transport);
|
|
2382
|
+
client.minimax = new Minimax(transport);
|
|
2291
2383
|
client.nanobanana = new NanoBanana(transport);
|
|
2292
2384
|
client.producer = new Producer(transport);
|
|
2293
2385
|
client.seedance = new Seedance(transport);
|
|
@@ -2300,6 +2392,7 @@ function attachProviders(client, transport) {
|
|
|
2300
2392
|
var AceDataCloud = class {
|
|
2301
2393
|
aichat;
|
|
2302
2394
|
chat;
|
|
2395
|
+
captcha;
|
|
2303
2396
|
images;
|
|
2304
2397
|
audio;
|
|
2305
2398
|
video;
|
|
@@ -2327,11 +2420,12 @@ var AceDataCloud = class {
|
|
|
2327
2420
|
});
|
|
2328
2421
|
this.aichat = new AiChat(this.transport);
|
|
2329
2422
|
this.chat = new Chat(this.transport);
|
|
2423
|
+
this.captcha = new Captcha(this.transport);
|
|
2330
2424
|
this.images = new Images(this.transport);
|
|
2331
2425
|
this.audio = new Audio(this.transport);
|
|
2332
2426
|
this.video = new Video(this.transport);
|
|
2333
2427
|
this.search = new Search(this.transport);
|
|
2334
|
-
this.tasks = new
|
|
2428
|
+
this.tasks = new Tasks2(this.transport);
|
|
2335
2429
|
this.files = new Files(this.transport);
|
|
2336
2430
|
this.platform = new Platform(this.transport);
|
|
2337
2431
|
this.openai = new OpenAI(this.transport);
|