@acedatacloud/sdk 2026.1009.0 → 2026.1009.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.
- package/README.md +31 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -108,6 +108,37 @@ const fluxTask = await client.images.generate({
|
|
|
108
108
|
});
|
|
109
109
|
```
|
|
110
110
|
|
|
111
|
+
### Nano Banana 2.1
|
|
112
|
+
|
|
113
|
+
Select `model: 'nano-banana-2.1'` explicitly for generation or editing at
|
|
114
|
+
1K, 2K, or 4K. Omitting `model` still uses `nano-banana`; there is no
|
|
115
|
+
`nano-banana-2.1:official` variant.
|
|
116
|
+
|
|
117
|
+
```typescript
|
|
118
|
+
const task = await client.nanobanana.generate({
|
|
119
|
+
action: 'generate',
|
|
120
|
+
model: 'nano-banana-2.1',
|
|
121
|
+
prompt: 'A blue ceramic vase on a cream background',
|
|
122
|
+
resolution: '2K',
|
|
123
|
+
aspectRatio: '1:1',
|
|
124
|
+
});
|
|
125
|
+
await task.wait();
|
|
126
|
+
const imageUrls = task.urls();
|
|
127
|
+
|
|
128
|
+
const editTask = await client.nanobanana.generate({
|
|
129
|
+
action: 'edit',
|
|
130
|
+
model: 'nano-banana-2.1',
|
|
131
|
+
prompt: 'Change the vase to green; preserve the background',
|
|
132
|
+
imageUrls,
|
|
133
|
+
resolution: '4K',
|
|
134
|
+
});
|
|
135
|
+
await editTask.wait();
|
|
136
|
+
```
|
|
137
|
+
|
|
138
|
+
The public model ID also works with `client.openai.images.generate(...)` and
|
|
139
|
+
`client.openai.images.edit(...)`; those use the OpenAI-compatible fields
|
|
140
|
+
(`image` for editing) and return response objects, not task handles.
|
|
141
|
+
|
|
111
142
|
## Multi-Provider Support
|
|
112
143
|
|
|
113
144
|
Image, video, and audio resources support a `provider` parameter to switch between services:
|