PhotoGPT AI Logo
PhotoGPT Developer Platform

Build image and video generation into your product with one API

PhotoGPT handles model training, generation queues, reference-image workflows, video creation, and upscaling so your team can ship creative features faster.

Built on the creative engine behind PhotoGPT's consumer products.

developer.photogptai.com
POST/api/images/generation
{
  "modelID": "<MODEL_ID>",
  "prompt": "studio headshot, soft key light",
  "width": 1024,
  }
200 OK
{ "result": { "jobId": "job_8f3a9c" } }
GET/api/jobs/job_8f3a9c
status: completed15s poll
01Create an API key
02Train or select a model
03Queue generation jobs
04Poll results when ready

Use Cases

Visual features your product can offer on day one

Use PhotoGPT for the heavy creative pipeline, then own the customer experience, templates, pricing, and workflow around it.

Identity

Professional profile products

Generate consistent headshots and profile assets from trained identity models.

Creative

Personalized portrait packs

Offer themed portrait sessions with prompts, presets, and reference images.

Business

Marketing and local business assets

Create campaign images, ads, and website visuals with controlled style direction.

Video

Image-to-video workflows

Turn finished images into short motion assets for social, UGC, and landing pages.

Platform Surface

The core workflows are exposed as predictable APIs

The platform keeps creative generation behind structured jobs, typed request shapes, and dashboard controls that are easy to operate in production.

API Flow

A small integration surface for a full creative pipeline

Use the dashboard for keys and credits, then integrate the same generation flow from your backend using JavaScript, Python, or any HTTP client.

Open quickstart
POST/api/images/generation

Queue generation

Send one structured request to start an image job. The API returns a job ID immediately.

const API_KEY = '<YOUR_API_KEY>'
const BASE_URL = 'https://developer.photogptai.com/api'

const payload = {
  modelID: '<MODEL_ID>',
  prompt: 'professional studio headshot, charcoal blazer, soft key light',
  width: 1024,
  height: 1024,
  numImages: 1,
  enhanceFace: true,
}

const response = await fetch(`${BASE_URL}/images/generation`, {
  method: 'POST',
  headers: {
    Authorization: `Bearer ${API_KEY}`,
    'API-Version': '1',
    'Content-Type': 'application/json',
  },
  body: JSON.stringify(payload),
})

if (!response.ok) throw new Error(await response.text())

const body = await response.json()
console.log('Queued job:', body.result.jobId)
Queue generation
Generated output
GET/api/jobs/{jobId}

Poll and use results

Generation is asynchronous by design. Poll the job endpoint, then read completed images or videos from the result.

async function waitForJob(jobId) {
  while (true) {
    const response = await fetch(`${BASE_URL}/jobs/${jobId}`, {
      headers: {
        Authorization: `Bearer ${API_KEY}`,
        'API-Version': '1',
      },
    })

    if (!response.ok) throw new Error(await response.text())

    const body = await response.json()
    const job = body.result

    if (job.status === 'success') return job
    if (job.status === 'failed') {
      throw new Error(job.error ?? 'Generation failed')
    }

    await new Promise((resolve) => setTimeout(resolve, 15000))
  }
}

const job = await waitForJob('<JOB_ID>')
console.log(job.images?.[0]?.url ?? job.videos?.[0]?.url)
Poll and use results
Generated output

Controls

Security and operations are built into the workflow

The developer platform gives teams the essentials they need before exposing creative AI features to customers: secret management, account-owned assets, and inspectable job history.

Key control

Create, rotate, and delete API keys from the developer dashboard.

Private assets

Uploaded images, trained models, generated files, and videos stay tied to your account.

Operational safeguards

Use clear status values, API error docs, and dashboard usage history to debug issues quickly.

Ready to add PhotoGPT generation to your product?

Start with a dashboard API key, run the quickstart, then move into image generation, training, video, and upscaling guides as your workflow expands.

FAQ

Common integration questions

Do I need to train a model before generating images?

No. You can use general image models immediately. Train a model when you need identity-consistent outputs for a person, character, or brand workflow.

How long does model training take?

Model training usually takes 20-25 minutes. Poll model status every 5 minutes instead of checking every few seconds.

What languages can I use with the API?

Any language that can make HTTPS requests works. The docs include JavaScript and Python examples for every major guide.

Can I generate video from images?

Yes. Use video generation with reference images when the selected model supports image-to-video or first-frame control.

How should my app handle long-running generation?

Queue the job, store the returned job ID, and poll the job endpoint until it reaches a terminal status. Do not keep the original request open while waiting for output.

Can I manage keys and credits from the dashboard?

Yes. The dashboard includes API key management, usage history, credit balance, billing, and model visibility.