@ai-grator/api 0.0.7 → 0.0.9
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/admin/endpoints/admin.ts +3 -0
- package/billing/endpoints/index.ts +1 -0
- package/billing/endpoints/queries/get-admin-stats.query.ts +29 -0
- package/billing/endpoints/queries/index.ts +1 -0
- package/billing/enums/index.ts +1 -0
- package/billing/enums/model-type.enum.ts +5 -0
- package/billing/index.ts +3 -0
- package/billing/models/admin-stats-response.schema.ts +29 -0
- package/billing/models/index.ts +1 -0
- package/build/admin/endpoints/admin.d.ts +1 -0
- package/build/admin/endpoints/admin.d.ts.map +1 -1
- package/build/admin/endpoints/admin.js +2 -0
- package/build/billing/endpoints/index.d.ts +2 -0
- package/build/billing/endpoints/index.d.ts.map +1 -0
- package/build/billing/endpoints/index.js +17 -0
- package/build/billing/endpoints/queries/get-admin-stats.query.d.ts +61 -0
- package/build/billing/endpoints/queries/get-admin-stats.query.d.ts.map +1 -0
- package/build/billing/endpoints/queries/get-admin-stats.query.js +26 -0
- package/build/billing/endpoints/queries/index.d.ts +2 -0
- package/build/billing/endpoints/queries/index.d.ts.map +1 -0
- package/build/billing/endpoints/queries/index.js +17 -0
- package/build/billing/enums/index.d.ts +2 -0
- package/build/billing/enums/index.d.ts.map +1 -0
- package/build/billing/enums/index.js +17 -0
- package/build/billing/enums/model-type.enum.d.ts +6 -0
- package/build/billing/enums/model-type.enum.d.ts.map +1 -0
- package/build/billing/enums/model-type.enum.js +9 -0
- package/build/billing/index.d.ts +4 -0
- package/build/billing/index.d.ts.map +1 -0
- package/build/billing/index.js +19 -0
- package/build/billing/models/admin-stats-response.schema.d.ts +37 -0
- package/build/billing/models/admin-stats-response.schema.d.ts.map +1 -0
- package/build/billing/models/admin-stats-response.schema.js +25 -0
- package/build/billing/models/index.d.ts +2 -0
- package/build/billing/models/index.d.ts.map +1 -0
- package/build/billing/models/index.js +17 -0
- package/build/errors/errors.d.ts +10 -0
- package/build/errors/errors.d.ts.map +1 -1
- package/build/errors/errors.js +10 -0
- package/build/generation-job/endpoints/commands/create-generation-job.command.d.ts +8 -0
- package/build/generation-job/endpoints/commands/create-generation-job.command.d.ts.map +1 -1
- package/build/generation-job/endpoints/commands/update-generation-job.command.d.ts +13 -20
- package/build/generation-job/endpoints/commands/update-generation-job.command.d.ts.map +1 -1
- package/build/generation-job/endpoints/commands/update-generation-job.command.js +3 -11
- package/build/generation-job/endpoints/queries/get-generation-job-by-uuid.query.d.ts +8 -0
- package/build/generation-job/endpoints/queries/get-generation-job-by-uuid.query.d.ts.map +1 -1
- package/build/generation-job/endpoints/queries/get-generation-job-history.query.d.ts +12 -0
- package/build/generation-job/endpoints/queries/get-generation-job-history.query.d.ts.map +1 -1
- package/build/generation-job/endpoints/queries/get-generation-jobs.query.d.ts +8 -0
- package/build/generation-job/endpoints/queries/get-generation-jobs.query.d.ts.map +1 -1
- package/build/generation-job/models/generation-job-response.schema.d.ts +8 -0
- package/build/generation-job/models/generation-job-response.schema.d.ts.map +1 -1
- package/build/generation-job/models/generation-job-response.schema.js +4 -0
- package/build/generation-job/models/index.d.ts +1 -0
- package/build/generation-job/models/index.d.ts.map +1 -1
- package/build/generation-job/models/index.js +1 -0
- package/build/generation-job/models/suno-params.schema.d.ts +55 -0
- package/build/generation-job/models/suno-params.schema.d.ts.map +1 -0
- package/build/generation-job/models/suno-params.schema.js +66 -0
- package/build/generation-model/endpoints/generation-model.d.ts +1 -0
- package/build/generation-model/endpoints/generation-model.d.ts.map +1 -1
- package/build/generation-model/endpoints/generation-model.js +1 -0
- package/build/generation-model/endpoints/queries/get-music-styles.query.d.ts +59 -0
- package/build/generation-model/endpoints/queries/get-music-styles.query.d.ts.map +1 -0
- package/build/generation-model/endpoints/queries/get-music-styles.query.js +19 -0
- package/build/generation-model/endpoints/queries/index.d.ts +1 -0
- package/build/generation-model/endpoints/queries/index.d.ts.map +1 -1
- package/build/generation-model/endpoints/queries/index.js +1 -0
- package/build/generation-model/enums/generation-type.enum.d.ts +2 -1
- package/build/generation-model/enums/generation-type.enum.d.ts.map +1 -1
- package/build/generation-model/enums/generation-type.enum.js +1 -0
- package/build/generation-model/enums/index.d.ts +1 -0
- package/build/generation-model/enums/index.d.ts.map +1 -1
- package/build/generation-model/enums/index.js +1 -0
- package/build/generation-model/enums/music-style.enum.d.ts +26 -0
- package/build/generation-model/enums/music-style.enum.d.ts.map +1 -0
- package/build/generation-model/enums/music-style.enum.js +27 -0
- package/build/scripts/generate-openapi.js +7 -0
- package/build/tsconfig.tsbuildinfo +1 -1
- package/build/wallet/enums/wallet-transaction-source-type.enum.d.ts +1 -0
- package/build/wallet/enums/wallet-transaction-source-type.enum.d.ts.map +1 -1
- package/build/wallet/enums/wallet-transaction-source-type.enum.js +1 -0
- package/errors/errors.ts +10 -0
- package/generation-job/endpoints/commands/update-generation-job.command.ts +5 -13
- package/generation-job/models/generation-job-response.schema.ts +4 -0
- package/generation-job/models/index.ts +1 -0
- package/generation-job/models/suno-params.schema.ts +73 -0
- package/generation-model/endpoints/generation-model.ts +1 -0
- package/generation-model/endpoints/queries/get-music-styles.query.ts +18 -0
- package/generation-model/endpoints/queries/index.ts +1 -0
- package/generation-model/enums/generation-type.enum.ts +1 -0
- package/generation-model/enums/index.ts +1 -0
- package/generation-model/enums/music-style.enum.ts +27 -0
- package/package.json +1 -1
- package/scripts/generate-openapi.ts +14 -0
- package/wallet/enums/wallet-transaction-source-type.enum.ts +1 -0
|
@@ -13,6 +13,10 @@ export declare const GetGenerationJobByUuidQueryResponse: z.ZodObject<{
|
|
|
13
13
|
outputs: z.ZodArray<z.ZodObject<{
|
|
14
14
|
uuid: z.ZodUUID;
|
|
15
15
|
url: z.ZodURL;
|
|
16
|
+
title: z.ZodOptional<z.ZodString>;
|
|
17
|
+
tags: z.ZodOptional<z.ZodString>;
|
|
18
|
+
duration: z.ZodOptional<z.ZodNumber>;
|
|
19
|
+
imageUrl: z.ZodOptional<z.ZodString>;
|
|
16
20
|
}, z.core.$strip>>;
|
|
17
21
|
errorMessage: z.ZodNullable<z.ZodString>;
|
|
18
22
|
startedAt: z.ZodNullable<z.ZodISODateTime>;
|
|
@@ -40,6 +44,10 @@ export declare const GetGenerationJobByUuidQuery: {
|
|
|
40
44
|
outputs: z.ZodArray<z.ZodObject<{
|
|
41
45
|
uuid: z.ZodUUID;
|
|
42
46
|
url: z.ZodURL;
|
|
47
|
+
title: z.ZodOptional<z.ZodString>;
|
|
48
|
+
tags: z.ZodOptional<z.ZodString>;
|
|
49
|
+
duration: z.ZodOptional<z.ZodNumber>;
|
|
50
|
+
imageUrl: z.ZodOptional<z.ZodString>;
|
|
43
51
|
}, z.core.$strip>>;
|
|
44
52
|
errorMessage: z.ZodNullable<z.ZodString>;
|
|
45
53
|
startedAt: z.ZodNullable<z.ZodISODateTime>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-generation-job-by-uuid.query.d.ts","sourceRoot":"","sources":["../../../../generation-job/endpoints/queries/get-generation-job-by-uuid.query.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAkB,YAAY,EAA2B,MAAM,kBAAkB,CAAC;AAIzF,eAAO,MAAM,iCAAiC;;iBAE5C,CAAC;AAEH,eAAO,MAAM,mCAAmC
|
|
1
|
+
{"version":3,"file":"get-generation-job-by-uuid.query.d.ts","sourceRoot":"","sources":["../../../../generation-job/endpoints/queries/get-generation-job-by-uuid.query.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAkB,YAAY,EAA2B,MAAM,kBAAkB,CAAC;AAIzF,eAAO,MAAM,iCAAiC;;iBAE5C,CAAC;AAEH,eAAO,MAAM,mCAAmC;;;;;;;;;;;;;;;;;;;;iBAA8B,CAAC;AAE/E,eAAO,MAAM,2BAA2B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAYtC,CAAC"}
|
|
@@ -19,6 +19,10 @@ export declare const GenerationJobHistoryItemSchema: z.ZodObject<{
|
|
|
19
19
|
outputs: z.ZodArray<z.ZodObject<{
|
|
20
20
|
uuid: z.ZodUUID;
|
|
21
21
|
url: z.ZodURL;
|
|
22
|
+
title: z.ZodOptional<z.ZodString>;
|
|
23
|
+
tags: z.ZodOptional<z.ZodString>;
|
|
24
|
+
duration: z.ZodOptional<z.ZodNumber>;
|
|
25
|
+
imageUrl: z.ZodOptional<z.ZodString>;
|
|
22
26
|
}, z.core.$strip>>;
|
|
23
27
|
errorMessage: z.ZodNullable<z.ZodString>;
|
|
24
28
|
startedAt: z.ZodNullable<z.ZodISODateTime>;
|
|
@@ -38,6 +42,10 @@ export declare const GetGenerationJobHistoryQueryResponse: z.ZodObject<{
|
|
|
38
42
|
outputs: z.ZodArray<z.ZodObject<{
|
|
39
43
|
uuid: z.ZodUUID;
|
|
40
44
|
url: z.ZodURL;
|
|
45
|
+
title: z.ZodOptional<z.ZodString>;
|
|
46
|
+
tags: z.ZodOptional<z.ZodString>;
|
|
47
|
+
duration: z.ZodOptional<z.ZodNumber>;
|
|
48
|
+
imageUrl: z.ZodOptional<z.ZodString>;
|
|
41
49
|
}, z.core.$strip>>;
|
|
42
50
|
errorMessage: z.ZodNullable<z.ZodString>;
|
|
43
51
|
startedAt: z.ZodNullable<z.ZodISODateTime>;
|
|
@@ -76,6 +84,10 @@ export declare const GetGenerationJobHistoryQuery: {
|
|
|
76
84
|
outputs: z.ZodArray<z.ZodObject<{
|
|
77
85
|
uuid: z.ZodUUID;
|
|
78
86
|
url: z.ZodURL;
|
|
87
|
+
title: z.ZodOptional<z.ZodString>;
|
|
88
|
+
tags: z.ZodOptional<z.ZodString>;
|
|
89
|
+
duration: z.ZodOptional<z.ZodNumber>;
|
|
90
|
+
imageUrl: z.ZodOptional<z.ZodString>;
|
|
79
91
|
}, z.core.$strip>>;
|
|
80
92
|
errorMessage: z.ZodNullable<z.ZodString>;
|
|
81
93
|
startedAt: z.ZodNullable<z.ZodISODateTime>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-generation-job-history.query.d.ts","sourceRoot":"","sources":["../../../../generation-job/endpoints/queries/get-generation-job-history.query.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAA+C,YAAY,EAA2B,MAAM,kBAAkB,CAAC;AAKtH,eAAO,MAAM,iCAAiC;;;;;;;;iBAM5C,CAAC;AAEH,eAAO,MAAM,8BAA8B
|
|
1
|
+
{"version":3,"file":"get-generation-job-history.query.d.ts","sourceRoot":"","sources":["../../../../generation-job/endpoints/queries/get-generation-job-history.query.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAA+C,YAAY,EAA2B,MAAM,kBAAkB,CAAC;AAKtH,eAAO,MAAM,iCAAiC;;;;;;;;iBAM5C,CAAC;AAEH,eAAO,MAAM,8BAA8B;;;;;;;;;;;;;;;;;;;;;iBAEzC,CAAC;AAEH,eAAO,MAAM,oCAAoC;;;;;;;;;;;;;;;;;;;;;;;;;iBAI/C,CAAC;AAEH,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAWvC,CAAC;AAEH,MAAM,MAAM,4BAA4B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,8BAA8B,CAAC,CAAC"}
|
|
@@ -14,6 +14,10 @@ export declare const GetGenerationJobsQueryResponse: z.ZodObject<{
|
|
|
14
14
|
outputs: z.ZodArray<z.ZodObject<{
|
|
15
15
|
uuid: z.ZodUUID;
|
|
16
16
|
url: z.ZodURL;
|
|
17
|
+
title: z.ZodOptional<z.ZodString>;
|
|
18
|
+
tags: z.ZodOptional<z.ZodString>;
|
|
19
|
+
duration: z.ZodOptional<z.ZodNumber>;
|
|
20
|
+
imageUrl: z.ZodOptional<z.ZodString>;
|
|
17
21
|
}, z.core.$strip>>;
|
|
18
22
|
errorMessage: z.ZodNullable<z.ZodString>;
|
|
19
23
|
startedAt: z.ZodNullable<z.ZodISODateTime>;
|
|
@@ -43,6 +47,10 @@ export declare const GetGenerationJobsQuery: {
|
|
|
43
47
|
outputs: z.ZodArray<z.ZodObject<{
|
|
44
48
|
uuid: z.ZodUUID;
|
|
45
49
|
url: z.ZodURL;
|
|
50
|
+
title: z.ZodOptional<z.ZodString>;
|
|
51
|
+
tags: z.ZodOptional<z.ZodString>;
|
|
52
|
+
duration: z.ZodOptional<z.ZodNumber>;
|
|
53
|
+
imageUrl: z.ZodOptional<z.ZodString>;
|
|
46
54
|
}, z.core.$strip>>;
|
|
47
55
|
errorMessage: z.ZodNullable<z.ZodString>;
|
|
48
56
|
startedAt: z.ZodNullable<z.ZodISODateTime>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-generation-jobs.query.d.ts","sourceRoot":"","sources":["../../../../generation-job/endpoints/queries/get-generation-jobs.query.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAkB,YAAY,EAA2B,MAAM,kBAAkB,CAAC;AAKzF,eAAO,MAAM,2BAA2B;;iBAEtC,CAAC;AAEH,eAAO,MAAM,8BAA8B
|
|
1
|
+
{"version":3,"file":"get-generation-jobs.query.d.ts","sourceRoot":"","sources":["../../../../generation-job/endpoints/queries/get-generation-jobs.query.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAkB,YAAY,EAA2B,MAAM,kBAAkB,CAAC;AAKzF,eAAO,MAAM,2BAA2B;;iBAEtC,CAAC;AAEH,eAAO,MAAM,8BAA8B;;;;;;;;;;;;;;;;;;;;;;iBAEzC,CAAC;AAEH,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAWjC,CAAC"}
|
|
@@ -4,6 +4,10 @@ export declare const GenerationJobStatusSchema: z.ZodEnum<typeof GENERATION_JOB_
|
|
|
4
4
|
export declare const GenerationJobOutputSchema: z.ZodObject<{
|
|
5
5
|
uuid: z.ZodUUID;
|
|
6
6
|
url: z.ZodURL;
|
|
7
|
+
title: z.ZodOptional<z.ZodString>;
|
|
8
|
+
tags: z.ZodOptional<z.ZodString>;
|
|
9
|
+
duration: z.ZodOptional<z.ZodNumber>;
|
|
10
|
+
imageUrl: z.ZodOptional<z.ZodString>;
|
|
7
11
|
}, z.core.$strip>;
|
|
8
12
|
export declare const GenerationJobResponseSchema: z.ZodObject<{
|
|
9
13
|
uuid: z.ZodUUID;
|
|
@@ -15,6 +19,10 @@ export declare const GenerationJobResponseSchema: z.ZodObject<{
|
|
|
15
19
|
outputs: z.ZodArray<z.ZodObject<{
|
|
16
20
|
uuid: z.ZodUUID;
|
|
17
21
|
url: z.ZodURL;
|
|
22
|
+
title: z.ZodOptional<z.ZodString>;
|
|
23
|
+
tags: z.ZodOptional<z.ZodString>;
|
|
24
|
+
duration: z.ZodOptional<z.ZodNumber>;
|
|
25
|
+
imageUrl: z.ZodOptional<z.ZodString>;
|
|
18
26
|
}, z.core.$strip>>;
|
|
19
27
|
errorMessage: z.ZodNullable<z.ZodString>;
|
|
20
28
|
startedAt: z.ZodNullable<z.ZodISODateTime>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"generation-job-response.schema.d.ts","sourceRoot":"","sources":["../../../generation-job/models/generation-job-response.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAAE,qBAAqB,EAAE,MAAM,UAAU,CAAC;AAIjD,eAAO,MAAM,yBAAyB,yCAAgC,CAAC;AAEvE,eAAO,MAAM,yBAAyB
|
|
1
|
+
{"version":3,"file":"generation-job-response.schema.d.ts","sourceRoot":"","sources":["../../../generation-job/models/generation-job-response.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAAE,qBAAqB,EAAE,MAAM,UAAU,CAAC;AAIjD,eAAO,MAAM,yBAAyB,yCAAgC,CAAC;AAEvE,eAAO,MAAM,yBAAyB;;;;;;;iBAOpC,CAAC;AAEH,eAAO,MAAM,2BAA2B;;;;;;;;;;;;;;;;;;;;iBAatC,CAAC;AAEH,MAAM,MAAM,+BAA+B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,2BAA2B,CAAC,CAAC"}
|
|
@@ -9,6 +9,10 @@ exports.GenerationJobStatusSchema = zod_1.z.enum(enums_1.GENERATION_JOB_STATUS);
|
|
|
9
9
|
exports.GenerationJobOutputSchema = zod_1.z.object({
|
|
10
10
|
uuid: zod_1.z.uuid(),
|
|
11
11
|
url: zod_1.z.url(),
|
|
12
|
+
title: zod_1.z.string().optional(),
|
|
13
|
+
tags: zod_1.z.string().optional(),
|
|
14
|
+
duration: zod_1.z.number().optional(),
|
|
15
|
+
imageUrl: zod_1.z.string().optional(),
|
|
12
16
|
});
|
|
13
17
|
exports.GenerationJobResponseSchema = zod_1.z.object({
|
|
14
18
|
uuid: zod_1.z.uuid(),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../generation-job/models/index.ts"],"names":[],"mappings":"AAAA,cAAc,kCAAkC,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../generation-job/models/index.ts"],"names":[],"mappings":"AAAA,cAAc,kCAAkC,CAAC;AACjD,cAAc,sBAAsB,CAAC"}
|
|
@@ -15,3 +15,4 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
__exportStar(require("./generation-job-response.schema"), exports);
|
|
18
|
+
__exportStar(require("./suno-params.schema"), exports);
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare const SunoVocalGenderSchema: z.ZodEnum<{
|
|
3
|
+
m: "m";
|
|
4
|
+
f: "f";
|
|
5
|
+
}>;
|
|
6
|
+
export type SunoVocalGender = z.infer<typeof SunoVocalGenderSchema>;
|
|
7
|
+
export declare const SunoPersonaModelSchema: z.ZodEnum<{
|
|
8
|
+
style_persona: "style_persona";
|
|
9
|
+
voice_persona: "voice_persona";
|
|
10
|
+
}>;
|
|
11
|
+
export type SunoPersonaModel = z.infer<typeof SunoPersonaModelSchema>;
|
|
12
|
+
export declare const SunoParamsSchema: z.ZodObject<{
|
|
13
|
+
customMode: z.ZodDefault<z.ZodBoolean>;
|
|
14
|
+
prompt: z.ZodOptional<z.ZodString>;
|
|
15
|
+
instrumental: z.ZodDefault<z.ZodBoolean>;
|
|
16
|
+
audioWeight: z.ZodDefault<z.ZodNumber>;
|
|
17
|
+
title: z.ZodOptional<z.ZodString>;
|
|
18
|
+
style: z.ZodOptional<z.ZodEnum<{
|
|
19
|
+
Pop: "Pop";
|
|
20
|
+
Rock: "Rock";
|
|
21
|
+
"Hip-hop": "Hip-hop";
|
|
22
|
+
Electronic: "Electronic";
|
|
23
|
+
Jazz: "Jazz";
|
|
24
|
+
Classical: "Classical";
|
|
25
|
+
"R&B": "R&B";
|
|
26
|
+
Country: "Country";
|
|
27
|
+
Metal: "Metal";
|
|
28
|
+
Folk: "Folk";
|
|
29
|
+
Reggae: "Reggae";
|
|
30
|
+
Blues: "Blues";
|
|
31
|
+
Funk: "Funk";
|
|
32
|
+
Punk: "Punk";
|
|
33
|
+
Ambient: "Ambient";
|
|
34
|
+
Latin: "Latin";
|
|
35
|
+
"K-pop": "K-pop";
|
|
36
|
+
Indie: "Indie";
|
|
37
|
+
Soul: "Soul";
|
|
38
|
+
Gospel: "Gospel";
|
|
39
|
+
}>>;
|
|
40
|
+
duration: z.ZodDefault<z.ZodNumber>;
|
|
41
|
+
vocalGender: z.ZodOptional<z.ZodEnum<{
|
|
42
|
+
m: "m";
|
|
43
|
+
f: "f";
|
|
44
|
+
}>>;
|
|
45
|
+
negativeTags: z.ZodOptional<z.ZodString>;
|
|
46
|
+
styleWeight: z.ZodOptional<z.ZodNumber>;
|
|
47
|
+
weirdnessConstraint: z.ZodOptional<z.ZodNumber>;
|
|
48
|
+
personaId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
49
|
+
personaModel: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
50
|
+
style_persona: "style_persona";
|
|
51
|
+
voice_persona: "voice_persona";
|
|
52
|
+
}>>>;
|
|
53
|
+
}, z.core.$strip>;
|
|
54
|
+
export type SunoParams = z.infer<typeof SunoParamsSchema>;
|
|
55
|
+
//# sourceMappingURL=suno-params.schema.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"suno-params.schema.d.ts","sourceRoot":"","sources":["../../../generation-job/models/suno-params.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,eAAO,MAAM,qBAAqB;;;EAAqB,CAAC;AACxD,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC;AAEpE,eAAO,MAAM,sBAAsB;;;EAA6C,CAAC;AACjF,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC,CAAC;AAMtE,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAyDvB,CAAC;AAEP,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC"}
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SunoParamsSchema = exports.SunoPersonaModelSchema = exports.SunoVocalGenderSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const generation_model_1 = require("../../generation-model");
|
|
6
|
+
exports.SunoVocalGenderSchema = zod_1.z.enum(['m', 'f']);
|
|
7
|
+
exports.SunoPersonaModelSchema = zod_1.z.enum(['style_persona', 'voice_persona']);
|
|
8
|
+
// KIE/Suno docs don't state an explicit max for V5_5; capped conservatively above the
|
|
9
|
+
// documented V4.5 ceiling (8 min) pending real limits/duration-aware pricing from product.
|
|
10
|
+
const MAX_DURATION_SECONDS = 600;
|
|
11
|
+
exports.SunoParamsSchema = zod_1.z
|
|
12
|
+
.object({
|
|
13
|
+
customMode: zod_1.z.boolean().default(false),
|
|
14
|
+
prompt: zod_1.z.string().max(5000).optional(),
|
|
15
|
+
instrumental: zod_1.z.boolean().default(false),
|
|
16
|
+
audioWeight: zod_1.z.number().min(0).max(1).multipleOf(0.05).default(0.65),
|
|
17
|
+
title: zod_1.z.string().max(80).optional(),
|
|
18
|
+
style: generation_model_1.MusicStyleSchema.optional(),
|
|
19
|
+
duration: zod_1.z.number().positive().max(MAX_DURATION_SECONDS).default(120),
|
|
20
|
+
vocalGender: exports.SunoVocalGenderSchema.optional(),
|
|
21
|
+
negativeTags: zod_1.z.string().max(500).optional(),
|
|
22
|
+
styleWeight: zod_1.z.number().min(0).max(1).optional(),
|
|
23
|
+
weirdnessConstraint: zod_1.z.number().min(0).max(1).optional(),
|
|
24
|
+
personaId: zod_1.z.string().nullable().optional(),
|
|
25
|
+
personaModel: exports.SunoPersonaModelSchema.nullable().optional(),
|
|
26
|
+
})
|
|
27
|
+
.superRefine((params, ctx) => {
|
|
28
|
+
if (!params.customMode) {
|
|
29
|
+
if (!params.prompt || params.prompt.length === 0) {
|
|
30
|
+
ctx.addIssue({
|
|
31
|
+
code: 'custom',
|
|
32
|
+
path: ['prompt'],
|
|
33
|
+
message: 'Song Description (prompt) is required when Custom Mode is disabled',
|
|
34
|
+
});
|
|
35
|
+
}
|
|
36
|
+
else if (params.prompt.length > 500) {
|
|
37
|
+
ctx.addIssue({
|
|
38
|
+
code: 'custom',
|
|
39
|
+
path: ['prompt'],
|
|
40
|
+
message: 'Song Description (prompt) must be at most 500 characters in Simple Mode',
|
|
41
|
+
});
|
|
42
|
+
}
|
|
43
|
+
return;
|
|
44
|
+
}
|
|
45
|
+
if (!params.title) {
|
|
46
|
+
ctx.addIssue({
|
|
47
|
+
code: 'custom',
|
|
48
|
+
path: ['title'],
|
|
49
|
+
message: 'Title is required when Custom Mode is enabled',
|
|
50
|
+
});
|
|
51
|
+
}
|
|
52
|
+
if (!params.style) {
|
|
53
|
+
ctx.addIssue({
|
|
54
|
+
code: 'custom',
|
|
55
|
+
path: ['style'],
|
|
56
|
+
message: 'Style of Music is required when Custom Mode is enabled',
|
|
57
|
+
});
|
|
58
|
+
}
|
|
59
|
+
if (!params.instrumental && (!params.prompt || params.prompt.length === 0)) {
|
|
60
|
+
ctx.addIssue({
|
|
61
|
+
code: 'custom',
|
|
62
|
+
path: ['prompt'],
|
|
63
|
+
message: 'Lyrics (prompt) is required when Instrumental is disabled in Custom Mode',
|
|
64
|
+
});
|
|
65
|
+
}
|
|
66
|
+
});
|
|
@@ -3,5 +3,6 @@ export declare const GENERATION_MODEL_ROUTES: {
|
|
|
3
3
|
readonly GET_ALL: "";
|
|
4
4
|
readonly GET_BY_TYPE: (generationType: string) => string;
|
|
5
5
|
readonly GET_PRICE: (modelId: string) => string;
|
|
6
|
+
readonly GET_MUSIC_STYLES: "music-styles";
|
|
6
7
|
};
|
|
7
8
|
//# sourceMappingURL=generation-model.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"generation-model.d.ts","sourceRoot":"","sources":["../../../generation-model/endpoints/generation-model.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,2BAA2B,EAAG,mBAA4B,CAAC;AAExE,eAAO,MAAM,uBAAuB;;2CAEF,MAAM;kCACf,MAAM
|
|
1
|
+
{"version":3,"file":"generation-model.d.ts","sourceRoot":"","sources":["../../../generation-model/endpoints/generation-model.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,2BAA2B,EAAG,mBAA4B,CAAC;AAExE,eAAO,MAAM,uBAAuB;;2CAEF,MAAM;kCACf,MAAM;;CAErB,CAAC"}
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { HTTP_METHODS } from '../../../_common';
|
|
3
|
+
export declare const GetMusicStylesQueryResponse: z.ZodObject<{
|
|
4
|
+
styles: z.ZodArray<z.ZodEnum<{
|
|
5
|
+
Pop: "Pop";
|
|
6
|
+
Rock: "Rock";
|
|
7
|
+
"Hip-hop": "Hip-hop";
|
|
8
|
+
Electronic: "Electronic";
|
|
9
|
+
Jazz: "Jazz";
|
|
10
|
+
Classical: "Classical";
|
|
11
|
+
"R&B": "R&B";
|
|
12
|
+
Country: "Country";
|
|
13
|
+
Metal: "Metal";
|
|
14
|
+
Folk: "Folk";
|
|
15
|
+
Reggae: "Reggae";
|
|
16
|
+
Blues: "Blues";
|
|
17
|
+
Funk: "Funk";
|
|
18
|
+
Punk: "Punk";
|
|
19
|
+
Ambient: "Ambient";
|
|
20
|
+
Latin: "Latin";
|
|
21
|
+
"K-pop": "K-pop";
|
|
22
|
+
Indie: "Indie";
|
|
23
|
+
Soul: "Soul";
|
|
24
|
+
Gospel: "Gospel";
|
|
25
|
+
}>>;
|
|
26
|
+
}, z.core.$strip>;
|
|
27
|
+
export declare const GetMusicStylesQuery: {
|
|
28
|
+
method: HTTP_METHODS.GET;
|
|
29
|
+
path: "music-styles";
|
|
30
|
+
summary: string;
|
|
31
|
+
responses: {
|
|
32
|
+
200: z.ZodObject<{
|
|
33
|
+
styles: z.ZodArray<z.ZodEnum<{
|
|
34
|
+
Pop: "Pop";
|
|
35
|
+
Rock: "Rock";
|
|
36
|
+
"Hip-hop": "Hip-hop";
|
|
37
|
+
Electronic: "Electronic";
|
|
38
|
+
Jazz: "Jazz";
|
|
39
|
+
Classical: "Classical";
|
|
40
|
+
"R&B": "R&B";
|
|
41
|
+
Country: "Country";
|
|
42
|
+
Metal: "Metal";
|
|
43
|
+
Folk: "Folk";
|
|
44
|
+
Reggae: "Reggae";
|
|
45
|
+
Blues: "Blues";
|
|
46
|
+
Funk: "Funk";
|
|
47
|
+
Punk: "Punk";
|
|
48
|
+
Ambient: "Ambient";
|
|
49
|
+
Latin: "Latin";
|
|
50
|
+
"K-pop": "K-pop";
|
|
51
|
+
Indie: "Indie";
|
|
52
|
+
Soul: "Soul";
|
|
53
|
+
Gospel: "Gospel";
|
|
54
|
+
}>>;
|
|
55
|
+
}, z.core.$strip>;
|
|
56
|
+
500: z.ZodType<import("../../../_common").HttpErrorResponse, unknown, z.core.$ZodTypeInternals<import("../../../_common").HttpErrorResponse, unknown>>;
|
|
57
|
+
};
|
|
58
|
+
};
|
|
59
|
+
//# sourceMappingURL=get-music-styles.query.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-music-styles.query.d.ts","sourceRoot":"","sources":["../../../../generation-model/endpoints/queries/get-music-styles.query.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAkB,YAAY,EAA2B,MAAM,kBAAkB,CAAC;AAIzF,eAAO,MAAM,2BAA2B;;;;;;;;;;;;;;;;;;;;;;;iBAEtC,CAAC;AAEH,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAQ9B,CAAC"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.GetMusicStylesQuery = exports.GetMusicStylesQueryResponse = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const _common_1 = require("../../../_common");
|
|
6
|
+
const enums_1 = require("../../enums");
|
|
7
|
+
const generation_model_1 = require("../generation-model");
|
|
8
|
+
exports.GetMusicStylesQueryResponse = zod_1.z.object({
|
|
9
|
+
styles: zod_1.z.array(enums_1.MusicStyleSchema),
|
|
10
|
+
});
|
|
11
|
+
exports.GetMusicStylesQuery = (0, _common_1.defineContract)({
|
|
12
|
+
method: _common_1.HTTP_METHODS.GET,
|
|
13
|
+
path: generation_model_1.GENERATION_MODEL_ROUTES.GET_MUSIC_STYLES,
|
|
14
|
+
summary: 'Get fixed list of music styles for Suno music generation',
|
|
15
|
+
responses: {
|
|
16
|
+
200: exports.GetMusicStylesQueryResponse,
|
|
17
|
+
500: _common_1.HttpErrorResponseSchema,
|
|
18
|
+
},
|
|
19
|
+
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../generation-model/endpoints/queries/index.ts"],"names":[],"mappings":"AAAA,cAAc,+BAA+B,CAAC;AAC9C,cAAc,uCAAuC,CAAC;AACtD,cAAc,8BAA8B,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../generation-model/endpoints/queries/index.ts"],"names":[],"mappings":"AAAA,cAAc,+BAA+B,CAAC;AAC9C,cAAc,uCAAuC,CAAC;AACtD,cAAc,8BAA8B,CAAC;AAC7C,cAAc,0BAA0B,CAAC"}
|
|
@@ -17,3 +17,4 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
17
17
|
__exportStar(require("./get-generation-models.query"), exports);
|
|
18
18
|
__exportStar(require("./get-generation-models-by-type.query"), exports);
|
|
19
19
|
__exportStar(require("./get-generation-price.query"), exports);
|
|
20
|
+
__exportStar(require("./get-music-styles.query"), exports);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"generation-type.enum.d.ts","sourceRoot":"","sources":["../../../generation-model/enums/generation-type.enum.ts"],"names":[],"mappings":"AAAA,oBAAY,eAAe;IACvB,KAAK,UAAU;IACf,KAAK,UAAU;CAClB"}
|
|
1
|
+
{"version":3,"file":"generation-type.enum.d.ts","sourceRoot":"","sources":["../../../generation-model/enums/generation-type.enum.ts"],"names":[],"mappings":"AAAA,oBAAY,eAAe;IACvB,KAAK,UAAU;IACf,KAAK,UAAU;IACf,KAAK,UAAU;CAClB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../generation-model/enums/index.ts"],"names":[],"mappings":"AAAA,cAAc,wBAAwB,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../generation-model/enums/index.ts"],"names":[],"mappings":"AAAA,cAAc,wBAAwB,CAAC;AACvC,cAAc,oBAAoB,CAAC"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare const MUSIC_STYLE: readonly ["Pop", "Rock", "Hip-hop", "Electronic", "Jazz", "Classical", "R&B", "Country", "Metal", "Folk", "Reggae", "Blues", "Funk", "Punk", "Ambient", "Latin", "K-pop", "Indie", "Soul", "Gospel"];
|
|
3
|
+
export declare const MusicStyleSchema: z.ZodEnum<{
|
|
4
|
+
Pop: "Pop";
|
|
5
|
+
Rock: "Rock";
|
|
6
|
+
"Hip-hop": "Hip-hop";
|
|
7
|
+
Electronic: "Electronic";
|
|
8
|
+
Jazz: "Jazz";
|
|
9
|
+
Classical: "Classical";
|
|
10
|
+
"R&B": "R&B";
|
|
11
|
+
Country: "Country";
|
|
12
|
+
Metal: "Metal";
|
|
13
|
+
Folk: "Folk";
|
|
14
|
+
Reggae: "Reggae";
|
|
15
|
+
Blues: "Blues";
|
|
16
|
+
Funk: "Funk";
|
|
17
|
+
Punk: "Punk";
|
|
18
|
+
Ambient: "Ambient";
|
|
19
|
+
Latin: "Latin";
|
|
20
|
+
"K-pop": "K-pop";
|
|
21
|
+
Indie: "Indie";
|
|
22
|
+
Soul: "Soul";
|
|
23
|
+
Gospel: "Gospel";
|
|
24
|
+
}>;
|
|
25
|
+
export type MusicStyle = z.infer<typeof MusicStyleSchema>;
|
|
26
|
+
//# sourceMappingURL=music-style.enum.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"music-style.enum.d.ts","sourceRoot":"","sources":["../../../generation-model/enums/music-style.enum.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,WAAW,sMAqBd,CAAC;AAEX,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;EAAsB,CAAC;AACpD,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.MusicStyleSchema = exports.MUSIC_STYLE = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
exports.MUSIC_STYLE = [
|
|
6
|
+
'Pop',
|
|
7
|
+
'Rock',
|
|
8
|
+
'Hip-hop',
|
|
9
|
+
'Electronic',
|
|
10
|
+
'Jazz',
|
|
11
|
+
'Classical',
|
|
12
|
+
'R&B',
|
|
13
|
+
'Country',
|
|
14
|
+
'Metal',
|
|
15
|
+
'Folk',
|
|
16
|
+
'Reggae',
|
|
17
|
+
'Blues',
|
|
18
|
+
'Funk',
|
|
19
|
+
'Punk',
|
|
20
|
+
'Ambient',
|
|
21
|
+
'Latin',
|
|
22
|
+
'K-pop',
|
|
23
|
+
'Indie',
|
|
24
|
+
'Soul',
|
|
25
|
+
'Gospel',
|
|
26
|
+
];
|
|
27
|
+
exports.MusicStyleSchema = zod_1.z.enum(exports.MUSIC_STYLE);
|
|
@@ -20,6 +20,7 @@ const get_admin_referral_config_query_1 = require("../admin/endpoints/queries/ge
|
|
|
20
20
|
const get_admin_users_query_1 = require("../admin/endpoints/queries/get-admin-users.query");
|
|
21
21
|
const get_admin_user_query_1 = require("../admin/endpoints/queries/get-admin-user.query");
|
|
22
22
|
const get_admin_user_transactions_query_1 = require("../admin/endpoints/queries/get-admin-user-transactions.query");
|
|
23
|
+
const get_admin_stats_query_1 = require("../billing/endpoints/queries/get-admin-stats.query");
|
|
23
24
|
const auth_1 = require("../auth/endpoints/auth");
|
|
24
25
|
const change_password_command_1 = require("../auth/endpoints/commands/change-password.command");
|
|
25
26
|
const delete_account_command_1 = require("../auth/endpoints/commands/delete-account.command");
|
|
@@ -54,6 +55,7 @@ const get_ai_models_query_1 = require("../ai-model/endpoints/queries/get-ai-mode
|
|
|
54
55
|
const generation_model_1 = require("../generation-model/endpoints/generation-model");
|
|
55
56
|
const get_generation_models_query_1 = require("../generation-model/endpoints/queries/get-generation-models.query");
|
|
56
57
|
const get_generation_models_by_type_query_1 = require("../generation-model/endpoints/queries/get-generation-models-by-type.query");
|
|
58
|
+
const get_music_styles_query_1 = require("../generation-model/endpoints/queries/get-music-styles.query");
|
|
57
59
|
const generation_job_1 = require("../generation-job/endpoints/generation-job");
|
|
58
60
|
const create_generation_job_command_1 = require("../generation-job/endpoints/commands/create-generation-job.command");
|
|
59
61
|
const delete_generation_job_command_1 = require("../generation-job/endpoints/commands/delete-generation-job.command");
|
|
@@ -168,6 +170,7 @@ async function main() {
|
|
|
168
170
|
registerSchema('GenerationModelGetAllResponse', get_generation_models_query_1.GetGenerationModelsQueryResponse);
|
|
169
171
|
registerSchema('GenerationModelGetByTypeParams', get_generation_models_by_type_query_1.GetGenerationModelsByTypeQueryParams);
|
|
170
172
|
registerSchema('GenerationModelGetByTypeResponse', get_generation_models_by_type_query_1.GetGenerationModelsByTypeQueryResponse);
|
|
173
|
+
registerSchema('GenerationModelGetMusicStylesResponse', get_music_styles_query_1.GetMusicStylesQueryResponse);
|
|
171
174
|
registerSchema('GenerationJobCreateRequest', create_generation_job_command_1.CreateGenerationJobCommandBody);
|
|
172
175
|
registerSchema('GenerationJobCreateResponse', create_generation_job_command_1.CreateGenerationJobCommandResponse);
|
|
173
176
|
registerSchema('GenerationJobGetAllResponse', get_generation_jobs_query_1.GetGenerationJobsQueryResponse);
|
|
@@ -225,6 +228,8 @@ async function main() {
|
|
|
225
228
|
registerSchema('AdminGetUserResponse', get_admin_user_query_1.GetAdminUserQueryResponse);
|
|
226
229
|
registerSchema('AdminGetUserTransactionsQuery', get_admin_user_transactions_query_1.GetAdminUserTransactionsQueryQuery);
|
|
227
230
|
registerSchema('AdminGetUserTransactionsResponse', get_admin_user_transactions_query_1.GetAdminUserTransactionsQueryResponse);
|
|
231
|
+
registerSchema('AdminGetStatsQuery', get_admin_stats_query_1.GetAdminStatsQueryQuery);
|
|
232
|
+
registerSchema('AdminGetStatsResponse', get_admin_stats_query_1.GetAdminStatsQueryResponse);
|
|
228
233
|
const authContracts = [
|
|
229
234
|
register_command_1.RegisterCommand,
|
|
230
235
|
login_command_1.LoginCommand,
|
|
@@ -257,6 +262,7 @@ async function main() {
|
|
|
257
262
|
get_generation_models_query_1.GetGenerationModelsQuery,
|
|
258
263
|
get_generation_models_by_type_query_1.GetGenerationModelsByTypeQuery,
|
|
259
264
|
get_generation_price_query_1.GetGenerationPriceQuery,
|
|
265
|
+
get_music_styles_query_1.GetMusicStylesQuery,
|
|
260
266
|
];
|
|
261
267
|
const generationJobContracts = [
|
|
262
268
|
create_generation_job_command_1.CreateGenerationJobCommand,
|
|
@@ -288,6 +294,7 @@ async function main() {
|
|
|
288
294
|
get_admin_users_query_1.GetAdminUsersQuery,
|
|
289
295
|
get_admin_user_query_1.GetAdminUserQuery,
|
|
290
296
|
get_admin_user_transactions_query_1.GetAdminUserTransactionsQuery,
|
|
297
|
+
get_admin_stats_query_1.GetAdminStatsQuery,
|
|
291
298
|
];
|
|
292
299
|
for (const contract of authContracts) {
|
|
293
300
|
const method = contract.method.toLowerCase();
|