Skip to content

Commit 6a5526f

Browse files
feat(api): api update
1 parent af6abac commit 6a5526f

9 files changed

Lines changed: 81 additions & 67 deletions

File tree

.stats.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
configured_endpoints: 10
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/luma-ai-karanganesan%2Fluma_ai-40360b5fde0fe57b8078d35565a402c5dc9af5cafa897fba042fdceff9d32617.yml
3-
openapi_spec_hash: 1ef811d56d6913d8f5c7f3bcdab0610c
4-
config_hash: f8dc17c4f411a28d1002067bbc0d4b5f
1+
configured_endpoints: 9
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/luma-ai-karanganesan%2Fluma_ai-77915e19d91e49806410e1f72c98350af91b90cc9757cc502214e532d51016fe.yml
3+
openapi_spec_hash: 5a8e2fe22b4400e78b88621090f145d8
4+
config_hash: 340ab81846cdf3a6dd774f425fd612aa

api.md

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -14,15 +14,7 @@ Methods:
1414
- <code title="get /generations/{id}">client.generations.<a href="./src/resources/generations/generations.ts">get</a>(id) -> Generation</code>
1515
- <code title="post /generations/{id}/upscale">client.generations.<a href="./src/resources/generations/generations.ts">upscale</a>(id, { ...params }) -> Generation</code>
1616

17-
## CameraMotion
18-
19-
Types:
20-
21-
- <code><a href="./src/resources/generations/camera-motion.ts">CameraMotionListResponse</a></code>
22-
23-
Methods:
24-
25-
- <code title="get /generations/camera_motion/list">client.generations.cameraMotion.<a href="./src/resources/generations/camera-motion.ts">list</a>() -> CameraMotionListResponse</code>
17+
## Concepts
2618

2719
## Image
2820

src/resources/generations/camera-motion.ts

Lines changed: 0 additions & 19 deletions
This file was deleted.
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2+
3+
import { APIResource } from '../../resource';
4+
5+
export class Concepts extends APIResource {}

src/resources/generations/generations.ts

Lines changed: 45 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,15 @@
33
import { APIResource } from '../../resource';
44
import { isRequestOptions } from '../../core';
55
import * as Core from '../../core';
6-
import * as CameraMotionAPI from './camera-motion';
7-
import { CameraMotion, CameraMotionListResponse } from './camera-motion';
6+
import * as ConceptsAPI from './concepts';
7+
import { Concepts } from './concepts';
88
import * as ImageAPI from './image';
99
import { Image, ImageCreateParams } from './image';
1010
import * as VideoAPI from './video';
1111
import { Video, VideoCreateParams } from './video';
1212

1313
export class Generations extends APIResource {
14-
cameraMotion: CameraMotionAPI.CameraMotion = new CameraMotionAPI.CameraMotion(this._client);
14+
concepts: ConceptsAPI.Concepts = new ConceptsAPI.Concepts(this._client);
1515
image: ImageAPI.Image = new ImageAPI.Image(this._client);
1616
video: VideoAPI.Video = new VideoAPI.Video(this._client);
1717

@@ -159,6 +159,11 @@ export namespace Generation {
159159
*/
160160
callback_url?: string;
161161

162+
/**
163+
* The concepts of the generation
164+
*/
165+
concepts?: Array<GenerationRequest.Concept>;
166+
162167
/**
163168
* The duration of the generation
164169
*/
@@ -193,6 +198,16 @@ export namespace Generation {
193198
}
194199

195200
export namespace GenerationRequest {
201+
/**
202+
* The concept object
203+
*/
204+
export interface Concept {
205+
/**
206+
* The key of the concept
207+
*/
208+
key: string;
209+
}
210+
196211
/**
197212
* The keyframes of the generation
198213
*/
@@ -295,6 +310,16 @@ export namespace Generation {
295310
prompt?: string;
296311

297312
style_ref?: Array<ImageGenerationRequest.StyleRef>;
313+
314+
/**
315+
* Create image in synchronous mode and return complated image
316+
*/
317+
sync?: boolean;
318+
319+
/**
320+
* The timeout for the synchronous image generation
321+
*/
322+
sync_timeout?: number;
298323
}
299324

300325
export namespace ImageGenerationRequest {
@@ -446,6 +471,11 @@ export interface GenerationCreateParams {
446471
*/
447472
callback_url?: string;
448473

474+
/**
475+
* The concepts of the generation
476+
*/
477+
concepts?: Array<GenerationCreateParams.Concept>;
478+
449479
/**
450480
* The duration of the generation
451481
*/
@@ -480,6 +510,16 @@ export interface GenerationCreateParams {
480510
}
481511

482512
export namespace GenerationCreateParams {
513+
/**
514+
* The concept object
515+
*/
516+
export interface Concept {
517+
/**
518+
* The key of the concept
519+
*/
520+
key: string;
521+
}
522+
483523
/**
484524
* The keyframes of the generation
485525
*/
@@ -585,7 +625,7 @@ export interface GenerationUpscaleParams {
585625
resolution?: '540p' | '720p' | '1080p' | '4k' | (string & {});
586626
}
587627

588-
Generations.CameraMotion = CameraMotion;
628+
Generations.Concepts = Concepts;
589629
Generations.Image = Image;
590630
Generations.Video = Video;
591631

@@ -599,7 +639,7 @@ export declare namespace Generations {
599639
type GenerationUpscaleParams as GenerationUpscaleParams,
600640
};
601641

602-
export { CameraMotion as CameraMotion, type CameraMotionListResponse as CameraMotionListResponse };
642+
export { Concepts as Concepts };
603643

604644
export { Image as Image, type ImageCreateParams as ImageCreateParams };
605645

src/resources/generations/image.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,16 @@ export interface ImageCreateParams {
4646
prompt?: string;
4747

4848
style_ref?: Array<ImageCreateParams.StyleRef>;
49+
50+
/**
51+
* Create image in synchronous mode and return complated image
52+
*/
53+
sync?: boolean;
54+
55+
/**
56+
* The timeout for the synchronous image generation
57+
*/
58+
sync_timeout?: number;
4959
}
5060

5161
export namespace ImageCreateParams {

src/resources/generations/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
22

3-
export { CameraMotion, type CameraMotionListResponse } from './camera-motion';
3+
export { Concepts } from './concepts';
44
export {
55
Generations,
66
type Generation,

src/resources/generations/video.ts

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,11 @@ export interface VideoCreateParams {
2626
*/
2727
callback_url?: string;
2828

29+
/**
30+
* The concepts of the generation
31+
*/
32+
concepts?: Array<VideoCreateParams.Concept>;
33+
2934
/**
3035
* The duration of the generation
3136
*/
@@ -60,6 +65,16 @@ export interface VideoCreateParams {
6065
}
6166

6267
export namespace VideoCreateParams {
68+
/**
69+
* The concept object
70+
*/
71+
export interface Concept {
72+
/**
73+
* The key of the concept
74+
*/
75+
key: string;
76+
}
77+
6378
/**
6479
* The keyframes of the generation
6580
*/

tests/api-resources/generations/camera-motion.test.ts

Lines changed: 0 additions & 29 deletions
This file was deleted.

0 commit comments

Comments
 (0)