Image-uitbreiding
Gebruik de Kling Image Expansion API via CometAPI om afbeeldingen buiten de oorspronkelijke randen uit te breiden, met behoud van context en controleerbare opvulling voor video-klare assets.
Gebruik dit endpoint om een afbeelding buiten de oorspronkelijke randen uit te breiden wanneer je meer canvas rond de broninhoud nodig hebt.Documentation Index
Fetch the complete documentation index at: https://apidoc.cometapi.com/llms.txt
Use this file to discover all available pages before exploring further.
Hoe de uitbreidingsverhoudingen werken
- Elke verhouding wordt gemeten ten opzichte van de oorspronkelijke breedte of hoogte
- Het gecombineerde uitgebreide canvas moet nog steeds binnen de door Kling gedocumenteerde oppervlaktelimieten blijven
- Begin met kleine waarden zoals
0.1aan elke zijde voordat je grotere uitbreidingen probeert
Huidige beschikbaarheid
- De gedocumenteerde route is
POST /kling/v1/images/editing/expand - Dit endpoint geeft een 404-respons terug
Autorisaties
Bearer token authentication. Use your CometAPI key.
Headers
Optional content type header.
Body
Source image to expand. Accepts an image URL or raw Base64 string (no data: prefix). Supported formats: JPG, JPEG, PNG. Max 10 MB, minimum 300×300 px, aspect ratio between 1:2.5 and 2.5:1.
Upward expansion as a multiple of the original image height. Range: 0–2. The resulting image area must not exceed 3× the original.
Rightward expansion as a multiple of the original image width. Range: 0–2. The resulting image area must not exceed 3× the original.
Leftward expansion as a multiple of the original image width. Range: 0–2. The resulting image area must not exceed 3× the original.
Downward expansion as a multiple of the original image height. Range: 0–2. The resulting image area must not exceed 3× the original.
Optional text prompt to guide the expanded area content. Max 2500 characters.
Number of expanded images to generate.
Webhook URL for task status notifications. The server sends a callback when the task status changes.
Optional user-defined task ID for your own tracking. Does not replace the system-generated task ID. Must be unique per account.