Skip to content

Latest commit

 

History

History
31 lines (23 loc) · 1.29 KB

README.md

File metadata and controls

31 lines (23 loc) · 1.29 KB

LeonardoAi

Nuget package dotnet License: MIT Discord

Generated C# SDK based on LeonardoAi OpenAPI specification using NSwag.

Usage

using LeonardoAi;

using var client = new HttpClient();
var api = new LeonardoAiApi(apiKey, client);
var createResponse = await api.CreateGenerationAsync(new Body
{
    Prompt = "Generate cat",
});

await Task.Delay(TimeSpan.FromSeconds(15));

var response = await api.GetGenerationByIdAsync(createResponse.SdGenerationJob.GenerationId);
var url = response.Generations_by_pk.Generated_images.ElementAt(0).Url;

Support

Priority place for bugs: https://github.com/tryAGI/LeonardoAi/issues
Priority place for ideas and general questions: https://github.com/tryAGI/LeonardoAi/discussions
Discord: https://discord.gg/Ca2xhfBf3v