From 8796d17f523014c10dd4c29063eb12303fb263d2 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 24 Sep 2026 18:43:58 +0000 Subject: [PATCH] feat: Updated OpenAPI spec --- .../Generated/Ideogram.IIdeogramClient.g.cs | 5 + ...eClient.PostGenerateImageV2Ideogram45.g.cs | 43 +- ...eClient.PostGenerateImageV2IdeogramV2.g.cs | 7 +- ...Client.PostGenerateImageV2IdeogramV2A.g.cs | 7 +- ...eClient.PostGenerateImageV2IdeogramV3.g.cs | 7 +- ...ostGenerateImageV2IdeogramV3Character.g.cs | 7 +- ...tGenerateImageV2IdeogramV3CustomModel.g.cs | 7 +- ...tGenerateImageV2IdeogramV3Transparent.g.cs | 7 +- ...eciseEditClient.Authorizations.Bearer.g.cs | 16 + ...ient.PostPreciseEditImageV2Ideogram45.g.cs | 223 ++++ .../Ideogram.IImagesPreciseEditClient.g.cs | 49 + .../Generated/Ideogram.IdeogramClient.g.cs | 9 + ....ImagesGenerate.JsonSerializerContext.g.cs | 16 + ...eClient.PostGenerateImageV2Ideogram45.g.cs | 97 +- ...eClient.PostGenerateImageV2IdeogramV2.g.cs | 7 +- ...Client.PostGenerateImageV2IdeogramV2A.g.cs | 7 +- ...eClient.PostGenerateImageV2IdeogramV3.g.cs | 7 +- ...ostGenerateImageV2IdeogramV3Character.g.cs | 7 +- ...tGenerateImageV2IdeogramV3CustomModel.g.cs | 7 +- ...tGenerateImageV2IdeogramV3Transparent.g.cs | 7 +- ...agesPreciseEdit.JsonSerializerContext.g.cs | 205 ++++ ...eciseEditClient.Authorizations.Bearer.g.cs | 35 + ...PreciseEditClient.Constructors.Bearer.g.cs | 31 + ...ient.PostPreciseEditImageV2Ideogram45.g.cs | 1080 +++++++++++++++++ .../Ideogram.ImagesPreciseEditClient.g.cs | 144 +++ ....JsonConverters.IdeogramV3AspectRatio.g.cs | 53 + ...verters.IdeogramV3AspectRatioNullable.g.cs | 60 + ...tImageIdeogram45RequestRenderingSpeed.g.cs | 53 + ...eogram45RequestRenderingSpeedNullable.g.cs | 60 + .../Ideogram.JsonSerializerContext.g.cs | 42 +- .../Ideogram.JsonSerializerContextTypes.g.cs | 566 ++++----- ...Models.GenerateImageIdeogram45Request.g.cs | 100 +- ...odels.GenerateImageIdeogramV2ARequest.g.cs | 16 +- ...Models.GenerateImageIdeogramV2Request.g.cs | 16 +- ...nerateImageIdeogramV3CharacterRequest.g.cs | 16 +- ...rateImageIdeogramV3CustomModelRequest.g.cs | 16 +- ...Models.GenerateImageIdeogramV3Request.g.cs | 16 +- ...rateImageIdeogramV3TransparentRequest.g.cs | 16 +- ...Ideogram.Models.IdeogramV3AspectRatio.g.cs | 138 +++ ...reciseEditImageIdeogram45Request.Json.g.cs | 141 +++ ...els.PreciseEditImageIdeogram45Request.g.cs | 250 ++++ ...tImageIdeogram45RequestRenderingSpeed.g.cs | 64 + ...eciseEditImageIdeogram45Response.Json.g.cs | 141 +++ ...ls.PreciseEditImageIdeogram45Response.g.cs | 76 ++ .../Generated/autosdk.generated-examples.json | 177 +-- src/libs/Ideogram/openapi.json | 300 ++++- 46 files changed, 3861 insertions(+), 493 deletions(-) create mode 100644 src/libs/Ideogram/Generated/Ideogram.IImagesPreciseEditClient.Authorizations.Bearer.g.cs create mode 100644 src/libs/Ideogram/Generated/Ideogram.IImagesPreciseEditClient.PostPreciseEditImageV2Ideogram45.g.cs create mode 100644 src/libs/Ideogram/Generated/Ideogram.IImagesPreciseEditClient.g.cs create mode 100644 src/libs/Ideogram/Generated/Ideogram.ImagesPreciseEdit.JsonSerializerContext.g.cs create mode 100644 src/libs/Ideogram/Generated/Ideogram.ImagesPreciseEditClient.Authorizations.Bearer.g.cs create mode 100644 src/libs/Ideogram/Generated/Ideogram.ImagesPreciseEditClient.Constructors.Bearer.g.cs create mode 100644 src/libs/Ideogram/Generated/Ideogram.ImagesPreciseEditClient.PostPreciseEditImageV2Ideogram45.g.cs create mode 100644 src/libs/Ideogram/Generated/Ideogram.ImagesPreciseEditClient.g.cs create mode 100644 src/libs/Ideogram/Generated/Ideogram.JsonConverters.IdeogramV3AspectRatio.g.cs create mode 100644 src/libs/Ideogram/Generated/Ideogram.JsonConverters.IdeogramV3AspectRatioNullable.g.cs create mode 100644 src/libs/Ideogram/Generated/Ideogram.JsonConverters.PreciseEditImageIdeogram45RequestRenderingSpeed.g.cs create mode 100644 src/libs/Ideogram/Generated/Ideogram.JsonConverters.PreciseEditImageIdeogram45RequestRenderingSpeedNullable.g.cs create mode 100644 src/libs/Ideogram/Generated/Ideogram.Models.IdeogramV3AspectRatio.g.cs create mode 100644 src/libs/Ideogram/Generated/Ideogram.Models.PreciseEditImageIdeogram45Request.Json.g.cs create mode 100644 src/libs/Ideogram/Generated/Ideogram.Models.PreciseEditImageIdeogram45Request.g.cs create mode 100644 src/libs/Ideogram/Generated/Ideogram.Models.PreciseEditImageIdeogram45RequestRenderingSpeed.g.cs create mode 100644 src/libs/Ideogram/Generated/Ideogram.Models.PreciseEditImageIdeogram45Response.Json.g.cs create mode 100644 src/libs/Ideogram/Generated/Ideogram.Models.PreciseEditImageIdeogram45Response.g.cs diff --git a/src/libs/Ideogram/Generated/Ideogram.IIdeogramClient.g.cs b/src/libs/Ideogram/Generated/Ideogram.IIdeogramClient.g.cs index 4c80666..c5abab7 100644 --- a/src/libs/Ideogram/Generated/Ideogram.IIdeogramClient.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.IIdeogramClient.g.cs @@ -103,6 +103,11 @@ public partial interface IIdeogramClient : global::System.IDisposable /// public ImagesInpaintClient ImagesInpaint { get; } + /// + /// Edit source images at the source's own width and height. These endpoints never reframe: the output always matches the image you sent. + /// + public ImagesPreciseEditClient ImagesPreciseEdit { get; } + /// /// Expand an existing image to a new model-specific output shape while
/// preserving the source content and filling the new area. diff --git a/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2Ideogram45.g.cs b/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2Ideogram45.g.cs index 86c10a2..df7412e 100644 --- a/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2Ideogram45.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2Ideogram45.g.cs @@ -118,17 +118,20 @@ public partial interface IImagesGenerateClient /// Default Value: false /// /// - /// The prompt to generate images from. Accepts either natural
+ /// The prompt to generate images from, or the edit instruction to
+ /// apply when source images are supplied. Accepts either natural
/// language or a structured Ideogram 4.0 JSON prompt; the server
- /// detects which was supplied. Required without source images; with
- /// sources it is optional guidance and may be empty. + /// detects which was supplied. /// /// - /// Controls magic prompt (automatic prompt rewriting). `auto` (the
- /// default) and `on` rewrite a natural-language prompt, while a
- /// prompt that is already a valid structured JSON prompt is always
- /// consumed directly. `off` disables rewriting entirely: the model
- /// receives your prompt verbatim.
+ /// Controls how a natural-language prompt is prepared. `auto` (the
+ /// default) and `on` rewrite and expand the prompt before
+ /// generation. `off` keeps your wording and only converts the prompt
+ /// into the structured format the model consumes. A prompt that is
+ /// already a valid structured JSON prompt skips magic prompt
+ /// entirely unless `magic_prompt` is `on`. With source images the
+ /// prompt is an edit instruction, and every mode converts it into
+ /// the structured edit contract the model consumes.
/// Default Value: auto /// /// @@ -137,17 +140,27 @@ public partial interface IImagesGenerateClient /// /// The source images to transform (max 5, max size 25MB per image), as raw bytes; only JPEG, PNG, and WEBP formats are supported. Multipart requests only; ignored if `image_asset_identifiers` is also supplied. /// + /// + /// An optional mask confining the edit to part of the first source image, as raw bytes (multipart requests only; JPEG, PNG, or WEBP, max 25MB). Black marks the area to edit and white the area to preserve; values in between are rounded to whichever is nearer. The mask must have the same width and height as the first source image, and must contain both black and white areas. Requires source images uploaded as raw `images` bytes; masks cannot be combined with `image_asset_identifiers`. The mask is supplied to the model as an additional reference image, so a masked request may carry at most three other source images. Supplying a mask fixes the output to the first source's own size, so `size` is rejected alongside it. + /// + /// + /// An optional mask confining the edit to part of the first source image, as raw bytes (multipart requests only; JPEG, PNG, or WEBP, max 25MB). Black marks the area to edit and white the area to preserve; values in between are rounded to whichever is nearer. The mask must have the same width and height as the first source image, and must contain both black and white areas. Requires source images uploaded as raw `images` bytes; masks cannot be combined with `image_asset_identifiers`. The mask is supplied to the model as an additional reference image, so a masked request may carry at most three other source images. Supplying a mask fixes the output to the first source's own size, so `size` is rejected alongside it. + /// /// /// The output size: "auto" or an exact "WIDTHxHEIGHT".
/// Without source images, an exact size must be one of the supported
/// 1K/2K presets (for example 1024x1024, 2048x2048 or 1440x2880);
/// "auto" or omitted lets the server pick a supported size based on
/// the prompt.
- /// With source images, "auto" (the default) uses the supported
- /// resolution closest to the first source's dimensions, and an exact
- /// size must have both dimensions multiples of 32 and at least 256px,
- /// the total size at most 2048x2048 pixels, and the aspect ratio at
- /// most 6:1.
+ /// With source images, "auto" (the default) returns the output at the
+ /// first source image's own width and height. A source too large for
+ /// the model is scaled down to fit while keeping its exact proportion,
+ /// and a source whose aspect ratio is outside 1:6 to 6:1 is rejected,
+ /// because serving it would mean reshaping an image you did not ask to
+ /// reshape — name an exact size if that is what you want.
+ /// An exact size must have both dimensions multiples of 32 and at least
+ /// 256px, the total size at most 2048x2048 pixels, and the aspect ratio
+ /// at most 6:1. Naming one reshapes the source to it.
/// Pricing is tiered by the resolved output pixels: up to 1024x1024
/// bills as 1K, above that as 2K.
/// Example: 2048x2048 @@ -192,11 +205,13 @@ public partial interface IImagesGenerateClient /// The token to cancel the operation with /// global::System.Threading.Tasks.Task PostGenerateImageV2Ideogram45Async( + string prompt, bool? dryRun = default, - string? prompt = default, global::Ideogram.MagicPromptMode? magicPrompt = default, global::System.Collections.Generic.IList? imageAssetIdentifiers = default, global::System.Collections.Generic.IList? images = default, + byte[]? mask = default, + string? maskname = default, string? size = default, global::Ideogram.GenerateImageIdeogram45RequestRenderingSpeed? renderingSpeed = default, int? seed = default, diff --git a/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2IdeogramV2.g.cs b/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2IdeogramV2.g.cs index 521f0b9..70b4b5d 100644 --- a/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2IdeogramV2.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2IdeogramV2.g.cs @@ -86,7 +86,10 @@ public partial interface IImagesGenerateClient /// Example: 12345 /// /// - /// The aspect ratio to use for image generation, which determines the image's resolution. Cannot be used in conjunction with resolution. Defaults to 1x1. + /// The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the
+ /// model select a ratio from the prompt; any other value pins the ratio.
+ /// Cannot be combined with `resolution`. Omitting the field is not `auto`:
+ /// it uses `1x1`. /// /// /// The rendering speed to use. `turbo` generates faster at a lower cost, while `quality` prioritizes the highest-quality result.
@@ -136,7 +139,7 @@ public partial interface IImagesGenerateClient bool? dryRun = default, string? negativePrompt = default, int? seed = default, - global::Ideogram.AspectRatioV3? aspectRatio = default, + global::Ideogram.IdeogramV3AspectRatio? aspectRatio = default, global::Ideogram.GenerateImageIdeogramV2RequestRenderingSpeed? renderingSpeed = default, global::Ideogram.MagicPromptMode? magicPrompt = default, int? numImages = default, diff --git a/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2IdeogramV2A.g.cs b/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2IdeogramV2A.g.cs index cc4feaf..33b3783 100644 --- a/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2IdeogramV2A.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2IdeogramV2A.g.cs @@ -83,7 +83,10 @@ public partial interface IImagesGenerateClient /// Example: 12345 /// /// - /// The aspect ratio to use for image generation, which determines the image's resolution. Cannot be used in conjunction with resolution. Defaults to 1x1. + /// The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the
+ /// model select a ratio from the prompt; any other value pins the ratio.
+ /// Cannot be combined with `resolution`. Omitting the field is not `auto`:
+ /// it uses `1x1`. /// /// /// The rendering speed to use. `turbo` generates faster at a lower cost, while `quality` prioritizes the highest-quality result.
@@ -132,7 +135,7 @@ public partial interface IImagesGenerateClient string prompt, bool? dryRun = default, int? seed = default, - global::Ideogram.AspectRatioV3? aspectRatio = default, + global::Ideogram.IdeogramV3AspectRatio? aspectRatio = default, global::Ideogram.GenerateImageIdeogramV2ARequestRenderingSpeed? renderingSpeed = default, global::Ideogram.MagicPromptMode? magicPrompt = default, int? numImages = default, diff --git a/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2IdeogramV3.g.cs b/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2IdeogramV3.g.cs index 3535896..0e44320 100644 --- a/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2IdeogramV3.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2IdeogramV3.g.cs @@ -102,7 +102,10 @@ public partial interface IImagesGenerateClient /// Example: 1280x800 /// /// - /// The aspect ratio to use for image generation, which determines the image's resolution. Cannot be used in conjunction with resolution. Defaults to 1x1. + /// The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the
+ /// model select a ratio from the prompt; any other value pins the ratio.
+ /// Cannot be combined with `resolution`. Omitting the field is not `auto`:
+ /// it uses `1x1`. /// /// /// The rendering speed to use.
@@ -176,7 +179,7 @@ public partial interface IImagesGenerateClient string? negativePrompt = default, int? seed = default, global::Ideogram.ResolutionV3? resolution = default, - global::Ideogram.AspectRatioV3? aspectRatio = default, + global::Ideogram.IdeogramV3AspectRatio? aspectRatio = default, global::Ideogram.GenerateImageIdeogramV3RequestRenderingSpeed? renderingSpeed = default, global::Ideogram.MagicPromptMode? magicPrompt = default, int? numImages = default, diff --git a/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2IdeogramV3Character.g.cs b/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2IdeogramV3Character.g.cs index 15eee05..c6d7c05 100644 --- a/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2IdeogramV3Character.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2IdeogramV3Character.g.cs @@ -144,7 +144,10 @@ public partial interface IImagesGenerateClient /// Example: 1280x800 /// /// - /// The aspect ratio to use for image generation, which determines the image's resolution. Cannot be used in conjunction with resolution. Defaults to 1x1. + /// The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the
+ /// model select a ratio from the prompt; any other value pins the ratio.
+ /// Cannot be combined with `resolution`. Omitting the field is not `auto`:
+ /// it uses `1x1`. /// /// /// The rendering speed to use.
@@ -213,7 +216,7 @@ public partial interface IImagesGenerateClient string? characterReferenceMaskname = default, int? seed = default, global::Ideogram.ResolutionV3? resolution = default, - global::Ideogram.AspectRatioV3? aspectRatio = default, + global::Ideogram.IdeogramV3AspectRatio? aspectRatio = default, global::Ideogram.GenerateImageIdeogramV3CharacterRequestRenderingSpeed? renderingSpeed = default, global::Ideogram.MagicPromptMode? magicPrompt = default, int? numImages = default, diff --git a/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2IdeogramV3CustomModel.g.cs b/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2IdeogramV3CustomModel.g.cs index 10b22a4..5957f57 100644 --- a/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2IdeogramV3CustomModel.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2IdeogramV3CustomModel.g.cs @@ -97,7 +97,10 @@ public partial interface IImagesGenerateClient /// Example: 1280x800 /// /// - /// The aspect ratio to use for image generation, which determines the image's resolution. Cannot be used in conjunction with resolution. Defaults to 1x1. + /// The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the
+ /// model select a ratio from the prompt; any other value pins the ratio.
+ /// Cannot be combined with `resolution`. Omitting the field is not `auto`:
+ /// it uses `1x1`. /// /// /// The rendering speed to use. When omitted, the server chooses a speed supported by the selected custom model. @@ -160,7 +163,7 @@ public partial interface IImagesGenerateClient string? negativePrompt = default, int? seed = default, global::Ideogram.ResolutionV3? resolution = default, - global::Ideogram.AspectRatioV3? aspectRatio = default, + global::Ideogram.IdeogramV3AspectRatio? aspectRatio = default, global::Ideogram.GenerateImageIdeogramV3CustomModelRequestRenderingSpeed? renderingSpeed = default, global::Ideogram.MagicPromptMode? magicPrompt = default, int? numImages = default, diff --git a/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2IdeogramV3Transparent.g.cs b/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2IdeogramV3Transparent.g.cs index 240751e..60a2fc8 100644 --- a/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2IdeogramV3Transparent.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.IImagesGenerateClient.PostGenerateImageV2IdeogramV3Transparent.g.cs @@ -90,7 +90,10 @@ public partial interface IImagesGenerateClient /// Default Value: x1 /// /// - /// The aspect ratio to use for image generation, which determines the image's resolution. Cannot be used in conjunction with resolution. Defaults to 1x1. + /// The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the
+ /// model select a ratio from the prompt; any other value pins the ratio.
+ /// Cannot be combined with `resolution`. Omitting the field is not `auto`:
+ /// it uses `1x1`. /// /// /// The rendering speed to use.
@@ -137,7 +140,7 @@ public partial interface IImagesGenerateClient string? negativePrompt = default, int? seed = default, global::Ideogram.GenerateImageIdeogramV3TransparentRequestUpscaleFactor? upscaleFactor = default, - global::Ideogram.AspectRatioV3? aspectRatio = default, + global::Ideogram.IdeogramV3AspectRatio? aspectRatio = default, global::Ideogram.GenerateImageIdeogramV3TransparentRequestRenderingSpeed? renderingSpeed = default, global::Ideogram.MagicPromptMode? magicPrompt = default, int? numImages = default, diff --git a/src/libs/Ideogram/Generated/Ideogram.IImagesPreciseEditClient.Authorizations.Bearer.g.cs b/src/libs/Ideogram/Generated/Ideogram.IImagesPreciseEditClient.Authorizations.Bearer.g.cs new file mode 100644 index 0000000..44710ba --- /dev/null +++ b/src/libs/Ideogram/Generated/Ideogram.IImagesPreciseEditClient.Authorizations.Bearer.g.cs @@ -0,0 +1,16 @@ + +#nullable enable + +namespace Ideogram +{ + public partial interface IImagesPreciseEditClient + { + /// + /// Authorize using bearer authentication. + /// + /// + + public void AuthorizeUsingBearer( + string apiKey); + } +} \ No newline at end of file diff --git a/src/libs/Ideogram/Generated/Ideogram.IImagesPreciseEditClient.PostPreciseEditImageV2Ideogram45.g.cs b/src/libs/Ideogram/Generated/Ideogram.IImagesPreciseEditClient.PostPreciseEditImageV2Ideogram45.g.cs new file mode 100644 index 0000000..227281e --- /dev/null +++ b/src/libs/Ideogram/Generated/Ideogram.IImagesPreciseEditClient.PostPreciseEditImageV2Ideogram45.g.cs @@ -0,0 +1,223 @@ +#nullable enable + +namespace Ideogram +{ + public partial interface IImagesPreciseEditClient + { + /// + /// Edit an image with Ideogram 4.5, keeping the source's exact geometry
+ /// Edit an image with Ideogram 4.5, returning output at that image's exact
+ /// width and height. An image too large for the model is scaled down to
+ /// fit while keeping its exact proportion, and one whose aspect ratio is
+ /// outside 1:6 to 6:1 is rejected — this endpoint never reshapes, so there
+ /// is no size to reshape it to. Unlike
+ /// `POST /v2/image/generate/ideogram-4-5`, this endpoint takes no `size`:
+ /// the output always matches the image being edited, so the edit drops
+ /// back into whatever it came from without reframing.
+ /// Supply the image to edit as an `image_asset_identifier` reference or as
+ /// raw `image` bytes (multipart requests only); if both are supplied, the
+ /// reference wins and the bytes are ignored. Add up to four more images
+ /// via `reference_image_asset_identifiers` or `reference_images` to guide
+ /// the edit — those are never edited themselves.
+ /// Supply a `mask` to confine the edit to part of the image being edited.
+ /// The mask is optional — without one the prompt is applied to the whole
+ /// image. Masks are read as an additional reference image, so a masked
+ /// request may carry at most three `reference_images`.
+ /// The `prompt` is the edit instruction. It accepts either natural
+ /// language or a structured JSON prompt; the server detects which was
+ /// supplied. A natural-language instruction is automatically rewritten
+ /// into the model's structured edit contract, while a prompt that is
+ /// already valid structured JSON is consumed directly.
+ /// By default the request blocks until the images are ready and returns
+ /// them in `data`. Set `async` to true to return immediately after the
+ /// request is accepted, then poll for completion and results with
+ /// `GET /v1/generations/{generation_id}` using the returned
+ /// `generation_id`.
+ /// Supplying a `webhook_url` makes the request asynchronous whatever
+ /// `async` says: the response returns as soon as the request is accepted,
+ /// and the finished result is POSTed to that URL. + ///
+ /// + /// Default Value: false + /// + /// + /// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering. + /// The token to cancel the operation with + /// + global::System.Threading.Tasks.Task PostPreciseEditImageV2Ideogram45Async( + + global::Ideogram.PreciseEditImageIdeogram45Request request, + bool? dryRun = default, + global::Ideogram.AutoSDKRequestOptions? requestOptions = default, + global::System.Threading.CancellationToken cancellationToken = default); + /// + /// Edit an image with Ideogram 4.5, keeping the source's exact geometry
+ /// Edit an image with Ideogram 4.5, returning output at that image's exact
+ /// width and height. An image too large for the model is scaled down to
+ /// fit while keeping its exact proportion, and one whose aspect ratio is
+ /// outside 1:6 to 6:1 is rejected — this endpoint never reshapes, so there
+ /// is no size to reshape it to. Unlike
+ /// `POST /v2/image/generate/ideogram-4-5`, this endpoint takes no `size`:
+ /// the output always matches the image being edited, so the edit drops
+ /// back into whatever it came from without reframing.
+ /// Supply the image to edit as an `image_asset_identifier` reference or as
+ /// raw `image` bytes (multipart requests only); if both are supplied, the
+ /// reference wins and the bytes are ignored. Add up to four more images
+ /// via `reference_image_asset_identifiers` or `reference_images` to guide
+ /// the edit — those are never edited themselves.
+ /// Supply a `mask` to confine the edit to part of the image being edited.
+ /// The mask is optional — without one the prompt is applied to the whole
+ /// image. Masks are read as an additional reference image, so a masked
+ /// request may carry at most three `reference_images`.
+ /// The `prompt` is the edit instruction. It accepts either natural
+ /// language or a structured JSON prompt; the server detects which was
+ /// supplied. A natural-language instruction is automatically rewritten
+ /// into the model's structured edit contract, while a prompt that is
+ /// already valid structured JSON is consumed directly.
+ /// By default the request blocks until the images are ready and returns
+ /// them in `data`. Set `async` to true to return immediately after the
+ /// request is accepted, then poll for completion and results with
+ /// `GET /v1/generations/{generation_id}` using the returned
+ /// `generation_id`.
+ /// Supplying a `webhook_url` makes the request asynchronous whatever
+ /// `async` says: the response returns as soon as the request is accepted,
+ /// and the finished result is POSTed to that URL. + ///
+ /// + /// Default Value: false + /// + /// + /// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering. + /// The token to cancel the operation with + /// + global::System.Threading.Tasks.Task> PostPreciseEditImageV2Ideogram45AsResponseAsync( + + global::Ideogram.PreciseEditImageIdeogram45Request request, + bool? dryRun = default, + global::Ideogram.AutoSDKRequestOptions? requestOptions = default, + global::System.Threading.CancellationToken cancellationToken = default); + /// + /// Edit an image with Ideogram 4.5, keeping the source's exact geometry
+ /// Edit an image with Ideogram 4.5, returning output at that image's exact
+ /// width and height. An image too large for the model is scaled down to
+ /// fit while keeping its exact proportion, and one whose aspect ratio is
+ /// outside 1:6 to 6:1 is rejected — this endpoint never reshapes, so there
+ /// is no size to reshape it to. Unlike
+ /// `POST /v2/image/generate/ideogram-4-5`, this endpoint takes no `size`:
+ /// the output always matches the image being edited, so the edit drops
+ /// back into whatever it came from without reframing.
+ /// Supply the image to edit as an `image_asset_identifier` reference or as
+ /// raw `image` bytes (multipart requests only); if both are supplied, the
+ /// reference wins and the bytes are ignored. Add up to four more images
+ /// via `reference_image_asset_identifiers` or `reference_images` to guide
+ /// the edit — those are never edited themselves.
+ /// Supply a `mask` to confine the edit to part of the image being edited.
+ /// The mask is optional — without one the prompt is applied to the whole
+ /// image. Masks are read as an additional reference image, so a masked
+ /// request may carry at most three `reference_images`.
+ /// The `prompt` is the edit instruction. It accepts either natural
+ /// language or a structured JSON prompt; the server detects which was
+ /// supplied. A natural-language instruction is automatically rewritten
+ /// into the model's structured edit contract, while a prompt that is
+ /// already valid structured JSON is consumed directly.
+ /// By default the request blocks until the images are ready and returns
+ /// them in `data`. Set `async` to true to return immediately after the
+ /// request is accepted, then poll for completion and results with
+ /// `GET /v1/generations/{generation_id}` using the returned
+ /// `generation_id`.
+ /// Supplying a `webhook_url` makes the request asynchronous whatever
+ /// `async` says: the response returns as soon as the request is accepted,
+ /// and the finished result is POSTed to that URL. + ///
+ /// + /// Default Value: false + /// + /// + /// The edit instruction to apply to the sources. Accepts either
+ /// natural language or a structured JSON prompt; the server detects
+ /// which was supplied. Natural language is automatically rewritten
+ /// into the model's structured edit contract, while structured JSON
+ /// is consumed directly. + /// + /// + /// The image to edit, as an existing upload or generated image asset. Supply this or `image`, never both. Takes priority over `image` if both are supplied. Cannot be combined with `mask`. + /// + /// + /// The image to edit, as raw bytes (max size 25MB; JPEG, PNG, or WEBP only). Multipart requests only; ignored if `image_asset_identifier` is also supplied. Required when supplying a `mask`. + /// + /// + /// The image to edit, as raw bytes (max size 25MB; JPEG, PNG, or WEBP only). Multipart requests only; ignored if `image_asset_identifier` is also supplied. Required when supplying a `mask`. + /// + /// + /// Optional additional images to guide the edit, by reference. These are never edited themselves; only `image_asset_identifier` or `image` is. Requires the image being edited to be supplied by reference too, and cannot be combined with `mask`. + /// + /// + /// Optional additional images to guide the edit (max 4, max size 25MB each), as raw bytes; only JPEG, PNG, and WEBP formats are supported. These are never edited themselves; only `image` is. Multipart requests only; ignored if `reference_image_asset_identifiers` is also supplied. A masked request may carry at most three, because the mask occupies one of the model's reference slots. + /// + /// + /// An optional mask confining the edit to part of `image`, as raw bytes (multipart requests only; JPEG, PNG, or WEBP, max 25MB). Black marks the area to edit and white the area to preserve; values in between are rounded to whichever is nearer. The mask must have the same width and height as `image`, and must contain both black and white areas. Requires the image being edited to be uploaded as raw `image` bytes in the same request; masks cannot be combined with asset references. The mask is supplied to the model as an additional reference image, so a masked request may carry at most three `reference_images`. + /// + /// + /// An optional mask confining the edit to part of `image`, as raw bytes (multipart requests only; JPEG, PNG, or WEBP, max 25MB). Black marks the area to edit and white the area to preserve; values in between are rounded to whichever is nearer. The mask must have the same width and height as `image`, and must contain both black and white areas. Requires the image being edited to be uploaded as raw `image` bytes in the same request; masks cannot be combined with asset references. The mask is supplied to the model as an additional reference image, so a masked request may carry at most three `reference_images`. + /// + /// + /// The rendering speed to use. `ultra` renders multiple candidate edits internally and returns the one that best applies the instruction; it takes longer than `quality`, is priced higher, and supports at most 4 images per request.
+ /// Default Value: default + /// + /// + /// Random seed. Set for reproducible generation.
+ /// Example: 12345 + /// + /// + /// The number of images to generate.
+ /// Default Value: 1 + /// + /// + /// Optional. Opt this request into post-generation copyright detection. Adds detection latency; flagged images come back with `is_image_safe: false`. + /// + /// + /// When false (the default), the request blocks until the images are ready and returns them in `data`. When true, the request returns as soon as it is accepted; poll for completion and results with `GET /v1/generations/{generation_id}` using the returned `generation_id`.
+ /// Default Value: false + /// + /// + /// HTTPS URL that Ideogram delivers the generated result to. Ideogram sends a
+ /// JSON POST to this URL once all images for the request have finished
+ /// generating. The body mirrors the synchronous generate response:
+ /// `request_id`, `created`, and a `data` array
+ /// containing every generated image (`url`, `prompt`, `resolution`, `seed`,
+ /// `is_image_safe`). Each delivery is signed with Ed25519 and verifiable
+ /// against the public keys at `https://api.ideogram.ai/v1/.well-known/jwks.json`. Must be HTTPS;
+ /// private and loopback hosts and the cloud metadata service are rejected.
+ /// Example: https://api.example.com/webhooks/ideogram + /// + /// + /// When true or omitted, the output is kept private to your account. Set to false to publish the output to the public feed. Enterprise accounts always generate privately. + /// + /// + /// A collection you can write to, by its URL-safe base64 collection id. The output images are added to it when the request completes. + /// + /// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering. + /// The token to cancel the operation with + /// + global::System.Threading.Tasks.Task PostPreciseEditImageV2Ideogram45Async( + string prompt, + bool? dryRun = default, + global::Ideogram.AssetIdentifier? imageAssetIdentifier = default, + byte[]? image = default, + string? imagename = default, + global::System.Collections.Generic.IList? referenceImageAssetIdentifiers = default, + global::System.Collections.Generic.IList? referenceImages = default, + byte[]? mask = default, + string? maskname = default, + global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeed? renderingSpeed = default, + int? seed = default, + int? numImages = default, + bool? enableCopyrightDetection = default, + bool? async = default, + string? webhookUrl = default, + bool? @private = default, + string? targetCollectionId = default, + global::Ideogram.AutoSDKRequestOptions? requestOptions = default, + global::System.Threading.CancellationToken cancellationToken = default); + } +} \ No newline at end of file diff --git a/src/libs/Ideogram/Generated/Ideogram.IImagesPreciseEditClient.g.cs b/src/libs/Ideogram/Generated/Ideogram.IImagesPreciseEditClient.g.cs new file mode 100644 index 0000000..ce67dbc --- /dev/null +++ b/src/libs/Ideogram/Generated/Ideogram.IImagesPreciseEditClient.g.cs @@ -0,0 +1,49 @@ + +#nullable enable + +namespace Ideogram +{ + /// + /// Edit source images at the source's own width and height. These endpoints never reframe: the output always matches the image you sent.
+ /// If no httpClient is provided, a new one will be created.
+ /// If no baseUri is provided, the default baseUri from OpenAPI spec will be used. + ///
+ public partial interface IImagesPreciseEditClient : global::System.IDisposable + { + /// + /// The HttpClient instance. + /// + public global::System.Net.Http.HttpClient HttpClient { get; } + + /// + /// The base URL for the API. + /// + public System.Uri? BaseUri { get; } + + /// + /// The authorizations to use for the requests. + /// + public global::System.Collections.Generic.List Authorizations { get; } + + /// + /// Gets or sets a value indicating whether the response content should be read as a string. + /// True by default in debug builds, false otherwise. + /// When false, successful responses are deserialized directly from the response stream for better performance. + /// Error responses are always read as strings regardless of this setting, + /// ensuring is populated. + /// + public bool ReadResponseAsString { get; set; } + /// + /// Client-wide request defaults such as headers, query parameters, retries, and timeout. + /// + public global::Ideogram.AutoSDKClientOptions Options { get; } + + + /// + /// + /// + global::System.Text.Json.Serialization.JsonSerializerContext JsonSerializerContext { get; set; } + + + } +} \ No newline at end of file diff --git a/src/libs/Ideogram/Generated/Ideogram.IdeogramClient.g.cs b/src/libs/Ideogram/Generated/Ideogram.IdeogramClient.g.cs index ca1e75b..3ccbea8 100644 --- a/src/libs/Ideogram/Generated/Ideogram.IdeogramClient.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.IdeogramClient.g.cs @@ -145,6 +145,15 @@ public sealed partial class IdeogramClient : global::Ideogram.IIdeogramClient, g JsonSerializerContextProvider = JsonSerializerContextProvider, }; + /// + /// Edit source images at the source's own width and height. These endpoints never reframe: the output always matches the image you sent. + /// + public ImagesPreciseEditClient ImagesPreciseEdit => new ImagesPreciseEditClient(HttpClient, baseUri: null, authorizations: Authorizations, options: Options) + { + ReadResponseAsString = ReadResponseAsString, + JsonSerializerContextProvider = JsonSerializerContextProvider, + }; + /// /// Expand an existing image to a new model-specific output shape while
/// preserving the source content and filling the new area. diff --git a/src/libs/Ideogram/Generated/Ideogram.ImagesGenerate.JsonSerializerContext.g.cs b/src/libs/Ideogram/Generated/Ideogram.ImagesGenerate.JsonSerializerContext.g.cs index 8557993..1ad3246 100644 --- a/src/libs/Ideogram/Generated/Ideogram.ImagesGenerate.JsonSerializerContext.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.ImagesGenerate.JsonSerializerContext.g.cs @@ -35,6 +35,7 @@ namespace Ideogram [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.IList))] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GeneratedImageObject))] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GenerateImageIdeogramV3Request))] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.IdeogramV3AspectRatio), TypeInfoPropertyName = "IdeogramV3AspectRatio2")] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GenerateImageIdeogramV3RequestRenderingSpeed), TypeInfoPropertyName = "GenerateImageIdeogramV3RequestRenderingSpeed2")] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.MagicPromptMode), TypeInfoPropertyName = "MagicPromptMode2")] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.IdeogramColorPalette), TypeInfoPropertyName = "IdeogramColorPalette2")] @@ -109,6 +110,7 @@ namespace Ideogram [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.AspectRatioV3?), TypeInfoPropertyName = "NullableAspectRatioV32")] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.ResolutionV3?), TypeInfoPropertyName = "NullableResolutionV32")] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GenerationRejectReason?), TypeInfoPropertyName = "NullableGenerationRejectReason2")] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.IdeogramV3AspectRatio?), TypeInfoPropertyName = "NullableIdeogramV3AspectRatio2")] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GenerateImageIdeogramV3RequestRenderingSpeed?), TypeInfoPropertyName = "NullableGenerateImageIdeogramV3RequestRenderingSpeed2")] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.MagicPromptMode?), TypeInfoPropertyName = "NullableMagicPromptMode2")] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.IdeogramColorPalette?), TypeInfoPropertyName = "NullableIdeogramColorPalette2")] @@ -312,6 +314,10 @@ public override bool CanConvert(global::System.Type typeToConvert) || typeToConvert == typeof(global::Ideogram.AssetType?) + || typeToConvert == typeof(global::Ideogram.IdeogramV3AspectRatio) + + || typeToConvert == typeof(global::Ideogram.IdeogramV3AspectRatio?) + || typeToConvert == typeof(global::Ideogram.MagicPromptMode) || typeToConvert == typeof(global::Ideogram.MagicPromptMode?) @@ -595,6 +601,16 @@ public override bool CanConvert(global::System.Type typeToConvert) return new global::Ideogram.JsonConverters.AssetTypeNullableJsonConverter(); } + if (typeToConvert == typeof(global::Ideogram.IdeogramV3AspectRatio)) + { + return new global::Ideogram.JsonConverters.IdeogramV3AspectRatioJsonConverter(); + } + + if (typeToConvert == typeof(global::Ideogram.IdeogramV3AspectRatio?)) + { + return new global::Ideogram.JsonConverters.IdeogramV3AspectRatioNullableJsonConverter(); + } + if (typeToConvert == typeof(global::Ideogram.MagicPromptMode)) { return new global::Ideogram.JsonConverters.MagicPromptModeJsonConverter(); diff --git a/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2Ideogram45.g.cs b/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2Ideogram45.g.cs index 4bceddd..f715c64 100644 --- a/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2Ideogram45.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2Ideogram45.g.cs @@ -206,14 +206,10 @@ partial void ProcessPostGenerateImageV2Ideogram45ResponseContent( } var __httpRequestContent = new global::System.Net.Http.MultipartFormDataContent(); - if (request.Prompt != default) - { - - __httpRequestContent.Add( - content: new global::System.Net.Http.StringContent(request.Prompt ?? string.Empty), - name: "\"prompt\""); + __httpRequestContent.Add( + content: new global::System.Net.Http.StringContent(request.Prompt ?? string.Empty), + name: "\"prompt\""); - } if (request.MagicPrompt != default) { @@ -247,6 +243,48 @@ partial void ProcessPostGenerateImageV2Ideogram45ResponseContent( } } + } + if (request.Mask != default) + { + + var __contentMask = new global::System.Net.Http.ByteArrayContent(request.Mask ?? global::System.Array.Empty()); + __contentMask.Headers.ContentType = new global::System.Net.Http.Headers.MediaTypeHeaderValue( + request.Maskname is null + ? "application/octet-stream" + : (global::System.IO.Path.GetExtension(request.Maskname) ?? string.Empty).ToLowerInvariant() switch + { + ".aac" => "audio/aac", + ".flac" => "audio/flac", + ".gif" => "image/gif", + ".jpeg" => "image/jpeg", + ".jpg" => "image/jpeg", + ".json" => "application/json", + ".m4a" => "audio/mp4", + ".mp3" => "audio/mpeg", + ".mp4" => "video/mp4", + ".mpeg" => "audio/mpeg", + ".mpga" => "audio/mpeg", + ".oga" => "audio/ogg", + ".ogg" => "audio/ogg", + ".opus" => "audio/ogg", + ".pdf" => "application/pdf", + ".png" => "image/png", + ".txt" => "text/plain", + ".wav" => "audio/wav", + ".weba" => "audio/webm", + ".webm" => "video/webm", + ".webp" => "image/webp", + _ => "application/octet-stream", + }); + __httpRequestContent.Add( + content: __contentMask, + name: "\"mask\"", + fileName: request.Maskname != null ? $"\"{request.Maskname}\"" : string.Empty); + if (__contentMask.Headers.ContentDisposition != null) + { + __contentMask.Headers.ContentDisposition.FileNameStar = null; + } + } if (request.Size != default) { @@ -876,17 +914,20 @@ partial void ProcessPostGenerateImageV2Ideogram45ResponseContent( /// Default Value: false /// /// - /// The prompt to generate images from. Accepts either natural
+ /// The prompt to generate images from, or the edit instruction to
+ /// apply when source images are supplied. Accepts either natural
/// language or a structured Ideogram 4.0 JSON prompt; the server
- /// detects which was supplied. Required without source images; with
- /// sources it is optional guidance and may be empty. + /// detects which was supplied. /// /// - /// Controls magic prompt (automatic prompt rewriting). `auto` (the
- /// default) and `on` rewrite a natural-language prompt, while a
- /// prompt that is already a valid structured JSON prompt is always
- /// consumed directly. `off` disables rewriting entirely: the model
- /// receives your prompt verbatim.
+ /// Controls how a natural-language prompt is prepared. `auto` (the
+ /// default) and `on` rewrite and expand the prompt before
+ /// generation. `off` keeps your wording and only converts the prompt
+ /// into the structured format the model consumes. A prompt that is
+ /// already a valid structured JSON prompt skips magic prompt
+ /// entirely unless `magic_prompt` is `on`. With source images the
+ /// prompt is an edit instruction, and every mode converts it into
+ /// the structured edit contract the model consumes.
/// Default Value: auto /// /// @@ -895,17 +936,27 @@ partial void ProcessPostGenerateImageV2Ideogram45ResponseContent( /// /// The source images to transform (max 5, max size 25MB per image), as raw bytes; only JPEG, PNG, and WEBP formats are supported. Multipart requests only; ignored if `image_asset_identifiers` is also supplied. /// + /// + /// An optional mask confining the edit to part of the first source image, as raw bytes (multipart requests only; JPEG, PNG, or WEBP, max 25MB). Black marks the area to edit and white the area to preserve; values in between are rounded to whichever is nearer. The mask must have the same width and height as the first source image, and must contain both black and white areas. Requires source images uploaded as raw `images` bytes; masks cannot be combined with `image_asset_identifiers`. The mask is supplied to the model as an additional reference image, so a masked request may carry at most three other source images. Supplying a mask fixes the output to the first source's own size, so `size` is rejected alongside it. + /// + /// + /// An optional mask confining the edit to part of the first source image, as raw bytes (multipart requests only; JPEG, PNG, or WEBP, max 25MB). Black marks the area to edit and white the area to preserve; values in between are rounded to whichever is nearer. The mask must have the same width and height as the first source image, and must contain both black and white areas. Requires source images uploaded as raw `images` bytes; masks cannot be combined with `image_asset_identifiers`. The mask is supplied to the model as an additional reference image, so a masked request may carry at most three other source images. Supplying a mask fixes the output to the first source's own size, so `size` is rejected alongside it. + /// /// /// The output size: "auto" or an exact "WIDTHxHEIGHT".
/// Without source images, an exact size must be one of the supported
/// 1K/2K presets (for example 1024x1024, 2048x2048 or 1440x2880);
/// "auto" or omitted lets the server pick a supported size based on
/// the prompt.
- /// With source images, "auto" (the default) uses the supported
- /// resolution closest to the first source's dimensions, and an exact
- /// size must have both dimensions multiples of 32 and at least 256px,
- /// the total size at most 2048x2048 pixels, and the aspect ratio at
- /// most 6:1.
+ /// With source images, "auto" (the default) returns the output at the
+ /// first source image's own width and height. A source too large for
+ /// the model is scaled down to fit while keeping its exact proportion,
+ /// and a source whose aspect ratio is outside 1:6 to 6:1 is rejected,
+ /// because serving it would mean reshaping an image you did not ask to
+ /// reshape — name an exact size if that is what you want.
+ /// An exact size must have both dimensions multiples of 32 and at least
+ /// 256px, the total size at most 2048x2048 pixels, and the aspect ratio
+ /// at most 6:1. Naming one reshapes the source to it.
/// Pricing is tiered by the resolved output pixels: up to 1024x1024
/// bills as 1K, above that as 2K.
/// Example: 2048x2048 @@ -950,11 +1001,13 @@ partial void ProcessPostGenerateImageV2Ideogram45ResponseContent( /// The token to cancel the operation with /// public async global::System.Threading.Tasks.Task PostGenerateImageV2Ideogram45Async( + string prompt, bool? dryRun = default, - string? prompt = default, global::Ideogram.MagicPromptMode? magicPrompt = default, global::System.Collections.Generic.IList? imageAssetIdentifiers = default, global::System.Collections.Generic.IList? images = default, + byte[]? mask = default, + string? maskname = default, string? size = default, global::Ideogram.GenerateImageIdeogram45RequestRenderingSpeed? renderingSpeed = default, int? seed = default, @@ -973,6 +1026,8 @@ partial void ProcessPostGenerateImageV2Ideogram45ResponseContent( MagicPrompt = magicPrompt, ImageAssetIdentifiers = imageAssetIdentifiers, Images = images, + Mask = mask, + Maskname = maskname, Size = size, RenderingSpeed = renderingSpeed, Seed = seed, diff --git a/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2IdeogramV2.g.cs b/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2IdeogramV2.g.cs index c9306ee..a6f395b 100644 --- a/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2IdeogramV2.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2IdeogramV2.g.cs @@ -731,7 +731,10 @@ partial void ProcessPostGenerateImageV2IdeogramV2ResponseContent( /// Example: 12345 /// /// - /// The aspect ratio to use for image generation, which determines the image's resolution. Cannot be used in conjunction with resolution. Defaults to 1x1. + /// The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the
+ /// model select a ratio from the prompt; any other value pins the ratio.
+ /// Cannot be combined with `resolution`. Omitting the field is not `auto`:
+ /// it uses `1x1`. /// /// /// The rendering speed to use. `turbo` generates faster at a lower cost, while `quality` prioritizes the highest-quality result.
@@ -781,7 +784,7 @@ partial void ProcessPostGenerateImageV2IdeogramV2ResponseContent( bool? dryRun = default, string? negativePrompt = default, int? seed = default, - global::Ideogram.AspectRatioV3? aspectRatio = default, + global::Ideogram.IdeogramV3AspectRatio? aspectRatio = default, global::Ideogram.GenerateImageIdeogramV2RequestRenderingSpeed? renderingSpeed = default, global::Ideogram.MagicPromptMode? magicPrompt = default, int? numImages = default, diff --git a/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2IdeogramV2A.g.cs b/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2IdeogramV2A.g.cs index cf85bf5..3af959b 100644 --- a/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2IdeogramV2A.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2IdeogramV2A.g.cs @@ -728,7 +728,10 @@ partial void ProcessPostGenerateImageV2IdeogramV2AResponseContent( /// Example: 12345 /// /// - /// The aspect ratio to use for image generation, which determines the image's resolution. Cannot be used in conjunction with resolution. Defaults to 1x1. + /// The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the
+ /// model select a ratio from the prompt; any other value pins the ratio.
+ /// Cannot be combined with `resolution`. Omitting the field is not `auto`:
+ /// it uses `1x1`. /// /// /// The rendering speed to use. `turbo` generates faster at a lower cost, while `quality` prioritizes the highest-quality result.
@@ -777,7 +780,7 @@ partial void ProcessPostGenerateImageV2IdeogramV2AResponseContent( string prompt, bool? dryRun = default, int? seed = default, - global::Ideogram.AspectRatioV3? aspectRatio = default, + global::Ideogram.IdeogramV3AspectRatio? aspectRatio = default, global::Ideogram.GenerateImageIdeogramV2ARequestRenderingSpeed? renderingSpeed = default, global::Ideogram.MagicPromptMode? magicPrompt = default, int? numImages = default, diff --git a/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2IdeogramV3.g.cs b/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2IdeogramV3.g.cs index 98362f0..d63f548 100644 --- a/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2IdeogramV3.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2IdeogramV3.g.cs @@ -952,7 +952,10 @@ partial void ProcessPostGenerateImageV2IdeogramV3ResponseContent( /// Example: 1280x800 /// /// - /// The aspect ratio to use for image generation, which determines the image's resolution. Cannot be used in conjunction with resolution. Defaults to 1x1. + /// The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the
+ /// model select a ratio from the prompt; any other value pins the ratio.
+ /// Cannot be combined with `resolution`. Omitting the field is not `auto`:
+ /// it uses `1x1`. /// /// /// The rendering speed to use.
@@ -1026,7 +1029,7 @@ partial void ProcessPostGenerateImageV2IdeogramV3ResponseContent( string? negativePrompt = default, int? seed = default, global::Ideogram.ResolutionV3? resolution = default, - global::Ideogram.AspectRatioV3? aspectRatio = default, + global::Ideogram.IdeogramV3AspectRatio? aspectRatio = default, global::Ideogram.GenerateImageIdeogramV3RequestRenderingSpeed? renderingSpeed = default, global::Ideogram.MagicPromptMode? magicPrompt = default, int? numImages = default, diff --git a/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2IdeogramV3Character.g.cs b/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2IdeogramV3Character.g.cs index b7c9eb8..c97af9f 100644 --- a/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2IdeogramV3Character.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2IdeogramV3Character.g.cs @@ -1054,7 +1054,10 @@ request.CharacterReferenceMaskname is null /// Example: 1280x800 /// /// - /// The aspect ratio to use for image generation, which determines the image's resolution. Cannot be used in conjunction with resolution. Defaults to 1x1. + /// The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the
+ /// model select a ratio from the prompt; any other value pins the ratio.
+ /// Cannot be combined with `resolution`. Omitting the field is not `auto`:
+ /// it uses `1x1`. /// /// /// The rendering speed to use.
@@ -1123,7 +1126,7 @@ request.CharacterReferenceMaskname is null string? characterReferenceMaskname = default, int? seed = default, global::Ideogram.ResolutionV3? resolution = default, - global::Ideogram.AspectRatioV3? aspectRatio = default, + global::Ideogram.IdeogramV3AspectRatio? aspectRatio = default, global::Ideogram.GenerateImageIdeogramV3CharacterRequestRenderingSpeed? renderingSpeed = default, global::Ideogram.MagicPromptMode? magicPrompt = default, int? numImages = default, diff --git a/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2IdeogramV3CustomModel.g.cs b/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2IdeogramV3CustomModel.g.cs index 8f7dd94..3c7ee4a 100644 --- a/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2IdeogramV3CustomModel.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2IdeogramV3CustomModel.g.cs @@ -959,7 +959,10 @@ partial void ProcessPostGenerateImageV2IdeogramV3CustomModelResponseContent( /// Example: 1280x800 /// /// - /// The aspect ratio to use for image generation, which determines the image's resolution. Cannot be used in conjunction with resolution. Defaults to 1x1. + /// The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the
+ /// model select a ratio from the prompt; any other value pins the ratio.
+ /// Cannot be combined with `resolution`. Omitting the field is not `auto`:
+ /// it uses `1x1`. /// /// /// The rendering speed to use. When omitted, the server chooses a speed supported by the selected custom model. @@ -1022,7 +1025,7 @@ partial void ProcessPostGenerateImageV2IdeogramV3CustomModelResponseContent( string? negativePrompt = default, int? seed = default, global::Ideogram.ResolutionV3? resolution = default, - global::Ideogram.AspectRatioV3? aspectRatio = default, + global::Ideogram.IdeogramV3AspectRatio? aspectRatio = default, global::Ideogram.GenerateImageIdeogramV3CustomModelRequestRenderingSpeed? renderingSpeed = default, global::Ideogram.MagicPromptMode? magicPrompt = default, int? numImages = default, diff --git a/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2IdeogramV3Transparent.g.cs b/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2IdeogramV3Transparent.g.cs index ee7aa51..2aedd28 100644 --- a/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2IdeogramV3Transparent.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.ImagesGenerateClient.PostGenerateImageV2IdeogramV3Transparent.g.cs @@ -735,7 +735,10 @@ partial void ProcessPostGenerateImageV2IdeogramV3TransparentResponseContent( /// Default Value: x1 /// /// - /// The aspect ratio to use for image generation, which determines the image's resolution. Cannot be used in conjunction with resolution. Defaults to 1x1. + /// The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the
+ /// model select a ratio from the prompt; any other value pins the ratio.
+ /// Cannot be combined with `resolution`. Omitting the field is not `auto`:
+ /// it uses `1x1`. /// /// /// The rendering speed to use.
@@ -782,7 +785,7 @@ partial void ProcessPostGenerateImageV2IdeogramV3TransparentResponseContent( string? negativePrompt = default, int? seed = default, global::Ideogram.GenerateImageIdeogramV3TransparentRequestUpscaleFactor? upscaleFactor = default, - global::Ideogram.AspectRatioV3? aspectRatio = default, + global::Ideogram.IdeogramV3AspectRatio? aspectRatio = default, global::Ideogram.GenerateImageIdeogramV3TransparentRequestRenderingSpeed? renderingSpeed = default, global::Ideogram.MagicPromptMode? magicPrompt = default, int? numImages = default, diff --git a/src/libs/Ideogram/Generated/Ideogram.ImagesPreciseEdit.JsonSerializerContext.g.cs b/src/libs/Ideogram/Generated/Ideogram.ImagesPreciseEdit.JsonSerializerContext.g.cs new file mode 100644 index 0000000..48849cb --- /dev/null +++ b/src/libs/Ideogram/Generated/Ideogram.ImagesPreciseEdit.JsonSerializerContext.g.cs @@ -0,0 +1,205 @@ + +#nullable enable + +#pragma warning disable CS0618 // Type or member is obsolete +#pragma warning disable CS3016 // Arrays as attribute arguments is not CLS-compliant + +namespace Ideogram +{ + /// + /// + /// + [global::System.Text.Json.Serialization.JsonSourceGenerationOptions( + DefaultIgnoreCondition = global::System.Text.Json.Serialization.JsonIgnoreCondition.WhenWritingNull, + Converters = new global::System.Type[] + { + })] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.Dictionary))] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.Dictionary))] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.List), TypeInfoPropertyName = "SystemCollectionsGeneric_ObjectList")] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Text.Json.JsonElement?))] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(string))] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(int))] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(bool))] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(byte[]))] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.IList))] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GenerationErrorResponse))] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GenerationRejectReason), TypeInfoPropertyName = "GenerationRejectReason2")] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.AssetIdentifier))] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.IList))] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.IList))] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GeneratedImageObject))] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.PreciseEditImageIdeogram45Response))] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.PreciseEditImageIdeogram45Request))] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeed), TypeInfoPropertyName = "PreciseEditImageIdeogram45RequestRenderingSpeed2")] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.AssetType), TypeInfoPropertyName = "AssetType2")] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(int?))] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(bool?))] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GenerationRejectReason?), TypeInfoPropertyName = "NullableGenerationRejectReason2")] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeed?), TypeInfoPropertyName = "NullablePreciseEditImageIdeogram45RequestRenderingSpeed2")] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.AssetType?), TypeInfoPropertyName = "NullableAssetType2")] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.List))] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.List))] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.List))] + internal sealed partial class ImagesPreciseEditSourceGenerationContextChunk0 : global::System.Text.Json.Serialization.JsonSerializerContext + { + } + /// + /// + /// + public sealed partial class ImagesPreciseEditSourceGenerationContext : global::System.Text.Json.Serialization.JsonSerializerContext + { + private static readonly global::System.Text.Json.Serialization.Metadata.IJsonTypeInfoResolver Resolver = new LazyChunkResolver(); + + + private static readonly global::System.Text.Json.JsonSerializerOptions DefaultOptions = CreateDefaultOptions(); + + /// + /// + /// + public static ImagesPreciseEditSourceGenerationContext Default { get; } = new(DefaultOptions); + + private ImagesPreciseEditSourceGenerationContext(global::System.Text.Json.JsonSerializerOptions options) + : base(options) + { + } + + /// + protected override global::System.Text.Json.JsonSerializerOptions? GeneratedSerializerOptions => DefaultOptions; + + /// + public override global::System.Text.Json.Serialization.Metadata.JsonTypeInfo? GetTypeInfo(global::System.Type type) + { + return Resolver.GetTypeInfo(type, Options); + } + + /// + /// Adds this package's converters to . + /// + /// + /// A converter has to be on the options a chained resolver builds its JsonTypeInfo against, + /// and a context resolves types from every package below it. Each package contributes only + /// what it owns and calls down the chain for the rest, so the family's converter table is + /// written once rather than copied into all of them. + /// + [global::System.ComponentModel.EditorBrowsable(global::System.ComponentModel.EditorBrowsableState.Never)] + public static void AddConverters(global::System.Text.Json.JsonSerializerOptions options) + { + options.Converters.Add(new global::Ideogram.JsonConverters.UnixTimestampJsonConverter()); + options.Converters.Add(new LazyEnumJsonConverterFactory()); + } + + private static global::System.Text.Json.JsonSerializerOptions CreateDefaultOptions() + { + var options = new global::System.Text.Json.JsonSerializerOptions + { + DefaultIgnoreCondition = global::System.Text.Json.Serialization.JsonIgnoreCondition.WhenWritingNull, + TypeInfoResolver = Resolver, + }; + AddConverters(options); + + return options; + } + + + private sealed class LazyEnumJsonConverterFactory : global::System.Text.Json.Serialization.JsonConverterFactory + { + public override bool CanConvert(global::System.Type typeToConvert) + { + return + typeToConvert == typeof(global::Ideogram.GenerationRejectReason) + + || typeToConvert == typeof(global::Ideogram.GenerationRejectReason?) + + || typeToConvert == typeof(global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeed) + + || typeToConvert == typeof(global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeed?) + + || typeToConvert == typeof(global::Ideogram.AssetType) + + || typeToConvert == typeof(global::Ideogram.AssetType?); + } + + public override global::System.Text.Json.Serialization.JsonConverter CreateConverter( + global::System.Type typeToConvert, + global::System.Text.Json.JsonSerializerOptions options) + { + if (typeToConvert == typeof(global::Ideogram.GenerationRejectReason)) + { + return new global::Ideogram.JsonConverters.GenerationRejectReasonJsonConverter(); + } + + if (typeToConvert == typeof(global::Ideogram.GenerationRejectReason?)) + { + return new global::Ideogram.JsonConverters.GenerationRejectReasonNullableJsonConverter(); + } + + if (typeToConvert == typeof(global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeed)) + { + return new global::Ideogram.JsonConverters.PreciseEditImageIdeogram45RequestRenderingSpeedJsonConverter(); + } + + if (typeToConvert == typeof(global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeed?)) + { + return new global::Ideogram.JsonConverters.PreciseEditImageIdeogram45RequestRenderingSpeedNullableJsonConverter(); + } + + if (typeToConvert == typeof(global::Ideogram.AssetType)) + { + return new global::Ideogram.JsonConverters.AssetTypeJsonConverter(); + } + + if (typeToConvert == typeof(global::Ideogram.AssetType?)) + { + return new global::Ideogram.JsonConverters.AssetTypeNullableJsonConverter(); + } + throw new global::System.NotSupportedException($"No generated enum converter is registered for '{typeToConvert}'."); + } + } + + private sealed class LazyChunkResolver : global::System.Text.Json.Serialization.Metadata.IJsonTypeInfoResolver + { + private readonly object _gate = new(); + private readonly global::System.Text.Json.Serialization.Metadata.IJsonTypeInfoResolver?[] _resolvers = new global::System.Text.Json.Serialization.Metadata.IJsonTypeInfoResolver?[1]; + + public global::System.Text.Json.Serialization.Metadata.JsonTypeInfo? GetTypeInfo( + global::System.Type type, + global::System.Text.Json.JsonSerializerOptions options) + { + for (var index = 0; index < _resolvers.Length; index++) + { + var typeInfo = GetResolver(index).GetTypeInfo(type, options); + if (typeInfo is not null) + { + return typeInfo; + } + } + + return null; + } + + private global::System.Text.Json.Serialization.Metadata.IJsonTypeInfoResolver GetResolver(int index) + { + var resolver = global::System.Threading.Volatile.Read(ref _resolvers[index]); + if (resolver is not null) + { + return resolver; + } + + lock (_gate) + { + return _resolvers[index] ??= CreateResolver(index); + } + } + + private static global::System.Text.Json.Serialization.Metadata.IJsonTypeInfoResolver CreateResolver(int index) + { + return index switch + { + 0 => new ImagesPreciseEditSourceGenerationContextChunk0(new global::System.Text.Json.JsonSerializerOptions()), + _ => throw new global::System.ArgumentOutOfRangeException(nameof(index)), + }; + } + } + } +} \ No newline at end of file diff --git a/src/libs/Ideogram/Generated/Ideogram.ImagesPreciseEditClient.Authorizations.Bearer.g.cs b/src/libs/Ideogram/Generated/Ideogram.ImagesPreciseEditClient.Authorizations.Bearer.g.cs new file mode 100644 index 0000000..d72d9fe --- /dev/null +++ b/src/libs/Ideogram/Generated/Ideogram.ImagesPreciseEditClient.Authorizations.Bearer.g.cs @@ -0,0 +1,35 @@ + +#nullable enable + +namespace Ideogram +{ + public sealed partial class ImagesPreciseEditClient + { + + /// + public void AuthorizeUsingBearer( + string apiKey) + { + apiKey = apiKey ?? throw new global::System.ArgumentNullException(nameof(apiKey)); + + for (var i = Authorizations.Count - 1; i >= 0; i--) + { + var __authorization = Authorizations[i]; + if (__authorization.Type == "Http" && + __authorization.Name == "Bearer") + { + Authorizations.RemoveAt(i); + } + } + + Authorizations.Add(new global::Ideogram.EndPointAuthorization + { + Type = "Http", + SchemeId = "HttpBearer", + Location = "Header", + Name = "Bearer", + Value = apiKey, + }); + } + } +} \ No newline at end of file diff --git a/src/libs/Ideogram/Generated/Ideogram.ImagesPreciseEditClient.Constructors.Bearer.g.cs b/src/libs/Ideogram/Generated/Ideogram.ImagesPreciseEditClient.Constructors.Bearer.g.cs new file mode 100644 index 0000000..7072222 --- /dev/null +++ b/src/libs/Ideogram/Generated/Ideogram.ImagesPreciseEditClient.Constructors.Bearer.g.cs @@ -0,0 +1,31 @@ + +#nullable enable + +namespace Ideogram +{ + public sealed partial class ImagesPreciseEditClient + { + /// + + public ImagesPreciseEditClient( + string apiKey, + global::System.Net.Http.HttpClient? httpClient = null, + global::System.Uri? baseUri = null, + global::System.Collections.Generic.List? authorizations = null, + bool disposeHttpClient = true) : this(httpClient, baseUri, authorizations, disposeHttpClient) + { + Authorizing(HttpClient, ref apiKey); + + AuthorizeUsingBearer(apiKey); + + Authorized(HttpClient); + } + + partial void Authorizing( + global::System.Net.Http.HttpClient client, + ref string apiKey); + partial void Authorized( + global::System.Net.Http.HttpClient client); + + } +} \ No newline at end of file diff --git a/src/libs/Ideogram/Generated/Ideogram.ImagesPreciseEditClient.PostPreciseEditImageV2Ideogram45.g.cs b/src/libs/Ideogram/Generated/Ideogram.ImagesPreciseEditClient.PostPreciseEditImageV2Ideogram45.g.cs new file mode 100644 index 0000000..9c8dceb --- /dev/null +++ b/src/libs/Ideogram/Generated/Ideogram.ImagesPreciseEditClient.PostPreciseEditImageV2Ideogram45.g.cs @@ -0,0 +1,1080 @@ + +#nullable enable + +namespace Ideogram +{ + public partial class ImagesPreciseEditClient + { + + + private static readonly global::Ideogram.EndPointSecurityRequirement s_PostPreciseEditImageV2Ideogram45SecurityRequirement0 = + new global::Ideogram.EndPointSecurityRequirement + { + Authorizations = new global::Ideogram.EndPointAuthorizationRequirement[] + { new global::Ideogram.EndPointAuthorizationRequirement + { + Type = "Http", + SchemeId = "HttpBearer", + Location = "Header", + Name = "Bearer", + FriendlyName = "Bearer", + }, + }, + }; + private static readonly global::Ideogram.EndPointSecurityRequirement[] s_PostPreciseEditImageV2Ideogram45SecurityRequirements = + new global::Ideogram.EndPointSecurityRequirement[] + { s_PostPreciseEditImageV2Ideogram45SecurityRequirement0, + }; + partial void PreparePostPreciseEditImageV2Ideogram45Arguments( + global::System.Net.Http.HttpClient httpClient, + ref bool? dryRun, + global::Ideogram.PreciseEditImageIdeogram45Request request); + partial void PreparePostPreciseEditImageV2Ideogram45Request( + global::System.Net.Http.HttpClient httpClient, + global::System.Net.Http.HttpRequestMessage httpRequestMessage, + bool? dryRun, + global::Ideogram.PreciseEditImageIdeogram45Request request); + partial void ProcessPostPreciseEditImageV2Ideogram45Response( + global::System.Net.Http.HttpClient httpClient, + global::System.Net.Http.HttpResponseMessage httpResponseMessage); + + partial void ProcessPostPreciseEditImageV2Ideogram45ResponseContent( + global::System.Net.Http.HttpClient httpClient, + global::System.Net.Http.HttpResponseMessage httpResponseMessage, + ref string content); + + /// + /// Edit an image with Ideogram 4.5, keeping the source's exact geometry
+ /// Edit an image with Ideogram 4.5, returning output at that image's exact
+ /// width and height. An image too large for the model is scaled down to
+ /// fit while keeping its exact proportion, and one whose aspect ratio is
+ /// outside 1:6 to 6:1 is rejected — this endpoint never reshapes, so there
+ /// is no size to reshape it to. Unlike
+ /// `POST /v2/image/generate/ideogram-4-5`, this endpoint takes no `size`:
+ /// the output always matches the image being edited, so the edit drops
+ /// back into whatever it came from without reframing.
+ /// Supply the image to edit as an `image_asset_identifier` reference or as
+ /// raw `image` bytes (multipart requests only); if both are supplied, the
+ /// reference wins and the bytes are ignored. Add up to four more images
+ /// via `reference_image_asset_identifiers` or `reference_images` to guide
+ /// the edit — those are never edited themselves.
+ /// Supply a `mask` to confine the edit to part of the image being edited.
+ /// The mask is optional — without one the prompt is applied to the whole
+ /// image. Masks are read as an additional reference image, so a masked
+ /// request may carry at most three `reference_images`.
+ /// The `prompt` is the edit instruction. It accepts either natural
+ /// language or a structured JSON prompt; the server detects which was
+ /// supplied. A natural-language instruction is automatically rewritten
+ /// into the model's structured edit contract, while a prompt that is
+ /// already valid structured JSON is consumed directly.
+ /// By default the request blocks until the images are ready and returns
+ /// them in `data`. Set `async` to true to return immediately after the
+ /// request is accepted, then poll for completion and results with
+ /// `GET /v1/generations/{generation_id}` using the returned
+ /// `generation_id`.
+ /// Supplying a `webhook_url` makes the request asynchronous whatever
+ /// `async` says: the response returns as soon as the request is accepted,
+ /// and the finished result is POSTed to that URL. + ///
+ /// + /// Default Value: false + /// + /// + /// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering. + /// The token to cancel the operation with + /// + public async global::System.Threading.Tasks.Task PostPreciseEditImageV2Ideogram45Async( + + global::Ideogram.PreciseEditImageIdeogram45Request request, + bool? dryRun = default, + global::Ideogram.AutoSDKRequestOptions? requestOptions = default, + global::System.Threading.CancellationToken cancellationToken = default) + { + var __response = await PostPreciseEditImageV2Ideogram45AsResponseAsync( + + request: request, + dryRun: dryRun, + requestOptions: requestOptions, + cancellationToken: cancellationToken + ).ConfigureAwait(false); + + return __response.Body; + } + /// + /// Edit an image with Ideogram 4.5, keeping the source's exact geometry
+ /// Edit an image with Ideogram 4.5, returning output at that image's exact
+ /// width and height. An image too large for the model is scaled down to
+ /// fit while keeping its exact proportion, and one whose aspect ratio is
+ /// outside 1:6 to 6:1 is rejected — this endpoint never reshapes, so there
+ /// is no size to reshape it to. Unlike
+ /// `POST /v2/image/generate/ideogram-4-5`, this endpoint takes no `size`:
+ /// the output always matches the image being edited, so the edit drops
+ /// back into whatever it came from without reframing.
+ /// Supply the image to edit as an `image_asset_identifier` reference or as
+ /// raw `image` bytes (multipart requests only); if both are supplied, the
+ /// reference wins and the bytes are ignored. Add up to four more images
+ /// via `reference_image_asset_identifiers` or `reference_images` to guide
+ /// the edit — those are never edited themselves.
+ /// Supply a `mask` to confine the edit to part of the image being edited.
+ /// The mask is optional — without one the prompt is applied to the whole
+ /// image. Masks are read as an additional reference image, so a masked
+ /// request may carry at most three `reference_images`.
+ /// The `prompt` is the edit instruction. It accepts either natural
+ /// language or a structured JSON prompt; the server detects which was
+ /// supplied. A natural-language instruction is automatically rewritten
+ /// into the model's structured edit contract, while a prompt that is
+ /// already valid structured JSON is consumed directly.
+ /// By default the request blocks until the images are ready and returns
+ /// them in `data`. Set `async` to true to return immediately after the
+ /// request is accepted, then poll for completion and results with
+ /// `GET /v1/generations/{generation_id}` using the returned
+ /// `generation_id`.
+ /// Supplying a `webhook_url` makes the request asynchronous whatever
+ /// `async` says: the response returns as soon as the request is accepted,
+ /// and the finished result is POSTed to that URL. + ///
+ /// + /// Default Value: false + /// + /// + /// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering. + /// The token to cancel the operation with + /// + public async global::System.Threading.Tasks.Task> PostPreciseEditImageV2Ideogram45AsResponseAsync( + + global::Ideogram.PreciseEditImageIdeogram45Request request, + bool? dryRun = default, + global::Ideogram.AutoSDKRequestOptions? requestOptions = default, + global::System.Threading.CancellationToken cancellationToken = default) + { + request = request ?? throw new global::System.ArgumentNullException(nameof(request)); + + PrepareArguments( + client: HttpClient); + PreparePostPreciseEditImageV2Ideogram45Arguments( + httpClient: HttpClient, + dryRun: ref dryRun, + request: request); + + + var __authorizations = global::Ideogram.EndPointSecurityResolver.ResolveAuthorizations( + availableAuthorizations: Authorizations, + securityRequirements: s_PostPreciseEditImageV2Ideogram45SecurityRequirements, + operationName: "PostPreciseEditImageV2Ideogram45Async"); + + using var __timeoutCancellationTokenSource = global::Ideogram.AutoSDKRequestOptionsSupport.CreateTimeoutCancellationTokenSource( + clientOptions: Options, + requestOptions: requestOptions, + cancellationToken: cancellationToken); + var __effectiveCancellationToken = __timeoutCancellationTokenSource?.Token ?? cancellationToken; + var __effectiveReadResponseAsString = global::Ideogram.AutoSDKRequestOptionsSupport.GetReadResponseAsString( + clientOptions: Options, + requestOptions: requestOptions, + fallbackValue: ReadResponseAsString); + var __maxAttempts = global::Ideogram.AutoSDKRequestOptionsSupport.GetMaxAttempts( + clientOptions: Options, + requestOptions: requestOptions, + supportsRetry: false); + + global::System.Net.Http.HttpRequestMessage __CreateHttpRequest() + { + + var __pathBuilder = new global::Ideogram.PathBuilder( + path: "/v2/image/precise-edit/ideogram-4-5", + baseUri: HttpClient.BaseAddress); + __pathBuilder + .AddOptionalParameter("dry_run", dryRun?.ToString().ToLowerInvariant()) + ; + var __path = __pathBuilder.ToString(); + __path = global::Ideogram.AutoSDKRequestOptionsSupport.AppendQueryParameters( + path: __path, + clientParameters: Options.QueryParameters, + requestParameters: requestOptions?.QueryParameters); + var __httpRequest = new global::System.Net.Http.HttpRequestMessage( + method: global::System.Net.Http.HttpMethod.Post, + requestUri: new global::System.Uri(__path, global::System.UriKind.RelativeOrAbsolute)); +#if NET6_0_OR_GREATER + __httpRequest.Version = global::System.Net.HttpVersion.Version11; + __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher; +#endif + + foreach (var __authorization in __authorizations) + { + if (__authorization.Type == "Http" || + __authorization.Type == "OAuth2" || + __authorization.Type == "OpenIdConnect") + { + __httpRequest.Headers.Authorization = new global::System.Net.Http.Headers.AuthenticationHeaderValue( + scheme: __authorization.Name, + parameter: __authorization.Value); + } + else if (__authorization.Type == "ApiKey" && + __authorization.Location == "Header") + { + __httpRequest.Headers.Add(__authorization.Name, __authorization.Value); + } + } + + var __httpRequestContent = new global::System.Net.Http.MultipartFormDataContent(); + __httpRequestContent.Add( + content: new global::System.Net.Http.StringContent(request.Prompt ?? string.Empty), + name: "\"prompt\""); + + if (request.ImageAssetIdentifier != default) + { + + __httpRequestContent.Add( + content: new global::System.Net.Http.StringContent(request.ImageAssetIdentifier.ToJson(JsonSerializerContext)), + name: "\"image_asset_identifier\""); + + } + if (request.Image != default) + { + + var __contentImage = new global::System.Net.Http.ByteArrayContent(request.Image ?? global::System.Array.Empty()); + __contentImage.Headers.ContentType = new global::System.Net.Http.Headers.MediaTypeHeaderValue( + request.Imagename is null + ? "application/octet-stream" + : (global::System.IO.Path.GetExtension(request.Imagename) ?? string.Empty).ToLowerInvariant() switch + { + ".aac" => "audio/aac", + ".flac" => "audio/flac", + ".gif" => "image/gif", + ".jpeg" => "image/jpeg", + ".jpg" => "image/jpeg", + ".json" => "application/json", + ".m4a" => "audio/mp4", + ".mp3" => "audio/mpeg", + ".mp4" => "video/mp4", + ".mpeg" => "audio/mpeg", + ".mpga" => "audio/mpeg", + ".oga" => "audio/ogg", + ".ogg" => "audio/ogg", + ".opus" => "audio/ogg", + ".pdf" => "application/pdf", + ".png" => "image/png", + ".txt" => "text/plain", + ".wav" => "audio/wav", + ".weba" => "audio/webm", + ".webm" => "video/webm", + ".webp" => "image/webp", + _ => "application/octet-stream", + }); + __httpRequestContent.Add( + content: __contentImage, + name: "\"image\"", + fileName: request.Imagename != null ? $"\"{request.Imagename}\"" : string.Empty); + if (__contentImage.Headers.ContentDisposition != null) + { + __contentImage.Headers.ContentDisposition.FileNameStar = null; + } + + } + if (request.ReferenceImageAssetIdentifiers != default) + { + + __httpRequestContent.Add( + content: new global::System.Net.Http.StringContent($"[{string.Join(",", global::System.Linq.Enumerable.Select(request.ReferenceImageAssetIdentifiers!, x => x.ToJson(JsonSerializerContext)))}]"), + name: "\"reference_image_asset_identifiers\""); + + } + if (request.ReferenceImages != default) + { + + for (var __iReferenceImages = 0; __iReferenceImages < request.ReferenceImages.Count; __iReferenceImages++) + { + var __contentReferenceImages = new global::System.Net.Http.ByteArrayContent(request.ReferenceImages[__iReferenceImages]); + __contentReferenceImages.Headers.ContentType = new global::System.Net.Http.Headers.MediaTypeHeaderValue("application/octet-stream"); + __httpRequestContent.Add( + content: __contentReferenceImages, + name: "\"reference_images\"", + fileName: $"\"file{__iReferenceImages}.bin\""); + if (__contentReferenceImages.Headers.ContentDisposition != null) + { + __contentReferenceImages.Headers.ContentDisposition.FileNameStar = null; + } + } + + } + if (request.Mask != default) + { + + var __contentMask = new global::System.Net.Http.ByteArrayContent(request.Mask ?? global::System.Array.Empty()); + __contentMask.Headers.ContentType = new global::System.Net.Http.Headers.MediaTypeHeaderValue( + request.Maskname is null + ? "application/octet-stream" + : (global::System.IO.Path.GetExtension(request.Maskname) ?? string.Empty).ToLowerInvariant() switch + { + ".aac" => "audio/aac", + ".flac" => "audio/flac", + ".gif" => "image/gif", + ".jpeg" => "image/jpeg", + ".jpg" => "image/jpeg", + ".json" => "application/json", + ".m4a" => "audio/mp4", + ".mp3" => "audio/mpeg", + ".mp4" => "video/mp4", + ".mpeg" => "audio/mpeg", + ".mpga" => "audio/mpeg", + ".oga" => "audio/ogg", + ".ogg" => "audio/ogg", + ".opus" => "audio/ogg", + ".pdf" => "application/pdf", + ".png" => "image/png", + ".txt" => "text/plain", + ".wav" => "audio/wav", + ".weba" => "audio/webm", + ".webm" => "video/webm", + ".webp" => "image/webp", + _ => "application/octet-stream", + }); + __httpRequestContent.Add( + content: __contentMask, + name: "\"mask\"", + fileName: request.Maskname != null ? $"\"{request.Maskname}\"" : string.Empty); + if (__contentMask.Headers.ContentDisposition != null) + { + __contentMask.Headers.ContentDisposition.FileNameStar = null; + } + + } + if (request.RenderingSpeed != default) + { + + __httpRequestContent.Add( + content: new global::System.Net.Http.StringContent((request.RenderingSpeed).HasValue ? (request.RenderingSpeed).GetValueOrDefault().ToValueString() : string.Empty), + name: "\"rendering_speed\""); + + } + if (request.Seed != default) + { + + __httpRequestContent.Add( + content: new global::System.Net.Http.StringContent(global::System.Convert.ToString(request.Seed, global::System.Globalization.CultureInfo.InvariantCulture) ?? string.Empty), + name: "\"seed\""); + + } + if (request.NumImages != default) + { + + __httpRequestContent.Add( + content: new global::System.Net.Http.StringContent(global::System.Convert.ToString(request.NumImages, global::System.Globalization.CultureInfo.InvariantCulture) ?? string.Empty), + name: "\"num_images\""); + + } + if (request.EnableCopyrightDetection != default) + { + + __httpRequestContent.Add( + content: new global::System.Net.Http.StringContent((global::System.Convert.ToString(request.EnableCopyrightDetection, global::System.Globalization.CultureInfo.InvariantCulture) ?? string.Empty).ToLowerInvariant()), + name: "\"enable_copyright_detection\""); + + } + if (request.Async != default) + { + + __httpRequestContent.Add( + content: new global::System.Net.Http.StringContent((global::System.Convert.ToString(request.Async, global::System.Globalization.CultureInfo.InvariantCulture) ?? string.Empty).ToLowerInvariant()), + name: "\"async\""); + + } + if (request.WebhookUrl != default) + { + + __httpRequestContent.Add( + content: new global::System.Net.Http.StringContent(request.WebhookUrl ?? string.Empty), + name: "\"webhook_url\""); + + } + if (request.Private != default) + { + + __httpRequestContent.Add( + content: new global::System.Net.Http.StringContent((global::System.Convert.ToString(request.Private, global::System.Globalization.CultureInfo.InvariantCulture) ?? string.Empty).ToLowerInvariant()), + name: "\"private\""); + + } + if (request.TargetCollectionId != default) + { + + __httpRequestContent.Add( + content: new global::System.Net.Http.StringContent(request.TargetCollectionId ?? string.Empty), + name: "\"target_collection_id\""); + + } + + __httpRequest.Content = __httpRequestContent; + + global::Ideogram.AutoSDKRequestOptionsSupport.ApplyHeaders( + request: __httpRequest, + clientHeaders: Options.Headers, + requestHeaders: requestOptions?.Headers); + + PrepareRequest( + client: HttpClient, + request: __httpRequest); + PreparePostPreciseEditImageV2Ideogram45Request( + httpClient: HttpClient, + httpRequestMessage: __httpRequest, + dryRun: dryRun, + request: request); + + return __httpRequest; + } + + global::System.Net.Http.HttpRequestMessage? __httpRequest = null; + global::System.Net.Http.HttpResponseMessage? __response = null; + var __attemptNumber = 0; + try + { + for (var __attempt = 1; __attempt <= __maxAttempts; __attempt++) + { + __attemptNumber = __attempt; + __httpRequest = __CreateHttpRequest(); + await global::Ideogram.AutoSDKRequestOptionsSupport.OnBeforeRequestAsync( + clientOptions: Options, + context: global::Ideogram.AutoSDKRequestOptionsSupport.CreateHookContext( + operationId: "PostPreciseEditImageV2Ideogram45", + methodName: "PostPreciseEditImageV2Ideogram45Async", + pathTemplate: "\"/v2/image/precise-edit/ideogram-4-5\"", + httpMethod: "POST", + baseUri: BaseUri, + request: __httpRequest!, + response: null, + exception: null, + clientOptions: Options, + requestOptions: requestOptions, + attempt: __attempt, + maxAttempts: __maxAttempts, + willRetry: false, + retryDelay: null, + retryReason: global::System.String.Empty, + cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false); + try + { + __response = await HttpClient.SendAsync( + request: __httpRequest, + completionOption: global::System.Net.Http.HttpCompletionOption.ResponseContentRead, + cancellationToken: __effectiveCancellationToken).ConfigureAwait(false); + } + catch (global::System.Net.Http.HttpRequestException __exception) + { + var __retryDelay = global::Ideogram.AutoSDKRequestOptionsSupport.GetRetryDelay( + clientOptions: Options, + requestOptions: requestOptions, + response: null, + attempt: __attempt); + var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested; + await global::Ideogram.AutoSDKRequestOptionsSupport.OnAfterErrorAsync( + clientOptions: Options, + context: global::Ideogram.AutoSDKRequestOptionsSupport.CreateHookContext( + operationId: "PostPreciseEditImageV2Ideogram45", + methodName: "PostPreciseEditImageV2Ideogram45Async", + pathTemplate: "\"/v2/image/precise-edit/ideogram-4-5\"", + httpMethod: "POST", + baseUri: BaseUri, + request: __httpRequest!, + response: null, + exception: __exception, + clientOptions: Options, + requestOptions: requestOptions, + attempt: __attempt, + maxAttempts: __maxAttempts, + willRetry: __willRetry, + retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null, + retryReason: "exception", + cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false); + if (!__willRetry) + { + throw; + } + + __httpRequest.Dispose(); + __httpRequest = null; + await global::Ideogram.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync( + retryDelay: __retryDelay, + cancellationToken: __effectiveCancellationToken).ConfigureAwait(false); + continue; + } + + if (__response != null && + __attempt < __maxAttempts && + global::Ideogram.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode)) + { + var __retryDelay = global::Ideogram.AutoSDKRequestOptionsSupport.GetRetryDelay( + clientOptions: Options, + requestOptions: requestOptions, + response: __response, + attempt: __attempt); + await global::Ideogram.AutoSDKRequestOptionsSupport.OnAfterErrorAsync( + clientOptions: Options, + context: global::Ideogram.AutoSDKRequestOptionsSupport.CreateHookContext( + operationId: "PostPreciseEditImageV2Ideogram45", + methodName: "PostPreciseEditImageV2Ideogram45Async", + pathTemplate: "\"/v2/image/precise-edit/ideogram-4-5\"", + httpMethod: "POST", + baseUri: BaseUri, + request: __httpRequest!, + response: __response, + exception: null, + clientOptions: Options, + requestOptions: requestOptions, + attempt: __attempt, + maxAttempts: __maxAttempts, + willRetry: true, + retryDelay: __retryDelay, + retryReason: "status:" + ((int)__response.StatusCode).ToString(global::System.Globalization.CultureInfo.InvariantCulture), + cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false); + __response.Dispose(); + __response = null; + __httpRequest.Dispose(); + __httpRequest = null; + await global::Ideogram.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync( + retryDelay: __retryDelay, + cancellationToken: __effectiveCancellationToken).ConfigureAwait(false); + continue; + } + + break; + } + + if (__response == null) + { + throw new global::System.InvalidOperationException("No response received."); + } + + using (__response) + { + + ProcessResponse( + client: HttpClient, + response: __response); + ProcessPostPreciseEditImageV2Ideogram45Response( + httpClient: HttpClient, + httpResponseMessage: __response); + if (__response.IsSuccessStatusCode) + { + await global::Ideogram.AutoSDKRequestOptionsSupport.OnAfterSuccessAsync( + clientOptions: Options, + context: global::Ideogram.AutoSDKRequestOptionsSupport.CreateHookContext( + operationId: "PostPreciseEditImageV2Ideogram45", + methodName: "PostPreciseEditImageV2Ideogram45Async", + pathTemplate: "\"/v2/image/precise-edit/ideogram-4-5\"", + httpMethod: "POST", + baseUri: BaseUri, + request: __httpRequest!, + response: __response, + exception: null, + clientOptions: Options, + requestOptions: requestOptions, + attempt: __attemptNumber, + maxAttempts: __maxAttempts, + willRetry: false, + retryDelay: null, + retryReason: global::System.String.Empty, + cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false); + } + else + { + await global::Ideogram.AutoSDKRequestOptionsSupport.OnAfterErrorAsync( + clientOptions: Options, + context: global::Ideogram.AutoSDKRequestOptionsSupport.CreateHookContext( + operationId: "PostPreciseEditImageV2Ideogram45", + methodName: "PostPreciseEditImageV2Ideogram45Async", + pathTemplate: "\"/v2/image/precise-edit/ideogram-4-5\"", + httpMethod: "POST", + baseUri: BaseUri, + request: __httpRequest!, + response: __response, + exception: null, + clientOptions: Options, + requestOptions: requestOptions, + attempt: __attemptNumber, + maxAttempts: __maxAttempts, + willRetry: false, + retryDelay: null, + retryReason: global::System.String.Empty, + cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false); + } + // + if ((int)__response.StatusCode == 400) + { + string? __content_400 = null; + global::System.Exception? __exception_400 = null; + try + { + if (__effectiveReadResponseAsString) + { + __content_400 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false); + } + else + { + __content_400 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false); + } + } + catch (global::System.Exception __ex) + { + __exception_400 = __ex; + } + + + throw global::Ideogram.ApiException.Create( + statusCode: __response.StatusCode, + message: __content_400 ?? __response.ReasonPhrase ?? string.Empty, + innerException: __exception_400, + responseBody: __content_400, + responseHeaders: global::System.Linq.Enumerable.ToDictionary( + __response.Headers, + h => h.Key, + h => h.Value)); + } + // + if ((int)__response.StatusCode == 401) + { + string? __content_401 = null; + global::System.Exception? __exception_401 = null; + try + { + if (__effectiveReadResponseAsString) + { + __content_401 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false); + } + else + { + __content_401 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false); + } + } + catch (global::System.Exception __ex) + { + __exception_401 = __ex; + } + + + throw global::Ideogram.ApiException.Create( + statusCode: __response.StatusCode, + message: __content_401 ?? __response.ReasonPhrase ?? string.Empty, + innerException: __exception_401, + responseBody: __content_401, + responseHeaders: global::System.Linq.Enumerable.ToDictionary( + __response.Headers, + h => h.Key, + h => h.Value)); + } + // Insufficient credits or quota. + if ((int)__response.StatusCode == 402) + { + string? __content_402 = null; + global::System.Exception? __exception_402 = null; + global::Ideogram.GenerationErrorResponse? __value_402 = null; + try + { + if (__effectiveReadResponseAsString) + { + __content_402 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false); + __value_402 = global::Ideogram.GenerationErrorResponse.FromJson(__content_402, JsonSerializerContext); + } + else + { + __content_402 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false); + + __value_402 = global::Ideogram.GenerationErrorResponse.FromJson(__content_402, JsonSerializerContext); + } + } + catch (global::System.Exception __ex) + { + __exception_402 = __ex; + } + + + throw global::Ideogram.ApiException.Create( + statusCode: __response.StatusCode, + message: __content_402 ?? __response.ReasonPhrase ?? string.Empty, + innerException: __exception_402, + responseBody: __content_402, + responseObject: __value_402, + responseHeaders: global::System.Linq.Enumerable.ToDictionary( + __response.Headers, + h => h.Key, + h => h.Value)); + } + // + if ((int)__response.StatusCode == 422) + { + string? __content_422 = null; + global::System.Exception? __exception_422 = null; + try + { + if (__effectiveReadResponseAsString) + { + __content_422 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false); + } + else + { + __content_422 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false); + } + } + catch (global::System.Exception __ex) + { + __exception_422 = __ex; + } + + + throw global::Ideogram.ApiException.Create( + statusCode: __response.StatusCode, + message: __content_422 ?? __response.ReasonPhrase ?? string.Empty, + innerException: __exception_422, + responseBody: __content_422, + responseHeaders: global::System.Linq.Enumerable.ToDictionary( + __response.Headers, + h => h.Key, + h => h.Value)); + } + // Too many requests. + if ((int)__response.StatusCode == 429) + { + string? __content_429 = null; + global::System.Exception? __exception_429 = null; + global::Ideogram.GenerationErrorResponse? __value_429 = null; + try + { + if (__effectiveReadResponseAsString) + { + __content_429 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false); + __value_429 = global::Ideogram.GenerationErrorResponse.FromJson(__content_429, JsonSerializerContext); + } + else + { + __content_429 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false); + + __value_429 = global::Ideogram.GenerationErrorResponse.FromJson(__content_429, JsonSerializerContext); + } + } + catch (global::System.Exception __ex) + { + __exception_429 = __ex; + } + + + throw global::Ideogram.ApiException.Create( + statusCode: __response.StatusCode, + message: __content_429 ?? __response.ReasonPhrase ?? string.Empty, + innerException: __exception_429, + responseBody: __content_429, + responseObject: __value_429, + responseHeaders: global::System.Linq.Enumerable.ToDictionary( + __response.Headers, + h => h.Key, + h => h.Value)); + } + // + if ((int)__response.StatusCode == 500) + { + string? __content_500 = null; + global::System.Exception? __exception_500 = null; + try + { + if (__effectiveReadResponseAsString) + { + __content_500 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false); + } + else + { + __content_500 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false); + } + } + catch (global::System.Exception __ex) + { + __exception_500 = __ex; + } + + + throw global::Ideogram.ApiException.Create( + statusCode: __response.StatusCode, + message: __content_500 ?? __response.ReasonPhrase ?? string.Empty, + innerException: __exception_500, + responseBody: __content_500, + responseHeaders: global::System.Linq.Enumerable.ToDictionary( + __response.Headers, + h => h.Key, + h => h.Value)); + } + // + if ((int)__response.StatusCode == 503) + { + string? __content_503 = null; + global::System.Exception? __exception_503 = null; + try + { + if (__effectiveReadResponseAsString) + { + __content_503 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false); + } + else + { + __content_503 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false); + } + } + catch (global::System.Exception __ex) + { + __exception_503 = __ex; + } + + + throw global::Ideogram.ApiException.Create( + statusCode: __response.StatusCode, + message: __content_503 ?? __response.ReasonPhrase ?? string.Empty, + innerException: __exception_503, + responseBody: __content_503, + responseHeaders: global::System.Linq.Enumerable.ToDictionary( + __response.Headers, + h => h.Key, + h => h.Value)); + } + + if (__effectiveReadResponseAsString) + { + var __content = await __response.Content.ReadAsStringAsync( + #if NET5_0_OR_GREATER + __effectiveCancellationToken + #endif + ).ConfigureAwait(false); + + ProcessResponseContent( + client: HttpClient, + response: __response, + content: ref __content); + ProcessPostPreciseEditImageV2Ideogram45ResponseContent( + httpClient: HttpClient, + httpResponseMessage: __response, + content: ref __content); + + try + { + __response.EnsureSuccessStatusCode(); + + var __value = global::Ideogram.PreciseEditImageIdeogram45Response.FromJson(__content, JsonSerializerContext) ?? + throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" "); + return new global::Ideogram.AutoSDKHttpResponse( + statusCode: __response.StatusCode, + headers: global::Ideogram.AutoSDKHttpResponse.CreateHeaders(__response), + requestUri: __response.RequestMessage?.RequestUri, + body: __value); + } + catch (global::System.Exception __ex) + { + throw global::Ideogram.ApiException.Create( + statusCode: __response.StatusCode, + message: __content ?? __response.ReasonPhrase ?? string.Empty, + innerException: __ex, + responseBody: __content, + responseHeaders: global::System.Linq.Enumerable.ToDictionary( + __response.Headers, + h => h.Key, + h => h.Value)); + } + } + else + { + try + { + __response.EnsureSuccessStatusCode(); + using var __content = await __response.Content.ReadAsStreamAsync( + #if NET5_0_OR_GREATER + __effectiveCancellationToken + #endif + ).ConfigureAwait(false); + + var __value = await global::Ideogram.PreciseEditImageIdeogram45Response.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ?? + throw new global::System.InvalidOperationException("Response deserialization failed."); + return new global::Ideogram.AutoSDKHttpResponse( + statusCode: __response.StatusCode, + headers: global::Ideogram.AutoSDKHttpResponse.CreateHeaders(__response), + requestUri: __response.RequestMessage?.RequestUri, + body: __value); + } + catch (global::System.Exception __ex) + { + string? __content = null; + try + { + __content = await __response.Content.ReadAsStringAsync( + #if NET5_0_OR_GREATER + __effectiveCancellationToken + #endif + ).ConfigureAwait(false); + } + catch (global::System.Exception) + { + } + + throw global::Ideogram.ApiException.Create( + statusCode: __response.StatusCode, + message: __content ?? __response.ReasonPhrase ?? string.Empty, + innerException: __ex, + responseBody: __content, + responseHeaders: global::System.Linq.Enumerable.ToDictionary( + __response.Headers, + h => h.Key, + h => h.Value)); + } + } + + } + } + finally + { + __httpRequest?.Dispose(); + } + } + /// + /// Edit an image with Ideogram 4.5, keeping the source's exact geometry
+ /// Edit an image with Ideogram 4.5, returning output at that image's exact
+ /// width and height. An image too large for the model is scaled down to
+ /// fit while keeping its exact proportion, and one whose aspect ratio is
+ /// outside 1:6 to 6:1 is rejected — this endpoint never reshapes, so there
+ /// is no size to reshape it to. Unlike
+ /// `POST /v2/image/generate/ideogram-4-5`, this endpoint takes no `size`:
+ /// the output always matches the image being edited, so the edit drops
+ /// back into whatever it came from without reframing.
+ /// Supply the image to edit as an `image_asset_identifier` reference or as
+ /// raw `image` bytes (multipart requests only); if both are supplied, the
+ /// reference wins and the bytes are ignored. Add up to four more images
+ /// via `reference_image_asset_identifiers` or `reference_images` to guide
+ /// the edit — those are never edited themselves.
+ /// Supply a `mask` to confine the edit to part of the image being edited.
+ /// The mask is optional — without one the prompt is applied to the whole
+ /// image. Masks are read as an additional reference image, so a masked
+ /// request may carry at most three `reference_images`.
+ /// The `prompt` is the edit instruction. It accepts either natural
+ /// language or a structured JSON prompt; the server detects which was
+ /// supplied. A natural-language instruction is automatically rewritten
+ /// into the model's structured edit contract, while a prompt that is
+ /// already valid structured JSON is consumed directly.
+ /// By default the request blocks until the images are ready and returns
+ /// them in `data`. Set `async` to true to return immediately after the
+ /// request is accepted, then poll for completion and results with
+ /// `GET /v1/generations/{generation_id}` using the returned
+ /// `generation_id`.
+ /// Supplying a `webhook_url` makes the request asynchronous whatever
+ /// `async` says: the response returns as soon as the request is accepted,
+ /// and the finished result is POSTed to that URL. + ///
+ /// + /// Default Value: false + /// + /// + /// The edit instruction to apply to the sources. Accepts either
+ /// natural language or a structured JSON prompt; the server detects
+ /// which was supplied. Natural language is automatically rewritten
+ /// into the model's structured edit contract, while structured JSON
+ /// is consumed directly. + /// + /// + /// The image to edit, as an existing upload or generated image asset. Supply this or `image`, never both. Takes priority over `image` if both are supplied. Cannot be combined with `mask`. + /// + /// + /// The image to edit, as raw bytes (max size 25MB; JPEG, PNG, or WEBP only). Multipart requests only; ignored if `image_asset_identifier` is also supplied. Required when supplying a `mask`. + /// + /// + /// The image to edit, as raw bytes (max size 25MB; JPEG, PNG, or WEBP only). Multipart requests only; ignored if `image_asset_identifier` is also supplied. Required when supplying a `mask`. + /// + /// + /// Optional additional images to guide the edit, by reference. These are never edited themselves; only `image_asset_identifier` or `image` is. Requires the image being edited to be supplied by reference too, and cannot be combined with `mask`. + /// + /// + /// Optional additional images to guide the edit (max 4, max size 25MB each), as raw bytes; only JPEG, PNG, and WEBP formats are supported. These are never edited themselves; only `image` is. Multipart requests only; ignored if `reference_image_asset_identifiers` is also supplied. A masked request may carry at most three, because the mask occupies one of the model's reference slots. + /// + /// + /// An optional mask confining the edit to part of `image`, as raw bytes (multipart requests only; JPEG, PNG, or WEBP, max 25MB). Black marks the area to edit and white the area to preserve; values in between are rounded to whichever is nearer. The mask must have the same width and height as `image`, and must contain both black and white areas. Requires the image being edited to be uploaded as raw `image` bytes in the same request; masks cannot be combined with asset references. The mask is supplied to the model as an additional reference image, so a masked request may carry at most three `reference_images`. + /// + /// + /// An optional mask confining the edit to part of `image`, as raw bytes (multipart requests only; JPEG, PNG, or WEBP, max 25MB). Black marks the area to edit and white the area to preserve; values in between are rounded to whichever is nearer. The mask must have the same width and height as `image`, and must contain both black and white areas. Requires the image being edited to be uploaded as raw `image` bytes in the same request; masks cannot be combined with asset references. The mask is supplied to the model as an additional reference image, so a masked request may carry at most three `reference_images`. + /// + /// + /// The rendering speed to use. `ultra` renders multiple candidate edits internally and returns the one that best applies the instruction; it takes longer than `quality`, is priced higher, and supports at most 4 images per request.
+ /// Default Value: default + /// + /// + /// Random seed. Set for reproducible generation.
+ /// Example: 12345 + /// + /// + /// The number of images to generate.
+ /// Default Value: 1 + /// + /// + /// Optional. Opt this request into post-generation copyright detection. Adds detection latency; flagged images come back with `is_image_safe: false`. + /// + /// + /// When false (the default), the request blocks until the images are ready and returns them in `data`. When true, the request returns as soon as it is accepted; poll for completion and results with `GET /v1/generations/{generation_id}` using the returned `generation_id`.
+ /// Default Value: false + /// + /// + /// HTTPS URL that Ideogram delivers the generated result to. Ideogram sends a
+ /// JSON POST to this URL once all images for the request have finished
+ /// generating. The body mirrors the synchronous generate response:
+ /// `request_id`, `created`, and a `data` array
+ /// containing every generated image (`url`, `prompt`, `resolution`, `seed`,
+ /// `is_image_safe`). Each delivery is signed with Ed25519 and verifiable
+ /// against the public keys at `https://api.ideogram.ai/v1/.well-known/jwks.json`. Must be HTTPS;
+ /// private and loopback hosts and the cloud metadata service are rejected.
+ /// Example: https://api.example.com/webhooks/ideogram + /// + /// + /// When true or omitted, the output is kept private to your account. Set to false to publish the output to the public feed. Enterprise accounts always generate privately. + /// + /// + /// A collection you can write to, by its URL-safe base64 collection id. The output images are added to it when the request completes. + /// + /// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering. + /// The token to cancel the operation with + /// + public async global::System.Threading.Tasks.Task PostPreciseEditImageV2Ideogram45Async( + string prompt, + bool? dryRun = default, + global::Ideogram.AssetIdentifier? imageAssetIdentifier = default, + byte[]? image = default, + string? imagename = default, + global::System.Collections.Generic.IList? referenceImageAssetIdentifiers = default, + global::System.Collections.Generic.IList? referenceImages = default, + byte[]? mask = default, + string? maskname = default, + global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeed? renderingSpeed = default, + int? seed = default, + int? numImages = default, + bool? enableCopyrightDetection = default, + bool? async = default, + string? webhookUrl = default, + bool? @private = default, + string? targetCollectionId = default, + global::Ideogram.AutoSDKRequestOptions? requestOptions = default, + global::System.Threading.CancellationToken cancellationToken = default) + { + var __request = new global::Ideogram.PreciseEditImageIdeogram45Request + { + Prompt = prompt, + ImageAssetIdentifier = imageAssetIdentifier, + Image = image, + Imagename = imagename, + ReferenceImageAssetIdentifiers = referenceImageAssetIdentifiers, + ReferenceImages = referenceImages, + Mask = mask, + Maskname = maskname, + RenderingSpeed = renderingSpeed, + Seed = seed, + NumImages = numImages, + EnableCopyrightDetection = enableCopyrightDetection, + Async = async, + WebhookUrl = webhookUrl, + Private = @private, + TargetCollectionId = targetCollectionId, + }; + + return await PostPreciseEditImageV2Ideogram45Async( + dryRun: dryRun, + request: __request, + requestOptions: requestOptions, + cancellationToken: cancellationToken).ConfigureAwait(false); + } + } +} \ No newline at end of file diff --git a/src/libs/Ideogram/Generated/Ideogram.ImagesPreciseEditClient.g.cs b/src/libs/Ideogram/Generated/Ideogram.ImagesPreciseEditClient.g.cs new file mode 100644 index 0000000..0f9a33b --- /dev/null +++ b/src/libs/Ideogram/Generated/Ideogram.ImagesPreciseEditClient.g.cs @@ -0,0 +1,144 @@ + +#nullable enable + +namespace Ideogram +{ + /// + /// Edit source images at the source's own width and height. These endpoints never reframe: the output always matches the image you sent.
+ /// If no httpClient is provided, a new one will be created.
+ /// If no baseUri is provided, the default baseUri from OpenAPI spec will be used. + ///
+ public sealed partial class ImagesPreciseEditClient : global::Ideogram.IImagesPreciseEditClient, global::System.IDisposable + { + /// + /// + /// + public const string DefaultBaseUrl = "https://api.ideogram.ai/"; + + private bool _disposeHttpClient = true; + + /// + public global::System.Net.Http.HttpClient HttpClient { get; } + + /// + public System.Uri? BaseUri => HttpClient.BaseAddress; + + /// + public global::System.Collections.Generic.List Authorizations { get; } + + /// + public bool ReadResponseAsString { get; set; } +#if DEBUG + = true; +#endif + + /// + public global::Ideogram.AutoSDKClientOptions Options { get; } + + internal global::System.Lazy JsonSerializerContextProvider { get; set; } = new(() => global::Ideogram.ImagesPreciseEditSourceGenerationContext.Default); + + /// + /// + /// + public global::System.Text.Json.Serialization.JsonSerializerContext JsonSerializerContext + { + get => JsonSerializerContextProvider.Value; + set => JsonSerializerContextProvider = new(() => value); + } + + + /// + /// Creates a new instance of the ImagesPreciseEditClient. + /// If no httpClient is provided, a new one will be created. + /// If no baseUri is provided, the default baseUri from OpenAPI spec will be used. + /// + /// The HttpClient instance. If not provided, a new one will be created. + /// The base URL for the API. If not provided, the default baseUri from OpenAPI spec will be used. + /// The authorizations to use for the requests. + /// Dispose the HttpClient when the instance is disposed. True by default. + public ImagesPreciseEditClient( + global::System.Net.Http.HttpClient? httpClient = null, + global::System.Uri? baseUri = null, + global::System.Collections.Generic.List? authorizations = null, + bool disposeHttpClient = true) : this( + httpClient, + baseUri, + authorizations, + options: null, + disposeHttpClient: disposeHttpClient) + { + } + + /// + /// Creates a new instance of the ImagesPreciseEditClient with explicit options but no base URL override. + /// Skips passing baseUri so the default base URL from the OpenAPI spec applies. + /// + /// The HttpClient instance. If not provided, a new one will be created. + /// The authorizations to use for the requests. + /// Client-wide request defaults such as headers, query parameters, retries, and timeout. + /// Dispose the HttpClient when the instance is disposed. True by default. + public ImagesPreciseEditClient( + global::System.Net.Http.HttpClient? httpClient, + global::System.Collections.Generic.List? authorizations, + global::Ideogram.AutoSDKClientOptions? options, + bool disposeHttpClient = true) : this( + httpClient, + baseUri: null, + authorizations, + options, + disposeHttpClient: disposeHttpClient) + { + } + + /// + /// Creates a new instance of the ImagesPreciseEditClient. + /// If no httpClient is provided, a new one will be created. + /// If no baseUri is provided, the default baseUri from OpenAPI spec will be used. + /// + /// The HttpClient instance. If not provided, a new one will be created. + /// The base URL for the API. If not provided, the default baseUri from OpenAPI spec will be used. + /// The authorizations to use for the requests. + /// Client-wide request defaults such as headers, query parameters, retries, and timeout. + /// Dispose the HttpClient when the instance is disposed. True by default. + public ImagesPreciseEditClient( + global::System.Net.Http.HttpClient? httpClient, + global::System.Uri? baseUri, + global::System.Collections.Generic.List? authorizations, + global::Ideogram.AutoSDKClientOptions? options, + bool disposeHttpClient = true) + { + + HttpClient = httpClient ?? new global::System.Net.Http.HttpClient(); + HttpClient.BaseAddress ??= baseUri ?? new global::System.Uri(DefaultBaseUrl); + Authorizations = authorizations ?? new global::System.Collections.Generic.List(); + Options = options ?? new global::Ideogram.AutoSDKClientOptions(); + _disposeHttpClient = disposeHttpClient; + + Initialized(HttpClient); + } + + /// + public void Dispose() + { + if (_disposeHttpClient) + { + HttpClient.Dispose(); + } + } + + partial void Initialized( + global::System.Net.Http.HttpClient client); + partial void PrepareArguments( + global::System.Net.Http.HttpClient client); + partial void PrepareRequest( + global::System.Net.Http.HttpClient client, + global::System.Net.Http.HttpRequestMessage request); + partial void ProcessResponse( + global::System.Net.Http.HttpClient client, + global::System.Net.Http.HttpResponseMessage response); + partial void ProcessResponseContent( + global::System.Net.Http.HttpClient client, + global::System.Net.Http.HttpResponseMessage response, + ref string content); + } +} \ No newline at end of file diff --git a/src/libs/Ideogram/Generated/Ideogram.JsonConverters.IdeogramV3AspectRatio.g.cs b/src/libs/Ideogram/Generated/Ideogram.JsonConverters.IdeogramV3AspectRatio.g.cs new file mode 100644 index 0000000..39a338e --- /dev/null +++ b/src/libs/Ideogram/Generated/Ideogram.JsonConverters.IdeogramV3AspectRatio.g.cs @@ -0,0 +1,53 @@ +#nullable enable + +namespace Ideogram.JsonConverters +{ + /// + public sealed class IdeogramV3AspectRatioJsonConverter : global::System.Text.Json.Serialization.JsonConverter + { + /// + public override global::Ideogram.IdeogramV3AspectRatio Read( + ref global::System.Text.Json.Utf8JsonReader reader, + global::System.Type typeToConvert, + global::System.Text.Json.JsonSerializerOptions options) + { + switch (reader.TokenType) + { + case global::System.Text.Json.JsonTokenType.String: + { + var stringValue = reader.GetString(); + if (stringValue != null) + { + return global::Ideogram.IdeogramV3AspectRatioExtensions.ToEnum(stringValue) ?? default; + } + + break; + } + case global::System.Text.Json.JsonTokenType.Number: + { + var numValue = reader.GetInt32(); + return (global::Ideogram.IdeogramV3AspectRatio)numValue; + } + case global::System.Text.Json.JsonTokenType.Null: + { + return default(global::Ideogram.IdeogramV3AspectRatio); + } + default: + throw new global::System.ArgumentOutOfRangeException(nameof(reader)); + } + + return default; + } + + /// + public override void Write( + global::System.Text.Json.Utf8JsonWriter writer, + global::Ideogram.IdeogramV3AspectRatio value, + global::System.Text.Json.JsonSerializerOptions options) + { + writer = writer ?? throw new global::System.ArgumentNullException(nameof(writer)); + + writer.WriteStringValue(global::Ideogram.IdeogramV3AspectRatioExtensions.ToValueString(value)); + } + } +} diff --git a/src/libs/Ideogram/Generated/Ideogram.JsonConverters.IdeogramV3AspectRatioNullable.g.cs b/src/libs/Ideogram/Generated/Ideogram.JsonConverters.IdeogramV3AspectRatioNullable.g.cs new file mode 100644 index 0000000..5014b78 --- /dev/null +++ b/src/libs/Ideogram/Generated/Ideogram.JsonConverters.IdeogramV3AspectRatioNullable.g.cs @@ -0,0 +1,60 @@ +#nullable enable + +namespace Ideogram.JsonConverters +{ + /// + public sealed class IdeogramV3AspectRatioNullableJsonConverter : global::System.Text.Json.Serialization.JsonConverter + { + /// + public override global::Ideogram.IdeogramV3AspectRatio? Read( + ref global::System.Text.Json.Utf8JsonReader reader, + global::System.Type typeToConvert, + global::System.Text.Json.JsonSerializerOptions options) + { + switch (reader.TokenType) + { + case global::System.Text.Json.JsonTokenType.String: + { + var stringValue = reader.GetString(); + if (stringValue != null) + { + return global::Ideogram.IdeogramV3AspectRatioExtensions.ToEnum(stringValue); + } + + break; + } + case global::System.Text.Json.JsonTokenType.Number: + { + var numValue = reader.GetInt32(); + return (global::Ideogram.IdeogramV3AspectRatio)numValue; + } + case global::System.Text.Json.JsonTokenType.Null: + { + return default(global::Ideogram.IdeogramV3AspectRatio?); + } + default: + throw new global::System.ArgumentOutOfRangeException(nameof(reader)); + } + + return default; + } + + /// + public override void Write( + global::System.Text.Json.Utf8JsonWriter writer, + global::Ideogram.IdeogramV3AspectRatio? value, + global::System.Text.Json.JsonSerializerOptions options) + { + writer = writer ?? throw new global::System.ArgumentNullException(nameof(writer)); + + if (value == null) + { + writer.WriteNullValue(); + } + else + { + writer.WriteStringValue(global::Ideogram.IdeogramV3AspectRatioExtensions.ToValueString(value.Value)); + } + } + } +} diff --git a/src/libs/Ideogram/Generated/Ideogram.JsonConverters.PreciseEditImageIdeogram45RequestRenderingSpeed.g.cs b/src/libs/Ideogram/Generated/Ideogram.JsonConverters.PreciseEditImageIdeogram45RequestRenderingSpeed.g.cs new file mode 100644 index 0000000..1bd3d5d --- /dev/null +++ b/src/libs/Ideogram/Generated/Ideogram.JsonConverters.PreciseEditImageIdeogram45RequestRenderingSpeed.g.cs @@ -0,0 +1,53 @@ +#nullable enable + +namespace Ideogram.JsonConverters +{ + /// + public sealed class PreciseEditImageIdeogram45RequestRenderingSpeedJsonConverter : global::System.Text.Json.Serialization.JsonConverter + { + /// + public override global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeed Read( + ref global::System.Text.Json.Utf8JsonReader reader, + global::System.Type typeToConvert, + global::System.Text.Json.JsonSerializerOptions options) + { + switch (reader.TokenType) + { + case global::System.Text.Json.JsonTokenType.String: + { + var stringValue = reader.GetString(); + if (stringValue != null) + { + return global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeedExtensions.ToEnum(stringValue) ?? default; + } + + break; + } + case global::System.Text.Json.JsonTokenType.Number: + { + var numValue = reader.GetInt32(); + return (global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeed)numValue; + } + case global::System.Text.Json.JsonTokenType.Null: + { + return default(global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeed); + } + default: + throw new global::System.ArgumentOutOfRangeException(nameof(reader)); + } + + return default; + } + + /// + public override void Write( + global::System.Text.Json.Utf8JsonWriter writer, + global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeed value, + global::System.Text.Json.JsonSerializerOptions options) + { + writer = writer ?? throw new global::System.ArgumentNullException(nameof(writer)); + + writer.WriteStringValue(global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeedExtensions.ToValueString(value)); + } + } +} diff --git a/src/libs/Ideogram/Generated/Ideogram.JsonConverters.PreciseEditImageIdeogram45RequestRenderingSpeedNullable.g.cs b/src/libs/Ideogram/Generated/Ideogram.JsonConverters.PreciseEditImageIdeogram45RequestRenderingSpeedNullable.g.cs new file mode 100644 index 0000000..36b7463 --- /dev/null +++ b/src/libs/Ideogram/Generated/Ideogram.JsonConverters.PreciseEditImageIdeogram45RequestRenderingSpeedNullable.g.cs @@ -0,0 +1,60 @@ +#nullable enable + +namespace Ideogram.JsonConverters +{ + /// + public sealed class PreciseEditImageIdeogram45RequestRenderingSpeedNullableJsonConverter : global::System.Text.Json.Serialization.JsonConverter + { + /// + public override global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeed? Read( + ref global::System.Text.Json.Utf8JsonReader reader, + global::System.Type typeToConvert, + global::System.Text.Json.JsonSerializerOptions options) + { + switch (reader.TokenType) + { + case global::System.Text.Json.JsonTokenType.String: + { + var stringValue = reader.GetString(); + if (stringValue != null) + { + return global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeedExtensions.ToEnum(stringValue); + } + + break; + } + case global::System.Text.Json.JsonTokenType.Number: + { + var numValue = reader.GetInt32(); + return (global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeed)numValue; + } + case global::System.Text.Json.JsonTokenType.Null: + { + return default(global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeed?); + } + default: + throw new global::System.ArgumentOutOfRangeException(nameof(reader)); + } + + return default; + } + + /// + public override void Write( + global::System.Text.Json.Utf8JsonWriter writer, + global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeed? value, + global::System.Text.Json.JsonSerializerOptions options) + { + writer = writer ?? throw new global::System.ArgumentNullException(nameof(writer)); + + if (value == null) + { + writer.WriteNullValue(); + } + else + { + writer.WriteStringValue(global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeedExtensions.ToValueString(value.Value)); + } + } + } +} diff --git a/src/libs/Ideogram/Generated/Ideogram.JsonSerializerContext.g.cs b/src/libs/Ideogram/Generated/Ideogram.JsonSerializerContext.g.cs index c5b6d76..237b3e2 100644 --- a/src/libs/Ideogram/Generated/Ideogram.JsonSerializerContext.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.JsonSerializerContext.g.cs @@ -357,6 +357,7 @@ namespace Ideogram [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.IList))] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GeneratedImageObject))] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GenerateImageIdeogramV3Request))] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.IdeogramV3AspectRatio), TypeInfoPropertyName = "IdeogramV3AspectRatio2")] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GenerateImageIdeogramV3RequestRenderingSpeed), TypeInfoPropertyName = "GenerateImageIdeogramV3RequestRenderingSpeed2")] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.MagicPromptMode), TypeInfoPropertyName = "MagicPromptMode2")] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.IdeogramColorPalette), TypeInfoPropertyName = "IdeogramColorPalette2")] @@ -407,6 +408,9 @@ namespace Ideogram [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GenerateImageIdeogram45Response))] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GenerateImageIdeogram45Request))] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GenerateImageIdeogram45RequestRenderingSpeed), TypeInfoPropertyName = "GenerateImageIdeogram45RequestRenderingSpeed2")] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.PreciseEditImageIdeogram45Response))] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.PreciseEditImageIdeogram45Request))] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeed), TypeInfoPropertyName = "PreciseEditImageIdeogram45RequestRenderingSpeed2")] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GenerateImageNanoBanana2Response))] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GenerateImageNanoBanana2Request))] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GenerateImageNanoBanana2RequestResolutionTier), TypeInfoPropertyName = "GenerateImageNanoBanana2RequestResolutionTier2")] @@ -510,10 +514,6 @@ namespace Ideogram [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GetApiProfilesResponse))] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.IList))] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.ApiProfile))] - [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.ApiProfileType), TypeInfoPropertyName = "ApiProfileType2")] - [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.ApiProfileRole), TypeInfoPropertyName = "ApiProfileRole2")] - [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.IList))] - [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.UpdateOrganizationApiPropertiesResponse))] internal sealed partial class SourceGenerationContextChunk0 : global::System.Text.Json.Serialization.JsonSerializerContext { } @@ -526,6 +526,10 @@ internal sealed partial class SourceGenerationContextChunk0 : global::System.Tex Converters = new global::System.Type[] { })] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.ApiProfileType), TypeInfoPropertyName = "ApiProfileType2")] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.ApiProfileRole), TypeInfoPropertyName = "ApiProfileRole2")] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.IList))] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.UpdateOrganizationApiPropertiesResponse))] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.UpdateOrganizationApiPropertiesRequest))] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GetApiOrganizationUserSuggestionsResponse))] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.IList))] @@ -754,6 +758,7 @@ internal sealed partial class SourceGenerationContextChunk0 : global::System.Tex [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.MaterialSwapQuality?), TypeInfoPropertyName = "NullableMaterialSwapQuality2")] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.UpscaleToolRequestUpscaleFactor?), TypeInfoPropertyName = "NullableUpscaleToolRequestUpscaleFactor2")] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.LayerizedImageObjectObjectType?), TypeInfoPropertyName = "NullableLayerizedImageObjectObjectType2")] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.IdeogramV3AspectRatio?), TypeInfoPropertyName = "NullableIdeogramV3AspectRatio2")] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GenerateImageIdeogramV3RequestRenderingSpeed?), TypeInfoPropertyName = "NullableGenerateImageIdeogramV3RequestRenderingSpeed2")] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.MagicPromptMode?), TypeInfoPropertyName = "NullableMagicPromptMode2")] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.IdeogramColorPalette?), TypeInfoPropertyName = "NullableIdeogramColorPalette2")] @@ -776,6 +781,7 @@ internal sealed partial class SourceGenerationContextChunk0 : global::System.Tex [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GenerationQuality?), TypeInfoPropertyName = "NullableGenerationQuality2")] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GenerateImagePImageIdeogramRequestResolution?), TypeInfoPropertyName = "NullableGenerateImagePImageIdeogramRequestResolution2")] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GenerateImageIdeogram45RequestRenderingSpeed?), TypeInfoPropertyName = "NullableGenerateImageIdeogram45RequestRenderingSpeed2")] + [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeed?), TypeInfoPropertyName = "NullablePreciseEditImageIdeogram45RequestRenderingSpeed2")] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GenerateImageNanoBanana2RequestResolutionTier?), TypeInfoPropertyName = "NullableGenerateImageNanoBanana2RequestResolutionTier2")] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GenerateImageNanoBananaProRequestResolutionTier?), TypeInfoPropertyName = "NullableGenerateImageNanoBananaProRequestResolutionTier2")] [global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Ideogram.GenerateImageGptImage25FlareRequestBackground?), TypeInfoPropertyName = "NullableGenerateImageGptImage25FlareRequestBackground2")] @@ -1339,6 +1345,10 @@ public override bool CanConvert(global::System.Type typeToConvert) || typeToConvert == typeof(global::Ideogram.GenerateImageIdeogram45RequestRenderingSpeed?) + || typeToConvert == typeof(global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeed) + + || typeToConvert == typeof(global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeed?) + || typeToConvert == typeof(global::Ideogram.GenerateImageNanoBanana2RequestResolutionTier) || typeToConvert == typeof(global::Ideogram.GenerateImageNanoBanana2RequestResolutionTier?) @@ -1615,6 +1625,10 @@ public override bool CanConvert(global::System.Type typeToConvert) || typeToConvert == typeof(global::Ideogram.MinimaxH3PromptExpansionMode?) + || typeToConvert == typeof(global::Ideogram.IdeogramV3AspectRatio) + + || typeToConvert == typeof(global::Ideogram.IdeogramV3AspectRatio?) + || typeToConvert == typeof(global::Ideogram.MagicPromptMode) || typeToConvert == typeof(global::Ideogram.MagicPromptMode?) @@ -2612,6 +2626,16 @@ public override bool CanConvert(global::System.Type typeToConvert) return new global::Ideogram.JsonConverters.GenerateImageIdeogram45RequestRenderingSpeedNullableJsonConverter(); } + if (typeToConvert == typeof(global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeed)) + { + return new global::Ideogram.JsonConverters.PreciseEditImageIdeogram45RequestRenderingSpeedJsonConverter(); + } + + if (typeToConvert == typeof(global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeed?)) + { + return new global::Ideogram.JsonConverters.PreciseEditImageIdeogram45RequestRenderingSpeedNullableJsonConverter(); + } + if (typeToConvert == typeof(global::Ideogram.GenerateImageNanoBanana2RequestResolutionTier)) { return new global::Ideogram.JsonConverters.GenerateImageNanoBanana2RequestResolutionTierJsonConverter(); @@ -3302,6 +3326,16 @@ public override bool CanConvert(global::System.Type typeToConvert) return new global::Ideogram.JsonConverters.MinimaxH3PromptExpansionModeNullableJsonConverter(); } + if (typeToConvert == typeof(global::Ideogram.IdeogramV3AspectRatio)) + { + return new global::Ideogram.JsonConverters.IdeogramV3AspectRatioJsonConverter(); + } + + if (typeToConvert == typeof(global::Ideogram.IdeogramV3AspectRatio?)) + { + return new global::Ideogram.JsonConverters.IdeogramV3AspectRatioNullableJsonConverter(); + } + if (typeToConvert == typeof(global::Ideogram.MagicPromptMode)) { return new global::Ideogram.JsonConverters.MagicPromptModeJsonConverter(); diff --git a/src/libs/Ideogram/Generated/Ideogram.JsonSerializerContextTypes.g.cs b/src/libs/Ideogram/Generated/Ideogram.JsonSerializerContextTypes.g.cs index ac908de..c479115 100644 --- a/src/libs/Ideogram/Generated/Ideogram.JsonSerializerContextTypes.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.JsonSerializerContextTypes.g.cs @@ -1393,1103 +1393,1119 @@ public sealed partial class JsonSerializerContextTypes /// /// /// - public global::Ideogram.GenerateImageIdeogramV3RequestRenderingSpeed? Type340 { get; set; } + public global::Ideogram.IdeogramV3AspectRatio? Type340 { get; set; } /// /// /// - public global::Ideogram.MagicPromptMode? Type341 { get; set; } + public global::Ideogram.GenerateImageIdeogramV3RequestRenderingSpeed? Type341 { get; set; } /// /// /// - public global::Ideogram.IdeogramColorPalette? Type342 { get; set; } + public global::Ideogram.MagicPromptMode? Type342 { get; set; } /// /// /// - public global::Ideogram.IdeogramV3StyleType? Type343 { get; set; } + public global::Ideogram.IdeogramColorPalette? Type343 { get; set; } /// /// /// - public global::Ideogram.IdeogramV3StylePreset? Type344 { get; set; } + public global::Ideogram.IdeogramV3StyleType? Type344 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV3CustomModelResponse? Type345 { get; set; } + public global::Ideogram.IdeogramV3StylePreset? Type345 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV3CustomModelRequest? Type346 { get; set; } + public global::Ideogram.GenerateImageIdeogramV3CustomModelResponse? Type346 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV3CustomModelRequestRenderingSpeed? Type347 { get; set; } + public global::Ideogram.GenerateImageIdeogramV3CustomModelRequest? Type347 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV4Response? Type348 { get; set; } + public global::Ideogram.GenerateImageIdeogramV3CustomModelRequestRenderingSpeed? Type348 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV4Request? Type349 { get; set; } + public global::Ideogram.GenerateImageIdeogramV4Response? Type349 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV4RequestRenderingSpeed? Type350 { get; set; } + public global::Ideogram.GenerateImageIdeogramV4Request? Type350 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV4CustomModelResponse? Type351 { get; set; } + public global::Ideogram.GenerateImageIdeogramV4RequestRenderingSpeed? Type351 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV4CustomModelRequest? Type352 { get; set; } + public global::Ideogram.GenerateImageIdeogramV4CustomModelResponse? Type352 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type353 { get; set; } + public global::Ideogram.GenerateImageIdeogramV4CustomModelRequest? Type353 { get; set; } /// /// /// - public global::Ideogram.StackedCustomModel? Type354 { get; set; } + public global::System.Collections.Generic.IList? Type354 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV4CustomModelRequestRenderingSpeed? Type355 { get; set; } + public global::Ideogram.StackedCustomModel? Type355 { get; set; } /// /// /// - public double? Type356 { get; set; } + public global::Ideogram.GenerateImageIdeogramV4CustomModelRequestRenderingSpeed? Type356 { get; set; } /// /// /// - public global::Ideogram.RemixImageIdeogramV3Response? Type357 { get; set; } + public double? Type357 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type358 { get; set; } + public global::Ideogram.RemixImageIdeogramV3Response? Type358 { get; set; } /// /// /// - public global::Ideogram.RemixedImageObject? Type359 { get; set; } + public global::System.Collections.Generic.IList? Type359 { get; set; } /// /// /// - public global::Ideogram.RemixImageIdeogramV3Request? Type360 { get; set; } + public global::Ideogram.RemixedImageObject? Type360 { get; set; } /// /// /// - public global::Ideogram.RemixImageIdeogramV3RequestRenderingSpeed? Type361 { get; set; } + public global::Ideogram.RemixImageIdeogramV3Request? Type361 { get; set; } /// /// /// - public global::Ideogram.RemixImageIdeogramV3CustomModelResponse? Type362 { get; set; } + public global::Ideogram.RemixImageIdeogramV3RequestRenderingSpeed? Type362 { get; set; } /// /// /// - public global::Ideogram.RemixImageIdeogramV3CustomModelRequest? Type363 { get; set; } + public global::Ideogram.RemixImageIdeogramV3CustomModelResponse? Type363 { get; set; } /// /// /// - public global::Ideogram.RemixImageIdeogramV3CustomModelRequestRenderingSpeed? Type364 { get; set; } + public global::Ideogram.RemixImageIdeogramV3CustomModelRequest? Type364 { get; set; } /// /// /// - public global::Ideogram.RemixImageIdeogramV4Response? Type365 { get; set; } + public global::Ideogram.RemixImageIdeogramV3CustomModelRequestRenderingSpeed? Type365 { get; set; } /// /// /// - public global::Ideogram.RemixImageIdeogramV4Request? Type366 { get; set; } + public global::Ideogram.RemixImageIdeogramV4Response? Type366 { get; set; } /// /// /// - public global::Ideogram.RemixImageIdeogramV4RequestRenderingSpeed? Type367 { get; set; } + public global::Ideogram.RemixImageIdeogramV4Request? Type367 { get; set; } /// /// /// - public global::Ideogram.RemixImageIdeogramV3CharacterResponse? Type368 { get; set; } + public global::Ideogram.RemixImageIdeogramV4RequestRenderingSpeed? Type368 { get; set; } /// /// /// - public global::Ideogram.RemixImageIdeogramV3CharacterRequest? Type369 { get; set; } + public global::Ideogram.RemixImageIdeogramV3CharacterResponse? Type369 { get; set; } /// /// /// - public global::Ideogram.RemixImageIdeogramV3CharacterRequestRenderingSpeed? Type370 { get; set; } + public global::Ideogram.RemixImageIdeogramV3CharacterRequest? Type370 { get; set; } /// /// /// - public global::Ideogram.RemixImageIdeogramV3CharacterRequestStyleType? Type371 { get; set; } + public global::Ideogram.RemixImageIdeogramV3CharacterRequestRenderingSpeed? Type371 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV3TransparentResponse? Type372 { get; set; } + public global::Ideogram.RemixImageIdeogramV3CharacterRequestStyleType? Type372 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV3TransparentRequest? Type373 { get; set; } + public global::Ideogram.GenerateImageIdeogramV3TransparentResponse? Type373 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV3TransparentRequestUpscaleFactor? Type374 { get; set; } + public global::Ideogram.GenerateImageIdeogramV3TransparentRequest? Type374 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV3TransparentRequestRenderingSpeed? Type375 { get; set; } + public global::Ideogram.GenerateImageIdeogramV3TransparentRequestUpscaleFactor? Type375 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV4TransparentResponse? Type376 { get; set; } + public global::Ideogram.GenerateImageIdeogramV3TransparentRequestRenderingSpeed? Type376 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV4TransparentRequest? Type377 { get; set; } + public global::Ideogram.GenerateImageIdeogramV4TransparentResponse? Type377 { get; set; } /// /// /// - public global::Ideogram.IdeogramV4AspectRatio? Type378 { get; set; } + public global::Ideogram.GenerateImageIdeogramV4TransparentRequest? Type378 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV4TransparentRequestOutputResolution? Type379 { get; set; } + public global::Ideogram.IdeogramV4AspectRatio? Type379 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV4TransparentRequestRenderingSpeed? Type380 { get; set; } + public global::Ideogram.GenerateImageIdeogramV4TransparentRequestOutputResolution? Type380 { get; set; } /// /// /// - public global::Ideogram.GenerateImagePImageIdeogramResponse? Type381 { get; set; } + public global::Ideogram.GenerateImageIdeogramV4TransparentRequestRenderingSpeed? Type381 { get; set; } /// /// /// - public global::Ideogram.GenerateImagePImageIdeogramRequest? Type382 { get; set; } + public global::Ideogram.GenerateImagePImageIdeogramResponse? Type382 { get; set; } /// /// /// - public global::Ideogram.GenerationQuality? Type383 { get; set; } + public global::Ideogram.GenerateImagePImageIdeogramRequest? Type383 { get; set; } /// /// /// - public global::Ideogram.GenerateImagePImageIdeogramRequestResolution? Type384 { get; set; } + public global::Ideogram.GenerationQuality? Type384 { get; set; } /// /// /// - public global::Ideogram.GenerateImageZImageResponse? Type385 { get; set; } + public global::Ideogram.GenerateImagePImageIdeogramRequestResolution? Type385 { get; set; } /// /// /// - public global::Ideogram.GenerateImageZImageRequest? Type386 { get; set; } + public global::Ideogram.GenerateImageZImageResponse? Type386 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogram45Response? Type387 { get; set; } + public global::Ideogram.GenerateImageZImageRequest? Type387 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogram45Request? Type388 { get; set; } + public global::Ideogram.GenerateImageIdeogram45Response? Type388 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogram45RequestRenderingSpeed? Type389 { get; set; } + public global::Ideogram.GenerateImageIdeogram45Request? Type389 { get; set; } /// /// /// - public global::Ideogram.GenerateImageNanoBanana2Response? Type390 { get; set; } + public global::Ideogram.GenerateImageIdeogram45RequestRenderingSpeed? Type390 { get; set; } /// /// /// - public global::Ideogram.GenerateImageNanoBanana2Request? Type391 { get; set; } + public global::Ideogram.PreciseEditImageIdeogram45Response? Type391 { get; set; } /// /// /// - public global::Ideogram.GenerateImageNanoBanana2RequestResolutionTier? Type392 { get; set; } + public global::Ideogram.PreciseEditImageIdeogram45Request? Type392 { get; set; } /// /// /// - public global::Ideogram.GenerateImageNanoBananaProResponse? Type393 { get; set; } + public global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeed? Type393 { get; set; } /// /// /// - public global::Ideogram.GenerateImageNanoBananaProRequest? Type394 { get; set; } + public global::Ideogram.GenerateImageNanoBanana2Response? Type394 { get; set; } /// /// /// - public global::Ideogram.GenerateImageNanoBananaProRequestResolutionTier? Type395 { get; set; } + public global::Ideogram.GenerateImageNanoBanana2Request? Type395 { get; set; } /// /// /// - public global::Ideogram.GenerateImageGptImage2Response? Type396 { get; set; } + public global::Ideogram.GenerateImageNanoBanana2RequestResolutionTier? Type396 { get; set; } /// /// /// - public global::Ideogram.GenerateImageGptImage2Request? Type397 { get; set; } + public global::Ideogram.GenerateImageNanoBananaProResponse? Type397 { get; set; } /// /// /// - public global::Ideogram.GenerateImageGptImage25FlareResponse? Type398 { get; set; } + public global::Ideogram.GenerateImageNanoBananaProRequest? Type398 { get; set; } /// /// /// - public global::Ideogram.GenerateImageGptImage25FlareRequest? Type399 { get; set; } + public global::Ideogram.GenerateImageNanoBananaProRequestResolutionTier? Type399 { get; set; } /// /// /// - public global::Ideogram.GenerateImageGptImage25FlareRequestBackground? Type400 { get; set; } + public global::Ideogram.GenerateImageGptImage2Response? Type400 { get; set; } /// /// /// - public global::Ideogram.GenerateImageGptImage25FlareRequestQuality? Type401 { get; set; } + public global::Ideogram.GenerateImageGptImage2Request? Type401 { get; set; } /// /// /// - public global::Ideogram.GenerateImageGptImage25SunburstResponse? Type402 { get; set; } + public global::Ideogram.GenerateImageGptImage25FlareResponse? Type402 { get; set; } /// /// /// - public global::Ideogram.GenerateImageGptImage25SunburstRequest? Type403 { get; set; } + public global::Ideogram.GenerateImageGptImage25FlareRequest? Type403 { get; set; } /// /// /// - public global::Ideogram.GenerateImageGptImage25SunburstRequestBackground? Type404 { get; set; } + public global::Ideogram.GenerateImageGptImage25FlareRequestBackground? Type404 { get; set; } /// /// /// - public global::Ideogram.GenerateImageGptImage25SunburstRequestQuality? Type405 { get; set; } + public global::Ideogram.GenerateImageGptImage25FlareRequestQuality? Type405 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV2Response? Type406 { get; set; } + public global::Ideogram.GenerateImageGptImage25SunburstResponse? Type406 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV2Request? Type407 { get; set; } + public global::Ideogram.GenerateImageGptImage25SunburstRequest? Type407 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV2RequestRenderingSpeed? Type408 { get; set; } + public global::Ideogram.GenerateImageGptImage25SunburstRequestBackground? Type408 { get; set; } /// /// /// - public global::Ideogram.IdeogramV2StyleType? Type409 { get; set; } + public global::Ideogram.GenerateImageGptImage25SunburstRequestQuality? Type409 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV2AResponse? Type410 { get; set; } + public global::Ideogram.GenerateImageIdeogramV2Response? Type410 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV2ARequest? Type411 { get; set; } + public global::Ideogram.GenerateImageIdeogramV2Request? Type411 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV2ARequestRenderingSpeed? Type412 { get; set; } + public global::Ideogram.GenerateImageIdeogramV2RequestRenderingSpeed? Type412 { get; set; } /// /// /// - public global::Ideogram.InpaintImageIdeogramV3Response? Type413 { get; set; } + public global::Ideogram.IdeogramV2StyleType? Type413 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type414 { get; set; } + public global::Ideogram.GenerateImageIdeogramV2AResponse? Type414 { get; set; } /// /// /// - public global::Ideogram.InpaintedImageObject? Type415 { get; set; } + public global::Ideogram.GenerateImageIdeogramV2ARequest? Type415 { get; set; } /// /// /// - public global::Ideogram.InpaintImageIdeogramV3Request? Type416 { get; set; } + public global::Ideogram.GenerateImageIdeogramV2ARequestRenderingSpeed? Type416 { get; set; } /// /// /// - public global::Ideogram.InpaintImageIdeogramV3RequestRenderingSpeed? Type417 { get; set; } + public global::Ideogram.InpaintImageIdeogramV3Response? Type417 { get; set; } /// /// /// - public global::Ideogram.InpaintImageIdeogramV3CustomModelResponse? Type418 { get; set; } + public global::System.Collections.Generic.IList? Type418 { get; set; } /// /// /// - public global::Ideogram.InpaintImageIdeogramV3CustomModelRequest? Type419 { get; set; } + public global::Ideogram.InpaintedImageObject? Type419 { get; set; } /// /// /// - public global::Ideogram.InpaintImageIdeogramV3CustomModelRequestRenderingSpeed? Type420 { get; set; } + public global::Ideogram.InpaintImageIdeogramV3Request? Type420 { get; set; } /// /// /// - public global::Ideogram.ReframeImageIdeogramV3Response? Type421 { get; set; } + public global::Ideogram.InpaintImageIdeogramV3RequestRenderingSpeed? Type421 { get; set; } /// /// /// - public global::Ideogram.ReframeImageIdeogramV3Request? Type422 { get; set; } + public global::Ideogram.InpaintImageIdeogramV3CustomModelResponse? Type422 { get; set; } /// /// /// - public global::Ideogram.ReframeImageIdeogramV3RequestRenderingSpeed? Type423 { get; set; } + public global::Ideogram.InpaintImageIdeogramV3CustomModelRequest? Type423 { get; set; } /// /// /// - public global::Ideogram.ReframeImageNanoBanana2Response? Type424 { get; set; } + public global::Ideogram.InpaintImageIdeogramV3CustomModelRequestRenderingSpeed? Type424 { get; set; } /// /// /// - public global::Ideogram.ReframeImageNanoBanana2Request? Type425 { get; set; } + public global::Ideogram.ReframeImageIdeogramV3Response? Type425 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV3CharacterResponse? Type426 { get; set; } + public global::Ideogram.ReframeImageIdeogramV3Request? Type426 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV3CharacterRequest? Type427 { get; set; } + public global::Ideogram.ReframeImageIdeogramV3RequestRenderingSpeed? Type427 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV3CharacterRequestRenderingSpeed? Type428 { get; set; } + public global::Ideogram.ReframeImageNanoBanana2Response? Type428 { get; set; } /// /// /// - public global::Ideogram.GenerateImageIdeogramV3CharacterRequestStyleType? Type429 { get; set; } + public global::Ideogram.ReframeImageNanoBanana2Request? Type429 { get; set; } /// /// /// - public global::Ideogram.InpaintImageIdeogramV3CharacterResponse? Type430 { get; set; } + public global::Ideogram.GenerateImageIdeogramV3CharacterResponse? Type430 { get; set; } /// /// /// - public global::Ideogram.InpaintImageIdeogramV3CharacterRequest? Type431 { get; set; } + public global::Ideogram.GenerateImageIdeogramV3CharacterRequest? Type431 { get; set; } /// /// /// - public global::Ideogram.InpaintImageIdeogramV3CharacterRequestRenderingSpeed? Type432 { get; set; } + public global::Ideogram.GenerateImageIdeogramV3CharacterRequestRenderingSpeed? Type432 { get; set; } /// /// /// - public global::Ideogram.InpaintImageIdeogramV3CharacterRequestStyleType? Type433 { get; set; } + public global::Ideogram.GenerateImageIdeogramV3CharacterRequestStyleType? Type433 { get; set; } /// /// /// - public global::Ideogram.GenerateImageV2AutoResponse? Type434 { get; set; } + public global::Ideogram.InpaintImageIdeogramV3CharacterResponse? Type434 { get; set; } /// /// /// - public global::Ideogram.GenerateImageV2AutoRequest? Type435 { get; set; } + public global::Ideogram.InpaintImageIdeogramV3CharacterRequest? Type435 { get; set; } /// /// /// - public global::Ideogram.GenerateImageV2AutoRequestResolutionTier? Type436 { get; set; } + public global::Ideogram.InpaintImageIdeogramV3CharacterRequestRenderingSpeed? Type436 { get; set; } /// /// /// - public global::Ideogram.ToolRemixResponse? Type437 { get; set; } + public global::Ideogram.InpaintImageIdeogramV3CharacterRequestStyleType? Type437 { get; set; } /// /// /// - public global::Ideogram.ToolRemixRequest? Type438 { get; set; } + public global::Ideogram.GenerateImageV2AutoResponse? Type438 { get; set; } /// /// /// - public global::Ideogram.ToolRemixRequestResolutionTier? Type439 { get; set; } + public global::Ideogram.GenerateImageV2AutoRequest? Type439 { get; set; } /// /// /// - public global::Ideogram.ResizeAdImageRequest? Type440 { get; set; } + public global::Ideogram.GenerateImageV2AutoRequestResolutionTier? Type440 { get; set; } /// /// /// - public global::Ideogram.ResizeAdImageRequestResolution? Type441 { get; set; } + public global::Ideogram.ToolRemixResponse? Type441 { get; set; } /// /// /// - public global::Ideogram.ResizeAdImageQuality? Type442 { get; set; } + public global::Ideogram.ToolRemixRequest? Type442 { get; set; } /// /// /// - public global::Ideogram.WebhookSigningJwks? Type443 { get; set; } + public global::Ideogram.ToolRemixRequestResolutionTier? Type443 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type444 { get; set; } + public global::Ideogram.ResizeAdImageRequest? Type444 { get; set; } /// /// /// - public global::Ideogram.WebhookSigningJwk? Type445 { get; set; } + public global::Ideogram.ResizeAdImageRequestResolution? Type445 { get; set; } /// /// /// - public global::Ideogram.ProvenanceVerifyResponse? Type446 { get; set; } + public global::Ideogram.ResizeAdImageQuality? Type446 { get; set; } /// /// /// - public global::Ideogram.ProvenanceVerifyResponseValidationState? Type447 { get; set; } + public global::Ideogram.WebhookSigningJwks? Type447 { get; set; } /// /// /// - public global::Ideogram.ProvenanceVerifyRequest? Type448 { get; set; } + public global::System.Collections.Generic.IList? Type448 { get; set; } /// /// /// - public global::Ideogram.ManageApiSubscriptionResponse? Type449 { get; set; } + public global::Ideogram.WebhookSigningJwk? Type449 { get; set; } /// /// /// - public global::Ideogram.MetronomeLinks? Type450 { get; set; } + public global::Ideogram.ProvenanceVerifyResponse? Type450 { get; set; } /// /// /// - public global::Ideogram.RechargeSettingsResponse? Type451 { get; set; } + public global::Ideogram.ProvenanceVerifyResponseValidationState? Type451 { get; set; } /// /// /// - public global::Ideogram.Price? Type452 { get; set; } + public global::Ideogram.ProvenanceVerifyRequest? Type452 { get; set; } /// /// /// - public global::Ideogram.RechargeSettings? Type453 { get; set; } + public global::Ideogram.ManageApiSubscriptionResponse? Type453 { get; set; } /// /// /// - public global::Ideogram.PostApiSubscriptionResponse? Type454 { get; set; } + public global::Ideogram.MetronomeLinks? Type454 { get; set; } /// /// /// - public global::Ideogram.PostApiSubscriptionError? Type455 { get; set; } + public global::Ideogram.RechargeSettingsResponse? Type455 { get; set; } /// /// /// - public global::Ideogram.PostApiSubscriptionRequest? Type456 { get; set; } + public global::Ideogram.Price? Type456 { get; set; } /// /// /// - public global::Ideogram.ManageApiCreditSummaryResponse? Type457 { get; set; } + public global::Ideogram.RechargeSettings? Type457 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type458 { get; set; } + public global::Ideogram.PostApiSubscriptionResponse? Type458 { get; set; } /// /// /// - public global::Ideogram.CreditGrant? Type459 { get; set; } + public global::Ideogram.PostApiSubscriptionError? Type459 { get; set; } /// /// /// - public global::Ideogram.PostApiReactivateResponse? Type460 { get; set; } + public global::Ideogram.PostApiSubscriptionRequest? Type460 { get; set; } /// /// /// - public global::Ideogram.GetApiKeysResponse? Type461 { get; set; } + public global::Ideogram.ManageApiCreditSummaryResponse? Type461 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type462 { get; set; } + public global::System.Collections.Generic.IList? Type462 { get; set; } /// /// /// - public global::Ideogram.RedactedApiKey? Type463 { get; set; } + public global::Ideogram.CreditGrant? Type463 { get; set; } /// /// /// - public global::Ideogram.PostApiKeyResponse? Type464 { get; set; } + public global::Ideogram.PostApiReactivateResponse? Type464 { get; set; } /// /// /// - public global::Ideogram.CreateApiKeyRequest? Type465 { get; set; } + public global::Ideogram.GetApiKeysResponse? Type465 { get; set; } /// /// /// - public global::Ideogram.ApiProfileApiKey? Type466 { get; set; } + public global::System.Collections.Generic.IList? Type466 { get; set; } /// /// /// - public global::Ideogram.ApiKeyStatus? Type467 { get; set; } + public global::Ideogram.RedactedApiKey? Type467 { get; set; } /// /// /// - public global::Ideogram.PatchApiKeyRequest? Type468 { get; set; } + public global::Ideogram.PostApiKeyResponse? Type468 { get; set; } /// /// /// - public global::Ideogram.ManageApiStripeSubscriptionResponse? Type469 { get; set; } + public global::Ideogram.CreateApiKeyRequest? Type469 { get; set; } /// /// /// - public global::Ideogram.ManageApiPaymentResponse? Type470 { get; set; } + public global::Ideogram.ApiProfileApiKey? Type470 { get; set; } /// /// /// - public global::Ideogram.GetApiTermsResponse? Type471 { get; set; } + public global::Ideogram.ApiKeyStatus? Type471 { get; set; } /// /// /// - public global::Ideogram.ApiTerms? Type472 { get; set; } + public global::Ideogram.PatchApiKeyRequest? Type472 { get; set; } /// /// /// - public global::Ideogram.PostApiTermsRequest? Type473 { get; set; } + public global::Ideogram.ManageApiStripeSubscriptionResponse? Type473 { get; set; } /// /// /// - public global::Ideogram.PostAddCreditsResponse? Type474 { get; set; } + public global::Ideogram.ManageApiPaymentResponse? Type474 { get; set; } /// /// /// - public global::Ideogram.PostAddCreditsError? Type475 { get; set; } + public global::Ideogram.GetApiTermsResponse? Type475 { get; set; } /// /// /// - public global::Ideogram.PostAddCreditsRequest? Type476 { get; set; } + public global::Ideogram.ApiTerms? Type476 { get; set; } /// /// /// - public global::Ideogram.GetUserCreditsResponse? Type477 { get; set; } + public global::Ideogram.PostApiTermsRequest? Type477 { get; set; } /// /// /// - public global::Ideogram.SpendCommitInfoResponse? Type478 { get; set; } + public global::Ideogram.PostAddCreditsResponse? Type478 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type479 { get; set; } + public global::Ideogram.PostAddCreditsError? Type479 { get; set; } /// /// /// - public global::Ideogram.SpendCommitInfo? Type480 { get; set; } + public global::Ideogram.PostAddCreditsRequest? Type480 { get; set; } /// /// /// - public global::Ideogram.GetUsageInfoResponse? Type481 { get; set; } + public global::Ideogram.GetUserCreditsResponse? Type481 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type482 { get; set; } + public global::Ideogram.SpendCommitInfoResponse? Type482 { get; set; } /// /// /// - public global::Ideogram.UsageSegment? Type483 { get; set; } + public global::System.Collections.Generic.IList? Type483 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type484 { get; set; } + public global::Ideogram.SpendCommitInfo? Type484 { get; set; } /// /// /// - public global::Ideogram.ToolUsage? Type485 { get; set; } + public global::Ideogram.GetUsageInfoResponse? Type485 { get; set; } /// /// /// - public global::Ideogram.ToolType? Type486 { get; set; } + public global::System.Collections.Generic.IList? Type486 { get; set; } /// /// /// - public global::Ideogram.ModelVersion? Type487 { get; set; } + public global::Ideogram.UsageSegment? Type487 { get; set; } /// /// /// - public global::Ideogram.SegmentBy? Type488 { get; set; } + public global::System.Collections.Generic.IList? Type488 { get; set; } /// /// /// - public global::Ideogram.UsageSource? Type489 { get; set; } + public global::Ideogram.ToolUsage? Type489 { get; set; } /// /// /// - public global::Ideogram.GetApiProfilesResponse? Type490 { get; set; } + public global::Ideogram.ToolType? Type490 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type491 { get; set; } + public global::Ideogram.ModelVersion? Type491 { get; set; } /// /// /// - public global::Ideogram.ApiProfile? Type492 { get; set; } + public global::Ideogram.SegmentBy? Type492 { get; set; } /// /// /// - public global::Ideogram.ApiProfileType? Type493 { get; set; } + public global::Ideogram.UsageSource? Type493 { get; set; } /// /// /// - public global::Ideogram.ApiProfileRole? Type494 { get; set; } + public global::Ideogram.GetApiProfilesResponse? Type494 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type495 { get; set; } + public global::System.Collections.Generic.IList? Type495 { get; set; } /// /// /// - public global::Ideogram.UpdateOrganizationApiPropertiesResponse? Type496 { get; set; } + public global::Ideogram.ApiProfile? Type496 { get; set; } /// /// /// - public global::Ideogram.UpdateOrganizationApiPropertiesRequest? Type497 { get; set; } + public global::Ideogram.ApiProfileType? Type497 { get; set; } /// /// /// - public global::Ideogram.GetApiOrganizationUserSuggestionsResponse? Type498 { get; set; } + public global::Ideogram.ApiProfileRole? Type498 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type499 { get; set; } + public global::System.Collections.Generic.IList? Type499 { get; set; } /// /// /// - public global::Ideogram.ApiOrganizationUserSuggestion? Type500 { get; set; } + public global::Ideogram.UpdateOrganizationApiPropertiesResponse? Type500 { get; set; } /// /// /// - public global::Ideogram.GetOrganizationMembersResponse? Type501 { get; set; } + public global::Ideogram.UpdateOrganizationApiPropertiesRequest? Type501 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type502 { get; set; } + public global::Ideogram.GetApiOrganizationUserSuggestionsResponse? Type502 { get; set; } /// /// /// - public global::Ideogram.OrganizationMember? Type503 { get; set; } + public global::System.Collections.Generic.IList? Type503 { get; set; } /// /// /// - public global::Ideogram.CreateApiKeyResponse? Type504 { get; set; } + public global::Ideogram.ApiOrganizationUserSuggestion? Type504 { get; set; } /// /// /// - public global::Ideogram.GetApiKeysV2Response? Type505 { get; set; } + public global::Ideogram.GetOrganizationMembersResponse? Type505 { get; set; } /// /// /// - public global::Ideogram.OrganizationMemberOperationResponse? Type506 { get; set; } + public global::System.Collections.Generic.IList? Type506 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type507 { get; set; } + public global::Ideogram.OrganizationMember? Type507 { get; set; } /// /// /// - public global::Ideogram.OrganizationMemberOperationResult? Type508 { get; set; } + public global::Ideogram.CreateApiKeyResponse? Type508 { get; set; } /// /// /// - public global::Ideogram.AddOrganizationMembersRequest? Type509 { get; set; } + public global::Ideogram.GetApiKeysV2Response? Type509 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type510 { get; set; } + public global::Ideogram.OrganizationMemberOperationResponse? Type510 { get; set; } /// /// /// - public global::Ideogram.LiteOrganizationMember? Type511 { get; set; } + public global::System.Collections.Generic.IList? Type511 { get; set; } /// /// /// - public global::Ideogram.RemoveOrganizationMembersRequest? Type512 { get; set; } + public global::Ideogram.OrganizationMemberOperationResult? Type512 { get; set; } /// /// /// - public global::Ideogram.PromoteOrganizationAdminsRequest? Type513 { get; set; } + public global::Ideogram.AddOrganizationMembersRequest? Type513 { get; set; } /// /// /// - public global::Ideogram.DemoteOrganizationAdminsRequest? Type514 { get; set; } + public global::System.Collections.Generic.IList? Type514 { get; set; } /// /// /// - public global::Ideogram.CancelOrganizationInviteRequest? Type515 { get; set; } + public global::Ideogram.LiteOrganizationMember? Type515 { get; set; } /// /// /// - public global::Ideogram.ResendOrganizationInviteRequest? Type516 { get; set; } + public global::Ideogram.RemoveOrganizationMembersRequest? Type516 { get; set; } /// /// /// - public global::Ideogram.ListOrganizationInvoicesResponse? Type517 { get; set; } + public global::Ideogram.PromoteOrganizationAdminsRequest? Type517 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type518 { get; set; } + public global::Ideogram.DemoteOrganizationAdminsRequest? Type518 { get; set; } /// /// /// - public global::Ideogram.Invoice? Type519 { get; set; } + public global::Ideogram.CancelOrganizationInviteRequest? Type519 { get; set; } /// /// /// - public global::Ideogram.InvoiceStatus? Type520 { get; set; } + public global::Ideogram.ResendOrganizationInviteRequest? Type520 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type521 { get; set; } + public global::Ideogram.ListOrganizationInvoicesResponse? Type521 { get; set; } /// /// /// - public global::Ideogram.InvoiceLineItem? Type522 { get; set; } + public global::System.Collections.Generic.IList? Type522 { get; set; } /// /// /// - public global::Ideogram.GetOrganizationBillingPortalResponse? Type523 { get; set; } + public global::Ideogram.Invoice? Type523 { get; set; } /// /// /// - public global::Ideogram.ListDatasetsResponse? Type524 { get; set; } + public global::Ideogram.InvoiceStatus? Type524 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type525 { get; set; } + public global::System.Collections.Generic.IList? Type525 { get; set; } /// /// /// - public global::Ideogram.Dataset? Type526 { get; set; } + public global::Ideogram.InvoiceLineItem? Type526 { get; set; } /// /// /// - public global::Ideogram.CreateDatasetRequest? Type527 { get; set; } + public global::Ideogram.GetOrganizationBillingPortalResponse? Type527 { get; set; } /// /// /// - public global::Ideogram.GetDatasetResponse? Type528 { get; set; } + public global::Ideogram.ListDatasetsResponse? Type528 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type529 { get; set; } + public global::System.Collections.Generic.IList? Type529 { get; set; } /// /// /// - public global::Ideogram.DatasetFile? Type530 { get; set; } + public global::Ideogram.Dataset? Type530 { get; set; } /// /// /// - public global::Ideogram.UploadDatasetAssetsResponse? Type531 { get; set; } + public global::Ideogram.CreateDatasetRequest? Type531 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type532 { get; set; } + public global::Ideogram.GetDatasetResponse? Type532 { get; set; } /// /// /// - public global::Ideogram.DatasetUploadSucceededAsset? Type533 { get; set; } + public global::System.Collections.Generic.IList? Type533 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type534 { get; set; } + public global::Ideogram.DatasetFile? Type534 { get; set; } /// /// /// - public global::Ideogram.DatasetUploadFailedAsset? Type535 { get; set; } + public global::Ideogram.UploadDatasetAssetsResponse? Type535 { get; set; } /// /// /// - public global::Ideogram.DatasetAssetFailureReason? Type536 { get; set; } + public global::System.Collections.Generic.IList? Type536 { get; set; } /// /// /// - public global::Ideogram.UploadDatasetAssetsRequest? Type537 { get; set; } + public global::Ideogram.DatasetUploadSucceededAsset? Type537 { get; set; } /// /// /// - public global::Ideogram.TrainDatasetModelResponse? Type538 { get; set; } + public global::System.Collections.Generic.IList? Type538 { get; set; } /// /// /// - public global::Ideogram.TrainDatasetModelRequest? Type539 { get; set; } + public global::Ideogram.DatasetUploadFailedAsset? Type539 { get; set; } /// /// /// - public global::Ideogram.ListModelsResponse? Type540 { get; set; } + public global::Ideogram.DatasetAssetFailureReason? Type540 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type541 { get; set; } + public global::Ideogram.UploadDatasetAssetsRequest? Type541 { get; set; } /// /// /// - public global::Ideogram.CustomModel? Type542 { get; set; } + public global::Ideogram.TrainDatasetModelResponse? Type542 { get; set; } /// /// /// - public global::Ideogram.ModelStatus? Type543 { get; set; } + public global::Ideogram.TrainDatasetModelRequest? Type543 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type544 { get; set; } + public global::Ideogram.ListModelsResponse? Type544 { get; set; } /// /// /// - public global::Ideogram.TrainingRun? Type545 { get; set; } + public global::System.Collections.Generic.IList? Type545 { get; set; } /// /// /// - public global::Ideogram.TrainingRunStatus? Type546 { get; set; } + public global::Ideogram.CustomModel? Type546 { get; set; } /// /// /// - public global::Ideogram.GetModelResponse? Type547 { get; set; } + public global::Ideogram.ModelStatus? Type547 { get; set; } /// /// /// - public global::Ideogram.TrainModelV3Request? Type548 { get; set; } + public global::System.Collections.Generic.IList? Type548 { get; set; } /// /// /// - public global::Ideogram.TrainModelV3AdvancedRequest? Type549 { get; set; } + public global::Ideogram.TrainingRun? Type549 { get; set; } /// /// /// - public global::Ideogram.TrainModelV4Request? Type550 { get; set; } + public global::Ideogram.TrainingRunStatus? Type550 { get; set; } /// /// /// - public global::Ideogram.TrainModelV4AdvancedRequest? Type551 { get; set; } + public global::Ideogram.GetModelResponse? Type551 { get; set; } /// /// /// - public global::Ideogram.PublishMiniAppResponse? Type552 { get; set; } + public global::Ideogram.TrainModelV3Request? Type552 { get; set; } /// /// /// - public global::Ideogram.PublishMiniAppRequest? Type553 { get; set; } + public global::Ideogram.TrainModelV3AdvancedRequest? Type553 { get; set; } /// /// /// - public global::Ideogram.PublishMiniAppRequestEmbed? Type554 { get; set; } + public global::Ideogram.TrainModelV4Request? Type554 { get; set; } /// /// /// - public object? Type555 { get; set; } + public global::Ideogram.TrainModelV4AdvancedRequest? Type555 { get; set; } /// /// /// - public global::Ideogram.MiniAppArtwork? Type556 { get; set; } + public global::Ideogram.PublishMiniAppResponse? Type556 { get; set; } /// /// /// - public global::Ideogram.PublishMiniAppPreviewResponse? Type557 { get; set; } + public global::Ideogram.PublishMiniAppRequest? Type557 { get; set; } /// /// /// - public global::Ideogram.PublishMiniAppPreviewRequest? Type558 { get; set; } + public global::Ideogram.PublishMiniAppRequestEmbed? Type558 { get; set; } /// /// /// - public global::Ideogram.PublishMiniAppPreviewRequestEmbed? Type559 { get; set; } + public object? Type559 { get; set; } /// /// /// - public global::Ideogram.UnpublishMiniAppPreviewResponse? Type560 { get; set; } + public global::Ideogram.MiniAppArtwork? Type560 { get; set; } /// /// /// - public global::Ideogram.GetStaleMiniAppPreviewsResponse? Type561 { get; set; } + public global::Ideogram.PublishMiniAppPreviewResponse? Type561 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type562 { get; set; } + public global::Ideogram.PublishMiniAppPreviewRequest? Type562 { get; set; } /// /// /// - public global::Ideogram.MiniAppMarketingProjectionEntry? Type563 { get; set; } + public global::Ideogram.PublishMiniAppPreviewRequestEmbed? Type563 { get; set; } /// /// /// - public global::Ideogram.MiniAppMarketingProjectionEntryEmbed? Type564 { get; set; } + public global::Ideogram.UnpublishMiniAppPreviewResponse? Type564 { get; set; } /// /// /// - public global::Ideogram.GetIntegrationsResponse? Type565 { get; set; } + public global::Ideogram.GetStaleMiniAppPreviewsResponse? Type565 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type566 { get; set; } + public global::System.Collections.Generic.IList? Type566 { get; set; } /// /// /// - public global::Ideogram.IntegrationType? Type567 { get; set; } + public global::Ideogram.MiniAppMarketingProjectionEntry? Type567 { get; set; } /// /// /// - public global::Ideogram.IntegrationErrorResponse? Type568 { get; set; } + public global::Ideogram.MiniAppMarketingProjectionEntryEmbed? Type568 { get; set; } /// /// /// - public global::Ideogram.IntegrationErrorResponseError? Type569 { get; set; } + public global::Ideogram.GetIntegrationsResponse? Type569 { get; set; } /// /// /// - public global::Ideogram.IntegrationAssetSearchResponse? Type570 { get; set; } + public global::System.Collections.Generic.IList? Type570 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type571 { get; set; } + public global::Ideogram.IntegrationType? Type571 { get; set; } /// /// /// - public global::Ideogram.IntegrationAsset? Type572 { get; set; } + public global::Ideogram.IntegrationErrorResponse? Type572 { get; set; } /// /// /// - public global::Ideogram.IntegrationAssetDelivery? Type573 { get; set; } + public global::Ideogram.IntegrationErrorResponseError? Type573 { get; set; } /// /// /// - public global::Ideogram.IntegrationAssetSearchRequest? Type574 { get; set; } + public global::Ideogram.IntegrationAssetSearchResponse? Type574 { get; set; } /// /// /// - public global::Ideogram.V4StyleDescription? Type575 { get; set; } + public global::System.Collections.Generic.IList? Type575 { get; set; } /// /// /// - public global::Ideogram.V4CompositionalDeconstruction? Type576 { get; set; } + public global::Ideogram.IntegrationAsset? Type576 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type577 { get; set; } + public global::Ideogram.IntegrationAssetDelivery? Type577 { get; set; } /// /// /// - public global::Ideogram.V4PromptElement? Type578 { get; set; } + public global::Ideogram.IntegrationAssetSearchRequest? Type578 { get; set; } /// /// /// - public global::Ideogram.V4ObjPromptElement? Type579 { get; set; } + public global::Ideogram.V4StyleDescription? Type579 { get; set; } /// /// /// - public global::Ideogram.V4TextPromptElement? Type580 { get; set; } + public global::Ideogram.V4CompositionalDeconstruction? Type580 { get; set; } /// /// /// - public global::Ideogram.V4PromptElementDiscriminator? Type581 { get; set; } + public global::System.Collections.Generic.IList? Type581 { get; set; } /// /// /// - public global::Ideogram.V4PromptElementDiscriminatorType? Type582 { get; set; } + public global::Ideogram.V4PromptElement? Type582 { get; set; } /// /// /// - public global::Ideogram.V4ObjPromptElementType? Type583 { get; set; } + public global::Ideogram.V4ObjPromptElement? Type583 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type584 { get; set; } + public global::Ideogram.V4TextPromptElement? Type584 { get; set; } /// /// /// - public global::Ideogram.V4TextPromptElementType? Type585 { get; set; } + public global::Ideogram.V4PromptElementDiscriminator? Type585 { get; set; } /// /// /// - public global::Ideogram.ColorPaletteWithPresetName? Type586 { get; set; } + public global::Ideogram.V4PromptElementDiscriminatorType? Type586 { get; set; } /// /// /// - public global::Ideogram.ColorPaletteWithMembers? Type587 { get; set; } + public global::Ideogram.V4ObjPromptElementType? Type587 { get; set; } /// /// /// - public global::Ideogram.ColorPalettePresetName? Type588 { get; set; } + public global::System.Collections.Generic.IList? Type588 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type589 { get; set; } + public global::Ideogram.V4TextPromptElementType? Type589 { get; set; } /// /// /// - public global::Ideogram.ColorPaletteMember? Type590 { get; set; } + public global::Ideogram.ColorPaletteWithPresetName? Type590 { get; set; } /// /// /// - public global::Ideogram.VideoObject? Type591 { get; set; } + public global::Ideogram.ColorPaletteWithMembers? Type591 { get; set; } /// /// /// - public global::Ideogram.VideoObjectObjectType? Type592 { get; set; } + public global::Ideogram.ColorPalettePresetName? Type592 { get; set; } /// /// /// - public global::Ideogram.DetectedTextBlockAlignment? Type593 { get; set; } + public global::System.Collections.Generic.IList? Type593 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type594 { get; set; } + public global::Ideogram.ColorPaletteMember? Type594 { get; set; } /// /// /// - public global::Ideogram.DetectedTextBlockFormattingItem? Type595 { get; set; } + public global::Ideogram.VideoObject? Type595 { get; set; } /// /// /// - public global::Ideogram.DetectedTextBlockRole? Type596 { get; set; } + public global::Ideogram.VideoObjectObjectType? Type596 { get; set; } /// /// /// - public global::Ideogram.AssetType? Type597 { get; set; } + public global::Ideogram.DetectedTextBlockAlignment? Type597 { get; set; } /// /// /// - public global::Ideogram.IdeogramColorPaletteWithPresetName? Type598 { get; set; } + public global::System.Collections.Generic.IList? Type598 { get; set; } /// /// /// - public global::Ideogram.IdeogramColorPalettePresetName? Type599 { get; set; } + public global::Ideogram.DetectedTextBlockFormattingItem? Type599 { get; set; } /// /// /// - public global::Ideogram.PostGenerateDesignV4200Response? Type600 { get; set; } + public global::Ideogram.DetectedTextBlockRole? Type600 { get; set; } /// /// /// - public global::Ideogram.PostGenerateDesignV4200ResponseDiscriminator? Type601 { get; set; } + public global::Ideogram.AssetType? Type601 { get; set; } /// /// /// - public global::Ideogram.PostGenerateDesignV4200ResponseDiscriminatorResponseType? Type602 { get; set; } + public global::Ideogram.IdeogramColorPaletteWithPresetName? Type602 { get; set; } /// /// /// - public global::Ideogram.PostInternalTesting200Response? Type603 { get; set; } + public global::Ideogram.IdeogramColorPalettePresetName? Type603 { get; set; } /// /// /// - public global::Ideogram.GenerationResponseDataInnerDiscriminator? Type604 { get; set; } + public global::Ideogram.PostGenerateDesignV4200Response? Type604 { get; set; } /// /// /// - public global::Ideogram.GenerationResponseDataInnerDiscriminatorObjectType? Type605 { get; set; } + public global::Ideogram.PostGenerateDesignV4200ResponseDiscriminator? Type605 { get; set; } /// /// /// - public global::Ideogram.MagicPromptRequestMessagesInnerRole? Type606 { get; set; } + public global::Ideogram.PostGenerateDesignV4200ResponseDiscriminatorResponseType? Type606 { get; set; } /// /// /// - public global::Ideogram.DatasetCoverAssetIdentifier? Type607 { get; set; } + public global::Ideogram.PostInternalTesting200Response? Type607 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type608 { get; set; } + public global::Ideogram.GenerationResponseDataInnerDiscriminator? Type608 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type609 { get; set; } + public global::Ideogram.GenerationResponseDataInnerDiscriminatorObjectType? Type609 { get; set; } /// /// /// - public global::Ideogram.ListCustomModelsScope? Type610 { get; set; } + public global::Ideogram.MagicPromptRequestMessagesInnerRole? Type610 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type611 { get; set; } + public global::Ideogram.DatasetCoverAssetIdentifier? Type611 { get; set; } /// /// /// - public global::Ideogram.GetAccountUsageBucketWidth? Type612 { get; set; } + public global::System.Collections.Generic.IList? Type612 { get; set; } /// /// /// - public global::System.Collections.Generic.IList? Type613 { get; set; } + public global::System.Collections.Generic.IList? Type613 { get; set; } /// /// /// - public global::Ideogram.GetAccountUsageSource? Type614 { get; set; } + public global::Ideogram.ListCustomModelsScope? Type614 { get; set; } + /// + /// + /// + public global::System.Collections.Generic.IList? Type615 { get; set; } + /// + /// + /// + public global::Ideogram.GetAccountUsageBucketWidth? Type616 { get; set; } + /// + /// + /// + public global::System.Collections.Generic.IList? Type617 { get; set; } + /// + /// + /// + public global::Ideogram.GetAccountUsageSource? Type618 { get; set; } /// /// diff --git a/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogram45Request.g.cs b/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogram45Request.g.cs index dee969e..76f90a5 100644 --- a/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogram45Request.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogram45Request.g.cs @@ -5,27 +5,30 @@ namespace Ideogram { /// /// Source images are optional. When supplied, the request becomes an
- /// image-to-image transform: the prompt becomes optional guidance and
- /// `size` defaults to "auto" (derived from the first source). Without
- /// source images a prompt is required. + /// image-to-image transform and `size` defaults to "auto" (derived from
+ /// the first source). A prompt is required either way. ///
public sealed partial class GenerateImageIdeogram45Request { /// - /// The prompt to generate images from. Accepts either natural
+ /// The prompt to generate images from, or the edit instruction to
+ /// apply when source images are supplied. Accepts either natural
/// language or a structured Ideogram 4.0 JSON prompt; the server
- /// detects which was supplied. Required without source images; with
- /// sources it is optional guidance and may be empty. + /// detects which was supplied. ///
[global::System.Text.Json.Serialization.JsonPropertyName("prompt")] - public string? Prompt { get; set; } + [global::System.Text.Json.Serialization.JsonRequired] + public required string Prompt { get; set; } /// - /// Controls magic prompt (automatic prompt rewriting). `auto` (the
- /// default) and `on` rewrite a natural-language prompt, while a
- /// prompt that is already a valid structured JSON prompt is always
- /// consumed directly. `off` disables rewriting entirely: the model
- /// receives your prompt verbatim.
+ /// Controls how a natural-language prompt is prepared. `auto` (the
+ /// default) and `on` rewrite and expand the prompt before
+ /// generation. `off` keeps your wording and only converts the prompt
+ /// into the structured format the model consumes. A prompt that is
+ /// already a valid structured JSON prompt skips magic prompt
+ /// entirely unless `magic_prompt` is `on`. With source images the
+ /// prompt is an edit instruction, and every mode converts it into
+ /// the structured edit contract the model consumes.
/// Default Value: auto ///
[global::System.Text.Json.Serialization.JsonPropertyName("magic_prompt")] @@ -44,17 +47,33 @@ public sealed partial class GenerateImageIdeogram45Request [global::System.Text.Json.Serialization.JsonPropertyName("images")] public global::System.Collections.Generic.IList? Images { get; set; } + /// + /// An optional mask confining the edit to part of the first source image, as raw bytes (multipart requests only; JPEG, PNG, or WEBP, max 25MB). Black marks the area to edit and white the area to preserve; values in between are rounded to whichever is nearer. The mask must have the same width and height as the first source image, and must contain both black and white areas. Requires source images uploaded as raw `images` bytes; masks cannot be combined with `image_asset_identifiers`. The mask is supplied to the model as an additional reference image, so a masked request may carry at most three other source images. Supplying a mask fixes the output to the first source's own size, so `size` is rejected alongside it. + /// + [global::System.Text.Json.Serialization.JsonPropertyName("mask")] + public byte[]? Mask { get; set; } + + /// + /// An optional mask confining the edit to part of the first source image, as raw bytes (multipart requests only; JPEG, PNG, or WEBP, max 25MB). Black marks the area to edit and white the area to preserve; values in between are rounded to whichever is nearer. The mask must have the same width and height as the first source image, and must contain both black and white areas. Requires source images uploaded as raw `images` bytes; masks cannot be combined with `image_asset_identifiers`. The mask is supplied to the model as an additional reference image, so a masked request may carry at most three other source images. Supplying a mask fixes the output to the first source's own size, so `size` is rejected alongside it. + /// + [global::System.Text.Json.Serialization.JsonPropertyName("maskname")] + public string? Maskname { get; set; } + /// /// The output size: "auto" or an exact "WIDTHxHEIGHT".
/// Without source images, an exact size must be one of the supported
/// 1K/2K presets (for example 1024x1024, 2048x2048 or 1440x2880);
/// "auto" or omitted lets the server pick a supported size based on
/// the prompt.
- /// With source images, "auto" (the default) uses the supported
- /// resolution closest to the first source's dimensions, and an exact
- /// size must have both dimensions multiples of 32 and at least 256px,
- /// the total size at most 2048x2048 pixels, and the aspect ratio at
- /// most 6:1.
+ /// With source images, "auto" (the default) returns the output at the
+ /// first source image's own width and height. A source too large for
+ /// the model is scaled down to fit while keeping its exact proportion,
+ /// and a source whose aspect ratio is outside 1:6 to 6:1 is rejected,
+ /// because serving it would mean reshaping an image you did not ask to
+ /// reshape — name an exact size if that is what you want.
+ /// An exact size must have both dimensions multiples of 32 and at least
+ /// 256px, the total size at most 2048x2048 pixels, and the aspect ratio
+ /// at most 6:1. Naming one reshapes the source to it.
/// Pricing is tiered by the resolved output pixels: up to 1024x1024
/// bills as 1K, above that as 2K.
/// Example: 2048x2048 @@ -136,17 +155,20 @@ public sealed partial class GenerateImageIdeogram45Request /// Initializes a new instance of the class. ///
/// - /// The prompt to generate images from. Accepts either natural
+ /// The prompt to generate images from, or the edit instruction to
+ /// apply when source images are supplied. Accepts either natural
/// language or a structured Ideogram 4.0 JSON prompt; the server
- /// detects which was supplied. Required without source images; with
- /// sources it is optional guidance and may be empty. + /// detects which was supplied. /// /// - /// Controls magic prompt (automatic prompt rewriting). `auto` (the
- /// default) and `on` rewrite a natural-language prompt, while a
- /// prompt that is already a valid structured JSON prompt is always
- /// consumed directly. `off` disables rewriting entirely: the model
- /// receives your prompt verbatim.
+ /// Controls how a natural-language prompt is prepared. `auto` (the
+ /// default) and `on` rewrite and expand the prompt before
+ /// generation. `off` keeps your wording and only converts the prompt
+ /// into the structured format the model consumes. A prompt that is
+ /// already a valid structured JSON prompt skips magic prompt
+ /// entirely unless `magic_prompt` is `on`. With source images the
+ /// prompt is an edit instruction, and every mode converts it into
+ /// the structured edit contract the model consumes.
/// Default Value: auto /// /// @@ -155,17 +177,27 @@ public sealed partial class GenerateImageIdeogram45Request /// /// The source images to transform (max 5, max size 25MB per image), as raw bytes; only JPEG, PNG, and WEBP formats are supported. Multipart requests only; ignored if `image_asset_identifiers` is also supplied. /// + /// + /// An optional mask confining the edit to part of the first source image, as raw bytes (multipart requests only; JPEG, PNG, or WEBP, max 25MB). Black marks the area to edit and white the area to preserve; values in between are rounded to whichever is nearer. The mask must have the same width and height as the first source image, and must contain both black and white areas. Requires source images uploaded as raw `images` bytes; masks cannot be combined with `image_asset_identifiers`. The mask is supplied to the model as an additional reference image, so a masked request may carry at most three other source images. Supplying a mask fixes the output to the first source's own size, so `size` is rejected alongside it. + /// + /// + /// An optional mask confining the edit to part of the first source image, as raw bytes (multipart requests only; JPEG, PNG, or WEBP, max 25MB). Black marks the area to edit and white the area to preserve; values in between are rounded to whichever is nearer. The mask must have the same width and height as the first source image, and must contain both black and white areas. Requires source images uploaded as raw `images` bytes; masks cannot be combined with `image_asset_identifiers`. The mask is supplied to the model as an additional reference image, so a masked request may carry at most three other source images. Supplying a mask fixes the output to the first source's own size, so `size` is rejected alongside it. + /// /// /// The output size: "auto" or an exact "WIDTHxHEIGHT".
/// Without source images, an exact size must be one of the supported
/// 1K/2K presets (for example 1024x1024, 2048x2048 or 1440x2880);
/// "auto" or omitted lets the server pick a supported size based on
/// the prompt.
- /// With source images, "auto" (the default) uses the supported
- /// resolution closest to the first source's dimensions, and an exact
- /// size must have both dimensions multiples of 32 and at least 256px,
- /// the total size at most 2048x2048 pixels, and the aspect ratio at
- /// most 6:1.
+ /// With source images, "auto" (the default) returns the output at the
+ /// first source image's own width and height. A source too large for
+ /// the model is scaled down to fit while keeping its exact proportion,
+ /// and a source whose aspect ratio is outside 1:6 to 6:1 is rejected,
+ /// because serving it would mean reshaping an image you did not ask to
+ /// reshape — name an exact size if that is what you want.
+ /// An exact size must have both dimensions multiples of 32 and at least
+ /// 256px, the total size at most 2048x2048 pixels, and the aspect ratio
+ /// at most 6:1. Naming one reshapes the source to it.
/// Pricing is tiered by the resolved output pixels: up to 1024x1024
/// bills as 1K, above that as 2K.
/// Example: 2048x2048 @@ -210,10 +242,12 @@ public sealed partial class GenerateImageIdeogram45Request [global::System.Diagnostics.CodeAnalysis.SetsRequiredMembers] #endif public GenerateImageIdeogram45Request( - string? prompt, + string prompt, global::Ideogram.MagicPromptMode? magicPrompt, global::System.Collections.Generic.IList? imageAssetIdentifiers, global::System.Collections.Generic.IList? images, + byte[]? mask, + string? maskname, string? size, global::Ideogram.GenerateImageIdeogram45RequestRenderingSpeed? renderingSpeed, int? seed, @@ -224,10 +258,12 @@ public GenerateImageIdeogram45Request( bool? @private, string? targetCollectionId) { - this.Prompt = prompt; + this.Prompt = prompt ?? throw new global::System.ArgumentNullException(nameof(prompt)); this.MagicPrompt = magicPrompt; this.ImageAssetIdentifiers = imageAssetIdentifiers; this.Images = images; + this.Mask = mask; + this.Maskname = maskname; this.Size = size; this.RenderingSpeed = renderingSpeed; this.Seed = seed; diff --git a/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogramV2ARequest.g.cs b/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogramV2ARequest.g.cs index fdd0816..86f480b 100644 --- a/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogramV2ARequest.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogramV2ARequest.g.cs @@ -24,11 +24,14 @@ public sealed partial class GenerateImageIdeogramV2ARequest public int? Seed { get; set; } /// - /// The aspect ratio to use for image generation, which determines the image's resolution. Cannot be used in conjunction with resolution. Defaults to 1x1. + /// The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the
+ /// model select a ratio from the prompt; any other value pins the ratio.
+ /// Cannot be combined with `resolution`. Omitting the field is not `auto`:
+ /// it uses `1x1`. ///
[global::System.Text.Json.Serialization.JsonPropertyName("aspect_ratio")] - [global::System.Text.Json.Serialization.JsonConverter(typeof(global::Ideogram.JsonConverters.AspectRatioV3JsonConverter))] - public global::Ideogram.AspectRatioV3? AspectRatio { get; set; } + [global::System.Text.Json.Serialization.JsonConverter(typeof(global::Ideogram.JsonConverters.IdeogramV3AspectRatioJsonConverter))] + public global::Ideogram.IdeogramV3AspectRatio? AspectRatio { get; set; } /// /// The rendering speed to use. `turbo` generates faster at a lower cost, while `quality` prioritizes the highest-quality result.
@@ -119,7 +122,10 @@ public sealed partial class GenerateImageIdeogramV2ARequest /// Example: 12345 /// /// - /// The aspect ratio to use for image generation, which determines the image's resolution. Cannot be used in conjunction with resolution. Defaults to 1x1. + /// The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the
+ /// model select a ratio from the prompt; any other value pins the ratio.
+ /// Cannot be combined with `resolution`. Omitting the field is not `auto`:
+ /// it uses `1x1`. /// /// /// The rendering speed to use. `turbo` generates faster at a lower cost, while `quality` prioritizes the highest-quality result.
@@ -167,7 +173,7 @@ public sealed partial class GenerateImageIdeogramV2ARequest public GenerateImageIdeogramV2ARequest( string prompt, int? seed, - global::Ideogram.AspectRatioV3? aspectRatio, + global::Ideogram.IdeogramV3AspectRatio? aspectRatio, global::Ideogram.GenerateImageIdeogramV2ARequestRenderingSpeed? renderingSpeed, global::Ideogram.MagicPromptMode? magicPrompt, int? numImages, diff --git a/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogramV2Request.g.cs b/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogramV2Request.g.cs index eba425e..446b4c3 100644 --- a/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogramV2Request.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogramV2Request.g.cs @@ -30,11 +30,14 @@ public sealed partial class GenerateImageIdeogramV2Request public int? Seed { get; set; } /// - /// The aspect ratio to use for image generation, which determines the image's resolution. Cannot be used in conjunction with resolution. Defaults to 1x1. + /// The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the
+ /// model select a ratio from the prompt; any other value pins the ratio.
+ /// Cannot be combined with `resolution`. Omitting the field is not `auto`:
+ /// it uses `1x1`. ///
[global::System.Text.Json.Serialization.JsonPropertyName("aspect_ratio")] - [global::System.Text.Json.Serialization.JsonConverter(typeof(global::Ideogram.JsonConverters.AspectRatioV3JsonConverter))] - public global::Ideogram.AspectRatioV3? AspectRatio { get; set; } + [global::System.Text.Json.Serialization.JsonConverter(typeof(global::Ideogram.JsonConverters.IdeogramV3AspectRatioJsonConverter))] + public global::Ideogram.IdeogramV3AspectRatio? AspectRatio { get; set; } /// /// The rendering speed to use. `turbo` generates faster at a lower cost, while `quality` prioritizes the highest-quality result.
@@ -128,7 +131,10 @@ public sealed partial class GenerateImageIdeogramV2Request /// Example: 12345 /// /// - /// The aspect ratio to use for image generation, which determines the image's resolution. Cannot be used in conjunction with resolution. Defaults to 1x1. + /// The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the
+ /// model select a ratio from the prompt; any other value pins the ratio.
+ /// Cannot be combined with `resolution`. Omitting the field is not `auto`:
+ /// it uses `1x1`. /// /// /// The rendering speed to use. `turbo` generates faster at a lower cost, while `quality` prioritizes the highest-quality result.
@@ -177,7 +183,7 @@ public GenerateImageIdeogramV2Request( string prompt, string? negativePrompt, int? seed, - global::Ideogram.AspectRatioV3? aspectRatio, + global::Ideogram.IdeogramV3AspectRatio? aspectRatio, global::Ideogram.GenerateImageIdeogramV2RequestRenderingSpeed? renderingSpeed, global::Ideogram.MagicPromptMode? magicPrompt, int? numImages, diff --git a/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogramV3CharacterRequest.g.cs b/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogramV3CharacterRequest.g.cs index e1c3f56..0ba3be8 100644 --- a/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogramV3CharacterRequest.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogramV3CharacterRequest.g.cs @@ -79,11 +79,14 @@ public sealed partial class GenerateImageIdeogramV3CharacterRequest public global::Ideogram.ResolutionV3? Resolution { get; set; } /// - /// The aspect ratio to use for image generation, which determines the image's resolution. Cannot be used in conjunction with resolution. Defaults to 1x1. + /// The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the
+ /// model select a ratio from the prompt; any other value pins the ratio.
+ /// Cannot be combined with `resolution`. Omitting the field is not `auto`:
+ /// it uses `1x1`. ///
[global::System.Text.Json.Serialization.JsonPropertyName("aspect_ratio")] - [global::System.Text.Json.Serialization.JsonConverter(typeof(global::Ideogram.JsonConverters.AspectRatioV3JsonConverter))] - public global::Ideogram.AspectRatioV3? AspectRatio { get; set; } + [global::System.Text.Json.Serialization.JsonConverter(typeof(global::Ideogram.JsonConverters.IdeogramV3AspectRatioJsonConverter))] + public global::Ideogram.IdeogramV3AspectRatio? AspectRatio { get; set; } /// /// The rendering speed to use.
@@ -222,7 +225,10 @@ public sealed partial class GenerateImageIdeogramV3CharacterRequest /// Example: 1280x800 /// /// - /// The aspect ratio to use for image generation, which determines the image's resolution. Cannot be used in conjunction with resolution. Defaults to 1x1. + /// The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the
+ /// model select a ratio from the prompt; any other value pins the ratio.
+ /// Cannot be combined with `resolution`. Omitting the field is not `auto`:
+ /// it uses `1x1`. /// /// /// The rendering speed to use.
@@ -290,7 +296,7 @@ public GenerateImageIdeogramV3CharacterRequest( string? characterReferenceMaskname, int? seed, global::Ideogram.ResolutionV3? resolution, - global::Ideogram.AspectRatioV3? aspectRatio, + global::Ideogram.IdeogramV3AspectRatio? aspectRatio, global::Ideogram.GenerateImageIdeogramV3CharacterRequestRenderingSpeed? renderingSpeed, global::Ideogram.MagicPromptMode? magicPrompt, int? numImages, diff --git a/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogramV3CustomModelRequest.g.cs b/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogramV3CustomModelRequest.g.cs index 4c3300e..c0102d1 100644 --- a/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogramV3CustomModelRequest.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogramV3CustomModelRequest.g.cs @@ -48,11 +48,14 @@ public sealed partial class GenerateImageIdeogramV3CustomModelRequest public global::Ideogram.ResolutionV3? Resolution { get; set; } /// - /// The aspect ratio to use for image generation, which determines the image's resolution. Cannot be used in conjunction with resolution. Defaults to 1x1. + /// The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the
+ /// model select a ratio from the prompt; any other value pins the ratio.
+ /// Cannot be combined with `resolution`. Omitting the field is not `auto`:
+ /// it uses `1x1`. ///
[global::System.Text.Json.Serialization.JsonPropertyName("aspect_ratio")] - [global::System.Text.Json.Serialization.JsonConverter(typeof(global::Ideogram.JsonConverters.AspectRatioV3JsonConverter))] - public global::Ideogram.AspectRatioV3? AspectRatio { get; set; } + [global::System.Text.Json.Serialization.JsonConverter(typeof(global::Ideogram.JsonConverters.IdeogramV3AspectRatioJsonConverter))] + public global::Ideogram.IdeogramV3AspectRatio? AspectRatio { get; set; } /// /// The rendering speed to use. When omitted, the server chooses a speed supported by the selected custom model. @@ -178,7 +181,10 @@ public sealed partial class GenerateImageIdeogramV3CustomModelRequest /// Example: 1280x800 /// /// - /// The aspect ratio to use for image generation, which determines the image's resolution. Cannot be used in conjunction with resolution. Defaults to 1x1. + /// The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the
+ /// model select a ratio from the prompt; any other value pins the ratio.
+ /// Cannot be combined with `resolution`. Omitting the field is not `auto`:
+ /// it uses `1x1`. /// /// /// The rendering speed to use. When omitted, the server chooses a speed supported by the selected custom model. @@ -240,7 +246,7 @@ public GenerateImageIdeogramV3CustomModelRequest( string? negativePrompt, int? seed, global::Ideogram.ResolutionV3? resolution, - global::Ideogram.AspectRatioV3? aspectRatio, + global::Ideogram.IdeogramV3AspectRatio? aspectRatio, global::Ideogram.GenerateImageIdeogramV3CustomModelRequestRenderingSpeed? renderingSpeed, global::Ideogram.MagicPromptMode? magicPrompt, int? numImages, diff --git a/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogramV3Request.g.cs b/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogramV3Request.g.cs index 1566048..9ec07a7 100644 --- a/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogramV3Request.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogramV3Request.g.cs @@ -39,11 +39,14 @@ public sealed partial class GenerateImageIdeogramV3Request public global::Ideogram.ResolutionV3? Resolution { get; set; } /// - /// The aspect ratio to use for image generation, which determines the image's resolution. Cannot be used in conjunction with resolution. Defaults to 1x1. + /// The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the
+ /// model select a ratio from the prompt; any other value pins the ratio.
+ /// Cannot be combined with `resolution`. Omitting the field is not `auto`:
+ /// it uses `1x1`. ///
[global::System.Text.Json.Serialization.JsonPropertyName("aspect_ratio")] - [global::System.Text.Json.Serialization.JsonConverter(typeof(global::Ideogram.JsonConverters.AspectRatioV3JsonConverter))] - public global::Ideogram.AspectRatioV3? AspectRatio { get; set; } + [global::System.Text.Json.Serialization.JsonConverter(typeof(global::Ideogram.JsonConverters.IdeogramV3AspectRatioJsonConverter))] + public global::Ideogram.IdeogramV3AspectRatio? AspectRatio { get; set; } /// /// The rendering speed to use.
@@ -188,7 +191,10 @@ public sealed partial class GenerateImageIdeogramV3Request /// Example: 1280x800 /// /// - /// The aspect ratio to use for image generation, which determines the image's resolution. Cannot be used in conjunction with resolution. Defaults to 1x1. + /// The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the
+ /// model select a ratio from the prompt; any other value pins the ratio.
+ /// Cannot be combined with `resolution`. Omitting the field is not `auto`:
+ /// it uses `1x1`. /// /// /// The rendering speed to use.
@@ -261,7 +267,7 @@ public GenerateImageIdeogramV3Request( string? negativePrompt, int? seed, global::Ideogram.ResolutionV3? resolution, - global::Ideogram.AspectRatioV3? aspectRatio, + global::Ideogram.IdeogramV3AspectRatio? aspectRatio, global::Ideogram.GenerateImageIdeogramV3RequestRenderingSpeed? renderingSpeed, global::Ideogram.MagicPromptMode? magicPrompt, int? numImages, diff --git a/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogramV3TransparentRequest.g.cs b/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogramV3TransparentRequest.g.cs index 37f0bf9..bbfdfbc 100644 --- a/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogramV3TransparentRequest.g.cs +++ b/src/libs/Ideogram/Generated/Ideogram.Models.GenerateImageIdeogramV3TransparentRequest.g.cs @@ -38,11 +38,14 @@ public sealed partial class GenerateImageIdeogramV3TransparentRequest public global::Ideogram.GenerateImageIdeogramV3TransparentRequestUpscaleFactor? UpscaleFactor { get; set; } /// - /// The aspect ratio to use for image generation, which determines the image's resolution. Cannot be used in conjunction with resolution. Defaults to 1x1. + /// The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the
+ /// model select a ratio from the prompt; any other value pins the ratio.
+ /// Cannot be combined with `resolution`. Omitting the field is not `auto`:
+ /// it uses `1x1`. ///
[global::System.Text.Json.Serialization.JsonPropertyName("aspect_ratio")] - [global::System.Text.Json.Serialization.JsonConverter(typeof(global::Ideogram.JsonConverters.AspectRatioV3JsonConverter))] - public global::Ideogram.AspectRatioV3? AspectRatio { get; set; } + [global::System.Text.Json.Serialization.JsonConverter(typeof(global::Ideogram.JsonConverters.IdeogramV3AspectRatioJsonConverter))] + public global::Ideogram.IdeogramV3AspectRatio? AspectRatio { get; set; } /// /// The rendering speed to use.
@@ -131,7 +134,10 @@ public sealed partial class GenerateImageIdeogramV3TransparentRequest /// Default Value: x1 /// /// - /// The aspect ratio to use for image generation, which determines the image's resolution. Cannot be used in conjunction with resolution. Defaults to 1x1. + /// The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the
+ /// model select a ratio from the prompt; any other value pins the ratio.
+ /// Cannot be combined with `resolution`. Omitting the field is not `auto`:
+ /// it uses `1x1`. /// /// /// The rendering speed to use.
@@ -177,7 +183,7 @@ public GenerateImageIdeogramV3TransparentRequest( string? negativePrompt, int? seed, global::Ideogram.GenerateImageIdeogramV3TransparentRequestUpscaleFactor? upscaleFactor, - global::Ideogram.AspectRatioV3? aspectRatio, + global::Ideogram.IdeogramV3AspectRatio? aspectRatio, global::Ideogram.GenerateImageIdeogramV3TransparentRequestRenderingSpeed? renderingSpeed, global::Ideogram.MagicPromptMode? magicPrompt, int? numImages, diff --git a/src/libs/Ideogram/Generated/Ideogram.Models.IdeogramV3AspectRatio.g.cs b/src/libs/Ideogram/Generated/Ideogram.Models.IdeogramV3AspectRatio.g.cs new file mode 100644 index 0000000..246cac0 --- /dev/null +++ b/src/libs/Ideogram/Generated/Ideogram.Models.IdeogramV3AspectRatio.g.cs @@ -0,0 +1,138 @@ + +#nullable enable + +namespace Ideogram +{ + /// + /// The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the
+ /// model select a ratio from the prompt; any other value pins the ratio.
+ /// Cannot be combined with `resolution`. Omitting the field is not `auto`:
+ /// it uses `1x1`. + ///
+ public enum IdeogramV3AspectRatio + { + /// + /// + /// + x10x16, + /// + /// + /// + x16x10, + /// + /// + /// + x16x9, + /// + /// + /// + x1x1, + /// + /// + /// + x1x2, + /// + /// + /// + x1x3, + /// + /// + /// + x2x1, + /// + /// + /// + x2x3, + /// + /// + /// + x3x1, + /// + /// + /// + x3x2, + /// + /// + /// + x3x4, + /// + /// + /// + x4x3, + /// + /// + /// + x4x5, + /// + /// + /// + x5x4, + /// + /// + /// + x9x16, + /// + /// + /// + Auto, + } + + /// + /// Enum extensions to do fast conversions without the reflection. + /// + public static class IdeogramV3AspectRatioExtensions + { + /// + /// Converts an enum to a string. + /// + public static string ToValueString(this IdeogramV3AspectRatio value) + { + return value switch + { + IdeogramV3AspectRatio.x10x16 => "10x16", + IdeogramV3AspectRatio.x16x10 => "16x10", + IdeogramV3AspectRatio.x16x9 => "16x9", + IdeogramV3AspectRatio.x1x1 => "1x1", + IdeogramV3AspectRatio.x1x2 => "1x2", + IdeogramV3AspectRatio.x1x3 => "1x3", + IdeogramV3AspectRatio.x2x1 => "2x1", + IdeogramV3AspectRatio.x2x3 => "2x3", + IdeogramV3AspectRatio.x3x1 => "3x1", + IdeogramV3AspectRatio.x3x2 => "3x2", + IdeogramV3AspectRatio.x3x4 => "3x4", + IdeogramV3AspectRatio.x4x3 => "4x3", + IdeogramV3AspectRatio.x4x5 => "4x5", + IdeogramV3AspectRatio.x5x4 => "5x4", + IdeogramV3AspectRatio.x9x16 => "9x16", + IdeogramV3AspectRatio.Auto => "auto", + _ => throw new global::System.ArgumentOutOfRangeException(nameof(value), value, null), + }; + } + /// + /// Converts an string to a enum. + /// + public static IdeogramV3AspectRatio? ToEnum(string value) + { + return value switch + { + "10x16" => IdeogramV3AspectRatio.x10x16, + "16x10" => IdeogramV3AspectRatio.x16x10, + "16x9" => IdeogramV3AspectRatio.x16x9, + "1x1" => IdeogramV3AspectRatio.x1x1, + "1x2" => IdeogramV3AspectRatio.x1x2, + "1x3" => IdeogramV3AspectRatio.x1x3, + "2x1" => IdeogramV3AspectRatio.x2x1, + "2x3" => IdeogramV3AspectRatio.x2x3, + "3x1" => IdeogramV3AspectRatio.x3x1, + "3x2" => IdeogramV3AspectRatio.x3x2, + "3x4" => IdeogramV3AspectRatio.x3x4, + "4x3" => IdeogramV3AspectRatio.x4x3, + "4x5" => IdeogramV3AspectRatio.x4x5, + "5x4" => IdeogramV3AspectRatio.x5x4, + "9x16" => IdeogramV3AspectRatio.x9x16, + "auto" => IdeogramV3AspectRatio.Auto, + _ => null, + }; + } + } +} \ No newline at end of file diff --git a/src/libs/Ideogram/Generated/Ideogram.Models.PreciseEditImageIdeogram45Request.Json.g.cs b/src/libs/Ideogram/Generated/Ideogram.Models.PreciseEditImageIdeogram45Request.Json.g.cs new file mode 100644 index 0000000..54899c4 --- /dev/null +++ b/src/libs/Ideogram/Generated/Ideogram.Models.PreciseEditImageIdeogram45Request.Json.g.cs @@ -0,0 +1,141 @@ +#nullable enable + +namespace Ideogram +{ + public sealed partial class PreciseEditImageIdeogram45Request + { + /// + /// Serializes the current instance to a JSON string using the provided JsonSerializerContext. + /// + public string ToJson( + global::System.Text.Json.Serialization.JsonSerializerContext jsonSerializerContext) + { + return global::System.Text.Json.JsonSerializer.Serialize( + this, + this.GetType(), + jsonSerializerContext); + } + + /// + /// Serializes the current instance to a JSON string using the generated default JsonSerializerContext. + /// + public string ToJson() + { + return ToJson(global::Ideogram.SourceGenerationContext.Default); + } + + /// + /// Serializes the current instance to a JSON string using the provided JsonSerializerOptions. + /// +#if NET8_0_OR_GREATER + [global::System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("JSON serialization and deserialization might require types that cannot be statically analyzed. Use the overload that takes a JsonTypeInfo or JsonSerializerContext, or make sure all of the required types are preserved.")] + [global::System.Diagnostics.CodeAnalysis.RequiresDynamicCode("JSON serialization and deserialization might require types that cannot be statically analyzed and might need runtime code generation. Use System.Text.Json source generation for native AOT applications.")] +#endif + public string ToJson( + global::System.Text.Json.JsonSerializerOptions? jsonSerializerOptions = null) + { + if (jsonSerializerOptions is null) + { + return ToJson(global::Ideogram.SourceGenerationContext.Default); + } + + return global::System.Text.Json.JsonSerializer.Serialize( + this, + jsonSerializerOptions); + } + + /// + /// Deserializes a JSON string using the provided JsonSerializerContext. + /// + public static global::Ideogram.PreciseEditImageIdeogram45Request? FromJson( + string json, + global::System.Text.Json.Serialization.JsonSerializerContext jsonSerializerContext) + { + return global::System.Text.Json.JsonSerializer.Deserialize( + json, + typeof(global::Ideogram.PreciseEditImageIdeogram45Request), + jsonSerializerContext) as global::Ideogram.PreciseEditImageIdeogram45Request; + } + + /// + /// Deserializes a JSON string using the generated default JsonSerializerContext. + /// + public static global::Ideogram.PreciseEditImageIdeogram45Request? FromJson( + string json) + { + return FromJson( + json, + global::Ideogram.SourceGenerationContext.Default); + } + + /// + /// Deserializes a JSON string using the provided JsonSerializerOptions. + /// +#if NET8_0_OR_GREATER + [global::System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("JSON serialization and deserialization might require types that cannot be statically analyzed. Use the overload that takes a JsonTypeInfo or JsonSerializerContext, or make sure all of the required types are preserved.")] + [global::System.Diagnostics.CodeAnalysis.RequiresDynamicCode("JSON serialization and deserialization might require types that cannot be statically analyzed and might need runtime code generation. Use System.Text.Json source generation for native AOT applications.")] +#endif + public static global::Ideogram.PreciseEditImageIdeogram45Request? FromJson( + string json, + global::System.Text.Json.JsonSerializerOptions? jsonSerializerOptions = null) + { + if (jsonSerializerOptions is null) + { + return FromJson( + json, + global::Ideogram.SourceGenerationContext.Default); + } + + return global::System.Text.Json.JsonSerializer.Deserialize( + json, + jsonSerializerOptions); + } + + /// + /// Deserializes a JSON stream using the provided JsonSerializerContext. + /// + public static async global::System.Threading.Tasks.ValueTask FromJsonStreamAsync( + global::System.IO.Stream jsonStream, + global::System.Text.Json.Serialization.JsonSerializerContext jsonSerializerContext) + { + return (await global::System.Text.Json.JsonSerializer.DeserializeAsync( + jsonStream, + typeof(global::Ideogram.PreciseEditImageIdeogram45Request), + jsonSerializerContext).ConfigureAwait(false)) as global::Ideogram.PreciseEditImageIdeogram45Request; + } + + /// + /// Deserializes a JSON stream using the generated default JsonSerializerContext. + /// + public static global::System.Threading.Tasks.ValueTask FromJsonStreamAsync( + global::System.IO.Stream jsonStream) + { + return FromJsonStreamAsync( + jsonStream, + global::Ideogram.SourceGenerationContext.Default); + } + + /// + /// Deserializes a JSON stream using the provided JsonSerializerOptions. + /// +#if NET8_0_OR_GREATER + [global::System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("JSON serialization and deserialization might require types that cannot be statically analyzed. Use the overload that takes a JsonTypeInfo or JsonSerializerContext, or make sure all of the required types are preserved.")] + [global::System.Diagnostics.CodeAnalysis.RequiresDynamicCode("JSON serialization and deserialization might require types that cannot be statically analyzed and might need runtime code generation. Use System.Text.Json source generation for native AOT applications.")] +#endif + public static global::System.Threading.Tasks.ValueTask FromJsonStreamAsync( + global::System.IO.Stream jsonStream, + global::System.Text.Json.JsonSerializerOptions? jsonSerializerOptions = null) + { + if (jsonSerializerOptions is null) + { + return FromJsonStreamAsync( + jsonStream, + global::Ideogram.SourceGenerationContext.Default); + } + + return global::System.Text.Json.JsonSerializer.DeserializeAsync( + jsonStream, + jsonSerializerOptions); + } + } +} diff --git a/src/libs/Ideogram/Generated/Ideogram.Models.PreciseEditImageIdeogram45Request.g.cs b/src/libs/Ideogram/Generated/Ideogram.Models.PreciseEditImageIdeogram45Request.g.cs new file mode 100644 index 0000000..89edac1 --- /dev/null +++ b/src/libs/Ideogram/Generated/Ideogram.Models.PreciseEditImageIdeogram45Request.g.cs @@ -0,0 +1,250 @@ + +#nullable enable + +namespace Ideogram +{ + /// + /// The image being edited is required, as an `image_asset_identifier`
+ /// reference or as raw `image` bytes. The output is always returned at
+ /// that image's exact width and height, so this request takes no output
+ /// size. + ///
+ public sealed partial class PreciseEditImageIdeogram45Request + { + /// + /// The edit instruction to apply to the sources. Accepts either
+ /// natural language or a structured JSON prompt; the server detects
+ /// which was supplied. Natural language is automatically rewritten
+ /// into the model's structured edit contract, while structured JSON
+ /// is consumed directly. + ///
+ [global::System.Text.Json.Serialization.JsonPropertyName("prompt")] + [global::System.Text.Json.Serialization.JsonRequired] + public required string Prompt { get; set; } + + /// + /// The image to edit, as an existing upload or generated image asset. Supply this or `image`, never both. Takes priority over `image` if both are supplied. Cannot be combined with `mask`. + /// + [global::System.Text.Json.Serialization.JsonPropertyName("image_asset_identifier")] + public global::Ideogram.AssetIdentifier? ImageAssetIdentifier { get; set; } + + /// + /// The image to edit, as raw bytes (max size 25MB; JPEG, PNG, or WEBP only). Multipart requests only; ignored if `image_asset_identifier` is also supplied. Required when supplying a `mask`. + /// + [global::System.Text.Json.Serialization.JsonPropertyName("image")] + public byte[]? Image { get; set; } + + /// + /// The image to edit, as raw bytes (max size 25MB; JPEG, PNG, or WEBP only). Multipart requests only; ignored if `image_asset_identifier` is also supplied. Required when supplying a `mask`. + /// + [global::System.Text.Json.Serialization.JsonPropertyName("imagename")] + public string? Imagename { get; set; } + + /// + /// Optional additional images to guide the edit, by reference. These are never edited themselves; only `image_asset_identifier` or `image` is. Requires the image being edited to be supplied by reference too, and cannot be combined with `mask`. + /// + [global::System.Text.Json.Serialization.JsonPropertyName("reference_image_asset_identifiers")] + public global::System.Collections.Generic.IList? ReferenceImageAssetIdentifiers { get; set; } + + /// + /// Optional additional images to guide the edit (max 4, max size 25MB each), as raw bytes; only JPEG, PNG, and WEBP formats are supported. These are never edited themselves; only `image` is. Multipart requests only; ignored if `reference_image_asset_identifiers` is also supplied. A masked request may carry at most three, because the mask occupies one of the model's reference slots. + /// + [global::System.Text.Json.Serialization.JsonPropertyName("reference_images")] + public global::System.Collections.Generic.IList? ReferenceImages { get; set; } + + /// + /// An optional mask confining the edit to part of `image`, as raw bytes (multipart requests only; JPEG, PNG, or WEBP, max 25MB). Black marks the area to edit and white the area to preserve; values in between are rounded to whichever is nearer. The mask must have the same width and height as `image`, and must contain both black and white areas. Requires the image being edited to be uploaded as raw `image` bytes in the same request; masks cannot be combined with asset references. The mask is supplied to the model as an additional reference image, so a masked request may carry at most three `reference_images`. + /// + [global::System.Text.Json.Serialization.JsonPropertyName("mask")] + public byte[]? Mask { get; set; } + + /// + /// An optional mask confining the edit to part of `image`, as raw bytes (multipart requests only; JPEG, PNG, or WEBP, max 25MB). Black marks the area to edit and white the area to preserve; values in between are rounded to whichever is nearer. The mask must have the same width and height as `image`, and must contain both black and white areas. Requires the image being edited to be uploaded as raw `image` bytes in the same request; masks cannot be combined with asset references. The mask is supplied to the model as an additional reference image, so a masked request may carry at most three `reference_images`. + /// + [global::System.Text.Json.Serialization.JsonPropertyName("maskname")] + public string? Maskname { get; set; } + + /// + /// The rendering speed to use. `ultra` renders multiple candidate edits internally and returns the one that best applies the instruction; it takes longer than `quality`, is priced higher, and supports at most 4 images per request.
+ /// Default Value: default + ///
+ [global::System.Text.Json.Serialization.JsonPropertyName("rendering_speed")] + [global::System.Text.Json.Serialization.JsonConverter(typeof(global::Ideogram.JsonConverters.PreciseEditImageIdeogram45RequestRenderingSpeedJsonConverter))] + public global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeed? RenderingSpeed { get; set; } + + /// + /// Random seed. Set for reproducible generation.
+ /// Example: 12345 + ///
+ /// 12345 + [global::System.Text.Json.Serialization.JsonPropertyName("seed")] + public int? Seed { get; set; } + + /// + /// The number of images to generate.
+ /// Default Value: 1 + ///
+ [global::System.Text.Json.Serialization.JsonPropertyName("num_images")] + public int? NumImages { get; set; } + + /// + /// Optional. Opt this request into post-generation copyright detection. Adds detection latency; flagged images come back with `is_image_safe: false`. + /// + [global::System.Text.Json.Serialization.JsonPropertyName("enable_copyright_detection")] + public bool? EnableCopyrightDetection { get; set; } + + /// + /// When false (the default), the request blocks until the images are ready and returns them in `data`. When true, the request returns as soon as it is accepted; poll for completion and results with `GET /v1/generations/{generation_id}` using the returned `generation_id`.
+ /// Default Value: false + ///
+ [global::System.Text.Json.Serialization.JsonPropertyName("async")] + public bool? Async { get; set; } + + /// + /// HTTPS URL that Ideogram delivers the generated result to. Ideogram sends a
+ /// JSON POST to this URL once all images for the request have finished
+ /// generating. The body mirrors the synchronous generate response:
+ /// `request_id`, `created`, and a `data` array
+ /// containing every generated image (`url`, `prompt`, `resolution`, `seed`,
+ /// `is_image_safe`). Each delivery is signed with Ed25519 and verifiable
+ /// against the public keys at `https://api.ideogram.ai/v1/.well-known/jwks.json`. Must be HTTPS;
+ /// private and loopback hosts and the cloud metadata service are rejected.
+ /// Example: https://api.example.com/webhooks/ideogram + ///
+ /// https://api.example.com/webhooks/ideogram + [global::System.Text.Json.Serialization.JsonPropertyName("webhook_url")] + public string? WebhookUrl { get; set; } + + /// + /// When true or omitted, the output is kept private to your account. Set to false to publish the output to the public feed. Enterprise accounts always generate privately. + /// + [global::System.Text.Json.Serialization.JsonPropertyName("private")] + public bool? Private { get; set; } + + /// + /// A collection you can write to, by its URL-safe base64 collection id. The output images are added to it when the request completes. + /// + [global::System.Text.Json.Serialization.JsonPropertyName("target_collection_id")] + public string? TargetCollectionId { get; set; } + + /// + /// Additional properties that are not explicitly defined in the schema + /// + [global::System.Text.Json.Serialization.JsonExtensionData] + public global::System.Collections.Generic.IDictionary AdditionalProperties { get; set; } = new global::System.Collections.Generic.Dictionary(); + + /// + /// Initializes a new instance of the class. + /// + /// + /// The edit instruction to apply to the sources. Accepts either
+ /// natural language or a structured JSON prompt; the server detects
+ /// which was supplied. Natural language is automatically rewritten
+ /// into the model's structured edit contract, while structured JSON
+ /// is consumed directly. + /// + /// + /// The image to edit, as an existing upload or generated image asset. Supply this or `image`, never both. Takes priority over `image` if both are supplied. Cannot be combined with `mask`. + /// + /// + /// The image to edit, as raw bytes (max size 25MB; JPEG, PNG, or WEBP only). Multipart requests only; ignored if `image_asset_identifier` is also supplied. Required when supplying a `mask`. + /// + /// + /// The image to edit, as raw bytes (max size 25MB; JPEG, PNG, or WEBP only). Multipart requests only; ignored if `image_asset_identifier` is also supplied. Required when supplying a `mask`. + /// + /// + /// Optional additional images to guide the edit, by reference. These are never edited themselves; only `image_asset_identifier` or `image` is. Requires the image being edited to be supplied by reference too, and cannot be combined with `mask`. + /// + /// + /// Optional additional images to guide the edit (max 4, max size 25MB each), as raw bytes; only JPEG, PNG, and WEBP formats are supported. These are never edited themselves; only `image` is. Multipart requests only; ignored if `reference_image_asset_identifiers` is also supplied. A masked request may carry at most three, because the mask occupies one of the model's reference slots. + /// + /// + /// An optional mask confining the edit to part of `image`, as raw bytes (multipart requests only; JPEG, PNG, or WEBP, max 25MB). Black marks the area to edit and white the area to preserve; values in between are rounded to whichever is nearer. The mask must have the same width and height as `image`, and must contain both black and white areas. Requires the image being edited to be uploaded as raw `image` bytes in the same request; masks cannot be combined with asset references. The mask is supplied to the model as an additional reference image, so a masked request may carry at most three `reference_images`. + /// + /// + /// An optional mask confining the edit to part of `image`, as raw bytes (multipart requests only; JPEG, PNG, or WEBP, max 25MB). Black marks the area to edit and white the area to preserve; values in between are rounded to whichever is nearer. The mask must have the same width and height as `image`, and must contain both black and white areas. Requires the image being edited to be uploaded as raw `image` bytes in the same request; masks cannot be combined with asset references. The mask is supplied to the model as an additional reference image, so a masked request may carry at most three `reference_images`. + /// + /// + /// The rendering speed to use. `ultra` renders multiple candidate edits internally and returns the one that best applies the instruction; it takes longer than `quality`, is priced higher, and supports at most 4 images per request.
+ /// Default Value: default + /// + /// + /// Random seed. Set for reproducible generation.
+ /// Example: 12345 + /// + /// + /// The number of images to generate.
+ /// Default Value: 1 + /// + /// + /// Optional. Opt this request into post-generation copyright detection. Adds detection latency; flagged images come back with `is_image_safe: false`. + /// + /// + /// When false (the default), the request blocks until the images are ready and returns them in `data`. When true, the request returns as soon as it is accepted; poll for completion and results with `GET /v1/generations/{generation_id}` using the returned `generation_id`.
+ /// Default Value: false + /// + /// + /// HTTPS URL that Ideogram delivers the generated result to. Ideogram sends a
+ /// JSON POST to this URL once all images for the request have finished
+ /// generating. The body mirrors the synchronous generate response:
+ /// `request_id`, `created`, and a `data` array
+ /// containing every generated image (`url`, `prompt`, `resolution`, `seed`,
+ /// `is_image_safe`). Each delivery is signed with Ed25519 and verifiable
+ /// against the public keys at `https://api.ideogram.ai/v1/.well-known/jwks.json`. Must be HTTPS;
+ /// private and loopback hosts and the cloud metadata service are rejected.
+ /// Example: https://api.example.com/webhooks/ideogram + /// + /// + /// When true or omitted, the output is kept private to your account. Set to false to publish the output to the public feed. Enterprise accounts always generate privately. + /// + /// + /// A collection you can write to, by its URL-safe base64 collection id. The output images are added to it when the request completes. + /// +#if NET7_0_OR_GREATER + [global::System.Diagnostics.CodeAnalysis.SetsRequiredMembers] +#endif + public PreciseEditImageIdeogram45Request( + string prompt, + global::Ideogram.AssetIdentifier? imageAssetIdentifier, + byte[]? image, + string? imagename, + global::System.Collections.Generic.IList? referenceImageAssetIdentifiers, + global::System.Collections.Generic.IList? referenceImages, + byte[]? mask, + string? maskname, + global::Ideogram.PreciseEditImageIdeogram45RequestRenderingSpeed? renderingSpeed, + int? seed, + int? numImages, + bool? enableCopyrightDetection, + bool? async, + string? webhookUrl, + bool? @private, + string? targetCollectionId) + { + this.Prompt = prompt ?? throw new global::System.ArgumentNullException(nameof(prompt)); + this.ImageAssetIdentifier = imageAssetIdentifier; + this.Image = image; + this.Imagename = imagename; + this.ReferenceImageAssetIdentifiers = referenceImageAssetIdentifiers; + this.ReferenceImages = referenceImages; + this.Mask = mask; + this.Maskname = maskname; + this.RenderingSpeed = renderingSpeed; + this.Seed = seed; + this.NumImages = numImages; + this.EnableCopyrightDetection = enableCopyrightDetection; + this.Async = async; + this.WebhookUrl = webhookUrl; + this.Private = @private; + this.TargetCollectionId = targetCollectionId; + } + + /// + /// Initializes a new instance of the class. + /// + public PreciseEditImageIdeogram45Request() + { + } + + } +} \ No newline at end of file diff --git a/src/libs/Ideogram/Generated/Ideogram.Models.PreciseEditImageIdeogram45RequestRenderingSpeed.g.cs b/src/libs/Ideogram/Generated/Ideogram.Models.PreciseEditImageIdeogram45RequestRenderingSpeed.g.cs new file mode 100644 index 0000000..ed49709 --- /dev/null +++ b/src/libs/Ideogram/Generated/Ideogram.Models.PreciseEditImageIdeogram45RequestRenderingSpeed.g.cs @@ -0,0 +1,64 @@ + +#nullable enable + +namespace Ideogram +{ + /// + /// The rendering speed to use. `ultra` renders multiple candidate edits internally and returns the one that best applies the instruction; it takes longer than `quality`, is priced higher, and supports at most 4 images per request.
+ /// Default Value: default + ///
+ public enum PreciseEditImageIdeogram45RequestRenderingSpeed + { + /// + /// + /// + Default, + /// + /// + /// + Quality, + /// + /// + /// + Turbo, + /// + /// + /// + Ultra, + } + + /// + /// Enum extensions to do fast conversions without the reflection. + /// + public static class PreciseEditImageIdeogram45RequestRenderingSpeedExtensions + { + /// + /// Converts an enum to a string. + /// + public static string ToValueString(this PreciseEditImageIdeogram45RequestRenderingSpeed value) + { + return value switch + { + PreciseEditImageIdeogram45RequestRenderingSpeed.Default => "default", + PreciseEditImageIdeogram45RequestRenderingSpeed.Quality => "quality", + PreciseEditImageIdeogram45RequestRenderingSpeed.Turbo => "turbo", + PreciseEditImageIdeogram45RequestRenderingSpeed.Ultra => "ultra", + _ => throw new global::System.ArgumentOutOfRangeException(nameof(value), value, null), + }; + } + /// + /// Converts an string to a enum. + /// + public static PreciseEditImageIdeogram45RequestRenderingSpeed? ToEnum(string value) + { + return value switch + { + "default" => PreciseEditImageIdeogram45RequestRenderingSpeed.Default, + "quality" => PreciseEditImageIdeogram45RequestRenderingSpeed.Quality, + "turbo" => PreciseEditImageIdeogram45RequestRenderingSpeed.Turbo, + "ultra" => PreciseEditImageIdeogram45RequestRenderingSpeed.Ultra, + _ => null, + }; + } + } +} \ No newline at end of file diff --git a/src/libs/Ideogram/Generated/Ideogram.Models.PreciseEditImageIdeogram45Response.Json.g.cs b/src/libs/Ideogram/Generated/Ideogram.Models.PreciseEditImageIdeogram45Response.Json.g.cs new file mode 100644 index 0000000..3d41e17 --- /dev/null +++ b/src/libs/Ideogram/Generated/Ideogram.Models.PreciseEditImageIdeogram45Response.Json.g.cs @@ -0,0 +1,141 @@ +#nullable enable + +namespace Ideogram +{ + public sealed partial class PreciseEditImageIdeogram45Response + { + /// + /// Serializes the current instance to a JSON string using the provided JsonSerializerContext. + /// + public string ToJson( + global::System.Text.Json.Serialization.JsonSerializerContext jsonSerializerContext) + { + return global::System.Text.Json.JsonSerializer.Serialize( + this, + this.GetType(), + jsonSerializerContext); + } + + /// + /// Serializes the current instance to a JSON string using the generated default JsonSerializerContext. + /// + public string ToJson() + { + return ToJson(global::Ideogram.SourceGenerationContext.Default); + } + + /// + /// Serializes the current instance to a JSON string using the provided JsonSerializerOptions. + /// +#if NET8_0_OR_GREATER + [global::System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("JSON serialization and deserialization might require types that cannot be statically analyzed. Use the overload that takes a JsonTypeInfo or JsonSerializerContext, or make sure all of the required types are preserved.")] + [global::System.Diagnostics.CodeAnalysis.RequiresDynamicCode("JSON serialization and deserialization might require types that cannot be statically analyzed and might need runtime code generation. Use System.Text.Json source generation for native AOT applications.")] +#endif + public string ToJson( + global::System.Text.Json.JsonSerializerOptions? jsonSerializerOptions = null) + { + if (jsonSerializerOptions is null) + { + return ToJson(global::Ideogram.SourceGenerationContext.Default); + } + + return global::System.Text.Json.JsonSerializer.Serialize( + this, + jsonSerializerOptions); + } + + /// + /// Deserializes a JSON string using the provided JsonSerializerContext. + /// + public static global::Ideogram.PreciseEditImageIdeogram45Response? FromJson( + string json, + global::System.Text.Json.Serialization.JsonSerializerContext jsonSerializerContext) + { + return global::System.Text.Json.JsonSerializer.Deserialize( + json, + typeof(global::Ideogram.PreciseEditImageIdeogram45Response), + jsonSerializerContext) as global::Ideogram.PreciseEditImageIdeogram45Response; + } + + /// + /// Deserializes a JSON string using the generated default JsonSerializerContext. + /// + public static global::Ideogram.PreciseEditImageIdeogram45Response? FromJson( + string json) + { + return FromJson( + json, + global::Ideogram.SourceGenerationContext.Default); + } + + /// + /// Deserializes a JSON string using the provided JsonSerializerOptions. + /// +#if NET8_0_OR_GREATER + [global::System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("JSON serialization and deserialization might require types that cannot be statically analyzed. Use the overload that takes a JsonTypeInfo or JsonSerializerContext, or make sure all of the required types are preserved.")] + [global::System.Diagnostics.CodeAnalysis.RequiresDynamicCode("JSON serialization and deserialization might require types that cannot be statically analyzed and might need runtime code generation. Use System.Text.Json source generation for native AOT applications.")] +#endif + public static global::Ideogram.PreciseEditImageIdeogram45Response? FromJson( + string json, + global::System.Text.Json.JsonSerializerOptions? jsonSerializerOptions = null) + { + if (jsonSerializerOptions is null) + { + return FromJson( + json, + global::Ideogram.SourceGenerationContext.Default); + } + + return global::System.Text.Json.JsonSerializer.Deserialize( + json, + jsonSerializerOptions); + } + + /// + /// Deserializes a JSON stream using the provided JsonSerializerContext. + /// + public static async global::System.Threading.Tasks.ValueTask FromJsonStreamAsync( + global::System.IO.Stream jsonStream, + global::System.Text.Json.Serialization.JsonSerializerContext jsonSerializerContext) + { + return (await global::System.Text.Json.JsonSerializer.DeserializeAsync( + jsonStream, + typeof(global::Ideogram.PreciseEditImageIdeogram45Response), + jsonSerializerContext).ConfigureAwait(false)) as global::Ideogram.PreciseEditImageIdeogram45Response; + } + + /// + /// Deserializes a JSON stream using the generated default JsonSerializerContext. + /// + public static global::System.Threading.Tasks.ValueTask FromJsonStreamAsync( + global::System.IO.Stream jsonStream) + { + return FromJsonStreamAsync( + jsonStream, + global::Ideogram.SourceGenerationContext.Default); + } + + /// + /// Deserializes a JSON stream using the provided JsonSerializerOptions. + /// +#if NET8_0_OR_GREATER + [global::System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("JSON serialization and deserialization might require types that cannot be statically analyzed. Use the overload that takes a JsonTypeInfo or JsonSerializerContext, or make sure all of the required types are preserved.")] + [global::System.Diagnostics.CodeAnalysis.RequiresDynamicCode("JSON serialization and deserialization might require types that cannot be statically analyzed and might need runtime code generation. Use System.Text.Json source generation for native AOT applications.")] +#endif + public static global::System.Threading.Tasks.ValueTask FromJsonStreamAsync( + global::System.IO.Stream jsonStream, + global::System.Text.Json.JsonSerializerOptions? jsonSerializerOptions = null) + { + if (jsonSerializerOptions is null) + { + return FromJsonStreamAsync( + jsonStream, + global::Ideogram.SourceGenerationContext.Default); + } + + return global::System.Text.Json.JsonSerializer.DeserializeAsync( + jsonStream, + jsonSerializerOptions); + } + } +} diff --git a/src/libs/Ideogram/Generated/Ideogram.Models.PreciseEditImageIdeogram45Response.g.cs b/src/libs/Ideogram/Generated/Ideogram.Models.PreciseEditImageIdeogram45Response.g.cs new file mode 100644 index 0000000..a55499a --- /dev/null +++ b/src/libs/Ideogram/Generated/Ideogram.Models.PreciseEditImageIdeogram45Response.g.cs @@ -0,0 +1,76 @@ + +#nullable enable + +namespace Ideogram +{ + /// + /// Response returned by `POST /v2/image/precise-edit/ideogram-4-5`.
+ /// Synchronous requests (the default) include the edited images in `data`.
+ /// Requests with `async` set to true omit `data`; poll for completion and
+ /// results with `GET /v1/generations/{generation_id}` using the returned
+ /// `generation_id`. The seed reports the value the request resolved to
+ /// when the caller left it unset.
+ /// Example: {"data":[{"seed":12345,"prompt":"prompt","resolution":"1024x1024","url":"https://openapi-generator.tech","is_image_safe":true},{"seed":12345,"prompt":"prompt","resolution":"1024x1024","url":"https://openapi-generator.tech","is_image_safe":true}],"seed":0,"generation_id":"generation_id"} + ///
+ public sealed partial class PreciseEditImageIdeogram45Response + { + /// + /// URL-safe base64 ID of the accepted generation. Accepted by the
+ /// `GET /v1/generations/{generation_id}` polling endpoint. + ///
+ [global::System.Text.Json.Serialization.JsonPropertyName("generation_id")] + public string? GenerationId { get; set; } + + /// + /// The edited images, in generation order. Present only for synchronous requests (`async` omitted or false). + /// + [global::System.Text.Json.Serialization.JsonPropertyName("data")] + public global::System.Collections.Generic.IList? Data { get; set; } + + /// + /// The seed the request was served with. + /// + [global::System.Text.Json.Serialization.JsonPropertyName("seed")] + public int? Seed { get; set; } + + /// + /// Additional properties that are not explicitly defined in the schema + /// + [global::System.Text.Json.Serialization.JsonExtensionData] + public global::System.Collections.Generic.IDictionary AdditionalProperties { get; set; } = new global::System.Collections.Generic.Dictionary(); + + /// + /// Initializes a new instance of the class. + /// + /// + /// URL-safe base64 ID of the accepted generation. Accepted by the
+ /// `GET /v1/generations/{generation_id}` polling endpoint. + /// + /// + /// The edited images, in generation order. Present only for synchronous requests (`async` omitted or false). + /// + /// + /// The seed the request was served with. + /// +#if NET7_0_OR_GREATER + [global::System.Diagnostics.CodeAnalysis.SetsRequiredMembers] +#endif + public PreciseEditImageIdeogram45Response( + string? generationId, + global::System.Collections.Generic.IList? data, + int? seed) + { + this.GenerationId = generationId; + this.Data = data; + this.Seed = seed; + } + + /// + /// Initializes a new instance of the class. + /// + public PreciseEditImageIdeogram45Response() + { + } + + } +} \ No newline at end of file diff --git a/src/libs/Ideogram/Generated/autosdk.generated-examples.json b/src/libs/Ideogram/Generated/autosdk.generated-examples.json index b8d9ef8..5042005 100644 --- a/src/libs/Ideogram/Generated/autosdk.generated-examples.json +++ b/src/libs/Ideogram/Generated/autosdk.generated-examples.json @@ -974,7 +974,7 @@ "Slug": "post-generate-image-v2-ideogram45", "Description": "Generate one or more images with Ideogram 4.5. Supplying source\nimages turns the request into an image-to-image transform: the model\nconditions on the sources, the prompt becomes optional guidance, and\n\u0060size\u0060 may be \u0022auto\u0022 to derive the output from the first source.\nProvide sources either as \u0060image_asset_identifiers\u0060 references or as\nraw \u0060images\u0060 bytes (multipart requests only); if both are supplied,\nthe references win and the bytes are ignored. The \u0060prompt\u0060 accepts\neither natural language or a structured Ideogram 4.0 JSON prompt; the\nserver detects which was supplied.\n\n\u0060magic_prompt\u0060 controls automatic prompt rewriting: \u0060auto\u0060 (the\ndefault) and \u0060on\u0060 rewrite a natural-language prompt, a prompt that is\nalready a valid structured JSON prompt is always consumed directly,\nand \u0060off\u0060 disables rewriting entirely so the model receives your\nprompt verbatim.\n\nIdeogram 4.5 renders a fixed set of output sizes. When \u0060size\u0060\nis omitted, the server picks a supported size automatically based on\nthe prompt.\n\nBy default the request blocks until the images are ready and returns\nthem in \u0060data\u0060. Set \u0060async\u0060 to true to return immediately after the\nrequest is accepted, then poll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using the returned\n\u0060generation_id\u0060.\n\nSupplying a \u0060webhook_url\u0060 makes the request asynchronous whatever\n\u0060async\u0060 says: the response returns as soon as the request is accepted,\nand the finished result is POSTed to that URL.", "Language": "http", - "Code": "### Generate images with Ideogram 4.5, from a prompt or by transforming source images\n# @name post_generate_image_v2_ideogram45\nPOST {{host}}/v2/image/generate/ideogram-4-5?dry_run=false\nAuthorization: Bearer {{token}}\nContent-Type: multipart/form-data; boundary=AutoSDKBoundary\nAccept: application/json\n\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022prompt\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022magic_prompt\u0022\n\nauto\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022image_asset_identifiers\u0022\n\n{\u0022asset_type\u0022:\u0022RESPONSE\u0022,\u0022asset_id\u0022:\u00227uS_VESkRI6O3-sVgHQp_A\u0022}\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022images\u0022; filename=\u0022images.bin\u0022\nContent-Type: application/octet-stream\n\n\u003C ./images.bin\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022size\u0022\n\n2048x2048\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022rendering_speed\u0022\n\ndefault\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022seed\u0022\n\n12345\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022num_images\u0022\n\n1\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022enable_copyright_detection\u0022\n\ntrue\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022async\u0022\n\nfalse\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022webhook_url\u0022\n\nhttps://api.example.com/webhooks/ideogram\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022private\u0022\n\ntrue\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022target_collection_id\u0022\n\nstring\n--AutoSDKBoundary--\n\n## Responses\n# 200\n# Description: The generated images (synchronous requests), or an acknowledgement to poll with \u0060GET /v1/generations/{generation_id}\u0060 (\u0060async\u0060 requests).\n# Content-Type: application/json\n# 400\n# Description: Invalid input provided.\n# 401\n# Description: Unauthorized.\n# 402\n# Description: Insufficient credits or quota.\n# Content-Type: application/json\n# 422\n# Description: The prompt did not pass safety checks.\n# 429\n# Description: Too many requests.\n# Content-Type: application/json\n# 500\n# Description: Internal server error.\n# 503\n# Description: The endpoint is temporarily unavailable.", + "Code": "### Generate images with Ideogram 4.5, from a prompt or by transforming source images\n# @name post_generate_image_v2_ideogram45\nPOST {{host}}/v2/image/generate/ideogram-4-5?dry_run=false\nAuthorization: Bearer {{token}}\nContent-Type: multipart/form-data; boundary=AutoSDKBoundary\nAccept: application/json\n\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022prompt\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022magic_prompt\u0022\n\nauto\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022image_asset_identifiers\u0022\n\n{\u0022asset_type\u0022:\u0022RESPONSE\u0022,\u0022asset_id\u0022:\u00227uS_VESkRI6O3-sVgHQp_A\u0022}\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022images\u0022; filename=\u0022images.bin\u0022\nContent-Type: application/octet-stream\n\n\u003C ./images.bin\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022mask\u0022; filename=\u0022mask.bin\u0022\nContent-Type: application/octet-stream\n\n\u003C ./mask.bin\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022size\u0022\n\n2048x2048\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022rendering_speed\u0022\n\ndefault\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022seed\u0022\n\n12345\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022num_images\u0022\n\n1\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022enable_copyright_detection\u0022\n\ntrue\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022async\u0022\n\nfalse\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022webhook_url\u0022\n\nhttps://api.example.com/webhooks/ideogram\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022private\u0022\n\ntrue\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022target_collection_id\u0022\n\nstring\n--AutoSDKBoundary--\n\n## Responses\n# 200\n# Description: The generated images (synchronous requests), or an acknowledgement to poll with \u0060GET /v1/generations/{generation_id}\u0060 (\u0060async\u0060 requests).\n# Content-Type: application/json\n# 400\n# Description: Invalid input provided.\n# 401\n# Description: Unauthorized.\n# 402\n# Description: Insufficient credits or quota.\n# Content-Type: application/json\n# 422\n# Description: The prompt did not pass safety checks.\n# 429\n# Description: Too many requests.\n# Content-Type: application/json\n# 500\n# Description: Internal server error.\n# 503\n# Description: The endpoint is temporarily unavailable.", "Format": "http", "OperationId": "post_generate_image_v2_ideogram45", "Setup": null @@ -1007,7 +1007,7 @@ "Slug": "post-generate-image-v2-ideogram-v3", "Description": "Generate one or more images from a text prompt with Ideogram 3.0,\nwith optional style controls: style codes, a style preset, a color\npalette, or style references. Supply style references as a saved style\n(\u0060style_reference_collection_id\u0060), as\n\u0060style_reference_asset_identifiers\u0060 references (images already stored\nwith Ideogram), or as raw \u0060style_reference_images\u0060 bytes (multipart\nrequests only). These three style reference forms cannot be combined.\n\nBy default the request blocks until the images are ready and returns\nthem in \u0060data\u0060. Set \u0060async\u0060 to true to return immediately after the\nrequest is accepted, then poll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using the returned\n\u0060generation_id\u0060.\n\nSupplying a \u0060webhook_url\u0060 makes the request asynchronous whatever\n\u0060async\u0060 says: the response returns as soon as the request is accepted,\nand the finished result is POSTed to that URL.", "Language": "http", - "Code": "### Generate images with Ideogram 3.0 from a text prompt\n# @name post_generate_image_v2_ideogram_v3\nPOST {{host}}/v2/image/generate/ideogram-3?dry_run=false\nAuthorization: Bearer {{token}}\nContent-Type: multipart/form-data; boundary=AutoSDKBoundary\nAccept: application/json\n\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022prompt\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022negative_prompt\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022seed\u0022\n\n12345\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022resolution\u0022\n\n1280x800\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022aspect_ratio\u0022\n\n1x3\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022rendering_speed\u0022\n\ndefault\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022magic_prompt\u0022\n\nauto\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022num_images\u0022\n\n1\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022color_palette\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_codes\u0022\n\nABCD1234\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_type\u0022\n\ngeneral\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_preset\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_reference_collection_id\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_reference_collection_version_id\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_reference_asset_identifiers\u0022\n\n{\u0022asset_type\u0022:\u0022RESPONSE\u0022,\u0022asset_id\u0022:\u00227uS_VESkRI6O3-sVgHQp_A\u0022}\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_reference_images\u0022; filename=\u0022style_reference_images.bin\u0022\nContent-Type: application/octet-stream\n\n\u003C ./style_reference_images.bin\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022enable_copyright_detection\u0022\n\ntrue\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022async\u0022\n\nfalse\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022webhook_url\u0022\n\nhttps://api.example.com/webhooks/ideogram\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022private\u0022\n\ntrue\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022target_collection_id\u0022\n\nstring\n--AutoSDKBoundary--\n\n## Responses\n# 200\n# Description: The generated images (synchronous requests), or an acknowledgement to poll with \u0060GET /v1/generations/{generation_id}\u0060 (\u0060async\u0060 requests).\n# Content-Type: application/json\n# 400\n# Description: Invalid input provided.\n# 401\n# Description: Unauthorized.\n# 402\n# Description: Insufficient credits or quota.\n# Content-Type: application/json\n# 404\n# Description: A referenced style collection or asset was not found.\n# 422\n# Description: The prompt did not pass safety checks.\n# 429\n# Description: Too many requests.\n# Content-Type: application/json\n# 500\n# Description: Internal server error.\n# 503\n# Description: The endpoint is temporarily unavailable.", + "Code": "### Generate images with Ideogram 3.0 from a text prompt\n# @name post_generate_image_v2_ideogram_v3\nPOST {{host}}/v2/image/generate/ideogram-3?dry_run=false\nAuthorization: Bearer {{token}}\nContent-Type: multipart/form-data; boundary=AutoSDKBoundary\nAccept: application/json\n\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022prompt\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022negative_prompt\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022seed\u0022\n\n12345\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022resolution\u0022\n\n1280x800\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022aspect_ratio\u0022\n\nauto\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022rendering_speed\u0022\n\ndefault\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022magic_prompt\u0022\n\nauto\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022num_images\u0022\n\n1\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022color_palette\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_codes\u0022\n\nABCD1234\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_type\u0022\n\ngeneral\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_preset\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_reference_collection_id\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_reference_collection_version_id\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_reference_asset_identifiers\u0022\n\n{\u0022asset_type\u0022:\u0022RESPONSE\u0022,\u0022asset_id\u0022:\u00227uS_VESkRI6O3-sVgHQp_A\u0022}\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_reference_images\u0022; filename=\u0022style_reference_images.bin\u0022\nContent-Type: application/octet-stream\n\n\u003C ./style_reference_images.bin\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022enable_copyright_detection\u0022\n\ntrue\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022async\u0022\n\nfalse\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022webhook_url\u0022\n\nhttps://api.example.com/webhooks/ideogram\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022private\u0022\n\ntrue\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022target_collection_id\u0022\n\nstring\n--AutoSDKBoundary--\n\n## Responses\n# 200\n# Description: The generated images (synchronous requests), or an acknowledgement to poll with \u0060GET /v1/generations/{generation_id}\u0060 (\u0060async\u0060 requests).\n# Content-Type: application/json\n# 400\n# Description: Invalid input provided.\n# 401\n# Description: Unauthorized.\n# 402\n# Description: Insufficient credits or quota.\n# Content-Type: application/json\n# 404\n# Description: A referenced style collection or asset was not found.\n# 422\n# Description: The prompt did not pass safety checks.\n# 429\n# Description: Too many requests.\n# Content-Type: application/json\n# 500\n# Description: Internal server error.\n# 503\n# Description: The endpoint is temporarily unavailable.", "Format": "http", "OperationId": "post_generate_image_v2_ideogram_v3", "Setup": null @@ -1018,7 +1018,7 @@ "Slug": "post-generate-image-v2-ideogram-v3-character", "Description": "Generate one or more images featuring a consistent character with\nIdeogram 3.0. Supply the character as a saved character\n(\u0060character_reference_collection_id\u0060), as\n\u0060character_reference_asset_identifiers\u0060 references (an image already\nstored with Ideogram), or as raw \u0060character_reference_images\u0060 bytes\n(multipart requests only, with an optional\n\u0060character_reference_mask\u0060 marking where the character is in the\nreference). If more than one form is supplied, the collection wins\nover the identifiers, and the identifiers win over the bytes.\n\nStyle references may be combined with the character on accounts with\naccess; otherwise the combination returns a 400. Supply them as a\nsaved style (\u0060style_reference_collection_id\u0060), as\n\u0060style_reference_asset_identifiers\u0060 references, or as raw\n\u0060style_reference_images\u0060 bytes, with the same precedence as the\ncharacter forms.\n\nBy default the request blocks until the images are ready and returns\nthem in \u0060data\u0060. Set \u0060async\u0060 to true to return immediately after the\nrequest is accepted, then poll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using the returned\n\u0060generation_id\u0060.\n\nSupplying a \u0060webhook_url\u0060 makes the request asynchronous whatever\n\u0060async\u0060 says: the response returns as soon as the request is accepted,\nand the finished result is POSTed to that URL.", "Language": "http", - "Code": "### Generate images of a consistent character with Ideogram 3.0\n# @name post_generate_image_v2_ideogram_v3_character\nPOST {{host}}/v2/image/generate/ideogram-3-character?dry_run=false\nAuthorization: Bearer {{token}}\nContent-Type: multipart/form-data; boundary=AutoSDKBoundary\nAccept: application/json\n\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022prompt\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022negative_prompt\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022character_reference_collection_id\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022character_reference_collection_version_id\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022character_reference_asset_identifiers\u0022\n\n{\u0022asset_type\u0022:\u0022RESPONSE\u0022,\u0022asset_id\u0022:\u00227uS_VESkRI6O3-sVgHQp_A\u0022}\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022character_reference_images\u0022; filename=\u0022character_reference_images.bin\u0022\nContent-Type: application/octet-stream\n\n\u003C ./character_reference_images.bin\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022character_reference_mask\u0022; filename=\u0022character_reference_mask.bin\u0022\nContent-Type: application/octet-stream\n\n\u003C ./character_reference_mask.bin\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022seed\u0022\n\n12345\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022resolution\u0022\n\n1280x800\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022aspect_ratio\u0022\n\n1x3\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022rendering_speed\u0022\n\ndefault\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022magic_prompt\u0022\n\nauto\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022num_images\u0022\n\n1\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_type\u0022\n\nauto\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_reference_collection_id\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_reference_collection_version_id\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_reference_asset_identifiers\u0022\n\n{\u0022asset_type\u0022:\u0022RESPONSE\u0022,\u0022asset_id\u0022:\u00227uS_VESkRI6O3-sVgHQp_A\u0022}\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_reference_images\u0022; filename=\u0022style_reference_images.bin\u0022\nContent-Type: application/octet-stream\n\n\u003C ./style_reference_images.bin\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022enable_copyright_detection\u0022\n\ntrue\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022async\u0022\n\nfalse\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022webhook_url\u0022\n\nhttps://api.example.com/webhooks/ideogram\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022private\u0022\n\ntrue\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022target_collection_id\u0022\n\nstring\n--AutoSDKBoundary--\n\n## Responses\n# 200\n# Description: The generated images (synchronous requests), or an acknowledgement to poll with \u0060GET /v1/generations/{generation_id}\u0060 (\u0060async\u0060 requests).\n# Content-Type: application/json\n# 400\n# Description: Invalid input provided.\n# 401\n# Description: Unauthorized.\n# 402\n# Description: Insufficient credits or quota.\n# Content-Type: application/json\n# 404\n# Description: A referenced asset or collection was not found.\n# 422\n# Description: The prompt did not pass safety checks.\n# 429\n# Description: Too many requests.\n# Content-Type: application/json\n# 500\n# Description: Internal server error.\n# 503\n# Description: The endpoint is temporarily unavailable.", + "Code": "### Generate images of a consistent character with Ideogram 3.0\n# @name post_generate_image_v2_ideogram_v3_character\nPOST {{host}}/v2/image/generate/ideogram-3-character?dry_run=false\nAuthorization: Bearer {{token}}\nContent-Type: multipart/form-data; boundary=AutoSDKBoundary\nAccept: application/json\n\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022prompt\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022negative_prompt\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022character_reference_collection_id\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022character_reference_collection_version_id\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022character_reference_asset_identifiers\u0022\n\n{\u0022asset_type\u0022:\u0022RESPONSE\u0022,\u0022asset_id\u0022:\u00227uS_VESkRI6O3-sVgHQp_A\u0022}\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022character_reference_images\u0022; filename=\u0022character_reference_images.bin\u0022\nContent-Type: application/octet-stream\n\n\u003C ./character_reference_images.bin\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022character_reference_mask\u0022; filename=\u0022character_reference_mask.bin\u0022\nContent-Type: application/octet-stream\n\n\u003C ./character_reference_mask.bin\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022seed\u0022\n\n12345\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022resolution\u0022\n\n1280x800\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022aspect_ratio\u0022\n\nauto\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022rendering_speed\u0022\n\ndefault\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022magic_prompt\u0022\n\nauto\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022num_images\u0022\n\n1\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_type\u0022\n\nauto\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_reference_collection_id\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_reference_collection_version_id\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_reference_asset_identifiers\u0022\n\n{\u0022asset_type\u0022:\u0022RESPONSE\u0022,\u0022asset_id\u0022:\u00227uS_VESkRI6O3-sVgHQp_A\u0022}\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_reference_images\u0022; filename=\u0022style_reference_images.bin\u0022\nContent-Type: application/octet-stream\n\n\u003C ./style_reference_images.bin\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022enable_copyright_detection\u0022\n\ntrue\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022async\u0022\n\nfalse\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022webhook_url\u0022\n\nhttps://api.example.com/webhooks/ideogram\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022private\u0022\n\ntrue\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022target_collection_id\u0022\n\nstring\n--AutoSDKBoundary--\n\n## Responses\n# 200\n# Description: The generated images (synchronous requests), or an acknowledgement to poll with \u0060GET /v1/generations/{generation_id}\u0060 (\u0060async\u0060 requests).\n# Content-Type: application/json\n# 400\n# Description: Invalid input provided.\n# 401\n# Description: Unauthorized.\n# 402\n# Description: Insufficient credits or quota.\n# Content-Type: application/json\n# 404\n# Description: A referenced asset or collection was not found.\n# 422\n# Description: The prompt did not pass safety checks.\n# 429\n# Description: Too many requests.\n# Content-Type: application/json\n# 500\n# Description: Internal server error.\n# 503\n# Description: The endpoint is temporarily unavailable.", "Format": "http", "OperationId": "post_generate_image_v2_ideogram_v3_character", "Setup": null @@ -1029,7 +1029,7 @@ "Slug": "post-generate-image-v2-ideogram-v3-custom-model", "Description": "Generate one or more images with a custom Ideogram 3.0 model that the\nauthenticated user or organization can access. The model registry\ncontrols the model\u0027s supported rendering speeds and whether it removes\nbackgrounds automatically.\n\nBy default the request blocks until the images are ready and returns\nthem in \u0060data\u0060. Set \u0060async\u0060 to true to return immediately after the\nrequest is accepted, then poll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using the returned\n\u0060generation_id\u0060.\n\nSupplying a \u0060webhook_url\u0060 makes the request asynchronous whatever\n\u0060async\u0060 says: the response returns as soon as the request is accepted,\nand the finished result is POSTed to that URL.", "Language": "http", - "Code": "### Generate images with a custom Ideogram 3.0 model\n# @name post_generate_image_v2_ideogram_v3_custom_model\nPOST {{host}}/v2/image/generate/ideogram-3-custom-model?dry_run=false\nAuthorization: Bearer {{token}}\nContent-Type: multipart/form-data; boundary=AutoSDKBoundary\nAccept: application/json\n\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022prompt\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022custom_model_uri\u0022\n\nmodel/my-custom-model/version/1\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022negative_prompt\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022seed\u0022\n\n12345\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022resolution\u0022\n\n1280x800\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022aspect_ratio\u0022\n\n1x3\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022rendering_speed\u0022\n\nturbo\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022magic_prompt\u0022\n\nauto\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022num_images\u0022\n\n1\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022color_palette\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_codes\u0022\n\nABCD1234\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_preset\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_reference_asset_identifiers\u0022\n\n{\u0022asset_type\u0022:\u0022RESPONSE\u0022,\u0022asset_id\u0022:\u00227uS_VESkRI6O3-sVgHQp_A\u0022}\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_reference_images\u0022; filename=\u0022style_reference_images.bin\u0022\nContent-Type: application/octet-stream\n\n\u003C ./style_reference_images.bin\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022enable_copyright_detection\u0022\n\ntrue\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022async\u0022\n\nfalse\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022webhook_url\u0022\n\nhttps://api.example.com/webhooks/ideogram\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022private\u0022\n\ntrue\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022target_collection_id\u0022\n\nstring\n--AutoSDKBoundary--\n\n## Responses\n# 200\n# Description: The generated images (synchronous requests), or an acknowledgement to poll with \u0060GET /v1/generations/{generation_id}\u0060 (\u0060async\u0060 requests).\n# Content-Type: application/json\n# 400\n# Description: Invalid input or an unsupported model option.\n# 401\n# Description: Unauthorized.\n# 402\n# Description: Insufficient credits or quota.\n# Content-Type: application/json\n# 403\n# Description: The custom model does not exist or is not accessible to this user or organization.\n# 404\n# Description: A referenced style asset was not found.\n# 422\n# Description: The prompt did not pass safety checks.\n# 429\n# Description: Too many requests.\n# Content-Type: application/json\n# 500\n# Description: Internal server error.\n# 503\n# Description: The endpoint is temporarily unavailable.", + "Code": "### Generate images with a custom Ideogram 3.0 model\n# @name post_generate_image_v2_ideogram_v3_custom_model\nPOST {{host}}/v2/image/generate/ideogram-3-custom-model?dry_run=false\nAuthorization: Bearer {{token}}\nContent-Type: multipart/form-data; boundary=AutoSDKBoundary\nAccept: application/json\n\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022prompt\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022custom_model_uri\u0022\n\nmodel/my-custom-model/version/1\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022negative_prompt\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022seed\u0022\n\n12345\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022resolution\u0022\n\n1280x800\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022aspect_ratio\u0022\n\nauto\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022rendering_speed\u0022\n\nturbo\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022magic_prompt\u0022\n\nauto\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022num_images\u0022\n\n1\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022color_palette\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_codes\u0022\n\nABCD1234\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_preset\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_reference_asset_identifiers\u0022\n\n{\u0022asset_type\u0022:\u0022RESPONSE\u0022,\u0022asset_id\u0022:\u00227uS_VESkRI6O3-sVgHQp_A\u0022}\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022style_reference_images\u0022; filename=\u0022style_reference_images.bin\u0022\nContent-Type: application/octet-stream\n\n\u003C ./style_reference_images.bin\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022enable_copyright_detection\u0022\n\ntrue\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022async\u0022\n\nfalse\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022webhook_url\u0022\n\nhttps://api.example.com/webhooks/ideogram\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022private\u0022\n\ntrue\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022target_collection_id\u0022\n\nstring\n--AutoSDKBoundary--\n\n## Responses\n# 200\n# Description: The generated images (synchronous requests), or an acknowledgement to poll with \u0060GET /v1/generations/{generation_id}\u0060 (\u0060async\u0060 requests).\n# Content-Type: application/json\n# 400\n# Description: Invalid input or an unsupported model option.\n# 401\n# Description: Unauthorized.\n# 402\n# Description: Insufficient credits or quota.\n# Content-Type: application/json\n# 403\n# Description: The custom model does not exist or is not accessible to this user or organization.\n# 404\n# Description: A referenced style asset was not found.\n# 422\n# Description: The prompt did not pass safety checks.\n# 429\n# Description: Too many requests.\n# Content-Type: application/json\n# 500\n# Description: Internal server error.\n# 503\n# Description: The endpoint is temporarily unavailable.", "Format": "http", "OperationId": "post_generate_image_v2_ideogram_v3_custom_model", "Setup": null @@ -1157,6 +1157,17 @@ }, { "Order": 106, + "Title": "Edit an image with Ideogram 4.5, keeping the source\u0027s exact geometry", + "Slug": "post-precise-edit-image-v2-ideogram45", + "Description": "Edit an image with Ideogram 4.5, returning output at that image\u0027s exact\nwidth and height. An image too large for the model is scaled down to\nfit while keeping its exact proportion, and one whose aspect ratio is\noutside 1:6 to 6:1 is rejected \u2014 this endpoint never reshapes, so there\nis no size to reshape it to. Unlike\n\u0060POST /v2/image/generate/ideogram-4-5\u0060, this endpoint takes no \u0060size\u0060:\nthe output always matches the image being edited, so the edit drops\nback into whatever it came from without reframing.\n\nSupply the image to edit as an \u0060image_asset_identifier\u0060 reference or as\nraw \u0060image\u0060 bytes (multipart requests only); if both are supplied, the\nreference wins and the bytes are ignored. Add up to four more images\nvia \u0060reference_image_asset_identifiers\u0060 or \u0060reference_images\u0060 to guide\nthe edit \u2014 those are never edited themselves.\n\nSupply a \u0060mask\u0060 to confine the edit to part of the image being edited.\nThe mask is optional \u2014 without one the prompt is applied to the whole\nimage. Masks are read as an additional reference image, so a masked\nrequest may carry at most three \u0060reference_images\u0060.\n\nThe \u0060prompt\u0060 is the edit instruction. It accepts either natural\nlanguage or a structured JSON prompt; the server detects which was\nsupplied. A natural-language instruction is automatically rewritten\ninto the model\u0027s structured edit contract, while a prompt that is\nalready valid structured JSON is consumed directly.\n\nBy default the request blocks until the images are ready and returns\nthem in \u0060data\u0060. Set \u0060async\u0060 to true to return immediately after the\nrequest is accepted, then poll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using the returned\n\u0060generation_id\u0060.\n\nSupplying a \u0060webhook_url\u0060 makes the request asynchronous whatever\n\u0060async\u0060 says: the response returns as soon as the request is accepted,\nand the finished result is POSTed to that URL.", + "Language": "http", + "Code": "### Edit an image with Ideogram 4.5, keeping the source\u0027s exact geometry\n# @name post_precise_edit_image_v2_ideogram45\nPOST {{host}}/v2/image/precise-edit/ideogram-4-5?dry_run=false\nAuthorization: Bearer {{token}}\nContent-Type: multipart/form-data; boundary=AutoSDKBoundary\nAccept: application/json\n\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022prompt\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022image_asset_identifier\u0022\n\nstring\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022image\u0022; filename=\u0022image.bin\u0022\nContent-Type: application/octet-stream\n\n\u003C ./image.bin\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022reference_image_asset_identifiers\u0022\n\n{\u0022asset_type\u0022:\u0022RESPONSE\u0022,\u0022asset_id\u0022:\u00227uS_VESkRI6O3-sVgHQp_A\u0022}\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022reference_images\u0022; filename=\u0022reference_images.bin\u0022\nContent-Type: application/octet-stream\n\n\u003C ./reference_images.bin\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022mask\u0022; filename=\u0022mask.bin\u0022\nContent-Type: application/octet-stream\n\n\u003C ./mask.bin\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022rendering_speed\u0022\n\ndefault\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022seed\u0022\n\n12345\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022num_images\u0022\n\n1\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022enable_copyright_detection\u0022\n\ntrue\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022async\u0022\n\nfalse\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022webhook_url\u0022\n\nhttps://api.example.com/webhooks/ideogram\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022private\u0022\n\ntrue\n--AutoSDKBoundary\nContent-Disposition: form-data; name=\u0022target_collection_id\u0022\n\nstring\n--AutoSDKBoundary--\n\n## Responses\n# 200\n# Description: The edited images (synchronous requests), or an acknowledgement to poll with \u0060GET /v1/generations/{generation_id}\u0060 (\u0060async\u0060 requests).\n# Content-Type: application/json\n# 400\n# Description: Invalid input provided.\n# 401\n# Description: Unauthorized.\n# 402\n# Description: Insufficient credits or quota.\n# Content-Type: application/json\n# 422\n# Description: The prompt did not pass safety checks.\n# 429\n# Description: Too many requests.\n# Content-Type: application/json\n# 500\n# Description: Internal server error.\n# 503\n# Description: The endpoint is temporarily unavailable.", + "Format": "http", + "OperationId": "post_precise_edit_image_v2_ideogram45", + "Setup": null + }, + { + "Order": 107, "Title": "Reframe an image with Ideogram 3.0, by asset id or by uploaded bytes", "Slug": "post-reframe-image-v2-ideogram-v3", "Description": "Expand an image to a new Ideogram 3.0 resolution. The source pixels\nare preserved in the center and Ideogram fills the new area. Supply\nexactly one source: an \u0060AssetIdentifier\u0060 reference\n(\u0060image_asset_identifier\u0060) or raw image bytes (\u0060image\u0060, multipart\nrequests only). Supplying both forms, or neither, is rejected.\n\nOptional style controls are mutually exclusive. Supply at most one of\n\u0060style_preset\u0060, \u0060style_codes\u0060, \u0060style_reference_asset_identifiers\u0060, or\nraw \u0060style_reference_images\u0060 (multipart requests only). Each style\nreference transport accepts at most 10 images.\n\nBy default the request blocks until the images are ready and returns\nthem in \u0060data\u0060. Set \u0060async\u0060 to true to return immediately, then poll\n\u0060GET /v1/generations/{generation_id}\u0060.", @@ -1167,7 +1178,7 @@ "Setup": null }, { - "Order": 107, + "Order": 108, "Title": "Reframe an image with Nano Banana 2", "Slug": "post-reframe-image-nano-banana2", "Description": "Expand one image to a new aspect ratio with Nano Banana 2.\nSupply either an existing Ideogram image asset or raw image bytes,\nbut not both. The requested aspect ratio is resolved to the closest\nsupported 1K output dimensions.\n\nThis operation is asynchronous. It returns as soon as the request is\naccepted; poll \u0060GET /v1/generations/{generation_id}\u0060 for completion\nand results.", @@ -1178,7 +1189,7 @@ "Setup": null }, { - "Order": 108, + "Order": 109, "Title": "Remix an existing image with Ideogram 3.0, guided by a prompt", "Slug": "post-remix-image-v2-ideogram-v3", "Description": "Transform an existing image with Ideogram 3.0, guided by a text\nprompt. Supply the source either as an \u0060image_asset_identifier\u0060\nreference (an image already stored with Ideogram) or as raw \u0060image\u0060\nbytes (multipart requests only). Supplying both is rejected rather\nthan one being ignored. \u0060image_weight\u0060 controls how closely the\nresult follows the source; when omitted the server picks a value from\nyour prompt.\n\nOmit \u0060resolution\u0060 and \u0060aspect_ratio\u0060 to keep the source image\u0027s\nshape. If you request a different shape, the source is center-cropped\nto fit it first, and whatever falls outside the new shape is\ndiscarded.\n\nOptional style controls work as on the Ideogram 3.0 generate\nendpoint: style codes, a style preset, a color palette, or style\nreference images.\n\nBy default the request blocks until the images are ready and returns\nthem in \u0060data\u0060. Set \u0060async\u0060 to true to return immediately after the\nrequest is accepted, then poll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using the returned\n\u0060generation_id\u0060.\n\nSupplying a \u0060webhook_url\u0060 makes the request asynchronous whatever\n\u0060async\u0060 says: the response returns as soon as the request is accepted,\nand the finished result is POSTed to that URL.", @@ -1189,7 +1200,7 @@ "Setup": null }, { - "Order": 109, + "Order": 110, "Title": "Remix an existing image with Ideogram 3.0, featuring a consistent character", "Slug": "post-remix-image-v2-ideogram-v3-character", "Description": "Transform an existing image with Ideogram 3.0, guided by a text\nprompt and featuring a consistent character. Supply the source either\nas an \u0060image_asset_identifier\u0060 reference (an image already stored\nwith Ideogram) or as raw \u0060image\u0060 bytes (multipart requests only).\nSupplying both is rejected rather than one being ignored.\n\u0060image_weight\u0060 controls how closely the result follows the source;\nwhen omitted the server picks a value from your prompt.\n\nSupply the character as a saved character\n(\u0060character_reference_collection_id\u0060), as\n\u0060character_reference_asset_identifiers\u0060 references, or as raw\n\u0060character_reference_images\u0060 bytes (multipart requests only, with an\noptional \u0060character_reference_mask\u0060 marking where the character is in\nthe reference). If more than one form is supplied, the collection\nwins over the identifiers, and the identifiers win over the bytes.\n\nOmit \u0060resolution\u0060 and \u0060aspect_ratio\u0060 to keep the source image\u0027s\nshape. If you request a different shape, the source is center-cropped\nto fit it first, and whatever falls outside the new shape is\ndiscarded.\n\nStyle references may be supplied as a saved style\n(\u0060style_reference_collection_id\u0060), as\n\u0060style_reference_asset_identifiers\u0060 references, or as raw\n\u0060style_reference_images\u0060 bytes, with the same precedence as the\ncharacter forms.\n\nBy default the request blocks until the images are ready and returns\nthem in \u0060data\u0060. Set \u0060async\u0060 to true to return immediately after the\nrequest is accepted, then poll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using the returned\n\u0060generation_id\u0060.\n\nSupplying a \u0060webhook_url\u0060 makes the request asynchronous whatever\n\u0060async\u0060 says: the response returns as soon as the request is accepted,\nand the finished result is POSTed to that URL.", @@ -1200,7 +1211,7 @@ "Setup": null }, { - "Order": 110, + "Order": 111, "Title": "Remix an existing image with a custom Ideogram 3.0 model", "Slug": "post-remix-image-v2-ideogram-v3-custom-model", "Description": "Transform an existing image with a custom Ideogram 3.0 model that the\nauthenticated user or organization can access, guided by a text\nprompt. Supply the source either as an \u0060image_asset_identifier\u0060\nreference (an image already stored with Ideogram) or as raw \u0060image\u0060\nbytes (multipart requests only). Supplying both is rejected rather\nthan one being ignored. \u0060image_weight\u0060 controls how closely the\nresult follows the source; when omitted the server picks a value from\nyour prompt.\n\nOmit \u0060resolution\u0060 and \u0060aspect_ratio\u0060 to keep the source image\u0027s\nshape. If you request a different shape, the source is center-cropped\nto fit it first, and whatever falls outside the new shape is\ndiscarded.\n\nBy default the request blocks until the images are ready and returns\nthem in \u0060data\u0060. Set \u0060async\u0060 to true to return immediately after the\nrequest is accepted, then poll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using the returned\n\u0060generation_id\u0060.\n\nSupplying a \u0060webhook_url\u0060 makes the request asynchronous whatever\n\u0060async\u0060 says: the response returns as soon as the request is accepted,\nand the finished result is POSTed to that URL.", @@ -1211,7 +1222,7 @@ "Setup": null }, { - "Order": 111, + "Order": 112, "Title": "Remix an existing image with Ideogram 4.0, guided by a prompt", "Slug": "post-remix-image-v2-ideogram-v4", "Description": "Transform an existing image with Ideogram 4.0, guided by a text\nprompt. Supply the source either as an \u0060image_asset_identifier\u0060\nreference (an image already stored with Ideogram) or as raw \u0060image\u0060\nbytes (multipart requests only). Supplying both is rejected rather\nthan one being ignored. \u0060image_weight\u0060 controls how closely the\nresult follows the source; when omitted the server picks a value from\nyour prompt.\n\nOmit \u0060resolution\u0060 to keep the source image\u0027s shape. A \u0060resolution\u0060\nwhose aspect ratio differs from the source\u0027s cannot be combined with\n\u0060image_weight\u0060 \u2014 that request is rejected with a 400.\n\nThe prompt is always interpreted by an instruction-editing model, so\nthere is no \u0060magic_prompt\u0060 option. Remixes are not reproducible, so\nno seed is accepted; the response reports the seed the request\nresolved to.\n\nBy default the request blocks until the images are ready and returns\nthem in \u0060data\u0060. Set \u0060async\u0060 to true to return immediately after the\nrequest is accepted, then poll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using the returned\n\u0060generation_id\u0060.\n\nSupplying a \u0060webhook_url\u0060 makes the request asynchronous whatever\n\u0060async\u0060 says: the response returns as soon as the request is accepted,\nand the finished result is POSTed to that URL.", @@ -1222,7 +1233,7 @@ "Setup": null }, { - "Order": 112, + "Order": 113, "Title": "Upscale an image with Nano Banana Pro, by asset id or by uploaded bytes", "Slug": "post-upscale-image-nano-banana-pro", "Description": "Regenerate the source image at a higher resolution tier (1K, 2K, or\n4K) while preserving its content, composition, and style. Supply the\nsource either as an \u0060image_asset_identifier\u0060 reference (an image\nalready stored with Ideogram) or as raw \u0060image\u0060 bytes (multipart\nrequests only) \u2014 callers are never required to upload the asset\nfirst. If both are supplied, the reference wins and the bytes are\nignored. Uploaded bytes are used for this request only and are not\nstored as an asset; upscales of a referenced asset keep a visible\nlink to their source image.\n\nAn optional \u0060prompt\u0060 adds short guidance for the enhancement; the\nimage is otherwise upscaled as-is. The source must be smaller than\nthe requested \u0060resolution_tier\u0060.\n\nBy default the request blocks until the upscaled image is ready and\nreturns it in \u0060data\u0060. Set \u0060async\u0060 to true to return immediately after\nthe request is accepted, then poll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using the returned\n\u0060generation_id\u0060.\n\nSupplying a \u0060webhook_url\u0060 makes the request asynchronous whatever\n\u0060async\u0060 says: the response returns as soon as the request is accepted,\nand the finished result is POSTed to that URL.", @@ -1233,7 +1244,7 @@ "Setup": null }, { - "Order": 113, + "Order": 114, "Title": "Upscale an image with Topaz Bloom 2, by asset id or by uploaded bytes", "Slug": "post-upscale-image-topaz-bloom2", "Description": "Creatively upscale one image to 2x, 4x, or 8x its original resolution,\nup to a maximum output of 8192px per side. Supply the source either as\nan \u0060image_asset_identifier\u0060 reference (an image already stored with\nIdeogram) or as raw \u0060image\u0060 bytes (multipart requests only) \u2014 callers\nare never required to upload the asset first. If both are supplied,\nthe reference wins and the bytes are ignored. Uploaded bytes are used\nfor this request only and are not stored as an asset; upscales of a\nreferenced asset keep a visible link to their source image.\n\nAn optional \u0060prompt\u0060 guides the regenerated detail, and \u0060creativity\u0060\ncontrols how strongly the model reinterprets the source while\nenlarging it.\n\nBy default the request blocks until the upscaled image is ready and\nreturns it in \u0060data\u0060. Set \u0060async\u0060 to true to return immediately after\nthe request is accepted, then poll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using the returned\n\u0060generation_id\u0060.\n\nSupplying a \u0060webhook_url\u0060 makes the request asynchronous whatever\n\u0060async\u0060 says: the response returns as soon as the request is accepted,\nand the finished result is POSTed to that URL.", @@ -1244,7 +1255,7 @@ "Setup": null }, { - "Order": 114, + "Order": 115, "Title": "Upscale an image with Topaz Redefine, by asset id or by uploaded bytes", "Slug": "post-upscale-image-topaz-redefine", "Description": "Creatively upscale one image to 2x, 4x, or 8x its original resolution,\nup to a maximum output of 8192px per side. Supply the source either as\nan \u0060image_asset_identifier\u0060 reference (an image already stored with\nIdeogram) or as raw \u0060image\u0060 bytes (multipart requests only) \u2014 callers\nare never required to upload the asset first. If both are supplied,\nthe reference wins and the bytes are ignored. Uploaded bytes are used\nfor this request only and are not stored as an asset; upscales of a\nreferenced asset keep a visible link to their source image.\n\nAn optional \u0060prompt\u0060 guides the regenerated detail, or \u0060autoprompt\u0060\nlets the model describe the image itself. \u0060creativity\u0060 controls how\nstrongly the model reinterprets the source, \u0060texture\u0060 how much fine\ntexture it adds, and the precision knobs (sharpen, denoise, detail,\nface enhancement, subject detection) refine the result.\n\nBy default the request blocks until the upscaled image is ready and\nreturns it in \u0060data\u0060. Set \u0060async\u0060 to true to return immediately after\nthe request is accepted, then poll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using the returned\n\u0060generation_id\u0060.\n\nSupplying a \u0060webhook_url\u0060 makes the request asynchronous whatever\n\u0060async\u0060 says: the response returns as soon as the request is accepted,\nand the finished result is POSTed to that URL.", @@ -1255,7 +1266,7 @@ "Setup": null }, { - "Order": 115, + "Order": 116, "Title": "Upscale an image with Topaz Standard V2, by asset id or by uploaded bytes", "Slug": "post-upscale-image-topaz-standard-v2", "Description": "Upscale one image to 2x, 4x, or 8x its original resolution, up to a\nmaximum output of 8192px per side. Supply the source either as an\n\u0060image_asset_identifier\u0060 reference (an image already stored with\nIdeogram) or as raw \u0060image\u0060 bytes (multipart requests only) \u2014 callers\nare never required to upload the asset first. If both are supplied,\nthe reference wins and the bytes are ignored. Uploaded bytes are used\nfor this request only and are not stored as an asset; upscales of a\nreferenced asset keep a visible link to their source image.\n\nUpscaling takes no prompt: the model enhances the source image as-is.\n\nBy default the request blocks until the upscaled image is ready and\nreturns it in \u0060data\u0060. Set \u0060async\u0060 to true to return immediately after\nthe request is accepted, then poll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using the returned\n\u0060generation_id\u0060.\n\nSupplying a \u0060webhook_url\u0060 makes the request asynchronous whatever\n\u0060async\u0060 says: the response returns as soon as the request is accepted,\nand the finished result is POSTed to that URL.", @@ -1266,7 +1277,7 @@ "Setup": null }, { - "Order": 116, + "Order": 117, "Title": "Upscale an image with Topaz Text Refine, by asset id or by uploaded bytes", "Slug": "post-upscale-image-topaz-text-refine", "Description": "Upscale one image to 2x, 4x, or 8x its original resolution, up to a\nmaximum output of 8192px per side. Supply the source either as an\n\u0060image_asset_identifier\u0060 reference (an image already stored with\nIdeogram) or as raw \u0060image\u0060 bytes (multipart requests only) \u2014 callers\nare never required to upload the asset first. If both are supplied,\nthe reference wins and the bytes are ignored. Uploaded bytes are used\nfor this request only and are not stored as an asset; upscales of a\nreferenced asset keep a visible link to their source image.\n\nUpscaling takes no prompt: the model enhances the source image as-is.\n\nBy default the request blocks until the upscaled image is ready and\nreturns it in \u0060data\u0060. Set \u0060async\u0060 to true to return immediately after\nthe request is accepted, then poll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using the returned\n\u0060generation_id\u0060.\n\nSupplying a \u0060webhook_url\u0060 makes the request asynchronous whatever\n\u0060async\u0060 says: the response returns as soon as the request is accepted,\nand the finished result is POSTed to that URL.", @@ -1277,7 +1288,7 @@ "Setup": null }, { - "Order": 117, + "Order": 118, "Title": "Upscale an image with Topaz Wonder 3.5, by asset id or by uploaded bytes", "Slug": "post-upscale-image-topaz-wonder35", "Description": "Upscale one image to 2x, 4x, or 8x its original resolution, up to a\nmaximum output of 8192px per side. Supply the source either as an\n\u0060image_asset_identifier\u0060 reference (an image already stored with\nIdeogram) or as raw \u0060image\u0060 bytes (multipart requests only) \u2014 callers\nare never required to upload the asset first. If both are supplied,\nthe reference wins and the bytes are ignored. Uploaded bytes are used\nfor this request only and are not stored as an asset; upscales of a\nreferenced asset keep a visible link to their source image.\n\nUpscaling takes no prompt: the model enhances the source image as-is.\nUse \u0060enhancement_strength\u0060 to control how strongly the generative\nmodel reconstructs detail.\n\nBy default the request blocks until the upscaled image is ready and\nreturns it in \u0060data\u0060. Set \u0060async\u0060 to true to return immediately after\nthe request is accepted, then poll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using the returned\n\u0060generation_id\u0060.\n\nSupplying a \u0060webhook_url\u0060 makes the request asynchronous whatever\n\u0060async\u0060 says: the response returns as soon as the request is accepted,\nand the finished result is POSTed to that URL.", @@ -1288,7 +1299,7 @@ "Setup": null }, { - "Order": 118, + "Order": 119, "Title": "Fetch the media bytes for an integration asset", "Slug": "get-integration-asset-delivery", "Description": "Redeems the short-lived signed delivery reference returned by an integration asset search and streams the asset\u0027s media bytes. The signed reference is the sole authorization for this endpoint; it is rejected once it expires or when the integration it names has changed.", @@ -1299,7 +1310,7 @@ "Setup": null }, { - "Order": 119, + "Order": 120, "Title": "List enabled integration types", "Slug": "get-integrations", "Description": "Lists the distinct integration types enabled for the authenticated organization. The response does not expose configured integration rows, provider details, configuration, or credentials.", @@ -1310,7 +1321,7 @@ "Setup": "This example assumes \u0060using Ideogram;\u0060 is in scope and \u0060apiKey\u0060 contains the required credential." }, { - "Order": 120, + "Order": 121, "Title": "Search assets from an enabled integration type", "Slug": "post-integration-assets-search", "Description": "Generated from OpenAPI examples.", @@ -1321,7 +1332,7 @@ "Setup": "This example assumes \u0060using Ideogram;\u0060 is in scope and \u0060apiKey\u0060 contains the required credential." }, { - "Order": 121, + "Order": 122, "Title": "Testing", "Slug": "post-internal-testing", "Description": "Just a testing endpoint", @@ -1332,7 +1343,7 @@ "Setup": null }, { - "Order": 122, + "Order": 123, "Title": "Add members to a specific organization", "Slug": "add-organization-members", "Description": "Generated from OpenAPI examples.", @@ -1343,7 +1354,7 @@ "Setup": null }, { - "Order": 123, + "Order": 124, "Title": "Cancel a pending invite for an organization", "Slug": "cancel-organization-invite", "Description": "Generated from OpenAPI examples.", @@ -1354,7 +1365,7 @@ "Setup": null }, { - "Order": 124, + "Order": 125, "Title": "Creates an API key.", "Slug": "create-api-key", "Description": "Generated from OpenAPI examples.", @@ -1365,7 +1376,7 @@ "Setup": "This example assumes \u0060using Ideogram;\u0060 is in scope and \u0060apiKey\u0060 contains the required credential." }, { - "Order": 125, + "Order": 126, "Title": "Create an API key for a specific organization", "Slug": "create-api-key-v2", "Description": "Generated from OpenAPI examples.", @@ -1376,7 +1387,7 @@ "Setup": null }, { - "Order": 126, + "Order": 127, "Title": "Create a payment setup session for inline card collection.", "Slug": "create-api-payment", "Description": "Returns a client_secret for the org\u0027s payment customer so the inline payment\nmodal can save a card without leaving the app.\n\nSoft-deprecated: the inline Elements flow was removed in the Stripe.js\neager-bundle incident (2026-05-20). New clients should use the\nstripe_payment_setup_url field on ManageApiStripeSubscriptionResponse, which\nreturns a hosted Stripe Checkout URL instead. This endpoint will be formally\ndeprecated and then removed once no callers reference it.", @@ -1387,7 +1398,7 @@ "Setup": null }, { - "Order": 127, + "Order": 128, "Title": "Delete an API key.", "Slug": "delete-single-api-key", "Description": "Generated from OpenAPI examples.", @@ -1398,7 +1409,7 @@ "Setup": "This example assumes \u0060using Ideogram;\u0060 is in scope and \u0060apiKey\u0060 contains the required credential." }, { - "Order": 128, + "Order": 129, "Title": "Demote admins back to member role in a TEAM_API or ENTERPRISE_API organization", "Slug": "demote-organization-admins", "Description": "Generated from OpenAPI examples.", @@ -1409,7 +1420,7 @@ "Setup": null }, { - "Order": 129, + "Order": 130, "Title": "Lifetime credit totals for the API user\u0027s account.", "Slug": "get-api-credit-summary", "Description": "Returns the lifetime credit KPIs (consumed, expired, issued) used to\nrender the API credit dashboard strip. All values default to $0 when\nMetronome is unavailable so the FE can always render.", @@ -1420,7 +1431,7 @@ "Setup": null }, { - "Order": 130, + "Order": 131, "Title": "Retrieve current API keys and their respective data.", "Slug": "get-api-keys", "Description": "Generated from OpenAPI examples.", @@ -1431,7 +1442,7 @@ "Setup": "This example assumes \u0060using Ideogram;\u0060 is in scope and \u0060apiKey\u0060 contains the required credential." }, { - "Order": 131, + "Order": 132, "Title": "Retrieve API keys for a specific organization", "Slug": "get-api-keys-v2", "Description": "Generated from OpenAPI examples.", @@ -1442,7 +1453,7 @@ "Setup": null }, { - "Order": 132, + "Order": 133, "Title": "Get search results for user handles with suggestions for a particular organization.", "Slug": "get-api-organization-user-suggestions", "Description": "Generated from OpenAPI examples.", @@ -1453,7 +1464,7 @@ "Setup": null }, { - "Order": 133, + "Order": 134, "Title": "Retrieve the user\u0027s current API profiles", "Slug": "get-api-profiles", "Description": "Generated from OpenAPI examples.", @@ -1464,7 +1475,7 @@ "Setup": "This example assumes \u0060using Ideogram;\u0060 is in scope and \u0060apiKey\u0060 contains the required credential." }, { - "Order": 134, + "Order": 135, "Title": "Retrieve data relevant to connecting to Stripe.", "Slug": "get-api-stripe-subscription", "Description": "Generated from OpenAPI examples.", @@ -1475,7 +1486,7 @@ "Setup": null }, { - "Order": 135, + "Order": 136, "Title": "Retrieve data relevant to creating an API subscription.", "Slug": "get-api-subscription", "Description": "Generated from OpenAPI examples.", @@ -1486,7 +1497,7 @@ "Setup": null }, { - "Order": 136, + "Order": 137, "Title": "Retrieve the latest terms of service for API usage.", "Slug": "get-api-terms", "Description": "Generated from OpenAPI examples.", @@ -1497,7 +1508,7 @@ "Setup": "This example assumes \u0060using Ideogram;\u0060 is in scope and \u0060apiKey\u0060 contains the required credential." }, { - "Order": 137, + "Order": 138, "Title": "Retrieve the Stripe billing portal URL for a specific organization", "Slug": "get-organization-billing-portal", "Description": "Generated from OpenAPI examples.", @@ -1508,7 +1519,7 @@ "Setup": null }, { - "Order": 138, + "Order": 139, "Title": "Retrieve members of a specific organization", "Slug": "get-organization-members", "Description": "Returns both active members and pending invites for the organization. A pending invite is identified by a non-null invite_status (e.g. PENDING); active members have a null invite_status.", @@ -1519,7 +1530,7 @@ "Setup": null }, { - "Order": 139, + "Order": 140, "Title": "Retrieve usage information segmented by time period with tool-specific breakdowns", "Slug": "get-usage-info", "Description": "Generated from OpenAPI examples.", @@ -1530,7 +1541,7 @@ "Setup": null }, { - "Order": 140, + "Order": 141, "Title": "Retrieve user credit information and spending metrics", "Slug": "get-user-credits", "Description": "Generated from OpenAPI examples.", @@ -1541,7 +1552,7 @@ "Setup": null }, { - "Order": 141, + "Order": 142, "Title": "Retrieve user spend commit information", "Slug": "get-user-spend-commit-info", "Description": "Generated from OpenAPI examples.", @@ -1552,7 +1563,7 @@ "Setup": null }, { - "Order": 142, + "Order": 143, "Title": "Retrieve invoices for a specific organization", "Slug": "list-organization-invoices", "Description": "Generated from OpenAPI examples.", @@ -1563,7 +1574,7 @@ "Setup": null }, { - "Order": 143, + "Order": 144, "Title": "Add credits to an API user\u0027s account.", "Slug": "post-add-credits-for-api", "Description": "Generated from OpenAPI examples.", @@ -1574,7 +1585,7 @@ "Setup": null }, { - "Order": 144, + "Order": 145, "Title": "Update API subscription settings", "Slug": "post-api-subscription", "Description": "Generated from OpenAPI examples.", @@ -1585,7 +1596,7 @@ "Setup": null }, { - "Order": 145, + "Order": 146, "Title": "Accept terms", "Slug": "post-api-terms", "Description": "Generated from OpenAPI examples.", @@ -1596,7 +1607,7 @@ "Setup": "This example assumes \u0060using Ideogram;\u0060 is in scope and \u0060apiKey\u0060 contains the required credential." }, { - "Order": 146, + "Order": 147, "Title": "Promote members to ADMIN role in a TEAM_API or ENTERPRISE_API organization", "Slug": "promote-organization-admins", "Description": "Generated from OpenAPI examples.", @@ -1607,7 +1618,7 @@ "Setup": null }, { - "Order": 147, + "Order": 148, "Title": "Reactivates a subscription by attempting to re-enable Metronome billing.", "Slug": "reactivate-subscription", "Description": "Generated from OpenAPI examples.", @@ -1618,7 +1629,7 @@ "Setup": "This example assumes \u0060using Ideogram;\u0060 is in scope and \u0060apiKey\u0060 contains the required credential." }, { - "Order": 148, + "Order": 149, "Title": "Remove members from a specific organization", "Slug": "remove-organization-members", "Description": "Generated from OpenAPI examples.", @@ -1629,7 +1640,7 @@ "Setup": null }, { - "Order": 149, + "Order": 150, "Title": "Resend a pending invite for an organization", "Slug": "resend-organization-invite", "Description": "Generated from OpenAPI examples.", @@ -1640,7 +1651,7 @@ "Setup": null }, { - "Order": 150, + "Order": 151, "Title": "Update a single field on an organization\u0027s API properties.", "Slug": "update-organization-api-properties", "Description": "Lets an organization owner toggle API-only settings such as\ncopyright_detection_enabled. Updates only the fields explicitly present\nin the request body; absent fields are left unchanged.", @@ -1651,7 +1662,7 @@ "Setup": null }, { - "Order": 151, + "Order": 152, "Title": "Update an API key\u0027s user-supplied label.", "Slug": "update-single-api-key", "Description": "Generated from OpenAPI examples.", @@ -1662,7 +1673,7 @@ "Setup": "This example assumes \u0060using Ideogram;\u0060 is in scope and \u0060apiKey\u0060 contains the required credential." }, { - "Order": 152, + "Order": 153, "Title": "Get stale mini-app preview entries", "Slug": "get-stale-preview-mini-apps", "Description": "Returns preview ids whose most recent successful publish is older than the cutoff. This read-only endpoint does not delete preview entries.", @@ -1673,7 +1684,7 @@ "Setup": null }, { - "Order": 153, + "Order": 154, "Title": "Publish a mini-app catalog entry", "Slug": "publish-mini-app", "Description": "Publishes a mini-app\u0027s catalog entry. Called by the mini-apps deploy pipeline after a deploy to register or refresh a single app, keyed by its unique slug. Re-publishing an existing app refreshes the deploy-managed fields (label, description, embed mode, scopes, image-input support, deployment details, and website) while leaving administrator-managed settings and artwork untouched. Artwork from the request is used only when creating a new app.", @@ -1684,7 +1695,7 @@ "Setup": "This example assumes \u0060using Ideogram;\u0060 is in scope and \u0060apiKey\u0060 contains the required credential." }, { - "Order": 154, + "Order": 155, "Title": "Publish a mini-app preview entry", "Slug": "publish-preview-mini-app", "Description": "Publishes a mini-app preview entry. Called by the mini-apps preview deploy pipeline to register a throwaway preview deploy, keyed by its unique preview id. Re-publishing an existing preview id refreshes every deploy-managed field. Preview entries are independent from the main catalog: they carry no slug, owner, or membership gating, and anyone with the preview link can access the app.", @@ -1695,7 +1706,7 @@ "Setup": "This example assumes \u0060using Ideogram;\u0060 is in scope and \u0060apiKey\u0060 contains the required credential." }, { - "Order": 155, + "Order": 156, "Title": "Unpublish a mini-app preview entry", "Slug": "unpublish-preview-mini-app", "Description": "Deletes a mini-app preview entry by its preview id. Repeated requests succeed when the entry is already absent, so preview teardown can retry safely.", @@ -1706,7 +1717,7 @@ "Setup": null }, { - "Order": 156, + "Order": 157, "Title": "Get model details", "Slug": "get-custom-model", "Description": "Get detailed information about a specific custom model. The user must either own the model or the model must be shared with the user\u0027s organization via the model registry. Returns 404 if the model is not found or not accessible.", @@ -1717,7 +1728,7 @@ "Setup": null }, { - "Order": 157, + "Order": 158, "Title": "List models", "Slug": "list-custom-models", "Description": "Lists custom models for the authenticated user. Use the \u0060scope\u0060 parameter to control which models are returned. If omitted, returns both owned models and models shared with the user\u0027s organization via the model registry. \u0060owned\u0060 returns only models created by the user. \u0060shared\u0060 returns only models shared via the model registry, excluding the user\u0027s own models.", @@ -1728,7 +1739,7 @@ "Setup": "This example assumes \u0060using Ideogram;\u0060 is in scope and \u0060apiKey\u0060 contains the required credential." }, { - "Order": 158, + "Order": 159, "Title": "Train a custom Ideogram v3 model", "Slug": "train-model-v3", "Description": "Start training a custom Ideogram v3 model from a dataset using default hyperparameters. The dataset must contain at least 15 images and a maximum of 100 images.", @@ -1739,7 +1750,7 @@ "Setup": "This example assumes \u0060using Ideogram;\u0060 is in scope and \u0060apiKey\u0060 contains the required credential." }, { - "Order": 159, + "Order": 160, "Title": "Train a custom Ideogram v3 model with advanced hyperparameters", "Slug": "train-model-v3-advanced", "Description": "Start training a custom Ideogram v3 model from a dataset with caller-supplied hyperparameters (training steps, LoRA rank, EMA decay, learning rate). All hyperparameters are optional and fall back to defaults when omitted. The dataset must contain at least 15 images and a maximum of 100 images. Returns the model ID and training status.", @@ -1750,7 +1761,7 @@ "Setup": "This example assumes \u0060using Ideogram;\u0060 is in scope and \u0060apiKey\u0060 contains the required credential." }, { - "Order": 160, + "Order": 161, "Title": "Train a custom Ideogram v4 model", "Slug": "train-model-v4", "Description": "Start training a custom Ideogram v4 model from a dataset using default hyperparameters. The dataset must contain at least 15 images and a maximum of 100 images.", @@ -1761,7 +1772,7 @@ "Setup": "This example assumes \u0060using Ideogram;\u0060 is in scope and \u0060apiKey\u0060 contains the required credential." }, { - "Order": 161, + "Order": 162, "Title": "Train a custom Ideogram v4 model with advanced hyperparameters", "Slug": "train-model-v4-advanced", "Description": "Start training a custom Ideogram v4 model from a dataset with caller-supplied hyperparameters (training steps, LoRA rank, EMA decay, learning rate). All hyperparameters are optional and fall back to defaults when omitted. The dataset must contain at least 15 images and a maximum of 100 images. Returns the model ID and training status.", @@ -1772,7 +1783,7 @@ "Setup": "This example assumes \u0060using Ideogram;\u0060 is in scope and \u0060apiKey\u0060 contains the required credential." }, { - "Order": 162, + "Order": 163, "Title": "Remove a masked object from an image, by asset id or by uploaded bytes", "Slug": "post-remove-object-from-v2-assets", "Description": "Remove a masked object from an image. For each of the source image and the\nmask, supply either an \u0060AssetIdentifier\u0060 reference (\u0060image_asset_identifier\u0060\n/ \u0060mask_asset_identifier\u0060) or the raw image bytes directly (\u0060image\u0060 / \u0060mask\u0060,\nmultipart requests only) \u2014 callers are never required to call\n\u0060POST /v2/assets\u0060 first. If both a reference and bytes are supplied for the\nsame input, the reference wins and the bytes are ignored.\n\nPoll for completion with \u0060GET /v1/generations/{generation_id}\u0060 using the\nreturned \u0060generation_id\u0060.\n\nThis is the \u0060/v2\u0060 capability-first shape; no \u0060model\u0060 or \u0060model_uri\u0060 field is\nexposed until a second backend exists.", @@ -1783,7 +1794,7 @@ "Setup": null }, { - "Order": 163, + "Order": 164, "Title": "Generate Magic Prompt", "Slug": "post-magic-prompt", "Description": "Transforms basic prompts into a magic prompt. Internal use only (feature flagged). TODO: update description if enabled externally.", @@ -1794,7 +1805,7 @@ "Setup": null }, { - "Order": 164, + "Order": 165, "Title": "Generate a Magic Prompt with Ideogram 4.0", "Slug": "post-magic-prompt-v4", "Description": "Transforms a basic prompt into an enhanced Ideogram 4.0 magic prompt.\nThe magic prompt model version is fixed; callers cannot select it.\nWhen \u0060aspect_ratio\u0060 is \u0060AUTO\u0060 (the default), the model selects the most\nsuitable aspect ratio for the prompt and returns it in the response.", @@ -1805,7 +1816,7 @@ "Setup": "This example assumes \u0060using Ideogram;\u0060 is in scope and \u0060apiKey\u0060 contains the required credential." }, { - "Order": 165, + "Order": 166, "Title": "Check whether content was created by Ideogram", "Slug": "post-provenance-verify", "Description": "Checks image content for an Ideogram provenance manifest (C2PA Content\nCredentials) and returns the disclosure it carries: the provider name,\nthe generating system and its version, the creation time, and the\ncontent\u0027s unique identifier.\n\nUpload the image to verify as the \u0060content\u0060 part.\n\nThis endpoint is public and unauthenticated \u2014 no API key is required.\nSubmitted content is analyzed in memory and never stored.", @@ -1816,7 +1827,7 @@ "Setup": null }, { - "Order": 166, + "Order": 167, "Title": "Remove an image background", "Slug": "post-remove-background-v2", "Description": "Remove the background from one image and return a foreground PNG with\ntransparency. Supply exactly one source: raw \u0060image\u0060 bytes in a\nmultipart request, or an existing \u0060image_asset_identifier\u0060 in JSON or\nmultipart form.\n\nBy default the request blocks until the foreground image is ready and\nreturns it in \u0060data\u0060. Set \u0060async\u0060 to true to return immediately after\nthe request is accepted, then poll \u0060GET /v1/generations/{generation_id}\u0060.\n\nAPI-key requests use the organization bound to the key. Firebase Bearer\nrequests use their selected organization, and Mini App context tokens\nremain bound to the organization in the token. When \u0060private\u0060 is omitted,\nBearer and Mini App callers inherit their plan\u0027s private-generation\ndefault; Enterprise generations are always private.", @@ -1827,7 +1838,7 @@ "Setup": null }, { - "Order": 167, + "Order": 168, "Title": "Replace an image background", "Slug": "post-replace-background", "Description": "Replaces the background of one image from a text prompt while preserving\nthe foreground subject. The foreground mask is detected automatically;\ncallers do not provide a mask.\n\nThe request is processed asynchronously. Poll\n\u0060GET /v1/generations/{generation_id}\u0060 with the returned \u0060generation_id\u0060\nuntil the generation is completed or failed.\n\nSupply exactly one source transport: an existing \u0060AssetIdentifier\u0060 in\n\u0060image_asset_identifier\u0060, or raw \u0060image\u0060 bytes in a multipart request.\nSupplying both or neither is rejected with a 400.", @@ -1838,7 +1849,7 @@ "Setup": null }, { - "Order": 168, + "Order": 169, "Title": "Replace an image background with Ideogram 3.0", "Slug": "post-replace-background-ideogram-v3", "Description": "Replaces the background of one image from a text prompt while preserving\nthe foreground subject, generated by Ideogram 3.0 inpainting. The\nforeground mask is detected automatically; callers do not provide a mask.\n\nThe request is processed asynchronously. Poll\n\u0060GET /v1/generations/{generation_id}\u0060 with the returned \u0060generation_id\u0060\nuntil the generation is completed or failed.\n\nSupply exactly one source transport: an existing \u0060AssetIdentifier\u0060 in\n\u0060image_asset_identifier\u0060, or raw \u0060image\u0060 bytes in a multipart request.\nSupplying both or neither is rejected with a 400. The source\u0027s longer\nside must be at most 3 times its shorter side; wider aspect ratios are\nrejected with a 400.", @@ -1849,7 +1860,7 @@ "Setup": null }, { - "Order": 169, + "Order": 170, "Title": "Upscale an image", "Slug": "post-upscale", "Description": "Upscale one image to 2x, 4x, or 8x its original resolution, up to a\nmaximum output of 8192px per side. Ideogram selects the best upscaling\nmodel for each request, and the selection may change over time; callers\nnever choose a model.\n\nSupply the source either as an \u0060image_asset_identifier\u0060 reference (an\nimage already stored with Ideogram) or as raw \u0060image\u0060 bytes (multipart\nrequests only). Provide exactly one of the two forms; supplying both,\nor neither, is rejected with a 400. Uploaded bytes are used for this\nrequest only and are not stored as an asset; upscales of a referenced\nasset keep a visible link to their source image.\n\nUpscaling takes no prompt: the source image is enhanced as-is.\n\nBy default the request blocks until the upscaled image is ready and\nreturns it in \u0060data\u0060. Set \u0060async\u0060 to true to return immediately after\nthe request is accepted, then poll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using the returned\n\u0060generation_id\u0060.\n\nSupplying a \u0060webhook_url\u0060 makes the request asynchronous whatever\n\u0060async\u0060 says: the response returns as soon as the request is accepted,\nand the finished result is POSTed to that URL.", @@ -1860,7 +1871,7 @@ "Setup": null }, { - "Order": 170, + "Order": 171, "Title": "Produce a video from reference media with MiniMax H3", "Slug": "post-edit-video-minimax-h3-reference-to-video", "Description": "Produce a video from a text prompt and reference media with MiniMax H3.\n\nThe prompt addresses the references by position: the first reference\nimage is \u0060Image 1\u0060, the second \u0060Image 2\u0060, the first reference video is\n\u0060Video 1\u0060, and the first reference audio is \u0060Audio 1\u0060. Supply reference\nimages either as\n\u0060reference_image_asset_identifiers\u0060 (images already stored with\nIdeogram) or as raw \u0060reference_images\u0060 bytes (multipart requests only);\nsupplying both is rejected, and uploaded bytes are used for this request\nonly and are not stored as an asset. Supply reference videos as\n\u0060reference_video_asset_identifiers\u0060, which must reference videos\ngenerated or uploaded with Ideogram. At most 9 reference images and 3 reference\nvideos are accepted, and reference videos are capped again on clip\nlength. Optional \u0060reference_audios\u0060 accepts MP3/WAV uploads alongside\nan image or video. Audio and video references must total at most 15\nseconds; at most 12 references are accepted across all media.\n\nReferences are optional. With none, the video is produced from the\nprompt alone.\n\nVideo generation always runs asynchronously: the response returns as\nsoon as the request is accepted and carries only a \u0060generation_id\u0060.\nPoll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using that id, or supply a\n\u0060webhook_url\u0060 to have the finished result POSTed to your server\ninstead.\n\nVideo links are available for a limited period of time; download the\nvideo if you want to keep it.", @@ -1871,7 +1882,7 @@ "Setup": null }, { - "Order": 171, + "Order": 172, "Title": "Edit a video with Seedance 2.0 by regenerating from frames of it", "Slug": "post-edit-video-seed-dance2", "Description": "Edit a video you already have stored with Ideogram by replacing part of\nit. Reference the source video with \u0060video_asset_identifier\u0060 and mark the\nspan to replace with \u0060start_frame_time\u0060 and \u0060end_frame_time\u0060, in seconds.\nSeedance 2.0 generates a new clip for that span from your prompt, and the\nresult is the source video with the generated clip spliced in over the\nspan: everything before \u0060start_frame_time\u0060, then the generated clip, then\neverything from \u0060end_frame_time\u0060 on. That edited video is the asset the\nrequest produces.\n\n\u0060is_start_frame_included\u0060 and \u0060is_end_frame_included\u0060 anchor the generated\nclip on the span\u0027s own end frames, so it joins the surrounding footage\ninstead of cutting to something unrelated. Anchoring the start opens the\nclip on the frame already at \u0060start_frame_time\u0060; anchoring the end lands\nit on the frame at \u0060end_frame_time\u0060; anchoring both joins at each seam. At\nleast one must be anchored.\n\nThe generated clip is used at its own length, which the model rarely makes\nexactly the span\u0027s, so the edited video is usually a different length from\nthe source. Request a \u0060duration\u0060 close to the span to keep them near each\nother. The clip is scaled and cropped to fill the source\u0027s frame and\nconformed to its frame rate, so resolution and aspect ratio follow the\nsource rather than being requested.\n\nVideo generation always runs asynchronously: the response returns as\nsoon as the request is accepted and carries only a \u0060generation_id\u0060.\nPoll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using that id, or supply a\n\u0060webhook_url\u0060 to have the finished result POSTed to your server\ninstead.\n\nVideo links are available for a limited period of time; download the\nvideo if you want to keep it.", @@ -1882,7 +1893,7 @@ "Setup": "This example assumes \u0060using Ideogram;\u0060 is in scope and \u0060apiKey\u0060 contains the required credential." }, { - "Order": 172, + "Order": 173, "Title": "Generate a video from a first frame with Kling v3 Standard, by asset id or by uploaded bytes", "Slug": "post-generate-video-kling-v3-standard-image-to-video", "Description": "Generate a video from a first-frame image and a text prompt with Kling\nv3 Standard. Supply the first frame either as an\n\u0060image_asset_identifier\u0060 reference (an image already stored with\nIdeogram) or as raw \u0060image\u0060 bytes (multipart requests only) \u2014 callers\nare never required to upload the asset first. Exactly one source is\nrequired; supplying neither or both is rejected. Only image assets are\naccepted as a first frame. Uploaded bytes are used for this request\nonly and are not stored as an asset.\n\nTo generate a transition between two stills, supply a final frame as\nwell, in either of the same two forms: \u0060end_image_asset_identifier\u0060 or\n\u0060end_image\u0060. The final frame is optional and follows the same\none-form-only rule.\n\nThe generated video takes its aspect ratio from the first frame, so\nthere is no aspect ratio to set.\n\nVideo generation always runs asynchronously: the response returns as\nsoon as the request is accepted and carries only a \u0060generation_id\u0060.\nPoll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using that id, or supply a\n\u0060webhook_url\u0060 to have the finished result POSTed to your server\ninstead.\n\nVideo links are available for a limited period of time; download the\nvideo if you want to keep it.", @@ -1893,7 +1904,7 @@ "Setup": null }, { - "Order": 173, + "Order": 174, "Title": "Generate a video from a text prompt with Kling v3 Standard", "Slug": "post-generate-video-kling-v3-standard-text-to-video", "Description": "Generate a video from a text prompt with Kling v3 Standard.\n\nVideo generation always runs asynchronously: the response returns as\nsoon as the request is accepted and carries only a \u0060generation_id\u0060.\nPoll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using that id, or supply a\n\u0060webhook_url\u0060 to have the finished result POSTed to your server\ninstead.\n\nVideo links are available for a limited period of time; download the\nvideo if you want to keep it.", @@ -1904,7 +1915,7 @@ "Setup": "This example assumes \u0060using Ideogram;\u0060 is in scope and \u0060apiKey\u0060 contains the required credential." }, { - "Order": 174, + "Order": 175, "Title": "Generate a video from a first frame with MiniMax H3, by asset id or by uploaded bytes", "Slug": "post-generate-video-minimax-h3-image-to-video", "Description": "Generate a video from a first-frame image and a text prompt with\nMiniMax H3. Supply the first frame either as an\n\u0060image_asset_identifier\u0060 reference (an image already stored with\nIdeogram) or as raw \u0060image\u0060 bytes (multipart requests only) \u2014 callers\nare never required to upload the asset first. Exactly one source is\nrequired; supplying neither or both is rejected. Only image assets are\naccepted as a first frame. Uploaded bytes are used for this request\nonly and are not stored as an asset.\n\nTo generate a transition between two stills, supply a final frame as\nwell, in either of the same two forms: \u0060end_image_asset_identifier\u0060 or\n\u0060end_image\u0060. The final frame is optional and follows the same\none-form-only rule.\n\nThe generated video takes its aspect ratio from the first frame, so\nthis endpoint accepts no \u0060aspect_ratio\u0060.\n\nVideo generation always runs asynchronously: the response returns as\nsoon as the request is accepted and carries only a \u0060generation_id\u0060.\nPoll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using that id, or supply a\n\u0060webhook_url\u0060 to have the finished result POSTed to your server\ninstead.\n\nVideo links are available for a limited period of time; download the\nvideo if you want to keep it.", @@ -1915,7 +1926,7 @@ "Setup": null }, { - "Order": 175, + "Order": 176, "Title": "Generate a video from a text prompt with MiniMax H3", "Slug": "post-generate-video-minimax-h3-text-to-video", "Description": "Generate a video from a text prompt with MiniMax H3.\n\nVideo generation always runs asynchronously: the response returns as\nsoon as the request is accepted and carries only a \u0060generation_id\u0060.\nPoll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using that id, or supply a\n\u0060webhook_url\u0060 to have the finished result POSTed to your server\ninstead.\n\nVideo links are available for a limited period of time; download the\nvideo if you want to keep it.", @@ -1926,7 +1937,7 @@ "Setup": "This example assumes \u0060using Ideogram;\u0060 is in scope and \u0060apiKey\u0060 contains the required credential." }, { - "Order": 176, + "Order": 177, "Title": "Generate a video from a first frame with Seedance 2.5, by asset id or by uploaded bytes", "Slug": "post-generate-video-seed-dance25-image-to-video", "Description": "Generate a video from a first-frame image and a text prompt with\nSeedance 2.5. Supply the first frame either as an\n\u0060image_asset_identifier\u0060 reference (an image already stored with\nIdeogram) or as raw \u0060image\u0060 bytes (multipart requests only) \u2014 callers\nare never required to upload the asset first. Exactly one source is\nrequired; supplying neither or both is rejected. Only image assets are\naccepted as a first frame. Uploaded bytes are used for this request\nonly and are not stored as an asset.\n\nTo generate a transition between two stills, supply a final frame as\nwell, in either of the same two forms: \u0060end_image_asset_identifier\u0060 or\n\u0060end_image\u0060. The final frame is optional and follows the same\none-form-only rule.\n\nSeedance 2.5 always derives an image-to-video result\u0027s aspect ratio\nfrom its first frame, so this endpoint takes no \u0060aspect_ratio\u0060.\n\nVideo generation always runs asynchronously: the response returns as\nsoon as the request is accepted and carries only a \u0060generation_id\u0060.\nPoll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using that id, or supply a\n\u0060webhook_url\u0060 to have the finished result POSTed to your server\ninstead.\n\nVideo links are available for a limited period of time; download the\nvideo if you want to keep it.", @@ -1937,7 +1948,7 @@ "Setup": null }, { - "Order": 177, + "Order": 178, "Title": "Produce a video from reference images and videos with Seedance 2.5", "Slug": "post-generate-video-seed-dance25-reference-to-video", "Description": "Produce a video from a text prompt and reference media with\nSeedance 2.5.\n\nThe prompt addresses the references by position: the first reference\nimage is \u0060[Image1]\u0060, the second\n\u0060[Image2]\u0060, the first reference video is\n\u0060[Video1]\u0060, and so on. Supply reference images\neither as \u0060reference_image_asset_identifiers\u0060 (images already stored\nwith Ideogram) or as raw \u0060reference_images\u0060 bytes (multipart requests\nonly); supplying both is rejected, and uploaded bytes are used for this\nrequest only and are not stored as an asset. Supply reference videos as\n\u0060reference_video_asset_identifiers\u0060, which can reference uploaded or generated videos. At most 9 reference images and 10\nreference videos are accepted, and reference videos are capped again on\nclip length: each clip must be between 2 and 30 seconds long, and the clips must total no more than 30 seconds.\nSupply up to 10 MP3/WAV \u0060reference_audios\u0060 as multipart files, at most 15 MB each.\nEach audio clip must be 2\u201330 seconds, with at most 30 seconds total. Reference\nthem as \u0060[Audio1]\u0060, \u0060[Audio2]\u0060, and so on. Audio is used for this request only.\n\nAt least one reference image or video is required: the model\nconditions every generation on the media it is given, so a request\nwith no references is rejected.\n\nVideo generation always runs asynchronously: the response returns as\nsoon as the request is accepted and carries only a \u0060generation_id\u0060.\nPoll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using that id, or supply a\n\u0060webhook_url\u0060 to have the finished result POSTed to your server\ninstead.\n\nVideo links are available for a limited period of time; download the\nvideo if you want to keep it.", @@ -1948,7 +1959,7 @@ "Setup": null }, { - "Order": 178, + "Order": 179, "Title": "Generate a video from a text prompt with Seedance 2.5", "Slug": "post-generate-video-seed-dance25-text-to-video", "Description": "Generate a video from a text prompt with Seedance 2.5, which serves\nresolutions up to 1080p and durations up to 30 seconds.\n\nVideo generation always runs asynchronously: the response returns as\nsoon as the request is accepted and carries only a \u0060generation_id\u0060.\nPoll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using that id, or supply a\n\u0060webhook_url\u0060 to have the finished result POSTed to your server\ninstead.\n\nVideo links are available for a limited period of time; download the\nvideo if you want to keep it.", @@ -1959,7 +1970,7 @@ "Setup": "This example assumes \u0060using Ideogram;\u0060 is in scope and \u0060apiKey\u0060 contains the required credential." }, { - "Order": 179, + "Order": 180, "Title": "Generate a video from a first frame with Seedance 2.0, by asset id or by uploaded bytes", "Slug": "post-generate-video-seed-dance2-image-to-video", "Description": "Generate one or more videos from a first-frame image and a text prompt\nwith Seedance 2.0. Supply the first frame either as an\n\u0060image_asset_identifier\u0060 reference (an image already stored with\nIdeogram) or as raw \u0060image\u0060 bytes (multipart requests only) \u2014 callers\nare never required to upload the asset first. Exactly one source is\nrequired; supplying neither or both is rejected. Only image assets are\naccepted as a first frame. Uploaded bytes are used for this request\nonly and are not stored as an asset.\n\nTo generate a transition between two stills, supply a final frame as\nwell, in either of the same two forms: \u0060end_image_asset_identifier\u0060 or\n\u0060end_image\u0060. The final frame is optional, follows the same one-form-only\nrule, and requires a first frame.\n\nVideo generation always runs asynchronously: the response returns as\nsoon as the request is accepted and carries only a \u0060generation_id\u0060.\nPoll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using that id, or supply a\n\u0060webhook_url\u0060 to have the finished result POSTed to your server\ninstead.\n\nVideo links are available for a limited period of time; download the\nvideo if you want to keep it.", @@ -1970,7 +1981,7 @@ "Setup": null }, { - "Order": 180, + "Order": 181, "Title": "Produce a video from reference images and videos with Seedance 2.0", "Slug": "post-generate-video-seed-dance2-reference-to-video", "Description": "Produce a video from a text prompt and reference media with\nSeedance 2.0.\n\nThe prompt addresses the references by position: the first reference\nimage is \u0060@Image1\u0060, the second\n\u0060@Image2\u0060, the first reference video is\n\u0060@Video1\u0060, and so on. Supply reference images\neither as \u0060reference_image_asset_identifiers\u0060 (images already stored\nwith Ideogram) or as raw \u0060reference_images\u0060 bytes (multipart requests\nonly); supplying both is rejected, and uploaded bytes are used for this\nrequest only and are not stored as an asset. Supply reference videos as\n\u0060reference_video_asset_identifiers\u0060, which can reference uploaded or generated videos. At most 9 reference images and 3\nreference videos are accepted, and reference videos are capped again on\nclip length: each clip must be between 2 and 15 seconds long, and the clips must total no more than 15 seconds.\nSupply up to 3 MP3/WAV \u0060reference_audios\u0060 as multipart files, at most 15 MB each.\nEach audio clip must be 2\u201315 seconds, with at most 15 seconds total. Reference\nthem as \u0060@Audio1\u0060, \u0060@Audio2\u0060, and so on. Audio is used for this request only.\nImages, videos, and audio combined must not exceed 12 references.\n\nAt least one reference image or video is required: the model\nconditions every generation on the media it is given, so a request\nwith no references is rejected.\n\nVideo generation always runs asynchronously: the response returns as\nsoon as the request is accepted and carries only a \u0060generation_id\u0060.\nPoll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using that id, or supply a\n\u0060webhook_url\u0060 to have the finished result POSTed to your server\ninstead.\n\nVideo links are available for a limited period of time; download the\nvideo if you want to keep it.", @@ -1981,7 +1992,7 @@ "Setup": null }, { - "Order": 181, + "Order": 182, "Title": "Generate a video from a text prompt with Seedance 2.0", "Slug": "post-generate-video-seed-dance2-text-to-video", "Description": "Generate one or more videos from a text prompt with Seedance 2.0.\n\nVideo generation always runs asynchronously: the response returns as\nsoon as the request is accepted and carries only a \u0060generation_id\u0060.\nPoll for completion and results with\n\u0060GET /v1/generations/{generation_id}\u0060 using that id, or supply a\n\u0060webhook_url\u0060 to have the finished result POSTed to your server\ninstead.\n\nVideo links are available for a limited period of time; download the\nvideo if you want to keep it.", @@ -1992,7 +2003,7 @@ "Setup": "This example assumes \u0060using Ideogram;\u0060 is in scope and \u0060apiKey\u0060 contains the required credential." }, { - "Order": 182, + "Order": 183, "Title": "Create a looping 360-degree product video", "Slug": "post-product360-video", "Description": "Animates one product image through a complete turntable revolution and returns to the starting pose so the result loops cleanly.\nVideo generation runs asynchronously. Poll \u0060GET /v1/generations/{generation_id}\u0060 with the returned \u0060generation_id\u0060 until the generation completes or fails.", @@ -2003,7 +2014,7 @@ "Setup": "This example assumes \u0060using Ideogram;\u0060 is in scope and \u0060apiKey\u0060 contains the required credential." }, { - "Order": 183, + "Order": 184, "Title": "Describe", "Slug": "post-describe", "Description": "Describe an image.\n\nSupported image formats include JPEG, PNG, and WebP.", @@ -2014,7 +2025,7 @@ "Setup": null }, { - "Order": 184, + "Order": 185, "Title": "Describe with Ideogram 4.0", "Slug": "post-describe-v4", "Description": "Describe an image with Ideogram 4.0 and return a structured\n\u0060V4JsonPrompt\u0060. The returned \u0060json_prompt\u0060 is a working JSON prompt\nthat can be passed directly as \u0060json_prompt\u0060 to the\n\u0060/v1/ideogram-v4/generate\u0060 family of endpoints.\n\nSupported image formats include JPEG, PNG, and WebP.", @@ -2025,7 +2036,7 @@ "Setup": null }, { - "Order": 185, + "Order": 186, "Title": "Get the public keys used to verify webhook signatures", "Slug": "get-webhook-signing-jwks", "Description": "Returns the set of Ed25519 public keys Ideogram uses to sign outbound\nwebhook payloads. Customers verify incoming webhooks by recomputing the\ncanonical signed message (\u0060request_id\\nuser_id\\ntimestamp\\nsha256_hex(body)\u0060)\nand checking the \u0060X-Ideogram-Webhook-Signature\u0060 header against any key\nin this document.\n\nThe document includes the current signing key plus any keys recently\nrotated out, so signatures already in flight remain verifiable across\nrotations. Cache for up to 24 hours; refresh sooner if a signature\nfails to verify against the cached set.\n\nThis endpoint is public and unauthenticated \u2014 no API key is required.", diff --git a/src/libs/Ideogram/openapi.json b/src/libs/Ideogram/openapi.json index 73001fe..65f2e60 100644 --- a/src/libs/Ideogram/openapi.json +++ b/src/libs/Ideogram/openapi.json @@ -151,6 +151,10 @@ }, "name": "images-remix" }, + { + "description": "Edit source images at the source's own width and height. These endpoints never reframe: the output always matches the image you sent.", + "name": "images-precise-edit" + }, { "description": "Repaint a masked region of an image with a specific model contract.\nRequests supply the source image and mask by `AssetIdentifier`\nreference or as uploaded bytes and return a generation id that can be\npolled via `GET /v1/generations/{generation_id}`.\n", "externalDocs": { @@ -9560,6 +9564,101 @@ "x-openapi-router-controller": "external_api.generated.openapi.controllers.images_inpaint_controller" } }, + "/v2/image/precise-edit/ideogram-4-5": { + "post": { + "description": "Edit an image with Ideogram 4.5, returning output at that image's exact\nwidth and height. An image too large for the model is scaled down to\nfit while keeping its exact proportion, and one whose aspect ratio is\noutside 1:6 to 6:1 is rejected — this endpoint never reshapes, so there\nis no size to reshape it to. Unlike\n`POST /v2/image/generate/ideogram-4-5`, this endpoint takes no `size`:\nthe output always matches the image being edited, so the edit drops\nback into whatever it came from without reframing.\n\nSupply the image to edit as an `image_asset_identifier` reference or as\nraw `image` bytes (multipart requests only); if both are supplied, the\nreference wins and the bytes are ignored. Add up to four more images\nvia `reference_image_asset_identifiers` or `reference_images` to guide\nthe edit — those are never edited themselves.\n\nSupply a `mask` to confine the edit to part of the image being edited.\nThe mask is optional — without one the prompt is applied to the whole\nimage. Masks are read as an additional reference image, so a masked\nrequest may carry at most three `reference_images`.\n\nThe `prompt` is the edit instruction. It accepts either natural\nlanguage or a structured JSON prompt; the server detects which was\nsupplied. A natural-language instruction is automatically rewritten\ninto the model's structured edit contract, while a prompt that is\nalready valid structured JSON is consumed directly.\n\nBy default the request blocks until the images are ready and returns\nthem in `data`. Set `async` to true to return immediately after the\nrequest is accepted, then poll for completion and results with\n`GET /v1/generations/{generation_id}` using the returned\n`generation_id`.\n\nSupplying a `webhook_url` makes the request asynchronous whatever\n`async` says: the response returns as soon as the request is accepted,\nand the finished result is POSTed to that URL.\n", + "operationId": "post_precise_edit_image_v2_ideogram45", + "parameters": [ + { + "description": "When true, the request is validated and priced but not run: nothing is\ngenerated, stored, or billed, and no safety review is performed. The\nresponse is a `PriceQuote` object instead of the usual response for this\nendpoint. Send exactly the request you would send to generate, so the\nquote reflects the same options.\n", + "in": "query", + "name": "dry_run", + "required": false, + "schema": { + "default": false, + "type": "boolean" + } + } + ], + "requestBody": { + "content": { + "multipart/form-data": { + "encoding": { + "image_asset_identifier": { + "contentType": "application/json" + }, + "reference_image_asset_identifiers": { + "contentType": "application/json" + } + }, + "schema": { + "$ref": "#/components/schemas/PreciseEditImageIdeogram45Request" + } + }, + "application/json": { + "schema": { + "$ref": "#/components/schemas/PreciseEditImageIdeogram45Request" + } + } + }, + "description": "A request to edit an image with Ideogram 4.5 at that image's own size. Use `multipart/form-data` to upload `image`, `reference_images` and `mask` bytes directly, or `application/json` (or multipart with `image_asset_identifier`) to reference existing assets instead.", + "required": true, + "x-body-name": "body" + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/PreciseEditImageIdeogram45Response" + } + } + }, + "description": "The edited images (synchronous requests), or an acknowledgement to poll with `GET /v1/generations/{generation_id}` (`async` requests)." + }, + "400": { + "description": "Invalid input provided." + }, + "401": { + "description": "Unauthorized." + }, + "402": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/GenerationErrorResponse" + } + } + }, + "description": "Insufficient credits or quota." + }, + "422": { + "description": "The prompt did not pass safety checks." + }, + "429": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/GenerationErrorResponse" + } + } + }, + "description": "Too many requests." + }, + "500": { + "description": "Internal server error." + }, + "503": { + "description": "The endpoint is temporarily unavailable." + } + }, + "summary": "Edit an image with Ideogram 4.5, keeping the source's exact geometry", + "tags": [ + "images-precise-edit" + ], + "x-openapi-router-controller": "external_api.generated.openapi.controllers.images_precise_edit_controller" + } + }, "/v2/image/reframe/ideogram-3": { "post": { "description": "Expand an image to a new Ideogram 3.0 resolution. The source pixels\nare preserved in the center and Ideogram fills the new area. Supply\nexactly one source: an `AssetIdentifier` reference\n(`image_asset_identifier`) or raw image bytes (`image`, multipart\nrequests only). Supplying both forms, or neither, is rejected.\n\nOptional style controls are mutually exclusive. Supply at most one of\n`style_preset`, `style_codes`, `style_reference_asset_identifiers`, or\nraw `style_reference_images` (multipart requests only). Each style\nreference transport accepts at most 10 images.\n\nBy default the request blocks until the images are ready and returns\nthem in `data`. Set `async` to true to return immediately, then poll\n`GET /v1/generations/{generation_id}`.\n", @@ -25430,7 +25529,7 @@ "$ref": "#/components/schemas/ResolutionV3" }, "aspect_ratio": { - "$ref": "#/components/schemas/AspectRatioV3" + "$ref": "#/components/schemas/IdeogramV3AspectRatio" }, "rendering_speed": { "default": "default", @@ -25628,7 +25727,7 @@ "$ref": "#/components/schemas/ResolutionV3" }, "aspect_ratio": { - "$ref": "#/components/schemas/AspectRatioV3" + "$ref": "#/components/schemas/IdeogramV3AspectRatio" }, "rendering_speed": { "description": "The rendering speed to use. When omitted, the server chooses a speed supported by the selected custom model.", @@ -27036,7 +27135,7 @@ "type": "string" }, "aspect_ratio": { - "$ref": "#/components/schemas/AspectRatioV3" + "$ref": "#/components/schemas/IdeogramV3AspectRatio" }, "rendering_speed": { "default": "default", @@ -27643,11 +27742,12 @@ "type": "object" }, "GenerateImageIdeogram45Request": { - "description": "Source images are optional. When supplied, the request becomes an\nimage-to-image transform: the prompt becomes optional guidance and\n`size` defaults to \"auto\" (derived from the first source). Without\nsource images a prompt is required.\n", + "description": "Source images are optional. When supplied, the request becomes an\nimage-to-image transform and `size` defaults to \"auto\" (derived from\nthe first source). A prompt is required either way.\n", "properties": { "prompt": { - "description": "The prompt to generate images from. Accepts either natural\nlanguage or a structured Ideogram 4.0 JSON prompt; the server\ndetects which was supplied. Required without source images; with\nsources it is optional guidance and may be empty.\n", + "description": "The prompt to generate images from, or the edit instruction to\napply when source images are supplied. Accepts either natural\nlanguage or a structured Ideogram 4.0 JSON prompt; the server\ndetects which was supplied.\n", "maxLength": 10000, + "minLength": 1, "type": "string" }, "magic_prompt": { @@ -27657,7 +27757,7 @@ } ], "default": "auto", - "description": "Controls magic prompt (automatic prompt rewriting). `auto` (the\ndefault) and `on` rewrite a natural-language prompt, while a\nprompt that is already a valid structured JSON prompt is always\nconsumed directly. `off` disables rewriting entirely: the model\nreceives your prompt verbatim.\n" + "description": "Controls how a natural-language prompt is prepared. `auto` (the\ndefault) and `on` rewrite and expand the prompt before\ngeneration. `off` keeps your wording and only converts the prompt\ninto the structured format the model consumes. A prompt that is\nalready a valid structured JSON prompt skips magic prompt\nentirely unless `magic_prompt` is `on`. With source images the\nprompt is an edit instruction, and every mode converts it into\nthe structured edit contract the model consumes.\n" }, "image_asset_identifiers": { "description": "Existing upload or generated image assets to transform, by reference. Takes priority over `images` if both are supplied. The first source is the primary image; any further sources are additional references. Supplying sources turns the request into an image-to-image transform.", @@ -27677,8 +27777,13 @@ "maxItems": 5, "type": "array" }, + "mask": { + "description": "An optional mask confining the edit to part of the first source image, as raw bytes (multipart requests only; JPEG, PNG, or WEBP, max 25MB). Black marks the area to edit and white the area to preserve; values in between are rounded to whichever is nearer. The mask must have the same width and height as the first source image, and must contain both black and white areas. Requires source images uploaded as raw `images` bytes; masks cannot be combined with `image_asset_identifiers`. The mask is supplied to the model as an additional reference image, so a masked request may carry at most three other source images. Supplying a mask fixes the output to the first source's own size, so `size` is rejected alongside it.", + "format": "binary", + "type": "string" + }, "size": { - "description": "The output size: \"auto\" or an exact \"WIDTHxHEIGHT\".\n\nWithout source images, an exact size must be one of the supported\n1K/2K presets (for example 1024x1024, 2048x2048 or 1440x2880);\n\"auto\" or omitted lets the server pick a supported size based on\nthe prompt.\n\nWith source images, \"auto\" (the default) uses the supported\nresolution closest to the first source's dimensions, and an exact\nsize must have both dimensions multiples of 32 and at least 256px,\nthe total size at most 2048x2048 pixels, and the aspect ratio at\nmost 6:1.\n\nPricing is tiered by the resolved output pixels: up to 1024x1024\nbills as 1K, above that as 2K.\n", + "description": "The output size: \"auto\" or an exact \"WIDTHxHEIGHT\".\n\nWithout source images, an exact size must be one of the supported\n1K/2K presets (for example 1024x1024, 2048x2048 or 1440x2880);\n\"auto\" or omitted lets the server pick a supported size based on\nthe prompt.\n\nWith source images, \"auto\" (the default) returns the output at the\nfirst source image's own width and height. A source too large for\nthe model is scaled down to fit while keeping its exact proportion,\nand a source whose aspect ratio is outside 1:6 to 6:1 is rejected,\nbecause serving it would mean reshaping an image you did not ask to\nreshape — name an exact size if that is what you want.\n\nAn exact size must have both dimensions multiples of 32 and at least\n256px, the total size at most 2048x2048 pixels, and the aspect ratio\nat most 6:1. Naming one reshapes the source to it.\n\nPricing is tiered by the resolved output pixels: up to 1024x1024\nbills as 1K, above that as 2K.\n", "example": "2048x2048", "nullable": true, "type": "string" @@ -27736,6 +27841,158 @@ "type": "string" } }, + "required": [ + "prompt" + ], + "type": "object" + }, + "PreciseEditImageIdeogram45Response": { + "description": "Response returned by `POST /v2/image/precise-edit/ideogram-4-5`.\nSynchronous requests (the default) include the edited images in `data`.\nRequests with `async` set to true omit `data`; poll for completion and\nresults with `GET /v1/generations/{generation_id}` using the returned\n`generation_id`. The seed reports the value the request resolved to\nwhen the caller left it unset.\n", + "example": { + "data": [ + { + "seed": 12345, + "prompt": "prompt", + "resolution": "1024x1024", + "url": "https://openapi-generator.tech", + "is_image_safe": true + }, + { + "seed": 12345, + "prompt": "prompt", + "resolution": "1024x1024", + "url": "https://openapi-generator.tech", + "is_image_safe": true + } + ], + "seed": 0, + "generation_id": "generation_id" + }, + "properties": { + "generation_id": { + "description": "URL-safe base64 ID of the accepted generation. Accepted by the\n`GET /v1/generations/{generation_id}` polling endpoint.\n", + "title": "generation_id", + "type": "string" + }, + "data": { + "description": "The edited images, in generation order. Present only for synchronous requests (`async` omitted or false).", + "items": { + "$ref": "#/components/schemas/GeneratedImageObject" + }, + "title": "data", + "type": "array" + }, + "seed": { + "description": "The seed the request was served with.", + "title": "seed", + "type": "integer" + } + }, + "title": "PreciseEditImageIdeogram45Response", + "type": "object" + }, + "PreciseEditImageIdeogram45Request": { + "description": "The image being edited is required, as an `image_asset_identifier`\nreference or as raw `image` bytes. The output is always returned at\nthat image's exact width and height, so this request takes no output\nsize.\n", + "properties": { + "prompt": { + "description": "The edit instruction to apply to the sources. Accepts either\nnatural language or a structured JSON prompt; the server detects\nwhich was supplied. Natural language is automatically rewritten\ninto the model's structured edit contract, while structured JSON\nis consumed directly.\n", + "maxLength": 10000, + "minLength": 1, + "type": "string" + }, + "image_asset_identifier": { + "allOf": [ + { + "$ref": "#/components/schemas/AssetIdentifier" + } + ], + "description": "The image to edit, as an existing upload or generated image asset. Supply this or `image`, never both. Takes priority over `image` if both are supplied. Cannot be combined with `mask`." + }, + "image": { + "description": "The image to edit, as raw bytes (max size 25MB; JPEG, PNG, or WEBP only). Multipart requests only; ignored if `image_asset_identifier` is also supplied. Required when supplying a `mask`.", + "format": "binary", + "type": "string" + }, + "reference_image_asset_identifiers": { + "description": "Optional additional images to guide the edit, by reference. These are never edited themselves; only `image_asset_identifier` or `image` is. Requires the image being edited to be supplied by reference too, and cannot be combined with `mask`.", + "items": { + "$ref": "#/components/schemas/AssetIdentifier" + }, + "maxItems": 4, + "minItems": 1, + "type": "array" + }, + "reference_images": { + "description": "Optional additional images to guide the edit (max 4, max size 25MB each), as raw bytes; only JPEG, PNG, and WEBP formats are supported. These are never edited themselves; only `image` is. Multipart requests only; ignored if `reference_image_asset_identifiers` is also supplied. A masked request may carry at most three, because the mask occupies one of the model's reference slots.", + "items": { + "format": "binary", + "type": "string" + }, + "maxItems": 4, + "type": "array" + }, + "mask": { + "description": "An optional mask confining the edit to part of `image`, as raw bytes (multipart requests only; JPEG, PNG, or WEBP, max 25MB). Black marks the area to edit and white the area to preserve; values in between are rounded to whichever is nearer. The mask must have the same width and height as `image`, and must contain both black and white areas. Requires the image being edited to be uploaded as raw `image` bytes in the same request; masks cannot be combined with asset references. The mask is supplied to the model as an additional reference image, so a masked request may carry at most three `reference_images`.", + "format": "binary", + "type": "string" + }, + "rendering_speed": { + "default": "default", + "description": "The rendering speed to use. `ultra` renders multiple candidate edits internally and returns the one that best applies the instruction; it takes longer than `quality`, is priced higher, and supports at most 4 images per request.", + "enum": [ + "turbo", + "default", + "quality", + "ultra" + ], + "type": "string" + }, + "seed": { + "description": "Random seed. Set for reproducible generation.", + "example": 12345, + "maximum": 2147483647, + "minimum": 0, + "title": "Seed", + "type": "integer" + }, + "num_images": { + "default": 1, + "description": "The number of images to generate.", + "maximum": 8, + "minimum": 1, + "type": "integer" + }, + "enable_copyright_detection": { + "description": "Optional. Opt this request into post-generation copyright detection. Adds detection latency; flagged images come back with `is_image_safe: false`.", + "nullable": true, + "type": "boolean" + }, + "async": { + "default": false, + "description": "When false (the default), the request blocks until the images are ready and returns them in `data`. When true, the request returns as soon as it is accepted; poll for completion and results with `GET /v1/generations/{generation_id}` using the returned `generation_id`.", + "type": "boolean" + }, + "webhook_url": { + "description": "HTTPS URL that Ideogram delivers the generated result to. Ideogram sends a\nJSON POST to this URL once all images for the request have finished\ngenerating. The body mirrors the synchronous generate response:\n`request_id`, `created`, and a `data` array\ncontaining every generated image (`url`, `prompt`, `resolution`, `seed`,\n`is_image_safe`). Each delivery is signed with Ed25519 and verifiable\nagainst the public keys at `https://api.ideogram.ai/v1/.well-known/jwks.json`. Must be HTTPS;\nprivate and loopback hosts and the cloud metadata service are rejected.\n", + "example": "https://api.example.com/webhooks/ideogram", + "format": "uri", + "maxLength": 2048, + "title": "webhook_url", + "type": "string" + }, + "private": { + "description": "When true or omitted, the output is kept private to your account. Set to false to publish the output to the public feed. Enterprise accounts always generate privately.", + "nullable": true, + "type": "boolean" + }, + "target_collection_id": { + "description": "A collection you can write to, by its URL-safe base64 collection id. The output images are added to it when the request completes.", + "type": "string" + } + }, + "required": [ + "prompt" + ], "type": "object" }, "GenerateImageNanoBanana2Response": { @@ -28543,7 +28800,7 @@ "type": "integer" }, "aspect_ratio": { - "$ref": "#/components/schemas/AspectRatioV3" + "$ref": "#/components/schemas/IdeogramV3AspectRatio" }, "rendering_speed": { "default": "default", @@ -28699,7 +28956,7 @@ "type": "integer" }, "aspect_ratio": { - "$ref": "#/components/schemas/AspectRatioV3" + "$ref": "#/components/schemas/IdeogramV3AspectRatio" }, "rendering_speed": { "default": "default", @@ -29579,7 +29836,7 @@ "$ref": "#/components/schemas/ResolutionV3" }, "aspect_ratio": { - "$ref": "#/components/schemas/AspectRatioV3" + "$ref": "#/components/schemas/IdeogramV3AspectRatio" }, "rendering_speed": { "default": "default", @@ -35897,6 +36154,29 @@ "minimum": 0, "type": "number" }, + "IdeogramV3AspectRatio": { + "description": "The aspect ratio for an Ideogram 3.x or 2.x generation. `auto` lets the\nmodel select a ratio from the prompt; any other value pins the ratio.\nCannot be combined with `resolution`. Omitting the field is not `auto`:\nit uses `1x1`.\n", + "enum": [ + "auto", + "1x3", + "3x1", + "1x2", + "2x1", + "9x16", + "16x9", + "10x16", + "16x10", + "2x3", + "3x2", + "3x4", + "4x3", + "4x5", + "5x4", + "1x1" + ], + "title": "IdeogramV3AspectRatio", + "type": "string" + }, "MagicPromptMode": { "description": "Determine if MagicPrompt should be used in generating the request or not.", "enum": [