Lovart

Lovart API Documentation

Integrate powerful AI design capabilities into your applications with our comprehensive RESTful API and SDKs.

πŸš€ RESTful API
πŸ“š Multiple SDKs
πŸ”’ Secure Authentication
πŸ“Š Real-time Processing

Quick Start

Get Started in 5 Minutes

1

Get API Key

Sign up and get your API key from the dashboard

2

Install SDK

Choose your preferred programming language SDK

3

Make API Calls

Start integrating AI design capabilities

Authentication

API Key Authentication

All API requests require authentication using your API key. Include your API key in the Authorization header:

Authorization: Bearer YOUR_API_KEY

Security Note: Keep your API key secure and never expose it in client-side code.

API Endpoints

Generate Design

POST /v1/design/generate

Generate AI-powered designs based on text prompts and parameters.

Request Body

{
  "prompt": "Modern logo for tech startup",
  "style": "minimalist",
  "dimensions": {
    "width": 512,
    "height": 512
  },
  "format": "png",
  "quality": "high"
}

Response

{
  "success": true,
  "design_id": "des_123456789",
  "image_url": "https://api.lovart.info/designs/des_123456789.png",
  "thumbnail_url": "https://api.lovart.info/designs/des_123456789_thumb.png",
  "created_at": "2024-01-15T10:30:00Z"
}

Get Design Status

GET /v1/design/{design_id}/status

Check the status of a design generation request.

Upload Image

POST /v1/images/upload

Upload images for processing and enhancement.

Enhance Image

POST /v1/images/enhance

Enhance image quality using AI-powered upscaling and optimization.

List Templates

GET /v1/templates

Get a list of available design templates.

Get Template Details

GET /v1/templates/{template_id}

Get detailed information about a specific template.

Get User Info

GET /v1/user

Get current user account information and usage stats.

Get Usage Statistics

GET /v1/user/usage

Get detailed usage statistics and billing information.

SDKs & Libraries

🐍

Python SDK

Full-featured Python SDK for AI design integration

pip install lovart-ai
View Documentation β†’
πŸ“œ

JavaScript SDK

Modern JavaScript SDK for web applications

npm install lovart-js
View Documentation β†’
🟒

Node.js SDK

Server-side Node.js integration

npm install lovart-node
View Documentation β†’
🌐

REST API

Direct REST API access for any language

curl -X POST https://api.lovart.info/v1/
View Documentation β†’

Code Examples

Python Example

import lovart_ai

# Initialize the client
client = lovart_ai.Client(api_key="your_api_key")

# Generate a design
design = client.design.generate(
    prompt="Modern logo for tech startup",
    style="minimalist",
    dimensions={"width": 512, "height": 512},
    format="png"
)

print(f"Design generated: {design.id}")
print(f"Image URL: {design.image_url}")

JavaScript Example

import { LovartAI } from 'lovart-js';

// Initialize the client
const client = new LovartAI('your_api_key');

// Generate a design
const design = await client.design.generate({
  prompt: 'Modern logo for tech startup',
  style: 'minimalist',
  dimensions: { width: 512, height: 512 },
  format: 'png'
});

console.log(`Design generated: ${design.id}`);
console.log(`Image URL: ${design.imageUrl}`);

cURL Example

curl -X POST https://api.lovart.info/v1/design/generate \
  -H "Authorization: Bearer your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
    "prompt": "Modern logo for tech startup",
    "style": "minimalist",
    "dimensions": {
      "width": 512,
      "height": 512
    },
    "format": "png"
  }'

API Pricing

Flexible pricing plans for developers and businesses of all sizes

Free Tier

$0/month

  • β€’ 100 API calls/month
  • β€’ Basic design generation
  • β€’ Community support

Pro

$49/month

  • β€’ 10,000 API calls/month
  • β€’ Advanced features
  • β€’ Priority support

Enterprise

Custom

  • β€’ Unlimited API calls
  • β€’ Custom integrations
  • β€’ Dedicated support

Need Help?

Our developer support team is here to help you integrate Lovart API successfully.

πŸ“š

Documentation

Comprehensive guides and references

Read Docs β†’
πŸ’¬

Developer Community

Join our developer community

Join Community β†’
πŸ“§

Email Support

Get help from our support team

Contact Support β†’