The Imagen API lets you create high quality images in seconds,
using text prompts and existing images to guide the generation. The API design for the Imagen 3 model differs from the
Imagen 2 and Imagen models.
View Imagen for Editing and Customization model card
Choose your model version before continuing:
For more information about the features that each model supports, see
Imagen
models. Syntax to edit an image from a text prompt. Syntax to edit an image. See examples for implementation details. The following examples show how to use the Imagen models
to edit images. Use the following object class IDs to
automatically create an image mask based on specific objects.Supported Models
Model
Code
Image Editing
Example syntax
Syntax
Parameter list
Edit Images
Examples
Edit images
Class IDs
Class ID (
class_
)Object
0
backpack
1
umbrella
2
bag
3
tie
4
suitcase
5
case
6
bird
7
cat
8
dog
9
horse
10
sheep
11
cow
12
elephant
13
bear
14
zebra
15
giraffe
16
animal (other)
17
microwave
18
radiator
19
oven
20
toaster
21
storage tank
22
conveyor belt
23
sink
24
refrigerator
25
washer dryer
26
fan
27
dishwasher
28
toilet
29
bathtub
30
shower
31
tunnel
32
bridge
33
pier wharf
34
tent
35
building
36
ceiling
37
laptop
38
keyboard
39
mouse
40
remote
41
cell phone
42
television
43
floor
44
stage
45
banana
46
apple
47
sandwich
48
orange
49
broccoli
50
carrot
51
hot dog
52
pizza
53
donut
54
cake
55
fruit (other)
56
food (other)
57
chair (other)
58
armchair
59
swivel chair
60
stool
61
seat
62
couch
63
trash can
64
potted plant
65
nightstand
66
bed
67
table
68
pool table
69
barrel
70
desk
71
ottoman
72
wardrobe
73
crib
74
basket
75
chest of drawers
76
bookshelf
77
counter (other)
78
bathroom counter
79
kitchen island
80
door
81
light (other)
82
lamp
83
sconce
84
chandelier
85
mirror
86
whiteboard
87
shelf
88
stairs
89
escalator
90
cabinet
91
fireplace
92
stove
93
arcade machine
94
gravel
95
platform
96
playingfield
97
railroad
98
road
99
snow
100
sidewalk pavement
101
runway
102
terrain
103
book
104
box
105
clock
106
vase
107
scissors
108
plaything (other)
109
teddy bear
110
hair dryer
111
toothbrush
112
painting
113
poster
114
bulletin board
115
bottle
116
cup
117
wine glass
118
knife
119
fork
120
spoon
121
bowl
122
tray
123
range hood
124
plate
125
person
126
rider (other)
127
bicyclist
128
motorcyclist
129
paper
130
streetlight
131
road barrier
132
mailbox
133
cctv camera
134
junction box
135
traffic sign
136
traffic light
137
fire hydrant
138
parking meter
139
bench
140
bike rack
141
billboard
142
sky
143
pole
144
fence
145
railing banister
146
guard rail
147
mountain hill
148
rock
149
frisbee
150
skis
151
snowboard
152
sports ball
153
kite
154
baseball bat
155
baseball glove
156
skateboard
157
surfboard
158
tennis racket
159
net
160
base
161
sculpture
162
column
163
fountain
164
awning
165
apparel
166
banner
167
flag
168
blanket
169
curtain (other)
170
shower curtain
171
pillow
172
towel
173
rug floormat
174
vegetation
175
bicycle
176
car
177
autorickshaw
178
motorcycle
179
airplane
180
bus
181
train
182
truck
183
trailer
184
boat ship
185
slow wheeled object
186
river lake
187
sea
188
water (other)
189
swimming pool
190
waterfall
191
wall
192
window
193
window blind
What's next
Edit images
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-08-21 UTC.